/* =====================================================
   Vallarta Medical Center - Unique Stylesheet
   Domain: vallartamedicalcenter.mx
   Professional Healthcare Design
   ===================================================== */

:root {
    --primary: #0a4d68;
    --primary-dark: #063447;
    --primary-light: #088395;
    --secondary: #05bfdb;
    --accent: #00ffca;
    --success: #28a745;
    --danger: #dc3545;
    --warning: #ffc107;
    --dark: #1a1a2e;
    --gray-100: #f8f9fa;
    --gray-200: #e9ecef;
    --gray-300: #dee2e6;
    --gray-600: #6c757d;
    --gray-800: #343a40;
    --white: #ffffff;
    --shadow: 0 4px 20px rgba(10, 77, 104, 0.1);
    --shadow-lg: 0 10px 40px rgba(10, 77, 104, 0.15);
    --radius: 12px;
    --transition: all 0.3s ease;
    --font: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: var(--font);
    line-height: 1.6;
    color: var(--gray-800);
    background: var(--white);
    overflow-x: hidden;
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--primary-light); }

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

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

/* ========== TOP BAR ========== */
.top-bar {
    background: var(--primary-dark);
    color: var(--white);
    font-size: 0.875rem;
    padding: 8px 0;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.top-info a {
    color: rgba(255,255,255,0.9);
    margin-right: 20px;
}

.top-info a:hover { color: var(--accent); }

.top-info i { margin-right: 6px; color: var(--secondary); }

.top-social a {
    color: rgba(255,255,255,0.8);
    margin-left: 12px;
    font-size: 1rem;
}

.top-social a:hover { color: var(--accent); }

/* ========== HEADER ========== */
.main-header {
    background: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    gap: 20px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--primary);
}

.logo:hover { color: var(--primary); }

.logo-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.4rem;
}

.logo-name {
    display: block;
    font-weight: 700;
    font-size: 1.15rem;
    line-height: 1.2;
}

.logo-sub {
    display: block;
    font-size: 0.7rem;
    color: var(--gray-600);
    font-weight: 500;
}

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

.nav-menu a {
    padding: 8px 14px;
    color: var(--gray-800);
    font-weight: 500;
    font-size: 0.95rem;
    border-radius: 8px;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary);
    background: rgba(10, 77, 104, 0.08);
}

.nav-cta { margin-left: 8px; }

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.nav-toggle span {
    width: 24px;
    height: 3px;
    background: var(--primary);
    border-radius: 2px;
    transition: var(--transition);
}

/* ========== BUTTONS ========== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-secondary {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-secondary:hover {
    background: var(--primary);
    color: white;
}

.btn-danger {
    background: var(--danger);
    color: white;
}

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

.btn-lg { padding: 16px 32px; font-size: 1.05rem; }

/* ========== HERO ========== */
.hero {
    background: linear-gradient(135deg, rgba(10,77,104,0.92), rgba(6,52,71,0.95)),
                url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><rect fill="%230a4d68" width="1200" height="600"/></svg>');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 100px 0 80px;
    position: relative;
    overflow: hidden;
}

.hero-content {
    max-width: 700px;
    position: relative;
    z-index: 2;
}

.hero-badge {
    display: inline-block;
    background: rgba(0,255,202,0.15);
    color: var(--accent);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 20px;
    border: 1px solid rgba(0,255,202,0.3);
}

.hero h1 {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
}

.hero h1 span { color: var(--accent); }

.hero p {
    font-size: 1.15rem;
    opacity: 0.9;
    margin-bottom: 32px;
    max-width: 560px;
}

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

.hero-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid rgba(255,255,255,0.15);
}

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

.stat-number {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--accent);
    display: block;
}

.stat-label {
    font-size: 0.85rem;
    opacity: 0.85;
}

/* ========== SECTIONS ========== */
.section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 50px;
}

.section-badge {
    display: inline-block;
    background: rgba(10,77,104,0.1);
    color: var(--primary);
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.section-header h2 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    color: var(--primary-dark);
    margin-bottom: 16px;
    font-weight: 700;
}

.section-header p {
    color: var(--gray-600);
    font-size: 1.05rem;
}

.bg-light { background: var(--gray-100); }

/* ========== CARDS ========== */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 28px;
}

.card {
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.card-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.6rem;
    margin-bottom: 20px;
}

.card-body { padding: 28px; }

.card h3 {
    font-size: 1.2rem;
    color: var(--primary-dark);
    margin-bottom: 12px;
}

.card p {
    color: var(--gray-600);
    font-size: 0.95rem;
    margin-bottom: 16px;
}

