:root {
  --forest: #243F37;
  --forest-soft: #31594D;
  --sage: #7E9375;
  --olive: #687B4B;
  --sea: #3F7F8C;
  --cream: #F4EEE3;
  --cream-deep: #E6DAC8;
  --paper: #FFF9F0;
  --terra: #A85F3E;
  --terra-light: #D09261;
  --terra-wash: rgba(168,95,62,.11);
  --ink: #1D302A;
  --text: #405851;
  --muted: #7E8D87;
  --border: #D3C6B3;
  --green: #2F7651;
  --red: #A93A37;
  --shadow: 0 18px 42px rgba(31,47,42,.14);
  --radius: 8px;
  --hero-photo: url("https://www.hotels-menorca.com/img/ofertas/agroturismobinissafulletvell/013.jpg?1681371791");
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(36,63,55,.08), transparent 360px),
    linear-gradient(90deg, rgba(168,95,62,.04), transparent 34%, rgba(63,127,140,.05)),
    var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:focus-visible {
  outline: 3px solid rgba(168,95,62,.24);
  outline-offset: 2px;
}
a { color: var(--terra); }

.top {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  min-height: 560px;
  background: var(--forest);
  color: var(--cream);
  border-bottom: 1px solid rgba(255,255,255,.1);
}
.top::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background-image: var(--hero-photo);
  background-size: cover;
  background-position: center 42%;
  filter: saturate(.92) contrast(.98) brightness(1.02);
  transform: scale(1.01);
}
.top::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(23,34,30,.14), rgba(23,34,30,.5) 68%, rgba(244,238,227,.97)),
    linear-gradient(90deg, rgba(23,34,30,.42), rgba(23,34,30,.08) 42%, rgba(23,34,30,.36));
  pointer-events: none;
}
.top-inner {
  position: relative;
  max-width: 1120px;
  min-height: 560px;
  margin: 0 auto;
  padding: max(18px, env(safe-area-inset-top)) 22px 86px;
  display: flex;
  flex-direction: column;
}
.lang-bar {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  margin-bottom: 20px;
}
.lang-btn {
  min-width: 38px;
  height: 32px;
  border: 1px solid rgba(244,238,227,.3);
  border-radius: 8px;
  background: rgba(29,48,42,.28);
  color: rgba(244,238,227,.78);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  transition: transform .16s ease, background .16s ease, color .16s ease, border-color .16s ease;
}
.lang-btn:hover { transform: translateY(-1px); color: var(--cream); }
.lang-btn.active {
  background: rgba(208,146,97,.2);
  border-color: rgba(208,146,97,.78);
  color: var(--terra-light);
}
.brand {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 10px;
  max-width: 820px;
  margin: auto;
  padding-bottom: 12px;
}
.brand-mark {
  width: 58px;
  height: 58px;
  border-radius: 8px;
  box-shadow: 0 12px 30px rgba(0,0,0,.18);
}
.kicker {
  font-size: 11px;
  line-height: 1.5;
  text-transform: uppercase;
  letter-spacing: .24em;
  color: rgba(255,249,240,.82);
  font-weight: 700;
}
.title {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(62px, 12vw, 128px);
  font-style: italic;
  font-weight: 500;
  letter-spacing: 0;
  line-height: .82;
  color: var(--cream);
  text-shadow: 0 20px 60px rgba(0,0,0,.22);
}
.title em {
  color: var(--terra-light);
  font-style: italic;
}
.property {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(30px, 6vw, 58px);
  font-weight: 400;
  font-style: italic;
  letter-spacing: 0;
  color: rgba(245,242,235,.92);
  margin-top: 2px;
}
.rule {
  width: min(280px, 70vw);
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 4px;
  color: var(--terra-light);
  font-size: 9px;
  letter-spacing: .3em;
}
.rule::before, .rule::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(232,160,111,.52));
}
.rule::after { background: linear-gradient(90deg, rgba(232,160,111,.52), transparent); }
.hero-copy {
  max-width: 560px;
  margin: 4px 0 8px;
  color: rgba(255,249,240,.86);
  font-size: 14px;
  line-height: 1.75;
  font-weight: 500;
}
.hero-facts {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 4px;
}
.hero-facts span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 12px;
  border: 1px solid rgba(244,238,227,.26);
  border-radius: 8px;
  background: rgba(29,48,42,.38);
  color: rgba(255,249,240,.8);
  backdrop-filter: blur(10px);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  line-height: 1.35;
}

