/* =====================================================================
   Inolvidia · tema «marfil» — Lacre & Lino  (demo: boda-sello, Lima)
   Dueño: temas elegantes. Contrato §5: variables en :root + decoración
   acotada SIEMPRE bajo html[data-theme="marfil"].
   Concepto: papelería fina sobre lino — marfil, lino, lacre vino, oro viejo
   y tinta. Florones de línea fina, textura de lino y pétalos secos que caen
   al abrir el sobre.
   Nota técnica: además de las clases públicas, este tema viste algunos hijos
   BEM del motor (p. ej. .inv-countdown__unit, .inv-event__media, .env__*).
   Si el motor los renombra, el tema cae con gracia al estilo base.
   Contraste: el oro viejo (#B08D57) solo se usa en adornos; para texto
   dorado grande se usa #8F6D3A (≥ 3:1 sobre marfil).
   ===================================================================== */

:root {
  --bg: #F7F3EC;
  --bg-alt: #EFE7DA;
  --surface: #FCF9F3;
  --ink: #2B2A26;
  --ink-soft: #675F55;
  --accent: #7A1F2B;
  --accent-2: #B08D57;
  --accent-ink: #FBF7F1;
  --line: rgba(43, 42, 38, .15);
  --font-display: 'Cormorant Garamond', 'Cormorant', Georgia, 'Times New Roman', serif;
  --font-script: 'Pinyon Script', 'Cormorant Garamond', cursive;
  --font-body: 'Jost', 'Futura', 'Century Gothic', system-ui, sans-serif;
  --radius: 6px;
  --shadow: 0 1px 2px rgba(43, 32, 20, .06), 0 22px 42px -28px rgba(60, 36, 20, .42);
  --hero-overlay: linear-gradient(180deg, rgba(28, 18, 12, .1) 0%, rgba(28, 18, 12, 0) 30%, rgba(28, 18, 12, .2) 55%, rgba(28, 18, 12, .78) 100%);
  --hero-ink: #FBF7F1;
  --intro-bg: #D8CAB1;
  --intro-ink: #2B2A26;
  --seal: #7A1F2B;
  --pattern: var(--mf-linen);
  --ornament: var(--mf-ornament);

  /* — propias del tema — */
  --mf-lino: #E4D9C6;
  --mf-oro: #8F6D3A;          /* oro legible para texto grande */
  --mf-oro-claro: #D8BC8A;    /* oro sobre fondos oscuros */
  --mf-vino-hondo: #5A1520;
  --mf-hair: color-mix(in srgb, var(--accent-2) 55%, transparent);
}

