:root {
  --navy: #081b64;
  --ivory: #f7f3ef;
  --paper: #fff;
  --ink: #263353;
  --line: #e4d9d1;
  --champagne: #ceb7a5;
  --champagne-text: #896d58;
  --gutter: clamp(24px, 10vw, 150px);
  --content-width: 1020px;
  --photo-radius: 16px;
  --button-radius: 8px;
  color: var(--navy);
  background: var(--paper);
  font: 400 1rem/1.55 "Nunito", system-ui, sans-serif;
}

* { box-sizing: border-box; }
body, h1, h2, p, ol, figure { margin: 0; }
a { color: inherit; }
a:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }
section[id], footer[id] { scroll-margin-top: 20px; }
img { display: block; max-width: 100%; }

.wrap { width: min(100% - 2 * var(--gutter), var(--content-width)); margin-inline: auto; }
.site-header { background: var(--paper); }
.header-inner { min-height: clamp(82px, 8vw, 106px); display: flex; align-items: center; gap: 10px 20px; padding-block: 11px; }
.site-header-catalogue .header-inner { min-height: clamp(69px, 7vw, 94px); }
.brand { display: flex; align-items: center; gap: 10px; margin-right: auto; text-decoration: none; }
.brand img { width: 47px; height: 47px; }
.brand span { display: grid; gap: 2px; }
.brand strong { font-size: 1.08rem; font-weight: 500; line-height: 1.18; }
.brand small { font-size: .78rem; line-height: 1.25; }
.navigation, .language { display: flex; align-items: center; gap: clamp(12px, 2vw, 24px); font-weight: 700; }
.navigation { flex-wrap: wrap; }
.navigation a, .language a { text-decoration: none; }
.language { gap: 2px; flex-shrink: 0; font-weight: 700; }
.language a { display: grid; place-items: center; min-width: 30px; min-height: 38px; color: var(--ink); font-size: .73rem; }
.language a:hover, .language a[aria-current] { text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1px; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: var(--button-radius);
  background: var(--navy);
  color: var(--paper);
  font-size: .9rem;
  font-weight: 700;
  text-decoration: none;
  border: 0;
  cursor: pointer;
}
.button:hover { background: #25397e; }
.button:focus-visible { outline-color: var(--navy); }
.button-champagne { background: var(--champagne); color: var(--navy); }
.button-champagne:hover { background: #decabc; }
.footer-contact { min-height: 39px; padding: 8px 14px; }
.footer-contact-row { margin-top: 24px; }
.section { padding-block: clamp(30px, 4.3vw, 52px); }
.split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: center; gap: clamp(26px, 5vw, 66px); }
.copy { display: grid; align-content: center; gap: 16px; }
h1, h2 { font-weight: 500; letter-spacing: -.028em; line-height: 1.13; }
h1 { font-size: clamp(2.25rem, 5vw, 4.3rem); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.55rem); }

.hero {
  position: relative; isolation: isolate; display: grid; align-items: center;
  min-height: clamp(310px, 36vw, 510px); color: var(--navy);
  background: linear-gradient(100deg, #fbf8f4 0%, #f7efe6 50%, #eddfd0 100%);
}
.portrait {
  position: absolute; inset: 0 clamp(0px, 9vw, 128px) 0 auto; z-index: -1;
  width: auto; height: 100%; max-width: none; object-fit: contain;
  mask-image: linear-gradient(90deg, transparent, #000 24%, #000 91%, transparent);
}
.hero-inner { padding-block: clamp(29px, 4vw, 56px); }
.hero-copy { display: grid; justify-items: start; gap: clamp(13px, 2vw, 25px); width: min(47%, 520px); }
.hero h1, .display-text, .catalogue h1 { color: var(--champagne-text); }
.hero h1 { font-size: clamp(2.1rem, 4.25vw, 3.9rem); font-weight: 400; }
.hero-lead, .hero-signature {
  font-family: "Libre Baskerville", Georgia, serif;
  font-size: clamp(.94rem, 1.55vw, 1.36rem);
  line-height: 1.55;
}
.hero-signature { margin-top: 3px; }

.editorial-section { padding-block: clamp(39px, 6vw, 78px); }
.clinic { background: var(--ivory); }
.editorial-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: clamp(35px, 8vw, 112px); }
.editorial-grid .copy { position: relative; isolation: isolate; }
.clinic-intro h2 { max-width: 17ch; }
.clinic-intro::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  background: url("./marca.png") center / contain no-repeat;
  width: 70%; height: 138%; inset: -19% auto auto -7%; opacity: .1;
}
.editorial-action { gap: clamp(16px, 2.6vw, 34px); }
.display-text { font-size: clamp(1.9rem, 3.75vw, 3.35rem); line-height: 1.09; letter-spacing: -.028em; max-width: 15ch; }

