/* ============================================
   PULS ZDRAVLJA AI — LIGHT THEME
   ============================================ */

:root {
    /* Navy / Teal palette */
    --navy: #1a2b4a;
    --navy-light: #2a3f66;
    --teal: #2d8a8a;
    --teal-muted: #3a9e9e;
    --cyan: #5ec4c4;
    --cyan-soft: #a8e0e0;

    /* Neutrals */
    --bg: #fafbfc;
    --bg-warm: #f5f6f8;
    --bg-card: #ffffff;
    --bg-elevated: #ffffff;
    --border: #e8ecf0;
    --border-light: #f0f2f5;

    /* Text */
    --text: #1a2b4a;
    --text-secondary: #5a6a7e;
    --text-muted: #8a96a6;

    /* Accent */
    --accent: #2d8a8a;
    --accent-hover: #247575;
    --accent-bg: #e8f5f5;

    /* Status */
    --success: #2d8a5e;
    --warning: #c47a20;
    --error: #c44040;

    /* Sizing */
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 16px;
    --radius-xl: 24px;

    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(26,43,74,0.06);
    --shadow: 0 2px 8px rgba(26,43,74,0.08);
    --shadow-lg: 0 8px 24px rgba(26,43,74,0.1);
    --shadow-xl: 0 16px 48px rgba(26,43,74,0.12);

    /* Transitions */
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main { flex: 1; }
img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; transition: color 0.2s var(--ease); }
a:hover { color: var(--accent-hover); }

.container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ============================================
   TYPOGRAPHY
   ============================================ */
h1, h2, h3, h4 { font-weight: 600; line-height: 1.25; color: var(--navy); }
h1 { font-size: clamp(2rem, 5vw, 3rem); letter-spacing: -0.03em; }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.25rem); letter-spacing: -0.02em; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1rem; }
p { color: var(--text-secondary); }

.section-label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--teal);
    margin-bottom: 8px;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 0.9375rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s var(--ease);
    text-decoration: none;
    line-height: 1.4;
}

.btn-primary {
    background: var(--navy);
    color: #fff;
}
.btn-primary:hover { background: var(--navy-light); color: #fff; transform: translateY(-1px); box-shadow: var(--shadow); }

.btn-accent {
    background: var(--accent);
    color: #fff;
}
.btn-accent:hover { background: var(--accent-hover); color: #fff; transform: translateY(-1px); }

.btn-ghost {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border);
}
.btn-ghost:hover { border-color: var(--navy); color: var(--navy); }

.btn-sm { padding: 8px 16px; font-size: 0.875rem; }
.btn-lg { padding: 16px 32px; font-size: 1.0625rem; }
.btn-block { width: 100%; justify-content: center; }

/* ============================================
   NAVIGATION
   ============================================ */
.nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(250,251,252,0.92);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-light);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--navy);
    font-weight: 600;
    font-size: 1.0625rem;
}

.nav-logo:hover { color: var(--navy); }

.logo-icon svg { width: 28px; height: 28px; }
.logo-ai { color: var(--teal); font-weight: 700; }

.nav-links {
    display: flex;
    align-items: center;
    gap: 28px;
}

.nav-links a {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    font-weight: 450;
    transition: color 0.2s;
}
.nav-links a:hover { color: var(--navy); }

.nav-toggle { display: none; background: none; border: none; cursor: pointer; color: var(--text); }
.nav-toggle svg { width: 24px; height: 24px; }

@media (max-width: 768px) {
    .nav-toggle { display: block; }
    .nav-links {
        display: none;
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        background: var(--bg-card);
        flex-direction: column;
        padding: 24px;
        gap: 16px;
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow-lg);
    }
    .nav-links.open { display: flex; }
}

/* ============================================
   HERO
   ============================================ */
.hero {
    padding: 80px 0 60px;
    text-align: center;
    background: linear-gradient(180deg, var(--bg) 0%, var(--bg-warm) 100%);
}

