/* ============================================
   Dr. Glenn L. Dominguez — Medical Website
   Clean Minimalist · Emerald + Cream
   ============================================ */

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

:root {
    --emerald-950: #042f2e;
    --emerald-900: #064e3b;
    --emerald-800: #065f46;
    --emerald-700: #047857;
    --emerald-600: #059669;
    --emerald-500: #10b981;
    --cream-50: #fafaf5;
    --cream-100: #f5f5ee;
    --cream-200: #e8e8dc;
    --cream-300: #d4d4c4;
    --text-primary: #1a2e28;
    --text-secondary: #4a5e56;
    --text-muted: #6b7f76;
    --white: #ffffff;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-display: 'Playfair Display', Georgia, serif;
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: var(--font-body);
    font-weight: 300;
    color: var(--text-primary);
    background-color: var(--cream-50);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

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

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

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

/* --- Navigation --- */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(250, 250, 245, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--cream-200);
    transition: box-shadow 0.4s var(--ease-smooth);
}

.nav.scrolled {
    box-shadow: 0 1px 20px rgba(4, 47, 46, 0.06);
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.nav-logo-mark {
    width: 40px;
    height: 40px;
    background: var(--emerald-800);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.02em;
    border-radius: 10px;
}

.nav-logo-text {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: 15px;
    color: var(--text-primary);
    letter-spacing: -0.01em;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
    list-style: none;
}

.nav-links a {
    font-size: 14px;
    font-weight: 400;
    color: var(--text-secondary);
    letter-spacing: 0.01em;
    transition: color 0.25s var(--ease-smooth);
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--emerald-600);
    transition: width 0.3s var(--ease-out);
}

.nav-links a:hover {
    color: var(--emerald-700);
}

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

.nav-cta {
    background: var(--emerald-800) !important;
    color: var(--white) !important;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 500 !important;
    font-size: 13px !important;
    letter-spacing: 0.02em !important;
    transition: background 0.25s var(--ease-smooth), transform 0.2s var(--ease-smooth) !important;
}

.nav-cta::after {
    display: none !important;
}

.nav-cta:hover {
    background: var(--emerald-900) !important;
    transform: translateY(-1px);
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--text-primary);
}

/* --- Hero --- */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    overflow: hidden;
    background: var(--emerald-950);
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.35;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(4, 47, 46, 0.92) 0%,
        rgba(6, 78, 59, 0.85) 40%,
        rgba(4, 47, 46, 0.78) 100%
    );
}

.hero-cream-block {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 45%;
    background: var(--cream-50);
    clip-path: polygon(15% 0, 100% 0, 100% 100%, 0% 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
    padding: 120px 24px 80px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    width: 100%;
}

.hero-main-card {
    background: rgba(255, 255, 255, 0.07);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 24px;
    padding: 48px;
    color: var(--white);
    max-width: 520px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 24px;
    padding: 8px 16px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 100px;
}

.hero-headline {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 5vw, 3.75rem);
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
    color: var(--white);
}

.hero-subtitle {
    font-size: 16px;
    line-height: 1.75;
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: 36px;
    font-weight: 300;
    max-width: 420px;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: all 0.3s var(--ease-smooth);
    border: none;
    font-family: var(--font-body);
}

.btn-primary {
    background: var(--emerald-600);
    color: var(--white);
    box-shadow: 0 4px 20px rgba(5, 150, 105, 0.3);
}

.btn-primary:hover {
    background: var(--emerald-500);
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(5, 150, 105, 0.35);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
}

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

/* Hero Stats */
.hero-stats {
    display: flex;
    flex-direction: column;
    gap: 16px;
    justify-content: center;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px 28px;
    border-radius: 16px;
    border: 1px solid var(--cream-200);
    transition: transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}

.stat-card:hover {
    transform: translateX(6px);
    box-shadow: 0 8px 32px rgba(4, 47, 46, 0.08);
}

.stat-card--cream {
    background: var(--white);
}

.stat-card--emerald {
    background: var(--emerald-800);
    border-color: var(--emerald-800);
    color: var(--white);
}

.stat-card--emerald .stat-label {
    color: rgba(255, 255, 255, 0.7);
}

.stat-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    flex-shrink: 0;
}

.stat-card--cream .stat-icon {
    background: var(--cream-100);
    color: var(--emerald-700);
}

.stat-card--emerald .stat-icon {
    background: rgba(255, 255, 255, 0.12);
    color: var(--white);
}

