/* ============================================
   Jeff Peppard Inc — Classic & Elegant Medical Site
   Palette: Terracotta + Sand
   Fonts: Cormorant Garamond + Lato
   ============================================ */

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

:root {
    --terra-950: #1a0f0a;
    --terra-900: #2d1810;
    --terra-800: #4a2518;
    --terra-700: #6b3424;
    --terra-600: #8b4529;
    --terra-500: #A0522D;
    --terra-400: #b8693f;
    --terra-300: #d4956e;
    --terra-200: #e8c4a8;
    --terra-100: #f5e0d0;
    --terra-50:  #faf3ed;
    
    --sand-950:  #1c1917;
    --sand-800:  #2e2a26;
    --sand-700:  #4a433d;
    --sand-600:  #6b6056;
    --sand-500:  #8e8074;
    --sand-400:  #b0a194;
    --sand-300:  #ccc4b8;
    --sand-200:  #e8e0d6;
    --sand-100:  #f5f0ea;
    --sand-50:   #faf8f5;
    
    --white:     #ffffff;
    --black:     #0f0d0b;
    
    --font-serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
    --font-sans:  'Lato', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    color: var(--sand-800);
    background-color: var(--sand-50);
    line-height: 1.7;
    overflow-x: hidden;
}

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

a {
    color: var(--terra-600);
    text-decoration: none;
    transition: color 0.3s var(--ease-out);
}

a:hover {
    color: var(--terra-500);
}

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

/* ---------- TYPOGRAPHY ---------- */
.section-eyebrow {
    font-family: var(--font-sans);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--terra-500);
    margin-bottom: 12px;
}

.section-title {
    font-family: var(--font-serif);
    font-size: clamp(2rem, 4vw, 3.25rem);
    font-weight: 500;
    line-height: 1.15;
    color: var(--terra-900);
    margin-bottom: 24px;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--sand-600);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

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

/* ---------- BUTTONS ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: var(--font-sans);
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 14px 32px;
    border-radius: 4px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.35s var(--ease-out);
    text-decoration: none;
}

.btn-primary {
    background-color: var(--terra-500);
    color: var(--white);
    border-color: var(--terra-500);
}

.btn-primary:hover {
    background-color: var(--terra-600);
    border-color: var(--terra-600);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(160, 82, 45, 0.3);
}

.btn-secondary {
    background-color: transparent;
    color: var(--white);
    border-color: rgba(255, 255, 255, 0.6);
}

.btn-secondary:hover {
    background-color: var(--white);
    color: var(--terra-800);
    border-color: var(--white);
    transform: translateY(-2px);
}

.btn-full {
    width: 100%;
}

/* ---------- HEADER ---------- */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: rgba(250, 248, 245, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--sand-200);
    transition: box-shadow 0.3s var(--ease-out);
}

.site-header.scrolled {
    box-shadow: 0 2px 20px rgba(45, 24, 16, 0.08);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--terra-900);
}

.logo-mark {
    font-family: var(--font-serif);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--terra-500);
    width: 40px;
    height: 40px;
    border: 2px solid var(--terra-500);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    letter-spacing: 0.05em;
}

.logo-text {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 500;
    letter-spacing: 0.02em;
}

.logo-sub {
    font-size: 0.85rem;
    color: var(--terra-500);
    font-weight: 400;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 8px;
}

.main-nav a {
    font-family: var(--font-sans);
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--sand-700);
    padding: 8px 16px;
    border-radius: 4px;
    transition: all 0.3s var(--ease-out);
}

.main-nav a:hover {
    color: var(--terra-600);
    background-color: var(--terra-50);
}

/* Mobile nav toggle */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.hamburger {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--terra-800);
    position: relative;
    transition: all 0.3s var(--ease-out);
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 2px;
    background-color: var(--terra-800);
    transition: all 0.3s var(--ease-out);
}

.hamburger::before { top: -7px; }
.hamburger::after { bottom: -7px; }

.nav-toggle[aria-expanded="true"] .hamburger {
    background-color: transparent;
}

.nav-toggle[aria-expanded="true"] .hamburger::before {
    top: 0;
    transform: rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .hamburger::after {
    bottom: 0;
    transform: rotate(-45deg);
}

/* ---------- HERO ---------- */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--terra-900);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background-image: url('https://images.pexels.com/photos/16051950/pexels-photo-16051950.jpeg?auto=compress&cs=tinysrgb&fit=crop&w=1920&h=1080');
    background-size: cover;
    background-position: center;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(26, 15, 10, 0.82) 0%,
        rgba(45, 24, 16, 0.72) 50%,
        rgba(74, 37, 24, 0.65) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    padding: 120px 24px 80px;
}