.main {
  width: min(820px, calc(100% - 32px));
  margin: -76px auto 72px;
  position: relative;
  z-index: 1;
}
.progress-panel {
  background: rgba(255,249,240,.94);
  border: 1px solid rgba(211,198,179,.9);
  border-radius: var(--radius);
  box-shadow: 0 14px 38px rgba(31,47,42,.1);
  padding: 16px 14px 14px;
  backdrop-filter: blur(10px);
}
.steps {
  display: grid;
  grid-template-columns: 1fr 46px 1fr 46px 1fr;
  align-items: start;
  gap: 0;
}
.step-item {
  display: grid;
  justify-items: center;
  gap: 8px;
  min-width: 0;
}
.step-node {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 1.5px solid var(--border);
  color: var(--muted);
  background: var(--paper);
  font-size: 13px;
  font-weight: 800;
  transition: .25s ease;
}
.step-label {
  max-width: 112px;
  text-align: center;
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .13em;
  font-weight: 800;
  line-height: 1.35;
}
.step-item.cur .step-node {
  transform: translateY(-2px) scale(1.06);
  color: white;
  border-color: var(--terra);
  background: linear-gradient(135deg, var(--terra), var(--terra-light));
  box-shadow: 0 0 0 6px rgba(168,95,62,.13), 0 8px 22px rgba(168,95,62,.24);
}
.step-item.cur .step-label { color: var(--terra); }
.step-item.done .step-node {
  color: white;
  border-color: var(--green);
  background: var(--green);
}
.step-item.done .step-num { display: none; }
.step-check { display: none; width: 15px; height: 15px; }
.step-item.done .step-check { display: block; }
.step-line {
  height: 2px;
  margin-top: 18px;
  border-radius: 999px;
  background: var(--cream-deep);
  overflow: hidden;
}
.step-line span {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), var(--terra-light));
  transition: width .32s ease;
}
.step-line.done span { width: 100%; }

.notice {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  margin: 14px 0;
  padding: 14px 16px;
  border: 1px solid rgba(168,95,62,.18);
  border-radius: 8px;
  color: var(--text);
  background: rgba(168,95,62,.07);
  font-size: 13px;
  line-height: 1.65;
}
.notice-icon {
  flex: 0 0 21px;
  width: 21px;
  height: 21px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(168,95,62,.14);
  color: var(--terra);
  font-size: 12px;
  font-weight: 800;
  margin-top: 1px;
}

