/* ============================================
   SONEXIAL LABS - MAIN STYLESHEET
   ============================================ */

/* CSS VARIABLES */
:root {
    /* THEME: "The Connected Study" (Warm/Indie) */
    --bg-light: #F9F7F2;       /* Warm Cream/Paper */
    --text-light: #2C2C2C;     /* Soft Charcoal */
    --bg-dark: #1C1B1A;        /* Warm Black */
    --text-dark: #E8E6E1;      /* Off-white */
    
    --accent: #C05621;         /* Terracotta/Burnt Orange */
    --accent-hover: #9C4221;
    --secondary: #6B7280;      /* Sage/Grey */
    
    --border-light: #E2DED5;   /* Tan border */
    --border-dark: #33302E;
    
    --font-serif: "Merriweather", Georgia, serif;
    --font-sans: "Inter", sans-serif;
    
    --bf-red: #9B2C2C;         /* Muted Red */
}

/* BASE STYLES */
html { 
    scroll-behavior: smooth; 
}

body {
    margin: 0;
    font-family: var(--font-sans);
    color: var(--text-light);
    line-height: 1.7;
    font-size: 1.05rem;
    background-color: var(--bg-light);
    /* Texture: Subtle Paper Noise */
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.04'/%3E%3C/svg%3E");
}

[data-theme="dark"] body {
    background-color: var(--bg-dark);
    color: var(--text-dark);
    /* Dark mode grid overlay */
    background-image: linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
    background-size: 40px 40px;
}

/* TYPOGRAPHY */
h1, h2, h3, h4, .cta-button, button, nav a {
    font-family: var(--font-sans);
    font-weight: 600;
    letter-spacing: -0.01em;
}

h1, h2, .step-number { 
    font-family: var(--font-serif); 
}

h2 { 
    font-size: 2.5rem; 
    margin-bottom: 1rem; 
    color: var(--text-light); 
}

[data-theme="dark"] h2 { 
    color: var(--text-dark); 
}

/* HEADER */
header {
    position: sticky; 
    top: 0; 
    z-index: 1000;
    background: rgba(249, 247, 242, 0.95);
    backdrop-filter: blur(10px);
    padding: 0.8rem 2rem;
    display: flex; 
    align-items: center; 
    justify-content: space-between;
    border-bottom: 1px solid var(--border-light);
}

[data-theme="dark"] header {
    background: rgba(28, 27, 26, 0.95);
    border-color: var(--border-dark);
}

/* LOGO */
.logo { 
    display: flex; 
    align-items: center; 
}

.logo img { 
    height: 32px; 
    width: auto; 
    display: block; 
    mix-blend-mode: multiply; 
}

[data-theme="dark"] .logo img { 
    filter: invert(1); 
    mix-blend-mode: screen; 
}

/* NAVIGATION */
nav {
    display: flex;
    gap: 2rem;
}

nav a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.2s;
}

nav a:hover {
    color: var(--accent);
}

[data-theme="dark"] nav a {
    color: var(--text-dark);
}

/* HERO SECTION */
.hero {
    position: relative;
    width: 100%;
    min-height: 85vh; 
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-bottom: 1px solid var(--border-light);
    background: #1C1B1A;
}

.hero-bg {
    position: absolute;
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%;
    background-image: url('Images/signal-bg.jpg');
    background-size: cover;
    background-position: center;
    opacity: 0.6;
    animation: kenBurns 20s ease-in-out infinite alternate;
}

.hero-grain {
    position: absolute;
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.5'/%3E%3C/svg%3E");
    opacity: 0.15;
    pointer-events: none;
}