/* @recursos:inicio — SVG hechos a mano: se generan con qa/temas-elegantes/svg/gen_marfil.py y rootblock.py (no editar a mano) */
html[data-theme="marfil"] {
  --mf-seal: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 120'%3E%3Cdefs%3E%3CradialGradient id='w' cx='.35' cy='.28' r='.9'%3E%3Cstop offset='0' stop-color='%23B04A57'/%3E%3Cstop offset='.42' stop-color='%237A1F2B'/%3E%3Cstop offset='1' stop-color='%23450C16'/%3E%3C/radialGradient%3E%3CradialGradient id='s' cx='.5' cy='.5' r='.5'%3E%3Cstop offset='.78' stop-color='%23000' stop-opacity='0'/%3E%3Cstop offset='1' stop-color='%23000' stop-opacity='.35'/%3E%3C/radialGradient%3E%3C/defs%3E%3Cpath d='M109.9 60.0C110.1 63.9 108.7 67.8 108.0 71.8C107.3 75.8 107.6 80.6 105.6 83.9C103.6 87.3 99.1 89.2 96.2 92.0C93.3 94.9 91.4 98.7 88.2 100.9C85.1 103.1 80.9 104.3 77.2 105.3C73.4 106.3 69.5 106.1 65.7 106.7C61.8 107.4 57.8 109.5 54.0 109.2C50.2 108.9 46.7 106.3 42.9 105.0C39.1 103.8 34.6 103.7 31.3 101.6C28.0 99.5 25.7 95.7 23.3 92.5C20.9 89.4 18.7 86.1 16.8 82.7C14.8 79.3 13.0 75.7 11.8 71.9C10.5 68.1 8.8 63.9 9.2 60.0C9.6 56.1 12.7 52.4 14.1 48.7C15.5 45.0 16.2 41.4 17.6 37.7C18.9 34.1 20.2 30.1 22.3 26.6C24.4 23.1 26.9 19.2 30.2 16.8C33.4 14.4 37.9 13.2 41.8 12.1C45.8 10.9 49.8 10.6 53.9 9.9C58.0 9.2 62.5 6.9 66.3 7.8C70.2 8.7 73.2 13.6 76.9 15.4C80.7 17.1 85.7 16.1 88.9 18.2C92.0 20.3 93.7 24.9 96.0 28.1C98.2 31.4 100.4 34.4 102.3 37.8C104.1 41.2 105.6 44.8 106.9 48.4C108.1 52.1 109.7 56.1 109.9 60.0Z' fill='url(%23w)'/%3E%3Ccircle cx='60' cy='60' r='37' fill='url(%23s)'/%3E%3Ccircle cx='60' cy='60' r='37.5' fill='none' stroke='%232E0710' stroke-opacity='.45' stroke-width='2.2'/%3E%3Ccircle cx='59.3' cy='59.2' r='37.5' fill='none' stroke='%23fff' stroke-opacity='.16' stroke-width='.9'/%3E%3Ccircle cx='60' cy='60' r='31' fill='none' stroke='%23D8BC8A' stroke-width='1.1' stroke-opacity='.9'/%3E%3Cg fill='%23D8BC8A' fill-opacity='.95'%3E%3Cpath d='M60.4 83.1Q54.5 82.5 50.7 87.1Q56.6 87.7 60.4 83.1Z'/%3E%3Cpath d='M51.7 81.7Q46.7 79.1 41.7 81.8Q46.8 84.5 51.7 81.7Z'/%3E%3Cpath d='M44.2 77.1Q40.6 73.1 35.3 73.8Q38.8 77.9 44.2 77.1Z'/%3E%3Cpath d='M38.8 70.0Q37.1 65.2 32.1 64.0Q33.9 68.8 38.8 70.0Z'/%3E%3Cpath d='M36.5 61.4Q36.7 56.6 32.7 53.8Q32.6 58.7 36.5 61.4Z'/%3E%3Cpath d='M37.6 52.5Q39.4 48.4 36.8 44.6Q35.1 48.8 37.6 52.5Z'/%3E%3Cpath d='M41.9 44.7Q44.9 41.6 44.0 37.4Q41.0 40.5 41.9 44.7Z'/%3E%3Cpath d='M59.6 83.1Q63.4 87.7 69.3 87.1Q65.5 82.5 59.6 83.1Z'/%3E%3Cpath d='M68.3 81.7Q73.2 84.5 78.3 81.8Q73.3 79.1 68.3 81.7Z'/%3E%3Cpath d='M75.8 77.1Q81.2 77.9 84.7 73.8Q79.4 73.1 75.8 77.1Z'/%3E%3Cpath d='M81.2 70.0Q86.1 68.8 87.9 64.0Q82.9 65.2 81.2 70.0Z'/%3E%3Cpath d='M83.5 61.4Q87.4 58.7 87.3 53.8Q83.3 56.6 83.5 61.4Z'/%3E%3Cpath d='M82.4 52.5Q84.9 48.8 83.2 44.6Q80.6 48.4 82.4 52.5Z'/%3E%3Cpath d='M78.1 44.7Q79.0 40.5 76.0 37.4Q75.1 41.6 78.1 44.7Z'/%3E%3C/g%3E%3Ccircle cx='60' cy='59' r='5.2' fill='%23EBD5A6'/%3E%3Cellipse cx='40' cy='30' rx='15' ry='6' fill='%23fff' fill-opacity='.13' transform='rotate(-38 40 30)'/%3E%3C/svg%3E");
  --mf-petal1: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40'%3E%3Cdefs%3E%3ClinearGradient id='p' x1='.5' y1='1' x2='.45' y2='0'%3E%3Cstop offset='0' stop-color='%236A1623'/%3E%3Cstop offset='1' stop-color='%23B8505C'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg transform='rotate(18 20 20)'%3E%3Cpath d='M20 35.3C11.1 30.6 4.2 19.3 7.4 9.3C12.8 3.9 17.3 5.9 20 8.1C22.8 4.7 28.3 3.6 31.8 11.3C36.0 19.5 29.4 29.9 20 36Z' fill='url(%23p)' stroke='%23E79AA2' stroke-opacity='.35' stroke-width='.6'/%3E%3Cpath d='M20 35C15 29 13 21 15 13C17 17 19 24 20 35Z' fill='%23E79AA2' fill-opacity='.28'/%3E%3C/g%3E%3C/svg%3E");
  --mf-petal2: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40'%3E%3Cdefs%3E%3ClinearGradient id='p' x1='.5' y1='1' x2='.45' y2='0'%3E%3Cstop offset='0' stop-color='%23C48A80'/%3E%3Cstop offset='1' stop-color='%23F0CFC5'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg transform='rotate(-40 20 20)'%3E%3Cpath d='M20 36.2C11.5 31.7 5.0 19.5 9.5 9.3C11.9 5.5 18.3 5.7 20 7.2C21.9 4.1 28.1 4.6 30.3 9.8C35.4 19.9 29.6 30.1 20 36Z' fill='url(%23p)' stroke='%23FFFFFF' stroke-opacity='.35' stroke-width='.6'/%3E%3C/g%3E%3C/svg%3E");
  --mf-petal3: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40'%3E%3Cdefs%3E%3ClinearGradient id='p' x1='.5' y1='1' x2='.45' y2='0'%3E%3Cstop offset='0' stop-color='%23A77E43'/%3E%3Cstop offset='1' stop-color='%23E2C592'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg transform='rotate(70 20 20)'%3E%3Cpath d='M20 35.8C11.1 32.0 3.9 19.0 8.7 9.7C12.0 4.8 18.7 3.8 20 7.7C21.0 5.5 28.4 3.4 32.6 11.6C36.3 19.2 28.1 29.8 20 36Z' fill='url(%23p)' stroke='%23FFF1D6' stroke-opacity='.35' stroke-width='.6'/%3E%3Cpath d='M20 35C15 29 13 21 15 13C17 17 19 24 20 35Z' fill='%23FFF1D6' fill-opacity='.28'/%3E%3C/g%3E%3C/svg%3E");
  --mf-petal4: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40'%3E%3Cdefs%3E%3ClinearGradient id='p' x1='.5' y1='1' x2='.45' y2='0'%3E%3Cstop offset='0' stop-color='%2356101B'/%3E%3Cstop offset='1' stop-color='%23A63A48'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg transform='rotate(150 20 20)'%3E%3Cpath d='M20 36.0C11.7 32.1 3.4 19.6 8.9 10.8C11.0 3.3 17.7 5.3 20 7.6C22.0 4.3 28.8 5.5 31.2 11.6C34.9 19.7 29.9 30.1 20 36Z' fill='url(%23p)' stroke='%23D97F89' stroke-opacity='.35' stroke-width='.6'/%3E%3C/g%3E%3C/svg%3E");
  --mf-liner: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='28' viewBox='0 0 28 28'%3E%3Crect width='28' height='28' fill='%236E1B26'/%3E%3Cpath d='M14 0L28 14 14 28 0 14z' fill='none' stroke='%23C9A56B' stroke-opacity='.42' stroke-width='.6'/%3E%3Cpath d='M14 9.5c.7 2.6 1.9 3.8 4.5 4.5-2.6.7-3.8 1.9-4.5 4.5-.7-2.6-1.9-3.8-4.5-4.5 2.6-.7 3.8-1.9 4.5-4.5z' fill='%23C9A56B' fill-opacity='.55'/%3E%3Ccircle cx='0' cy='0' r='1.2' fill='%23C9A56B' fill-opacity='.5'/%3E%3Ccircle cx='28' cy='0' r='1.2' fill='%23C9A56B' fill-opacity='.5'/%3E%3Ccircle cx='0' cy='28' r='1.2' fill='%23C9A56B' fill-opacity='.5'/%3E%3Ccircle cx='28' cy='28' r='1.2' fill='%23C9A56B' fill-opacity='.5'/%3E%3C/svg%3E");
  --mf-linen: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='a' x='0' y='0' width='100%25' height='100%25'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85 .016' numOctaves='2' seed='4' stitchTiles='stitch' result='v'/%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.016 .85' numOctaves='2' seed='9' stitchTiles='stitch' result='h'/%3E%3CfeComposite in='v' in2='h' operator='arithmetic' k2='.5' k3='.5'/%3E%3CfeColorMatrix values='0 0 0 0 .38 0 0 0 0 .3 0 0 0 0 .2 1.9 0 0 0 -.9'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23a)'/%3E%3C/svg%3E");
  --mf-grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .35 0 0 0 0 .28 0 0 0 0 .2 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  --mf-fleuron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 132 22'%3E%3Cg fill='none' stroke='%23B08D57' stroke-width='.8' stroke-linecap='round'%3E%3Cpath d='M4 11h38c7 0 10-5 15-5 3.5 0 5 2.4 3.6 4.4'/%3E%3Cpath d='M42 11c7 0 10 5 15 5 3.5 0 5-2.4 3.6-4.4'/%3E%3Cpath d='M128 11H90c-7 0-10-5-15-5-3.5 0-5 2.4-3.6 4.4'/%3E%3Cpath d='M90 11c-7 0-10 5-15 5-3.5 0-5-2.4-3.6-4.4'/%3E%3C/g%3E%3Cpath d='M1 11l3-2.2L7 11l-3 2.2z M125 11l3-2.2 3 2.2-3 2.2z' fill='%23B08D57'/%3E%3Ccircle cx='66' cy='11' r='4.4' fill='%237A1F2B'/%3E%3Ccircle cx='66' cy='11' r='2.5' fill='none' stroke='%23D8BC8A' stroke-width='.6'/%3E%3C/svg%3E");
  --mf-ornament: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 280 56'%3E%3Cg fill='none' stroke='%23B08D57' stroke-width='.9' stroke-linecap='round'%3E%3Cpath d='M22 28h96'/%3E%3Cpath d='M162 28h96'/%3E%3C/g%3E%3Cg fill='%23B08D57' fill-opacity='.8'%3E%3Cpath d='M30.0 26.7Q35.0 26.5 38.0 22.5Q33.0 22.7 30.0 26.7Z'/%3E%3Cpath d='M37.0 29.3Q40.0 33.3 45.0 33.5Q42.0 29.5 37.0 29.3Z'/%3E%3Cpath d='M250.0 26.7Q247.0 22.7 242.0 22.5Q245.0 26.5 250.0 26.7Z'/%3E%3Cpath d='M243.0 29.3Q238.0 29.5 235.0 33.5Q240.0 33.3 243.0 29.3Z'/%3E%3Cpath d='M46.0 26.7Q51.0 26.5 54.0 22.5Q49.0 22.7 46.0 26.7Z'/%3E%3Cpath d='M53.0 29.3Q56.0 33.3 61.0 33.5Q58.0 29.5 53.0 29.3Z'/%3E%3Cpath d='M234.0 26.7Q231.0 22.7 226.0 22.5Q229.0 26.5 234.0 26.7Z'/%3E%3Cpath d='M227.0 29.3Q222.0 29.5 219.0 33.5Q224.0 33.3 227.0 29.3Z'/%3E%3Cpath d='M62.0 26.7Q67.0 26.5 70.0 22.5Q65.0 22.7 62.0 26.7Z'/%3E%3Cpath d='M69.0 29.3Q72.0 33.3 77.0 33.5Q74.0 29.5 69.0 29.3Z'/%3E%3Cpath d='M218.0 26.7Q215.0 22.7 210.0 22.5Q213.0 26.5 218.0 26.7Z'/%3E%3Cpath d='M211.0 29.3Q206.0 29.5 203.0 33.5Q208.0 33.3 211.0 29.3Z'/%3E%3Cpath d='M78.0 26.7Q83.0 26.5 86.0 22.5Q81.0 22.7 78.0 26.7Z'/%3E%3Cpath d='M85.0 29.3Q88.0 33.3 93.0 33.5Q90.0 29.5 85.0 29.3Z'/%3E%3Cpath d='M202.0 26.7Q199.0 22.7 194.0 22.5Q197.0 26.5 202.0 26.7Z'/%3E%3Cpath d='M195.0 29.3Q190.0 29.5 187.0 33.5Q192.0 33.3 195.0 29.3Z'/%3E%3Cpath d='M94.0 26.7Q99.0 26.5 102.0 22.5Q97.0 22.7 94.0 26.7Z'/%3E%3Cpath d='M101.0 29.3Q104.0 33.3 109.0 33.5Q106.0 29.5 101.0 29.3Z'/%3E%3Cpath d='M186.0 26.7Q183.0 22.7 178.0 22.5Q181.0 26.5 186.0 26.7Z'/%3E%3Cpath d='M179.0 29.3Q174.0 29.5 171.0 33.5Q176.0 33.3 179.0 29.3Z'/%3E%3C/g%3E%3Cpath d='M14 28l4-3 4 3-4 3z M258 28l4-3 4 3-4 3z' fill='%23B08D57'/%3E%3Cpath d='M152.1 28.0C151.9 29.6 151.6 31.1 151.0 32.6C150.4 34.0 149.8 35.6 148.7 36.7C147.7 37.8 146.0 38.6 144.6 39.1C143.1 39.6 141.6 39.8 140.0 39.8C138.4 39.9 136.8 39.8 135.3 39.4C133.7 39.0 131.9 38.4 130.7 37.3C129.5 36.2 128.6 34.5 128.0 33.0C127.4 31.4 127.0 29.6 127.1 28.0C127.2 26.4 128.2 24.9 128.8 23.4C129.5 21.9 130.0 20.2 131.1 19.1C132.2 18.0 133.9 17.3 135.3 16.8C136.8 16.2 138.5 16.0 140.0 16.0C141.5 16.0 143.1 16.4 144.6 17.0C146.0 17.6 147.3 18.5 148.5 19.5C149.8 20.5 151.5 21.5 152.1 23.0C152.7 24.4 152.3 26.4 152.1 28.0Z' fill='%237A1F2B'/%3E%3Ccircle cx='140' cy='28' r='8.6' fill='none' stroke='%23D8BC8A' stroke-width='.7'/%3E%3Cpath d='M140 22.6c.45 3.4 1.8 4.9 5.2 5.4-3.4.4-4.7 2-5.2 5.4-.45-3.4-1.8-4.9-5.2-5.4 3.4-.5 4.7-2 5.2-5.4z' fill='%23E6CFA0'/%3E%3C/svg%3E");
  --mf-sprig: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 164 204'%3E%3Cg fill='none' stroke='%23B08D57' stroke-width='.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M8 196C40 150 70 90 150 14'/%3E%3Cpath d='M16.6 184.4Q27.0 186.1 35.3 179.6Q24.9 177.9 16.6 184.4Z'/%3E%3Cpath d='M23.3 171.9Q25.8 162.1 20.3 153.6Q17.8 163.4 23.3 171.9Z'/%3E%3Cpath d='M32.3 160.2Q41.9 161.6 49.5 155.5Q39.9 154.1 32.3 160.2Z'/%3E%3Cpath d='M39.7 146.6Q42.1 137.6 37.1 129.7Q34.6 138.7 39.7 146.6Z'/%3E%3Cpath d='M49.6 133.8Q58.4 135.3 65.5 129.8Q56.6 128.3 49.6 133.8Z'/%3E%3Cpath d='M58.4 119.1Q60.8 110.9 56.5 103.5Q54.0 111.7 58.4 119.1Z'/%3E%3Cpath d='M69.7 105.0Q77.7 106.8 84.4 102.1Q76.4 100.3 69.7 105.0Z'/%3E%3Cpath d='M80.6 89.2Q83.2 81.9 79.6 75.0Q77.0 82.3 80.6 89.2Z'/%3E%3Cpath d='M94.1 74.0Q101.2 76.0 107.5 72.1Q100.4 70.1 94.1 74.0Z'/%3E%3Cpath d='M107.6 57.1Q110.4 50.6 107.5 44.3Q104.7 50.7 107.6 57.1Z'/%3E%3Cpath d='M123.9 40.6Q130.1 42.8 135.9 39.7Q129.7 37.5 123.9 40.6Z'/%3E%3C/g%3E%3Cg fill='%23B08D57' fill-opacity='.75'%3E%3Ccircle cx='154' cy='11' r='2.2'/%3E%3Ccircle cx='146' cy='8' r='1.6'/%3E%3Ccircle cx='157' cy='20' r='1.5'/%3E%3C/g%3E%3C/svg%3E");
}
/* @recursos:fin */

