:root {
    /* Color Palette - Premium Trust */
    --clr-primary: #0a3a60; /* Deep Trust Blue */
    --clr-primary-light: #1664a0;
    --clr-accent: #00bfa5; /* Teal / Health */
    --clr-accent-hover: #009c86;
    --clr-whatsapp: #25D366;
    --clr-whatsapp-hover: #128C7E;
    
    --clr-dark: #0f172a;
    --clr-text: #334155;
    --clr-text-light: #64748b;
    --clr-bg: #ffffff;
    --clr-bg-alt: #f8fafc;
    
    /* Gradients */
    --grad-primary: linear-gradient(135deg, var(--clr-primary), var(--clr-primary-light));
    --grad-accent: linear-gradient(135deg, #00bfa5, #00d2b6);
    
    /* Typography */
    --font-main: 'Outfit', sans-serif;
    
    /* Spacing */
    --sp-xs: 0.5rem;
    --sp-sm: 1rem;
    --sp-md: 2rem;
    --sp-lg: 4rem;
    --sp-xl: 6rem;
    
    /* Borders & Shadows */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.025);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.05), 0 10px 10px -5px rgba(0, 0, 0, 0.02);
    --shadow-float: 0 10px 40px -10px rgba(10, 58, 96, 0.2);
    
    /* Motion */
    --ease-spring: cubic-bezier(0.175, 0.885, 0.32, 1.275);
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: 0.2s var(--ease-out);
    --transition-normal: 0.4s var(--ease-out);
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-main);
    color: var(--clr-text);
    background-color: var(--clr-bg);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--clr-dark);
    line-height: 1.2;
    font-weight: 700;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

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

/* Utilities */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

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

.bg-light { background-color: var(--clr-bg-alt); }
.bg-dark { background-color: var(--clr-dark); color: #fff; }
.bg-gradient { background: var(--grad-primary); }

.text-center { text-align: center; }
.text-white { color: #fff; }
.text-white h2, .text-white h3 { color: #fff; }
.text-blue-light { color: #94a3b8; }
.text-gradient {
    background: var(--grad-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.mt-sm { margin-top: var(--sp-sm); }
.mt-md { margin-top: var(--sp-md); }
.mt-l { margin-top: var(--sp-lg); }
.mt-xl { margin-top: var(--sp-xl); }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 1rem;
    transition: all var(--transition-fast);
    cursor: pointer;
    border: 2px solid transparent;
}

.btn i {
    font-size: 1.25rem;
}

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

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    background-color: var(--clr-accent);
    color: #fff;
}

.btn-primary:hover {
    background-color: var(--clr-accent-hover);
}

.btn-whatsapp {
    background-color: var(--clr-whatsapp);
    color: #fff;
}

.btn-whatsapp:hover {
    background-color: var(--clr-whatsapp-hover);
}

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

.btn-outline:hover {
    background-color: var(--clr-primary);
    color: #fff;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    transition: transform var(--transition-normal);
}

.navbar.scrolled-down {
    transform: translateY(-100%);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--clr-primary);
}

.logo i {
    font-size: 2rem;
    color: var(--clr-accent);
}

.logo b {
    font-weight: 800;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    font-weight: 500;
    position: relative;
    color: var(--clr-text);
    transition: color var(--transition-fast);
}

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

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--clr-accent);
    transition: width var(--transition-normal);
}

.nav-links a:hover::after {
    width: 100%;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.75rem;
    color: var(--clr-dark);
    cursor: pointer;
}

/* Mobile Menu */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: #fff;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    padding: 2rem;
    transform: translateX(100%);
    transition: transform var(--transition-normal);
}

.mobile-menu-overlay.active {
    transform: translateX(0);
}

.close-menu-btn {
    align-self: flex-end;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--clr-dark);
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-top: 3rem;
    margin-bottom: 3rem;
}

.mobile-nav-links a {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--clr-dark);
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    padding-top: 80px;
    padding-bottom: 100px; /* Safe space for the scroll indicator */
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.85);
}

#tooth-rain-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 1;
}

.rain-tooth {
    position: absolute;
    top: -200px;
    color: var(--clr-primary);
    animation: toothFall linear infinite;
    font-size: calc(1.5rem + (var(--scale) * 2.5rem)); /* Mobile size */
    will-change: transform;
}

@keyframes toothFall {
    0% { transform: translateY(-200px) rotate(var(--rot, 0deg)); }
    100% { transform: translateY(120vh) rotate(var(--rot, 0deg)); }
}

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

.badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background-color: rgba(0, 191, 165, 0.1);
    color: var(--clr-accent-hover);
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(0, 191, 165, 0.2);
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--clr-text);
    margin-bottom: 2.5rem;
}

.hero-ctas {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
}

.hero-note {
    font-size: 0.875rem;
    color: var(--clr-text-light);
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    animation: gentleFloat 2.5s ease-in-out infinite;
    z-index: 10;
}

.scroll-indicator a {
    color: var(--clr-primary);
    font-size: 2.5rem;
    opacity: 0.6;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all var(--transition-fast);
}

.scroll-indicator a:hover {
    opacity: 1;
}

@keyframes gentleFloat {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(12px); }
}

/* Section Headers */
.section-header {
    margin-bottom: 4rem;
}

.section-subtitle {
    display: block;
    color: var(--clr-accent);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 2.5rem);
}

/* Treatments Grid */
.treatments-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.treatment-card {
    background: var(--clr-bg);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-normal);
    border: 1px solid rgba(0,0,0,0.03);
}

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

.card-icon {
    width: 60px;
    height: 60px;
    background: rgba(0, 191, 165, 0.1);
    color: var(--clr-accent);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    transition: transform var(--transition-fast);
}

.treatment-card:hover .card-icon {
    transform: scale(1.1) rotate(5deg);
    background: var(--clr-accent);
    color: #fff;
}

.treatment-card h3 {
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

/* Before & After */
.ba-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.check-list {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.check-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
    color: var(--clr-dark);
}

.check-list i {
    color: var(--clr-accent);
    font-size: 1.5rem;
}

.ba-image-wrapper {
    position: relative;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.ba-image-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-lg);
    border: 4px solid #fff;
    z-index: 2;
    pointer-events: none;
}

.ba-image {
    border-radius: var(--radius-lg);
    width: 100%;
}

.ba-badge {
    position: absolute;
    bottom: -20px;
    right: -20px;
    background: var(--clr-bg);
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    z-index: 3;
    font-weight: 700;
    color: var(--clr-dark);
    max-width: 90%;
}

.ba-badge i {
    color: #fbbf24; /* Gold */
}

/* Steps */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
}

.step-card {
    text-align: center;
    position: relative;
}

.step-number {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 6rem;
    font-weight: 800;
    color: rgba(255,255,255,0.05);
    z-index: 0;
}

.step-icon {
    width: 80px;
    height: 80px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: var(--clr-accent);
    margin: 0 auto 1.5rem;
    position: relative;
    z-index: 1;
}