.hero h1 {
    margin-bottom: 16px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.hero p {
    font-size: 1.125rem;
    max-width: 560px;
    margin: 0 auto 40px;
    color: var(--text-secondary);
}

.hero-search {
    max-width: 520px;
    margin: 0 auto 48px;
    position: relative;
}

.hero-search input {
    width: 100%;
    padding: 16px 52px 16px 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 1rem;
    font-family: inherit;
    background: var(--bg-card);
    color: var(--text);
    box-shadow: var(--shadow);
    transition: all 0.2s var(--ease);
}

.hero-search input:focus {
    outline: none;
    border-color: var(--teal);
    box-shadow: var(--shadow), 0 0 0 3px var(--accent-bg);
}

.hero-search input::placeholder { color: var(--text-muted); }

.hero-search button {
    position: absolute;
    right: 6px;
    top: 6px;
    bottom: 6px;
    width: 42px;
    border: none;
    background: var(--navy);
    color: #fff;
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}
.hero-search button:hover { background: var(--navy-light); }
.hero-search button svg { width: 18px; height: 18px; }

/* ============================================
   BODY SYSTEMS GRID
   ============================================ */
.systems-section { padding: 60px 0 80px; }
.systems-section h2 { text-align: center; margin-bottom: 12px; }
.systems-section > .container > p { text-align: center; margin-bottom: 48px; }

.systems-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
}

.system-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    transition: all 0.25s var(--ease);
    cursor: pointer;
    text-decoration: none;
    display: block;
}

.system-card:hover {
    border-color: var(--teal);
    box-shadow: var(--shadow);
    transform: translateY(-2px);
}

.system-card .system-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 14px;
    color: var(--teal);
}

.system-card .system-icon svg { width: 100%; height: 100%; }

.system-card h3 {
    font-size: 0.9375rem;
    font-weight: 550;
    color: var(--navy);
}

/* ============================================
   BODY MAP
   ============================================ */
.body-map-section { padding: 60px 0; }

.body-map-container {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 40px;
    align-items: start;
}

.body-svg {
    position: relative;
    max-width: 300px;
    margin: 0 auto;
}

.body-svg svg { width: 100%; height: auto; }

.body-zone {
    cursor: pointer;
    fill: var(--cyan-soft);
    stroke: var(--teal);
    stroke-width: 1;
    transition: all 0.2s;
    opacity: 0.7;
}
.body-zone:hover, .body-zone.active {
    fill: var(--teal);
    opacity: 1;
}

.body-info-panel {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    min-height: 300px;
}

@media (max-width: 768px) {
    .body-map-container {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   TOOLS
   ============================================ */
.tools-section { padding: 60px 0 80px; }

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.tool-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    transition: all 0.25s var(--ease);
    display: flex;
    flex-direction: column;
    text-decoration: none;
}

.tool-card:hover {
    border-color: var(--teal);
    box-shadow: var(--shadow);
    transform: translateY(-2px);
}

.tool-card .tool-icon {
    width: 40px;
    height: 40px;
    color: var(--teal);
    margin-bottom: 16px;
}

.tool-card .tool-icon svg { width: 100%; height: 100%; }

.tool-card h3 { font-size: 1.0625rem; margin-bottom: 8px; color: var(--navy); }
.tool-card p { font-size: 0.875rem; color: var(--text-secondary); flex: 1; margin-bottom: 16px; }

.tool-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 550;
    background: var(--accent-bg);
    color: var(--teal);
    align-self: flex-start;
}

.tool-badge.pro { background: #fef3e2; color: var(--warning); }
.tool-badge.premium { background: #f0e8f7; color: #7c3aed; }

/* ============================================
   TOOL FORM
   ============================================ */
.tool-page { padding: 48px 0 80px; max-width: 680px; margin: 0 auto; }
.tool-page .container { max-width: 680px; }

.tool-header { margin-bottom: 36px; }
.tool-header h1 { font-size: 1.75rem; margin-bottom: 8px; }
.tool-header p { font-size: 1rem; }

.form-group { margin-bottom: 24px; }

.form-group label {
    display: block;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--navy);
    margin-bottom: 8px;
}

.form-group select,
.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 0.9375rem;
    color: var(--text);
    background: var(--bg-card);
    transition: all 0.2s var(--ease);
}

.form-group select:focus,
.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--teal);
    box-shadow: 0 0 0 3px var(--accent-bg);
}

.form-group textarea { min-height: 100px; resize: vertical; }

.checkbox-group { display: flex; flex-wrap: wrap; gap: 10px; }

.checkbox-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 400;
    font-size: 0.875rem;
    transition: all 0.15s;
    margin-bottom: 0;
}

.checkbox-group label:hover { border-color: var(--teal); }
.checkbox-group input:checked + span { color: var(--teal); }
.checkbox-group label:has(input:checked) { border-color: var(--teal); background: var(--accent-bg); }
.checkbox-group input { display: none; }