/* =====================================================================
   PÁGINA · papel marfil sobre lino
   ===================================================================== */
html[data-theme="marfil"] {
  background-color: #E9DFCE;
  background-image:
    radial-gradient(70vw 70vh at 0% 0%, rgba(122, 31, 43, .08), transparent 70%),
    radial-gradient(60vw 60vh at 100% 100%, rgba(176, 141, 87, .2), transparent 70%),
    linear-gradient(rgba(233, 223, 206, .74), rgba(233, 223, 206, .74)),
    var(--mf-linen);
}
html[data-theme="marfil"] body.inv { letter-spacing: .005em; }
html[data-theme="marfil"] ::selection { background: color-mix(in srgb, var(--accent) 20%, transparent); }

html[data-theme="marfil"] .inv-section { background-image: var(--mf-grain); }
html[data-theme="marfil"] .inv-section.is-alt {
  background-image:
    linear-gradient(color-mix(in srgb, var(--bg-alt) 74%, transparent), color-mix(in srgb, var(--bg-alt) 74%, transparent)),
    var(--mf-linen);
}
/* costura fina entre secciones */
html[data-theme="marfil"] .inv-section.is-alt::before,
html[data-theme="marfil"] .inv-section.is-alt::after {
  content: ''; position: absolute; left: 0; right: 0; height: 1px; pointer-events: none;
  background: repeating-linear-gradient(90deg, color-mix(in srgb, var(--accent-2) 55%, transparent) 0 6px, transparent 6px 11px);
  opacity: .7;
}
html[data-theme="marfil"] .inv-section.is-alt::before { top: 9px; }
html[data-theme="marfil"] .inv-section.is-alt::after { bottom: 9px; }

/* ---------- tipografía ---------- */
html[data-theme="marfil"] .inv-head::before {
  content: ''; display: block; width: 132px; height: 22px; margin: 0 auto 20px;
  background: var(--mf-fleuron) center / contain no-repeat;
}
html[data-theme="marfil"] .inv-eyebrow {
  font-family: var(--font-body); font-weight: 500; font-size: .68rem; letter-spacing: .34em; color: var(--accent);
}
html[data-theme="marfil"] .inv-title {
  font-weight: 400; font-size: clamp(2.3rem, 10vw, 3.05rem); line-height: 1.04; letter-spacing: -.01em; color: var(--ink);
}
html[data-theme="marfil"] .inv-head .inv-title { margin-bottom: .75rem; }
html[data-theme="marfil"] .inv-text { font-size: 1rem; line-height: 1.78; }
html[data-theme="marfil"] .inv-head .inv-text { font-size: .98rem; max-width: 27em; }

