:root {
  --blue: #0b4a8f;
  --blue-dark: #072f5d;
  --sky: #2f8fe8;
  --sky-soft: #e8f2fd;
  --cream: #fbf5e4;
  --cream-deep: #f3e8c8;
  --terracotta: #b9573a;
  --ink: #1c2b3b;
  --muted: #5a6877;
  --line: #dfe5ec;
  --radius: 18px;
  --shadow: 0 12px 34px rgba(7, 47, 93, .14);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body { margin: 0; font-family: var(--sans); font-size: 1.0625rem; line-height: 1.7; color: var(--ink); background: #fff; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); text-underline-offset: 3px; }
a:hover { color: var(--sky); }
h1, h2, h3 { font-family: var(--serif); line-height: 1.2; margin: 0 0 .6em; color: var(--blue-dark); font-weight: 700; }
h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.5rem; }
p { margin: 0 0 1em; }
ul { margin: 0 0 1em; padding-left: 1.2em; }
address { font-style: normal; }
.wrap { width: min(1160px, 100% - 40px); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 8px; background: #fff; padding: 8px 14px; z-index: 100; border-radius: 8px; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--sky); outline-offset: 3px; border-radius: 4px; }

/* Header */
.topbar { background: var(--blue-dark); color: #dbe8f7; font-size: .875rem; }
.topbar a { color: #fff; font-weight: 600; text-decoration: none; }
.topbar-inner { display: flex; gap: 24px; padding: 7px 0; flex-wrap: wrap; }
.topbar-hours { margin-left: auto; }
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .96); backdrop-filter: blur(8px); box-shadow: 0 1px 0 var(--line); }
.nav-row { display: flex; align-items: center; justify-content: space-between; padding: 10px 0; gap: 16px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--blue); }
.brand-logo { height: 62px; width: auto; }
.menu ul { list-style: none; display: flex; gap: 6px; margin: 0; padding: 0; }
.menu a { display: block; padding: 8px 14px; text-decoration: none; color: var(--ink); font-weight: 600; border-radius: 999px; font-size: .98rem; }
.menu a:hover { background: var(--sky-soft); color: var(--blue); }
.nav-toggle { display: none; background: none; border: 0; padding: 10px; cursor: pointer; }
.nav-toggle span { display: block; width: 26px; height: 3px; background: var(--blue); margin: 5px 0; border-radius: 2px; transition: .25s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* Buttons */
.btn { display: inline-block; padding: 14px 28px; border-radius: 999px; font-weight: 700; text-decoration: none; border: 2px solid transparent; transition: transform .15s, background .15s, box-shadow .15s; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--blue); color: #fff; box-shadow: 0 8px 20px rgba(11, 74, 143, .3); }
.btn-primary:hover { background: var(--sky); color: #fff; }
.btn-ghost { border-color: var(--blue); color: var(--blue); }
.btn-ghost:hover { background: var(--blue); color: #fff; }

/* Hero */
.hero { background: linear-gradient(180deg, var(--cream) 0%, #fff 100%); padding: 56px 0 40px; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.eyebrow { text-transform: uppercase; letter-spacing: .18em; font-size: .8rem; font-weight: 700; color: var(--terracotta); margin-bottom: .8em; }
.hero h1 em { font-style: normal; color: var(--sky); }
.lead { font-size: 1.25rem; color: #33465a; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin: 28px 0 18px; }
.hero-note { font-size: .95rem; color: var(--muted); border-left: 4px solid var(--terracotta); padding-left: 12px; }
.hero-photo { margin: 0; position: relative; }
.hero-photo::before { content: ""; position: absolute; inset: 22px -22px -22px 22px; background: var(--sky); border-radius: 28px; z-index: 0; opacity: .9; }
.hero-photo img { position: relative; z-index: 1; border-radius: 28px; box-shadow: var(--shadow); aspect-ratio: 4/3.4; object-fit: cover; width: 100%; }

.intro { padding: 28px 0 56px; }
.intro-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; }
.intro-grid > div p:first-child { font-size: 1.15rem; }
blockquote { margin: 0; padding: 28px 32px; background: var(--blue); color: #fff; border-radius: var(--radius); font-family: var(--serif); box-shadow: var(--shadow); }
blockquote p:first-child { font-size: 1.5rem; line-height: 1.35; margin-bottom: .6em; }
blockquote p:last-child { margin: 0; color: #cfe3fa; font-family: var(--sans); font-size: 1rem; }

/* Features */
.features { padding-bottom: 28px; }
.cards-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.feature { display: block; text-decoration: none; color: var(--ink); background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; transition: transform .2s, box-shadow .2s, border-color .2s; }
.feature:hover { transform: translateY(-5px); box-shadow: var(--shadow); border-color: var(--sky); color: var(--ink); }
.feature h2 { font-size: 1.5rem; margin-bottom: .4em; }
.feature p { color: var(--muted); margin: 0; }
.feature-icon { width: 58px; height: 58px; border-radius: 16px; background: var(--sky-soft); color: var(--blue); display: grid; place-items: center; margin-bottom: 18px; }
.feature-icon svg { width: 30px; height: 30px; }

/* Highlights */
.highlights { padding: 28px 0 72px; }
.highlight-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.highlight { background: var(--cream); border-radius: var(--radius); padding: 32px; position: relative; border-top: 6px solid var(--terracotta); }
.highlight:nth-child(2) { border-top-color: var(--sky); background: var(--sky-soft); }
.highlight:nth-child(3) { border-top-color: var(--blue); background: #fff; box-shadow: var(--shadow); }
.highlight h3 { font-size: 1.4rem; }
.highlight p:last-child, .highlight ul:last-child { margin-bottom: 0; }

/* Sections */
.section { padding: 84px 0; }
.section-cream { background: var(--cream); }
.section-head { max-width: 780px; margin-bottom: 40px; }
.section-head p:last-child { margin-bottom: 0; }
.section-blue { background: linear-gradient(160deg, var(--blue) 0%, var(--blue-dark) 100%); color: #e6f0fb; }
.section-blue .eyebrow { color: #ffd3bf; }
.section-blue h2 { color: #fff; }
.section-blue a { color: #fff; }

/* Logos */
.logos { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
.logos li { background: #fff; border-radius: 14px; padding: 16px; display: grid; place-items: center; min-height: 104px; border: 1px solid var(--cream-deep); transition: transform .2s, box-shadow .2s; }
.logos li:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.logos img { max-height: 72px; width: auto; object-fit: contain; }

/* Instalaciones */
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; padding: 0; margin: 0 0 48px; }
.chips a { display: inline-block; padding: 9px 18px; border-radius: 999px; background: var(--sky-soft); color: var(--blue); text-decoration: none; font-weight: 600; font-size: .95rem; }
.chips a:hover { background: var(--blue); color: #fff; }
.area { display: grid; grid-template-columns: 1fr 1.25fr; gap: 44px; align-items: center; margin-bottom: 72px; }
.area:last-child { margin-bottom: 0; }
.area-reverse { grid-template-columns: 1.25fr 1fr; }
.area-reverse .area-text { order: 2; }
.area-text h3 { position: relative; padding-bottom: .5em; }
.area-text h3::after { content: ""; position: absolute; left: 0; bottom: 0; width: 56px; height: 4px; background: var(--terracotta); border-radius: 2px; }
.gallery { display: grid; gap: 12px; }
.gallery a { display: block; overflow: hidden; border-radius: 14px; box-shadow: 0 4px 14px rgba(7, 47, 93, .12); }
.gallery img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4/3; transition: transform .5s; }
.gallery a:hover img { transform: scale(1.06); }
.gallery-2 { grid-template-columns: 1fr 1fr; }
.gallery-wide { grid-template-columns: repeat(6, 1fr); }
.gallery-wide a { grid-column: span 3; }
.gallery-wide a:first-child { grid-column: span 6; }
.gallery-wide a:first-child img { aspect-ratio: 16/9; }
#gabinetes .gallery a:nth-child(n+2) { grid-column: span 2; }
#exterior .gallery a:nth-child(n+2) { grid-column: span 2; }
.steri { display: grid; place-items: center; gap: 14px; text-align: center; background: var(--sky-soft); border-radius: 28px; padding: 56px 24px; color: var(--blue); font-family: var(--serif); font-size: 1.4rem; font-weight: 700; min-height: 280px; }
.steri svg { width: 92px; height: 92px; }

/* Tratamientos */
.treat-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 40px; align-items: start; }
.accordion { display: grid; gap: 12px; }
details { background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .18); border-radius: 14px; transition: background .2s; }
details[open] { background: #fff; color: var(--ink); border-color: #fff; }
summary { cursor: pointer; list-style: none; padding: 18px 56px 18px 24px; font-family: var(--serif); font-size: 1.3rem; font-weight: 700; color: #fff; position: relative; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 22px; top: 50%; transform: translateY(-50%); width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; background: rgba(255, 255, 255, .18); font-family: var(--sans); font-size: 1.4rem; line-height: 1; }
details[open] summary { color: var(--blue-dark); }
details[open] summary::after { content: "–"; background: var(--sky-soft); color: var(--blue); }
summary:hover { background: rgba(255, 255, 255, .06); border-radius: 14px; }
.panel { padding: 0 24px 8px; }
.panel li { margin-bottom: .6em; }
.treat-aside { position: sticky; top: 110px; }
.treat-aside img { border-radius: 24px; aspect-ratio: 4/4.4; object-fit: cover; width: 100%; box-shadow: 0 18px 44px rgba(0, 0, 0, .35); }
.guarantee { margin: -46px 20px 0; position: relative; background: var(--terracotta); color: #fff; padding: 18px 22px; border-radius: 16px; display: flex; flex-direction: column; box-shadow: var(--shadow); }
.guarantee strong { font-family: var(--serif); font-size: 1.25rem; }

/* Ubicación */
.location-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 40px; align-items: stretch; }
.location-info { background: var(--cream); border-radius: var(--radius); padding: 36px; }
.location-info h3 { font-size: 1.3rem; margin-bottom: .4em; }
.location-info address { font-size: 1.15rem; margin-bottom: 1em; }
.location-info h3:nth-of-type(2) { margin-top: 1.2em; }
.map { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); min-height: 380px; }
.map iframe { width: 100%; height: 100%; min-height: 380px; border: 0; display: block; }
.map-placeholder { height: 100%; min-height: 380px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 4px; padding: 32px; background: var(--sky-soft); }
.map-placeholder p { max-width: 380px; }
.reviews-placeholder { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 8px; padding: 40px 24px; min-height: 220px; background: #fff; border-radius: var(--radius); border: 1px solid var(--cream-deep); }
.reviews-placeholder p { max-width: 460px; }
.reviews-link { margin: 28px 0 0; text-align: center; }
[hidden] { display: none !important; }

/* Cookies */
.cookie-banner { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 90; max-width: 900px; margin-inline: auto; display: flex; gap: 20px; align-items: center; background: var(--blue-dark); color: #e6f0fb; padding: 18px 22px; border-radius: 16px; box-shadow: 0 18px 50px rgba(0, 0, 0, .35); font-size: .95rem; line-height: 1.5; }
.cookie-banner[hidden] { display: none; }
.cookie-banner p { margin: 0; }
.cookie-banner a { color: #fff; }
.cookie-actions { display: flex; gap: 10px; flex-shrink: 0; }
.cookie-banner .btn { padding: 10px 22px; }
.cookie-banner .btn-primary { background: var(--sky); box-shadow: none; }
.cookie-banner .btn-ghost { border-color: #fff; color: #fff; background: transparent; }
.cookie-banner .btn-ghost:hover { background: #fff; color: var(--blue-dark); }
@media (max-width: 640px) { .cookie-banner { flex-direction: column; align-items: stretch; } .cookie-actions .btn { flex: 1; text-align: center; } }

/* Footer */
.site-footer { background: var(--blue-dark); color: #c9dbef; padding: 48px 0 36px; position: relative; }
.footer-grid { display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.footer-name { font-family: var(--serif); font-size: 1.6rem; color: #fff; margin-bottom: .3em; }
.site-footer p { margin-bottom: .4em; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .4em; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.to-top { position: absolute; right: 24px; top: -24px; width: 48px; height: 48px; border-radius: 50%; background: var(--terracotta); display: grid; place-items: center; font-size: 1.4rem; box-shadow: var(--shadow); }

/* Lightbox */
dialog#lightbox { border: 0; padding: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; }
dialog#lightbox::backdrop { background: rgba(4, 18, 36, .92); }
dialog#lightbox[open] { display: grid; grid-template-columns: 64px 1fr 64px; align-items: center; justify-items: center; }
dialog#lightbox figure { margin: 0; grid-column: 2; text-align: center; max-width: 100%; }
dialog#lightbox img { max-width: min(92vw, 1200px); max-height: 82vh; width: auto; border-radius: 10px; margin-inline: auto; }
dialog#lightbox figcaption { color: #dbe8f7; margin-top: 10px; font-size: .95rem; }
.lb-prev, .lb-next, .lb-close { background: rgba(255, 255, 255, .14); color: #fff; border: 0; border-radius: 50%; width: 48px; height: 48px; font-size: 2rem; line-height: 1; cursor: pointer; }
.lb-prev:hover, .lb-next:hover, .lb-close:hover { background: var(--sky); }
.lb-prev { grid-column: 1; grid-row: 1; }
.lb-next { grid-column: 3; grid-row: 1; }
.lb-close { position: fixed; top: 18px; right: 18px; }

/* Legal */
.legal { padding: 48px 0 72px; max-width: 860px; }
.legal section { margin-bottom: 64px; padding-top: 12px; }
.legal h1 { font-size: 2.2rem; border-bottom: 3px solid var(--terracotta); padding-bottom: .3em; display: inline-block; }
.legal h2 { font-size: 1.2rem; margin-top: 1.6em; }
.menu-simple ul { gap: 6px; }

/* Responsive */
@media (max-width: 960px) {
  .hero-grid, .intro-grid, .area, .area-reverse, .treat-grid, .location-grid { grid-template-columns: 1fr; }
  .area-reverse .area-text { order: 0; }
  .hero-photo { margin-right: 22px; }
  .cards-3, .highlight-grid { grid-template-columns: 1fr; }
  .treat-aside { position: static; max-width: 460px; }
  .topbar-hours { margin-left: 0; width: 100%; }
  .nav-toggle { display: block; }
  .menu:not(.menu-simple) { position: absolute; left: 0; right: 0; top: 100%; background: #fff; box-shadow: 0 14px 20px rgba(7, 47, 93, .14); display: none; padding: 8px 20px 18px; }
  .menu.open { display: block; }
  .menu:not(.menu-simple) ul { flex-direction: column; }
  .section { padding: 60px 0; }
}
@media (max-width: 560px) {
  .brand-logo { height: 52px; }
  .topbar-inner { gap: 12px; }
  .gallery-wide { grid-template-columns: 1fr 1fr; }
  .gallery-wide a, #gabinetes .gallery a:nth-child(n+2), #exterior .gallery a:nth-child(n+2) { grid-column: span 1; }
  .gallery-wide a:first-child { grid-column: span 2; }
  dialog#lightbox[open] { grid-template-columns: 44px 1fr 44px; }
  .lb-prev, .lb-next { width: 38px; height: 38px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
