/* Bluebell — GCSE Tutor Styles */

:root {
    --bb-primary: #4f6bed;
    --bb-primary-dark: #3b54d4;
    --bb-green: #2ecc71;
    --bb-amber: #f39c12;
    --bb-red: #e74c3c;
    --bb-yellow: #eab308;
    --bb-bg: #f8fafc;
    --bb-text: #1e293b;
    --bb-text-muted: #64748b;
    --bb-border: #e2e8f0;
    --bb-radius: 14px;
}

* { box-sizing: border-box; }

/* Global soft corners */
article, details, figure, dialog { border-radius: var(--bb-radius) !important; }
input, select, textarea { border-radius: 10px !important; }
button { border-radius: 10px !important; }

html {
    scroll-behavior: smooth;
}

body {
    background: var(--bb-bg);
}

body.public-page {
    background: white;
}

/* ============================================
   SHARED: AUTH PAGES
   ============================================ */

.auth-card {
    max-width: 420px;
    margin: 2rem auto;
}

.auth-switch {
    text-align: center;
    margin-top: 1rem;
}

.errors .error {
    color: var(--bb-red);
    font-size: 0.9rem;
    margin: 0.25rem 0;
}

/* ============================================
   SHARED: NAVIGATION
   ============================================ */

.logo {
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--bb-text);
}

.bell-icon {
    vertical-align: middle;
}

.beta-badge {
    font-size: .55rem;
    font-weight: 700;
    letter-spacing: .5px;
    background: var(--bb-primary);
    color: white;
    padding: .15rem .45rem;
    border-radius: 4px;
    margin-left: .25rem;
    vertical-align: super;
}

.xp-badge, .streak-badge {
    background: var(--bb-primary);
    color: white;
    padding: 0.2rem 0.6rem;
    border-radius: 1rem;
    font-size: 0.85rem;
    font-weight: 600;
}

.streak-badge {
    background: var(--bb-amber);
}

/* ============================================
   SITE NAV (unified, always visible)
   ============================================ */
.site-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.4rem 1.5rem;
    background: rgba(255,255,255,0.97);
    border-bottom: 1px solid var(--bb-border);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(12px);
    gap: 1.5rem;
}

.site-nav .logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: inherit;
    flex-shrink: 0;
}

.site-nav .nav-links {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    margin: 0;
    padding: 0;
    align-items: center;
}

.site-nav .nav-links a {
    text-decoration: none;
    color: #475569;
    font-weight: 500;
    font-size: 0.9rem;
    transition: color 0.15s;
}

.site-nav .nav-links a:hover {
    color: var(--bb-primary);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.nav-cta {
    display: inline-block;
    background: var(--bb-primary);
    color: white !important;
    padding: 0.45rem 1.4rem;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: background 0.2s, transform 0.15s;
}

.nav-cta:hover {
    background: var(--bb-primary-dark);
    transform: translateY(-1px);
}

.nav-icon-link {
    color: #94a3b8;
    transition: color 0.15s;
}

.nav-icon-link:hover {
    color: var(--bb-primary);
}

.nav-settings-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.8rem;
    background: #f1f5f9;
    color: #475569 !important;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
    transition: background 0.15s, color 0.15s;
}

.nav-settings-btn:hover {
    background: var(--bb-primary);
    color: white !important;
}

.nav-settings-btn svg {
    flex-shrink: 0;
}

.nav-logout {
    font-size: 0.85rem;
    color: #94a3b8;
    text-decoration: none;
}

.nav-logout:hover {
    color: var(--bb-red);
}

/* Subjects dropdown */
.nav-dropdown {
    position: relative;
}

.nav-dropdown-toggle {
    cursor: pointer;
}

.nav-caret {
    font-size: 0.65em;
    opacity: 0.5;
    transition: transform 0.2s;
}

.nav-dropdown:hover .nav-caret {
    transform: rotate(180deg);
}