.hero-eyebrow {
    font-family: var(--font-sans);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--terra-200);
    margin-bottom: 24px;
}

.hero-headline {
    font-family: var(--font-serif);
    font-size: clamp(2.75rem, 7vw, 5.5rem);
    font-weight: 500;
    line-height: 1.05;
    color: var(--white);
    margin-bottom: 28px;
    letter-spacing: -0.01em;
}

.hero-subheadline {
    font-size: clamp(1rem, 1.5vw, 1.2rem);
    color: var(--terra-200);
    line-height: 1.8;
    max-width: 600px;
    margin: 0 auto 44px;
    font-weight: 300;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-scroll {
    position: absolute;
    bottom: 36px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--terra-300);
    font-size: 0.6875rem;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    opacity: 0.7;
    animation: float 2.5s ease-in-out infinite;
}

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

/* ---------- ABOUT ---------- */
.about {
    padding: 120px 0;
    background-color: var(--sand-50);
}

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

.about-image-wrapper {
    position: relative;
}

.about-image-wrapper img {
    width: 100%;
    height: 700px;
    object-fit: cover;
    border-radius: 6px;
    box-shadow: 0 24px 64px rgba(45, 24, 16, 0.15);
}

.about-accent {
    position: absolute;
    bottom: -20px;
    right: -20px;
    width: 200px;
    height: 200px;
    border: 3px solid var(--terra-300);
    border-radius: 6px;
    z-index: -1;
}

.about-content .section-title {
    margin-top: 0;
}

.about-content p {
    color: var(--sand-600);
    font-size: 1.05rem;
    line-height: 1.85;
    margin-bottom: 20px;
}

.about-values {
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.value-item {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.value-item svg {
    flex-shrink: 0;
    color: var(--terra-500);
    margin-top: 2px;
}

.value-item h4 {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--terra-900);
    margin-bottom: 4px;
}

.value-item p {
    font-size: 0.95rem;
    color: var(--sand-600);
    margin-bottom: 0;
    line-height: 1.7;
}

/* ---------- SERVICES ---------- */
.services {
    padding: 120px 0;
    background-color: var(--terra-50);
}

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

.service-card {
    background-color: var(--white);
    border-radius: 6px;
    padding: 40px 32px;
    border: 1px solid var(--sand-200);
    transition: all 0.4s var(--ease-out);
}

.service-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 48px rgba(45, 24, 16, 0.1);
    border-color: var(--terra-200);
}

.service-icon {
    width: 56px;
    height: 56px;
    border-radius: 4px;
    background-color: var(--terra-50);
    border: 1px solid var(--terra-200);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--terra-600);
    margin-bottom: 24px;
    transition: all 0.35s var(--ease-out);
}

.service-card:hover .service-icon {
    background-color: var(--terra-500);
    border-color: var(--terra-500);
    color: var(--white);
}

.service-card h3 {
    font-family: var(--font-serif);
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--terra-900);
    margin-bottom: 12px;
}

.service-card p {
    font-size: 0.95rem;
    color: var(--sand-600);
    line-height: 1.75;
}

/* ---------- COMMUNITY ---------- */
.community {
    padding: 120px 0;
    background-color: var(--white);
}

.community .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
}

.community-text {
    font-size: 1.05rem;
    color: var(--sand-600);
    line-height: 1.85;
    margin-bottom: 20px;
}

.community-stats {
    margin-top: 48px;
    display: flex;
    align-items: center;
    gap: 32px;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-family: var(--font-serif);
    font-size: 2.75rem;
    font-weight: 600;
    color: var(--terra-500);
    line-height: 1;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--sand-500);
}

.stat-divider {
    width: 1px;
    height: 48px;
    background-color: var(--sand-300);
}

.community-image img {
    width: 100%;
    height: 650px;
    object-fit: cover;
    border-radius: 6px;
    box-shadow: 0 24px 64px rgba(45, 24, 16, 0.12);
}

/* ---------- CONTACT ---------- */
.contact {
    padding: 120px 0;
    background-color: var(--terra-900);
}

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

.contact .section-title {
    color: var(--white);
}

.contact .section-eyebrow {
    color: var(--terra-300);
}