.range-input {
    display: flex;
    align-items: center;
    gap: 16px;
}

.range-input input[type="range"] {
    flex: 1;
    accent-color: var(--teal);
    height: 6px;
}

.range-input .range-value {
    width: 40px;
    text-align: center;
    font-weight: 600;
    font-size: 1.125rem;
    color: var(--teal);
}

/* ============================================
   AI OUTPUT
   ============================================ */
.ai-output {
    background: var(--bg-warm);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    margin-top: 32px;
    animation: fadeIn 0.4s var(--ease);
}

.ai-output h3 { margin-bottom: 16px; }
.ai-output p { margin-bottom: 12px; line-height: 1.7; }
.ai-output ul, .ai-output ol { margin: 12px 0; padding-left: 20px; color: var(--text-secondary); }
.ai-output li { margin-bottom: 6px; line-height: 1.6; }
.ai-output strong { color: var(--navy); }

.ai-disclaimer {
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    font-size: 0.8125rem;
    color: var(--text-muted);
    font-style: italic;
}

.loading-indicator {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 24px;
    color: var(--text-muted);
    font-size: 0.9375rem;
}

.loading-dots span {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--teal);
    animation: dot 1.2s infinite;
}
.loading-dots span:nth-child(2) { animation-delay: 0.15s; }
.loading-dots span:nth-child(3) { animation-delay: 0.3s; }

@keyframes dot {
    0%, 80%, 100% { opacity: 0.2; transform: scale(0.8); }
    40% { opacity: 1; transform: scale(1); }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============================================
   PACKAGES
   ============================================ */
.packages-section { padding: 60px 0 80px; }
.packages-section h1, .packages-section h2 { text-align: center; margin-bottom: 12px; }
.packages-section > .container > p { text-align: center; margin-bottom: 48px; }

.packages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    max-width: 960px;
    margin: 0 auto;
}

.package-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    display: flex;
    flex-direction: column;
    transition: all 0.25s var(--ease);
}

.package-card:hover { box-shadow: var(--shadow-lg); }

.package-card.featured {
    border-color: var(--teal);
    box-shadow: var(--shadow);
    position: relative;
}

.package-card.featured::before {
    content: 'Popularan';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--teal);
    color: #fff;
    padding: 4px 16px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 600;
}

.package-card h3 {
    font-size: 1.25rem;
    margin-bottom: 4px;
}

.package-price {
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--navy);
    margin: 16px 0 4px;
    line-height: 1;
}

.package-price span {
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--text-muted);
}

.package-price-note {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.package-features {
    list-style: none;
    padding: 0;
    margin: 0 0 24px;
    flex: 1;
}

.package-features li {
    padding: 8px 0;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.package-features li::before {
    content: '✓';
    color: var(--teal);
    font-weight: 700;
    flex-shrink: 0;
}

/* ============================================
   AUTH
   ============================================ */
.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 200px);
    padding: 48px 24px;
}

.auth-card {
    width: 100%;
    max-width: 420px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: var(--shadow);
}

.auth-card h1 {
    font-size: 1.5rem;
    text-align: center;
    margin-bottom: 8px;
}

.auth-card > p {
    text-align: center;
    margin-bottom: 32px;
    font-size: 0.9375rem;
}

.auth-card .form-group { margin-bottom: 20px; }

/* ============================================
   DASHBOARD
   ============================================ */
.dashboard { padding: 48px 0 80px; }

.dash-header {
    margin-bottom: 40px;
}

.dash-header h1 {
    font-size: 1.75rem;
    margin-bottom: 4px;
}

.dash-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 40px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
}

.stat-card .stat-label {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.stat-card .stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--navy);
}

/* ============================================
   LEGAL PAGES
   ============================================ */
.legal-page {
    padding: 48px 0 80px;
    max-width: 720px;
    margin: 0 auto;
}

.legal-page h1 { font-size: 1.75rem; margin-bottom: 8px; }
.legal-page .legal-date { color: var(--text-muted); font-size: 0.875rem; margin-bottom: 32px; }
.legal-page h2 { font-size: 1.25rem; margin: 32px 0 12px; }
.legal-page p { margin-bottom: 16px; line-height: 1.7; }
.legal-page ul { margin: 12px 0 16px 20px; color: var(--text-secondary); }
.legal-page li { margin-bottom: 6px; line-height: 1.6; }