.nav-dropdown-panel {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 50%;
    transform: translateX(-50%) translateY(-4px);
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    box-shadow: 0 8px 30px rgba(0,0,0,0.12), 0 2px 8px rgba(0,0,0,0.06);
    padding: 0.5rem;
    min-width: 240px;
    z-index: 200;
    transition: opacity 0.15s, transform 0.15s, visibility 0.15s;
}

.nav-dropdown:hover .nav-dropdown-panel,
.nav-dropdown:focus-within .nav-dropdown-panel {
    visibility: visible;
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Invisible bridge so mouse can travel from trigger to panel */
.nav-dropdown::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 0.75rem;
}

.nav-subj-item {
    display: grid;
    grid-template-columns: 10px 1fr;
    grid-template-rows: auto auto;
    column-gap: 0.75rem;
    row-gap: 0;
    padding: 0.6rem 0.8rem;
    border-radius: 0.5rem;
    text-decoration: none;
    transition: background 0.12s;
}

.nav-subj-item:hover {
    background: #f8fafc;
}

.nav-subj-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    grid-row: 1 / 3;
    align-self: center;
}

.nav-subj-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.3;
}

.nav-subj-desc {
    font-size: 0.75rem;
    color: #94a3b8;
    line-height: 1.3;
}

/* Legacy: keep .public-nav working for pages not yet migrated */
.public-nav {
    display: none;
}

/* ============================================
   HOME PAGE: HERO
   ============================================ */

.section {
    padding: 4rem 2rem;
    max-width: 1100px;
    margin: 0 auto;
}

.section-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--bb-text);
    margin-bottom: 0.5rem;
    text-align: center;
    letter-spacing: -0.01em;
}

.section-subtitle {
    text-align: center;
    color: var(--bb-text-muted);
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
}

/* ============================================
   FOOTER
   ============================================ */

.public-footer {
    background: #f8fafc;
    border-top: 1px solid var(--bb-border);
    padding: 2.5rem 2rem;
}

.footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    text-align: center;
}

.footer-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    font-weight: 600;
    color: var(--bb-text-muted);
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.footer-links a {
    color: var(--bb-text-muted);
    text-decoration: none;
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--bb-primary);
}

.public-footer small {
    color: #94a3b8;
    font-size: 0.85rem;
}

/* ============================================
   APP: SUBJECT CARDS (dashboard)
   ============================================ */

.subject-card {
    text-align: center;
}

.subject-card header {
    padding-bottom: 0.5rem;
}

/* ============================================
   APP: TOPIC LIST
   ============================================ */

/* Legacy mastery classes (used by progress page) */
.mastery-green { background: var(--bb-green); }
.mastery-amber { background: var(--bb-amber); }
.mastery-red { background: var(--bb-red); }

/* ============================================
   APP: CHAT
   ============================================ */

.chat-container {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 110px);
    min-height: 400px;
}

.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0;
}

.chat-header h2 {
    margin: 0;
    font-size: .95rem;
    font-weight: 600;
    color: #cbd5e1;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: .5rem 0;
}

.message {
    margin-bottom: .8rem;
    display: flex;
}

.message.user {
    justify-content: flex-end;
}

.message-content {
    max-width: 80%;
    padding: 0.6rem 1rem;
    border-radius: 1rem;
    line-height: 1.6;
    white-space: pre-wrap;
    word-wrap: break-word;
    font-size: .92rem;
}

.message.user .message-content {
    background: var(--bb-primary);
    color: white;
    border-bottom-right-radius: 0.25rem;
}

.message.assistant .message-content {
    background: transparent;
    color: #1e293b;
    padding-left: 0;
    white-space: normal;
}