.card {
  display: none;
  background: var(--paper);
  border: 1px solid var(--border);
  border-top: 4px solid rgba(168,95,62,.72);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.card.on {
  display: block;
  animation: cardIn .3s cubic-bezier(.16,1,.3,1);
}
@keyframes cardIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}
.card-head { padding: 28px 30px 0; }
.card-title {
  margin: 0 0 6px;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(25px, 5vw, 36px);
  font-style: italic;
  font-weight: 500;
  color: var(--forest);
  line-height: 1.05;
}
.card-sub {
  margin: 0 0 24px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 400;
  line-height: 1.65;
}
.fields { padding: 0 30px; }
.grid-2, .grid-3 {
  display: grid;
  gap: 16px;
  margin-bottom: 16px;
}
.grid-2 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.field { min-width: 0; }
.field.full { grid-column: 1 / -1; }
label {
  display: block;
  margin: 0 0 7px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  line-height: 1.35;
}
.label-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 7px;
  position: relative;
}
.label-row label { margin-bottom: 0; }
.info-tip {
  position: static;
  width: 19px;
  height: 19px;
  flex: 0 0 19px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(168,95,62,.38);
  background: rgba(168,95,62,.09);
  color: var(--terra);
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  padding: 0;
}
.tip-pop {
  position: absolute;
  left: 0;
  bottom: calc(100% + 10px);
  width: min(286px, calc(100vw - 44px));
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--forest);
  color: var(--cream);
  box-shadow: 0 12px 34px rgba(31,47,42,.26);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.5;
  text-align: left;
  text-transform: none;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity .16s ease, visibility .16s ease, transform .16s ease;
  z-index: 15;
}
.tip-pop::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 100%;
  transform: translateX(-50%);
  border: 7px solid transparent;
  border-top-color: var(--forest);
}
.info-tip:hover .tip-pop,
.info-tip:focus .tip-pop,
.info-tip:focus-visible .tip-pop {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.req { color: var(--terra); }
input, select, textarea {
  width: 100%;
  min-width: 0;
  height: 46px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background: #FFFCF7;
  color: var(--ink);
  padding: 0 13px;
  outline: none;
  transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
}
textarea {
  height: auto;
  min-height: 104px;
  padding: 12px 13px;
  line-height: 1.5;
  resize: vertical;
}
select {
  appearance: none;
  padding-right: 38px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%2383948F' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
}
input::placeholder, textarea::placeholder { color: #B9AEA0; }
input:focus, select:focus, textarea:focus {
  border-color: var(--terra);
  box-shadow: 0 0 0 4px rgba(168,95,62,.13);
  background: #FFFDF9;
}
input.ok, select.ok, textarea.ok {
  border-color: rgba(47,118,81,.7);
  background: #F5FBF7;
}
.native-date {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.date-trigger {
  width: 100%;
  min-height: 58px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 38px;
  align-items: center;
  gap: 12px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.96), rgba(255,253,248,.9)),
    #fff;
  color: var(--ink);
  padding: 9px 10px 9px 14px;
  text-align: left;
  box-shadow: 0 6px 18px rgba(31,47,42,.05);
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease, background .16s ease;
}
.date-trigger:hover,
.date-trigger:focus-visible {
  border-color: var(--terra);
  box-shadow: 0 0 0 4px rgba(168,95,62,.12), 0 10px 24px rgba(31,47,42,.08);
  transform: translateY(-1px);
  outline: none;
}
.date-main {
  display: block;
  color: var(--forest);
  font-size: 15px;
  font-weight: 900;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.date-sub {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.date-trigger.no-sub .date-sub { display: none; }
.date-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--terra-wash);
  color: var(--terra);
}
.date-icon svg {
  width: 19px;
  height: 19px;
  stroke-width: 2;
}
.date-picker {
  position: fixed;
  width: 322px;
  max-width: calc(100vw - 24px);
  padding: 14px;
  border: 1px solid rgba(211,198,179,.95);
  border-radius: 8px;
  background: rgba(255,249,240,.98);
  box-shadow: 0 26px 70px rgba(31,47,42,.22);
  z-index: 90;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px) scale(.98);
  transition: opacity .16s ease, visibility .16s ease, transform .16s ease;
  backdrop-filter: blur(12px);
}
.date-picker.on {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}
.cal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}
.cal-month {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(86px, .75fr);
  gap: 8px;
  flex: 1;
  color: var(--forest);
  text-transform: capitalize;
}
.cal-select {
  width: 100%;
  height: 36px;
  border: 1px solid rgba(211,198,179,.95);
  border-radius: 8px;
  background-color: #FFFCF7;
  color: var(--forest);
  font-size: 12px;
  font-weight: 900;
  text-transform: none;
  padding: 0 30px 0 12px;
  box-shadow: 0 4px 12px rgba(31,47,42,.04);
}
.cal-select:focus {
  border-color: var(--terra);
  box-shadow: 0 0 0 3px rgba(168,95,62,.13);
}
.cal-nav {
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: #fff;
  color: var(--forest);
  font-size: 18px;
  font-weight: 900;
  line-height: 1;
  transition: border-color .16s ease, background .16s ease, color .16s ease;
}
.cal-nav:hover {
  border-color: var(--terra);
  background: var(--terra-wash);
  color: var(--terra);
}
.cal-week,
.cal-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 5px;
}
.date-picker.weekday-only .cal-week,
.date-picker.weekday-only .cal-days {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
.cal-week {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .08em;
  text-align: center;
  text-transform: uppercase;
}
.cal-week span { padding: 4px 0; }
.cal-day {
  aspect-ratio: 1;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
  transition: background .14s ease, border-color .14s ease, color .14s ease, transform .14s ease;
}
.cal-day:hover {
  border-color: rgba(168,95,62,.35);
  background: var(--terra-wash);
  color: var(--terra);
}
.cal-day.out {
  color: rgba(131,148,143,.42);
}
.cal-day.today {
  border-color: rgba(47,118,81,.28);
  background: rgba(47,118,81,.08);
}
.cal-day.sel {
  border-color: var(--terra);
  background: linear-gradient(135deg, var(--terra), var(--terra-light));
  color: #fff;
  box-shadow: 0 8px 18px rgba(168,95,62,.22);
}
.cal-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--cream-deep);
}
.cal-mini {
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  min-height: 34px;
  padding: 0 12px;
  font-size: 11px;
  font-weight: 900;
}
.cal-mini:hover {
  border-color: var(--terra);
  color: var(--terra);
  background: var(--terra-wash);
}
.hint {
  margin-top: 6px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}