/* ============================================
   COOKIE CONSENT
   ============================================ */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: var(--bg-card);
    border-top: 1px solid var(--border);
    box-shadow: 0 -4px 24px rgba(26,43,74,0.1);
    animation: slideUp 0.3s var(--ease);
}

.cookie-inner {
    max-width: 1120px;
    margin: 0 auto;
    padding: 20px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.cookie-inner p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin: 0;
    flex: 1;
    min-width: 200px;
}

.cookie-inner a { color: var(--teal); }

.cookie-actions {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

@keyframes slideUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

/* ============================================
   ALERTS
   ============================================ */
.alert {
    padding: 14px 20px;
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
    font-size: 0.9375rem;
}

.alert-success { background: #ecfdf3; color: var(--success); border: 1px solid #a7f3d0; }
.alert-error { background: #fef2f2; color: var(--error); border: 1px solid #fecaca; }
.alert-info { background: var(--accent-bg); color: var(--teal); border: 1px solid var(--cyan-soft); }

/* ============================================
   HOW IT WORKS
   ============================================ */
.how-section { padding: 60px 0 80px; background: var(--bg-warm); }
.how-section h2 { text-align: center; margin-bottom: 48px; }

.how-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 32px;
    max-width: 800px;
    margin: 0 auto;
}

.how-step {
    text-align: center;
}

.how-step .step-num {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--accent-bg);
    color: var(--teal);
    font-weight: 700;
    font-size: 1.125rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.how-step h3 { font-size: 1.0625rem; margin-bottom: 8px; }
.how-step p { font-size: 0.875rem; }

/* ============================================
   CTA SECTION
   ============================================ */
.cta-section {
    padding: 80px 0;
    text-align: center;
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
    color: #fff;
}

.cta-section h2 { color: #fff; margin-bottom: 12px; }
.cta-section p { color: rgba(255,255,255,0.7); margin-bottom: 32px; font-size: 1.125rem; }

/* ============================================
   UTILITY
   ============================================ */
.text-center { text-align: center; }
.mt-2 { margin-top: 16px; }
.mt-4 { margin-top: 32px; }
.mb-2 { margin-bottom: 16px; }
.mb-4 { margin-bottom: 32px; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 640px) {
    .hero { padding: 48px 0 40px; }
    .systems-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .system-card { padding: 16px; }
    .system-card h3 { font-size: 0.8125rem; }
    .tools-grid { grid-template-columns: 1fr; }
    .packages-grid { grid-template-columns: 1fr; }
    .auth-card { padding: 28px; }
    .tool-page { padding: 32px 0 60px; }
}

/* ============================================
   AI RESULTS — PREMIUM CARDS v2
   ============================================ */
.ai-results {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 24px;
    animation: fadeIn 0.5s var(--ease);
}

.ai-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: box-shadow 0.2s;
}
.ai-card:hover { box-shadow: var(--shadow); }

.ai-card-header {
    padding: 16px 20px;
    background: var(--bg-warm);
    border-bottom: 1px solid var(--border-light);
}
.ai-card-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--navy);
    margin: 0;
}

.ai-card-body {
    padding: 20px;
}
.ai-card-body p {
    font-size: 0.9375rem;
    line-height: 1.7;
    margin-bottom: 12px;
}

.ai-subheader {
    font-weight: 600;
    font-size: 0.9375rem;
    color: var(--navy);
    margin: 16px 0 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border-light);
}

.ai-kv {
    display: flex;
    gap: 8px;
    padding: 10px 14px;
    margin-bottom: 6px;
    background: var(--bg-warm);
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    line-height: 1.5;
    flex-wrap: wrap;
}
.ai-kv-key {
    font-weight: 600;
    color: var(--navy);
    min-width: 120px;
}
.ai-kv-key::after { content: ':'; }
.ai-kv-val { color: var(--text-secondary); flex: 1; }

.ai-bullet {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 8px 0;
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--text-secondary);
}
.ai-bullet-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 8px;
}

