  /* =====================================================================
     ========== SKIN FESTORÍA (rediseño según mockup) ==========
     Header, inicio y nav inferior replican el diseño entregado. Las
     piezas ilustradas (logo, banner, carrusel de tarjetas, escena) son
     recortes del propio mockup en assets/festoria/. Todo lo demás de la
     app sigue igual y se tiñe con el tema "Festoría" (dorado cálido).
     ===================================================================== */
  :root{
    --fx-w:min(100vw, 480px);
    /* Alto del header y de la barra inferior Terraviva: proporción de
       sus imágenes (895×264 y 895×218) sobre el ancho de la app. */
    --fx-hdr-img:calc(var(--fx-w) * 264 / 895);
    --header-h:calc(var(--fx-hdr-img) + env(safe-area-inset-top, 0px));
    --nav-h:calc(var(--fx-w) * 218 / 895);
    --nav-total:calc(var(--nav-h) + env(safe-area-inset-bottom, 0px));
    --fx-gold:var(--t-glow);
    --fx-gold-deep:var(--t-primary);
    --fx-ink:#140604;
  }
  body{ background:#0b0302; }
  #appHeader.fx-header{
    background:var(--fx-ink);
    overflow:visible; padding-top:0;
  }
  #appHeader.fx-header > *{ z-index:1; }
  /* Las ilustraciones (banner, tarjetas, escena, logo) siguen el tema */
  .fx-slice > img, .fx-card img, #eventoImgDetalle, #eventoThumbImg,
  #reservaFormHeroImg, .splash-logo{ filter:var(--fx-art-filter, none); }

  /* El arte del header, los botones redondos y la barra inferior ahora
     los define css/terraviva.css (el header se ve en todas las vistas). */
  .fx-logo-hit{
    position:absolute; left:22%; right:22%; top:4%; bottom:8%;
    background:none; border:0; padding:0; cursor:pointer;
    -webkit-tap-highlight-color:transparent;
  }

  /* ---------- Menú lateral (hamburguesa): aquí vive "Temas" ---------- */
  .fx-drawer-backdrop{
    position:fixed; inset:0; z-index:9600; background:rgba(0,0,0,.55);
    opacity:0; visibility:hidden; transition:opacity .25s ease, visibility .25s;
  }
  .fx-drawer{
    position:fixed; top:0; bottom:0; left:0; z-index:9601;
    width:min(78%, 320px); overflow-y:auto;
    background:linear-gradient(180deg, #1d0a05 0%, #120503 100%);
    border-right:1.5px solid color-mix(in srgb, var(--t-secondary) 55%, transparent);
    box-shadow:6px 0 30px rgba(0,0,0,.6), 0 0 18px color-mix(in srgb, var(--t-secondary) 25%, transparent);
    transform:translateX(-102%); transition:transform .28s cubic-bezier(.22,1,.36,1);
    padding:calc(env(safe-area-inset-top, 0px) + 18px) 14px 24px;
  }
  body.fx-drawer-open .fx-drawer{ transform:none; }
  body.fx-drawer-open .fx-drawer-backdrop{ opacity:1; visibility:visible; }
  .fx-drawer-head{ display:flex; align-items:center; justify-content:space-between; margin-bottom:14px; }
  .fx-drawer-title{ font-family:'Poppins',sans-serif; font-weight:800; font-size:20px; letter-spacing:.5px;
    background:linear-gradient(180deg,#fff2b8,var(--fx-gold) 55%,var(--t-primary)); -webkit-background-clip:text; background-clip:text; color:transparent; }
  .fx-drawer-close{ width:34px; height:34px; border-radius:50%; border:1.5px solid color-mix(in srgb, var(--t-secondary) 60%, transparent); background:transparent; color:var(--fx-gold); font-size:16px; cursor:pointer; }
  .fx-drawer-item{
    display:block; width:100%; text-align:left; cursor:pointer;
    margin-bottom:8px; padding:12px 14px; border-radius:14px;
    background:color-mix(in srgb, var(--t-secondary) 6%, transparent); border:1px solid color-mix(in srgb, var(--t-secondary) 22%, transparent);
    color:#fbe9c9; font:600 14.5px 'Inter',sans-serif;
  }
  .fx-drawer-item:active{ background:color-mix(in srgb, var(--t-secondary) 16%, transparent); }
  .fx-drawer-item .fx-ico{ display:inline-block; width:26px; }
  .fx-drawer-item.fx-temas{ border-color:color-mix(in srgb, var(--t-secondary) 60%, transparent); box-shadow:0 0 10px color-mix(in srgb, var(--t-secondary) 25%, transparent); }
  .fx-drawer-sep{ height:1px; margin:12px 4px; background:linear-gradient(90deg,transparent,color-mix(in srgb, var(--t-secondary) 45%, transparent),transparent); }
  /* El panel de temas ahora se abre desde la esquina izquierda */
  .theme-panel{ right:auto !important; left:clamp(12px, 4vw, 18px); z-index:9700; }

  /* ---------- Inicio ---------- */
  .fx-home{ display:block; line-height:0; }
  .fx-slice{ position:relative; display:block; width:100%; padding:0; margin:0; border:0; background:none; }
  .fx-slice > img{ display:block; width:100%; height:auto; user-select:none; -webkit-user-drag:none; }
  button.fx-slice{ cursor:pointer; -webkit-tap-highlight-color:transparent; }
  button.fx-slice:active > img{ filter:brightness(1.08); }
  .fx-hot{
    position:absolute; border:0; padding:0; background:transparent; cursor:pointer;
    border-radius:9% / 6%; -webkit-tap-highlight-color:transparent;
    transition:box-shadow .2s ease, background .2s ease;
  }
  .fx-hot:focus-visible, .fx-hot:active{
    background:color-mix(in srgb, var(--t-secondary) 10%, transparent);
    box-shadow:0 0 0 2px color-mix(in srgb, var(--t-secondary) 85%, transparent), 0 0 24px color-mix(in srgb, var(--t-secondary) 70%, transparent);
    outline:none;
  }
  .fx-hot--carta{ z-index:2; }
  .fx-legacy{ display:none !important; }
  /* ---------- Carrusel deslizable de tarjetas ---------- */
  .fx-carousel{
    position:relative; line-height:normal;
    height:calc(var(--fx-w) * 0.585);
    background:
      radial-gradient(ellipse 55% 60% at 50% 42%, color-mix(in srgb, var(--t-secondary) 30%, transparent), transparent 70%),
      radial-gradient(ellipse 90% 70% at 50% 40%, rgba(120,30,60,.35), transparent 75%);
  }
  .fx-carousel-stage{
    position:absolute; left:3%; right:3%; bottom:3.5%; height:15%;
    border-radius:50%;
    background:radial-gradient(ellipse at 50% 40%, #3a1a08 0%, #160703 70%);
    border:2px solid color-mix(in srgb, var(--t-secondary) 90%, transparent);
    box-shadow:0 0 14px color-mix(in srgb, var(--t-secondary) 90%, transparent), 0 0 34px color-mix(in srgb, var(--t-secondary) 50%, transparent), inset 0 0 18px color-mix(in srgb, var(--t-secondary) 40%, transparent);
  }
  .fx-track{
    position:relative; z-index:1; height:100%;
    display:flex; align-items:center;
    overflow-x:auto; overflow-y:hidden;
    scroll-snap-type:x mandatory; scroll-behavior:smooth;
    -webkit-overflow-scrolling:touch; overscroll-behavior-x:contain;
    scrollbar-width:none;
    padding:0 calc(50% - var(--fx-w) * 0.165);
    perspective:900px;
    touch-action:pan-x pan-y;
  }
  .fx-track::-webkit-scrollbar{ display:none; }
  .fx-track.fx-dragging{ scroll-snap-type:none; scroll-behavior:auto; cursor:grabbing; }
  .fx-card{
    flex:0 0 calc(var(--fx-w) * 0.33);
    margin:0;
    aspect-ratio:2/3; padding:0; cursor:pointer;
    scroll-snap-align:center;
    border:2.5px solid var(--fx-gold); border-radius:16px; overflow:hidden;
    background:#120604;
    box-shadow:0 0 10px color-mix(in srgb, var(--t-secondary) 90%, transparent), 0 0 26px color-mix(in srgb, var(--t-secondary) 45%, transparent), inset 0 0 10px color-mix(in srgb, var(--t-secondary) 35%, transparent);
    transform-origin:50% 60%;
    will-change:transform;
    -webkit-tap-highlight-color:transparent;
    transition:box-shadow .2s ease;
  }
  .fx-card img{ display:block; width:100%; height:100%; object-fit:cover; pointer-events:none; user-select:none; }
  .fx-card.is-center{ box-shadow:0 0 14px color-mix(in srgb, var(--t-secondary) 100%, transparent), 0 0 40px color-mix(in srgb, var(--t-secondary) 70%, transparent), inset 0 0 12px color-mix(in srgb, var(--t-secondary) 45%, transparent); }
  .fx-card:active.is-center{ filter:brightness(1.1); }
  @media (prefers-reduced-motion: reduce){ .fx-track{ scroll-behavior:auto; } }

  /* El inicio ocupa toda la pantalla: la escena final llega hasta abajo
     y queda detrás de la barra flotante, como en el diseño. */
  #view-inicio.active, #view-reservas.active{
    display:flex; flex-direction:column;
    min-height:calc(100% + var(--nav-total)); margin-bottom:calc(-1 * var(--nav-total)); padding-bottom:0;
  }
  #view-inicio .fx-home, #view-reservas .fx-home{ flex:1 0 auto; display:flex; flex-direction:column; }
  #view-inicio .fx-scene, #view-reservas .fx-scene{ flex:1 0 auto; display:flex; }
  #view-inicio .fx-scene > img, #view-reservas .fx-scene > img{ flex:1 1 auto; width:100%; height:auto; object-fit:cover; object-position:center top; }
  .fx-res-card{ transition:transform .15s ease; }
  /* ---------- Banners del inicio (rotan solos) ---------- */
  .fx-hero-slider{ overflow:hidden; touch-action:pan-y; }
  .fx-hero-sizer{ visibility:hidden; }
  .fx-hero-slide{
    position:absolute; inset:0; padding:0; border:0; background:none; cursor:pointer;
    opacity:0; transition:opacity .7s ease; pointer-events:none; -webkit-tap-highlight-color:transparent;
  }
  .fx-hero-slide.is-active{ opacity:1; pointer-events:auto; }
  .fx-hero-slide > img{ display:block; width:100%; height:100%; object-fit:cover; filter:var(--fx-art-filter, none); }
  /* mismo hueco que la tarjeta dorada del 1er banner (848×322 dentro de 884×340) */
  .fx-hero-slide--marco > img{
    position:absolute; left:2.04%; right:2.04%; top:2.6%; bottom:2.6%; width:auto; height:auto;
    width:95.92%; height:94.8%; border-radius:16px;
    border:2px solid var(--fx-gold);
    box-shadow:0 0 10px color-mix(in srgb, var(--t-secondary) 90%, transparent), 0 0 24px color-mix(in srgb, var(--t-secondary) 45%, transparent);
    box-sizing:border-box;
  }
  .fx-hero-dots{ position:absolute; left:0; right:0; bottom:6.5%; display:flex; justify-content:center; gap:6px; z-index:3; pointer-events:none; }
  .fx-hero-dots span{ width:6px; height:6px; border-radius:50%; background:rgba(255,255,255,.45); transition:all .3s ease; }
  .fx-hero-dots span.on{ width:16px; border-radius:3px; background:var(--fx-gold); box-shadow:0 0 6px var(--fx-gold); }

  /* ---------- Mi Perfil (mockup) ---------- */
  #view-perfil.active{ padding-bottom:110px; }
  .fx-pf-hero, .fx-pf-stats, .fx-pf-row{ line-height:normal; }
  .fx-pf-foto{
    position:absolute; left:50%; top:55.5%; width:19.2%; aspect-ratio:1; transform:translate(-50%,-50%);
    border-radius:50%; overflow:hidden; display:none; background:#2a1206;
  }
  .fx-pf-foto img{ width:100%; height:100%; object-fit:cover; display:block; }
  .fx-pf-cam{ left:53%; top:63%; width:8.5%; height:21%; border-radius:50%; z-index:2; }
  .fx-pf-saludo{
    position:absolute; left:50%; top:92.4%; transform:translate(-50%,-50%); margin:0;
    max-width:41%; white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
    font:700 calc(var(--fx-w) * 0.031) 'Poppins',sans-serif; color:#fff; text-shadow:0 1px 6px rgba(0,0,0,.8);
  }
  .fx-pf-num{
    position:absolute; top:55.4%; transform:translate(-50%,-50%);
    font:800 calc(var(--fx-w) * 0.036) 'Poppins',sans-serif; color:#fff; text-shadow:0 0 6px color-mix(in srgb, var(--t-secondary) 70%, transparent);
    pointer-events:none;
  }
  .fx-pf-badge{
    position:absolute; left:12%; top:16%; min-width:20px; height:20px; padding:0 5px; border-radius:10px;
    background:#ff3b30; color:#fff; font:800 11px/20px 'Inter',sans-serif; text-align:center; display:none;
    box-shadow:0 0 8px rgba(255,59,48,.9);
  }
  .fx-pf-sub{
    position:absolute; left:19.1%; top:65%; transform:translateY(-50%); white-space:nowrap;
    font:400 calc(var(--fx-w) * 0.0232) 'Inter',sans-serif; color:#fff; pointer-events:none;
  }
  .fx-pf-chip{
    position:absolute; right:12%; top:14%; padding:2px 8px; border-radius:999px; display:none;
    background:rgba(16,185,129,.18); border:1px solid rgba(16,185,129,.8); color:#a7f3d0; font:700 10.5px 'Inter',sans-serif;
  }
  .fx-pf-row{ transition:transform .15s ease; }
  .fx-pf-row:active, .fx-pf-daynite:active{ transform:scale(.985); }
  .fx-pf-daynite{ display:block; margin-top:4px; }
  .fx-pf-daynite > img{ display:block; width:100%; height:auto; filter:var(--fx-art-filter, none); }
  .fx-pf-logout{
    display:flex; align-items:center; gap:14px; width:calc(100% - 5.4%); margin:8px auto; padding:14px 16px; text-align:left; cursor:pointer;
    border-radius:18px; background:rgba(30,8,10,.85); color:#fff; font:400 13px 'Inter',sans-serif;
    border:1.8px solid var(--fx-gold); box-shadow:0 0 10px color-mix(in srgb, var(--t-secondary) 80%, transparent);
  }
  .fx-pf-logout span:first-child{ font-size:24px; }
  .fx-pf-logout b{ display:block; font:700 16px 'Poppins',sans-serif; }
  .fx-pf-logout small{ color:#d9cfc9; font-size:12.5px; }
  .fx-pf-chev{ margin-left:auto; font-size:26px; color:var(--fx-gold); }

  /* ---------- Formulario de reserva (mockup Cumpleaños) ---------- */
  .fx-rf{ padding:8px 12px 18px; position:relative;
    background:
      linear-gradient(135deg, transparent 0 46%, transparent 46%) ,
      radial-gradient(ellipse 80% 40% at 50% 100%, color-mix(in srgb, var(--t-secondary) 14%, transparent), transparent 70%);
  }
  .fx-rf-banner{
    position:relative; border-radius:18px; overflow:hidden;
    border:2px solid var(--fx-gold); background:#120503;
    box-shadow:0 0 12px color-mix(in srgb, var(--t-secondary) 85%, transparent), 0 0 28px color-mix(in srgb, var(--t-secondary) 40%, transparent);
  }
  .fx-rf-banner img{ display:block; width:100%; height:auto; min-height:120px; object-fit:cover; }
  .fx-rf-top{ display:flex; align-items:flex-start; gap:14px; padding:4px 2px 12px; }
  .fx-rf-top-back{ background:none; border:0; padding:6px 2px; cursor:pointer; }
  .fx-rf-top-back svg{ width:26px; height:26px; fill:none; stroke:#fff; stroke-width:2.3; stroke-linecap:round; stroke-linejoin:round; }
  .fx-rf-top-title{ margin:0; font:800 26px/1.2 'Poppins',sans-serif; color:#fff; }
  .fx-rf-top-orn{ display:block; position:relative; width:120px; height:12px; margin-top:4px; }
  .fx-rf-top-orn::before{ content:''; position:absolute; left:0; right:0; top:50%; height:1.5px;
    background:linear-gradient(90deg, transparent, var(--fx-gold), transparent); }
  .fx-rf-top-orn::after{ content:''; position:absolute; left:50%; top:50%; width:8px; height:8px; margin:-4px 0 0 -4px;
    border:1.5px solid var(--fx-gold); background:#140604; transform:rotate(45deg); box-shadow:0 0 6px var(--fx-gold); }
  .fx-rf-submit--caps #reservaFormSubmitText{ text-transform:uppercase; letter-spacing:.2px; font-size:17px; }
  #reservaFormSubmitText{ white-space:nowrap; }
  .fx-rf-wa{ display:inline-block; width:18px; height:18px; vertical-align:-4px; margin-right:6px; }
  .fx-rf-back{
    position:absolute; left:8px; top:8px; width:34px; height:34px; border-radius:50%;
    display:flex; align-items:center; justify-content:center; padding:0; cursor:pointer;
    background:rgba(14,5,3,.72); border:1.5px solid var(--fx-gold);
    box-shadow:0 0 8px color-mix(in srgb, var(--t-secondary) 70%, transparent);
  }
  .fx-rf-back svg{ width:18px; height:18px; fill:none; stroke:var(--fx-gold); stroke-width:2.4; stroke-linecap:round; stroke-linejoin:round; }
  .fx-rf-title{
    position:absolute; left:0; right:0; bottom:0; margin:0; padding:26px 14px 10px;
    background:linear-gradient(180deg, transparent, rgba(10,3,2,.85));
    font:800 24px 'Poppins',sans-serif; color:#fff; text-shadow:0 0 10px color-mix(in srgb, var(--t-secondary) 90%, transparent);
  }
  .fx-rf-tagline{
    display:flex; align-items:center; justify-content:center; gap:10px;
    margin:12px 0 4px; text-align:center; color:#fff; font:500 13.5px/1.35 'Inter',sans-serif;
  }
  .fx-orn{ flex:0 0 34px; height:10px; position:relative; }
  .fx-orn::before{ content:''; position:absolute; left:0; right:0; top:50%; height:1.5px; background:var(--fx-gold); }
  .fx-orn::after{ content:''; position:absolute; left:50%; top:50%; width:8px; height:8px; margin:-4px 0 0 -4px;
    border:1.5px solid var(--fx-gold); background:#140604; transform:rotate(45deg); box-shadow:0 0 6px var(--fx-gold); }
  .fx-field{ margin-top:12px; }
  .fx-field label{ display:flex; align-items:center; gap:7px; font:700 13px 'Inter',sans-serif; color:#fff; margin-bottom:7px; }
  .fx-rf-ico{ display:inline-flex; width:20px; height:20px; }
  .fx-rf-ico svg{ width:100%; height:100%; fill:none; stroke:var(--fx-gold); stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round;
    filter:drop-shadow(0 0 3px color-mix(in srgb, var(--t-secondary) 80%, transparent)); }
  .fx-field input, .fx-field select, .fx-field textarea, .fx-wa{
    width:100%; min-height:44px; border-radius:12px; padding:0 14px;
    background:rgba(16,5,3,.88); color:#fff; font:400 14px 'Inter',sans-serif;
    border:1.5px solid color-mix(in srgb, var(--t-secondary) 80%, transparent);
    box-shadow:0 0 8px color-mix(in srgb, var(--t-secondary) 45%, transparent), inset 0 0 10px color-mix(in srgb, var(--t-secondary) 10%, transparent);
    color-scheme:dark;
  }
  .fx-field textarea{ padding:10px 14px; min-height:64px; resize:none; }
  .fx-field input::placeholder, .fx-field textarea::placeholder{ color:#a59a95; }
  .fx-field select{
    appearance:none; -webkit-appearance:none; padding-right:40px;
    background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat:no-repeat; background-position:right 12px center; background-size:18px;
  }
  .fx-field select:invalid{ color:#d9d2cf; }
  .fx-field input[type="date"]::-webkit-calendar-picker-indicator{ filter:invert(1); opacity:.9; cursor:pointer; }
  .fx-field input:focus, .fx-field select:focus, .fx-field textarea:focus, .fx-wa:focus-within{
    outline:none; border-color:var(--fx-gold);
    box-shadow:0 0 12px color-mix(in srgb, var(--t-secondary) 90%, transparent), inset 0 0 10px color-mix(in srgb, var(--t-secondary) 18%, transparent);
  }
  .fx-wa{ display:flex; align-items:stretch; padding:0; overflow:hidden; }
  .fx-wa-prefijo{
    display:flex; align-items:center; gap:7px; padding:0 12px; color:#fff; font:500 14px 'Inter',sans-serif;
    border-right:1.5px solid color-mix(in srgb, var(--t-secondary) 80%, transparent);
    border-radius:12px; box-shadow:0 0 8px color-mix(in srgb, var(--t-secondary) 45%, transparent);
  }
  .fx-flag-pe{ display:inline-block; width:22px; height:15px; border-radius:2px;
    background:linear-gradient(90deg,#d91023 0 33.3%,#fff 33.3% 66.6%,#d91023 66.6%); }
  .fx-field .fx-wa input{ border:0; box-shadow:none; background:transparent; min-height:42px; border-radius:0; }
  .fx-rf-submit-wrap{ margin-top:22px; padding:0 4px; }
  .fx-rf-submit{
    width:100%; height:64px; border-radius:999px; cursor:pointer;
    display:flex; align-items:center; justify-content:center; gap:14px; padding:0 22px;
    background:radial-gradient(ellipse 70% 120% at 50% 50%, #3a1306 0%, #1a0703 80%);
    border:2px solid var(--fx-gold); color:#fff; font:800 19px 'Poppins',sans-serif;
    box-shadow:0 0 14px color-mix(in srgb, var(--t-secondary) 95%, transparent), 0 0 36px color-mix(in srgb, var(--t-secondary) 50%, transparent), inset 0 0 16px color-mix(in srgb, var(--t-secondary) 35%, transparent);
    transition:transform .15s ease;
  }
  .fx-rf-submit:active{ transform:scale(.97); }
  .fx-rf-submit-ico{ display:inline-flex; width:38px; height:38px; color:var(--fx-gold); filter:drop-shadow(0 0 5px color-mix(in srgb, var(--t-secondary) 90%, transparent)); }
  .fx-rf-submit-ico svg{ width:100%; height:100%; }
  .fx-rf-submit-arrow{ width:24px; height:24px; margin-left:auto; fill:none; stroke:#fff; stroke-width:2.2; stroke-linecap:round; stroke-linejoin:round; }
  #reservaFormSubmitText{ flex:0 1 auto; }
  .fx-rf-footnote{ font-size:12px; color:#fff; text-align:center; margin-top:14px; }

  .fx-res-card:active{ transform:scale(.985); }
  body.fx-drawer-open .bottom-nav{ visibility:hidden; }
  #view-inicio #birthdayBanner{ margin-top:10px; line-height:normal; }

  .nav-item svg.nav-icon-bounce{ animation:navIconBounce 0.35s ease; }