.tel {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr);
  gap: 8px;
}

.guest {
  border-top: 1px solid var(--border);
  padding: 22px 30px 6px;
  background:
    linear-gradient(180deg, rgba(126,147,117,.07), transparent 160px),
    var(--paper);
}
.guest-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}
.guest-title {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.guest-num {
  width: 31px;
  height: 31px;
  flex: 0 0 31px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: white;
  background: linear-gradient(135deg, var(--terra), var(--terra-light));
  box-shadow: 0 7px 18px rgba(168,95,62,.22);
  font-size: 13px;
  font-weight: 800;
}
.guest-name {
  color: var(--forest);
  font-size: 15px;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lead-pill {
  flex: 0 0 auto;
  padding: 4px 10px;
  border-radius: 999px;
  color: var(--terra);
  border: 1px solid rgba(168,95,62,.25);
  background: var(--terra-wash);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.guest-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}
.mini-btn, .danger-btn, .scan-btn {
  height: 34px;
  border-radius: 8px;
  border: 1px solid rgba(168,95,62,.26);
  background: rgba(168,95,62,.08);
  color: var(--terra);
  padding: 0 13px;
  font-size: 12px;
  font-weight: 800;
  transition: transform .16s ease, background .16s ease, border-color .16s ease;
}
.mini-btn:hover, .danger-btn:hover, .scan-btn:hover { transform: translateY(-1px); border-color: rgba(168,95,62,.56); }
.danger-btn {
  border-color: rgba(169,58,55,.24);
  background: rgba(169,58,55,.07);
  color: var(--red);
}
.scan-btn {
  display: inline-flex;
  align-items: center;
  color: var(--forest);
  border-color: rgba(63,127,140,.24);
  background: rgba(63,127,140,.09);
}
.dni-btn {
  display: none;
  height: 36px;
  padding: 0 15px;
  border: none;
  border-radius: 8px;
  color: white;
  background: linear-gradient(135deg, #1B5DA8, #1F8AD6);
  box-shadow: 0 8px 22px rgba(31,116,190,.28);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .02em;
  transition: transform .16s ease, box-shadow .16s ease;
}
.dni-btn.visible { display: inline-flex; align-items: center; gap: 7px; }
.dni-btn:hover { transform: translateY(-1px); box-shadow: 0 12px 28px rgba(31,116,190,.34); }
.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 22px 0 16px;
  padding: 11px 14px;
  border-left: 3px solid var(--terra);
  border-radius: 0 8px 8px 0;
  background: linear-gradient(90deg, rgba(168,95,62,.12), rgba(126,147,117,.05));
  color: var(--terra);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.address-wrap { display: none; }
.address-wrap.on { display: block; }
.province-wrap { display: none; }
.province-wrap.on { display: grid; }

.add-btn {
  width: calc(100% - 60px);
  margin: 16px 30px 28px;
  height: 46px;
  border: 1.5px dashed var(--border);
  border-radius: 8px;
  background: rgba(255,255,255,.4);
  color: var(--muted);
  font-weight: 800;
  transition: background .16s ease, color .16s ease, border-color .16s ease, transform .16s ease;
}
.add-btn:hover {
  border-color: var(--terra);
  color: var(--terra);
  background: var(--terra-wash);
  transform: translateY(-1px);
}

.actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 22px 30px;
  background: rgba(244,238,227,.62);
  border-top: 1px solid var(--border);
}
.actions-centered { justify-content: center; }
.btn {
  min-width: 118px;
  height: 46px;
  border-radius: 8px;
  border: 1.5px solid transparent;
  padding: 0 22px;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: .01em;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease, border-color .16s ease;
}
.btn-main {
  color: white;
  background: linear-gradient(135deg, #B36E48, var(--terra) 52%, var(--terra-light));
  box-shadow: 0 8px 22px rgba(168,95,62,.24);
}
.btn-main:hover { transform: translateY(-1px); box-shadow: 0 12px 28px rgba(168,95,62,.3); }
.btn-main:disabled { opacity: .52; cursor: not-allowed; transform: none; box-shadow: none; }
.btn-back {
  color: var(--text);
  background: transparent;
  border-color: var(--border);
}
.btn-back:hover { border-color: var(--text); color: var(--forest); }

.summary { padding: 0 30px 6px; }
.summary-section { margin-bottom: 24px; }
.summary-heading {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .18em;
  text-transform: uppercase;
}
.summary-heading::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}
.summary-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 9px 0;
  border-bottom: 1px solid var(--cream-deep);
  font-size: 13px;
}
.summary-row span:first-child { color: var(--muted); }
.summary-row span:last-child { text-align: right; font-weight: 800; }
.guest-chip {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 12px;
  padding: 13px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--cream);
  margin-bottom: 9px;
}
.chip-num {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: white;
  background: var(--terra);
  font-size: 12px;
  font-weight: 900;
}
.chip-name { font-size: 13px; font-weight: 900; color: var(--forest); margin-bottom: 3px; }
.chip-detail { color: var(--muted); font-size: 11px; line-height: 1.6; }
.legal {
  margin: 0 30px 28px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--cream);
  color: var(--muted);
  font-size: 11px;
  line-height: 1.75;
}

