/* =========================================================
   Mausoleo Digital — "Mi Historia"
   Extiende styles.css (tokens, fuentes, .wrap, .btn, .icon, reveal).
   Mobile first: se diseña a 390px y se amplía hacia desktop.
   Prioridad: legibilidad para adultos mayores (texto ≥ 16px,
   objetivos táctiles ≥ 48px, icono + texto siempre).
   ========================================================= */

:root {
  --md-paper: #FFFDF9;
  --md-line: #E9E3EC;
  --md-soft: #F7F3F8;
  --md-ink-2: #3A3340;
  --md-rec: #C8352E;         /* rojo de grabación (solo el punto) */
  --md-radius: 18px;
  --md-shadow: 0 18px 40px -26px rgba(42, 15, 59, .35);
}

/* ---------- Botones que agrega esta sección ---------- */
.btn--primary {
  background: var(--jp-purple); color: #fff; border-color: var(--jp-purple);
  box-shadow: 0 8px 20px -12px rgba(75, 36, 100, .6);
}
.btn--primary:hover { background: var(--jp-purple-dark); border-color: var(--jp-purple-dark); }
.btn--primary:disabled { background: #B9AEC0; border-color: #B9AEC0; box-shadow: none; cursor: not-allowed; }
.btn--outline { color: var(--jp-purple); border-color: rgba(75, 36, 100, .45); background: #fff; }
.btn--outline:hover { border-color: var(--jp-purple); background: var(--jp-purple-light); }
.btn--lg { min-height: 56px; padding: 16px 28px; font-size: 17px; font-weight: 600; }
.btn { justify-content: center; cursor: pointer; }
.btn .icon { font-size: 19px; }

.md-textlink {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 8px 6px;
  font: 600 16px/1.3 var(--font-sans); color: var(--jp-purple);
  background: none; border: 0; cursor: pointer; text-decoration: underline;
  text-decoration-color: rgba(75, 36, 100, .35); text-underline-offset: 5px;
}
.md-textlink:hover { text-decoration-color: currentColor; }
.md-textlink .icon { font-size: 18px; }

.md-stepx__num, .md-film__num, .md-ring__num, .md-card__time, .md-memcard__years, .md-camera__time, .md-voice__time,
.md-question__count, .md-letter__to { font-variant-numeric: lining-nums tabular-nums; }

.md-eyebrow {
  font: 600 13px/1.2 var(--font-sans); letter-spacing: .22em; text-transform: uppercase;
  color: var(--jp-purple); margin-bottom: 18px;
}
.md-title {
  font-family: var(--font-serif); font-weight: 500;
  font-size: clamp(36px, 4.4vw, 60px); line-height: 1.04; letter-spacing: -.01em;
}
.md-title--sm { font-size: clamp(32px, 3.4vw, 46px); }
.md-lead { font-size: 18px; line-height: 1.6; color: var(--jp-muted); }
.md-note, .md-private {
  display: flex; align-items: flex-start; gap: 10px;
  font-size: 15.5px; line-height: 1.45; color: var(--jp-muted);
}
.md-note .icon, .md-private .icon { font-size: 18px; color: var(--jp-purple); margin-top: 2px; }
.md-hint { font-size: 16px; line-height: 1.5; color: var(--jp-muted); }

/* ---------- Reproducir (compartido: wizard y landing) ---------- */
.md-play {
  display: grid; place-items: center; width: 58px; height: 58px; border-radius: 50%;
  background: rgba(255, 255, 255, .92); color: var(--jp-purple);
  box-shadow: 0 10px 24px -12px rgba(42, 15, 59, .5);
}
.md-play .icon { font-size: 24px; margin-left: 3px; }
.icon .fill { fill: currentColor; stroke: none; }

/* ---------- Aviso breve (simulaciones) ---------- */
.md-toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 90; transform: translateX(-50%);
  width: min(92vw, 520px); padding: 16px 20px; border-radius: 14px;
  background: var(--jp-text); color: #fff; font-size: 16px; line-height: 1.45;
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .6);
}

/* =========================================================
   EXPERIENCIA "MI HISTORIA" (wizard y panel)
   ========================================================= */