/* ---------- tarjetas: papelería con doble filete ---------- */
html[data-theme="marfil"] .inv-card {
  background-color: var(--surface);
  background-image: var(--mf-grain);
  border: 1px solid color-mix(in srgb, var(--accent-2) 40%, transparent);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
html[data-theme="marfil"] .inv-card::after {
  content: ''; position: absolute; inset: 6px; z-index: 1; pointer-events: none;
  border: 1px solid color-mix(in srgb, var(--accent-2) 28%, transparent); border-radius: 3px;
}

/* ---------- botones: etiqueta de papelería ---------- */
html[data-theme="marfil"] .inv-btn {
  border-radius: 3px; min-height: 50px; padding: .95em 1.7em;
  font-family: var(--font-body); font-weight: 500; font-size: .72rem; letter-spacing: .22em; text-transform: uppercase;
  box-shadow: 0 10px 22px -14px color-mix(in srgb, var(--accent) 90%, transparent), inset 0 1px 0 rgba(255, 255, 255, .12);
}
html[data-theme="marfil"] .inv-btn .inv-icon { width: 1.35em; height: 1.35em; }
html[data-theme="marfil"] .inv-btn--ghost { border-width: 1px; box-shadow: none; background: transparent; }
html[data-theme="marfil"] .inv-btn--lg { min-height: 56px; font-size: .76rem; }
html[data-theme="marfil"] .inv-btn.is-draft { text-transform: none; letter-spacing: .02em; font-size: .86rem; }

/* =====================================================================
   HERO · retrato en arco sellado con lacre
   ===================================================================== */
html[data-theme="marfil"] .inv-hero { color: var(--ink); }
html[data-theme="marfil"] .inv-hero--framed,
html[data-theme="marfil"] .inv-hero--type,
html[data-theme="marfil"] .inv-hero--noimg {
  background-color: var(--bg);
  background-image:
    radial-gradient(80% 42% at 50% 28%, rgba(255, 253, 248, .95), rgba(255, 253, 248, 0) 72%),
    linear-gradient(color-mix(in srgb, var(--bg) 76%, transparent), color-mix(in srgb, var(--bg) 76%, transparent)),
    var(--mf-linen);
}
/* ramitas de línea fina en las esquinas superiores */
html[data-theme="marfil"] .inv-hero::before,
html[data-theme="marfil"] .inv-hero::after {
  content: ''; position: absolute; top: -6px; z-index: -1; width: 118px; height: 148px; pointer-events: none;
  background: var(--mf-sprig) center / contain no-repeat; opacity: .8;
}
html[data-theme="marfil"] .inv-hero::before { left: -8px; transform: scaleY(-1) rotate(8deg); }
html[data-theme="marfil"] .inv-hero::after { right: -8px; transform: scale(-1, -1) rotate(8deg); }
html[data-theme="marfil"] .inv-hero--photo::before,
html[data-theme="marfil"] .inv-hero--photo::after { display: none; }

html[data-theme="marfil"] .inv-hero--framed {
  justify-content: flex-start;
  padding-top: clamp(46px, 8vh, 84px);
}
html[data-theme="marfil"] .inv-hero--framed .inv-hero__media {
  width: min(64%, 292px);
  padding: 7px;
  background: var(--surface);
  border-color: color-mix(in srgb, var(--accent-2) 75%, transparent);
  box-shadow: 0 34px 60px -36px rgba(60, 36, 20, .55), 0 2px 5px rgba(60, 36, 20, .08);
}
html[data-theme="marfil"] .inv-hero--framed .inv-hero__media::before {
  inset: -11px;
  border-color: color-mix(in srgb, var(--accent-2) 45%, transparent);
}
/* lacre que sella el retrato */
html[data-theme="marfil"] .inv-hero--framed .inv-hero__media::after {
  content: ''; position: absolute; left: 50%; bottom: -33px; z-index: 3; width: 70px; height: 70px;
  background: var(--mf-seal) center / contain no-repeat;
  filter: drop-shadow(0 7px 8px rgba(70, 20, 25, .35));
  transform: translateX(-50%) rotate(-8deg) scale(.4); opacity: 0;
  transition: transform .9s var(--spring) 1.1s, opacity .4s ease 1.1s;
}
html[data-theme="marfil"].is-revealed .inv-hero--framed .inv-hero__media::after { transform: translateX(-50%) rotate(-8deg); opacity: 1; }
/* la foto se revela de arriba abajo (sin desbordar el arco) */
html[data-theme="marfil"] .inv-hero--framed .inv-hero__img {
  transform: none;
  background: var(--bg-alt);
  clip-path: inset(0 0 100% 0 round 999px 999px 14px 14px);
  transition: clip-path 1.8s var(--ease) .15s;
}
html[data-theme="marfil"].is-revealed .inv-hero--framed .inv-hero__img { clip-path: inset(0 0 0 0 round 999px 999px 14px 14px); }

html[data-theme="marfil"] .inv-hero--framed .inv-hero__content { padding-top: 44px; }
html[data-theme="marfil"] .inv-hero__eyebrow { color: var(--accent); opacity: 1; letter-spacing: .42em; margin-bottom: .2rem; }
html[data-theme="marfil"] .inv-hero--photo .inv-hero__eyebrow { color: inherit; }
html[data-theme="marfil"] .inv-hero__title {
  font-size: clamp(3.2rem, 14.2vw, 4.5rem); line-height: .98; color: var(--ink); margin: .12em 0 .1em;
}
html[data-theme="marfil"] .inv-amp {
  font-family: var(--font-display); font-style: italic; font-weight: 400;
  font-size: .56em; line-height: 1; margin: .06em 0 0; color: var(--mf-oro);
}
html[data-theme="marfil"] .inv-hero--photo .inv-amp { color: var(--mf-oro-claro); }
html[data-theme="marfil"] .inv-hero__subtitle {
  font-size: 1.22rem; line-height: 1.38; color: var(--ink-soft); opacity: 1; max-width: 19rem; margin-top: .5rem;
}
html[data-theme="marfil"] .inv-hero--photo .inv-hero__subtitle { color: inherit; }
html[data-theme="marfil"] .inv-hero__date { gap: 12px; max-width: 18.5rem; margin: 1.35rem auto .7rem; font-weight: 500; font-size: .66rem; letter-spacing: .3em; }
html[data-theme="marfil"] .inv-hero__date-side { border-color: color-mix(in srgb, var(--accent-2) 70%, transparent); padding: .7em 0; }
html[data-theme="marfil"] .inv-hero__date-day { font-weight: 300; font-size: 3.5rem; color: var(--accent); }
html[data-theme="marfil"] .inv-hero--photo .inv-hero__date-day { color: inherit; }
html[data-theme="marfil"] .inv-hero__time { font-size: .74rem; letter-spacing: .16em; text-transform: none; opacity: 1; color: var(--ink-soft); padding-top: 4px; }
html[data-theme="marfil"] .inv-hero--photo .inv-hero__time { color: inherit; opacity: .85; }
html[data-theme="marfil"] .inv-hero__place { font-size: .84rem; letter-spacing: .08em; color: var(--ink-soft); opacity: 1; }
html[data-theme="marfil"] .inv-hero--photo .inv-hero__place { color: inherit; }
html[data-theme="marfil"] .inv-hero__place .inv-icon { color: var(--accent); }
html[data-theme="marfil"] .inv-hero--photo .inv-hero__place .inv-icon { color: inherit; }
html[data-theme="marfil"] .inv-hero__cue { color: var(--ink-soft); }
html[data-theme="marfil"] .inv-hero--photo .inv-hero__cue { color: inherit; }

/* pase del invitado: tarjeta de mesa */
html[data-theme="marfil"] .inv-guest {
  border-radius: 4px; padding: 14px 26px 15px;
  background-color: var(--surface); background-image: var(--mf-grain);
  border: 1px solid color-mix(in srgb, var(--accent-2) 55%, transparent);
  box-shadow: 0 0 0 4px var(--surface), 0 0 0 5px color-mix(in srgb, var(--accent-2) 30%, transparent), var(--shadow);
}
html[data-theme="marfil"] .inv-guest__label { font-weight: 500; letter-spacing: .34em; font-size: .6rem; color: var(--accent); opacity: 1; }
html[data-theme="marfil"] .inv-guest__name { font-family: var(--font-display); font-weight: 500; font-size: 1.5rem; line-height: 1.15; }
html[data-theme="marfil"] .inv-guest__passes { font-size: .8rem; color: var(--ink-soft); opacity: 1; }
html[data-theme="marfil"] .inv-hero--photo .inv-guest { box-shadow: 0 10px 30px rgba(0, 0, 0, .2); }
html[data-theme="marfil"] .inv-hero--photo .inv-guest__label,
html[data-theme="marfil"] .inv-hero--photo .inv-guest__passes { color: inherit; }
html[data-theme="marfil"] .inv-hero__guest { margin-top: 1.5rem; }

/* =====================================================================
   SECCIONES
   ===================================================================== */

/* lacre reutilizable (insignias de íconos) */
html[data-theme="marfil"] .inv-event__icon,
html[data-theme="marfil"] .inv-event.has-img .inv-event__icon,
html[data-theme="marfil"] .inv-note__icon,
html[data-theme="marfil"] .inv-gift__icon,
html[data-theme="marfil"] .inv-dress__icon,
html[data-theme="marfil"] .inv-album__icon {
  color: var(--mf-oro-claro);
  background: radial-gradient(circle at 34% 28%, #B04A57 0%, var(--accent) 44%, #480E17 100%);
  border: 0;
  border-radius: 47% 53% 49% 51% / 53% 46% 54% 47%;
  box-shadow: inset 0 2px 2px rgba(255, 255, 255, .28), inset 0 -4px 7px rgba(0, 0, 0, .34), 0 8px 14px -6px rgba(80, 20, 28, .5);
}

/* quote — la cita abre con un lacre */
html[data-theme="marfil"] .inv-section--quote { padding-block: clamp(82px, 20vw, 118px); }
html[data-theme="marfil"] .inv-quote { padding-top: 3.6rem; max-width: 26rem; }
html[data-theme="marfil"] .inv-quote__mark {
  top: -14px; width: 60px; height: 60px; font-size: 0; opacity: 1;
  background: var(--mf-seal) center / contain no-repeat;
  filter: drop-shadow(0 6px 7px rgba(80, 20, 28, .3));
  transform: translateX(-50%) rotate(-10deg);
}
html[data-theme="marfil"] .inv-quote__text p {
  font-weight: 400; font-size: clamp(1.55rem, 6.7vw, 1.95rem); line-height: 1.36; color: var(--ink);
}
html[data-theme="marfil"] .inv-quote__author { font-weight: 500; font-size: .66rem; letter-spacing: .32em; color: var(--accent); }
html[data-theme="marfil"] .inv-quote__author::before { width: 54px; background: linear-gradient(90deg, transparent, var(--accent-2), transparent); }

/* countdown — cifras de imprenta entre filetes */
html[data-theme="marfil"] .inv-countdown {
  position: relative; gap: 0; max-width: 372px; padding: 20px 0 18px;
  border-block: 1px solid color-mix(in srgb, var(--accent-2) 60%, transparent);
}
html[data-theme="marfil"] .inv-countdown::before,
html[data-theme="marfil"] .inv-countdown::after {
  content: ''; position: absolute; left: 0; right: 0; height: 1px; background: color-mix(in srgb, var(--accent-2) 32%, transparent);
}
html[data-theme="marfil"] .inv-countdown::before { top: 4px; }
html[data-theme="marfil"] .inv-countdown::after { bottom: 4px; }
html[data-theme="marfil"] .inv-countdown__unit { background: none; border: 0; border-radius: 0; box-shadow: none; padding: 4px 2px 2px; gap: 8px; }
html[data-theme="marfil"] .inv-countdown__unit + .inv-countdown__unit { border-left: 1px solid color-mix(in srgb, var(--accent-2) 45%, transparent); }
html[data-theme="marfil"] .inv-countdown__unit::before { display: none; }
html[data-theme="marfil"] .inv-countdown__num { font-weight: 300; font-size: clamp(2.7rem, 12.5vw, 3.4rem); color: var(--ink); }
html[data-theme="marfil"] .inv-countdown__lbl { font-weight: 500; font-size: .58rem; letter-spacing: .32em; color: var(--accent); }
html[data-theme="marfil"] .inv-countdown__date {
  font-family: var(--font-display); font-style: italic; font-size: 1.12rem; letter-spacing: .02em; text-transform: none; color: var(--ink-soft);
}
html[data-theme="marfil"] .inv-countdown__done { font-family: var(--font-script); font-style: normal; font-size: 2.6rem; }

/* story — la carta */
html[data-theme="marfil"] .inv-story__figure { width: min(76%, 300px); margin-bottom: 2.6rem; }
html[data-theme="marfil"] .inv-story__figure img { border-radius: 999px 999px 4px 4px; box-shadow: 0 30px 50px -32px rgba(60, 30, 20, .6); }
html[data-theme="marfil"] .inv-story__figure::after {
  inset: -9px; border-radius: 999px 999px 8px 8px; border-color: color-mix(in srgb, var(--accent-2) 60%, transparent);
}
html[data-theme="marfil"] .inv-story__glow { background: radial-gradient(closest-side, rgba(122, 31, 43, .12), transparent); }
html[data-theme="marfil"] .inv-story__body .inv-text { text-align: left; hyphens: auto; -webkit-hyphens: auto; color: #4A443C; font-size: 1.02rem; }
html[data-theme="marfil"] .inv-story__body .inv-text:first-child::first-letter {
  font-family: var(--font-script); font-size: 4.3em; line-height: .78; padding: .1em .12em 0 0; color: var(--accent);
}
html[data-theme="marfil"] .inv-story__sig { font-size: 2.7rem; margin-top: 2rem; }
html[data-theme="marfil"] .inv-story__sig::after {
  content: ''; display: block; width: 46px; height: 46px; margin: .5rem auto 0;
  background: var(--mf-seal) center / contain no-repeat; transform: rotate(12deg);
  filter: drop-shadow(0 5px 6px rgba(80, 20, 28, .28));
}

/* people — padres y padrinos */
html[data-theme="marfil"] .inv-people.is-multi { grid-template-columns: 1fr 1fr; gap: 34px 14px; }
html[data-theme="marfil"] .inv-people__group { padding-bottom: 0; }
/* los padres a lo ancho; los padrinos en pares */
html[data-theme="marfil"] .inv-people__group:nth-child(-n + 2),
html[data-theme="marfil"] .inv-people__group:nth-child(odd):last-child { grid-column: 1 / -1; }
html[data-theme="marfil"] .inv-people.is-multi .inv-people__group:nth-child(3)::before {
  content: ''; position: absolute; left: 0; top: -18px; width: calc(200% + 14px); height: 1px;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--accent-2) 60%, transparent), transparent);
}
html[data-theme="marfil"] .inv-people__spark { display: none; }
html[data-theme="marfil"] .inv-people__label { font-size: .58rem; letter-spacing: .26em; margin-bottom: .55rem; }
html[data-theme="marfil"] .inv-people__names li { font-size: 1.24rem; line-height: 1.32; }
html[data-theme="marfil"] .inv-people__names li + li { margin-top: .2rem; }

