/*
 * Theme Name:  Nha Khoa Hoàng Yến — Astra Child
 * Theme URI:   https://nhakhoahoangyen.vn
 * Description: Child theme cho website Nha Khoa Hoàng Yến. Xây dựng trên Astra theme.
 * Author:      Nha Khoa Hoàng Yến
 * Author URI:  https://nhakhoahoangyen.vn
 * Template:    astra
 * Version:     1.0.0
 * Text Domain: nkhyvn
 * Tags:        dental, healthcare, vietnamese
 */

/* ╔══════════════════════════════════════════════════════════════╗
   ║         NHA KHOA HOÀNG YẾN — DESIGN SYSTEM v1.0            ║
   ║         "Tận tâm cho nụ cười trọn vẹn"                      ║
   ╚══════════════════════════════════════════════════════════════╝ */

/* ─── 1. DESIGN TOKENS ───────────────────────────────────────── */
:root {
    /* Primary — Xanh lá (đồng bộ logo) */
    --primary:          #2E8B57;
    --primary-dark:     #1B5E37;
    --primary-mid:      #236b43;
    --primary-light:    #4CAF50;
    --primary-50:       #E8F5E9;
    --primary-100:      #C8E6C9;

    /* Accent — Đỏ (đồng bộ logo) */
    --accent:           #D42027;
    --accent-dark:      #A8191F;
    --accent-light:     #FFEBEE;
    --accent-50:        #fff5f5;

    /* Neutral */
    --text-primary:     #1A2332;
    --text-secondary:   #4A5568;
    --text-muted:       #718096;
    --text-light:       #A0AEC0;
    --bg-white:         #FFFFFF;
    --bg-gray:          #F7F8FA;
    --bg-dark:          #1A2332;
    --bg-darker:        #0F1823;
    --border:           #E2E8F0;
    --border-light:     #F1F5F9;

    /* Semantic */
    --success:          #38A169;
    --warning:          #D69E2E;
    --info:             #3182CE;

    /* Typography */
    --font-body:        'Be Vietnam Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-heading:     'Montserrat', 'Be Vietnam Pro', sans-serif;

    /* Type Scale */
    --text-xs:    0.75rem;
    --text-sm:    0.875rem;
    --text-base:  1rem;
    --text-lg:    1.125rem;
    --text-xl:    1.25rem;
    --text-2xl:   1.5rem;
    --text-3xl:   1.875rem;
    --text-4xl:   2.25rem;
    --text-5xl:   3rem;

    /* Spacing (8px base) */
    --space-1:  0.25rem;
    --space-2:  0.5rem;
    --space-3:  0.75rem;
    --space-4:  1rem;
    --space-5:  1.25rem;
    --space-6:  1.5rem;
    --space-8:  2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;
    --space-24: 6rem;

    /* Layout */
    --container-max:    1200px;
    --container-narrow: 800px;
    --section-py:       5rem;
    --card-p:           2rem;
    --radius-sm:        6px;
    --radius:           12px;
    --radius-lg:        16px;
    --radius-xl:        24px;
    --radius-full:      9999px;

    /* Shadows */
    --shadow-xs:   0 1px 2px rgba(0,0,0,0.05);
    --shadow-sm:   0 1px 4px rgba(0,0,0,0.08);
    --shadow:      0 4px 12px rgba(0,0,0,0.10);
    --shadow-md:   0 6px 20px rgba(0,0,0,0.10);
    --shadow-lg:   0 8px 30px rgba(0,0,0,0.12);
    --shadow-xl:   0 20px 60px rgba(0,0,0,0.15);
    --shadow-card: 0 2px 8px rgba(0,0,0,0.06), 0 8px 24px rgba(0,0,0,0.08);
    --shadow-primary: 0 4px 20px rgba(46,139,87,0.3);
    --shadow-accent:  0 4px 20px rgba(212,32,39,0.3);

    /* Transitions */
    --transition:       all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast:  all 0.15s ease;
    --transition-slow:  all 0.4s ease;

    /* Z-index layers */
    --z-base:    1;
    --z-card:    10;
    --z-sticky:  100;
    --z-nav:     200;
    --z-float:   300;
    --z-modal:   400;
    --z-toast:   500;
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: 1.65;
    color: var(--text-primary);
    background: var(--bg-white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img, video {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition-fast);
}

a:hover { color: var(--primary-dark); }

/* ─── 3. TYPOGRAPHY ─────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.25;
    color: var(--text-primary);
}

h1 { font-size: var(--text-4xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-2xl); }
h4 { font-size: var(--text-xl); }
h5 { font-size: var(--text-lg); }
h6 { font-size: var(--text-base); }

p { margin-bottom: var(--space-4); line-height: 1.75; }
p:last-child { margin-bottom: 0; }

ul, ol {
    padding-left: var(--space-6);
    margin-bottom: var(--space-4);
}

li { margin-bottom: var(--space-2); }

/* Section labels */
.section-label {
    display: inline-block;
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: var(--space-3);
}
.section-label::before {
    content: '';
    display: inline-block;
    width: 24px;
    height: 2px;
    background: var(--primary);
    margin-right: 8px;
    vertical-align: middle;
    margin-top: -2px;
}

/* Section title */
.section-title {
    font-size: var(--text-3xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--space-4);
}

.section-title span {
    color: var(--primary);
}

/* Section subtitle */
.section-subtitle {
    font-size: var(--text-lg);
    color: var(--text-secondary);
    max-width: 680px;
    line-height: 1.7;
}

/* ─── 4. LAYOUT ─────────────────────────────────────────────── */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-6);
}

