/* ===================================================================
   Dr. Sebastián Ruarte — Cirugía Pediátrica Mendoza
   Paleta minimalista: marfil, verde salvia apagado, carbón, oro tenue
   =================================================================== */

:root {
  --ivory: #faf8f4;
  --ivory-soft: #f3efe8;
  --charcoal: #2b2b28;
  --charcoal-soft: #55534c;
  --sage: #8a9a89;
  --sage-deep: #5f7062;
  --sage-pale: #e7ece6;
  --gold: #b8a369;
  --gold-pale: #f1ead8;
  --line: #e3ddd0;
  --white: #ffffff;
  --radius: 10px;
  --radius-sm: 6px;
  --shadow-sm: 0 2px 10px rgba(43,43,40,0.05);
  --shadow-md: 0 10px 34px rgba(43,43,40,0.09);
  --shadow-lg: 0 22px 60px rgba(43,43,40,0.14);
  --max-width: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ivory);
  color: var(--charcoal);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 300;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: 'Cormorant Garamond', 'Georgia', serif;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--charcoal);
  margin: 0 0 0.6em;
}

h1 { font-size: clamp(2.2rem, 4vw, 3.2rem); font-weight: 500; }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1.2em; color: var(--charcoal-soft); }

a { color: var(--sage-deep); text-decoration: none; }
a:hover { color: var(--gold); }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.72rem;
  color: var(--gold);
  font-weight: 500;
  margin-bottom: 0.8em;
  display: inline-block;
}

/* ---------- Header ---------- */
header.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--ivory);
  position: sticky;
  top: 0;
  z-index: 50;
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 32px;
  max-width: var(--max-width);
  margin: 0 auto;
}

.brand {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  letter-spacing: 0.02em;
  color: var(--charcoal);
}

.brand span { color: var(--sage-deep); }

nav.main-nav ul {
  list-style: none;
  display: flex;
  gap: 34px;
  margin: 0;
  padding: 0;
}

nav.main-nav a {
  color: var(--charcoal-soft);
  font-size: 0.88rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

nav.main-nav a:hover, nav.main-nav a.active { color: var(--sage-deep); }

.nav-toggle { display: none; }

@media (max-width: 820px) {
  nav.main-nav { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  padding: 0;
  border-bottom: 1px solid var(--line);
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 85% 20%, var(--gold-pale) 0%, transparent 45%),
    radial-gradient(circle at 10% 90%, var(--sage-pale) 0%, transparent 50%),
    var(--ivory);
}

.hero .blob {
  position: absolute;
  z-index: 0;
  opacity: 0.9;
  pointer-events: none;
}

.hero .blob-1 { top: -60px; right: -40px; width: 340px; }
.hero .blob-2 { bottom: -80px; left: -60px; width: 300px; }

.hero .hero-grid { position: relative; z-index: 1; }

/* pequeños motivos infantiles sutiles, dibujados a línea */
.doodle { position: absolute; opacity: 0.5; stroke: var(--gold); }

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 60px;
  align-items: center;
  padding: 100px 0 80px;
}

@media (max-width: 820px) {
  .hero-grid { grid-template-columns: 1fr; padding: 60px 0 50px; }
}

.hero p.lead {
  font-size: 1.15rem;
  color: var(--charcoal-soft);
  max-width: 46ch;
}

.hero-photo {
  aspect-ratio: 4/5;
  background: linear-gradient(160deg, var(--ivory-soft), var(--sage-pale));
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--sage-deep);
  font-size: 0.85rem;
  text-align: center;
  padding: 20px;
  position: relative;
}

.hero-photo::before {
  content: "";
  position: absolute;
  inset: 14px;
  border: 1px solid rgba(184,163,105,0.35);
  border-radius: calc(var(--radius) - 4px);
}

.hero-photo.small { aspect-ratio: 1/1; }

.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: calc(var(--radius) - 4px);
  position: relative;
  z-index: 1;
}

.hero-photo.has-img {
  padding: 14px;
  background: var(--white);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 15px 32px;
  border: 1px solid var(--charcoal);
  border-radius: 999px;
  color: var(--charcoal);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: all 0.25s ease;
}

.btn:hover { background: var(--charcoal); color: var(--ivory); box-shadow: var(--shadow-md); }