.hero-overlay {
    position: absolute;
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%;
    background: radial-gradient(circle, rgba(28,27,26,0.4) 0%, rgba(28,27,26,0.9) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    text-align: center;
    padding: 2rem;
}

.hero h1 { 
    font-size: 4rem; 
    margin-bottom: 1.5rem; 
    line-height: 1.1; 
    color: #ffffff !important; 
    font-weight: 300; 
    text-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.hero p { 
    font-size: 1.3rem; 
    opacity: 0.9; 
    max-width: 700px; 
    margin: 0 auto 2.5rem; 
    color: #e5e5e5 !important; 
    font-weight: 300; 
}

.hero-tag { 
    text-transform: uppercase; 
    letter-spacing: 2px; 
    font-size: 0.75rem; 
    opacity: 0.9; 
    margin-bottom: 1rem; 
    display: block; 
    color: var(--accent) !important; 
    font-weight: 700; 
}

@keyframes kenBurns {
    0% { transform: scale(1); }
    100% { transform: scale(1.15); }
}

/* BUTTONS */
.cta {
    display: inline-block;
    padding: 1rem 2rem;
    background: var(--text-light);
    color: var(--bg-light);
    text-decoration: none;
    border-radius: 2px;
    font-weight: 600;
    margin-right: 1rem;
    margin-bottom: 1rem;
    transition: all 0.2s ease;
    border: 1px solid var(--text-light);
    font-size: 0.95rem;
}

[data-theme="dark"] .cta { 
    background: var(--text-dark); 
    color: var(--bg-dark); 
    border-color: var(--text-dark); 
}

.cta.secondary { 
    background: transparent; 
    color: var(--text-light); 
    border: 1px solid var(--border-light); 
}

[data-theme="dark"] .cta.secondary { 
    color: var(--text-dark); 
    border-color: var(--border-dark); 
}

.cta.secondary:hover { 
    border-color: var(--accent); 
    color: var(--accent); 
}

.hero .cta {
    background: var(--accent);
    color: #ffffff;
    border-color: var(--accent);
}

.hero .cta:hover { 
    background: var(--accent-hover); 
    opacity: 1; 
    transform: translateY(-1px); 
}

.hero .cta.secondary {
    background: transparent;
    color: #ffffff;
    border: 1px solid rgba(255,255,255,0.3);
}

.hero .cta.secondary:hover { 
    border-color: #ffffff; 
    color: #ffffff; 
}

button { 
    padding: 1rem; 
    background: var(--accent); 
    color: white; 
    border: none; 
    cursor: pointer; 
    font-weight: 600; 
    transition: opacity 0.2s; 
    border-radius: 2px; 
    letter-spacing: 0.5px; 
    font-family: var(--font-sans);
}

button:hover { 
    background: var(--accent-hover); 
}

/* SECTIONS */
section { 
    padding: 7rem 2rem; 
    max-width: 1100px; 
    margin: 0 auto; 
    border-bottom: 1px solid var(--border-light); 
}

[data-theme="dark"] section { 
    border-color: var(--border-dark); 
}

section:last-of-type { 
    border-bottom: none; 
}

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

.section-sub { 
    max-width: 700px; 
    margin: 0 auto 4rem; 
    opacity: 0.8; 
    font-size: 1.15rem; 
    font-family: var(--font-serif); 
    font-style: italic; 
    color: var(--secondary); 
}

/* LAYOUT UTILITIES */
.three-col { 
    display: flex; 
    flex-wrap: wrap; 
    gap: 2rem; 
    justify-content: center; 
}

.three-col > .card { 
    flex: 1 1 300px; 
    max-width: 350px; 
}

/* STEPS */
.steps { 
    display: flex; 
    flex-wrap: wrap; 
    gap: 3rem; 
    justify-content: center; 
    margin-top: 3rem; 
}

.step { 
    flex: 1 1 250px; 
    text-align: left; 
}

.step-number { 
    font-size: 3.5rem; 
    color: var(--border-light); 
    font-weight: 700; 
    line-height: 1; 
    margin-bottom: 0.5rem; 
}

[data-theme="dark"] .step-number { 
    color: var(--border-dark); 
    opacity: 0.5; 
}

/* CARDS */
.card {
    padding: 2.5rem; 
    border: 1px solid var(--border-light); 
    background: #ffffff;
    transition: transform 0.3s ease, box-shadow 0.3s ease; 
    display: flex; 
    flex-direction: column;
    box-shadow: 0 2px 5px rgba(0,0,0,0.02);
}

[data-theme="dark"] .card { 
    background: var(--bg-dark); 
    border-color: var(--border-dark); 
}

.card:hover { 
    border-color: var(--accent); 
    transform: translateY(-4px); 
    box-shadow: 0 10px 20px rgba(0,0,0,0.05); 
}

.card h3 { 
    font-family: var(--font-serif); 
    font-size: 1.3rem; 
    margin-top: 0; 
    margin-bottom: 0.8rem; 
}

.card p { 
    font-size: 0.95rem; 
    opacity: 0.8; 
    color: var(--secondary); 
}

[data-theme="dark"] .card p { 
    color: #aaa; 
}

.text-card h3 { 
    border-bottom: 2px solid var(--accent); 
    display: inline-block; 
    padding-bottom: 5px; 
}

/* FLAGSHIP CARD WITH 3D BOOK */
.card.flagship {
    flex: 1 1 100%; 
    max-width: 900px; 
    margin: 0 auto 2rem; 
    border: 1px solid var(--border-light);
    text-align: left; 
    flex-direction: row; 
    align-items: center; 
    gap: 3rem;
    background: linear-gradient(to bottom right, #fff, #FDFBF7);
}

[data-theme="dark"] .card.flagship { 
    background: linear-gradient(to bottom right, #1C1B1A, #111); 
    border-color: var(--accent); 
}

.book-container {
    perspective: 1000px;
    width: 180px;
    height: 260px;
    margin: 0 auto;
    flex-shrink: 0;
}

.book {
    width: 100%; 
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    transform: rotateY(-25deg);
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
    box-shadow: 15px 15px 30px rgba(0,0,0,0.15);
}

.book:hover { 
    transform: rotateY(0deg) scale(1.02); 
}

.book-cover {
    position: absolute; 
    width: 100%; 
    height: 100%;
    background: var(--accent);
    border-radius: 2px 4px 4px 2px;
    display: flex; 
    align-items: center; 
    justify-content: center;
    color: white; 
    font-weight: bold; 
    text-align: center; 
    padding: 1rem; 
    font-family: var(--font-serif);
}

.book-spine {
    position: absolute; 
    width: 30px; 
    height: 100%;
    background: var(--accent-hover);
    transform: rotateY(90deg) translateZ(-15px);
    border-left: 1px solid rgba(255,255,255,0.1);
}

.flagship-content { 
    flex: 2; 
}

/* New Year's Special Promo Text */
.flagship-action .promo-text {
    display: inline-block;
    background-color: rgba(255, 215, 0, 0.15); /* soft gold highlight */
    color: #c05621; /* matches accent color */
    font-weight: 600;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    margin-left: 0.5rem;
    font-size: 0.95rem;
    transition: opacity 0.3s ease;
}

/* Optional: subtle hover glow effect */
.flagship-action .promo-text:hover {
    background-color: rgba(255, 215, 0, 0.25);
}


[data-theme="dark"] .flagship-action { 
    border-color: var(--border-dark); 
}

.price { 
    font-size: 2.5rem; 
    font-weight: 700; 
    color: var(--text-light); 
    margin: 1rem 0; 
    font-family: var(--font-serif); 
}

[data-theme="dark"] .price { 
    color: var(--text-dark); 
}

.strike { 
    text-decoration: line-through; 
    opacity: 0.5; 
    font-size: 1.2rem; 
    margin-right: 10px; 
    color: var(--secondary);
}

.bf-badge { 
    font-size: 0.4em; 
    vertical-align: middle; 
    background: var(--bf-red); 
    color: white; 
    padding: 4px 8px; 
    border-radius: 2px; 
    text-transform: uppercase; 
    letter-spacing: 1px; 
    font-family: var(--font-sans);
}

/* TABLE */
.comparison-table { 
    overflow-x: auto; 
    margin-top: 2rem; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.03); 
    border-radius: 4px; 
}

table { 
    width: 100%; 
    border-collapse: collapse; 
    min-width: 600px; 
    font-size: 0.95rem; 
    background: white; 
}

[data-theme="dark"] table { 
    background: var(--bg-dark); 
}

th { 
    background: var(--text-light); 
    color: var(--bg-light); 
    padding: 1.2rem; 
    text-align: left; 
    font-weight: 600; 
}

[data-theme="dark"] th { 
    background: var(--text-dark); 
    color: var(--bg-dark); 
}

td { 
    padding: 1.2rem; 
    border-bottom: 1px solid var(--border-light); 
}

[data-theme="dark"] td { 
    border-color: var(--border-dark); 
}

.checkmark { 
    color: var(--accent); 
    font-weight: bold; 
}

/* FORMS */
form { 
    max-width: 500px; 
    margin: 0 auto; 
    display: grid; 
    gap: 1rem; 
}

input, textarea, select {
    padding: 1rem; 
    border: 1px solid var(--border-light); 
    background: #ffffff; 
    color: var(--text-light);
    font-family: var(--font-sans); 
    font-size: 1rem; 
    border-radius: 2px;
    transition: border-color 0.2s;
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--accent);
}

[data-theme="dark"] input, 
[data-theme="dark"] textarea, 
[data-theme="dark"] select {
    background: #2a2827; 
    border-color: var(--border-dark); 
    color: var(--text-dark);
}

/* FOOTER */
footer { 
    padding: 4rem 2rem; 
    text-align: center; 
    opacity: 0.6; 
    font-size: 0.9rem; 
    border-top: 1px solid var(--border-light); 
}

[data-theme="dark"] footer { 
    border-color: var(--border-dark); 
}

/* AUDIO WIDGET */
.audio-widget {
    position: fixed; 
    bottom: 25px; 
    right: 25px;
    background: var(--bg-light);
    border: 1px solid var(--border-light);
    padding: 8px 16px 8px 8px;
    border-radius: 50px;
    display: flex; 
    align-items: center; 
    gap: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    z-index: 9999;
    font-family: var(--font-sans);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-light);
    transition: transform 0.2s;
}

[data-theme="dark"] .audio-widget {
    background: #2a2827;
    border-color: var(--border-dark);
    color: var(--text-dark);
}

.audio-widget:hover { 
    transform: scale(1.02); 
}

#play-btn {
    background: var(--accent);
    color: white;
    border-radius: 50%;
    width: 32px; 
    height: 32px;
    padding: 0; 
    border: none;
    display: flex; 
    align-items: center; 
    justify-content: center;
    cursor: pointer;
}

