/* Leñaleón · sistema visual 2026
   Una sola voz para la web pública y el configurador de Don Goro. */
:root {
  --ll-carbon: #17130f;
  --ll-ink: #2b2119;
  --ll-ember: #e65319;
  --ll-ember-dark: #a93610;
  --ll-flame: #f2b632;
  --ll-oak: #b9854f;
  --ll-paper: #fbf7ef;
  --ll-sawdust: #ead8bd;
  --ll-moss: #2f6b45;
  --ll-danger: #b42318;
  --ll-radius: 18px;
  --ll-shadow: 0 18px 45px rgba(24, 16, 10, .16);
  --ll-display: 'Archivo Black', 'Montserrat', sans-serif;
  --ll-body: 'Poppins', 'Roboto', sans-serif;
  --ll-utility: 'Montserrat', sans-serif;
}

html { scroll-padding-top: 104px; }
body { font-family: var(--ll-body); }

body > header {
  min-height: 76px;
  background: rgba(251, 247, 239, .96) !important;
  border-bottom: 1px solid rgba(91, 61, 34, .16);
  box-shadow: 0 8px 30px rgba(34, 23, 14, .08) !important;
}
body > header::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--ll-ember-dark), var(--ll-ember) 42%, var(--ll-flame));
}
body > header nav { max-width: 1280px; }
body > header nav img {
  height: 60px !important;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 4px 6px rgba(52, 33, 20, .08));
}
body > header nav a { font-family: var(--ll-utility); }
body > header .nav-link {
  position: relative;
  font-weight: 700;
  letter-spacing: -.01em;
  color: #514238 !important;
}
body > header .nav-link:hover,
body > header .active-nav { color: var(--ll-ember-dark) !important; }
body > header .active-nav::after {
  content: '';
  position: absolute;
  left: 15%;
  right: 15%;
  bottom: -12px;
  height: 3px;
  border-radius: 99px;
  background: var(--ll-ember);
}