/* Markdown content inside assistant messages */
.message.assistant .message-content h2,
.message.assistant .message-content h3,
.message.assistant .message-content h4 {
    font-size: .95rem;
    font-weight: 700;
    margin: .8rem 0 .3rem;
    color: #1e293b;
}
.message.assistant .message-content h2:first-child,
.message.assistant .message-content h3:first-child,
.message.assistant .message-content h4:first-child {
    margin-top: 0;
}
.message.assistant .message-content p {
    margin: 0 0 .5rem;
}
.message.assistant .message-content p:last-child {
    margin-bottom: 0;
}
.message.assistant .message-content ul,
.message.assistant .message-content ol {
    margin: .3rem 0 .5rem;
    padding-left: 1.4rem;
}
.message.assistant .message-content li {
    margin-bottom: .2rem;
}
.message.assistant .message-content code {
    background: #f1f5f9;
    padding: .1rem .3rem;
    border-radius: 4px;
    font-size: .85em;
}
.message.assistant .message-content pre {
    background: #f1f5f9;
    padding: .6rem .8rem;
    border-radius: 8px;
    overflow-x: auto;
    margin: .5rem 0;
}
.message.assistant .message-content pre code {
    background: none;
    padding: 0;
}

.message-content.error {
    background: #fef2f2;
    color: var(--bb-red);
}

.chat-input {
    display: flex;
    gap: 0.5rem;
    align-items: flex-end;
}

.chat-input textarea {
    flex: 1;
    resize: none;
    margin-bottom: 0;
    border: none;
    border-top: 1px solid #f1f5f9;
    border-radius: 0;
    padding: .7rem .2rem;
    font-size: .9rem;
    background: transparent;
}

.chat-input textarea:focus {
    outline: none;
    border-top-color: #e2e8f0;
}

.chat-input button[type="submit"] {
    margin-bottom: 0;
    width: auto;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: .82rem;
    font-weight: 600;
    background: #4f6bed;
    color: white;
    border: none;
}

/* Thinking indicator (loading bell) */
.thinking-indicator {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .2rem 0;
}
.thinking-bell {
    animation: bell-swing 1s ease-in-out infinite;
    transform-origin: 50% 4px;
}
@keyframes bell-swing {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(15deg); }
    75% { transform: rotate(-15deg); }
}
.thinking-dots {
    display: inline-flex;
    gap: 1px;
    color: #94a3b8;
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1;
}
.thinking-dots span {
    animation: dot-bounce .6s ease-in-out infinite;
}
.thinking-dots span:nth-child(2) { animation-delay: .15s; }
.thinking-dots span:nth-child(3) { animation-delay: .3s; }
@keyframes dot-bounce {
    0%, 80%, 100% { opacity: .25; transform: translateY(0); }
    40% { opacity: 1; transform: translateY(-3px); }
}

/* ============================================
   APP: QUIZ
   ============================================ */

.quiz-container fieldset {
    margin-bottom: 1rem;
}

.quiz-result-item {
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    border-radius: 0.5rem;
}

.quiz-result-item.correct {
    background: #f0fdf4;
    border-left: 4px solid var(--bb-green);
}

.quiz-result-item.incorrect {
    background: #fef2f2;
    border-left: 4px solid var(--bb-red);
}

/* ============================================
   APP: PROGRESS PAGE
   ============================================ */

.stats-overview {
    text-align: center;
}

.stat-box {
    padding: 1rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--bb-primary);
}

.stat-label {
    font-size: 0.9rem;
    color: #64748b;
}

.mastery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 0.5rem;
}

.mastery-cell {
    padding: 0.5rem;
    border-radius: 0.5rem;
    text-align: center;
    color: white;
    font-size: 0.8rem;
    font-weight: 600;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ============================================
   APP: XP BAR
   ============================================ */

.xp-bar-container {
    position: relative;
    height: 24px;
    background: #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
}

.xp-bar-fill {
    height: 100%;
    background: var(--bb-primary);
    border-radius: 12px;
    transition: width 0.5s ease;
}

.xp-bar-text {
    position: absolute;
    width: 100%;
    text-align: center;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.75rem;
    font-weight: 600;
}

/* ============================================
   HTMX
   ============================================ */

.htmx-indicator {
    display: none;
    color: #64748b;
    font-style: italic;
}

.htmx-request .htmx-indicator {
    display: block;
}

/* ============================================
   SUBJECT LANDING PAGES
   ============================================ */

/* Hero */
.subj-hero {
    text-align: center;
    padding: 4rem 2rem 3rem;
}

.subj-hero-inner {
    max-width: 700px;
    margin: 0 auto;
}

.subj-hero-badge {
    display: inline-block;
    padding: 0.35rem 1rem;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
}

.subj-hero h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
    line-height: 1.1;
}