.clinic-feature {
  position: relative; isolation: isolate; display: grid; align-items: center;
  min-height: clamp(230px, 29vw, 410px); color: var(--paper); background: #837061;
}
.clinic-photo {
  position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%;
  object-fit: cover; object-position: center 24%;
}
.clinic-feature::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, #827062 0%, #8b7668 34%, rgb(139 118 104 / .75) 44%, transparent 54%);
}
.feature-copy { padding: 27px 0 27px max(var(--gutter), calc((100% - var(--content-width)) / 2)); width: 46%; }
.feature-copy h2 { max-width: 15ch; font-size: clamp(1.9rem, 3.8vw, 3.35rem); }
.statement { background: var(--navy); color: var(--paper); text-align: center; padding-block: clamp(25px, 3.8vw, 53px); }
.statement h2 { max-width: 34ch; margin-inline: auto; }
.statement p { max-width: 62ch; margin: 14px auto 0; }
.consultation-inner { display: grid; gap: clamp(22px, 3vw, 35px); }
.consultation-heading { display: grid; gap: 12px; text-align: center; }
.consultation-heading .display-text { max-width: 24ch; margin-inline: auto; }
.consultation-heading h2 { font-size: clamp(1.28rem, 2.1vw, 1.8rem); }
.consultation-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(13px, 2.5vw, 35px); list-style: none; padding: 0; }
.consultation-list li { border-top: 1px solid var(--champagne); padding-top: 12px; }
.consultation-list li p { margin-top: 4px; }
.consultation-button { justify-self: center; }
.editorial-footer { background: var(--ivory); border-top: 1px solid var(--line); }
address { display: grid; gap: 6px; font-style: normal; }
address a { width: fit-content; overflow-wrap: anywhere; text-underline-offset: 3px; }

.contact-dialog {
  position: fixed;
  width: min(500px, calc(100% - 28px));
  max-height: calc(100dvh - 28px);
  padding: clamp(19px, 4.5vw, 32px);
  border: 1px solid var(--line);
  border-radius: var(--photo-radius);
  color: var(--navy);
  background: var(--ivory);
  overflow-y: auto;
}
.contact-dialog:focus { outline: none; }
.contact-dialog::backdrop { background: rgb(21 29 52 / .48); backdrop-filter: blur(3px); }
.contact-dialog h2 { margin-right: 72px; font-size: clamp(1.5rem, 4vw, 2rem); }
.contact-dialog h2 + p { margin-top: 7px; font-size: .94rem; }
.contact-dismiss button {
  position: absolute; top: 12px; right: 14px; min-height: 44px; padding-inline: 9px;
  border: 0; border-radius: var(--button-radius); background: transparent;
  color: var(--ink); font: inherit; font-size: .82rem; text-decoration: underline;
  text-underline-offset: 4px; cursor: pointer;
}
.contact-dismiss button:hover { background: #ebe2da; }
.contact-form { display: grid; gap: 12px; margin-top: 18px; }
.contact-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.contact-form label { display: grid; gap: 4px; font-size: .87rem; font-weight: 500; }
.contact-form input, .contact-form textarea {
  width: 100%; padding: 9px 12px; border: 1px solid #aaa6a1;
  border-radius: var(--button-radius); color: var(--ink);
  background: var(--paper); font: inherit; font-size: 1rem; font-weight: 400;
}
.contact-form textarea { resize: vertical; }
.contact-note, .contact-status { color: var(--ink); font-size: .85rem; }
.contact-status:empty { display: none; }
.contact-status[data-error] { color: #9b2430; }
.contact-form .button { width: 100%; }
.contact-form .button:disabled { opacity: .65; cursor: wait; }

.catalogue-heading { background: linear-gradient(#fcfaf8, var(--ivory)); padding-block: clamp(14px, 2vw, 26px); text-align: center; }
.catalogue-heading h1 { font-size: clamp(2rem, 4.25vw, 3.6rem); }
.catalogue-body { padding-block: clamp(24px, 4.5vw, 49px); }
.treatment-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(14px, 2vw, 24px); }
.treatment {
  display: flex; flex-direction: column; align-items: flex-start; gap: 11px;
  padding: clamp(12px, 1.6vw, 18px); border: 1px solid var(--line);
  border-radius: var(--photo-radius); background: var(--paper);
}
.treatment img { width: 100%; height: auto; border-radius: 12px; }
.treatment h2 { font-size: clamp(1.15rem, 1.8vw, 1.45rem); overflow-wrap: anywhere; font-weight: 700; }
.treatment p { color: var(--ink); font-size: .94rem; margin-bottom: 5px; }
.treatment .button { margin-top: auto; }

@media (max-width: 950px) {
  .treatment-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 650px) {
  :root { --gutter: clamp(20px, 5.5vw, 34px); }
  .split, .editorial-grid { grid-template-columns: 1fr; }
  .header-inner { min-height: 66px; gap: 9px; padding-block: 8px; }
  .brand img { width: 42px; height: 42px; }
  .hero { min-height: auto; }
  .clinic-feature::before { display: none; }
  .hero-inner { order: -1; padding-block: 23px 13px; }
  .hero-copy { width: 100%; gap: 8px; }
  .hero h1 { font-size: clamp(2rem, 7.2vw, 2.65rem); }
  .portrait { position: static; margin-inline: auto; height: clamp(172px, 51vw, 271px); max-width: 100%; }
  .clinic-photo { position: static; width: 100%; height: clamp(143px, 40vw, 240px); }
  .clinic-feature { min-height: auto; }
  .feature-copy { width: 100%; padding: 22px var(--gutter); }
  .feature-copy h2 { max-width: 18ch; }
  .editorial-section { padding-block: 34px; }
  .editorial-action { gap: 16px; }
}

@media (max-width: 510px) {
  .header-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1px 8px; }
  .brand { margin-right: 0; }
  .language { grid-column: 2; grid-row: 1; justify-self: end; }
  .navigation { grid-column: 1 / -1; justify-self: end; }
  .navigation .button { min-height: 36px; padding: 5px 11px; font-size: .84rem; }
  .treatment-grid { grid-template-columns: 1fr; }
  .consultation-list { grid-template-columns: 1fr; }
}

@media (max-width: 390px) {
  .contact-fields { grid-template-columns: 1fr; gap: 9px; }
}

@media (max-width: 360px) {
  .brand img { width: 42px; height: 42px; }
  .brand strong { font-size: 1rem; }
  .brand small { font-size: .72rem; }
}
