/* ==========================================================================
   styles.css - poohpathologytest.net
   Premium Glassmorphic Style Sheet with Dual Themes & RTL Support
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

:root {
    /* Color Palette - Dark Theme (Default) */
    --bg-primary: #05060f;
    --bg-glow: #13102a;
    --bg-secondary: #0c0e1e;
    --text-primary: #f3f4f6;
    --text-secondary: #a0aec0;
    --glass-bg: rgba(12, 14, 30, 0.65);
    --glass-border: rgba(255, 255, 255, 0.07);
    --accent-gradient: linear-gradient(135deg, #7c3aed 0%, #3b82f6 100%);
    --accent-glow: rgba(124, 58, 237, 0.3);
    --shadow-main: 0 20px 45px rgba(0, 0, 0, 0.5);
    --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    --border-radius-lg: 24px;
    --border-radius-md: 16px;
    --border-radius-sm: 8px;

    /* Character Colors */
    --color-winnie: #f59e0b;       /* ADD - Amber Gold */
    --color-piglet: #ec4899;       /* Anxiety - Soft Rose */
    --color-tigger: #ff6b00;       /* ADHD - Fire Orange */
    --color-eeyore: #3a86ff;       /* Depression - Slate Blue */
    --color-rabbit: #10b981;       /* OCD - Emerald Green */
    --color-christopher: #8b5cf6;  /* Dissociation - Imaginative Violet */
}

/* Light Theme Variables */
:root.light {
    --bg-primary: #f3f4f8;
    --bg-glow: #e2e1f5;
    --bg-secondary: #ffffff;
    --text-primary: #1f2937;
    --text-secondary: #4b5563;
    --glass-bg: rgba(255, 255, 255, 0.75);
    --glass-border: rgba(0, 0, 0, 0.05);
    --accent-gradient: linear-gradient(135deg, #6d28d9 0%, #2563eb 100%);
    --accent-glow: rgba(109, 40, 217, 0.12);
    --shadow-main: 0 20px 40px rgba(31, 41, 55, 0.05);
    --card-shadow: 0 10px 30px rgba(31, 41, 55, 0.03);
}

/* Reset and Global Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}

body {
    font-family: 'Inter', sans-serif;
    background: radial-gradient(circle at 80% 20%, var(--bg-glow) 0%, var(--bg-primary) 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
}

/* Header & Navigation */
header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-block {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    text-decoration: none;
}

.logo-img {
    height: 42px;
    width: auto;
    filter: drop-shadow(0 0 8px rgba(124, 58, 237, 0.6));
}

.logo-title {
    font-size: 1.35rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.5px;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.nav-menu {
    display: flex;
    gap: 1.5rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 500;
    padding: 0.5rem 0.75rem;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
}

.nav-link:hover, .nav-link.active {
    color: var(--text-primary);
    background: var(--glass-border);
}

/* Controls */
.lang-selector-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-sm);
    padding: 0.25rem 0.5rem;
}

.lang-select {
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.85rem;
    cursor: pointer;
    outline: none;
    padding-right: 0.5rem;
}

.theme-toggle-btn {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--card-shadow);
}

.theme-toggle-btn:hover {
    background: var(--glass-border);
    transform: scale(1.05);
}

