html {
    -webkit-text-size-adjust: 100%;
}

html, body {
    min-height: 100vh;
    margin: 0;
    background-color: #0b1329;
    color: #f8fafc;
    font-family: 'Inter', sans-serif;
}

img, svg {
    max-width: 100%;
}

body {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.navbar-wrapper {
    background: rgba(11, 19, 41, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1150px;
    margin: 0 auto;
    padding: 12px 24px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.logo span {
    font-size: 1.15rem;
    font-weight: 700;
    color: #f8fafc;
}

.logo img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 28px;
    margin: 0;
    padding: 0;
}

.nav-links a {
    color: #94a3b8;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.15s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: #38bdf8;
}

.btn-primary {
    background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
    color: #fff;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.15s ease;
}

.btn-primary:hover {
    box-shadow: 0 4px 14px rgba(14, 165, 233, 0.35);
}

.typed-cursor {
    font-weight: 200;
    color: #38bdf8; 
    animation: blink 0.5s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.hero-section {
    text-align: center;
    padding: 6px 20px 0;
}

.hero-section h1 {
    font-size: clamp(1.8rem, 3vw, 2.8rem);
    margin-bottom: 4px;
}

.hero-section p {
    font-size: clamp(0.85rem, 1.1vw, 1rem);
    color: #94a3b8;
    max-width: 800px;
    margin: 0 auto;
}

.courses-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    max-width: 1150px;
    width: 100%;
    margin: 6px auto;
    padding: 0 24px;
    box-sizing: border-box;
    flex: 1;
    min-height: 0;
}

.course-box {
    flex: 1;
    max-width: 520px;
    min-height: 390px; 
    background: linear-gradient(180deg, rgba(30, 41, 59, 0.7) 0%, rgba(15, 23, 42, 0.7) 100%);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    overflow: hidden;
    text-align: left;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.2s ease;
}

.course-box:hover {
    border-color: rgba(56, 189, 248, 0.5);
    transform: translateY(-3px);
    box-shadow: 0 12px 30px -10px rgba(0, 0, 0, 0.5);
}

.card-image-wrapper {
    position: relative;
    width: 100%;
    height: 165px; 
    overflow: hidden;
}

.card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.course-box:hover .card-image {
    transform: scale(1.04);
}

.card-image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(11, 19, 41, 0.2) 0%, rgba(15, 23, 42, 0.95) 100%);
}

.card-body {
    padding: 18px 16px 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex: 1;
}

.card-tag {
    display: inline-block;
    align-self: flex-start;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.1);
    border: 1px solid rgba(56, 189, 248, 0.25);
    padding: 2px 8px;
    border-radius: 10px;
    margin-bottom: 6px;
}

.course-box h2 {
    color: #f8fafc;
    font-size: clamp(1.05rem, 1.3vw, 1.25rem);
    font-weight: 700;
    margin-bottom: 4px;
    line-height: 1.25;
}

.course-box:hover h2 {
    color: #38bdf8;
}

.course-box p {
    color: #94a3b8;
    font-size: clamp(0.78rem, 0.9vw, 0.85rem);
    line-height: 1.35;
    margin: 0;
}

.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 0.8rem;
    font-weight: 600;
    color: #64748b;
}

.course-box:hover .card-footer {
    color: #38bdf8;
}

.card-footer .arrow {
    transition: transform 0.2s ease;
}

.course-box:hover .card-footer .arrow {
    transform: translateX(4px);
}

.features-section {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    max-width: 1150px;
    width: 100%;
    margin: 18px auto 6px; 
    padding: 0 24px;
    box-sizing: border-box;
}

.feature-card {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.4) 0%, rgba(15, 23, 42, 0.5) 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 12px 18px;
    text-align: left;
    display: flex;
    align-items: center;
    gap: 14px;
    transition: all 0.2s ease;
}

.feature-card:hover {
    border-color: rgba(56, 189, 248, 0.3);
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.6) 0%, rgba(15, 23, 42, 0.7) 100%);
    transform: translateY(-2px);
}

.feature-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(56, 189, 248, 0.1);
    border: 1px solid rgba(56, 189, 248, 0.2);
    border-radius: 10px;
    flex-shrink: 0;
}

.feature-content h3 {
    font-size: 0.88rem;
    font-weight: 600;
    color: #f8fafc;
    margin: 0 0 2px 0;
}

.feature-content p {
    font-size: 0.76rem;
    color: #94a3b8;
    margin: 0;
    line-height: 1.3;
}

.footer {
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(15, 23, 42, 0.5);
    padding: 10px 24px;
}

.footer-container {
    max-width: 1150px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    color: #64748b;
}

.footer-links {
    display: flex;
    gap: 20px;
}

.footer-links a {
    color: #64748b;
    text-decoration: none;
}

.footer-links a:hover {
    color: #94a3b8;
}

@media (max-width: 900px) {
    body {
        display: block;
    }

    .navbar {
        flex-direction: column;
        gap: 16px;
        padding: 16px;
    }

    .nav-links {
        gap: 16px;
        flex-wrap: wrap;
        justify-content: center;
    }

    .courses-container {
        flex-direction: column;
        align-items: center;
        padding: 0 16px;
        margin: 20px auto;
    }

    .course-box {
        width: 100%;
        max-width: 100%;
        min-height: 0;
    }

    .card-image-wrapper {
        height: 160px;
    }

    .features-section {
        grid-template-columns: 1fr;
        padding: 0 16px;
        margin: 20px auto;
    }

    .footer-container {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
}

@media (max-width: 600px) {
    .hero-section {
        padding: 4px 16px 0;
    }

    .courses-container {
        gap: 16px;
        padding: 0 14px;
        margin: 16px auto;
    }

    .card-image-wrapper {
        height: 132px;
    }

    .card-body {
        padding: 14px 14px 16px;
    }

    .features-section {
        gap: 12px;
        padding: 0 14px;
    }

    .feature-card {
        padding: 12px 14px;
        gap: 12px;
    }

    .footer {
        padding: 12px 16px;
    }

    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px 16px;
    }
}

/* Text links are only as tall as their font — too small to hit reliably with a
   thumb. Grow the hit area without changing how they look. */
@media (max-width: 767px) {
    header nav a {
        align-items: center;
        min-height: 40px;
    }

    .footer a,
    footer a {
        display: inline-flex;
        align-items: center;
        min-height: 38px;
    }
}

/* Tap-and-stick hover lift on touch devices. */
@media (hover: none) {
    .course-box:hover,
    .feature-card:hover {
        transform: none;
    }

    .course-box:hover .card-image {
        transform: none;
    }
}