.ai-disclaimer-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-top: 20px;
    padding: 18px 20px;
    background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 100%);
    border: 1px solid #bbf7d0;
    border-radius: var(--radius);
}
.ai-disclaimer-icon { font-size: 1.5rem; flex-shrink: 0; }
.ai-disclaimer-card strong { font-size: 0.875rem; color: #166534; display: block; margin-bottom: 4px; }
.ai-disclaimer-card p { font-size: 0.8125rem; color: #15803d; margin: 0; line-height: 1.5; }

.ai-loading {
    text-align: center;
    padding: 40px 20px;
}
.ai-loading-bar {
    width: 200px;
    height: 4px;
    background: var(--border);
    border-radius: 4px;
    margin: 0 auto 16px;
    overflow: hidden;
    position: relative;
}
.ai-loading-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: -40%;
    width: 40%;
    height: 100%;
    background: linear-gradient(90deg, var(--teal), var(--cyan));
    border-radius: 4px;
    animation: loadSlide 1.2s ease-in-out infinite;
}
@keyframes loadSlide {
    0% { left: -40%; }
    100% { left: 100%; }
}
.ai-loading p { color: var(--text-muted); font-size: 0.9375rem; }

.btn-loader {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    vertical-align: middle;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================
   FOOTER — PREMIUM v2
   ============================================ */
.footer {
    background: var(--navy);
    color: rgba(255,255,255,0.8);
    margin-top: 80px;
}

.footer-top {
    display: grid;
    grid-template-columns: 1.2fr 2fr;
    gap: 60px;
    padding: 60px 0 40px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #fff;
    font-weight: 600;
    font-size: 1.0625rem;
    margin-bottom: 16px;
}
.footer-logo .logo-icon svg { width: 28px; height: 28px; color: var(--cyan); }
.footer-logo .logo-ai { color: var(--cyan); }

.footer-desc {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: rgba(255,255,255,0.6);
    margin-bottom: 20px;
}

.footer-trust {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}
.footer-trust span {
    font-size: 0.8125rem;
    color: rgba(255,255,255,0.5);
}

.footer-links-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.footer-col h4 {
    color: #fff;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 16px;
}

.footer-col a {
    display: block;
    color: rgba(255,255,255,0.55);
    font-size: 0.9375rem;
    padding: 5px 0;
    transition: color 0.2s;
}
.footer-col a:hover { color: var(--cyan); }

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 24px 0;
    text-align: center;
}
.footer-bottom p { color: rgba(255,255,255,0.4); font-size: 0.8125rem; margin-bottom: 4px; }
.footer-disclaimer { font-style: italic; }

@media (max-width: 768px) {
    .footer-top { grid-template-columns: 1fr; gap: 32px; }
    .footer-links-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
    .footer-links-grid { grid-template-columns: 1fr; }
}

/* ============================================
   HERO — PREMIUM v2
   ============================================ */
.hero {
    padding: 80px 0 60px;
    text-align: center;
    background: linear-gradient(160deg, #f0f4f8 0%, #e8f5f5 40%, #f5f6f8 100%);
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    top: -200px;
    right: -200px;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(45,138,138,0.08) 0%, transparent 70%);
    border-radius: 50%;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 16px;
    background: rgba(45,138,138,0.1);
    border: 1px solid rgba(45,138,138,0.2);
    border-radius: 100px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--teal);
    margin-bottom: 24px;
}

.hero-features {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-top: 16px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}
.hero-features span {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* ============================================
   TRUST SECTION
   ============================================ */
.trust-section {
    padding: 48px 0;
    background: var(--navy);
}
.trust-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 24px;
}
.trust-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}
.trust-icon {
    width: 44px;
    height: 44px;
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}
.trust-item h4 { color: #fff; font-size: 0.9375rem; margin-bottom: 4px; }
.trust-item p { color: rgba(255,255,255,0.55); font-size: 0.8125rem; margin: 0; line-height: 1.4; }

/* ============================================
   SECTION UPGRADES
   ============================================ */
.section-header {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 48px;
}
.section-header h2 { margin-bottom: 12px; }
.section-header p { font-size: 1.0625rem; }

/* Tool cards upgrade */
.tool-card {
    border-radius: var(--radius-lg);
    padding: 0;
    overflow: hidden;
}
.tool-card-inner {
    padding: 28px;
    display: flex;
    flex-direction: column;
    height: 100%;
}
.tool-card-top {
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--teal), var(--cyan));
}

/* System cards upgrade */
.system-card {
    border-radius: var(--radius-lg);
    padding: 28px 20px;
    position: relative;
    overflow: hidden;
}
.system-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--teal), var(--cyan));
    opacity: 0;
    transition: opacity 0.2s;
}
.system-card:hover::after { opacity: 1; }

