@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;400;500;600;700&family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap');

:root {
  /* Nueva Paleta - Elegant Green Theme */
  --bg: #F9F7F1; /* Crema suave premium */
  --surface: #FFFFFF;
  --ink: #2C3529; /* Gris oscuro / Verde muy profundo */
  --muted: #64705F; /* Verde grisáceo apagado para texto */
  
  --brand: #5F7D4F; /* Verde principal solicitado */
  --brand-dark: #3f5534;
  --brand-soft: #EDF2EA; /* Verde de fondo muy suave */
  --brand-light: #A3B59B;
  
  --accent: #B49265; /* Acento dorado/oliva suave */
  --line: #E8EBE4;
  
  --radius-lg: 32px;
  --radius-md: 20px;
  --radius-sm: 12px;
  --shadow-sm: 0 4px 12px rgba(44, 53, 41, 0.04);
  --shadow: 0 16px 40px rgba(44, 53, 41, 0.08);
  --shadow-hover: 0 24px 50px rgba(95, 125, 79, 0.15);
  --max: 1200px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: 'Manrope', sans-serif;
  color: var(--ink);
  background: var(--bg);
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body { line-height: 1.65; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container {
  width: min(var(--max), calc(100% - 3rem));
  margin-inline: auto;
}

/* --- HEADER --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(249, 247, 241, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: all 0.4s ease;
}

.site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.96);
  border-color: var(--line);
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 90px;
  gap: 1rem;
}

.brand {
  display: grid;
  gap: 0;
  text-transform: uppercase;
  position: relative;
  z-index: 100;
}

.brand strong {
  font-family: 'Playfair Display', serif;
  font-size: 1.45rem;
  letter-spacing: 0.05em;
  color: var(--brand-dark);
}

.brand span {
  color: var(--brand);
  font-size: 0.75rem;
  letter-spacing: 0.25em;
  font-weight: 700;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.site-nav a {
  padding: 0.6rem 1rem;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 500;
  font-size: 0.95rem;
  transition: all 0.3s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--brand-dark);
  background: var(--brand-soft);
  font-weight: 600;
}

/* --- BUTTONS --- */
.call-btn, .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 999px;
  padding: 0.9rem 1.6rem;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.3s cubic-bezier(0.25, 1, 0.25, 1);
  border: 1px solid transparent;
  cursor: pointer;
}

.call-btn {
  color: #fff;
  background: var(--brand);
  margin-left: 0.5rem;
}

.btn-primary {
  color: #fff;
  background: var(--brand);
  box-shadow: 0 8px 24px rgba(95, 125, 79, 0.25);
}

.btn-primary:hover, .call-btn:hover {
  background: var(--brand-dark);
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(95, 125, 79, 0.35);
}

.btn-secondary {
  color: var(--brand-dark);
  border-color: var(--brand-light);
  background: var(--surface);
}

.btn-secondary:hover {
  border-color: var(--brand);
  background: var(--brand-soft);
}

/* --- HERO --- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 7rem 0 6rem;
}

.hero::before {
  content: '';
  position: absolute;
  top: -10vw; right: -10vw;
  width: 45vw; height: 45vw;
  background: var(--brand-soft);
  border-radius: 50%;
  filter: blur(80px);
  z-index: -1;
  opacity: 0.7;
}

.hero-grid {
  display: grid;
  gap: 4rem;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--brand);
  background: var(--surface);
  border-radius: 999px;
  padding: 0.5rem 1.2rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line);
}

.hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.8rem, 5.5vw, 4.5rem);
  line-height: 1.08;
  margin: 0 0 1.2rem;
  color: var(--ink);
  font-weight: 500;
}

.hero h1 span {
  font-style: italic;
  color: var(--brand);
}

.hero p {
  margin: 0;
  color: var(--muted);
  font-size: 1.15rem;
  max-width: 48ch;
}

.hero-actions {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.hero-media {
  border-radius: 40px 180px 40px 180px;
  overflow: hidden;
  box-shadow: var(--shadow);
  min-height: 580px;
  background: url('https://images.unsplash.com/photo-1629909613654-28e377c37b09?auto=format&fit=crop&w=1200&q=80') center/cover no-repeat;
  animation: float-in 1s cubic-bezier(0.2, 1, 0.2, 1) forwards;
  position: relative;
}

.hero-media::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 8px solid rgba(255,255,255,0.4);
  pointer-events: none;
}

/* --- SECTIONS --- */
.section { padding: 6rem 0; }

.section h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.2rem, 4vw, 3rem);
  font-weight: 500;
  margin: 0 0 1rem;
  color: var(--ink);
}