/* events — tarjetas con fotografía enmarcada */
html[data-theme="marfil"] .inv-events { gap: 30px; }
html[data-theme="marfil"] .inv-event { padding-bottom: 30px; }
html[data-theme="marfil"] .inv-event__media { margin: 12px 12px 0; aspect-ratio: 16 / 10; border-radius: 2px; }
html[data-theme="marfil"] .inv-event__media::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, transparent 55%, rgba(40, 20, 12, .28));
}
html[data-theme="marfil"] .inv-event__media img { filter: saturate(.92) contrast(1.03); }
html[data-theme="marfil"] .inv-event__icon { width: 60px; height: 60px; position: relative; z-index: 2; }
html[data-theme="marfil"] .inv-event .inv-eyebrow { margin-bottom: .4rem; }
html[data-theme="marfil"] .inv-event__name { font-size: 1.62rem; line-height: 1.15; padding: 0 22px; }
html[data-theme="marfil"] .inv-event__meta { font-size: .9rem; gap: 8px; margin-top: 16px; }
html[data-theme="marfil"] .inv-event__meta li:first-child span { font-family: var(--font-display); font-size: 1.25rem; line-height: 1.1; color: var(--ink); }
html[data-theme="marfil"] .inv-event__actions { position: relative; z-index: 2; margin-top: 22px; }

/* timeline — programa de la noche */
html[data-theme="marfil"] .inv-timeline::before {
  left: 23.5px; width: 1px;
  background: linear-gradient(180deg, transparent, color-mix(in srgb, var(--accent-2) 80%, transparent) 6%, color-mix(in srgb, var(--accent-2) 80%, transparent) 94%, transparent);
}
html[data-theme="marfil"] .inv-timeline__item { grid-template-columns: 48px 1fr; gap: 18px; padding: 12px 0; }
html[data-theme="marfil"] .inv-section .inv-timeline__dot,
html[data-theme="marfil"] .inv-section.is-alt .inv-timeline__dot {
  width: 48px; height: 48px; color: var(--accent);
  background: var(--surface); border: 1px solid color-mix(in srgb, var(--accent-2) 70%, transparent);
  box-shadow: 0 0 0 5px var(--bg), 0 0 0 6px color-mix(in srgb, var(--accent-2) 25%, transparent);
}
html[data-theme="marfil"] .inv-section.is-alt .inv-timeline__dot { box-shadow: 0 0 0 5px var(--bg-alt), 0 0 0 6px color-mix(in srgb, var(--accent-2) 25%, transparent); }
html[data-theme="marfil"] .inv-timeline__dot .inv-icon { width: 20px; height: 20px; }
html[data-theme="marfil"] .inv-timeline__body { padding-top: 3px; }
html[data-theme="marfil"] .inv-timeline__time { font-weight: 500; font-size: .66rem; letter-spacing: .26em; }
html[data-theme="marfil"] .inv-timeline__title { font-size: 1.42rem; line-height: 1.2; }
html[data-theme="marfil"] .inv-timeline__text { font-size: .9rem; }