#play-btn:hover { 
    background: var(--accent-hover); 
}

#status-text {
    user-select: none;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    header { 
        flex-direction: column; 
        gap: 1rem; 
    }
    
    nav {
        gap: 1rem;
    }
    
    .hero { 
        min-height: 70vh; 
    }
    
    .hero h1 { 
        font-size: 2.8rem; 
    }
    
    .card.flagship { 
        flex-direction: column; 
        padding: 1.5rem; 
        text-align: center; 
    }
    
    .book-container { 
        margin-bottom: 2rem; 
    }
    
    .flagship-action { 
        border-left: none; 
        border-top: 1px solid var(--border-light); 
        padding-left: 0; 
        padding-top: 1.5rem; 
        margin-top: 1rem; 
    }
    
    .three-col { 
        gap: 1rem; 
    }
    
    .audio-widget { 
        bottom: 15px; 
        right: 15px; 
        padding: 6px 12px 6px 6px; 
    }
}


/* ============================================
   ADDITIONAL IMPROVEMENTS
   ============================================ */

/* SKIP TO CONTENT LINK (Accessibility) */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--accent);
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    z-index: 10000;
    font-weight: 600;
}

.skip-link:focus {
    top: 0;
}

/* TRUST BADGES */
.trust-badges {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.trust-badges .badge {
    font-size: 0.85rem;
    opacity: 0.7;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

/* SCROLL TO TOP BUTTON */
.scroll-to-top {
    position: fixed;
    bottom: 90px;
    right: 25px;
    width: 48px;
    height: 48px;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transition: all 0.3s ease;
    z-index: 999;
}

.scroll-to-top:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
}

.scroll-to-top.visible {
    display: flex;
}

/* EXIT INTENT MODAL */
.exit-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.exit-modal-content {
    background: var(--bg-light);
    padding: 3rem;
    border-radius: 4px;
    max-width: 500px;
    width: 90%;
    position: relative;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    animation: slideUp 0.3s ease;
}

[data-theme="dark"] .exit-modal-content {
    background: var(--bg-dark);
}

.exit-modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-light);
    padding: 0;
    width: 32px;
    height: 32px;
    line-height: 1;
}