/* Icons */
.theme-toggle-btn svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* Body / Core Layout */
main {
    flex: 1;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 3rem 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Glass panel */
.glass-panel {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-main);
    padding: 2.5rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

/* Intro Section */
.hero-card {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.hero-tagline {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -1px;
    margin-bottom: 0.5rem;
}

.hero-desc {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 600px;
}

.expert-tag {
    background: var(--accent-gradient);
    font-size: 0.85rem;
    font-weight: 600;
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 15px var(--accent-glow);
}

/* Button UI */
.btn-primary {
    background: var(--accent-gradient);
    color: #fff;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    border-radius: var(--border-radius-md);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    box-shadow: 0 8px 25px var(--accent-glow);
    text-decoration: none;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px var(--accent-glow);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--glass-border);
    padding: 0.85rem 1.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    font-family: 'Outfit', sans-serif;
    border-radius: var(--border-radius-md);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-secondary:hover {
    background: var(--glass-border);
}

/* Quiz Section */
.quiz-container {
    max-width: 750px;
    margin: 0 auto;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    font-weight: 600;
    font-size: 0.95rem;
}

.progress-bar-bg {
    width: 100%;
    height: 8px;
    background: var(--glass-border);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 2.5rem;
}

.progress-bar-filler {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 10px;
    width: 0%;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.question-card {
    min-height: 120px;
    margin-bottom: 2.5rem;
    text-align: center;
}

.question-text {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.4;
    font-family: 'Outfit', sans-serif;
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.options-stack {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    margin-bottom: 2.5rem;
}

.option-btn {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    padding: 1.1rem 1.5rem;
    border-radius: var(--border-radius-md);
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    text-align: left;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: var(--card-shadow);
}

.option-btn:hover {
    background: var(--glass-border);
    border-color: var(--text-secondary);
}

.option-btn.active {
    background: var(--accent-gradient);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 4px 15px var(--accent-glow);
}

.option-btn::after {
    content: '○';
    font-size: 1.2rem;
    opacity: 0.5;
}

.option-btn.active::after {
    content: '●';
    opacity: 1;
}

.quiz-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Results Panel */
.results-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
    margin-bottom: 3rem;
}

/* ============================================================
   HAMBURGER MENU (Mobile Nav Toggle)
   ============================================================ */
.hamburger-btn {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 28px;
    height: 20px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 200;
}

.hamburger-btn span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s ease;
    transform-origin: center;
}

.hamburger-btn.open span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}
.hamburger-btn.open span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}
.hamburger-btn.open span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* Mobile overlay nav */
.mobile-nav-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(5, 6, 15, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 150;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    padding: 2rem;
}

.mobile-nav-overlay.open {
    display: flex;
}

.mobile-nav-overlay .nav-link {
    font-size: 1.75rem;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    color: var(--text-primary);
    padding: 0.75rem 2rem;
    border-radius: var(--border-radius-md);
    text-align: center;
    width: 100%;
    max-width: 280px;
    border: 1px solid var(--glass-border);
    background: var(--glass-bg);
}

.mobile-nav-overlay .nav-link.active {
    background: var(--accent-gradient);
    color: #fff;
    border-color: transparent;
}

.mobile-nav-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
}

.primary-match-card {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.result-badge {
    background: var(--glass-border);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 0.4rem 0.85rem;
    border-radius: 50px;
    letter-spacing: 1px;
}

.character-image-holder {
    position: relative;
    width: 100%;
    max-width: 320px;
    height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.results-character-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-main);
    border: 1px solid var(--glass-border);
}