.card-link {
    font-weight: 600;
    color: var(--primary-light);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.card-link:hover { gap: 10px; }

/* ========== SERVICES ========== */
.service-item {
    display: flex;
    gap: 20px;
    padding: 24px;
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 20px;
    transition: var(--transition);
}

.service-item:hover {
    box-shadow: var(--shadow-lg);
}

.service-icon {
    width: 56px;
    height: 56px;
    min-width: 56px;
    background: rgba(10,77,104,0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.4rem;
}

.service-content h3 {
    color: var(--primary-dark);
    margin-bottom: 8px;
    font-size: 1.15rem;
}

.service-content p {
    color: var(--gray-600);
    font-size: 0.95rem;
}

/* ========== DOCTORS ========== */
.doctor-card {
    text-align: center;
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
}

.doctor-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.doctor-photo {
    width: 100%;
    height: 220px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 4rem;
}

.doctor-info { padding: 24px; }

.doctor-info h3 {
    color: var(--primary-dark);
    margin-bottom: 4px;
}

.doctor-specialty {
    color: var(--primary-light);
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.doctor-info p {
    color: var(--gray-600);
    font-size: 0.9rem;
    margin-bottom: 16px;
}

/* ========== CTA ========== */
.cta-section {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    padding: 70px 0;
    text-align: center;
}

.cta-section h2 {
    font-size: clamp(1.6rem, 3.5vw, 2.2rem);
    margin-bottom: 16px;
}

.cta-section p {
    opacity: 0.9;
    max-width: 560px;
    margin: 0 auto 28px;
}

/* ========== CONTACT ========== */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.contact-info-card {
    background: white;
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.contact-info-card i {
    width: 48px;
    height: 48px;
    background: rgba(10,77,104,0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.contact-info-card h4 {
    color: var(--primary-dark);
    margin-bottom: 4px;
}

.contact-info-card p,
.contact-info-card a {
    color: var(--gray-600);
    font-size: 0.95rem;
}

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

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

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3px rgba(8,131,149,0.15);
}

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

.form-card {
    background: white;
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow);
}

/* ========== PAGE HERO ========== */
.page-hero {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    padding: 60px 0 50px;
    text-align: center;
}

.page-hero h1 {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    margin-bottom: 12px;
}

.page-hero p {
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

.breadcrumb {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 16px;
    font-size: 0.9rem;
    opacity: 0.8;
}

.breadcrumb a { color: var(--accent); }
.breadcrumb span { opacity: 0.6; }

/* ========== ABOUT ========== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-content h2 {
    color: var(--primary-dark);
    font-size: 2rem;
    margin-bottom: 20px;
}

.about-content p {
    color: var(--gray-600);
    margin-bottom: 16px;
}

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

.about-feature {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
}

.about-feature i {
    color: var(--primary-light);
}

.about-image {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: var(--radius);
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 5rem;
}

/* ========== FOOTER ========== */
.main-footer {
    background: var(--dark);
    color: rgba(255,255,255,0.8);
    padding: 60px 0 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1.3fr;
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: white;
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 16px;
}

.footer-logo i {
    font-size: 1.5rem;
    color: var(--secondary);
}

.footer-about p {
    font-size: 0.9rem;
    margin-bottom: 20px;
    line-height: 1.7;
}

.footer-social a {
    display: inline-flex;
    width: 38px;
    height: 38px;
    background: rgba(255,255,255,0.1);
    border-radius: 8px;
    align-items: center;
    justify-content: center;
    color: white;
    margin-right: 8px;
}

.footer-social a:hover {
    background: var(--primary-light);
    color: white;
}

.footer-col h4 {
    color: white;
    margin-bottom: 20px;
    font-size: 1.05rem;
}

.footer-col ul { list-style: none; }

.footer-col ul li { margin-bottom: 10px; }

.footer-col ul a {
    color: rgba(255,255,255,0.7);
    font-size: 0.9rem;
}

.footer-col ul a:hover { color: var(--accent); }

.contact-list li {
    display: flex;
    gap: 12px;
    margin-bottom: 14px;
    font-size: 0.9rem;
}

.contact-list i {
    color: var(--secondary);
    margin-top: 3px;
    width: 16px;
}

.contact-list a { color: rgba(255,255,255,0.7); }
.contact-list a:hover { color: var(--accent); }

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 0;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 0.85rem;
}

.footer-links a {
    color: rgba(255,255,255,0.6);
    margin-left: 20px;
}

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

/* ========== FLOATING ========== */
.whatsapp-float {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 56px;
    height: 56px;
    background: #25d366;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 4px 20px rgba(37,211,102,0.4);
    z-index: 999;
    transition: var(--transition);
}

.whatsapp-float:hover {
    transform: scale(1.1);
    color: white;
}

.emergency-mobile {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--danger);
    color: white;
    text-align: center;
    padding: 12px;
    font-weight: 600;
    z-index: 998;
}

.emergency-mobile:hover { color: white; }

/* ========== ALERTS ========== */
.alert {
    padding: 14px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ========== SPECIALTIES GRID ========== */
.specialty-tag {
    display: inline-block;
    background: rgba(10,77,104,0.08);
    color: var(--primary);
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 500;
    margin: 4px;
    transition: var(--transition);
}

.specialty-tag:hover {
    background: var(--primary);
    color: white;
}

.specialties-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

/* ========== TABLE ========== */
.table-responsive { overflow-x: auto; }

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

th, td {
    padding: 14px 18px;
    text-align: left;
    border-bottom: 1px solid var(--gray-200);
}

th {
    background: var(--primary);
    color: white;
    font-weight: 600;
}

tr:hover { background: var(--gray-100); }

/* ========== RESPONSIVE ========== */
@media (max-width: 992px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .hero-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .about-grid,
    .contact-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-toggle { display: flex; }
    
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: white;
        flex-direction: column;
        padding: 80px 24px 24px;
        box-shadow: -5px 0 30px rgba(0,0,0,0.1);
        transition: right 0.3s ease;
        align-items: stretch;
        gap: 4px;
        z-index: 1001;
    }
    
    .nav-menu.active { right: 0; }
    
    .nav-menu a {
        padding: 12px 16px;
        display: block;
    }
    
    .nav-cta { margin-left: 0; margin-top: 12px; }
    
    .top-bar-content { justify-content: center; text-align: center; }
    .top-info a { margin: 0 10px; }
    
    .hero { padding: 60px 0 50px; }
    
    .hero-stats {
        grid-template-columns: 1fr 1fr;
        gap: 16px;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links a { margin: 0 10px; }
    
    .emergency-mobile { display: block; }
    .whatsapp-float { bottom: 60px; }
    
    .about-features { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
    .hero-buttons { flex-direction: column; }
    .hero-buttons .btn { width: 100%; }
}