/* Package cards upgrade */
.package-card {
    border-radius: var(--radius-lg);
}
.package-card.featured {
    background: linear-gradient(180deg, #f0fdf9 0%, #fff 30%);
}

/* How section upgrade */
.how-section { background: linear-gradient(180deg, var(--bg-warm) 0%, var(--bg) 100%); }
.how-step .step-num {
    width: 52px;
    height: 52px;
    background: linear-gradient(135deg, var(--teal), var(--cyan));
    color: #fff;
    font-size: 1.25rem;
}

/* CTA upgrade */
.cta-section {
    background: linear-gradient(135deg, var(--navy) 0%, #1e3a5f 50%, var(--navy-light) 100%);
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    margin-top: 0;
}

/* ============================================
   HERO GRID — IMAGE + TEXT v3
   ============================================ */
.hero {
    text-align: left;
    padding: 60px 0 40px;
    background: linear-gradient(90deg, #f0f4f8 0%, #edf5f5 35%, #ffffff 55%, #ffffff 100%);
}
.hero::before { display: none; }

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.hero-left h1 { max-width: 100%; margin-left: 0; margin-right: 0; }
.hero-left p { margin-left: 0; margin-right: 0; max-width: 480px; }
.hero-features { justify-content: flex-start; }
.hero-search { margin: 0; max-width: 480px; }

/* Body image wrapper */
.hero-right { position: relative; }

.hero-body-wrap {
    position: relative;
    max-width: 460px;
    margin: 0 auto;
}

.hero-body-img {
    width: 100%;
    height: auto;
    display: block;
    filter: drop-shadow(0 8px 32px rgba(45,138,138,0.15));
}

/* Floating bubbles */
.hero-bubble {
    position: absolute;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(232,236,240,0.8);
    border-radius: 100px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--navy);
    white-space: nowrap;
    box-shadow: 0 4px 16px rgba(26,43,74,0.08);
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
    z-index: 2;
}
.hero-bubble:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 24px rgba(26,43,74,0.14);
    color: var(--teal);
}
.hb-icon { width: 20px; height: 20px; display: inline-flex; align-items: center; justify-content: center; color: var(--teal); flex-shrink: 0; }
.hb-icon svg { width: 18px; height: 18px; }

/* Bubble positions around body */
.hb-1 { top: 2%;   left: -10%; animation: hbFloat1 4s ease-in-out infinite; }
.hb-2 { top: 8%;   right: -8%; animation: hbFloat2 4.5s ease-in-out infinite; }
.hb-3 { top: 26%;  left: -14%; animation: hbFloat3 3.8s ease-in-out infinite; }
.hb-4 { top: 32%;  right: -10%; animation: hbFloat2 4.2s ease-in-out infinite; }
.hb-5 { top: 50%;  left: -12%; animation: hbFloat1 4.3s ease-in-out infinite; }
.hb-6 { top: 56%;  right: -14%; animation: hbFloat3 3.9s ease-in-out infinite; }
.hb-7 { top: 72%;  left: -8%;  animation: hbFloat2 4.1s ease-in-out infinite; }
.hb-8 { top: 78%;  right: -10%; animation: hbFloat1 4.4s ease-in-out infinite; }

@keyframes hbFloat1 {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}
@keyframes hbFloat2 {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}
@keyframes hbFloat3 {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* Mobile */
@media (max-width: 900px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .hero-left h1 { margin: 0 auto; }
    .hero-left p { margin: 0 auto 24px; }
    .hero-features { justify-content: center; }
    .hero-search { margin: 0 auto; }
    .hero-body-wrap { max-width: 320px; margin-top: 20px; }
    .hero-bubble { font-size: 0.6875rem; padding: 6px 10px; }
    .hb-1 { left: -4%; }
    .hb-2 { right: -4%; }
    .hb-3 { left: -6%; }
    .hb-4 { right: -4%; }
    .hb-5 { left: -4%; }
    .hb-6 { right: -6%; }
    .hb-7 { left: -2%; }
    .hb-8 { right: -4%; }
}

@media (max-width: 480px) {
    .hero-bubble { display: none; }
}

/* ============================================
   KNOWLEDGE MODULE CARDS
   ============================================ */
.km-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 16px;
    overflow: hidden;
    transition: box-shadow 0.2s;
}
.km-card:hover { box-shadow: var(--shadow); }

.km-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 18px 22px;
    background: var(--bg-warm);
    border-bottom: 1px solid var(--border-light);
}
.km-card-header h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--navy);
    margin: 0;
    line-height: 1.4;
}

