/* ============================================
   Raley Chiropractic — Styles
   Forest Green + Off-White | Warm & Friendly
   ============================================ */

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --green-900: #0B2218;
    --green-800: #1B4332;
    --green-700: #2D6A4F;
    --green-600: #40916C;
    --green-500: #52B788;
    --green-400: #74C69D;
    --green-300: #95D5B2;
    --green-200: #B7E4C7;
    --green-100: #D8F3DC;
    --green-50:  #EFF7F1;
    --white:     #FFFFFF;
    --off-white: #F5F7F0;
    --cream:     #FAFBF7;
    --gray-100:  #F1F3EF;
    --gray-200:  #E2E6DF;
    --gray-300:  #C5CAC0;
    --gray-400:  #9BA396;
    --gray-500:  #6B7568;
    --gray-600:  #4A5248;
    --gray-700:  #2D332C;
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --shadow-sm: 0 1px 3px rgba(27,67,50,0.06), 0 1px 2px rgba(27,67,50,0.04);
    --shadow-md: 0 4px 16px rgba(27,67,50,0.08), 0 2px 6px rgba(27,67,50,0.05);
    --shadow-lg: 0 12px 40px rgba(27,67,50,0.12), 0 4px 12px rgba(27,67,50,0.06);
    --shadow-xl: 0 20px 60px rgba(27,67,50,0.15), 0 8px 20px rgba(27,67,50,0.08);
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--gray-700);
    background: var(--off-white);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: 'Playfair Display', Georgia, serif;
    color: var(--green-800);
    line-height: 1.25;
    font-weight: 700;
}

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

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

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

/* ============================================
   Buttons
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: 'DM Sans', sans-serif;
    font-weight: 600;
    font-size: 0.9375rem;
    border: 2px solid transparent;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
    text-align: center;
}

.btn-primary {
    background: var(--green-700);
    color: var(--white);
    border-color: var(--green-700);
    padding: 12px 28px;
}

.btn-primary:hover {
    background: var(--green-800);
    border-color: var(--green-800);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background: transparent;
    color: var(--green-700);
    border-color: var(--green-700);
    padding: 12px 28px;
}

.btn-outline:hover {
    background: var(--green-700);
    color: var(--white);
    transform: translateY(-2px);
}

.btn-light {
    background: var(--white);
    color: var(--green-800);
    border-color: var(--white);
    padding: 14px 32px;
}

.btn-light:hover {
    background: var(--green-50);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-outline-light {
    background: transparent;
    color: var(--white);
    border-color: rgba(255,255,255,0.6);
    padding: 14px 32px;
}

.btn-outline-light:hover {
    background: rgba(255,255,255,0.15);
    border-color: var(--white);
    transform: translateY(-2px);
}

.btn-sm {
    padding: 8px 20px;
    font-size: 0.875rem;
}

.btn-lg {
    padding: 16px 36px;
    font-size: 1.0625rem;
}

.btn-full {
    width: 100%;
    justify-content: center;
    padding: 14px 28px;
}

/* ============================================
   Badges
   ============================================ */
.badge {
    display: inline-block;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 6px 16px;
    border-radius: 50px;
    background: var(--green-100);
    color: var(--green-700);
}

.badge-green {
    background: var(--green-100);
    color: var(--green-700);
}

/* ============================================
   Section Header
   ============================================ */
.section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 60px;
}

.section-header .badge {
    margin-bottom: 16px;
}

.section-header h2 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    margin-bottom: 16px;
}

.section-header p {
    font-size: 1.0625rem;
    color: var(--gray-500);
    line-height: 1.7;
}

/* ============================================
   Header
   ============================================ */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(245, 247, 240, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(27,67,50,0.06);
    transition: all var(--transition);
}

.site-header.scrolled {
    box-shadow: var(--shadow-sm);
}

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

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 1.1875rem;
    color: var(--green-800);
}

.logo-icon {
    flex-shrink: 0;
}

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

.nav a:not(.btn) {
    padding: 8px 16px;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--gray-600);
    border-radius: var(--radius-md);
    transition: all var(--transition);
}

.nav a:not(.btn):hover {
    color: var(--green-700);
    background: var(--green-50);
}

/* Mobile toggle */
.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: var(--radius-sm);
}

.mobile-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--green-800);
    border-radius: 2px;
    transition: all var(--transition);
}