[data-theme="dark"] .exit-modal-close {
    color: var(--text-dark);
}

.exit-modal h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--text-light);
}

[data-theme="dark"] .exit-modal h3 {
    color: var(--text-dark);
}

.exit-modal p {
    margin-bottom: 2rem;
    opacity: 0.8;
}

.exit-form {
    display: flex;
    gap: 0.5rem;
}

.exit-form input {
    flex: 1;
}

.exit-form button {
    white-space: nowrap;
}

/* SUCCESS MODAL */
.success-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.success-modal-content {
    background: var(--bg-light);
    padding: 3rem;
    border-radius: 4px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    animation: slideUp 0.3s ease;
}

[data-theme="dark"] .success-modal-content {
    background: var(--bg-dark);
}

.success-icon {
    width: 64px;
    height: 64px;
    background: var(--accent);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin: 0 auto 1.5rem;
}

.success-modal h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.success-modal p {
    margin-bottom: 2rem;
    opacity: 0.8;
}

/* FAQ SECTION */
.faq-container {
    max-width: 800px;
    margin: 3rem auto 0;
    text-align: left;
}

.faq-item {
    border-bottom: 1px solid var(--border-light);
    margin-bottom: 0;
}

[data-theme="dark"] .faq-item {
    border-color: var(--border-dark);
}