.subj-hero-tagline {
    font-size: 1.15rem;
    color: var(--bb-text-muted);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.subj-hero-stats {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.subj-stat {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--bb-text-muted);
    padding: 0.3rem 0.75rem;
    background: rgba(255,255,255,0.7);
    border-radius: 999px;
}

/* Sections */
.subj-section {
    padding: 3.5rem 2rem;
}

.subj-container {
    max-width: 900px;
    margin: 0 auto;
}

.subj-section h2 {
    text-align: center;
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--bb-text);
    margin-bottom: 1rem;
}

.subj-description {
    max-width: 700px;
    margin: 0 auto 2rem;
    text-align: center;
    font-size: 1.05rem;
    color: var(--bb-text-muted);
    line-height: 1.7;
}

/* Real world examples */
.real-world-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.rw-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: white;
    border-radius: 0.75rem;
    padding: 1rem 1.25rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    font-size: 0.95rem;
    color: #334155;
    line-height: 1.5;
}

/* Fun facts */
.facts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
}

.fact-card {
    background: rgba(255,255,255,0.6);
    border-radius: 1rem;
    padding: 1.5rem;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255,255,255,0.8);
    transition: transform 0.2s;
}

.fact-card:hover {
    transform: translateY(-3px);
}

.fact-icon {
    margin-bottom: 0.5rem;
}

.fact-card p {
    font-size: 0.95rem;
    color: #334155;
    line-height: 1.6;
    margin: 0;
}

/* Units overview */
.units-grid {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.unit-card {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    background: white;
    border-radius: 0.75rem;
    padding: 1.25rem 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    transition: transform 0.15s, box-shadow 0.15s;
}

.unit-card:hover {
    transform: translateX(4px);
    box-shadow: 0 4px 14px rgba(0,0,0,0.08);
}

.unit-number {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    color: white;
    font-size: 0.95rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.unit-info h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--bb-text);
    margin-bottom: 0.15rem;
}

.unit-info p {
    font-size: 0.9rem;
    color: var(--bb-text-muted);
    line-height: 1.5;
    margin: 0;
}

/* How Bluebell helps */
.help-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
}

.help-card {
    background: white;
    border-radius: 0.75rem;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    transition: transform 0.2s;
}

.help-card:hover {
    transform: translateY(-3px);
}

.help-card svg {
    margin-bottom: 0.75rem;
}

.help-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--bb-text);
    margin-bottom: 0.35rem;
}

.help-card p {
    font-size: 0.9rem;
    color: var(--bb-text-muted);
    line-height: 1.5;
    margin: 0;
}

/* CTA */
.subj-cta {
    padding: 4rem 2rem;
    text-align: center;
}

.subj-cta-inner {
    max-width: 600px;
    margin: 0 auto;
}

.subj-cta h2 {
    color: white;
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
}

.subj-cta p {
    color: rgba(255,255,255,0.85);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

/* Legacy pills (used in dashboard) */
.concept-pill {
    display: inline-block;
    background: #eef2ff;
    color: var(--bb-primary);
    padding: 0.2rem 0.65rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 500;
    margin: 0.2rem 0.25rem 0.2rem 0;
}

/* ============================================
   ABOUT PAGE
   ============================================ */

.founder-section {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 2.5rem;
    align-items: center;
    max-width: 800px;
    margin: 0 auto;
}

.founder-photo {
    width: 200px;
    height: 200px;
    border-radius: 1rem;
    background: #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
    font-size: 0.9rem;
    overflow: hidden;
    flex-shrink: 0;
}

.founder-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 1rem;
}

.founder-story h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--bb-text);
    margin-bottom: 0.75rem;
}

.founder-story p {
    font-size: 1rem;
    color: #475569;
    line-height: 1.7;
    margin-bottom: 0.75rem;
}