.md-app-body { background: var(--jp-ivory); font-size: 18px; }
.md-apphead { position: sticky; top: 0; z-index: 40; background: rgba(255, 255, 255, .97); border-bottom: 1px solid var(--md-line); }
.md-apphead__inner {
  display: flex; align-items: center; gap: 12px; height: 64px;
  width: min(100% - 32px, 1100px); margin-inline: auto;
}
.md-apphead__brand { display: inline-flex; align-items: center; min-height: 48px; }
.md-apphead__brand img { height: 42px; width: auto; }
.md-apphead__title {
  flex: 1; text-align: center;
  font: 600 13px/1 var(--font-sans); letter-spacing: .22em; text-transform: uppercase; color: var(--jp-purple);
}
.md-apphead__exit {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border-radius: 999px;
  border: 1px solid rgba(75, 36, 100, .35); color: var(--jp-purple); text-decoration: none;
  font-size: 15px; font-weight: 600; white-space: nowrap;
}
.md-apphead__exit:hover { background: var(--jp-purple-light); }
.md-apphead__form { margin: 0; }
button.md-apphead__exit { background: #fff; font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; }
button.md-apphead__exit:hover { background: var(--jp-purple-light); }

/* ---------- Entrar / crear cuenta ---------- */
.md-acceso { max-width: 460px; margin-inline: auto; padding-top: 8px; }
.md-acceso__title { font-family: var(--font-serif); font-weight: 500; font-size: clamp(38px, 10vw, 52px); line-height: 1.05; }
.md-acceso__lead { margin: 12px 0 26px; font-size: 18px; line-height: 1.55; color: var(--md-ink-2); }
.md-acceso .btn { width: 100%; margin-top: 6px; }
.md-acceso__alt { margin-top: 22px; text-align: center; font-size: 17px; color: var(--jp-muted); }
.md-acceso__alt a { color: var(--jp-purple); font-weight: 600; }
.md-acceso__privado { justify-content: center; margin-top: 18px; }
.md-field__help { display: block; margin-top: 6px; font-size: 15px; color: var(--jp-muted); }
.md-field__error { display: block; margin-top: 6px; font-size: 16px; font-weight: 600; color: #A3261F; }
.md-field input[aria-invalid="true"] { border-color: #A3261F; }
.md-aviso { padding: 14px 16px; border-radius: 12px; margin-bottom: 20px; font-size: 16px; line-height: 1.45; }
.md-aviso--error { background: #FBEAE8; color: #7E1D17; }
.md-aviso--ok { background: #E3F1E7; color: #1F5132; }
.md-saveerror { margin-top: 10px; text-align: center; font-size: 16px; font-weight: 600; color: #A3261F; }
.md-autosave.is-error { color: #A3261F; }

.md-appmain { width: min(100% - 40px, 720px); margin-inline: auto; padding: 22px 0 40px; }
.md-appfoot { padding: 28px 20px 110px; text-align: center; font-size: 15px; color: var(--jp-muted); border-top: 1px solid var(--md-line); background: #fff; }
.md-appfoot p { display: flex; justify-content: center; align-items: center; gap: 8px; flex-wrap: wrap; }
.md-appfoot .icon { color: var(--jp-purple); font-size: 17px; }
.md-appfoot__links { margin-top: 10px; gap: 6px 22px !important; }
.md-appfoot__links a { color: var(--jp-purple); font-weight: 600; min-height: 44px; display: inline-flex; align-items: center; }
.md-appfoot__proto { margin-top: 6px; font-size: 14px; }

/* ---------- Progreso ---------- */
.md-progress { margin-bottom: 30px; }
.md-progress__top { display: flex; justify-content: space-between; align-items: center; gap: 10px 16px; flex-wrap: wrap; margin-bottom: 16px; }
.md-progress__label { font-size: 16px; color: var(--jp-muted); }
.md-progress__label strong { color: var(--jp-text); font-weight: 600; }
.md-autosave { display: inline-flex; align-items: center; gap: 6px; font-size: 15px; color: #2E6B45; }
.md-autosave .icon { font-size: 17px; }
.md-autosave.is-saving { color: var(--jp-muted); }

.md-stepper { list-style: none; margin: 0; padding: 0; display: flex; }
.md-stepper__item { position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; text-align: center; }
.md-stepper__item::before {
  content: ""; position: absolute; top: 11px; right: 50%; width: 100%; height: 2px; background: var(--md-line);
}
.md-stepper__item:first-child::before { display: none; }
.md-stepper__item.is-done::before, .md-stepper__item.is-current::before { background: var(--jp-purple); }
.md-stepper__dot {
  position: relative; z-index: 1; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%;
  background: #fff; border: 2px solid #CFC5D6; color: #fff;
}
.md-stepper__dot .icon { font-size: 14px; stroke-width: 2.4; opacity: 0; }
.md-stepper__item.is-done .md-stepper__dot { background: var(--jp-purple); border-color: var(--jp-purple); }
.md-stepper__item.is-done .md-stepper__dot .icon { opacity: 1; }
.md-stepper__item.is-current .md-stepper__dot { border-color: var(--jp-purple); box-shadow: 0 0 0 5px var(--jp-purple-tint); background: var(--jp-purple); }
.md-stepper__name { display: none; margin-top: 10px; font-size: 14px; line-height: 1.25; color: var(--jp-muted); }
.md-stepper__item.is-current .md-stepper__name { color: var(--jp-text); font-weight: 600; }
.md-progress__current { margin-top: 14px; text-align: center; font: 600 14px/1 var(--font-sans); letter-spacing: .18em; text-transform: uppercase; color: var(--jp-purple); }

/* ---------- Paso ---------- */
.md-step__intro { margin-bottom: 26px; }
.md-step__title { font-family: var(--font-serif); font-weight: 500; font-size: clamp(38px, 10vw, 56px); line-height: 1.04; letter-spacing: -.01em; }
.md-step__title:focus { outline: none; }
.md-step__lead { margin-top: 14px; font-size: 18px; line-height: 1.55; color: var(--md-ink-2); }

.md-question {
  padding: 26px 0 8px; border-top: 1px solid var(--md-line); margin-bottom: 22px;
}
.md-question__count { font: 600 14px/1 var(--font-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--jp-purple); margin-bottom: 12px; }
.md-question__title { font-family: var(--font-serif); font-weight: 500; font-size: clamp(32px, 8.4vw, 44px); line-height: 1.1; color: var(--jp-text); }
.md-question__help { margin-top: 12px; font-size: 18px; line-height: 1.55; color: var(--jp-muted); }

/* Chips de ayuda */
.md-chips { margin-top: 20px; }
.md-chips__label { font-size: 16px; color: var(--md-ink-2); margin-bottom: 12px; }
.md-chips__list { display: flex; flex-wrap: wrap; gap: 10px; }
.md-chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 48px; padding: 10px 18px; border-radius: 999px;
  background: #fff; border: 1px solid #D9CFE0; color: var(--jp-text); font: 500 16px/1.2 var(--font-sans); cursor: pointer;
  transition: background-color .2s var(--ease), border-color .2s var(--ease), color .2s var(--ease);
}
.md-chip:hover { border-color: var(--jp-purple); }
.md-chip[aria-pressed="true"], .md-chip--radio:has(input:checked) { background: var(--jp-purple); border-color: var(--jp-purple); color: #fff; }
.md-chip[aria-pressed="true"]::before { content: "✓"; font-weight: 700; }
.md-chip--radio input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.md-chip--radio:has(input:focus-visible) { outline: 2px solid var(--jp-purple); outline-offset: 3px; }

/* ---------- Composer: cómo contarlo ---------- */
.md-composer__ask { font-size: 17px; font-weight: 600; margin-bottom: 14px; }
.md-options { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.md-option {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  min-height: 112px; padding: 16px 10px; border-radius: 16px;
  background: #fff; border: 1.5px solid #DDD3E3; color: var(--jp-text);
  font: 600 17px/1.2 var(--font-sans); cursor: pointer; text-align: center;
  transition: border-color .2s var(--ease), background-color .2s var(--ease), transform .2s var(--ease);
}
.md-option .icon { font-size: 32px; color: var(--jp-purple); stroke-width: 1.4; }
.md-option:hover { border-color: var(--jp-purple); }
.md-option:active { transform: scale(.98); }
.md-option[aria-pressed="true"] { border-color: var(--jp-purple); background: var(--jp-purple-light); box-shadow: inset 0 0 0 1px var(--jp-purple); }
.md-composer.has-mode .md-options { grid-template-columns: repeat(4, 1fr); gap: 8px; }
.md-composer.has-mode .md-option { min-height: 76px; font-size: 14px; gap: 6px; padding: 10px 4px; }
.md-composer.has-mode .md-option .icon { font-size: 24px; }

.md-panel { margin-top: 18px; }
.md-camera {
  position: relative; display: grid; place-items: center; aspect-ratio: 4 / 3; border-radius: 18px; overflow: hidden;
  background: radial-gradient(90% 90% at 50% 40%, #4A4250 0%, #2A252F 70%);
  color: rgba(255, 255, 255, .85);
}
.md-camera::after {
  content: ""; position: absolute; inset: 14px; border-radius: 10px; pointer-events: none;
  background:
    linear-gradient(#fff, #fff) top left / 22px 2px no-repeat, linear-gradient(#fff, #fff) top left / 2px 22px no-repeat,
    linear-gradient(#fff, #fff) top right / 22px 2px no-repeat, linear-gradient(#fff, #fff) top right / 2px 22px no-repeat,
    linear-gradient(#fff, #fff) bottom left / 22px 2px no-repeat, linear-gradient(#fff, #fff) bottom left / 2px 22px no-repeat,
    linear-gradient(#fff, #fff) bottom right / 22px 2px no-repeat, linear-gradient(#fff, #fff) bottom right / 2px 22px no-repeat;
  opacity: .45;
}
.md-camera__label { position: absolute; left: 24px; top: 22px; font-size: 14px; letter-spacing: .12em; text-transform: uppercase; opacity: .8; }
.md-camera__time, .md-voice__time {
  position: absolute; right: 22px; top: 18px; display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 999px; background: rgba(0, 0, 0, .35); color: #fff;
  font: 600 17px/1 var(--font-sans); font-variant-numeric: tabular-nums;
}
.md-camera__face .icon { font-size: 96px; stroke-width: .9; opacity: .35; }
.md-dot { width: 10px; height: 10px; border-radius: 50%; background: rgba(255, 255, 255, .5); }
.is-recording .md-dot { background: var(--md-rec); }
@media (prefers-reduced-motion: no-preference) {
  .is-recording .md-dot { animation: md-blink 1.2s ease-in-out infinite; }
}
@keyframes md-blink { 50% { opacity: .25; } }
.is-recorded .md-camera { background: radial-gradient(90% 90% at 50% 40%, #5A4F63 0%, #342C3B 70%); }

.md-voice {
  position: relative; display: grid; place-items: center; height: 170px; border-radius: 18px;
  background: #fff; border: 1px solid var(--md-line);
}
.md-voice__time { background: var(--jp-purple-light); color: var(--jp-purple); top: 14px; right: 14px; }
.md-voice__time .md-dot { background: rgba(75, 36, 100, .35); }
.md-voice__bars { display: flex; align-items: center; gap: 4px; height: 70px; width: 78%; }
.md-voice__bars i { flex: 1; height: 12%; border-radius: 3px; background: var(--jp-purple); opacity: .35; transition: height .25s var(--ease); }
.is-recording .md-voice__bars i, .is-recorded .md-voice__bars i { opacity: .85; }

.md-recbar { display: flex; justify-content: center; margin: 18px 0 10px; }
.md-rec {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 60px; min-width: 260px;
  padding: 14px 28px; border-radius: 999px; background: #fff; border: 1.5px solid var(--jp-text); color: var(--jp-text);
  font: 600 18px/1.2 var(--font-sans); cursor: pointer;
}
.md-rec__dot { width: 18px; height: 18px; border-radius: 50%; background: var(--md-rec); flex: none; }
.is-recording .md-rec { background: var(--jp-text); color: #fff; }
.is-recording .md-rec__dot { border-radius: 4px; background: #fff; }
.md-panel .md-hint, .md-modal .md-hint { text-align: center; }

.md-field { display: block; border: 0; margin: 0 0 18px; padding: 0; min-width: 0; }
.md-field__label { display: block; font-size: 16px; font-weight: 600; color: var(--jp-text); margin-bottom: 8px; padding: 0; }
.md-field input[type="text"], .md-field input[type="tel"], .md-field input[type="email"], .md-field input[type="password"], .md-field textarea {
  width: 100%; min-height: 56px; padding: 14px 16px; border-radius: 12px; border: 1.5px solid #D6CCDD; background: #fff;
  font: 400 18px/1.4 var(--font-sans); color: var(--jp-text);
}
.md-field textarea { min-height: 170px; resize: vertical; line-height: 1.55; }
.md-field input:focus, .md-field textarea:focus { outline: none; border-color: var(--jp-purple); box-shadow: 0 0 0 3px var(--jp-purple-tint); }
.md-field ::placeholder { color: #8D8494; }

.md-photos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 16px; }
.md-photos:empty { display: none; }
.md-photos li {
  display: grid; place-items: center; aspect-ratio: 1; border-radius: 12px; color: rgba(75, 36, 100, .7);
  font-size: 13px; text-align: center; padding: 6px;
}
.md-photos li .icon { font-size: 26px; }
.md-photos li:nth-child(3n+1) { background: linear-gradient(150deg, #F3E4D4, #E4D2EA); }
.md-photos li:nth-child(3n+2) { background: linear-gradient(150deg, #E3EBDD, #F2E7D8); }
.md-photos li:nth-child(3n+3) { background: linear-gradient(150deg, #E6E0F0, #F6EADF); }
.md-photos__add { width: 100%; margin-bottom: 10px; }

.md-composer__actions, .md-saved { display: grid; gap: 8px; margin-top: 22px; }
.md-composer__actions .btn, .md-saved .btn { width: 100%; }
.md-composer__actions[hidden], .md-saved[hidden] { display: none; }
.md-saved { padding: 22px 20px 16px; border-radius: 16px; background: #fff; border: 1px solid var(--md-line); text-align: center; }
.md-saved__msg { display: inline-flex; align-items: center; justify-content: center; gap: 10px; font-family: var(--font-serif); font-size: 28px; font-weight: 500; }
.md-saved__msg:focus { outline: none; }
.md-saved__icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: #E3F1E7; color: #2E6B45; }
.md-saved__icon .icon { font-size: 20px; stroke-width: 2.2; }
.md-saved__detail { font-size: 16px; color: var(--jp-muted); margin-bottom: 10px; }
.md-composer .md-private { margin-top: 22px; }

/* ---------- Mensajes ---------- */
.md-people { display: grid; gap: 14px; margin-bottom: 14px; }
.md-person {
  display: grid; gap: 14px; padding: 22px 20px 20px; border-radius: var(--md-radius);
  background: #fff; border: 1px solid var(--md-line);
}
.md-person.is-done { background: var(--md-paper); }
.md-person__head { display: flex; align-items: center; gap: 16px; }
.md-person__initial {
  flex: none; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%;
  background: var(--jp-purple-light); color: var(--jp-purple); font-family: var(--font-serif); font-size: 28px; font-weight: 600;
}
.md-person__name { font-family: var(--font-serif); font-size: 32px; line-height: 1; font-weight: 500; text-transform: uppercase; letter-spacing: .04em; }
.md-person__rel { margin-top: 6px; font-size: 16px; color: var(--jp-muted); }
.md-person__status { display: flex; align-items: center; gap: 10px; font-size: 17px; color: #2E6B45; }
.md-person__status .icon { font-size: 22px; }
.md-person__status--empty { color: var(--jp-muted); font-style: italic; }
.md-person__btn { width: 100%; min-height: 54px; font-size: 17px; font-weight: 600; }
.md-addperson {
  display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 60px;
  border-radius: var(--md-radius); border: 1.5px dashed rgba(75, 36, 100, .45); background: transparent;
  color: var(--jp-purple); font: 600 17px/1.2 var(--font-sans); cursor: pointer; margin-bottom: 18px;
}
.md-addperson:hover { background: var(--jp-purple-light); }
.md-addperson .icon { font-size: 22px; }
.md-newperson { padding: 22px 20px; border-radius: var(--md-radius); background: #fff; border: 1px solid var(--md-line); margin-bottom: 22px; }
.md-newperson__title { font-family: var(--font-serif); font-size: 28px; margin-bottom: 18px; }
.md-newperson__actions { display: grid; gap: 6px; margin-top: 10px; }
.md-formerror { color: #A3261F; font-size: 16px; font-weight: 600; margin: 4px 0 8px; }

/* ---------- Videografía ---------- */
.md-cover { margin-bottom: 26px; }
.md-cover__art {
  position: relative; display: flex; flex-direction: column; justify-content: flex-end; aspect-ratio: 16 / 10;
  padding: 26px 24px; border-radius: 20px; overflow: hidden; color: #fff; margin-bottom: 18px;
  background:
    radial-gradient(80% 90% at 85% 10%, rgba(255, 210, 122, .45) 0%, rgba(255, 210, 122, 0) 60%),
    radial-gradient(70% 80% at 0% 100%, rgba(196, 58, 128, .35) 0%, rgba(196, 58, 128, 0) 65%),
    linear-gradient(135deg, #5A2E78 0%, var(--jp-purple) 45%, #2E0F42 100%);
  box-shadow: 0 26px 50px -30px rgba(42, 15, 59, .8);
}
.md-cover__kicker { font: 600 13px/1 var(--font-sans); letter-spacing: .3em; text-transform: uppercase; color: var(--jp-gold); margin-bottom: 12px; }
.md-cover__name { font-family: var(--font-serif); font-size: clamp(38px, 11vw, 60px); line-height: 1; font-weight: 500; overflow-wrap: anywhere; }
.md-cover__sub { margin-top: 10px; font-family: var(--font-serif); font-style: italic; font-size: 20px; opacity: .85; }
.md-cover__field { margin: 0; }

.md-film { list-style: none; margin: 0 0 18px; padding: 0; border-top: 1px solid var(--md-line); }
.md-film li { display: grid; grid-template-columns: 44px 1fr; gap: 2px 12px; align-items: baseline; padding: 16px 0; border-bottom: 1px solid var(--md-line); }
.md-film__num { grid-row: span 2; font-family: var(--font-serif); font-size: 30px; color: rgba(75, 36, 100, .45); line-height: 1; }
.md-film__name { font-family: var(--font-serif); font-size: 26px; line-height: 1.1; }
.md-film__count { font-size: 16px; color: var(--jp-muted); }
.md-film__duration { display: flex; align-items: center; gap: 8px; font-size: 17px; color: var(--md-ink-2); margin-bottom: 24px; }
.md-film__duration .icon { color: var(--jp-purple); font-size: 20px; }
.md-film__actions { display: grid; gap: 12px; }
.md-film__actions .btn { width: 100%; }

/* ---------- Compartir ---------- */
.md-recipientf { border: 0; margin: 0 0 16px; padding: 22px 20px 6px; border-radius: var(--md-radius); background: #fff; border: 1px solid var(--md-line); min-width: 0; }
.md-recipientf__title { float: left; width: 100%; padding: 0; margin-bottom: 18px; font-family: var(--font-serif); font-size: 26px; font-weight: 500; }
.md-recipientf__title + * { clear: both; }
.md-recipientf__remove { margin: -6px 0 10px; }
.md-checks { display: grid; gap: 10px; }
.md-check { position: relative; display: block; cursor: pointer; }
.md-check input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.md-check span {
  display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 12px 16px 12px 52px; border-radius: 12px;
  border: 1.5px solid #D6CCDD; background: #fff; font-size: 17px; font-weight: 500; position: relative;
}
.md-check span::before {
  content: ""; position: absolute; left: 16px; top: 50%; width: 22px; height: 22px; margin-top: -11px; border-radius: 6px;
  border: 2px solid #B9AEC0; background: #fff;
}
.md-check input:checked + span { border-color: var(--jp-purple); background: var(--jp-purple-light); }
.md-check input:checked + span::before {
  border-color: var(--jp-purple); background: var(--jp-purple)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 16px no-repeat;
}
.md-check input:focus-visible + span { outline: 2px solid var(--jp-purple); outline-offset: 3px; }
.md-check .icon { font-size: 22px; color: var(--jp-purple); }
.md-when { margin: 8px 0 24px; }
.md-when__opt {
  display: flex; gap: 12px; align-items: flex-start; padding: 16px; border-radius: 12px; margin-bottom: 10px;
  border: 1.5px solid #D6CCDD; background: #fff; font-size: 16px; line-height: 1.45; color: var(--jp-muted); cursor: pointer;
}
.md-when__opt input { margin-top: 4px; width: 20px; height: 20px; accent-color: var(--jp-purple); flex: none; }
.md-when__opt strong { display: block; color: var(--jp-text); font-size: 17px; }
.md-when__opt.is-selected { border-color: var(--jp-purple); background: var(--jp-purple-light); }
.md-when__opt.is-future { border-style: dashed; cursor: default; opacity: .8; }
.md-share__submit { width: 100%; margin-bottom: 16px; }

/* ---------- Navegación inferior ---------- */
.md-bottom {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 12px max(16px, calc((100% - 720px) / 2)) calc(12px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, .97); border-top: 1px solid var(--md-line);
  box-shadow: 0 -10px 30px -24px rgba(42, 15, 59, .5);
}
.md-back {
  display: inline-flex; align-items: center; gap: 6px; min-height: 56px; padding: 0 16px 0 8px;
  background: none; border: 0; color: var(--jp-text); font: 600 17px/1 var(--font-sans); cursor: pointer; border-radius: 12px;
}
.md-back .icon { font-size: 22px; }
.md-back:hover { background: var(--md-soft); }
.md-back[disabled] { visibility: hidden; }
.md-continue { min-height: 56px; padding: 0 26px; font-size: 17px; font-weight: 600; }

/* ---------- Modal ---------- */
.md-modal {
  width: min(100% - 24px, 560px); max-height: calc(100% - 24px); padding: 0; border: 0; border-radius: 22px;
  background: #fff; color: var(--jp-text); box-shadow: 0 30px 80px -30px rgba(20, 8, 28, .6);
}
.md-modal::backdrop { background: rgba(31, 18, 40, .55); }
.md-modal__body { padding: 30px 22px 22px; text-align: center; }
.md-modal__title { font-family: var(--font-serif); font-weight: 500; font-size: 32px; line-height: 1.1; margin-bottom: 10px; }
.md-modal__text { font-size: 17px; line-height: 1.55; color: var(--jp-muted); margin-bottom: 16px; }
.md-modal__text--small { font-size: 15.5px; }
.md-modal__actions { display: grid; gap: 6px; margin-top: 16px; }
.md-modal__actions .btn { width: 100%; }
.md-modal .md-camera { margin: 10px 0 0; }
.md-proto { margin-top: 12px; font-size: 14px; color: var(--jp-muted); }
.md-making__icon {
  display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; margin-bottom: 14px;
  background: var(--jp-purple-light); color: var(--jp-purple);
}
.md-making__icon .icon { font-size: 30px; }
.md-making__icon--done { background: #E3F1E7; color: #2E6B45; }
.md-making__icon--done .icon { stroke-width: 2.2; }
.md-bar { height: 10px; border-radius: 999px; background: var(--jp-purple-light); overflow: hidden; margin: 8px 0 6px; }
.md-bar span { display: block; height: 100%; width: 0; background: var(--jp-purple); border-radius: inherit; transition: width .4s var(--ease); }
.md-player {
  position: relative; display: grid; place-items: center; aspect-ratio: 16 / 10; border-radius: 16px; overflow: hidden; color: #fff; margin: 8px 0 16px;
  background: radial-gradient(80% 90% at 85% 10%, rgba(255, 210, 122, .4) 0%, rgba(255, 210, 122, 0) 60%), linear-gradient(135deg, #5A2E78, var(--jp-purple) 45%, #2E0F42);
}
.md-player__name { position: absolute; top: 18px; left: 20px; font-family: var(--font-serif); font-size: 26px; }
.md-play--lg { width: 74px; height: 74px; }
.md-play--lg .icon { font-size: 30px; }
.md-player__chapter { position: absolute; left: 20px; bottom: 26px; font-size: 15px; opacity: .9; }
.md-player__bar { position: absolute; left: 20px; right: 20px; bottom: 16px; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .3); }
.md-player__bar span { display: block; width: 18%; height: 100%; border-radius: inherit; background: #fff; }
.md-player__chapters { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px; font-family: var(--font-serif); font-size: 20px; color: var(--md-ink-2); }

/* ---------- Panel "Mi historia" ---------- */
.md-panelx { padding-top: 10px; }
.md-welcome { display: grid; gap: 28px; justify-items: start; margin-bottom: 40px; }
.md-welcome__title { font-family: var(--font-serif); font-weight: 500; font-size: clamp(46px, 13vw, 72px); line-height: 1; }
.md-welcome__lead { margin: 12px 0 26px; font-size: 20px; color: var(--md-ink-2); }
.md-welcome .btn { width: 100%; }
.md-ring { position: relative; width: 190px; height: 190px; justify-self: center; display: grid; place-items: center; text-align: center; }
.md-ring svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.md-ring__bg { fill: none; stroke: var(--jp-purple-light); stroke-width: 8; }
.md-ring__fg { fill: none; stroke: var(--jp-purple); stroke-width: 8; stroke-linecap: round; }
.md-ring__num { font-family: var(--font-serif); font-size: 54px; line-height: 1; font-weight: 500; margin-top: 18px; }
.md-ring__label { font-size: 15px; color: var(--jp-muted); margin-top: -34px; }
.md-section-label { font: 600 14px/1 var(--font-sans); letter-spacing: .18em; text-transform: uppercase; color: var(--jp-purple); margin-bottom: 16px; }
.md-chaps { margin-bottom: 40px; }
.md-chaps ul { border-top: 1px solid var(--md-line); }
.md-chap {
  display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; align-items: center;
  padding: 20px 4px; border-bottom: 1px solid var(--md-line); text-decoration: none; color: var(--jp-text);
}
.md-chap:hover .md-chap__name { color: var(--jp-purple); }
.md-chap:hover .icon--arrow { transform: translateX(4px); }
.md-chap__name { font-family: var(--font-serif); font-size: 28px; line-height: 1.1; transition: color .2s var(--ease); }
.md-chap__detail { font-size: 16px; color: var(--jp-muted); text-align: right; }
.md-chap__bar { grid-column: 1 / -1; height: 6px; border-radius: 6px; background: var(--jp-purple-light); overflow: hidden; }
.md-chap__bar span { display: block; height: 100%; background: var(--jp-purple); border-radius: inherit; }
.md-chap__go { grid-column: 1 / -1; display: inline-flex; align-items: center; gap: 8px; font-size: 16px; font-weight: 600; color: var(--jp-purple); min-height: 28px; }
.md-chap__go .icon { transition: transform .3s var(--ease); }
.md-panelx__grid { display: grid; gap: 36px; margin-bottom: 36px; }
.md-last__card { padding: 22px 20px; border-radius: var(--md-radius); background: #fff; border: 1px solid var(--md-line); display: grid; gap: 8px; justify-items: start; }
.md-last__kind { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600; color: var(--jp-purple); }
.md-last__title { font-family: var(--font-serif); font-size: 30px; line-height: 1.1; }
.md-last__meta { font-size: 16px; color: var(--jp-muted); margin-bottom: 8px; }
.md-last__card .btn { min-height: 52px; }
.md-today { padding: 28px 22px; border-radius: var(--md-radius); background: linear-gradient(180deg, #fff, var(--md-paper)); border: 1px solid var(--md-line); }
.md-today__q { font-family: var(--font-serif); font-style: italic; font-weight: 500; font-size: 32px; line-height: 1.2; margin-bottom: 24px; }
.md-today .btn { width: 100%; margin-bottom: 12px; }
.md-panelx__privacy { display: grid; gap: 10px; padding-top: 24px; border-top: 1px solid var(--md-line); }
.md-panelx__privacy p { display: flex; align-items: center; gap: 10px; font-size: 16px; color: var(--jp-muted); }
.md-panelx__privacy .icon { color: var(--jp-purple); font-size: 19px; }
body:has(.md-panelx) .md-appfoot { padding-bottom: 32px; }

/* =========================================================
   TABLET Y DESKTOP
   ========================================================= */
@media (min-width: 600px) {
  .md-stepper__name { display: block; }
  .md-progress__current { display: none; }
  .md-composer__actions, .md-saved { justify-items: center; }
  .md-composer__actions .btn, .md-saved .btn { width: auto; min-width: 300px; }
  .md-film__actions { grid-template-columns: 1fr 1fr; }
  .md-modal__body { padding: 36px 36px 28px; }
  .md-modal__actions { justify-items: center; }
  .md-modal__actions .btn { width: auto; min-width: 280px; }
  .md-welcome .btn, .md-today .btn { width: auto; }
  .md-checks { grid-template-columns: 1fr 1fr; }
  .md-newperson__actions { justify-items: start; }
  .md-appmain { padding-top: 34px; }
  .md-apphead__inner { height: 76px; }
  .md-apphead__brand img { height: 52px; }
}

@media (min-width: 900px) {
  /* Experiencia: más aire, misma columna íntima */
  .md-appmain { width: min(100% - 64px, 760px); padding: 44px 0 56px; }
  .md-bottom { position: static; padding: 26px 0 0; margin-top: 36px; background: none; box-shadow: none; }
  .md-appfoot { padding-bottom: 32px; }
  .md-options { grid-template-columns: repeat(4, 1fr); }
  .md-option { min-height: 132px; }
  .md-camera { aspect-ratio: 16 / 9; }
  .md-film li { grid-template-columns: 64px 1fr auto; padding: 20px 0; }
  .md-film__num { grid-row: auto; font-size: 36px; }
  .md-film__count { text-align: right; }
  .md-film__name { font-size: 30px; }
  .md-people { grid-template-columns: 1fr 1fr; }
  .md-cover__art { aspect-ratio: 21 / 9; padding: 32px 36px; }
  .md-welcome { grid-template-columns: 1fr auto; align-items: center; }
  .md-panelx__grid { grid-template-columns: 1fr 1fr; align-items: start; gap: 28px; }
  .md-panelx__privacy { grid-template-columns: repeat(3, auto); justify-content: space-between; }
}

@media (min-width: 1200px) {
  .md-appmain { width: 820px; }
}

@media (prefers-reduced-motion: reduce) {
  .md-bar span { transition: none; }
}
.md-modal__title:focus, .md-question__title:focus { outline: none; }

/* =========================================================
   LANDING /mausoleodigital/ — composición del mockup
   (prefijo .mdl-; mobile first)
   ========================================================= */
.mdl-eyebrow {
  font: 700 13px/1.45 var(--font-sans); letter-spacing: .2em; text-transform: uppercase;
  color: var(--jp-purple); margin-bottom: 14px;
}
.mdl-eyebrow--light { color: rgba(255, 255, 255, .92); }
.mdl-title {
  font-family: var(--font-serif); font-weight: 500; color: var(--jp-purple-deep);
  font-size: clamp(36px, 4vw, 54px); line-height: 1.04; letter-spacing: -.01em;
}
.mdl-title--light { color: #fff; }
.mdl-script {
  font-family: var(--font-serif); font-style: italic; font-weight: 500;
  font-size: clamp(24px, 2.2vw, 32px); line-height: 1.15; color: #fff;
  text-shadow: 0 2px 14px rgba(0, 0, 0, .35);
}
.mdl-circle {
  display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%;
  background: var(--jp-purple-tint); color: var(--jp-purple);
}
.mdl-circle .icon { font-size: 30px; stroke-width: 1.35; }
.mdl-circle--sm { width: 50px; height: 50px; background: #fff; border: 1px solid var(--jp-purple-tint); }
.mdl-circle--sm .icon { font-size: 26px; }

/* ---------- Hero ---------- */
.mdl-hero { position: relative; isolation: isolate; overflow: hidden; color: #fff; min-height: 520px; display: flex; }
/* Capas hacia arriba: foto (0) · velo (1) · texto (2). Sin z-index negativos. */
.mdl-hero__photo, .mdl-hero__photo img { position: absolute; inset: 0; width: 100%; height: 100%; }
.mdl-hero__photo { z-index: 0; }
.mdl-hero__photo img { object-fit: cover; object-position: 62% 40%; }
/* El recorte vertical ya viene encuadrado en las dos caras: se centra. */
@media (max-width: 719px) { .mdl-hero__photo img { object-position: 50% 42%; } }
.mdl-hero::after {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    linear-gradient(0deg, rgba(24, 12, 30, .88) 0%, rgba(24, 12, 30, .45) 46%, rgba(24, 12, 30, 0) 78%),
    linear-gradient(90deg, rgba(24, 12, 30, .6) 0%, rgba(24, 12, 30, .15) 55%, rgba(24, 12, 30, 0) 85%);
}
.mdl-hero__inner { position: relative; z-index: 2; display: flex; flex-direction: column; justify-content: flex-end; gap: 24px; padding-top: 56px; padding-bottom: 48px; }
.mdl-hero__title { font-family: var(--font-serif); font-weight: 500; font-size: clamp(46px, 12vw, 80px); line-height: 1; letter-spacing: -.01em; }
.mdl-hero__lead { margin: 18px 0 28px; font-size: 18px; line-height: 1.55; color: rgba(255, 255, 255, .92); }
.mdl-hero__lead br { display: none; }
.mdl-hero__actions { display: flex; flex-direction: column; gap: 12px; }
.mdl-hero__actions .btn { width: 100%; }
.mdl-hero__script { font-size: 24px; opacity: .95; }

/* ---------- Formatos ---------- */
.mdl-formats { background: var(--jp-ivory); border-bottom: 1px solid var(--md-line); }
.mdl-formats__grid { display: grid; grid-template-columns: 1fr 1fr; padding-block: 8px; }
.mdl-formats__grid li { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 26px 10px; }
.mdl-formats__grid li:nth-child(odd) { border-right: 1px solid var(--md-line); }
.mdl-formats__grid li:nth-child(-n+2) { border-bottom: 1px solid var(--md-line); }
.mdl-formats h2 { margin: 14px 0 6px; font: 700 14px/1.2 var(--font-sans); letter-spacing: .12em; text-transform: uppercase; color: var(--jp-text); }
.mdl-formats p { font-size: 15.5px; line-height: 1.5; color: var(--jp-muted); }
.mdl-formats p br { display: none; }

/* ---------- Miles de historias ---------- */
.mdl-stories { display: grid; background: #fff; }
.mdl-stories__text { padding: 48px 20px 36px; }
.mdl-stories__text p { font-size: 17.5px; line-height: 1.6; color: var(--md-ink-2); }
.mdl-stories__quote {
  margin: 28px 0 0; padding-top: 26px; position: relative;
  font-family: var(--font-serif); font-style: italic; font-size: 26px; line-height: 1.25; color: var(--jp-purple-deep);
}
.mdl-stories__quote::before { content: ""; position: absolute; top: 0; left: 0; width: 44px; height: 1.5px; background: var(--jp-purple); }
.mdl-stories__photo { position: relative; margin: 0; aspect-ratio: 16 / 10; }
.mdl-stories__photo picture, .mdl-stories__photo img { position: absolute; inset: 0; width: 100%; height: 100%; }
.mdl-stories__photo img { object-fit: cover; object-position: 50% 50%; }

/* ---------- Paso a paso ---------- */
.mdl-steps { background: linear-gradient(180deg, #F3EDF6 0%, #F7F3F8 100%); padding: 56px 0 60px; }
.mdl-steps__head { display: grid; gap: 14px; margin-bottom: 30px; }
.mdl-steps__head > p { font-size: 17px; line-height: 1.6; color: var(--md-ink-2); max-width: 520px; }
.mdl-steps__grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.mdl-step {
  position: relative; padding: 22px 22px 20px; border-radius: 16px; background: #fff;
  border: 1px solid rgba(233, 227, 236, .9); box-shadow: 0 16px 34px -30px rgba(42, 15, 59, .6);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.mdl-step:hover { transform: translateY(-3px); box-shadow: 0 22px 40px -28px rgba(42, 15, 59, .6); }
.mdl-step__link { position: absolute; inset: 0; z-index: 1; border-radius: inherit; }
.mdl-step__link:focus-visible { outline: 2px solid var(--jp-purple); outline-offset: 3px; }
.mdl-step__top { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.mdl-step__num { font: 600 15px/1 var(--font-sans); color: var(--jp-purple); font-variant-numeric: lining-nums; }
.mdl-step__title { font: 700 15px/1.3 var(--font-sans); letter-spacing: .1em; text-transform: uppercase; color: var(--jp-purple); margin-bottom: 8px; }
.mdl-step__text { font-size: 16px; line-height: 1.5; color: var(--md-ink-2); margin-bottom: 14px; }
.mdl-step__list li { position: relative; padding: 5px 0 5px 16px; font-size: 15px; line-height: 1.4; color: var(--jp-muted); }
.mdl-step__list li::before { content: "›"; position: absolute; left: 0; top: 3px; color: var(--jp-purple); font-weight: 700; }

/* ---------- Una historia viva ---------- */
.mdl-live { background: #fff; padding: 56px 0 64px; overflow: hidden; }
.mdl-live__inner { display: grid; gap: 44px; }
.mdl-live__lead { margin: 16px 0 22px; font-size: 17.5px; line-height: 1.6; color: var(--md-ink-2); }
.mdl-checks { display: grid; gap: 12px; margin-bottom: 28px; }
.mdl-checks li { display: flex; align-items: center; gap: 12px; font-size: 16px; color: var(--md-ink-2); }
.mdl-checks .icon { flex: none; font-size: 20px; color: var(--jp-purple); }
.mdl-live__text .btn { width: 100%; }

.mdl-devices { margin: 0; }
.mdl-devices picture { display: block; }
.mdl-devices img { width: 100%; height: auto; }

/* ---------- Espacio memorial ---------- */
.mdl-memorial {
  position: relative; overflow: hidden; color: #fff; padding: 56px 0 60px;
  background:
    radial-gradient(50% 80% at 90% 50%, rgba(120, 60, 170, .45) 0%, rgba(120, 60, 170, 0) 70%),
    linear-gradient(115deg, #2E0F42 0%, var(--jp-purple) 55%, #3A1553 100%);
}
.mdl-memorial__inner { display: grid; gap: 36px; }
.mdl-memorial__text p { margin: 18px 0 26px; font-size: 17px; line-height: 1.6; color: rgba(255, 255, 255, .88); }
.mdl-memorial__photo { position: relative; margin: 0; border-radius: 18px; overflow: hidden; aspect-ratio: 4 / 3.4; box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .7); }
.mdl-memorial__photo picture, .mdl-memorial__photo img { width: 100%; height: 100%; }
.mdl-memorial__photo img { object-fit: cover; }
.mdl-memorial__script { font-size: 26px; }

/* ---------- Ejemplo de Mausoleo Digital ---------- */
.mdl-example { background: linear-gradient(180deg, #F3EDF6 0, #F3EDF6 50%, #fff 50%); padding: 0 0 48px; }
.mdl-memorial + .mdl-example { background: linear-gradient(180deg, var(--jp-ivory), #fff); padding-top: 28px; }
.mdl-example__card {
  display: grid; gap: 22px; padding: 24px 20px; border-radius: 18px; background: #fff;
  border: 1px solid var(--md-line); box-shadow: 0 24px 48px -34px rgba(42, 15, 59, .55);
}
.mdl-example__label { font: 700 15px/1.3 var(--font-sans); color: var(--jp-purple-deep); margin-bottom: 16px; }
.mdl-example__who { display: flex; gap: 18px; align-items: center; }
.mdl-example__avatar {
  flex: none; display: grid; place-items: center; width: 96px; height: 110px; border-radius: 12px;
  background: linear-gradient(150deg, #E7D9CF, #C9B6D3); color: var(--jp-purple);
  font-family: var(--font-serif); font-size: 36px;
}
.mdl-example__name { font-family: var(--font-serif); font-style: italic; font-size: 28px; line-height: 1.1; color: var(--jp-purple-deep); }
.mdl-example__years { margin: 6px 0 8px; font-size: 16px; color: var(--jp-muted); font-variant-numeric: lining-nums; }
.mdl-example__quote { font-family: var(--font-serif); font-style: italic; font-size: 19px; color: var(--jp-purple); }
.mdl-example__tabs { display: flex; flex-wrap: wrap; gap: 4px 20px; border-bottom: 1px solid var(--md-line); margin-bottom: 16px; font-size: 14.5px; color: var(--jp-muted); }
.mdl-example__tabs li { padding: 8px 0; }
.mdl-example__tabs .is-on { color: var(--jp-purple); font-weight: 600; box-shadow: inset 0 -2px 0 var(--jp-purple); }
.mdl-example__thumbs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-bottom: 18px; }
.mdl-example__thumbs i { border-radius: 8px; }
.mdl-example__content .btn { width: 100%; }

/* Cierre reutilizado de la home con el fondo lavanda del mockup */
.md-landing-body .closing { background: linear-gradient(180deg, #F3EDF6 0%, #F8F4F9 100%); }

/* ---------- Tablet ---------- */
@media (min-width: 600px) {
  .mdl-hero__actions { flex-direction: row; }
  .mdl-hero__actions .btn { width: auto; }
  .mdl-hero__lead br, .mdl-formats p br { display: inline; }
  .mdl-steps__grid { grid-template-columns: 1fr 1fr; }
  .mdl-live__text .btn, .mdl-example__content .btn { width: auto; }
  .mdl-formats__grid { grid-template-columns: repeat(4, 1fr); }
  .mdl-formats__grid li { border: 0 !important; border-left: 1px solid var(--md-line) !important; padding-block: 34px; }
  .mdl-formats__grid li:first-child { border-left: 0 !important; }
}

/* ---------- Desktop ---------- */
@media (min-width: 1024px) {
  .mdl-hero { min-height: clamp(460px, 34vw, 560px); }
  .mdl-hero__photo img { object-position: 62% 38%; }
  .mdl-hero__inner { flex-direction: row; align-items: center; justify-content: space-between; padding-block: 64px; }
  .mdl-hero__script { align-self: flex-start; margin-top: 30px; font-size: clamp(26px, 2.2vw, 32px); transform: rotate(-4deg); }

  .mdl-stories { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); min-height: 440px; }
  .mdl-stories__text {
    align-self: center; padding: 56px 48px 56px max(var(--gutter), calc((100vw - var(--container-max)) / 2));
  }
  .mdl-stories__photo { aspect-ratio: auto; }
  .mdl-stories__photo::after {
    content: ""; position: absolute; inset: 0;
    background: linear-gradient(90deg, #fff 0%, rgba(255, 255, 255, 0) 22%);
  }

  .mdl-steps { padding: 72px 0 80px; }
  .mdl-steps__head { grid-template-columns: 1fr 1fr; align-items: end; gap: 40px; margin-bottom: 36px; }
  .mdl-steps__grid { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; }
  .mdl-step { padding: 22px 18px 22px; }
  .mdl-step__top { flex-direction: row; justify-content: space-between; }
  .mdl-step__title { font-size: 14px; min-height: 2.6em; }
  .mdl-step__text { font-size: 15px; min-height: 4.5em; }
  .mdl-step__list li { font-size: 14.5px; }

  .mdl-live { padding: 80px 0; }
  .mdl-live__inner { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); align-items: center; gap: 64px; }

  .mdl-memorial { padding: 64px 0; }
  .mdl-memorial__inner { grid-template-columns: minmax(0, 1fr) minmax(0, .9fr) minmax(0, .6fr); align-items: center; gap: 40px; }
  .mdl-memorial__script { transform: rotate(-4deg); font-size: clamp(26px, 2.2vw, 32px); }

  .mdl-example { padding-bottom: 56px; }
  .mdl-memorial + .mdl-example { padding-top: 0; background: linear-gradient(180deg, #fff 0, #fff 100%); }
  .mdl-example__card { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 40px; align-items: center; padding: 28px 32px; margin-top: -24px; position: relative; }
  .mdl-example__content { text-align: right; }
  .mdl-example__tabs { justify-content: flex-start; }
}

/* ---------- Multimedia REAL del recuerdo (Fase 3) ---------- */
.md-camera__label, .md-camera__time { z-index: 1; }
.md-camera__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #1E1A22; }
.md-camera__video.is-live { object-fit: cover; transform: scaleX(-1); }   /* como un espejo mientras se graba */
.md-camera__video[controls] { z-index: 2; }
.md-preview { display: block; width: 100%; margin-top: 12px; }
.md-preview[hidden] { display: none; }
.md-media-msg {
  margin: 0 0 12px; padding: 12px 14px; border-radius: 12px; background: #FBEAE8; color: #7E1D17;
  font-size: 16px; line-height: 1.45;
}
.md-filelink {
  display: inline-block; padding: 8px 0; border: 0; background: none; color: var(--jp-purple);
  font: 600 16px/1.4 var(--font-sans); text-decoration: underline; text-underline-offset: 3px; cursor: pointer;
}
.md-current { margin-top: 14px; padding: 12px; border-radius: 14px; background: #fff; border: 1px solid var(--md-line); }
.md-current__label { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; font-size: 16px; font-weight: 600; color: var(--jp-purple); }
.md-current video, .md-current audio { display: block; width: 100%; }
.md-current video { max-height: 360px; border-radius: 10px; background: #1E1A22; }
.md-composer__summary { margin-top: 12px; text-align: center; }

.md-photos li.md-photo { position: relative; padding: 0; overflow: hidden; background: var(--jp-purple-light); }
.md-photo img { width: 100%; height: 100%; object-fit: cover; }
.md-photo__del {
  position: absolute; right: 6px; top: 6px; display: inline-flex; align-items: center; gap: 4px; min-width: 44px; min-height: 44px;
  justify-content: center; padding: 0 10px; border-radius: 999px; border: 0; background: rgba(255, 255, 255, .92); color: var(--jp-text);
  font: 600 14px/1.1 var(--font-sans); cursor: pointer; box-shadow: 0 1px 4px rgba(0, 0, 0, .18);
}
.md-photo__del .icon { font-size: 18px; }
.md-photo__del span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.md-photo__del.is-armed { background: #A3261F; color: #fff; }
.md-photo__del.is-armed span { position: static; width: auto; height: auto; clip-path: none; }
/* Editar (girar/recortar): mismo botón que «Quitar», en la esquina opuesta. */
.md-photo__edit {
  position: absolute; left: 6px; top: 6px; display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px;
  padding: 0 10px; border-radius: 999px; border: 0; background: rgba(255, 255, 255, .92); color: var(--jp-text);
  cursor: pointer; box-shadow: 0 1px 4px rgba(0, 0, 0, .18);
}
.md-photo__edit .icon { font-size: 18px; }
.md-photo__edit span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.md-photo__edit:focus-visible { outline: 2px solid var(--jp-purple); outline-offset: 2px; }

/* Editor de la foto (md-foto-editor.js + vendor/cropperjs) */
.md-editor { width: min(100% - 24px, 760px); }
.md-editor__body { padding: 22px 16px 18px; }
.md-editor__stage { height: min(48vh, 460px); border-radius: 14px; overflow: hidden; background: #1E1A22; margin-bottom: 12px; }
.md-editor__stage img { display: block; max-width: 100%; }
.md-editor__tools { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.md-editor__tool {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 8px 12px; border-radius: 12px;
  border: 1px solid var(--md-line); background: #fff; color: var(--jp-text); font: 600 15px/1.2 var(--font-sans); cursor: pointer;
}
.md-editor__tool .icon { font-size: 20px; color: var(--jp-purple); flex: none; }
.md-editor__tool[aria-pressed="true"] { border-color: var(--jp-purple); background: var(--jp-purple-light); }
.md-editor__tool:disabled, .md-editor__prop:disabled { opacity: .5; cursor: not-allowed; }
.md-editor__props { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 10px; }
.md-editor__props[hidden] { display: none; }
.md-editor__prop {
  min-height: 44px; min-width: 64px; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--md-line); background: #fff;
  color: var(--jp-text); font: 600 15px/1.2 var(--font-sans); cursor: pointer;
}
.md-editor__prop[aria-pressed="true"] { border-color: var(--jp-purple); background: var(--jp-purple); color: #fff; }
.md-editor__hint { margin: 10px 0 0; font-size: 14.5px; color: var(--jp-muted); }
.md-editor__result { display: grid; justify-items: center; gap: 6px; margin-top: 12px; }
.md-editor__result-label { font-size: 14.5px; font-weight: 600; color: var(--jp-muted); }
.md-editor__preview { width: 180px; height: 120px; overflow: hidden; border-radius: 10px; background: var(--jp-purple-light); }
.md-editor__estado { min-height: 1.3em; margin: 6px 0 0; font-size: 15px; color: var(--jp-muted); }
.md-editor__estado:empty { min-height: 0; margin: 0; }
@media (min-width: 720px) {
  .md-editor__body { padding: 28px 30px 24px; }
  .md-editor__tools { grid-template-columns: repeat(4, 1fr); }
  .md-editor__stage { height: min(56vh, 480px); }
}
.md-photo__state {
  position: absolute; inset: auto 0 0 0; padding: 6px; background: rgba(42, 37, 47, .72); color: #fff;
  font-size: 13px; line-height: 1.3; text-align: center;
}
.md-photo.is-uploading img { opacity: .6; }
.md-photo.is-error { background: #FBEAE8; }
.md-photo.is-error img { opacity: .25; }
.md-photo.is-error .md-photo__state { background: #7E1D17; }

.md-upload { margin-bottom: 14px; }
.md-upload__bar { display: block; height: 10px; border-radius: 999px; background: var(--jp-purple-light); overflow: hidden; }
.md-upload__bar i { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--jp-purple); transition: width .2s linear; }
.md-upload__txt { display: block; margin-top: 8px; text-align: center; font-size: 16px; color: var(--jp-muted); }

/* ---------- Mis mensajes REAL (Fase 4) ---------- */
.md-people:empty { display: none; }
.md-people__empty { margin-bottom: 14px; text-align: center; }
.md-person__more { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 18px; margin-top: -6px; }
.md-person__more .md-textlink { font-size: 15px; min-height: 44px; }
.md-person__confirm { display: grid; gap: 8px; padding: 14px; border-radius: 12px; background: #FBEAE8; text-align: center; }
.md-person__confirm[hidden] { display: none; }
.md-person__confirm-text { font-size: 16px; line-height: 1.45; color: #7E1D17; }
.md-person__confirm .btn { width: 100%; background: #A3261F; border-color: #A3261F; }
.md-newperson__otra { margin: 14px 0 0; }
.md-current__nosoporte { font-size: 16px; line-height: 1.45; color: var(--jp-muted); }
.md-current__nosoporte[hidden] { display: none; }
.md-current__nosoporte a { color: var(--jp-purple); font-weight: 600; }
/* Editor del mensaje: el composer de las preguntas dentro del modal, con scroll propio. */
.md-mensaje { text-align: left; }
.md-mensaje .md-modal__title, .md-mensaje .md-modal__text { text-align: center; }
.md-mensaje__close { display: flex; margin: 8px auto 0; }
.md-modal:has(.md-mensaje:not([hidden])) { overflow-y: auto; overscroll-behavior: contain; }

/* ---------- 320 px (Fase 4) ----------
   Botones `nowrap` más anchos que la pantalla y celdas del panel que no podían
   encogerse. Sólo estos componentes y sólo por debajo de 360 px: a partir de ahí
   nada cambia. Sin overflow-x: hidden. */
.md-panelx__grid > * { min-width: 0; }
@media (max-width: 359px) {
  .md-panelx .btn, .md-film__actions .btn, .md-bottom .md-continue { white-space: normal; text-align: center; line-height: 1.25; }
  .md-panelx .btn--lg, .md-film__actions .btn { padding-inline: 18px; }
  .md-bottom .md-continue { padding: 0 16px; }
}
/* «Mis mensajes · 2 personas · 1 con mensaje»: el nombre del capítulo no se parte; el detalle, sí. */
.md-chap__name { white-space: nowrap; }
@media (max-width: 359px) { .md-chap__name { white-space: normal; } }

/* ---------- Compartir REAL (Fase 5) ---------- */
.md-field select {
  width: 100%; min-height: 56px; padding: 12px 14px; border-radius: 12px; border: 1.5px solid #D6CCDD; background: #fff;
  font: 400 17px/1.3 var(--font-sans); color: var(--jp-text);
}
.md-field select:focus { outline: none; border-color: var(--jp-purple); box-shadow: 0 0 0 3px var(--jp-purple-tint); }
.md-field select:disabled { background: var(--md-paper); color: var(--jp-text); opacity: 1; }
/* Código de país + número: en la misma fila si caben; en el teléfono, uno debajo del otro (nada se corta). */
.md-tel { display: flex; flex-wrap: wrap; gap: 8px; }
.md-tel select { flex: 1 1 auto; width: auto; min-width: 0; field-sizing: content; padding-right: 30px; }
.md-tel input { flex: 1 1 200px; min-width: 0; }
.md-recipientf__estado { display: flex; align-items: center; gap: 8px; margin: -6px 0 16px; font-size: 16px; font-weight: 600; color: #2E6B45; }
.md-recipientf__estado[hidden] { display: none; }
.md-check.is-future { cursor: default; opacity: .7; }
.md-check.is-future span { border-style: dashed; }
.md-check.is-future em { font-style: normal; color: var(--jp-muted); font-weight: 500; }
.md-recipientf .md-person__confirm { margin-bottom: 14px; }
.md-recipientf .md-field__help { margin-top: 8px; }
/* «Videografía · Próximamente» y «Mis mensajes para …» pueden partirse en pantallas angostas (320 px). */
.md-recipientf [data-ambitos] .md-check span { flex-wrap: wrap; column-gap: .3em; row-gap: 2px; }
.md-recipientf [data-ambitos] .md-check span, .md-recipientf [data-ambitos] .md-check em { min-width: 0; overflow-wrap: anywhere; }
.md-recipientf .md-check span { min-width: 0; }

/* ---------- Videografía REAL: editor (Fase 6A) ---------- */
.md-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.md-opt { font-style: normal; font-weight: 400; color: var(--jp-muted); }
.md-vstart { display: grid; gap: 18px; padding: 24px 20px; border-radius: var(--md-radius); background: #fff; border: 1px solid var(--md-line); margin-bottom: 24px; }
.md-vstart__text { font-size: 18px; line-height: 1.5; }
.md-vstart .btn { width: 100%; }
.md-cover__art { isolation: isolate; }
.md-cover__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.md-cover__art.has-photo::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(20, 8, 28, .05) 20%, rgba(20, 8, 28, .78) 100%); }
.md-cover__frase { margin-top: 10px; font-size: 16px; line-height: 1.45; opacity: .92; max-width: 34ch; }
.md-cover__frase:empty, .md-cover__sub:empty { display: none; }
.md-vcover { padding: 20px; border-radius: var(--md-radius); background: #fff; border: 1px solid var(--md-line); }
.md-vcover__save { width: 100%; }
.md-vfotos { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 10px; }
.md-vfotos .md-field__help { grid-column: 1 / -1; }
.md-vfoto { position: relative; display: grid; place-items: center; aspect-ratio: 1; border-radius: 12px; overflow: hidden; cursor: pointer;
  border: 2px solid transparent; background: var(--jp-purple-light); color: var(--jp-purple); font-size: 15px; font-weight: 600; text-align: center; }
.md-vfoto input { position: absolute; opacity: 0; }
.md-vfoto img { width: 100%; height: 100%; object-fit: cover; }
.md-vfoto:has(input:checked) { border-color: var(--jp-purple); box-shadow: 0 0 0 3px var(--jp-purple-tint); }
.md-vfoto:has(input:focus-visible) { outline: 2px solid var(--jp-purple); outline-offset: 3px; }
.md-vsum { margin: 8px 0 22px; }
.md-vtotal { display: flex; flex-wrap: wrap; gap: 8px; }
.md-vtotal__n { padding: 8px 14px; border-radius: 999px; background: #fff; border: 1px solid var(--md-line); font-size: 16px; color: var(--jp-muted); }
.md-vtotal__n strong { color: var(--jp-text); font-weight: 700; }
.md-film--edit > li.md-film__cap { display: block; padding: 18px 0; }
.md-film__head { display: grid; grid-template-columns: 44px 1fr; gap: 2px 12px; align-items: baseline; margin-bottom: 12px; }
.md-vitems { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.md-vitem {
  display: grid; grid-template-columns: auto 56px 1fr; gap: 10px 12px; align-items: center; padding: 12px;
  border-radius: 14px; background: #fff; border: 1px solid var(--md-line);
}
.md-vitem.is-dragging { opacity: .5; border-style: dashed; }
.md-vitem.is-aviso { background: #FFF8EC; border-color: #EBD2A0; }
.md-vitem.is-fuera { grid-template-columns: 56px 1fr; background: var(--md-paper); }
.md-vitem__grip { cursor: grab; color: var(--jp-muted); font-size: 18px; letter-spacing: -3px; padding: 4px 2px; user-select: none; }
.md-vitem__thumb { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 10px; overflow: hidden; background: var(--jp-purple-light); color: var(--jp-purple); }
.md-vitem__thumb img { width: 100%; height: 100%; object-fit: cover; }
.md-vitem__thumb .icon { font-size: 22px; }
.md-vitem__body { min-width: 0; }
.md-vitem__title { font-family: var(--font-serif); font-size: 21px; line-height: 1.2; overflow-wrap: anywhere; }
.md-vitem__meta { margin-top: 4px; font-size: 15px; color: var(--jp-muted); }
.md-vitem__aviso { margin-top: 6px; font-size: 15px; font-weight: 600; color: #8A5A00; }
.md-vitem__acts { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.md-vitem__btn {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; min-width: 44px; padding: 0 12px; border-radius: 10px;
  border: 1.5px solid #D6CCDD; background: #fff; color: var(--jp-text); font: 600 15px/1 var(--font-sans); cursor: pointer;
}
.md-vitem__btn:disabled { opacity: .35; cursor: default; }
.md-vitem__cap { flex: 1 1 150px; min-width: 0; }
.md-vitem__cap select {
  width: 100%; min-height: 44px; padding: 8px 10px; border-radius: 10px; border: 1.5px solid #D6CCDD; background: #fff;
  font: 500 15px/1.2 var(--font-sans); color: var(--jp-text);
}
.md-vitem__quitar { min-height: 44px; font-size: 15px; }
.md-vitem__agregar { min-height: 44px; padding: 0 16px; }
.md-vfuera { margin: 8px 0 26px; }
.md-vfuera .md-hint[hidden] { display: none; }
.md-vestado { margin-bottom: 14px; font-size: 16px; color: var(--jp-muted); text-align: center; }
@media (min-width: 768px) {
  .md-vstart .btn, .md-vcover__save { width: auto; }
  .md-vitem { grid-template-columns: auto 64px 1fr auto; }
  .md-vitem.is-fuera { grid-template-columns: 64px 1fr auto; }
  .md-vitem__thumb { width: 64px; height: 64px; }
  .md-vitem__acts { grid-column: auto; flex-wrap: nowrap; }
  .md-vitem__cap { flex: 0 0 190px; }
}

/* ---------- Videografía: vista previa (narración web, no es video) ---------- */
.md-vp { max-width: 760px; margin: 0 auto; padding: 24px 0 40px; }
.md-vp__cover {
  position: relative; isolation: isolate; display: flex; align-items: flex-end; min-height: 320px; padding: 30px 26px; border-radius: 22px;
  overflow: hidden; color: #fff; margin-bottom: 18px;
  background:
    radial-gradient(80% 90% at 85% 10%, rgba(255, 210, 122, .45) 0%, rgba(255, 210, 122, 0) 60%),
    linear-gradient(135deg, #5A2E78 0%, var(--jp-purple) 45%, #2E0F42 100%);
}
.md-vp__cover-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.md-vp__cover.has-photo::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(20, 8, 28, .05) 25%, rgba(20, 8, 28, .8) 100%); }
.md-vp__title { font-family: var(--font-serif); font-weight: 500; font-size: clamp(40px, 11vw, 68px); line-height: 1; overflow-wrap: anywhere; }
.md-vp__sub { margin-top: 10px; font-family: var(--font-serif); font-style: italic; font-size: 22px; }
.md-vp__frase { margin-top: 12px; font-size: 17px; line-height: 1.5; max-width: 40ch; opacity: .92; }
.md-vp__aviso { display: flex; align-items: center; gap: 8px; margin-bottom: 30px; font-size: 16px; color: var(--jp-muted); }
.md-vp__aviso .icon { color: var(--jp-purple); flex: none; }
.md-vp__vacio { font-size: 18px; margin-bottom: 30px; }
.md-vp__vacio a { color: var(--jp-purple); font-weight: 600; }
.md-vp__cap { margin-bottom: 36px; }
.md-vp__cap-head { display: flex; align-items: baseline; gap: 14px; padding: 18px 0 14px; border-top: 1px solid var(--md-line); margin-bottom: 8px; }
.md-vp__num { font-family: var(--font-serif); font-size: 44px; line-height: 1; color: rgba(75, 36, 100, .45); }
.md-vp__cap-name { font-family: var(--font-serif); font-weight: 500; font-size: 34px; line-height: 1.1; }
.md-vp__item { padding: 22px 0 26px; border-bottom: 1px dashed var(--md-line); }
.md-vp__item:last-child { border-bottom: 0; }
.md-vp__fotos { display: grid; gap: 8px; margin-bottom: 18px; }
.md-vp__fotos img { width: 100%; height: auto; border-radius: 14px; object-fit: cover; background: var(--jp-purple-light); }
.md-vp__fotos--2, .md-vp__fotos--3 { grid-template-columns: repeat(3, 1fr); }
.md-vp__fotos--2 .md-vp__foto-main, .md-vp__fotos--3 .md-vp__foto-main { grid-column: 1 / -1; max-height: 520px; }
.md-vp__foto { aspect-ratio: 1; height: 100%; }
.md-vp__foto-main { max-height: 560px; }
.md-vp__q { font-family: var(--font-serif); font-weight: 500; font-size: 28px; line-height: 1.15; margin-bottom: 12px; }
.md-vp__texto { margin: 0 0 16px; padding-left: 16px; border-left: 3px solid var(--jp-purple-light); font-size: 18px; line-height: 1.65; color: var(--jp-text); overflow-wrap: anywhere; }
.md-vp__media { margin: 0 0 14px; }
.md-vp__media video { display: block; width: 100%; max-height: 480px; border-radius: 14px; background: #1E1A22; }
.md-vp__media--audio { padding: 14px; border-radius: 14px; background: #fff; border: 1px solid var(--md-line); }
.md-vp__media audio { display: block; width: 100%; }
.md-vp__media-label { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; font-size: 16px; font-weight: 600; color: var(--jp-purple); }
.md-vp__nosoporte { font-size: 16px; color: var(--jp-muted); }
.md-vp__nosoporte[hidden] { display: none; }
.md-vp__nosoporte a { color: var(--jp-purple); font-weight: 600; }
.md-vp__fin { display: grid; gap: 14px; justify-items: center; padding-top: 10px; }
/* 320 px: la columna de la tarjeta inicial no crece por un botón «nowrap». */
.md-vstart { grid-template-columns: minmax(0, 1fr); }
@media (max-width: 359px) {
  .md-vstart .btn, .md-vp__fin .btn { white-space: normal; text-align: center; line-height: 1.25; }
}
/* Los recuerdos dentro de un capítulo: la regla `.md-film li` (rejilla de 2 columnas del
   diseño original) también los alcanzaba y les aplastaba el título. Selector más específico. */
.md-film .md-vitem { display: grid; grid-template-columns: auto 56px minmax(0, 1fr); gap: 10px 12px; align-items: center;
  padding: 12px; border: 1px solid var(--md-line); border-radius: 14px; }
.md-film .md-vitem.is-aviso { border-color: #EBD2A0; }
.md-vitem.is-fuera { grid-template-columns: 56px minmax(0, 1fr); }
@media (min-width: 768px) {
  .md-film .md-vitem { grid-template-columns: auto 64px minmax(0, 1fr) auto; }
  .md-vitem.is-fuera { grid-template-columns: 64px minmax(0, 1fr) auto; }
}
.md-film__head .md-film__name, .md-film__head .md-film__count { grid-column: 2; }
@media (min-width: 900px) {        /* como el diseño original: número · nombre · conteo a la derecha */
  .md-film__head { grid-template-columns: 64px 1fr auto; }
  .md-film__head .md-film__count { grid-column: 3; grid-row: 1; text-align: right; }
}

/* ---------- El video de la videografía (Fase 6B) ---------- */
.md-vrender { display: grid; gap: 10px; margin: 6px 0 18px; }
.md-vrender:empty { display: none; }
.md-vrender__titulo { font-family: var(--font-serif); font-size: 26px; line-height: 1.2; color: var(--jp-purple); }
.md-vrender__fase { font-size: 16px; color: var(--jp-muted); }
.md-vrender__aviso, .md-vrender__error { padding: 12px 14px; border-radius: 12px; background: #FBEAE8; color: #7E1D17; font-size: 16px; line-height: 1.45; }
.md-vrender__cambio { padding: 10px 14px; border-radius: 12px; background: #FFF8EC; color: #6B4A00; font-size: 16px; }
.md-vrender__video { display: block; width: 100%; max-height: 420px; border-radius: 14px; background: #1E1A22; }
.md-vrender__acc { display: flex; flex-wrap: wrap; gap: 10px; }
.md-vrender__acc .btn { flex: 1 1 160px; justify-content: center; }
.md-vrender__versiones summary { cursor: pointer; font-weight: 600; color: var(--jp-purple); min-height: 44px; display: flex; align-items: center; }
.md-vrender__versiones a { display: block; padding: 8px 0; color: var(--jp-purple); }
.md-vrender__video[hidden] { display: none; }
.md-vrender__anterior { margin-top: 8px; padding-top: 14px; border-top: 1px solid rgba(0, 0, 0, .08); font-size: 16px; color: var(--jp-purple); }
/* .btn declara display: inline-flex, que anula [hidden]: sin esto el botón seguía visible durante un render. */
[data-render-generar][hidden] {
    display: none;
}
/* Sin cambios desde la última versión (o pidiendo): se ve inactivo, no sólo lo está. */
[data-render-generar]:disabled { opacity: .5; cursor: not-allowed; }

/* ── Destinatario de una invitación (sólo lectura) ───────────────────────── */
.md-guest { max-width: 720px; margin: 0 auto; padding: 8px 0 32px; display: grid; gap: 28px; }
.md-guest__intro { display: grid; gap: 6px; }
.md-guest__de { font-size: 15px; color: var(--jp-muted); }
.md-guest__title { font-family: var(--font-serif); font-size: 32px; line-height: 1.15; color: var(--jp-purple); margin: 0; }
.md-guest__para { font-size: 16px; color: var(--jp-muted); }
.md-guest__h2 { font-family: var(--font-serif); font-size: 24px; color: var(--jp-purple); margin: 0 0 12px; }
.md-guest__h3 { font-size: 17px; color: var(--jp-purple); margin: 0 0 6px; }
.md-guest__video, .md-guest__mensaje, .md-guest__cap { display: grid; gap: 10px; }
.md-guest__mensaje { padding: 18px; border-radius: 16px; background: #FFF8EC; }
.md-guest__item { display: grid; gap: 10px; padding-top: 18px; border-top: 1px solid rgba(0, 0, 0, .08); }
.md-guest__item:first-of-type { border-top: 0; padding-top: 0; }
.md-guest__texto { font-size: 17px; line-height: 1.7; color: var(--jp-ink); }
.md-guest__foto, .md-guest__media { display: block; width: 100%; height: auto; border-radius: 14px; }
.md-guest__audio { width: 100%; }
.md-guest__nota, .md-guest__pie { font-size: 14px; color: var(--jp-muted); display: flex; align-items: center; gap: 8px; }
.md-guest--cerrado { gap: 14px; text-align: center; padding-top: 32px; }
.md-invite { display: grid; gap: 8px; margin-top: 4px; padding-top: 14px; border-top: 1px solid rgba(0, 0, 0, .08); }
.md-invite[hidden] { display: none; }
.md-invite__btn:disabled { opacity: .5; cursor: not-allowed; }
.md-invite__state { font-size: 14px; color: var(--jp-muted); min-height: 20px; }

/* =========================================================
   CIERRE «Honramos cada historia» — sólo en esta landing
   La sección es la misma de la portada (secciones/cierre.php); aquí se le pone
   detrás la lámina de hojas del material propio. El velo va como primera capa
   del mismo background-image: no hace falta pseudo-elemento ni z-index.
   ========================================================= */
.md-landing-body .closing {
  background-color: #F6F2F8;
  background-image:
    linear-gradient(180deg, rgba(250, 248, 251, .5) 0%, rgba(250, 248, 251, .25) 55%, rgba(255, 255, 255, .55) 100%),
    url("../images/mdl-cierre-fondo-1600.jpg");
  background-image:
    linear-gradient(180deg, rgba(250, 248, 251, .5) 0%, rgba(250, 248, 251, .25) 55%, rgba(255, 255, 255, .55) 100%),
    image-set(url("../images/mdl-cierre-fondo-1600.webp") type("image/webp"),
              url("../images/mdl-cierre-fondo-1600.jpg") type("image/jpeg"));
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