.stat-number {
    font-family: var(--font-display);
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.2;
}

.stat-card--emerald .stat-number {
    color: var(--white);
}

.stat-label {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 2px;
}

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

.section-tag {
    display: inline-block;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--emerald-700);
    margin-bottom: 16px;
    padding: 6px 14px;
    border: 1px solid var(--emerald-200, #a7f3d0);
    background: rgba(16, 185, 129, 0.06);
    border-radius: 100px;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 2.75rem);
    font-weight: 600;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.section-desc {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.75;
    font-weight: 300;
}

/* --- Services --- */
.services {
    padding: 120px 0;
    background: var(--cream-50);
}

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

.service-card {
    background: var(--white);
    border: 1px solid var(--cream-200);
    border-radius: 20px;
    padding: 40px 32px;
    transition: all 0.35s var(--ease-out);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--emerald-600);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.35s var(--ease-out);
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(4, 47, 46, 0.08);
    border-color: transparent;
}

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

.service-card-icon {
    width: 56px;
    height: 56px;
    background: var(--cream-100);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--emerald-700);
    margin-bottom: 24px;
    transition: background 0.3s var(--ease-smooth);
}

.service-card:hover .service-card-icon {
    background: var(--emerald-800);
    color: var(--white);
}

.service-card h3 {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
    letter-spacing: -0.01em;
}

.service-card p {
    font-size: 14px;
    line-height: 1.75;
    color: var(--text-secondary);
    font-weight: 300;
}

/* --- About --- */
.about {
    padding: 120px 0;
    background: var(--white);
}

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

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

.about-image {
    width: 100%;
    height: 750px;
    object-fit: cover;
    border-radius: 24px;
    box-shadow: 0 24px 64px rgba(4, 47, 46, 0.12);
}

.about-image-accent {
    position: absolute;
    bottom: -20px;
    right: -20px;
    width: 200px;
    height: 200px;
    background: var(--cream-200);
    border-radius: 20px;
    z-index: -1;
}

.about-content {
    max-width: 520px;
}

.about-body {
    font-size: 15px;
    line-height: 1.8;
    color: var(--text-secondary);
    margin-bottom: 20px;
    font-weight: 300;
}

.about-values {
    margin-top: 36px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.value-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    font-weight: 400;
    color: var(--text-primary);
}

.value-item svg {
    color: var(--emerald-600);
    flex-shrink: 0;
}

/* --- Approach --- */
.approach {
    padding: 120px 0;
    background: var(--emerald-950);
    position: relative;
    overflow: hidden;
}

.approach::before {
    content: '';
    position: absolute;
    top: -200px;
    right: -200px;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.08) 0%, transparent 70%);
    pointer-events: none;
}

.approach .section-tag {
    color: rgba(255, 255, 255, 0.6);
    border-color: rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.06);
}

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

.approach-steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    position: relative;
}

.approach-steps::before {
    content: '';
    position: absolute;
    top: 36px;
    left: calc(16.66% + 20px);
    right: calc(16.66% + 20px);
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
}

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

.step-number {
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.08);
    line-height: 1;
    margin-bottom: 20px;
}

.approach-step h3 {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--white);
    margin-bottom: 12px;
    letter-spacing: -0.01em;
}

.approach-step p {
    font-size: 14px;
    line-height: 1.75;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 300;
    max-width: 280px;
    margin: 0 auto;
}

.approach-step a {
    color: var(--emerald-400, #34d399);
    text-decoration: underline;
    text-underline-offset: 3px;
    transition: color 0.2s;
}

.approach-step a:hover {
    color: var(--white);
}

/* --- Contact --- */
.contact {
    padding: 120px 0 80px;
    background: var(--cream-50);
}

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

.contact-info {
    max-width: 440px;
}

.contact-desc {
    font-size: 15px;
    line-height: 1.75;
    color: var(--text-secondary);
    margin-bottom: 40px;
    font-weight: 300;
}

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

.contact-detail {
    display: flex;
    gap: 20px;
}

.contact-detail-icon {
    width: 48px;
    height: 48px;
    background: var(--white);
    border: 1px solid var(--cream-200);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--emerald-700);
    flex-shrink: 0;
}

