/* ============================================
   Great White Smile — Custom Styles
   ============================================ */

/* Base */
*, *::before, *::after {
    box-sizing: border-box;
}

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

body {
    min-height: 100vh;
    overflow-x: hidden;
}

/* Focus styles */
*:focus-visible {
    outline: 2px solid #059669;
    outline-offset: 2px;
}

/* Skip link */
.skip-link {
    z-index: 9999;
}

/* ============================================
   Navbar
   ============================================ */
.nav-header {
    transition: box-shadow 0.3s ease, background 0.3s ease;
}

.nav-header.scrolled {
    box-shadow: 0 1px 20px rgba(2, 44, 34, 0.08);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: #059669;
    transition: all 0.2s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 60%;
}

/* ============================================
   Mobile Menu
   ============================================ */
.mobile-menu {
    max-height: 0;
}

.mobile-menu.open {
    max-height: 400px;
}

.mobile-nav-link {
    border-radius: 0.75rem;
}

/* ============================================
   Hero Section
   ============================================ */
.hero-gradient {
    background: linear-gradient(135deg, #022c22 0%, #065f46 30%, #047857 55%, #059669 80%, #10b981 100%);
    position: relative;
}

.hero-circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.3;
}

.hero-circle-1 {
    width: 600px;
    height: 600px;
    background: #10b981;
    top: -200px;
    right: -100px;
    animation: float 8s ease-in-out infinite;
}

.hero-circle-2 {
    width: 400px;
    height: 400px;
    background: #34d399;
    bottom: -100px;
    left: -100px;
    animation: float 6s ease-in-out infinite reverse;
}

.hero-circle-3 {
    width: 200px;
    height: 200px;
    background: #6ee7b7;
    top: 40%;
    left: 45%;
    animation: float 10s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(20px, -20px) scale(1.05); }
    66% { transform: translate(-10px, 15px) scale(0.95); }
}

/* ============================================
   Service Cards
   ============================================ */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #059669, #10b981);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.service-card:hover::before {
    opacity: 1;
}

/* ============================================
   FAQ Accordion
   ============================================ */
.faq-item {
    transition: box-shadow 0.3s ease;
}

.faq-item:hover {
    box-shadow: 0 4px 20px rgba(2, 44, 34, 0.06);
}

.faq-toggle {
    background: none;
    border: none;
    width: 100%;
    cursor: pointer;
    text-align: left;
}

.faq-toggle:hover .faq-icon {
    color: #047857;
}

.faq-content {
    transition: max-height 0.4s ease, padding 0.4s ease;
}

.faq-content.open {
    max-height: 300px;
}

/* ============================================
   Scroll Reveal (Progressive Enhancement)
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }

    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }

    .reveal[data-delay="100"] {
        transition-delay: 0.1s;
    }

    .reveal[data-delay="200"] {
        transition-delay: 0.2s;
    }

    .reveal[data-delay="300"] {
        transition-delay: 0.3s;
    }

    .reveal[data-delay="400"] {
        transition-delay: 0.4s;
    }
}

/* Default visible state (no JS) */
.reveal {
    opacity: 1;
    transform: none;
}

.js-active .reveal {
    opacity: 0;
    transform: translateY(30px);
}

.js-active .reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================
   Back to Top
   ============================================ */
.back-to-top {
    transition: opacity 0.3s ease, transform 0.3s ease, background 0.3s ease;
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.back-to-top:hover {
    background: #047857;
}

/* ============================================
   Form Styles
   ============================================ */
select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 0.75rem center;
    background-repeat: no-repeat;
    background-size: 1.25em 1.25em;
    padding-right: 2.5rem;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 767px) {
    .hero-gradient {
        min-height: auto;
        padding-top: 6rem;
        padding-bottom: 4rem;
    }

    .hero-circle-1 {
        width: 300px;
        height: 300px;
    }

    .hero-circle-2 {
        width: 200px;
        height: 200px;
    }

    .hero-circle-3 {
        display: none;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .hero-gradient {
        min-height: 90vh;
    }
}

/* ============================================
   Print
   ============================================ */
@media print {
    .nav-header,
    .back-to-top,
    .hero-gradient {
        background: none !important;
    }

    .hero-gradient {
        color: #000 !important;
    }

    .reveal {
        opacity: 1 !important;
        transform: none !important;
    }
}