.btn-primary {
  background: var(--sage-deep);
  border-color: var(--sage-deep);
  color: var(--white);
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover { background: var(--charcoal); border-color: var(--charcoal); color: var(--ivory); }

.btn-group { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 28px; }

/* ---------- Sections ---------- */
section { padding: 80px 0; }
section.alt { background: var(--ivory-soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

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

/* ---------- Cards ---------- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}

@media (max-width: 820px) {
  .grid-3 { grid-template-columns: 1fr; }
}

.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 40px 32px;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}

.card:hover { border-color: var(--sage); box-shadow: var(--shadow-md); transform: translateY(-3px); }

.card .icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--sage-pale);
  color: var(--sage-deep);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.card .icon svg { width: 22px; height: 22px; }

.card .eyebrow { margin-bottom: 14px; }

.card h3 { margin-bottom: 12px; }

.card ul { margin: 0; padding-left: 18px; color: var(--charcoal-soft); }
.card ul li { margin-bottom: 6px; }

/* ---------- Hub interactivo (Patologías / Obras Sociales / Consultorios) ---------- */
.hub-btn {
  cursor: pointer;
  text-align: left;
  width: 100%;
  font-family: inherit;
}

.hub-btn.active {
  border-color: var(--sage-deep);
  box-shadow: var(--shadow-md);
  background: var(--sage-pale);
}

.hub-panel {
  margin-top: 40px;
  padding-top: 10px;
}

.tab-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  margin-bottom: 34px;
}

.tab-sq {
  min-width: 150px;
  aspect-ratio: 1.3/1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  text-align: center;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  padding: 14px;
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--charcoal);
  cursor: pointer;
  transition: all 0.25s ease;
}

.tab-sq:hover { border-color: var(--sage); box-shadow: var(--shadow-md); transform: translateY(-2px); }

.tab-sq.active {
  border-color: var(--gold);
  background: var(--gold-pale);
  color: var(--charcoal);
}

.tab-sq.no-link {
  cursor: default;
  min-width: 0;
  aspect-ratio: auto;
  padding: 12px 8px;
  font-size: 0.85rem;
  color: var(--charcoal-soft);
}

.tab-sq.no-link:hover { transform: none; box-shadow: var(--shadow-sm); border-color: var(--line); }

.tab-sq.compact {
  aspect-ratio: auto;
  min-width: 132px;
  padding: 14px 12px;
  font-size: 0.85rem;
  line-height: 1.3;
}

.tab-group { margin-bottom: 22px; }

.tab-group-label {
  display: block;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.7rem;
  color: var(--gold);
  font-weight: 500;
  margin-bottom: 12px;
}

.tag-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

@media (max-width: 820px) { .tag-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 560px) { .tag-grid { grid-template-columns: repeat(2, 1fr); } }

.location-sq {
  text-decoration: none;
  color: var(--charcoal);
}

.location-sq strong { font-family: 'Cormorant Garamond', serif; font-size: 1.15rem; }
.location-sq span { font-size: 0.82rem; color: var(--charcoal-soft); }

.tab-content { max-width: 720px; margin: 0 auto; }

.tab-pane {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 34px 38px;
}

.tab-pane h3 { color: var(--sage-deep); margin-bottom: 16px; }

/* ---------- Trust points (reemplazo de testimonios) ---------- */
.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 34px;
}

@media (max-width: 820px) { .trust-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .trust-grid { grid-template-columns: 1fr; } }

.trust-item { text-align: center; padding: 10px; }

.trust-item .icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--gold-pale);
  color: var(--gold);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
  box-shadow: var(--shadow-sm);
}

.trust-item .icon svg { width: 26px; height: 26px; }

.trust-item h3 { font-size: 1.05rem; margin-bottom: 8px; }
.trust-item p { font-size: 0.92rem; }

/* ---------- Locations ---------- */
.location {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 30px 32px;
  margin-bottom: 22px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  gap: 20px;
  align-items: center;
  transition: box-shadow 0.25s ease;
}

.location:hover { box-shadow: var(--shadow-md); }
.location:last-child { margin-bottom: 0; }

@media (max-width: 760px) {
  .location { grid-template-columns: 1fr; }
}

.location h4 { margin-bottom: 4px; }
.location .meta { font-size: 0.9rem; color: var(--charcoal-soft); }

/* ---------- FAQ ---------- */
.faq-item {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  padding: 24px 28px;
  margin-bottom: 16px;
}

.faq-item h3 { font-size: 1.15rem; margin-bottom: 10px; color: var(--sage-deep); }

/* ---------- Table (obras sociales) ---------- */
.convenios-list {
  columns: 3;
  column-gap: 40px;
  list-style: none;
  padding: 0;
  margin: 0;
}

@media (max-width: 820px) { .convenios-list { columns: 2; } }
@media (max-width: 560px) { .convenios-list { columns: 1; } }

.convenios-list li {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  break-inside: avoid;
  color: var(--charcoal-soft);
  font-size: 0.95rem;
}

.destacados {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 50px;
}

@media (max-width: 760px) { .destacados { grid-template-columns: repeat(2, 1fr); } }

.destacado-tag {
  border: 1px solid var(--gold);
  border-radius: var(--radius-sm);
  background: var(--gold-pale);
  color: #8a713a;
  text-align: center;
  padding: 18px 10px;
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  box-shadow: var(--shadow-sm);
}

.convenios-list li { border-radius: 2px; }

/* ---------- Breadcrumb / page hero small ---------- */
.page-hero {
  padding: 64px 0 44px;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 90% 0%, var(--gold-pale) 0%, transparent 40%),
    radial-gradient(circle at 0% 100%, var(--sage-pale) 0%, transparent 45%),
    var(--ivory);
}

.page-hero .eyebrow { display: block; }

/* ---------- Footer ---------- */
footer {
  background: var(--charcoal);
  color: var(--ivory-soft);
  padding: 60px 0 30px;
}

footer a { color: var(--ivory-soft); }
footer a:hover { color: var(--gold); }

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  margin-bottom: 40px;
}

@media (max-width: 820px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }

.footer-grid h4 {
  color: var(--gold);
  font-family: 'Inter', sans-serif;
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  margin-bottom: 16px;
}

footer p, footer li { color: #cfcbc0; font-size: 0.92rem; }

footer ul { list-style: none; padding: 0; margin: 0; }
footer li { margin-bottom: 8px; }

.footer-bottom {
  border-top: 1px solid #43423b;
  padding-top: 22px;
  font-size: 0.8rem;
  color: #9c988c;
  text-align: center;
}

/* ---------- Utility ---------- */
.center { text-align: center; }
.mt-0 { margin-top: 0; }
.small { font-size: 0.85rem; color: var(--charcoal-soft); }