.mobile-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile menu */
.mobile-menu {
    display: none;
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(245, 247, 240, 0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 24px;
    flex-direction: column;
    gap: 8px;
    border-bottom: 1px solid rgba(27,67,50,0.08);
    box-shadow: var(--shadow-md);
    z-index: 999;
}

.mobile-menu.active {
    display: flex;
}

.mobile-menu a {
    padding: 12px 16px;
    font-size: 1rem;
    font-weight: 500;
    color: var(--gray-600);
    border-radius: var(--radius-md);
    transition: all var(--transition);
}

.mobile-menu a:hover {
    background: var(--green-50);
    color: var(--green-700);
}

.mobile-menu .btn {
    margin-top: 8px;
    justify-content: center;
}

/* ============================================
   Hero
   ============================================ */
.hero {
    padding-top: 72px;
    background: var(--off-white);
    overflow: hidden;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    padding: 60px 0 80px;
}

.hero-content {
    max-width: 540px;
}

.hero .badge {
    margin-bottom: 20px;
}

.hero h1 {
    font-size: clamp(2.5rem, 5.5vw, 4rem);
    color: var(--green-800);
    margin-bottom: 20px;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

.hero-desc {
    font-size: 1.125rem;
    color: var(--gray-500);
    line-height: 1.75;
    margin-bottom: 36px;
    max-width: 480px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 44px;
}

.hero-trust {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
}

.trust-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-600);
}

.trust-item svg {
    color: var(--green-500);
    flex-shrink: 0;
}

/* Hero image */
.hero-image {
    position: relative;
}

.hero-img-wrapper {
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    aspect-ratio: 580/700;
}

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

.hero-floating-card {
    position: absolute;
    bottom: 40px;
    left: -30px;
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 18px 24px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: var(--shadow-lg);
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.floating-icon {
    width: 48px;
    height: 48px;
    background: var(--green-100);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.floating-label {
    font-size: 0.8125rem;
    color: var(--gray-400);
    font-weight: 500;
}

.floating-value {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--green-800);
}

/* Hero wave */
.hero-wave {
    margin-top: -1px;
}

.hero-wave svg {
    display: block;
    width: 100%;
    height: 60px;
}

/* ============================================
   Services
   ============================================ */
.services {
    background: var(--off-white);
    padding: 80px 0;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.service-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 36px 28px;
    border: 1px solid var(--gray-200);
    transition: all var(--transition);
}

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

.service-icon {
    width: 56px;
    height: 56px;
    background: var(--green-100);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    transition: all var(--transition);
}

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

.service-card:hover .service-icon svg {
    stroke: var(--white);
}

.service-card h3 {
    font-family: 'DM Sans', sans-serif;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--green-800);
    margin-bottom: 10px;
}

.service-card p {
    font-size: 0.9375rem;
    color: var(--gray-500);
    line-height: 1.7;
}

/* ============================================
   About
   ============================================ */
.about {
    background: var(--cream);
    padding: 80px 0;
}

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

.about-images {
    position: relative;
}

.about-img-main {
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    aspect-ratio: 500/600;
}

.about-img-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.about-img-secondary {
    position: absolute;
    bottom: -30px;
    right: -20px;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    border: 4px solid var(--cream);
    aspect-ratio: 400/300;
    width: 55%;
}

.about-img-secondary img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.about-stats {
    position: absolute;
    top: -20px;
    right: 30px;
    display: flex;
    gap: 12px;
}

.stat {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    text-align: center;
    box-shadow: var(--shadow-md);
}

.stat-number {
    display: block;
    font-family: 'Playfair Display', serif;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--green-700);
}

.stat-label {
    font-size: 0.75rem;
    color: var(--gray-400);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.about-content .badge {
    margin-bottom: 16px;
}

.about-content h2 {
    font-size: clamp(1.75rem, 3.5vw, 2.25rem);
    margin-bottom: 20px;
}

.about-content > p {
    color: var(--gray-500);
    font-size: 1.0625rem;
    margin-bottom: 14px;
    line-height: 1.75;
}

.about-features {
    margin-top: 28px;
    display: grid;
    gap: 14px;
}

.about-feature {
    display: flex;
    align-items: center;
    gap: 14px;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--gray-600);
}

.feature-check {
    width: 28px;
    height: 28px;
    background: var(--green-100);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* ============================================
   Patient Info
   ============================================ */
.patient-info {
    background: var(--white);
    padding: 80px 0;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.info-card {
    background: var(--off-white);
    border-radius: var(--radius-lg);
    padding: 32px 24px;
    text-align: center;
    border: 1px solid var(--gray-200);
    transition: all var(--transition);
    position: relative;
    overflow: hidden;
}

.info-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--green-400);
    transform: scaleX(0);
    transition: transform var(--transition);
}

.info-card:hover::before {
    transform: scaleX(1);
}

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

.info-number {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--green-200);
    margin-bottom: 12px;
    line-height: 1;
}

.info-card h3 {
    font-family: 'DM Sans', sans-serif;
    font-size: 1.0625rem;
    font-weight: 700;
    color: var(--green-800);
    margin-bottom: 10px;
}

.info-card p {
    font-size: 0.875rem;
    color: var(--gray-500);
    line-height: 1.7;
}

/* ============================================
   CTA
   ============================================ */
.cta {
    background: var(--green-800);
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.cta::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(82,183,136,0.2) 0%, transparent 70%);
    border-radius: 50%;
}

.cta::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(116,198,157,0.15) 0%, transparent 70%);
    border-radius: 50%;
}