.result {
  padding: 44px 30px 34px;
  text-align: center;
}
.result-mark {
  width: 62px;
  height: 62px;
  margin: 0 auto 18px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: white;
  background: var(--green);
  font-size: 30px;
  font-weight: 900;
  animation: pop .32s cubic-bezier(.16,1,.3,1);
}
.result-mark.err { background: var(--red); }
@keyframes pop {
  from { opacity: 0; transform: scale(.7); }
  to { opacity: 1; transform: none; }
}
.result-title {
  margin: 0 0 9px;
  color: var(--forest);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 32px;
  font-style: italic;
  font-weight: 500;
}
.result-sub {
  margin: 0 auto;
  max-width: 460px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.75;
  white-space: pre-line;
}
.result-sub.error { color: var(--red); }
.batch {
  display: inline-block;
  margin: 20px 0 6px;
  padding: 13px 24px;
  border: 2px dashed rgba(168,95,62,.42);
  border-radius: 8px;
  background: var(--terra-wash);
  color: var(--terra);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: .12em;
}
.xml-toggle {
  margin-top: 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  padding: 7px 14px;
  font-size: 11px;
  font-weight: 800;
}
.xml-box {
  display: none;
  max-height: 260px;
  overflow: auto;
  margin: 12px auto 0;
  padding: 16px;
  border-radius: 8px;
  background: #132823;
  color: rgba(245,242,235,.82);
  text-align: left;
  white-space: pre-wrap;
  word-break: break-word;
  font: 11px/1.55 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.xml-box.on { display: block; }

.loader {
  position: fixed;
  inset: 0;
  display: none;
  place-items: center;
  z-index: 50;
  padding: 24px;
  background: rgba(31,47,42,.68);
  backdrop-filter: blur(8px);
}
.loader.on { display: grid; }
.loader-box {
  width: min(360px, 100%);
  padding: 34px 30px;
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 24px 80px rgba(0,0,0,.24);
  text-align: center;
}
.spinner {
  width: 42px;
  height: 42px;
  margin: 0 auto 16px;
  border-radius: 50%;
  border: 3px solid var(--cream-deep);
  border-top-color: var(--terra);
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loader-title {
  color: var(--forest);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 22px;
  font-style: italic;
  font-weight: 500;
}
.loader-sub { margin-top: 4px; color: var(--muted); font-size: 12px; }

.qr-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 28px;
  background: rgba(8,13,12,.93);
  color: white;
}
.qr-overlay.on { display: flex; }
.qr-stage {
  position: relative;
  width: min(340px, 86vw);
  aspect-ratio: 1;
  border-radius: 20px;
  overflow: hidden;
  background: #000;
  box-shadow: 0 24px 70px rgba(0,0,0,.42);
}
#qrVideo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
#qrCanvas { display: none; }
.qr-frame {
  position: absolute;
  inset: 18%;
  border: 3px solid var(--terra-light);
  border-radius: 16px;
  box-shadow: 0 0 0 999px rgba(0,0,0,.18);
  pointer-events: none;
}
.qr-title {
  margin: 22px 0 7px;
  font-size: 15px;
  font-weight: 900;
  text-align: center;
}
.qr-hint {
  max-width: 360px;
  color: rgba(255,255,255,.7);
  text-align: center;
  font-size: 13px;
  line-height: 1.6;
}
.qr-status {
  min-height: 21px;
  margin-top: 11px;
  color: var(--terra-light);
  font-size: 12px;
  font-weight: 900;
  text-align: center;
}
.qr-status.ok { color: #72D393; }
.qr-status.err { color: #F08C86; }
.qr-close {
  margin-top: 22px;
  height: 44px;
  padding: 0 28px;
  border-radius: 999px;
  border: 1.5px solid rgba(255,255,255,.28);
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.82);
  font-weight: 900;
}

.doc-overlay {
  position: fixed;
  inset: 0;
  z-index: 85;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(17,29,25,.78);
  backdrop-filter: blur(10px);
}
.doc-overlay.on { display: flex; }
.doc-panel {
  position: relative;
  width: min(520px, 100%);
  max-height: min(760px, calc(100vh - 36px));
  overflow: auto;
  padding: 26px;
  border: 1px solid rgba(211,198,179,.92);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 28px 90px rgba(0,0,0,.35);
}
.doc-x {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: rgba(255,255,255,.55);
  color: var(--muted);
  font-size: 20px;
  line-height: 1;
}
.doc-title {
  margin-right: 34px;
  color: var(--forest);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 32px;
  font-style: italic;
  font-weight: 500;
  line-height: 1.05;
}
.doc-hint {
  margin: 8px 42px 18px 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}
.doc-file {
  width: 100%;
  min-height: 92px;
  display: grid;
  place-items: center;
  margin-bottom: 14px;
  border: 1.5px dashed rgba(63,127,140,.42);
  border-radius: 8px;
  background: rgba(63,127,140,.08);
  color: var(--sea);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: none;
}
.doc-file input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.doc-preview {
  display: none;
  width: 100%;
  max-height: 180px;
  object-fit: contain;
  margin: 0 0 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
}
.doc-preview.on { display: block; }
#docCanvas { display: none; }
.doc-status {
  min-height: 22px;
  margin-top: 12px;
  color: var(--terra);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.45;
}
.doc-status.ok { color: var(--green); }
.doc-status.err { color: var(--red); }

@media (max-width: 680px) {
  .top { min-height: 480px; }
  .top::before { background-position: center top; transform: scale(1.04); }
  .top::after {
    background:
      linear-gradient(180deg, rgba(23,34,30,.18), rgba(23,34,30,.58) 62%, rgba(244,238,227,.98)),
      linear-gradient(90deg, rgba(23,34,30,.22), transparent 48%, rgba(23,34,30,.24));
  }
  .top-inner {
    min-height: 480px;
    padding-left: 16px;
    padding-right: 16px;
    padding-bottom: 64px;
  }
  .lang-bar { gap: 5px; margin-bottom: 8px; }
  .lang-btn { min-width: 36px; height: 32px; font-size: 11px; }
  .brand { gap: 8px; }
  .kicker { font-size: 10px; letter-spacing: .18em; }
  .title { max-width: 340px; font-size: clamp(52px, 16vw, 76px); line-height: .88; }
  .property { font-size: clamp(30px, 9vw, 42px); line-height: 1; }
  .rule { margin-top: 0; }
  .hero-copy { max-width: 330px; margin: 0 0 4px; font-size: 12px; line-height: 1.55; }
  .hero-facts { gap: 6px; }
  .hero-facts span {
    max-width: 100%;
    min-height: 28px;
    justify-content: center;
    text-align: center;
    padding: 6px 10px;
    font-size: 9px;
    letter-spacing: .1em;
  }
  .main { width: min(100% - 18px, 760px); margin-top: -48px; margin-bottom: 48px; }
  .progress-panel { padding: 13px 8px 12px; }
  .steps { grid-template-columns: 1fr 25px 1fr 25px 1fr; }
  .step-node { width: 34px; height: 34px; font-size: 12px; }
  .step-label { font-size: 8px; letter-spacing: .09em; }
  .step-line { margin-top: 16px; }
  .card-head, .fields, .guest { padding-left: 16px; padding-right: 16px; }
  .card-head { padding-top: 22px; }
  .card-title { font-size: 27px; }
  .card-sub { margin-bottom: 18px; font-size: 12px; line-height: 1.55; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; gap: 13px; margin-bottom: 13px; }
  .actions { padding: 16px; flex-direction: column-reverse; }
  .actions .btn { width: 100%; }
  .add-btn { width: calc(100% - 32px); margin-left: 16px; margin-right: 16px; }
  .summary { padding-left: 16px; padding-right: 16px; }
  .legal { margin-left: 16px; margin-right: 16px; }
  .guest { padding-top: 18px; }
  .guest-head { align-items: flex-start; gap: 10px; }
  .guest-title { flex: 1 1 auto; min-width: 0; }
  .guest-actions { flex: 0 0 auto; flex-wrap: wrap; justify-content: flex-end; max-width: 220px; }
  .dni-btn, .danger-btn, .mini-btn, .scan-btn { min-height: 36px; }
  .section-title { align-items: flex-start; flex-direction: column; gap: 8px; }
  .section-title .mini-btn { width: 100%; }
  .tel { grid-template-columns: 116px minmax(0,1fr); }
  input, select, textarea { font-size: 16px; }
  input, select { height: 48px; }
  textarea { min-height: 112px; }
  .date-trigger { min-height: 60px; }
  .btn, .add-btn { height: 50px; }
  .summary-row { align-items: flex-start; font-size: 12px; }
  .guest-chip { grid-template-columns: 26px minmax(0,1fr); padding: 11px; }
  .tip-pop {
    bottom: auto;
    top: calc(100% + 9px);
    width: min(320px, calc(100vw - 34px));
  }
  .tip-pop::after {
    top: auto;
    bottom: 100%;
    border-top-color: transparent;
    border-bottom-color: var(--forest);
  }
  .date-picker {
    left: 10px !important;
    right: 10px;
    bottom: max(10px, env(safe-area-inset-bottom));
    top: auto !important;
    width: auto;
    max-width: none;
      border-radius: 8px;
    transform: translateY(18px);
  }
  .date-picker.on { transform: translateY(0); }
  .cal-day { border-radius: 8px; font-size: 14px; }
  .doc-panel { max-height: calc(100vh - 28px); padding: 22px 16px 16px; }
  .doc-title { font-size: 28px; }
  .doc-hint { margin-right: 34px; }
}

@media (max-width: 420px) {
  .lang-bar { justify-content: center; flex-wrap: wrap; }
  .top { min-height: 455px; }
  .top-inner { min-height: 455px; padding-bottom: 58px; }
  .title { font-size: clamp(48px, 15vw, 62px); line-height: .9; }
  .property { font-size: 29px; }
  .hero-copy { max-width: 292px; font-size: 11px; }
  .hero-facts span { font-size: 8px; }
  .main { width: calc(100% - 14px); margin-top: -42px; }
  .progress-panel { border-radius: 8px; }
  .steps { grid-template-columns: 1fr 18px 1fr 18px 1fr; }
  .step-node { width: 31px; height: 31px; box-shadow: none; }
  .step-item.cur .step-node { box-shadow: 0 0 0 4px rgba(168,95,62,.13), 0 6px 16px rgba(168,95,62,.22); }
  .step-label { max-width: 74px; font-size: 7px; letter-spacing: .07em; }
  .card { border-radius: 8px; }
  .card-head, .fields, .guest { padding-left: 12px; padding-right: 12px; }
  .card-title { font-size: 25px; }
  .notice { font-size: 12px; padding: 12px; }
  .lead-pill { display: none; }
  .guest-name { white-space: normal; }
  .guest-actions { max-width: 170px; }
  .dni-btn, .scan-btn { padding: 0 11px; font-size: 11px; }
  .danger-btn { padding: 0 10px; font-size: 11px; }
  .tel { grid-template-columns: 1fr; }
  .date-main { font-size: 14px; }
  .date-sub { font-size: 10px; }
  .date-icon { width: 36px; height: 36px; }
  .date-picker { padding: 12px; }
  .cal-head { gap: 7px; }
  .cal-month { gap: 6px; grid-template-columns: minmax(0, 1.1fr) minmax(78px, .9fr); }
  .cal-select { height: 34px; font-size: 11px; padding-left: 10px; }
  .cal-nav { width: 34px; height: 34px; }
  .cal-week, .cal-days { gap: 4px; }
  .legal { margin-left: 12px; margin-right: 12px; }
  .summ-row, .summary-row { flex-direction: column; gap: 3px; }
  .summary-row span:last-child { text-align: left; }
  .result { padding-left: 18px; padding-right: 18px; }
  .qr-overlay { padding: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
}