.container-narrow {
    max-width: var(--container-narrow);
    margin: 0 auto;
    padding: 0 var(--space-6);
}

.section {
    padding: var(--section-py) 0;
}

.section-alt {
    padding: var(--section-py) 0;
    background: var(--bg-gray);
}

.section-dark {
    padding: var(--section-py) 0;
    background: var(--bg-dark);
    color: white;
}

.section-green {
    padding: var(--section-py) 0;
    background: var(--primary-50);
}

/* Grid systems */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-6); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-6); }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-6); }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: var(--space-6); }

/* Flex utilities */
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-col { display: flex; flex-direction: column; }
.gap-2 { gap: var(--space-2); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }

/* Text alignment */
.text-center { text-align: center; }
.text-left   { text-align: left; }

/* Section header block */
.section-header { margin-bottom: var(--space-12); }
.section-header.text-center .section-subtitle { margin: 0 auto; }
.section-header.text-center .section-label::before { display: none; }
.section-header.text-center .section-label { display: block; text-align: center; }

/* ─── 5. BUTTONS ─────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: 14px 28px;
    border-radius: var(--radius-full);
    font-family: var(--font-body);
    font-size: var(--text-base);
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    border: 2px solid transparent;
    transition: var(--transition);
    white-space: nowrap;
    text-decoration: none;
}

.btn-primary {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    box-shadow: var(--shadow-accent);
}
.btn-primary:hover {
    background: var(--accent-dark);
    border-color: var(--accent-dark);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(212,32,39,0.4);
}

.btn-secondary {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    box-shadow: var(--shadow-primary);
}
.btn-secondary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(46,139,87,0.4);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border-color: var(--primary);
}
.btn-outline:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
}

.btn-outline-white {
    background: transparent;
    color: white;
    border-color: white;
}
.btn-outline-white:hover {
    background: white;
    color: var(--primary);
}

.btn-lg {
    padding: 16px 36px;
    font-size: var(--text-lg);
}

.btn-sm {
    padding: 10px 20px;
    font-size: var(--text-sm);
}

/* Phone button — accent */
.btn-phone {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}
.btn-phone:hover {
    background: var(--accent-dark);
    color: white;
    transform: translateY(-2px);
}

/* Zalo button */
.btn-zalo {
    background: #0068FF;
    color: white;
    border-color: #0068FF;
}
.btn-zalo:hover {
    background: #0052CC;
    color: white;
    border-color: #0052CC;
    transform: translateY(-2px);
}

/* ─── 6. CARDS ───────────────────────────────────────────────── */
.card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: var(--card-p);
    box-shadow: var(--shadow-card);
    border: 1px solid var(--border-light);
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-100);
}

.card-service {
    text-align: center;
    padding: var(--space-8);
}

.card-service .card-icon {
    width: 72px;
    height: 72px;
    background: var(--primary-50);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-4);
    transition: var(--transition);
}

.card-service:hover .card-icon {
    background: var(--primary);
}

.card-service:hover .card-icon svg,
.card-service:hover .card-icon img {
    filter: brightness(0) invert(1);
}

.card-service .card-title {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--space-3);
}