.section-intro {
  margin: 0 0 3rem;
  color: var(--muted);
  font-size: 1.15rem;
  max-width: 60ch;
}

/* --- CARDS (ESPECIALIDADES) --- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2.5rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 3rem 2.5rem;
  transition: all 0.4s cubic-bezier(0.25, 1, 0.25, 1);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 4px;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s ease;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
  border-color: transparent;
}

.card:hover::before { transform: scaleX(1); }

.card-icon {
  width: 54px;
  height: 54px;
  background: var(--brand-soft);
  color: var(--brand);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2rem;
  font-size: 1.5rem;
}

.card h3 {
  margin: 0 0 1rem;
  font-size: 1.4rem;
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  color: var(--ink);
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
}

.card ul {
  margin: 1.5rem 0 0;
  padding-left: 1.2rem;
  color: var(--muted);
  font-size: 1rem;
}

.card ul li { margin-bottom: 0.4rem; }
.card ul li::marker { color: var(--brand); }

/* --- BAND (DIRECTOR MEDICO) --- */
.band {
  background: var(--surface);
  position: relative;
  padding: 7rem 0;
}

.band::after {
  content: '';
  position: absolute;
  top: 0; right: 0; width: 40%; height: 100%;
  background: var(--brand-soft);
  border-radius: 40px 0 0 40px;
  z-index: 0;
}

.director-highlight {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 5rem;
  align-items: center;
  position: relative;
  z-index: 1;
}

/* FOTO DOCTOR REAL */
.director-photo {
  border-radius: 300px 300px 20px 20px;
  min-height: 560px;
  background: url('../img/drsalas.jpg') top center/cover no-repeat;
  box-shadow: var(--shadow);
  border: 12px solid #fff;
}

.director-copy {
  padding: 1rem 0;
}

.director-copy h2 { margin-bottom: 1.5rem; color: var(--brand-dark); }
.director-copy p { margin-bottom: 1.5rem; font-size: 1.1rem; }

/* --- INFO CARDS --- */
.data-points {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2rem;
}

.data-points .item {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  border: 1px solid var(--line);
  text-align: center;
  transition: transform 0.3s ease;
}

.data-points .item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-sm);
  border-color: var(--brand-light);
}

.data-points .item strong {
  display: block;
  font-size: 1.25rem;
  color: var(--ink);
  font-family: 'Playfair Display', serif;
  margin-bottom: 0.8rem;
}

.data-points .item span { color: var(--muted); font-size: 1.05rem; }