.step-card h3 {
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.step-card p {
    color: var(--clr-text-light);
    position: relative;
    z-index: 1;
}

/* About Section */
.about-layout {
    display: grid;
    grid-template-columns: 4fr 5fr;
    gap: 4rem;
    align-items: center;
}

.about-image {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.about-experience {
    position: absolute;
    bottom: 0;
    left: 0;
    background: var(--clr-primary);
    color: #fff;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border-top-right-radius: var(--radius-lg);
}

.exp-number {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1;
}

.exp-text {
    font-weight: 600;
    line-height: 1.2;
}

.cro {
    color: var(--clr-text-light);
    font-weight: 500;
    margin-bottom: 1.5rem;
}

.about-bio {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.about-credentials {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cred-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 600;
    color: var(--clr-dark);
}

.cred-item i {
    color: var(--clr-accent);
    font-size: 1.5rem;
}

/* Testimonials */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.testimonial-card {
    background: var(--clr-bg);
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.stars {
    color: #fbbf24;
    display: flex;
    gap: 0.25rem;
    font-size: 1.25rem;
}

.review {
    font-style: italic;
    font-size: 1.125rem;
    color: var(--clr-dark);
    flex-grow: 1;
}

.reviewer {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.avatar {
    width: 50px;
    height: 50px;
    background: var(--clr-primary-light);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
}

.reviewer-info strong {
    display: block;
    color: var(--clr-dark);
}

.reviewer-info span {
    font-size: 0.875rem;
    color: var(--clr-text-light);
}

/* FAQ */
.faq-container {
    max-width: 800px;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.faq-item {
    border: 1px solid rgba(0,0,0,0.1);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.faq-question {
    width: 100%;
    background: var(--clr-bg);
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--clr-dark);
    text-align: left;
    transition: background var(--transition-fast);
}

.faq-question:hover {
    background: var(--clr-bg-alt);
}

.faq-question i {
    transition: transform var(--transition-fast);
    color: var(--clr-primary);
}

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

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--transition-normal);
    background: var(--clr-bg);
}

.faq-item.active .faq-answer {
    max-height: 300px; /* Fallback arbitrary value to allow transition */
}

.faq-answer p {
    padding: 0 1.5rem 1.5rem;
    color: var(--clr-text);
}

/* Final CTA */
.cta-container {
    text-align: center;
    max-width: 800px;
}

.cta-title {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1rem;
}

.cta-subtitle {
    font-size: 1.25rem;
    opacity: 0.9;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    text-align: left;
    background: rgba(255,255,255,0.1);
    padding: 2rem;
    border-radius: var(--radius-lg);
    backdrop-filter: blur(10px);
}

.info-item {
    display: flex;
    gap: 1rem;
}

.info-item i {
    font-size: 2rem;
    color: var(--clr-accent);
}

.info-item strong {
    display: block;
    font-size: 1.125rem;
    margin-bottom: 0.25rem;
}

.info-item p {
    opacity: 0.8;
    font-size: 0.875rem;
}

/* Footer */
.footer {
    background: var(--clr-dark);
    color: #fff;
    padding: 4rem 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-brand .logo {
    color: #fff;
    margin-bottom: 1rem;
}

.footer-brand p {
    color: var(--clr-text-light);
    max-width: 300px;
}

.footer-links p, .footer-social p {
    font-weight: 700;
    font-size: 1.125rem;
    margin-bottom: 1.5rem;
}

.footer-links a {
    display: block;
    color: var(--clr-text-light);
    margin-bottom: 0.75rem;
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: var(--clr-accent);
}

.social-icons {
    display: flex;
    gap: 1rem;
}

.social-icons a {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1.25rem;
    transition: background var(--transition-fast);
}

.social-icons a:hover {
    background: var(--clr-accent);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: var(--clr-text-light);
    font-size: 0.875rem;
}

/* Floating WhatsApp */
.floating-whatsapp {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background-color: var(--clr-whatsapp);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    box-shadow: var(--shadow-float);
    z-index: 1000;
    transition: transform var(--transition-spring);
    animation: pulse 2s infinite;
}

.floating-whatsapp:hover {
    transform: scale(1.1);
    animation: none;
}

.tooltip {
    position: absolute;
    right: 75px;
    background: var(--clr-dark);
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    font-weight: 600;
    opacity: 0;
    pointer-events: none;
    transform: translateX(10px);
    transition: all var(--transition-fast);
    white-space: nowrap;
}

.floating-whatsapp:hover .tooltip {
    opacity: 1;
    transform: translateX(0);
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.5);
    }
    70% {
        box-shadow: 0 0 0 15px rgba(37, 211, 102, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

/* Motion Reveal Classes */
.motion-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.motion-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.motion-reveal[style*="--delay"] {
    transition-delay: var(--delay);
}

/* Media Queries */
@media (max-width: 992px) {
    .ba-layout, .about-layout {
        grid-template-columns: 1fr;
    }
    
    .ba-image-wrapper {
        order: -1;
    }
    
    .hero-overlay {
        background: linear-gradient(to right, rgba(255,255,255,0.95) 0%, rgba(255,255,255,0.9) 100%);
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .desktop-only {
        display: none !important;
    }
    
    .nav-links, .nav-cta {
        display: none;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    .hero {
        text-align: center;
    }
    
    .hero-content {
        margin: auto;
    }
    
    .hero-ctas {
        align-items: center;
    }
    
    .ba-badge {
        bottom: 10px;
        right: 10px;
        padding: 0.75rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

@media (min-width: 769px) {
    .treatments-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .ba-layout {
        grid-template-columns: 1fr 1fr;
        align-items: center;
    }
    
    .about-layout {
        grid-template-columns: 1fr 1fr;
        align-items: center;
    }
    
    .testimonials-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .rain-tooth {
        font-size: calc(3rem + (var(--scale) * 4rem)); /* Desktop size */
    }
}

@media (max-width: 480px) {
    .hero-content {
        padding: 1rem;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .scroll-indicator a {
        font-size: 2rem; /* Scaled down for mobile */
    }
    
    .floating-whatsapp {
        bottom: 1rem;
        right: 1rem;
    }
}
