/* ========================================
   Dr. Luis Lopez Medical Website
   Classic & Elegant Design
======================================== */

/* CSS Custom Properties */
:root {
    --emerald-900: #064e3b;
    --emerald-800: #065f46;
    --emerald-700: #047857;
    --emerald-600: #059669;
    --emerald-500: #10b981;
    --emerald-100: #d1fae5;
    --emerald-50: #ecfdf5;
    
    --cream-50: #fafaf9;
    --cream-100: #f5f5f4;
    --cream-200: #e7e5e4;
    --cream-300: #d6d3d1;
    --cream-400: #a8a29e;
    
    --stone-900: #0c0a09;
    --stone-800: #1c1917;
    --stone-700: #292524;
    --stone-600: #44403c;
    --stone-500: #57534e;
    --stone-400: #78716c;
    --stone-300: #a8a29e;
    --stone-200: #e7e5e4;
    --stone-100: #f5f5f4;
    --stone-50: #fafaf9;
    
    --font-serif: 'Cormorant Garamond', Georgia, serif;
    --font-sans: 'Lato', -apple-system, BlinkMacSystemFont, sans-serif;
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
}

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

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

body {
    font-family: var(--font-sans);
    color: var(--stone-800);
    background-color: var(--cream-50);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
}

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

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-serif);
    font-weight: 500;
    line-height: 1.2;
    color: var(--stone-900);
}

.section-eyebrow {
    font-family: var(--font-sans);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--emerald-700);
    margin-bottom: 0.75rem;
}

.section-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 1.5rem;
    color: var(--stone-900);
}

.text-emerald {
    color: var(--emerald-700);
}

.section-text {
    font-size: 1.125rem;
    color: var(--stone-600);
    line-height: 1.75;
    margin-bottom: 1rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    font-family: var(--font-sans);
    font-size: 0.9375rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    transition: all 0.3s ease;
    text-align: center;
}

.btn-emerald {
    background-color: var(--emerald-700);
    color: white;
    border: 2px solid var(--emerald-700);
}

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

.btn-outline {
    background-color: transparent;
    color: var(--stone-800);
    border: 2px solid var(--stone-300);
}

.btn-outline:hover {
    border-color: var(--emerald-700);
    color: var(--emerald-700);
    transform: translateY(-2px);
}

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

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

/* Header */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: rgba(250, 250, 249, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--cream-200);
    transition: box-shadow 0.3s ease;
}

.main-header.scrolled {
    box-shadow: var(--shadow-md);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-icon {
    color: var(--emerald-700);
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-name {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--stone-900);
    line-height: 1.2;
}

.logo-tagline {
    font-size: 0.6875rem;
    color: var(--stone-500);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.main-nav ul {
    display: flex;
    align-items: center;
    gap: 2rem;
    list-style: none;
}

.main-nav a {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--stone-600);
}

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

.mobile-menu-btn {
    display: none;
    color: var(--stone-700);
    padding: 0.5rem;
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 0 80px;
    background-color: var(--cream-50);
    overflow: hidden;
}

.hero-bg-pattern {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(5, 150, 105, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(5, 150, 105, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 60% 80%, rgba(5, 150, 105, 0.06) 0%, transparent 45%);
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    margin-bottom: 3rem;
}

.hero-text {
    max-width: 650px;
}

.hero-eyebrow {
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--emerald-700);
    margin-bottom: 1rem;
}

.hero-headline {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 500;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--stone-900);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--stone-600);
    line-height: 1.75;
    margin-bottom: 2.5rem;
    max-width: 550px;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Floating Stat Cards */
.hero-stats {
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 1rem;
    z-index: 2;
}

.stat-card {
    background-color: white;
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 200px;
    border: 1px solid var(--cream-200);
}

.stat-icon {
    width: 48px;
    height: 48px;
    background-color: var(--emerald-50);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--emerald-700);
    flex-shrink: 0;
}

.stat-number {
    font-family: var(--font-serif);
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--stone-900);
    line-height: 1;
}

.stat-label {
    font-size: 0.8125rem;
    color: var(--stone-500);
    margin-top: 0.25rem;
}

/* About Section */
.about {
    padding: 100px 0;
    background-color: white;
}

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

.about-image {
    position: relative;
}

.about-image img {
    width: 100%;
    height: 700px;
    object-fit: cover;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
}

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

.about-content {
    padding: 2rem 0;
}

.about-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 2rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--stone-700);
}

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

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