.results-svg-fallback {
    width: 100%;
    height: 100%;
    border-radius: var(--border-radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.fallback-emoji-large {
    font-size: 8rem;
    z-index: 2;
    filter: drop-shadow(0 10px 15px rgba(0,0,0,0.3));
}

.glow-orb {
    position: absolute;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    z-index: 1;
}

.match-name {
    font-size: 2.25rem;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.match-description {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 1.05rem;
}

/* Diagnostic Bars */
.axis-progress-item {
    margin-bottom: 1.25rem;
}

.axis-progress-info {
    display: flex;
    justify-content: space-between;
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.axis-progress-bar-bg {
    height: 12px;
    background: var(--glass-border);
    border-radius: 50px;
    overflow: hidden;
}

.axis-progress-bar-fill {
    height: 100%;
    border-radius: 50px;
    transition: width 1s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Spectrum advice card grid */
.advice-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.advice-spectrum-card {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    padding: 1.5rem;
    border-radius: var(--border-radius-md);
}

.spectrum-badge {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    text-transform: uppercase;
}

/* Psychologist block */
.psychologist-block {
    display: flex;
    gap: 2rem;
    align-items: center;
    border-top: 1px solid var(--glass-border);
    padding-top: 2rem;
    margin-top: 3rem;
}

/* Psychologist block responsive handled in main media queries */

.psychologist-avatar {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f59e0b 0%, #ec4899 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.75rem;
    flex-shrink: 0;
    border: 3px solid var(--glass-bg);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.psychologist-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.psychologist-text {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.results-sharing {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-top: 3rem;
    border-top: 1px solid var(--glass-border);
    padding-top: 2rem;
}

.share-buttons {
    display: flex;
    gap: 0.75rem;
}

.share-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--card-shadow);
}

.share-btn:hover {
    transform: translateY(-2px);
}

.share-btn.whatsapp { background-color: #25d366; }
.share-btn.facebook { background-color: #1877f2; }
.share-btn.twitter { background-color: #1da1f2; }

/* Characters Section Under main list */
.section-title {
    font-size: 2rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 2.5rem;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.characters-details-section {
    margin-top: 4rem;
}

.characters-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

/* Characters grid responsive handled in main media queries */

.character-info-card {
    display: flex;
    gap: 1.5rem;
    align-items: start;
    padding: 1.75rem;
}

.character-card-img {
    width: 100px;
    height: 100px;
    border-radius: var(--border-radius-md);
    object-fit: cover;
    border: 1px solid var(--glass-border);
}

.character-card-svg-fallback {
    width: 100px;
    height: 100px;
    border-radius: var(--border-radius-md);
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.fallback-emoji {
    font-size: 3rem;
}

.character-card-details h4 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.character-desc {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
}

.character-advice {
    font-size: 0.85rem;
    background: var(--bg-primary);
    border: 1px solid var(--glass-border);
    padding: 0.75rem;
    border-radius: var(--border-radius-sm);
}

/* Footer layout */
footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--glass-border);
    padding: 4rem 2rem 2rem 2rem;
    margin-top: 4rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

/* Footer responsive handled in main media queries */

.footer-column h4 {
    font-size: 1.15rem;
    margin-bottom: 1.25rem;
    color: var(--text-primary);
    position: relative;
    padding-bottom: 0.5rem;
}

.footer-column h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--accent-gradient);
    border-radius: 5px;
}

body.rtl-layout .footer-column h4::after {
    left: auto;
    right: 0;
}

.footer-column p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-disclaimer-text {
    font-style: italic;
    font-weight: 500;
    margin-top: 1rem;
    color: var(--text-secondary);
    display: block;
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

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

.footer-links a:hover {
    color: var(--text-primary);
    text-decoration: underline;
}

.social-links-grid {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.social-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: var(--card-shadow);
}

.social-btn:hover {
    background: var(--accent-gradient);
    color: #fff;
    border-color: transparent;
    transform: translateY(-2px);
}

.social-btn svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    border-top: 1px solid var(--glass-border);
    padding-top: 2rem;
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

/* Animations */
.animate-fade-in {
    animation: fadeIn 0.4s ease-out forwards;
}

.animate-float {
    animation: float 4s ease-in-out infinite;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

/* Right-To-Left (RTL) Arabic styles overrides */
body.rtl-layout {
    text-align: right;
}

body.rtl-layout .option-btn {
    text-align: right;
    flex-direction: row-reverse;
}

body.rtl-layout .option-btn::after {
    content: '○';
}

body.rtl-layout .option-btn.active::after {
    content: '●';
}

body.rtl-layout .character-info-card {
    border-left: none !important;
    border-right: 6px solid var(--color); /* Computed dynamically or bound in layout */
}

body.rtl-layout .advice-spectrum-card {
    border-left: none !important;
    border-right: 5px solid var(--color); /* Done inline in JS dynamically */
}

/* ==========================================================================
   COMPREHENSIVE RESPONSIVE DESIGN
   Breakpoints:
   - 1100px : Large tablet / small laptop
   - 900px  : Tablet portrait
   - 768px  : Mobile landscape / small tablet
   - 600px  : Mobile portrait
   - 420px  : Small phones (iPhone SE etc.)
   ========================================================================== */

/* --- 1100px: Large Tablet / Small Laptop --- */
@media (max-width: 1100px) {
    .header-container {
        padding: 0.9rem 1.5rem;
    }

    main {
        padding: 2.5rem 1.5rem;
    }

    .footer-container {
        gap: 2rem;
        padding: 0 1rem;
    }

    .hero-tagline {
        font-size: 2.2rem;
    }

    .section-title {
        font-size: 1.85rem;
    }
}

/* --- 900px: Tablet Portrait --- */
@media (max-width: 900px) {
    .results-grid {
        grid-template-columns: 1fr;
    }

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

    .hero-tagline {
        font-size: 1.95rem;
        letter-spacing: -0.5px;
    }

    .hero-desc {
        font-size: 1rem;
    }

    .about-list {
        grid-template-columns: 1fr 1fr;
    }

    .glass-panel {
        padding: 2rem;
    }

    .character-info-card {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .character-card-img,
    .character-card-svg-fallback {
        width: 80px;
        height: 80px;
    }

    .match-name {
        font-size: 1.9rem;
    }

    .psychologist-block {
        flex-direction: column;
        text-align: center;
    }

    .results-sharing {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.25rem;
    }
}

/* --- 768px: Mobile Landscape / Small Tablet --- */
@media (max-width: 768px) {
    /* Show hamburger, hide desktop nav */
    .hamburger-btn {
        display: flex;
    }

    .nav-menu {
        display: none;
    }

    .header-container {
        padding: 0.85rem 1.2rem;
    }

    .logo-title {
        font-size: 1.1rem;
    }

    .logo-img {
        height: 34px;
    }

    main {
        padding: 2rem 1rem;
        gap: 2rem;
    }

    .hero-tagline {
        font-size: 1.65rem;
        letter-spacing: -0.3px;
    }

    .hero-desc {
        font-size: 0.95rem;
    }

    .btn-primary {
        font-size: 1rem;
        padding: 0.9rem 1.6rem;
        width: 100%;
        justify-content: center;
    }

    .btn-secondary {
        font-size: 0.9rem;
        padding: 0.8rem 1.25rem;
    }

    .quiz-container {
        max-width: 100%;
    }

    .question-text {
        font-size: 1.25rem;
    }

    .option-btn {
        padding: 0.95rem 1.2rem;
        font-size: 0.95rem;
        min-height: 52px; /* Touch-friendly */
    }

    .quiz-controls {
        flex-direction: column;
        gap: 0.85rem;
    }

    .quiz-controls .btn-primary,
    .quiz-controls .btn-secondary {
        width: 100%;
        justify-content: center;
    }

    .section-title {
        font-size: 1.65rem;
        margin-bottom: 1.75rem;
    }

    .match-name {
        font-size: 1.6rem;
    }

    .footer-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    footer {
        padding: 3rem 1.25rem 1.5rem;
    }

    .about-list {
        grid-template-columns: 1fr;
    }

    .about-hero h2 {
        font-size: 1.9rem;
    }

    .share-buttons {
        flex-wrap: wrap;
    }

    .psychologist-avatar {
        width: 75px;
        height: 75px;
        font-size: 2.25rem;
    }

    .faq-question {
        font-size: 1rem;
        padding: 1.1rem 1.25rem;
    }

    .faq-answer {
        padding: 0 1.25rem;
    }

    .faq-item.active .faq-answer {
        padding: 0.5rem 1.25rem 1.25rem;
    }

    .character-image-holder {
        max-width: 260px;
        height: 260px;
    }

    .glass-panel {
        padding: 1.5rem;
    }

    .results-sharing {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .results-sharing > div {
        justify-content: center;
    }
}

/* --- 600px: Mobile Portrait --- */
@media (max-width: 600px) {
    body {
        font-size: 0.95rem;
    }

    .header-container {
        padding: 0.75rem 1rem;
    }

    .logo-title {
        font-size: 1rem;
        letter-spacing: -0.3px;
    }

    .logo-img {
        height: 30px;
    }

    .lang-selector-wrapper {
        padding: 0.2rem 0.4rem;
    }

    .lang-select {
        font-size: 0.78rem;
    }

    main {
        padding: 1.5rem 0.85rem;
    }

    .glass-panel {
        border-radius: var(--border-radius-md);
        padding: 1.25rem;
    }

    .hero-tagline {
        font-size: 1.45rem;
        letter-spacing: 0;
    }

    .expert-tag {
        font-size: 0.78rem;
        padding: 0.4rem 0.85rem;
    }

    .hero-desc {
        font-size: 0.9rem;
    }

    .question-text {
        font-size: 1.1rem;
        line-height: 1.5;
    }

    .question-card {
        min-height: 90px;
        margin-bottom: 1.75rem;
    }

    .option-btn {
        font-size: 0.9rem;
        padding: 0.9rem 1rem;
        border-radius: var(--border-radius-sm);
    }

    .options-stack {
        gap: 0.7rem;
        margin-bottom: 1.75rem;
    }

    .progress-header {
        font-size: 0.85rem;
    }

    .section-title {
        font-size: 1.45rem;
        margin-bottom: 1.35rem;
    }

    .match-name {
        font-size: 1.4rem;
    }

    .match-description {
        font-size: 0.95rem;
    }

    .character-image-holder {
        max-width: 220px;
        height: 220px;
    }

    .character-info-card {
        padding: 1.25rem;
        gap: 0.85rem;
    }

    .character-card-img,
    .character-card-svg-fallback {
        width: 68px;
        height: 68px;
    }

    .character-card-details h4 {
        font-size: 1.1rem;
    }

    .psychologist-block {
        gap: 1.25rem;
        padding-top: 1.5rem;
    }

    .psychologist-title {
        font-size: 1.1rem;
    }

    .psychologist-text {
        font-size: 0.88rem;
    }

    .axis-progress-info {
        font-size: 0.85rem;
    }

    .footer-bottom {
        font-size: 0.78rem;
        padding-top: 1.5rem;
    }

    .social-btn {
        width: 38px;
        height: 38px;
    }

    .social-btn svg {
        width: 16px;
        height: 16px;
    }

    .about-hero h2 {
        font-size: 1.6rem;
    }

    .about-content-section h3 {
        font-size: 1.3rem;
    }

    .faq-section {
        margin-top: 3rem;
    }

    .fallback-emoji-large {
        font-size: 6rem;
    }
}

/* --- 420px: Small Phones (iPhone SE, Galaxy A series) --- */
@media (max-width: 420px) {
    .logo-title {
        display: none; /* Show only icon on very small screens */
    }

    .hero-tagline {
        font-size: 1.3rem;
    }

    .hero-desc {
        font-size: 0.85rem;
    }

    .btn-primary {
        font-size: 0.95rem;
        padding: 0.85rem 1.25rem;
    }

    .option-btn {
        font-size: 0.85rem;
        padding: 0.85rem 0.9rem;
    }

    .section-title {
        font-size: 1.3rem;
    }

    .match-name {
        font-size: 1.3rem;
    }

    .character-image-holder {
        max-width: 190px;
        height: 190px;
    }

    .glass-panel {
        padding: 1rem;
    }

    .radarChartContainer {
        width: 100% !important;
        height: 280px !important;
    }

    footer {
        padding: 2.5rem 1rem 1rem;
    }
}

/* ==========================================================================
   PRINT MEDIA - Premium Clinical Report Download
   ========================================================================== */
@media print {
    body {
        background-color: #fff !important;
        color: #000 !important;
    }

    header, footer, .theme-toggle-btn, .lang-selector-wrapper,
    .btn-secondary, .results-sharing, .nav-menu,
    .hamburger-btn, .mobile-nav-overlay {
        display: none !important;
    }

    main {
        padding: 0 !important;
        max-width: 100% !important;
    }

    .glass-panel {
        background: transparent !important;
        border: none !important;
        box-shadow: none !important;
        padding: 0 !important;
    }

    .results-grid {
        grid-template-columns: 1fr !important;
        gap: 1.5in !important;
        page-break-after: always;
    }

    .character-image-holder {
        max-width: 200px !important;
        height: 200px !important;
    }

    .results-character-image {
        box-shadow: none !important;
        border: 2px solid #000 !important;
    }

    .axis-progress-bar-bg {
        border: 1px solid #000 !important;
        background: #eee !important;
    }

    .axis-progress-bar-fill {
        background-color: #333 !important;
    }
}

/* FAQ Section Styles */
.faq-section {
    margin-top: 4.5rem;
}

.faq-accordion {
    display: flex;
    flex-direction: column;
    gap: 1.15rem;
    margin-top: 2rem;
}

.faq-item {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-md);
    overflow: hidden;
    box-shadow: var(--card-shadow);
}

.faq-question {
    padding: 1.35rem 1.85rem;
    font-weight: 700;
    font-size: 1.1rem;
    font-family: 'Outfit', sans-serif;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
    background: transparent;
    border: none;
    width: 100%;
    text-align: inherit;
    color: var(--text-primary);
    outline: none;
}

.faq-question:hover {
    background: var(--glass-border);
}

.faq-answer {
    padding: 0 1.85rem;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0, 1, 0, 1), padding 0.3s ease;
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.65;
}

.faq-item.active .faq-answer {
    padding: 0.5rem 1.85rem 1.5rem 1.85rem;
    max-height: 500px;
    transition: max-height 0.5s ease-in, padding 0.3s ease;
}

.faq-icon {
    font-size: 1.25rem;
    transition: transform 0.3s ease;
    font-weight: 400;
    opacity: 0.7;
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
    opacity: 1;
}

/* About Page Specific Styles */
.about-hero {
    text-align: left;
    margin-bottom: 2.5rem;
}

.about-hero h2 {
    font-size: 2.35rem;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1rem;
    font-family: 'Outfit', sans-serif;
}

.about-content-section {
    margin-bottom: 3rem;
}

.about-content-section h3 {
    font-size: 1.55rem;
    margin-bottom: 1.15rem;
    color: var(--text-primary);
    border-bottom: 1.5px solid var(--glass-border);
    padding-bottom: 0.5rem;
}

.about-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.about-list-item {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    padding: 1.65rem;
    border-radius: var(--border-radius-md);
    box-shadow: var(--card-shadow);
}

.about-list-item h4 {
    font-size: 1.2rem;
    margin-bottom: 0.50rem;
    color: var(--text-primary);
}