.km-card-body {
    padding: 22px;
}

.km-text {
    font-size: 0.9375rem;
    line-height: 1.75;
    color: var(--text-secondary);
    margin-bottom: 14px;
}
.km-text:last-child { margin-bottom: 0; }
.km-text strong { color: var(--navy); font-weight: 600; }

.km-list {
    margin: 12px 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.km-list-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 14px;
    background: var(--bg-warm);
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--text-secondary);
}

.km-list-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--teal);
    flex-shrink: 0;
    margin-top: 9px;
}

.km-list-item strong { color: var(--navy); }

/* ============================================
   ACCESSIBILITY
   ============================================ */
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}

/* ============================================
   MODULE PAGE
   ============================================ */
.modul-page { padding: 32px 0 80px; }

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-bottom: 28px;
    flex-wrap: wrap;
}
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--teal); }
.bc-sep { color: var(--border); }

.modul-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 40px;
    align-items: start;
}

.modul-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}
.modul-cat {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8125rem;
    color: var(--teal);
}
.modul-meta time { font-size: 0.8125rem; color: var(--text-muted); }

.modul-main h1 {
    font-size: clamp(1.5rem, 4vw, 2rem);
    line-height: 1.3;
    margin-bottom: 28px;
}

.modul-content { margin-bottom: 32px; }