/* ============================================
   JOIN PAGE (LOGIN / SIGNUP)
   ============================================ */

.join-card {
    max-width: 450px;
    margin: 3rem auto;
    background: white;
    border-radius: 1rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    padding: 2rem 2rem 2.5rem;
}

.tab-switcher {
    display: flex;
    border-bottom: 2px solid #e2e8f0;
    margin-bottom: 1.5rem;
}

.tab-switcher button {
    flex: 1;
    background: none;
    border: none;
    padding: 0.75rem 0;
    font-size: 1rem;
    font-weight: 600;
    color: #94a3b8;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    transition: color 0.2s, border-color 0.2s;
}

.tab-switcher button:hover {
    color: #475569;
}

.tab-switcher button.active {
    color: var(--bb-primary);
    border-bottom-color: var(--bb-primary);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* ============================================
   SMALL BUTTON VARIANT
   ============================================ */

.small {
    padding: 0.25rem 0.75rem;
    font-size: 0.85rem;
}

/* ============================================
   MOBILE RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    /* Nav */
    .site-nav {
        flex-wrap: wrap;
        gap: 0.5rem;
        padding: 0.6rem 1rem;
    }

    .site-nav .nav-links {
        order: 3;
        width: 100%;
        justify-content: center;
        gap: 0.75rem;
        flex-wrap: wrap;
        font-size: 0.85rem;
    }

    .nav-right {
        gap: 0.5rem;
    }

    .nav-dropdown-panel {
        left: 0;
        transform: translateX(0);
        min-width: 200px;
    }

    /* Hero */
    .hero-section {
        padding: 3rem 1.25rem 2.5rem;
        min-height: auto;
    }

    .hero-content h1 {
        font-size: 2.25rem;
    }

    .hero-content .subtitle {
        font-size: 1.05rem;
    }

    .hero-shapes .shape {
        display: none;
    }

    .hero-mockup {
        max-width: 100%;
    }

    /* Stats bar */
    .stats-bar {
        gap: 1.5rem;
        padding: 1.5rem 1rem;
    }

    .stat-item {
        flex: 1 1 40%;
        min-width: 140px;
    }

    /* Steps */
    .steps-container {
        flex-direction: column;
        align-items: center;
    }

    .step-arrow {
        transform: rotate(90deg);
        padding: 0;
    }

    .step {
        max-width: 100%;
    }

    /* Features */
    .features-grid-v2 {
        grid-template-columns: 1fr;
    }

    /* Subject cards */
    .subject-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    /* Why section */
    .why-grid {
        grid-template-columns: 1fr;
    }

    /* Final CTA */
    .final-cta {
        padding: 3rem 1.5rem;
    }

    .final-cta h2 {
        font-size: 1.75rem;
    }

    /* App chat */
    .chat-container {
        height: calc(100vh - 100px);
    }

    .message-content {
        max-width: 90%;
    }

    .mastery-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }

    nav ul {
        gap: 0.25rem;
    }

    .xp-badge, .streak-badge {
        font-size: 0.75rem;
        padding: 0.15rem 0.4rem;
    }

    /* Subject landing */
    .subj-hero h1 {
        font-size: 2rem;
    }

    .subj-hero-tagline {
        font-size: 1rem;
    }

    .real-world-grid,
    .facts-grid {
        grid-template-columns: 1fr;
    }

    .help-grid {
        grid-template-columns: 1fr;
    }

    .subj-cta h2 {
        font-size: 1.5rem;
    }

    .founder-section {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .founder-photo {
        margin: 0 auto;
    }

    .join-card {
        margin: 2rem 1rem;
        padding: 1.5rem;
    }

    /* Footer */
    .footer-links {
        flex-wrap: wrap;
        gap: 1rem;
    }
}

@media (max-width: 480px) {
    .subject-cards {
        grid-template-columns: 1fr;
    }

    .hero-content h1 {
        font-size: 1.85rem;
    }

    .stats-bar {
        flex-direction: column;
        gap: 1rem;
    }
}