/* --- CTA SECUNDARIO --- */
.cta-panel {
  background: var(--brand);
  background-image: linear-gradient(135deg, var(--brand) 0%, var(--brand-dark) 100%);
  color: #fff;
  border-radius: 40px;
  padding: 4.5rem 4rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 2rem;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.cta-panel::before {
  content: ''; position: absolute;
  width: 400px; height: 400px;
  background: rgba(255,255,255,0.06);
  border-radius: 50%;
  top: -150px; left: -100px;
}
.cta-panel::after {
  content: ''; position: absolute;
  width: 500px; height: 500px;
  background: rgba(255,255,255,0.04);
  border-radius: 50%;
  bottom: -200px; right: -150px;
}

.cta-panel h2 { color: #fff; margin: 0; position: relative; z-index: 2; }
.cta-panel p { margin: 0; color: rgba(255, 255, 255, 0.9); font-size: 1.15rem; max-width: 52ch; position: relative; z-index: 2;}
.cta-panel .btn-secondary {
  color: var(--brand-dark);
  border-color: #fff;
  background: #fff;
  font-size: 1.05rem;
  padding: 1.1rem 2.4rem;
  position: relative; z-index: 2;
  box-shadow: 0 4px 14px rgba(0,0,0,0.1);
}
.cta-panel .btn-secondary:hover {
  background: var(--brand-soft);
  color: var(--brand-dark);
  transform: translateY(-2px);
}

/* --- INTERIORES (Page Titles) --- */
.page-title {
  padding: 5.5rem 0 4rem;
  text-align: center;
  background: radial-gradient(100% 150% at 50% 0%, #FFFFFF 0%, var(--bg) 100%);
}

.page-title h1 {
  margin: 0;
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.8rem, 5.5vw, 4.2rem);
  color: var(--ink);
}

.page-title p {
  margin: 1.5rem auto 0;
  max-width: 64ch;
  color: var(--muted);
  font-size: 1.2rem;
}

/* --- CONTACTO MAPA --- */
.map-wrap iframe {
  width: 100%;
  height: 100%;
  min-height: 500px;
  border: 0;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 4rem;
  align-items: stretch;
}

.contact-box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 3.5rem 3rem;
  position: relative;
  overflow: hidden;
}

.contact-box::before {
  content: ''; position: absolute;
  top: 0; left: 0; width: 6px; height: 100%;
  background: var(--brand);
}

.contact-box h3 {
  margin: 0 0 2rem;
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  color: var(--brand-dark);
}

.contact-list {
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
  color: var(--ink);
  font-size: 1.1rem;
}

.contact-list span {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.contact-list strong {
  color: var(--brand);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* --- FOOTER --- */
.site-footer {
  margin-top: 5rem;
  border-top: 1px solid var(--line);
  background: var(--surface);
  padding: 4rem 0;
}

.footer-grid {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  color: var(--muted);
  font-size: 1rem;
}

/* --- UTILS --- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  animation: reveal 0.9s cubic-bezier(0.2, 1, 0.2, 1) forwards;
}

.delay-1 { animation-delay: 0.15s; }
.delay-2 { animation-delay: 0.3s; }
.delay-3 { animation-delay: 0.45s; }

@keyframes reveal {
  to { opacity: 1; transform: translateY(0); }
}

@keyframes float-in {
  from { transform: translateY(30px) scale(0.97); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}

/* --- MOBILE --- */
.nav-toggle {
  display: none;
  border: 0;
  background: transparent;
  width: 3rem;
  height: 3rem;
  cursor: pointer;
  z-index: 100;
}

.nav-toggle .bar {
  display: block;
  width: 1.6rem;
  height: 2px;
  margin: 6px auto;
  background: var(--ink);
  transition: all 0.3s ease;
}

@media (max-width: 980px) {
  .hero { padding: 5rem 0 4rem; text-align: center; }
  .hero-grid { grid-template-columns: 1fr; gap: 3rem; }
  .hero p { margin-inline: auto; }
  .hero-actions { justify-content: center; }
  .hero-media { min-height: 450px; border-radius: 40px 120px 40px 120px; }

  .director-highlight, .contact-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .band::after { width: 100%; height: 50%; top: auto; bottom: 0; border-radius: 0; }
  .director-photo { min-height: 500px; order: -1; }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .data-points { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cta-panel { padding: 4rem 2rem; border-radius: 30px; }
}

@media (max-width: 760px) {
  .nav-toggle { display: inline-block; }
  .site-nav {
    position: absolute;
    right: 1.5rem;
    top: 90px;
    width: min(92vw, 340px);
    border-radius: var(--radius-md);
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(12px);
    padding: 1.5rem;
    display: none;
    flex-direction: column;
    align-items: stretch;
    box-shadow: var(--shadow);
    gap: 0.5rem;
    border: 1px solid var(--line);
  }
  .site-nav.is-open { display: flex; }
  .site-nav a, .call-btn { text-align: center; }
  .call-btn { margin-left: 0; margin-top: 1rem; }
  
  .grid-3, .data-points { grid-template-columns: 1fr; }
  .footer-grid { flex-direction: column; text-align: center; gap: 1rem; }
  
  .contact-box { padding: 2.5rem 2rem; }
}