.contact-intro {
    font-size: 1.05rem;
    color: var(--terra-200);
    line-height: 1.8;
    margin-bottom: 40px;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

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

.contact-icon {
    width: 44px;
    height: 44px;
    border-radius: 4px;
    background-color: rgba(160, 82, 45, 0.2);
    border: 1px solid rgba(160, 82, 45, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--terra-300);
    flex-shrink: 0;
}

.contact-item h4 {
    font-family: var(--font-serif);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--white);
    margin-bottom: 4px;
}

.contact-item p {
    font-size: 0.95rem;
    color: var(--terra-200);
    line-height: 1.7;
}

.contact-item a {
    color: var(--terra-300);
}

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

/* Form */
.contact-form-wrapper {
    background-color: var(--white);
    border-radius: 6px;
    padding: 44px;
}

.contact-form .form-group {
    margin-bottom: 24px;
}

.contact-form label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--sand-700);
    margin-bottom: 8px;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 14px 16px;
    font-family: var(--font-sans);
    font-size: 1rem;
    color: var(--sand-800);
    background-color: var(--sand-50);
    border: 1.5px solid var(--sand-200);
    border-radius: 4px;
    transition: all 0.3s var(--ease-out);
    outline: none;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: var(--sand-400);
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--terra-400);
    background-color: var(--white);
    box-shadow: 0 0 0 3px rgba(160, 82, 45, 0.1);
}

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

.form-note {
    font-size: 0.8125rem;
    color: var(--sand-500);
    text-align: center;
    margin-top: 16px;
}

.form-success {
    text-align: center;
    padding: 44px 20px;
}

.form-success svg {
    color: var(--terra-500);
    margin: 0 auto 20px;
}

.form-success h3 {
    font-family: var(--font-serif);
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--terra-900);
    margin-bottom: 12px;
}

.form-success p {
    font-size: 1rem;
    color: var(--sand-600);
    line-height: 1.7;
}

/* ---------- FOOTER ---------- */
.site-footer {
    background-color: var(--terra-950);
}

.footer-map iframe {
    filter: grayscale(0.5) contrast(1.1);
    opacity: 0.85;
}

.footer-inner {
    padding: 64px 24px;
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr;
    gap: 48px;
}

.footer-brand .logo-mark {
    margin-bottom: 12px;
}

.footer-brand .logo-text {
    font-size: 1.5rem;
    color: var(--white);
    display: block;
    margin-bottom: 16px;
}

.footer-brand p {
    font-size: 0.95rem;
    color: var(--terra-300);
    line-height: 1.7;
    max-width: 300px;
}

.footer-links h4,
.footer-contact h4 {
    font-family: var(--font-serif);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--white);
    margin-bottom: 20px;
}

.footer-links ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a {
    font-size: 0.95rem;
    color: var(--terra-300);
}

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

.footer-contact p {
    font-size: 0.95rem;
    color: var(--terra-300);
    line-height: 1.7;
    margin-bottom: 8px;
}

.footer-contact a {
    color: var(--terra-300);
}

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

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 24px;
}

.footer-bottom-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

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

/* ---------- SCROLL REVEAL (progressive enhancement) ---------- */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
        transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
    }
    
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1024px) {
    .about-grid,
    .community .container,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }
    
    .about-image-wrapper img,
    .community-image img {
        height: 480px;
    }
    
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-inner {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: block;
    }
    
    .main-nav {
        position: fixed;
        top: 76px;
        left: 0;
        right: 0;
        background-color: rgba(250, 248, 245, 0.98);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        border-bottom: 1px solid var(--sand-200);
        padding: 24px;
        transform: translateY(-110%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.4s var(--ease-out);
    }
    
    .main-nav.open {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .main-nav ul {
        flex-direction: column;
        gap: 4px;
    }
    
    .main-nav a {
        display: block;
        padding: 14px 16px;
        font-size: 0.9rem;
    }
    
    .hero-headline {
        font-size: clamp(2.25rem, 10vw, 3.5rem);
    }
    
    .hero-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 100%;
        max-width: 280px;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .community-stats {
        flex-direction: column;
        gap: 24px;
    }
    
    .stat-divider {
        width: 48px;
        height: 1px;
    }
    
    .contact-form-wrapper {
        padding: 28px;
    }
    
    .footer-inner {
        grid-template-columns: 1fr;
        gap: 36px;
    }
    
    .footer-bottom-inner {
        flex-direction: column;
        text-align: center;
    }
    
    .about-accent {
        display: none;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }
    
    .about,
    .services,
    .community,
    .contact {
        padding: 80px 0;
    }
    
    .hero-content {
        padding: 100px 16px 60px;
    }
}