/* dresscode — tarjeta de etiqueta con chips de cera */
html[data-theme="marfil"] .inv-dress {
  position: relative; padding: 36px 22px 32px;
  background-color: var(--surface); background-image: var(--mf-grain);
  border: 1px solid color-mix(in srgb, var(--accent-2) 40%, transparent); border-radius: var(--radius);
  box-shadow: var(--shadow);
}
html[data-theme="marfil"] .inv-dress::after {
  content: ''; position: absolute; inset: 6px; pointer-events: none;
  border: 1px solid color-mix(in srgb, var(--accent-2) 28%, transparent); border-radius: 3px;
}
html[data-theme="marfil"] .inv-dress__icon { width: 58px; height: 58px; }
html[data-theme="marfil"] .inv-dress__code { font-family: var(--font-script); font-size: clamp(2.8rem, 13vw, 3.4rem); line-height: 1.2; color: var(--accent); margin-bottom: .3rem; }
html[data-theme="marfil"] .inv-dress__label { font-weight: 500; font-size: .6rem; letter-spacing: .3em; color: var(--ink-soft); }
html[data-theme="marfil"] .inv-chip {
  background: transparent; border-color: color-mix(in srgb, var(--accent-2) 45%, transparent);
  font-size: .82rem; letter-spacing: .02em; padding-right: 15px;
}
html[data-theme="marfil"] .inv-chip__swatch {
  width: 25px; height: 25px; border-radius: 47% 53% 49% 51% / 53% 46% 54% 47%;
  box-shadow: inset 0 2px 2px rgba(255, 255, 255, .32), inset 0 -3px 5px rgba(0, 0, 0, .3), 0 2px 5px rgba(0, 0, 0, .15);
}
html[data-theme="marfil"] .inv-chip--avoid { padding-left: 13px; }

/* gallery — copias con paspartú */
html[data-theme="marfil"] .inv-gallery__track { gap: 14px; }
html[data-theme="marfil"] .inv-gallery__track .inv-gallery__item {
  padding: 8px; border-radius: 2px;
  background-color: var(--surface); background-image: var(--mf-grain);
  box-shadow: 0 1px 2px rgba(60, 36, 20, .08), 0 26px 40px -28px rgba(60, 36, 20, .6);
}
html[data-theme="marfil"] .inv-gallery__item img { border-radius: 1px; }
html[data-theme="marfil"] .inv-gallery--grid .inv-gallery__item,
html[data-theme="marfil"] .inv-gallery--polaroids .inv-gallery__item { border-radius: 2px; }
html[data-theme="marfil"] .inv-gallery__dots span { height: 5px; width: 5px; background: color-mix(in srgb, var(--accent-2) 45%, transparent); }
html[data-theme="marfil"] .inv-gallery__dots span.is-on { width: 26px; background: var(--accent); }
html[data-theme="marfil"] .inv-gallery__nav { border-radius: 3px; border-color: color-mix(in srgb, var(--accent-2) 50%, transparent); color: var(--accent); }

/* gifts y hotels */
html[data-theme="marfil"] .inv-gifts, html[data-theme="marfil"] .inv-hotels { gap: 20px; }
html[data-theme="marfil"] .inv-gift, html[data-theme="marfil"] .inv-hotel { padding: 26px 22px 24px; grid-template-columns: 50px 1fr; }
html[data-theme="marfil"] .inv-gift__icon { width: 50px; height: 50px; }
html[data-theme="marfil"] .inv-gift__icon .inv-icon { width: 22px; height: 22px; }
html[data-theme="marfil"] .inv-hotel__icon {
  width: 50px; height: 50px; border-radius: 50%; color: var(--accent);
  background: var(--bg); border: 1px solid color-mix(in srgb, var(--accent-2) 60%, transparent);
}
html[data-theme="marfil"] .inv-gift__title, html[data-theme="marfil"] .inv-hotel__name { font-size: 1.4rem; font-weight: 500; }
html[data-theme="marfil"] .inv-gift__detail, html[data-theme="marfil"] .inv-hotel__detail { font-size: .9rem; }
html[data-theme="marfil"] .inv-gift__copy {
  font-size: .86rem; letter-spacing: .1em; border-radius: 2px; background: var(--bg);
  border: 1px dashed color-mix(in srgb, var(--accent-2) 70%, transparent);
}
html[data-theme="marfil"] .inv-gift__actions, html[data-theme="marfil"] .inv-hotel__actions { position: relative; z-index: 2; }
html[data-theme="marfil"] .inv-gift__actions .inv-btn, html[data-theme="marfil"] .inv-hotel__actions .inv-btn { min-height: 44px; font-size: .66rem; padding: .7em 1.1em; }
html[data-theme="marfil"] .inv-hotel__code strong { font-family: var(--font-body); font-weight: 600; letter-spacing: .14em; }

/* note — aviso con lacre */
html[data-theme="marfil"] .inv-note {
  position: relative; grid-template-columns: 1fr; justify-items: center; gap: 14px; text-align: center;
  padding: 38px 26px 32px; border-radius: var(--radius);
  background-color: var(--surface); background-image: var(--mf-grain);
  border: 1px solid color-mix(in srgb, var(--accent-2) 42%, transparent);
  box-shadow: var(--shadow);
}
html[data-theme="marfil"] .inv-note::after {
  content: ''; position: absolute; inset: 6px; pointer-events: none;
  border: 1px solid color-mix(in srgb, var(--accent-2) 28%, transparent); border-radius: 3px;
}
html[data-theme="marfil"] .inv-note__icon { width: 58px; height: 58px; }
html[data-theme="marfil"] .inv-note__title { font-style: italic; font-size: 1.62rem; line-height: 1.2; margin-bottom: .5rem; }
html[data-theme="marfil"] .inv-note .inv-text { max-width: 24rem; margin-inline: auto; }

/* formularios */
html[data-theme="marfil"] .inv-input { border-radius: 3px; border-width: 1px; background: color-mix(in srgb, var(--bg) 70%, #fff); }
html[data-theme="marfil"] .inv-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 12%, transparent); }
html[data-theme="marfil"] .inv-field__label { font-weight: 500; letter-spacing: .12em; text-transform: uppercase; font-size: .66rem; }
html[data-theme="marfil"] .inv-field__label small { text-transform: none; letter-spacing: 0; }
html[data-theme="marfil"] .inv-field, html[data-theme="marfil"] .inv-card .inv-btn { position: relative; z-index: 2; }

/* wishes — cartas en el muro */
html[data-theme="marfil"] .inv-wish {
  border-radius: 3px; background-color: var(--surface); background-image: var(--mf-grain);
  border-color: color-mix(in srgb, var(--accent-2) 35%, transparent);
  box-shadow: 0 16px 30px -24px rgba(60, 36, 20, .55);
}
html[data-theme="marfil"] .inv-wish:nth-child(odd) { transform: rotate(-.5deg); }
html[data-theme="marfil"] .inv-wish:nth-child(even) { transform: rotate(.4deg); }
html[data-theme="marfil"] .inv-wish:nth-child(3n + 2) { background-color: color-mix(in srgb, var(--mf-lino) 40%, var(--surface)); }
html[data-theme="marfil"] .inv-wish::before { color: var(--accent-2); }
html[data-theme="marfil"] .inv-wish__msg p { font-style: italic; font-size: 1.2rem; }