.section-header {
    text-align: center;
    max-width: 650px;
    margin: 0 auto 4rem;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--stone-600);
    line-height: 1.75;
}

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

.service-card {
    background-color: white;
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--cream-200);
    transition: all 0.3s ease;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--emerald-200);
}

.service-icon {
    width: 64px;
    height: 64px;
    background-color: var(--emerald-50);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--emerald-700);
    margin-bottom: 1.5rem;
}

.service-card h3 {
    font-size: 1.375rem;
    margin-bottom: 0.75rem;
    color: var(--stone-900);
}

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

/* Contact Section */
.contact {
    padding: 100px 0 60px;
    background-color: white;
}

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

.contact-details {
    margin-top: 3rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-item {
    display: flex;
    gap: 1.25rem;
}

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

.contact-item strong {
    display: block;
    font-size: 1rem;
    color: var(--stone-900);
    margin-bottom: 0.25rem;
}

.contact-item p {
    font-size: 0.9375rem;
    color: var(--stone-600);
    line-height: 1.6;
}

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

.contact-item a:hover {
    text-decoration: underline;
}

/* Contact Form */
.contact-form-wrapper {
    background-color: var(--cream-50);
    padding: 2.5rem;
    border-radius: var(--radius-xl);
    border: 1px solid var(--cream-200);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--stone-700);
}

.form-group input,
.form-group textarea {
    padding: 0.875rem 1rem;
    border: 1px solid var(--cream-300);
    border-radius: var(--radius-md);
    font-family: var(--font-sans);
    font-size: 1rem;
    color: var(--stone-800);
    background-color: white;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

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

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

.form-success {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 3rem 2rem;
    gap: 1rem;
}

.form-success svg {
    color: var(--emerald-600);
}

.form-success h3 {
    font-size: 1.5rem;
    color: var(--stone-900);
}

.form-success p {
    font-size: 1rem;
    color: var(--stone-600);
}

/* Map */
.map-container {
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.map-container iframe {
    display: block;
}

/* Footer */
.footer {
    background-color: var(--stone-900);
    color: var(--stone-300);
    padding: 80px 0 40px;
}

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

.footer-logo .logo-name {
    color: white;
}

.footer-logo .logo-tagline {
    color: var(--stone-400);
}

.footer-text {
    margin-top: 1rem;
    font-size: 0.9375rem;
    line-height: 1.75;
    color: var(--stone-400);
    max-width: 300px;
}

.footer-links h4,
.footer-contact h4 {
    font-family: var(--font-sans);
    font-size: 0.875rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: white;
    margin-bottom: 1.25rem;
}

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

.footer-links a {
    font-size: 0.9375rem;
    color: var(--stone-400);
}

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

.footer-contact p {
    font-size: 0.9375rem;
    margin-bottom: 0.5rem;
}

.footer-contact a {
    color: var(--emerald-400);
}

.footer-contact a:hover {
    text-decoration: underline;
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid var(--stone-800);
    text-align: center;
    font-size: 0.875rem;
    color: var(--stone-500);
}

/* Mobile Menu */
.mobile-menu {
    display: none;
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    background-color: white;
    border-bottom: 1px solid var(--cream-200);
    padding: 1.5rem;
    box-shadow: var(--shadow-lg);
    z-index: 999;
}

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

.mobile-menu ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.mobile-menu a {
    display: block;
    padding: 0.75rem 0;
    font-size: 1rem;
    font-weight: 500;
    color: var(--stone-700);
    border-bottom: 1px solid var(--cream-200);
}

.mobile-menu a:last-child {
    border-bottom: none;
}

/* Responsive */
@media (max-width: 1024px) {
    .hero-stats {
        position: relative;
        right: auto;
        top: auto;
        transform: none;
        flex-direction: row;
        justify-content: center;
        margin-top: 4rem;
    }
    
    .stat-card {
        min-width: auto;
    }
    
    .about-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .about-image img {
        height: 500px;
    }
    
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 3rem;
    }
}

@media (max-width: 768px) {
    .main-nav {
        display: none;
    }
    
    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .hero {
        padding: 100px 0 60px;
        min-height: auto;
    }
    
    .hero-headline {
        font-size: clamp(2rem, 8vw, 3rem);
    }
    
    .hero-stats {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .stat-card {
        width: 100%;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .about-features {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

@media (max-width: 480px) {
    .hero-actions {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .contact-form-wrapper {
        padding: 1.5rem;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}