.contact-detail strong {
    display: block;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.contact-detail p {
    font-size: 15px;
    color: var(--text-primary);
    line-height: 1.6;
    font-weight: 400;
}

.contact-detail a {
    color: var(--emerald-700);
    transition: color 0.2s;
}

.contact-detail a:hover {
    color: var(--emerald-600);
    text-decoration: underline;
}

/* Contact Form */
.contact-form-wrapper {
    max-width: 520px;
}

.contact-form-card {
    background: var(--white);
    border: 1px solid var(--cream-200);
    border-radius: 24px;
    padding: 48px;
}

.contact-form-card h3 {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    letter-spacing: -0.01em;
}

.form-note {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 32px;
    font-weight: 300;
}

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

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

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 8px;
    letter-spacing: 0.02em;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--cream-300);
    border-radius: 10px;
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 300;
    color: var(--text-primary);
    background: var(--cream-50);
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--emerald-500);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
    background: var(--white);
}

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

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

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

.form-success svg {
    color: var(--emerald-600);
    margin-bottom: 16px;
}

.form-success h4 {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.form-success p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.7;
    font-weight: 300;
}

/* Map */
.map-wrapper {
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--cream-200);
    box-shadow: 0 8px 32px rgba(4, 47, 46, 0.06);
}

/* --- Footer --- */
.footer {
    background: var(--emerald-950);
    color: var(--white);
    padding: 64px 0 32px;
}

.footer-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 16px;
}

.footer-logo-mark {
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 14px;
    border-radius: 12px;
}

.footer-brand strong {
    display: block;
    font-size: 15px;
    font-weight: 500;
    letter-spacing: -0.01em;
}

.footer-brand p {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 2px;
    font-weight: 300;
}

.footer-nav {
    display: flex;
    gap: 32px;
    list-style: none;
}

.footer-nav a {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    transition: color 0.2s;
    font-weight: 300;
}

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

.footer-phone {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    transition: color 0.2s;
    font-weight: 400;
}

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

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 32px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.35);
    font-weight: 300;
}

/* --- Reveal Animations --- */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

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

/* Default state: visible (progressive enhancement) */
.reveal[data-reveal] {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: no-preference) {
    .reveal[data-reveal] {
        opacity: 0;
        transform: translateY(24px);
    }
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Responsive --- */
@media (max-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .hero-cream-block {
        width: 35%;
        opacity: 0.9;
    }
    
    .hero-stats {
        flex-direction: row;
        flex-wrap: wrap;
    }
    
    .stat-card {
        flex: 1;
        min-width: 200px;
    }
    
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .about-layout {
        grid-template-columns: 1fr;
        gap: 48px;
    }
    
    .about-image {
        height: 500px;
        max-width: 480px;
    }
    
    .contact-layout {
        grid-template-columns: 1fr;
        gap: 48px;
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 72px;
        left: 0;
        right: 0;
        background: rgba(250, 250, 245, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 32px 24px;
        gap: 24px;
        border-bottom: 1px solid var(--cream-200);
        transform: translateY(-120%);
        opacity: 0;
        transition: transform 0.4s var(--ease-out), opacity 0.3s var(--ease-smooth);
        pointer-events: none;
    }
    
    .nav-links.open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
    }
    
    .nav-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .hero {
        min-height: auto;
        padding: 120px 0 80px;
    }
    
    .hero-cream-block {
        display: none;
    }
    
    .hero-content {
        padding: 0 24px;
    }
    
    .hero-main-card {
        padding: 32px;
    }
    
    .hero-stats {
        flex-direction: column;
        padding: 0 24px;
    }
    
    .stat-card {
        flex: none;
    }
    
    .services {
        padding: 80px 0;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .about {
        padding: 80px 0;
    }
    
    .about-image {
        height: 400px;
    }
    
    .about-image-accent {
        display: none;
    }
    
    .about-values {
        grid-template-columns: 1fr;
    }
    
    .approach {
        padding: 80px 0;
    }
    
    .approach-steps {
        grid-template-columns: 1fr;
        gap: 48px;
    }
    
    .approach-steps::before {
        display: none;
    }
    
    .contact {
        padding: 80px 0 60px;
    }
    
    .contact-form-card {
        padding: 32px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .footer-top {
        flex-direction: column;
        align-items: flex-start;
        gap: 24px;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero-main-card {
        padding: 24px;
    }
    
    .hero-headline {
        font-size: 2rem;
    }
    
    .hero-actions {
        flex-direction: column;
    }
    
    .btn {
        justify-content: center;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
}