.cta-inner {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.cta-content h2 {
    font-size: clamp(1.75rem, 3.5vw, 2.5rem);
    color: var(--white);
    margin-bottom: 14px;
}

.cta-content p {
    font-size: 1.0625rem;
    color: var(--green-300);
    max-width: 480px;
    line-height: 1.7;
}

.cta-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    flex-shrink: 0;
}

/* ============================================
   Contact
   ============================================ */
.contact {
    background: var(--off-white);
    padding: 80px 0;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.contact-info .badge {
    margin-bottom: 16px;
}

.contact-info h2 {
    font-size: clamp(1.75rem, 3.5vw, 2.25rem);
    margin-bottom: 14px;
}

.contact-info > p {
    color: var(--gray-500);
    font-size: 1.0625rem;
    margin-bottom: 36px;
    line-height: 1.75;
}

.contact-details {
    display: grid;
    gap: 24px;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.contact-icon {
    width: 48px;
    height: 48px;
    background: var(--green-100);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.contact-item strong {
    display: block;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--green-800);
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.contact-item span,
.contact-item a {
    font-size: 0.9375rem;
    color: var(--gray-500);
    line-height: 1.6;
}

.contact-item a:hover {
    color: var(--green-700);
}

/* Contact form */
.contact-form-wrap {
    background: var(--white);
    border-radius: var(--radius-xl);
    padding: 40px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--gray-200);
}

.contact-form h3 {
    font-size: 1.5rem;
    margin-bottom: 6px;
}

.form-note {
    font-size: 0.875rem;
    color: var(--gray-400);
    margin-bottom: 28px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

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

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 6px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid var(--gray-200);
    border-radius: var(--radius-md);
    font-family: 'DM Sans', sans-serif;
    font-size: 0.9375rem;
    color: var(--gray-700);
    background: var(--off-white);
    transition: all var(--transition);
    outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--green-500);
    background: var(--white);
    box-shadow: 0 0 0 3px rgba(82,183,136,0.15);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--gray-300);
}

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

.form-success {
    display: none;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    background: var(--green-50);
    border: 1px solid var(--green-200);
    border-radius: var(--radius-md);
    color: var(--green-700);
    font-weight: 600;
    font-size: 0.9375rem;
    margin-top: 16px;
}

.form-success.show {
    display: flex;
}

/* ============================================
   Footer
   ============================================ */
.footer {
    background: var(--green-900);
    color: var(--green-300);
    padding: 60px 0 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 40px;
    padding-bottom: 48px;
}

.footer-brand p {
    margin-top: 16px;
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--green-400);
    max-width: 280px;
}

.footer-links h4,
.footer-contact h4 {
    font-family: 'DM Sans', sans-serif;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--green-200);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 18px;
}

.footer-links a {
    display: block;
    padding: 5px 0;
    font-size: 0.9375rem;
    color: var(--green-400);
    transition: all var(--transition);
}

.footer-links a:hover {
    color: var(--white);
    padding-left: 6px;
}

.footer-contact p {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.875rem;
    color: var(--green-400);
    margin-bottom: 10px;
    line-height: 1.6;
}

.footer-contact a:hover {
    color: var(--white);
}

.footer-bottom {
    border-top: 1px solid rgba(149,213,178,0.15);
    padding: 24px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.footer-bottom p {
    font-size: 0.8125rem;
    color: var(--green-500);
}

.footer-bottom a {
    color: var(--green-400);
}

.footer-bottom a:hover {
    color: var(--white);
}

/* ============================================
   Scroll reveal (progressive enhancement)
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
        transition: opacity 0.6s ease, transform 0.6s ease;
    }

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

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 1024px) {
    .hero-grid {
        gap: 40px;
    }

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

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

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }
}

@media (max-width: 768px) {
    .nav {
        display: none;
    }

    .mobile-toggle {
        display: flex;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        padding: 40px 0 60px;
        gap: 40px;
    }

    .hero-content {
        max-width: 100%;
        text-align: center;
    }

    .hero-desc {
        max-width: 100%;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-trust {
        justify-content: center;
    }

    .hero-image {
        max-width: 480px;
        margin: 0 auto;
    }

    .hero-floating-card {
        left: 10px;
        bottom: 20px;
    }

    .hero-wave svg {
        height: 40px;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .about-grid {
        grid-template-columns: 1fr;
        gap: 60px;
    }

    .about-images {
        max-width: 480px;
        margin: 0 auto;
    }

    .info-grid {
        grid-template-columns: 1fr;
        max-width: 480px;
        margin: 0 auto;
    }

    .cta-inner {
        flex-direction: column;
        text-align: center;
    }

    .cta-actions {
        justify-content: center;
    }

    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .contact-form-wrap {
        padding: 28px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 18px;
    }

    .hero h1 {
        font-size: 2.25rem;
    }

    .hero-actions {
        flex-direction: column;
        width: 100%;
    }

    .hero-actions .btn {
        width: 100%;
        justify-content: center;
    }

    .about-img-secondary {
        right: -10px;
        bottom: -20px;
    }

    .about-stats {
        right: 10px;
    }
}