.card-service .card-desc {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    line-height: 1.65;
    margin-bottom: var(--space-4);
}

.card-service .card-link {
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.card-service .card-link::after { content: ' →'; }
.card-service:hover .card-link { color: var(--primary-dark); }

/* Doctor cards */
.card-doctor {
    text-align: center;
    overflow: hidden;
}

.card-doctor .doctor-photo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto var(--space-4);
    border: 4px solid var(--primary-100);
}

.card-doctor .doctor-name {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--space-1);
}

.card-doctor .doctor-title {
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--primary);
    margin-bottom: var(--space-3);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.card-doctor .doctor-spec {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    margin-bottom: var(--space-2);
}

.card-doctor .doctor-badge {
    display: inline-block;
    padding: 4px 12px;
    background: var(--primary-50);
    color: var(--primary-dark);
    border-radius: var(--radius-full);
    font-size: var(--text-xs);
    font-weight: 600;
    margin: 2px;
}

/* ─── 7. TRUST SIGNALS ───────────────────────────────────────── */
.trust-card {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-6);
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
}

.trust-icon {
    width: 56px;
    height: 56px;
    background: var(--primary-50);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.75rem;
}

.trust-number {
    font-size: var(--text-3xl);
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
}

.trust-label {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    font-weight: 500;
}

/* ─── 8. BREADCRUMB ──────────────────────────────────────────── */
.breadcrumb {
    padding: var(--space-4) 0;
    font-size: var(--text-sm);
    color: var(--text-muted);
}

.breadcrumb a {
    color: var(--text-muted);
}
.breadcrumb a:hover { color: var(--primary); }

.breadcrumb span + span::before {
    content: ' › ';
    margin: 0 6px;
}

/* ─── 9. BADGES & TAGS ───────────────────────────────────────── */
.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: var(--text-xs);
    font-weight: 600;
    letter-spacing: 0.03em;
}

.badge-primary { background: var(--primary-50); color: var(--primary-dark); }
.badge-accent  { background: var(--accent-light); color: var(--accent-dark); }
.badge-gray    { background: var(--bg-gray); color: var(--text-secondary); }

/* ─── 10. ANIMATIONS ─────────────────────────────────────────── */
/* Scroll reveal */
[data-reveal] {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
[data-reveal].revealed {
    opacity: 1;
    transform: translateY(0);
}
[data-reveal-delay="1"] { transition-delay: 0.1s; }
[data-reveal-delay="2"] { transition-delay: 0.2s; }
[data-reveal-delay="3"] { transition-delay: 0.3s; }
[data-reveal-delay="4"] { transition-delay: 0.4s; }

/* Pulse animation for phone CTA */
@keyframes pulse-ring {
    0%   { box-shadow: 0 0 0 0 rgba(212,32,39,0.4); }
    70%  { box-shadow: 0 0 0 12px rgba(212,32,39,0); }
    100% { box-shadow: 0 0 0 0 rgba(212,32,39,0); }
}

/* Count-up ready state */
.count-up { transition: all 0.05s; }

/* ─── 11. PAGE HERO MINI (for inner pages) ───────────────────── */
.page-hero {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
    padding: var(--space-16) 0 var(--space-12);
    color: white;
    text-align: center;
}

.page-hero h1 {
    color: white;
    font-size: var(--text-4xl);
    margin-bottom: var(--space-4);
}

.page-hero .page-hero-desc {
    font-size: var(--text-lg);
    color: rgba(255,255,255,0.85);
    max-width: 600px;
    margin: 0 auto;
}

.page-hero .breadcrumb {
    justify-content: center;
    display: flex;
    margin-bottom: var(--space-4);
    opacity: 0.8;
}

/* ─── 12. FAQ ACCORDION ──────────────────────────────────────── */
.faq-list { list-style: none; padding: 0; }

.faq-item {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: var(--space-3);
    overflow: hidden;
    transition: var(--transition);
}

.faq-item.active {
    border-color: var(--primary-100);
    box-shadow: var(--shadow-sm);
}

.faq-question {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-5) var(--space-6);
    background: white;
    border: none;
    cursor: pointer;
    font-family: var(--font-body);
    font-size: var(--text-base);
    font-weight: 600;
    color: var(--text-primary);
    text-align: left;
    transition: var(--transition-fast);
}

.faq-question:hover { color: var(--primary); }