.modul-disclaimer {
    padding: 20px;
    background: linear-gradient(135deg, #f0fdf4, #ecfdf5);
    border: 1px solid #bbf7d0;
    border-radius: var(--radius);
    margin-bottom: 32px;
}
.modul-disclaimer strong { color: #166534; display: block; margin-bottom: 6px; font-size: 0.9375rem; }
.modul-disclaimer p { color: #15803d; font-size: 0.875rem; margin: 0; line-height: 1.6; }

/* Share buttons */
.modul-share {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}
.modul-share-label { font-size: 0.875rem; font-weight: 500; color: var(--text-muted); }
.share-btn {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    transition: transform 0.15s, opacity 0.15s;
    text-decoration: none;
}
.share-btn:hover { transform: scale(1.1); opacity: 0.9; color: #fff; }
.share-btn svg { width: 18px; height: 18px; }
.share-fb { background: #1877f2; }
.share-x { background: #000; }
.share-li { background: #0a66c2; }
.share-rd { background: #ff4500; }
.share-vb { background: #665cac; }
.share-wa { background: #25d366; }
.share-em { background: var(--navy); }

/* Sidebar */
.modul-sidebar { position: sticky; top: 80px; }

.modul-sidebar-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 16px;
}
.modul-sidebar-card h3 {
    font-size: 0.9375rem;
    font-weight: 600;
    margin-bottom: 14px;
    color: var(--navy);
}

.modul-sidebar-link {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: background 0.15s;
    margin-bottom: 4px;
    line-height: 1.4;
}
.modul-sidebar-link:hover { background: var(--bg-warm); color: var(--teal); }

.modul-tag {
    display: inline-block;
    padding: 4px 10px;
    background: var(--bg-warm);
    border-radius: 100px;
    font-size: 0.75rem;
    color: var(--text-muted);
}

@media (max-width: 768px) {
    .modul-layout { grid-template-columns: 1fr; }
    .modul-sidebar { position: static; }
}

/* ============================================
   FOOTER SOCIAL ICONS
   ============================================ */
.footer-social {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}
.footer-social a {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.6);
    transition: all 0.15s;
}
.footer-social a:hover { background: rgba(255,255,255,0.2); color: #fff; }
.footer-social svg { width: 16px; height: 16px; }

/* ============================================
   CLS PREVENTION
   ============================================ */
.hero-body-img { aspect-ratio: 1/1; width: 100%; height: auto; }
.nav { min-height: 64px; }
.hero { min-height: 400px; }
img { content-visibility: auto; }

/* ============================================
   KNOWLEDGE BASE PAGE
   ============================================ */
.kb-page { padding: 32px 0 80px; }

.kb-header { margin-bottom: 28px; }
.kb-header h1 { font-size: clamp(1.5rem, 4vw, 2rem); margin-bottom: 8px; }
.kb-header p { font-size: 1rem; color: var(--text-secondary); max-width: 600px; }

/* Tabs */
.kb-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border);
}

.kb-tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border: 1px solid var(--border);
    border-radius: 100px;
    font-size: 0.875rem;
    font-weight: 450;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.15s;
    white-space: nowrap;
}
.kb-tab:hover { border-color: var(--teal); color: var(--teal); }
.kb-tab.active {
    background: var(--navy);
    border-color: var(--navy);
    color: #fff;
}
.kb-tab-icon { width: 18px; height: 18px; display: inline-flex; }
.kb-tab.active .kb-tab-icon { color: var(--cyan); }

@media (max-width: 640px) {
    .kb-tabs { gap: 6px; }
    .kb-tab { padding: 8px 12px; font-size: 0.8125rem; }
    .kb-tab-text { display: none; }
    .kb-tab.active .kb-tab-text { display: inline; }
}

/* Tools bar */
.kb-tools-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding: 16px 20px;
    background: var(--accent-bg);
    border-radius: var(--radius);
    margin-bottom: 24px;
}
.kb-tools-label { font-size: 0.875rem; color: var(--teal); font-weight: 500; }

/* Count */
.kb-count {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 20px;
}

/* Module grid */
.kb-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 16px;
}

@media (max-width: 640px) {
    .kb-grid { grid-template-columns: 1fr; }
}

.kb-hidden { display: none; }

.kb-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    display: flex;
    flex-direction: column;
    transition: all 0.2s var(--ease);
}
.kb-card:hover {
    border-color: var(--teal);
    box-shadow: var(--shadow);
    transform: translateY(-2px);
}

.kb-card-top { margin-bottom: 12px; }

.kb-type-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 550;
}
.kb-type-symptom { background: #fef2f2; color: #c44040; }
.kb-type-condition { background: #fff7ed; color: #c47a20; }
.kb-type-method { background: #ecfdf3; color: #2d8a5e; }
.kb-type-supplement { background: #f0e8f7; color: #7c3aed; }
.kb-type-exercise { background: #eff6ff; color: #2563eb; }
.kb-type-risk_factor { background: #fef3e2; color: #b45309; }
.kb-type-lifestyle { background: #f5f0eb; color: #78583a; }
.kb-type-explanation { background: #f5f6f8; color: #5a6a7e; }

.kb-card h3 {
    font-size: 1.0625rem;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 10px;
}
.kb-card h3 a {
    color: var(--navy);
    text-decoration: none;
}
.kb-card h3 a:hover { color: var(--teal); }

.kb-card-excerpt {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.6;
    flex: 1;
    margin-bottom: 16px;
}

.kb-read-more {
    display: inline-flex;
    align-items: center;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--teal);
    text-decoration: none;
    transition: gap 0.15s;
    gap: 4px;
}
.kb-read-more:hover { gap: 8px; color: var(--accent-hover); }

/* Show more */
.kb-show-more-wrap {
    text-align: center;
    margin-top: 28px;
}

/* Overview cards (no category selected) */
.kb-overview {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 14px;
}

.kb-overview-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    text-decoration: none;
    transition: all 0.2s;
}
.kb-overview-card:hover {
    border-color: var(--teal);
    box-shadow: var(--shadow);
    transform: translateY(-2px);
}
.kb-overview-icon {
    width: 44px;
    height: 44px;
    color: var(--teal);
    flex-shrink: 0;
}
.kb-overview-icon svg { width: 100%; height: 100%; }
.kb-overview-card h3 { font-size: 1rem; color: var(--navy); margin-bottom: 2px; }
.kb-overview-card p { font-size: 0.8125rem; color: var(--text-muted); margin: 0; }

/* ============================================
   MODULE IMAGES
   ============================================ */
.kb-card-img {
    width: 100%;
    aspect-ratio: 16/9;
    overflow: hidden;
    border-radius: var(--radius) var(--radius) 0 0;
    margin: -24px -24px 0;
    width: calc(100% + 48px);
}
.kb-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s var(--ease);
}
.kb-card:hover .kb-card-img img { transform: scale(1.03); }

.kb-card-body { padding-top: 16px; }
.kb-card:has(.kb-card-img) { padding-top: 0; }
.kb-card:has(.kb-card-img) .kb-card-body { padding: 20px 24px 24px; }

/* Featured image on module page */
.modul-featured-img {
    width: 100%;
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 28px;
    aspect-ratio: 16/9;
}
.modul-featured-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