.btn {
  min-height: 44px;
  border-radius: 12px !important;
  font-family: var(--ll-utility) !important;
  font-weight: 800 !important;
  letter-spacing: .01em;
}
.btn-primary {
  color: #fff !important;
  border-color: var(--ll-ember) !important;
  background: linear-gradient(135deg, var(--ll-ember), #c64012) !important;
  box-shadow: 0 10px 24px rgba(230, 83, 25, .23) !important;
}
.btn-primary:hover { transform: translateY(-2px); filter: brightness(1.04); }
.btn-outline {
  color: var(--ll-ink) !important;
  border: 2px solid rgba(43, 33, 25, .22) !important;
  background: #fff !important;
}
.btn-outline:hover { border-color: var(--ll-ember) !important; color: var(--ll-ember-dark) !important; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, [role='button']:focus-visible {
  outline: 3px solid var(--ll-flame) !important;
  outline-offset: 3px;
}

footer {
  position: relative;
  background: #17130f !important;
  border-top: 5px solid var(--ll-ember);
}
footer h3 { font-family: var(--ll-display) !important; font-size: 1rem !important; letter-spacing: -.02em; }
footer a:hover { color: var(--ll-flame) !important; }

/* Configurador */
body.ll-purchase {
  color: var(--ll-ink);
  background:
    radial-gradient(circle at 12% 10%, rgba(230, 83, 25, .17), transparent 28rem),
    radial-gradient(circle at 88% 22%, rgba(242, 182, 50, .10), transparent 25rem),
    linear-gradient(180deg, #110d0a 0, #1c1510 620px, #302116 100%);
}
.ll-purchase #fire-canvas { opacity: .28; }
.ll-purchase > header { z-index: 60 !important; }
.ll-purchase > .mt-8.mb-12 {
  max-width: 1120px;
  margin: 30px auto 24px !important;
  text-align: left !important;
  padding: 38px 30px 20px !important;
}
.ll-purchase > .mt-8.mb-12 span:first-child {
  color: #ffe2bd !important;
  background: rgba(230, 83, 25, .16) !important;
  border-color: rgba(242, 182, 50, .28) !important;
}
.ll-purchase > .mt-8.mb-12 h1 {
  max-width: 850px;
  font-family: var(--ll-display);
  font-size: clamp(2.45rem, 6vw, 5.2rem) !important;
  line-height: .98;
  letter-spacing: -.055em;
  text-wrap: balance;
}
.ll-purchase > .mt-8.mb-12 p {
  max-width: 790px !important;
  margin-left: 0 !important;
  font-size: clamp(1rem, 2vw, 1.18rem) !important;
  color: #e9ded3 !important;
}

.ll-process-rail {
  position: sticky;
  top: 79px;
  z-index: 35;
  width: min(1240px, calc(100% - 28px));
  margin: 0 auto 26px;
  padding: 10px;
  overflow-x: auto;
  scrollbar-width: none;
  background: rgba(23, 19, 15, .94);
  border: 1px solid rgba(242, 182, 50, .20);
  border-radius: 16px;
  box-shadow: 0 12px 34px rgba(0, 0, 0, .24);
  backdrop-filter: blur(16px);
}
.ll-process-rail::-webkit-scrollbar { display: none; }
.ll-process-list {
  display: grid;
  grid-template-columns: repeat(6, minmax(132px, 1fr));
  gap: 7px;
  min-width: 840px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ll-process-item {
  display: grid;
  grid-template-columns: 30px 1fr;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  padding: 7px 10px;
  color: #b7a99d;
  border: 1px solid transparent;
  border-radius: 11px;
  cursor: pointer;
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.ll-process-index {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  color: #ead8bd;
  background: rgba(255, 255, 255, .07);
  font: 800 12px/1 var(--ll-utility);
}
.ll-process-copy strong { display: block; font: 800 11px/1.1 var(--ll-utility); text-transform: uppercase; letter-spacing: .05em; }
.ll-process-copy small { display: block; margin-top: 3px; font-size: 9px; color: inherit; opacity: .75; }
.ll-process-item[data-state='current'] {
  color: #fff6e9;
  background: rgba(230, 83, 25, .18);
  border-color: rgba(242, 182, 50, .32);
}
.ll-process-item[data-state='current'] .ll-process-index { background: var(--ll-ember); color: #fff; }
.ll-process-item[data-state='done'] { color: #b9dfc6; }
.ll-process-item[data-state='done'] .ll-process-index { background: var(--ll-moss); color: #fff; }

.ll-purchase .layout-wrapper {
  align-items: start;
  gap: 28px !important;
  width: min(1240px, calc(100% - 28px));
}
.ll-purchase .layout-wrapper > .space-y-12 { display: flex; flex-direction: column; gap: 26px; }
.ll-purchase .layout-wrapper > .space-y-12 > * { margin: 0 !important; }

.ll-guide-board {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 250px;
  min-height: 280px;
  overflow: hidden;
  color: #fff8ee;
  background:
    linear-gradient(112deg, rgba(255,255,255,.03), transparent 42%),
    linear-gradient(135deg, #2c2119, #17130f 68%);
  border: 1px solid rgba(242, 182, 50, .24);
  border-radius: 22px;
  box-shadow: var(--ll-shadow);
}
.ll-guide-board::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: .16;
  pointer-events: none;
  background: repeating-linear-gradient(93deg, transparent 0 58px, rgba(255,255,255,.08) 59px, transparent 60px);
}
.ll-guide-copy { position: relative; z-index: 2; padding: 30px 18px 26px 30px; }
.ll-guide-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 11px;
  color: var(--ll-flame);
  font: 900 10px/1 var(--ll-utility);
  letter-spacing: .14em;
  text-transform: uppercase;
}
.ll-guide-kicker::before { content: ''; width: 23px; height: 3px; background: var(--ll-ember); border-radius: 99px; }
.ll-guide-title { margin: 0 0 10px; color: #fff8ee !important; font: 400 clamp(1.55rem, 3vw, 2.3rem)/1.04 var(--ll-display); letter-spacing: -.045em; }
.ll-guide-message { max-width: 570px; margin: 0; color: #e5d8cc; font-size: 15px; line-height: 1.6; }
.ll-guide-meta { display: flex; align-items: center; gap: 12px; margin-top: 20px; }
.ll-guide-action {
  min-height: 42px;
  padding: 10px 15px;
  color: #fff;
  background: var(--ll-ember);
  border: 0;
  border-radius: 11px;
  font: 800 11px/1 var(--ll-utility);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.ll-guide-capacity { color: #ddcbbb; font: 700 11px/1.3 var(--ll-utility); }
.ll-guide-meter { width: min(330px, 100%); height: 7px; margin-top: 17px; overflow: hidden; background: rgba(255,255,255,.12); border-radius: 99px; }
.ll-guide-meter > span { display: block; width: 0; height: 100%; background: linear-gradient(90deg, var(--ll-ember), var(--ll-flame)); border-radius: inherit; transition: width .4s ease; }
.ll-guide-visual { position: relative; z-index: 1; align-self: end; height: 100%; min-height: 260px; }
.ll-guide-visual::before { content: ''; position: absolute; width: 210px; height: 210px; right: 12px; bottom: 12px; border: 1px solid rgba(242,182,50,.20); border-radius: 50%; }
.ll-guide-image { position: absolute; right: -8px; bottom: -38px; width: 270px; max-height: 330px; object-fit: contain; object-position: bottom center; filter: drop-shadow(0 16px 18px rgba(0,0,0,.36)); transition: opacity .2s ease, transform .25s ease; }
.ll-guide-board[data-tone='error'] { border-color: rgba(180, 35, 24, .55); }
.ll-guide-board[data-tone='error'] .ll-guide-kicker { color: #ffb4aa; }
.ll-guide-board[data-tone='success'] { border-color: rgba(69, 159, 98, .52); }

.ll-purchase .glass-panel {
  overflow: hidden;
  color: var(--ll-ink);
  background: rgba(251, 247, 239, .97) !important;
  border: 1px solid rgba(104, 72, 43, .16) !important;
  border-top: 4px solid var(--ll-oak) !important;
  border-radius: 20px !important;
  box-shadow: 0 14px 38px rgba(23, 14, 8, .14) !important;
}
.ll-purchase .glass-panel h2 {
  font-family: var(--ll-display) !important;
  font-weight: 400 !important;
  letter-spacing: -.035em;
}
.ll-purchase .glass-panel h2 + span,
.ll-purchase .glass-panel h2 ~ span[class*='bg-gray-900'] {
  background: var(--ll-ink) !important;
  color: var(--ll-flame) !important;
}
.ll-purchase .card-interactive,
.ll-purchase #step-2 .bg-white,
.ll-purchase #step-extras .bg-white {
  border-color: rgba(118, 81, 47, .16) !important;
  box-shadow: 0 7px 20px rgba(48, 29, 16, .06) !important;
}
.ll-purchase .card-interactive:hover,
.ll-purchase #step-2 .bg-white:hover {
  border-color: rgba(230, 83, 25, .46) !important;
  transform: translateY(-3px);
}
.ll-purchase .card-interactive.active {
  border-color: var(--ll-ember) !important;
  background: #fff8ed !important;
  box-shadow: 0 0 0 3px rgba(230, 83, 25, .12), 0 13px 28px rgba(48, 29, 16, .11) !important;
}
.ll-purchase .form-input {
  min-height: 52px;
  border: 1px solid rgba(85, 58, 34, .24) !important;
  border-radius: 12px !important;
  background: #fff !important;
}
.ll-field-label { display: block; margin: 0 0 7px; color: #49392d; font: 800 11px/1 var(--ll-utility); text-transform: uppercase; letter-spacing: .05em; }
.ll-purchase #trailer-panel { top: 168px !important; }
.ll-purchase #trailer-panel > div {
  border-color: rgba(242, 182, 50, .20) !important;
  border-radius: 20px !important;
  box-shadow: 0 24px 55px rgba(0, 0, 0, .28) !important;
}
.ll-purchase #trailer-panel > div > div:first-child {
  background: linear-gradient(110deg, #2c2119, #17130f) !important;
  border-bottom: 3px solid var(--ll-ember);
}
.ll-trailer-subtitle { display: block; margin-top: 3px; color: #cfbba8; font-size: 11px; font-weight: 500; }
.ll-purchase .progress-container { height: 11px !important; background: #eadfce !important; }
.ll-purchase .progress-fill { background: linear-gradient(90deg, var(--ll-ember), var(--ll-flame)) !important; }
.ll-purchase #app-toast {
  top: 92px !important;
  background: #211914 !important;
  border: 1px solid rgba(242, 182, 50, .34);
  border-left: 5px solid var(--ll-ember);
  border-radius: 12px !important;
}

.ll-purchase #order-success-screen,
.ll-purchase #order-error-screen { background: rgba(18, 13, 10, .97) !important; }
.ll-purchase #order-success-screen h2,
.ll-purchase #order-error-screen h2 { font-family: var(--ll-display) !important; letter-spacing: -.04em; }

@media (max-width: 1023px) {
  .ll-purchase #trailer-panel { top: auto !important; }
  .ll-purchase #trailer-panel { order: 0 !important; }
  .ll-process-rail { top: 76px; width: calc(100% - 18px); margin-bottom: 18px; }
  .ll-purchase .layout-wrapper { width: calc(100% - 18px); }
}

@media (max-width: 700px) {
  body > header { min-height: 72px; }
  body > header nav { padding-left: 15px !important; padding-right: 15px !important; }
  body > header nav img { height: 50px !important; max-width: 165px; }
  .ll-purchase > .mt-8.mb-12 { padding: 24px 18px 12px !important; margin-top: 14px !important; }
  .ll-purchase > .mt-8.mb-12 h1 { font-size: clamp(2.25rem, 13vw, 3.5rem) !important; }
  .ll-process-rail { top: 72px; padding: 7px; border-radius: 13px; }
  .ll-process-list { grid-template-columns: repeat(6, 115px); min-width: 718px; }
  .ll-process-item { grid-template-columns: 27px 1fr; min-height: 42px; padding: 5px 7px; }
  .ll-process-index { width: 27px; height: 27px; }
  .ll-guide-board { grid-template-columns: 1fr 112px; min-height: 245px; border-radius: 18px; }
  .ll-guide-copy { padding: 23px 0 20px 20px; }
  .ll-guide-title { max-width: 280px; font-size: 1.45rem; }
  .ll-guide-message { max-width: 260px; font-size: 13px; line-height: 1.5; }
  .ll-guide-meta { align-items: flex-start; flex-direction: column; gap: 7px; margin-top: 14px; }
  .ll-guide-action { min-height: 38px; padding: 8px 11px; }
  .ll-guide-visual { min-height: 245px; }
  .ll-guide-visual::before { width: 120px; height: 120px; right: -4px; bottom: 24px; }
  .ll-guide-image { right: -23px; bottom: -12px; width: 175px; max-height: 255px; }
  .ll-purchase .glass-panel { padding: 21px !important; border-radius: 17px !important; }
  .ll-purchase #step-2 .bg-white { align-items: stretch !important; }
  .ll-purchase #step-2 .bg-white > div:first-child { width: 100% !important; height: 150px !important; }
  .ll-purchase #step-checkout .grid-cols-2 { grid-template-columns: 1fr !important; }
  .ll-purchase .mobile-bar { border-top: 3px solid var(--ll-ember); background: rgba(251, 247, 239, .97); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto !important; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  #fire-canvas { display: none !important; }
}

/* ===== ACCESIBILIDAD ===== */

/* Enlace de salto: invisible hasta que se tabula */
.skip-al-contenido {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 10000;
    padding: 0.85rem 1.25rem;
    background: #1f2937;
    color: #fff;
    font-weight: 700;
    text-decoration: none;
    border-radius: 0 0 10px 0;
}
.skip-al-contenido:focus {
    left: 0;
    outline: 3px solid #E65100;
    outline-offset: 2px;
}

/* Foco visible en todo lo interactivo. Se usa :focus-visible para que
   no aparezca al hacer clic con el ratón, solo al navegar con teclado. */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
[tabindex]:not([tabindex="-1"]):focus-visible {
    outline: 3px solid #E65100;
    outline-offset: 3px;
    border-radius: 6px;
}

/* Sobre fondos oscuros, el naranja no contrasta: se usa blanco */
footer a:focus-visible,
header .bg-gray-900 a:focus-visible {
    outline-color: #fff;
}

/* El ancla del skip link no debe dibujar recuadro al recibir el foco
   por programa, solo servir de destino */
#contenido-principal:focus,
#sale-editor:focus {
    outline: none;
}

/* Área mínima táctil de 24x24 en los +/- de cantidad (WCAG 2.2, 2.5.8) */
button[aria-label^="Añadir"],
button[aria-label^="Quitar"] {
    min-width: 32px;
    min-height: 32px;
}