.faq-chevron {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    transition: transform 0.3s ease;
    color: var(--primary);
}

.faq-item.active .faq-chevron { transform: rotate(180deg); }

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease, padding 0.3s ease;
}

.faq-item.active .faq-answer {
    max-height: 600px;
}

.faq-answer-inner {
    padding: 0 var(--space-6) var(--space-5);
    color: var(--text-secondary);
    line-height: 1.75;
    font-size: var(--text-base);
}

/* ─── 13. CTA SECTION ────────────────────────────────────────── */
.cta-section {
    padding: var(--space-20) 0;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 60%, var(--primary-mid) 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Ccircle cx='30' cy='30' r='20'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E") repeat;
    pointer-events: none;
}

.cta-section h2 {
    color: white;
    font-size: var(--text-4xl);
    margin-bottom: var(--space-4);
}

.cta-section p {
    color: rgba(255,255,255,0.85);
    font-size: var(--text-lg);
    margin-bottom: var(--space-8);
}

.cta-buttons {
    display: flex;
    gap: var(--space-4);
    justify-content: center;
    flex-wrap: wrap;
}

/* ─── 14. TESTIMONIALS ───────────────────────────────────────── */
.testimonial-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: var(--space-8);
    box-shadow: var(--shadow-card);
    border: 1px solid var(--border-light);
}

.testimonial-stars {
    color: #F6C90E;
    font-size: var(--text-lg);
    margin-bottom: var(--space-4);
    letter-spacing: 2px;
}

.testimonial-text {
    font-style: italic;
    color: var(--text-secondary);
    line-height: 1.75;
    margin-bottom: var(--space-5);
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.testimonial-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--primary-50);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-weight: 700;
    font-size: var(--text-lg);
    flex-shrink: 0;
}

.testimonial-name {
    font-weight: 700;
    color: var(--text-primary);
    font-size: var(--text-base);
}

.testimonial-service {
    font-size: var(--text-sm);
    color: var(--primary);
}

/* ─── 15. PROCESS STEPS ──────────────────────────────────────── */
.process-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--space-6);
    counter-reset: step;
}

.process-step {
    text-align: center;
    padding: var(--space-8) var(--space-4);
    position: relative;
}

.process-step::after {
    content: '';
    position: absolute;
    top: 40px;
    right: -24px;
    width: 48px;
    height: 2px;
    background: var(--primary-100);
}

.process-step:last-child::after { display: none; }

.step-number {
    width: 56px;
    height: 56px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--text-xl);
    font-weight: 700;
    margin: 0 auto var(--space-4);
    counter-increment: step;
}

.step-title {
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--space-2);
}

.step-desc {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    line-height: 1.65;
}

/* ─── 16. BLOG / ARTICLE CARDS ───────────────────────────────── */
.post-card {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-card);
    border: 1px solid var(--border-light);
    transition: var(--transition);
}

.post-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.post-card .post-thumbnail {
    aspect-ratio: 16/9;
    overflow: hidden;
}

.post-card .post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.post-card:hover .post-thumbnail img { transform: scale(1.05); }

.post-card .post-content {
    padding: var(--space-6);
}

.post-card .post-cat {
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: var(--space-2);
    display: block;
}

.post-card .post-title {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--space-3);
    line-height: 1.4;
}

.post-card:hover .post-title { color: var(--primary); }

.post-card .post-excerpt {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    line-height: 1.65;
    margin-bottom: var(--space-4);
}

.post-meta {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    font-size: var(--text-xs);
    color: var(--text-muted);
}

/* ─── 17. SERVICE HTML CONTENT ───────────────────────────────── */
.service-html-content {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--text-primary);
}
.service-html-content h2 {
    font-size: var(--text-2xl);
    color: var(--primary);
    margin-top: 2.5rem;
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-100);
}
.service-html-content p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}
.service-html-content ul, 
.service-html-content ol {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
    color: var(--text-secondary);
}
.service-html-content li {
    margin-bottom: 0.5rem;
}
.service-html-content strong {
    color: var(--text-primary);
    font-weight: 700;
}

/* ─── 17. UTILITIES ──────────────────────────────────────────── */
.visually-hidden {
    position: absolute;
    width: 1px; height: 1px;
    margin: -1px; padding: 0;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap; border: 0;
}

.divider {
    height: 1px;
    background: var(--border);
    margin: var(--space-8) 0;
}