.faq-question {
    width: 100%;
    padding: 1.5rem 0;
    background: none;
    border: none;
    text-align: left;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-light);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    transition: color 0.2s;
}

[data-theme="dark"] .faq-question {
    color: var(--text-dark);
}

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

.faq-icon {
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.faq-question[aria-expanded="true"] .faq-icon {
    transform: rotate(180deg);
}

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

.faq-answer.active {
    max-height: 500px;
    padding-bottom: 1.5rem;
}

.faq-answer p {
    margin: 0;
    opacity: 0.8;
    line-height: 1.7;
}

/* TESTIMONIALS GRID */
.testimonials {
    background: transparent;
}

.testimonial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.testimonial-card {
    padding: 2rem;
    border: 1px solid var(--border-light);
    background: #ffffff;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

[data-theme="dark"] .testimonial-card {
    background: var(--bg-dark);
    border-color: var(--border-dark);
}

.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}

.testimonial-card blockquote {
    margin: 0 0 1.5rem 0;
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1rem;
    line-height: 1.6;
}

.testimonial-card cite {
    display: block;
    font-weight: 700;
    color: var(--accent);
    font-style: normal;
    font-size: 0.9rem;
}

/* FORM LOADING STATE */
form.loading {
    opacity: 0.6;
    pointer-events: none;
}

form button[type="submit"] {
    position: relative;
}

form.loading button[type="submit"]::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid white;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.6s linear infinite;
}

/* INPUT VALIDATION STATES */
input.valid,
textarea.valid {
    border-color: #10b981;
}

input.invalid,
textarea.invalid {
    border-color: var(--bf-red);
}

.input-feedback {
    font-size: 0.85rem;
    margin-top: 0.25rem;
    display: block;
}

.input-feedback.error {
    color: var(--bf-red);
}

.input-feedback.success {
    color: #10b981;
}

/* ENHANCED FOCUS STATES */
a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* ANIMATIONS */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* LAZY LOADING PLACEHOLDER */
img[loading="lazy"] {
    background: var(--border-light);
}

[data-theme="dark"] img[loading="lazy"] {
    background: var(--border-dark);
}

/* MOBILE RESPONSIVE UPDATES */
@media (max-width: 768px) {
    .scroll-to-top {
        bottom: 80px;
        right: 15px;
        width: 44px;
        height: 44px;
    }
    
    .exit-modal-content {
        padding: 2rem;
    }
    
    .exit-form {
        flex-direction: column;
    }
    
    .testimonial-grid {
        grid-template-columns: 1fr;
    }
    
    .trust-badges {
        flex-direction: column;
        gap: 0.5rem;
    }
}

/* PRINT STYLES */
@media print {
    .audio-widget,
    .scroll-to-top,
    .exit-modal,
    header button,
    nav {
        display: none !important;
    }
}

/* NAVBAR for standalone pages */
.navbar {
    padding: 1rem 2rem;
    border-bottom: 1px solid var(--border-light);
    background: rgba(249, 247, 242, 0.95);
}

[data-theme="dark"] .navbar {
    border-color: var(--border-dark);
    background: rgba(28, 27, 26, 0.95);
}

.nav-brand a {
    font-weight: 700;
    color: var(--text-light);
    text-decoration: none;
    font-size: 1.2rem;
}

[data-theme="dark"] .nav-brand a {
    color: var(--text-dark);
}

/* REDUCED MOTION */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .hero-bg {
        animation: none;
    }
}

/* HIGH CONTRAST MODE */
@media (prefers-contrast: high) {
    :root {
        --accent: #D97706;
        --border-light: #000;
        --border-dark: #fff;
    }
}