/* faq — índice de libro */
html[data-theme="marfil"] .inv-faq { gap: 0; border-top: 1px solid color-mix(in srgb, var(--accent-2) 55%, transparent); }
html[data-theme="marfil"] .inv-faq__item {
  background: none; border: 0; border-radius: 0; box-shadow: none;
  border-bottom: 1px solid color-mix(in srgb, var(--accent-2) 55%, transparent);
}
html[data-theme="marfil"] .inv-faq__item.is-open { box-shadow: none; }
html[data-theme="marfil"] .inv-faq__q { font-size: 1.24rem; padding: 18px 2px 18px 2px; min-height: 64px; }
html[data-theme="marfil"] .inv-faq__icon {
  width: 30px; height: 30px; background: transparent; color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent-2) 70%, transparent);
}
html[data-theme="marfil"] .inv-faq__item.is-open .inv-faq__icon { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
html[data-theme="marfil"] .inv-faq__a p { padding: 0 2px 22px; font-size: .95rem; }

/* rsvp */
html[data-theme="marfil"] .inv-rsvp__form { padding: 26px 20px 28px; }
html[data-theme="marfil"] .inv-rsvp__face { border-radius: 4px; border-width: 1px; background: color-mix(in srgb, var(--bg) 70%, #fff); }
html[data-theme="marfil"] .inv-rsvp__face-ico .inv-sparkle path { fill: var(--accent-2); }
html[data-theme="marfil"] .inv-rsvp__face-txt strong { font-family: var(--font-display); font-size: 1.3rem; font-weight: 600; }
html[data-theme="marfil"] .inv-rsvp__radio:checked + .inv-rsvp__face { background: color-mix(in srgb, var(--accent) 6%, var(--surface)); }
html[data-theme="marfil"] .inv-stepper { border-radius: 4px; border-width: 1px; background: color-mix(in srgb, var(--bg) 70%, #fff); }
html[data-theme="marfil"] .inv-stepper__btn { border-width: 1px; }
html[data-theme="marfil"] .inv-stepper__val { font-weight: 400; }
html[data-theme="marfil"] .inv-rsvp__seats i { border-radius: 2px; border-color: color-mix(in srgb, var(--accent-2) 80%, transparent); }
html[data-theme="marfil"] .inv-rsvp__badge {
  border-radius: 47% 53% 49% 51% / 53% 46% 54% 47%;
  background: radial-gradient(circle at 34% 28%, #B04A57 0%, var(--accent) 44%, #480E17 100%);
  color: var(--mf-oro-claro);
}
html[data-theme="marfil"] .inv-rsvp__badge.is-no { background: var(--surface); color: var(--accent); }
html[data-theme="marfil"] .inv-rsvp__done-title { font-style: italic; }

/* divider */
html[data-theme="marfil"] .inv-divider.has-ornament { height: 50px; max-width: 290px; }

/* pie */
html[data-theme="marfil"] .inv-footer {
  padding-top: 92px;
  background-color: var(--bg-alt);
  background-image:
    linear-gradient(color-mix(in srgb, var(--bg-alt) 74%, transparent), color-mix(in srgb, var(--bg-alt) 74%, transparent)),
    var(--mf-linen);
}
html[data-theme="marfil"] .inv-footer__orn {
  width: 64px; height: 64px; margin-bottom: 18px; fill: transparent;
  background: var(--mf-seal) center / contain no-repeat; filter: drop-shadow(0 7px 8px rgba(80, 20, 28, .3));
}
html[data-theme="marfil"] .inv-footer__text { font-size: 2.5rem; line-height: 1.14; text-wrap: balance; }
html[data-theme="marfil"] .inv-footer__orn { color: transparent; }
html[data-theme="marfil"] .inv-footer__date { font-weight: 500; font-size: .68rem; letter-spacing: .34em; color: var(--accent); }

/* barra de acciones y hojas */
html[data-theme="marfil"] .inv-actionbar {
  border-radius: 14px;
  background: color-mix(in srgb, var(--surface) 86%, transparent);
  border-color: color-mix(in srgb, var(--accent-2) 35%, transparent);
}
html[data-theme="marfil"] .inv-actionbar__btn { border-radius: 10px; font-weight: 500; letter-spacing: .04em; }
html[data-theme="marfil"] .inv-sheet__panel { background-color: var(--surface); background-image: var(--mf-grain); }
html[data-theme="marfil"] .inv-sheet__opt { border-radius: 6px; border-width: 1px; }

/* =====================================================================
   INTRO · sobre de papel sobre un mantel de lino, lacre vino y oro
   ===================================================================== */
html[data-theme="marfil"] .inv-intro__eyebrow { font-weight: 500; letter-spacing: .4em; color: #3A2F25; }
html[data-theme="marfil"] .inv-intro.is-ready .inv-intro__eyebrow { opacity: .85; }
html[data-theme="marfil"] .inv-intro__cta {
  min-height: 52px; padding: 0 26px 0 22px; border-radius: 3px;
  background: var(--accent); color: var(--accent-ink);
  font-weight: 500; font-size: .7rem; letter-spacing: .26em; text-transform: uppercase;
  box-shadow: 0 18px 32px -16px rgba(90, 20, 30, .75), inset 0 1px 0 rgba(255, 255, 255, .14);
}
html[data-theme="marfil"] .inv-intro__cta-ring { animation-name: mfCtaRing; }
@keyframes mfCtaRing {
  0% { box-shadow: 0 0 0 0 rgba(122, 31, 43, .5); }
  80%, 100% { box-shadow: 0 0 0 15px rgba(122, 31, 43, 0); }
}
html[data-theme="marfil"] .inv-intro__cta:focus-visible { outline-color: var(--accent); }
html[data-theme="marfil"] .inv-intro__guest { border-radius: 4px; background: #F6F0E4; }

html[data-theme="marfil"] .inv-intro--envelope {
  --paper: #FBF7EF;
  --paper-2: #F3ECE0;
  --paper-3: #E2D6C2;
  background-color: #D3C3A7;
}
/* mantel de lino con luz cálida y viñeta */
html[data-theme="marfil"] .inv-intro--envelope .inv-intro__bg {
  background-image:
    radial-gradient(125% 80% at 50% 44%, transparent 38%, rgba(58, 36, 18, .42) 100%),
    radial-gradient(60% 42% at 50% 42%, rgba(255, 250, 240, .5), transparent 72%),
    linear-gradient(rgba(211, 195, 167, .5), rgba(211, 195, 167, .5)),
    var(--mf-linen);
}
/* luz de ventana que cae en diagonal sobre el mantel */
html[data-theme="marfil"] .inv-intro--envelope::after {
  content: ''; position: absolute; inset: -12%; z-index: -1; pointer-events: none;
  background: linear-gradient(116deg,
    transparent 14%, rgba(255, 247, 230, .3) 21%, rgba(255, 247, 230, .3) 31%, transparent 37%,
    transparent 41%, rgba(255, 247, 230, .22) 47%, rgba(255, 247, 230, .22) 57%, transparent 63%);
  filter: blur(16px);
  opacity: 0; transition: opacity 2s var(--ease) .3s;
}
html[data-theme="marfil"] .inv-intro--envelope.is-ready::after { opacity: 1; }
/* pétalos secos sobre el mantel */
html[data-theme="marfil"] .inv-intro--envelope .inv-intro__bg::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background-image: var(--mf-petal1), var(--mf-petal2), var(--mf-petal3), var(--mf-petal4), var(--mf-petal2), var(--mf-petal1), var(--mf-petal3);
  background-repeat: no-repeat;
  background-size: 30px, 24px, 22px, 27px, 19px, 21px, 26px;
  background-position: 12% 22%, 84% 17%, 91% 66%, 7% 71%, 22% 82%, 73% 84%, 60% 12%;
  filter: drop-shadow(0 2px 2px rgba(60, 30, 20, .25));
  opacity: 0; transition: opacity 1.2s var(--ease) .5s;
}
html[data-theme="marfil"] .inv-intro--envelope.is-ready .inv-intro__bg::before { opacity: .92; }
html[data-theme="marfil"] .inv-intro--envelope.is-opening .inv-intro__bg::before { opacity: 0; transition-delay: 1.4s; transition-duration: .8s; }

/* papel con grano */
html[data-theme="marfil"] .env__back {
  background: var(--mf-grain), linear-gradient(165deg, var(--paper-3), color-mix(in srgb, var(--paper-3), #000 9%));
  box-shadow: 0 36px 60px -30px rgba(50, 28, 12, .6);
}
html[data-theme="marfil"] .env__side.is-l { background: var(--mf-grain), linear-gradient(95deg, color-mix(in srgb, var(--paper-2), #000 6%), var(--paper-2) 70%); }
html[data-theme="marfil"] .env__side.is-r { background: var(--mf-grain), linear-gradient(265deg, color-mix(in srgb, var(--paper-2), #000 6%), var(--paper-2) 70%); }
html[data-theme="marfil"] .env__pocket::before { background: var(--mf-grain), linear-gradient(180deg, var(--paper-2), color-mix(in srgb, var(--paper-2), #000 4%)); }
html[data-theme="marfil"] .env__flap-out {
  background: var(--mf-grain), linear-gradient(180deg, color-mix(in srgb, var(--paper-2), #fff 30%), color-mix(in srgb, var(--paper-2), #000 5%));
}
/* forro de damasco vino y oro */
html[data-theme="marfil"] .env__flap-in {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, .28), rgba(0, 0, 0, 0) 45%),
    var(--mf-liner) 0 0 / 20px 20px;
}
/* tarjeta interior */
html[data-theme="marfil"] .env__card { background: var(--mf-grain), var(--paper); }
html[data-theme="marfil"] .env__card-in {
  border-color: color-mix(in srgb, var(--accent-2) 70%, transparent);
  outline: 1px solid color-mix(in srgb, var(--accent-2) 28%, transparent); outline-offset: 3px;
}
/* sparkle() pinta el <path> con currentColor: se tiñe con color, no con fill */
html[data-theme="marfil"] .env__card-spark,
html[data-theme="marfil"] .inv-wishes__spark { color: var(--accent-2); }
html[data-theme="marfil"] .env__card-eyebrow { color: var(--accent); opacity: 1; font-weight: 500; letter-spacing: .34em; }
html[data-theme="marfil"] .env__card-date { letter-spacing: .32em; opacity: .75; }
/* «Para:» manuscrito en el frente */
html[data-theme="marfil"] .env__to { bottom: 5.5%; }
html[data-theme="marfil"] .env__to-label { color: var(--accent); opacity: .9; font-weight: 500; }
html[data-theme="marfil"] .env__to-name { color: #2E2A25; padding-bottom: 2px; }
html[data-theme="marfil"] .env__to::after {
  content: ''; width: 64%; height: 1px; margin-top: 1px;
  background: linear-gradient(90deg, transparent, rgba(43, 42, 38, .3), transparent);
}
/* sobre un poco más grande: protagonista de la escena */
html[data-theme="marfil"] .env { --w: min(90vw, 400px, 60vh); }
@media (min-width: 700px) { html[data-theme="marfil"] .env { --w: min(56vw, 540px, 60vh); } }
/* faja de lino alrededor del sobre; el lacre la sella y cae al romperlo */
html[data-theme="marfil"] .env::after {
  content: ''; position: absolute; left: -1.2%; right: -1.2%; top: 55.5%; height: 13%; z-index: 5; pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .42), rgba(255, 255, 255, 0) 34%, rgba(60, 36, 20, .08) 100%),
    var(--mf-linen),
    #E6DAC6;
  border-block: 1px solid rgba(176, 141, 87, .6);
  border-radius: 1px;
  box-shadow: 0 4px 6px -3px rgba(60, 36, 20, .4), 0 -1px 0 rgba(255, 255, 255, .35);
  transition: opacity .45s var(--ease), transform .8s var(--ease);
}
html[data-theme="marfil"] .env.s1::after { opacity: 0; transform: translateY(55%) scaleX(1.03); }
/* lacre vino con monograma dorado */
html[data-theme="marfil"] .env__seal { width: 27%; z-index: 6; filter: drop-shadow(0 6px 7px rgba(60, 12, 20, .42)); }
html[data-theme="marfil"] .env__seal-face {
  background: radial-gradient(circle at 33% 27%, #B34D5A 0%, var(--seal) 42%, #470D16 100%);
}
html[data-theme="marfil"] .env__seal-ring {
  inset: 14%;
  border: 1.4px solid rgba(226, 198, 140, .78);
  box-shadow: inset 0 2px 3px rgba(0, 0, 0, .45), 0 1px 0 rgba(255, 255, 255, .22);
}
html[data-theme="marfil"] .env__seal-mono {
  font-family: var(--font-display); font-style: italic; font-weight: 600; letter-spacing: .01em;
  font-size: calc(var(--w) * .082);
  color: #E6CC93;
  background: linear-gradient(165deg, #F6E2B0 10%, #C9A15C 48%, #F1D9A2 62%, #A9823F 90%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  text-shadow: none;
  filter: drop-shadow(0 1px 0 rgba(40, 6, 12, .55));
  padding: 0 .08em;
}

/* =====================================================================
   EFECTOS · pétalos secos que caen al abrir (capa .inv-fx, solo CSS)
   ===================================================================== */
html[data-theme="marfil"] .inv-fx::before,
html[data-theme="marfil"] .inv-fx::after {
  content: ''; position: absolute; inset: 0; opacity: 0;
  background-repeat: no-repeat;
  filter: drop-shadow(0 3px 3px rgba(60, 30, 20, .18));
}
html[data-theme="marfil"] .inv-fx::before {
  background-image: var(--mf-petal1), var(--mf-petal2), var(--mf-petal3), var(--mf-petal4), var(--mf-petal2), var(--mf-petal1), var(--mf-petal3);
  background-size: 22px, 18px, 16px, 20px, 15px, 17px, 19px;
  background-position: 8% -6%, 26% -22%, 47% -12%, 66% -34%, 84% -9%, 36% -48%, 94% -40%;
}
html[data-theme="marfil"] .inv-fx::after {
  background-image: var(--mf-petal4), var(--mf-petal2), var(--mf-petal1), var(--mf-petal3), var(--mf-petal2);
  background-size: 18px, 21px, 14px, 17px, 16px;
  background-position: 15% -14%, 58% -30%, 78% -8%, 31% -40%, 90% -26%;
}
html[data-theme="marfil"].is-revealed .inv-fx::before { animation: mfPetalsA 10s cubic-bezier(.45, .05, .55, .95) .5s 1 both; }
html[data-theme="marfil"].is-revealed .inv-fx::after { animation: mfPetalsB 13s cubic-bezier(.45, .05, .55, .95) 2.4s 1 both; }
@keyframes mfPetalsA {
  0% { opacity: 0; background-position: 8% -6%, 26% -22%, 47% -12%, 66% -34%, 84% -9%, 36% -48%, 94% -40%; }
  6% { opacity: 1; }
  25% { background-position: 12% 22%, 21% 8%, 52% 18%, 61% -2%, 88% 21%, 40% -14%, 90% -7%; }
  50% { background-position: 6% 50%, 28% 38%, 45% 47%, 69% 32%, 81% 52%, 33% 20%, 96% 27%; }
  75% { background-position: 13% 78%, 22% 70%, 53% 77%, 62% 66%, 89% 82%, 41% 56%, 91% 62%; }
  92% { opacity: 1; }
  100% { opacity: 0; background-position: 9% 108%, 27% 104%, 48% 108%, 68% 100%, 84% 112%, 35% 92%, 95% 98%; }
}
@keyframes mfPetalsB {
  0% { opacity: 0; background-position: 15% -14%, 58% -30%, 78% -8%, 31% -40%, 90% -26%; }
  8% { opacity: .95; }
  33% { background-position: 20% 20%, 53% 4%, 83% 26%, 36% -6%, 85% 8%; }
  66% { background-position: 12% 56%, 60% 40%, 76% 62%, 28% 30%, 92% 44%; }
  90% { opacity: .95; }
  100% { opacity: 0; background-position: 18% 104%, 55% 94%, 81% 110%, 33% 82%, 88% 96%; }
}

/* =====================================================================
   ESCRITORIO · la invitación sobre un escritorio de lino
   ===================================================================== */
@media (min-width: 900px) {
  html[data-theme="marfil"] body.inv::before,
  html[data-theme="marfil"] body.inv::after {
    content: ''; position: fixed; z-index: -1; pointer-events: none;
    background: var(--mf-sprig) center / contain no-repeat; opacity: .55;
  }
  html[data-theme="marfil"] body.inv::before { left: max(2vw, calc(50% - 560px)); bottom: 6vh; width: 220px; height: 274px; }
  html[data-theme="marfil"] body.inv::after { right: max(2vw, calc(50% - 560px)); top: 5vh; width: 220px; height: 274px; transform: scale(-1, -1); }
  html[data-theme="marfil"] .inv-page { box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent-2) 30%, transparent), 0 50px 120px -40px rgba(60, 36, 20, .45); }
}

/* =====================================================================
   MOVIMIENTO REDUCIDO
   ===================================================================== */
@media (prefers-reduced-motion: reduce) {
  html[data-theme="marfil"] .inv-fx::before,
  html[data-theme="marfil"] .inv-fx::after { display: none; }
  html[data-theme="marfil"] .inv-hero--framed .inv-hero__img { clip-path: none; transition: none; }
  html[data-theme="marfil"] .inv-hero--framed .inv-hero__media::after { transform: translateX(-50%) rotate(-8deg); opacity: 1; transition: none; }
  html[data-theme="marfil"] .inv-intro--envelope .inv-intro__bg::before { transition: none; }
}