.highlight { color: var(--primary); }
.highlight-accent { color: var(--accent); }

/* ─── 18. RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 1024px) {
    :root {
        --text-5xl: 2.5rem;
        --text-4xl: 2rem;
        --text-3xl: 1.6rem;
        --section-py: 4rem;
    }

    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    :root {
        --text-5xl: 2rem;
        --text-4xl: 1.75rem;
        --text-3xl: 1.375rem;
        --section-py: 3rem;
        --card-p: 1.5rem;
    }

    .container { padding: 0 var(--space-4); }
    .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .cta-buttons .btn { width: 100%; max-width: 320px; justify-content: center; }

    .section-title { font-size: var(--text-2xl); }
    .process-step::after { display: none; }

    .page-hero h1 { font-size: var(--text-3xl); }
}

/* ─── 19. ASTRA OVERRIDES — CRITICAL FULL-WIDTH FIX ─────────── */

/* ══ Force our sections to break out of Astra's ast-container ══ */

/* Astra wraps content in .site-content > .ast-container
   We need to reset this for our custom sections */
#content .ast-container {
    display: block !important;
    max-width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* The .entry-content also has padding - remove for full-width pages */
.nkhyvn-homepage #content .entry-content,
.nkhyvn-homepage #content .entry-content-wrap {
    padding: 0 !important;
    margin: 0 !important;
}

/* Our custom sections handle their own container width */
.nkhyvn-hero,
.nkhyvn-trust,
.nkhyvn-services,
.nkhyvn-team,
.nkhyvn-why,
.nkhyvn-reviews,
.nkhyvn-faq,
.nkhyvn-video,
.nkhyvn-blog,
.cta-section,
.page-hero,
.section-alt {
    width: 100vw !important;
    max-width: 100vw !important;
    margin-left: calc(-50vw + 50%) !important;
    margin-right: calc(-50vw + 50%) !important;
    position: relative;
}

/* Fix overflow from the negative margin technique */
body, #content, #primary {
    overflow-x: hidden;
}

/* Remove Astra page-title on homepage */
.nkhyvn-homepage .ast-page-title,
.nkhyvn-homepage .entry-title,
.nkhyvn-homepage .page-title {
    display: none !important;
}

/* ══ Astra sidebar — force no-sidebar on homepage ══ */
.nkhyvn-homepage #primary {
    width: 100% !important;
    max-width: 100% !important;
    flex: 0 0 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* ══ Astra header overrides ══ */
.ast-container { max-width: var(--container-max) !important; }

/* Remove Astra's header background so our top bar shows correctly */
#masthead {
    position: sticky;
    top: 0;
    z-index: calc(var(--z-nav) - 1);
    box-shadow: none;
    transition: box-shadow 0.3s ease;
}

#masthead.scrolled {
    box-shadow: 0 2px 16px rgba(0,0,0,0.1);
}

/* Site title / logo */
#masthead .site-title a { color: var(--primary) !important; }
.custom-logo { max-height: 56px; width: auto; }

/* Nav link styles */
#masthead .main-navigation a,
#masthead .ast-nav-menu > li > a {
    font-family: var(--font-body) !important;
    font-weight: 600 !important;
    font-size: 0.9375rem !important;
    color: var(--text-primary) !important;
    transition: color 0.2s ease !important;
}

#masthead .main-navigation a:hover,
#masthead .ast-nav-menu > li > a:hover,
#masthead .ast-nav-menu > .current-menu-item > a {
    color: var(--primary) !important;
}

/* Astra dropdown menu */
.ast-nav-menu .sub-menu {
    border-top: 2px solid var(--primary) !important;
    border-radius: 0 0 var(--radius) var(--radius) !important;
    box-shadow: var(--shadow-lg) !important;
}

/* ══ Astra footer — hide if we add custom footer ══ */
.ast-footer-copyright { text-align: center; }

/* Remove Astra defaults that conflict */
.ast-page-builder-template .entry-content-wrap,
.ast-separate-container .ast-article-single { padding: 0 !important; }

/* ══ Additional - Section alt bg needs full bleed ══ */
.section-alt { background: var(--bg-gray); }

/* ══ Fix: data-reveal initial state - make visible if JS fails ══ */
@media (prefers-reduced-motion: reduce) {
    [data-reveal] {
        opacity: 1 !important;
        transform: none !important;
    }
}

