/* ============================================================
   ALDERA MUEBLES — demo estática para portfolio
   HTML + CSS + JS vanilla. Sin frameworks, sin build.

   Índice
   00 Tipografía · 01 Variables
   02 Reset y base
   03 Utilidades
   04 Header
   05 Hero
   06 Beneficios
   07 Categorías
   08 Productos (S1 y S2)
   09 Bandas full-width
   10 Por qué elegirnos
   11 Testimonios
   12 Newsletter
   13 Footer
   14 Responsive
   ============================================================ */

/* ---------- 00 Tipografía (auto-hospedada: cero pedidos a terceros) ---------- */
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 600; font-display: swap; src: url('../assets/fonts/manrope-600.woff2') format('woff2'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 700; font-display: swap; src: url('../assets/fonts/manrope-700.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap; src: url('../assets/fonts/inter-400.woff2') format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 500; font-display: swap; src: url('../assets/fonts/inter-500.woff2') format('woff2'); }

/* ---------- 01 Variables ---------- */
:root {
  /* Verde y naranja de la referencia; los paneles están muestreados
     de la zona quemada de cada foto, para que el CSS empalme. */
  --verde: #003024;
  --verde-osc: #00231B;
  --verde-claro: #0A4636;
  --naranja: #EA6624;
  --naranja-osc: #CE5316;
  --durazno: #FBE3D2;

  --crema: #F6F6F0;
  --panel-hero: #F9F8F3;
  --panel-promo: #FDF9F3;
  --panel-hojas: #FDFCF7;
  --panel-coleccion: #FEFEFC;
  --panel-novedades: #101B18;

  --tinta: #14211C;
  --gris: #6B7A73;
  --linea: #E6E6DD;
  --linea-osc: rgba(255, 255, 255, .14);
  --blanco: #FFFFFF;

  --ff-head: 'Manrope', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --ff-body: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;

  --gutter: 24px;
  /* Layout a ancho completo: el contenido arranca al 12% del viewport,
     no en el borde de un container de ancho fijo. Todas las secciones y
     los paneles de las bandas usan esta misma línea. */
  --edge: 12%;

  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 20px;

  --sombra: 0 2px 4px rgba(0, 40, 30, .04), 0 10px 26px rgba(0, 40, 30, .07);
  --sombra-alta: 0 22px 54px rgba(0, 30, 22, .16);

  --section-y: clamp(56px, 6.2vw, 96px);
}

/* ---------- 02 Reset y base ---------- */
*, *::before, *::after { box-sizing: border-box; }
body, h1, h2, h3, p, ul, figure, blockquote { margin: 0; }
ul { padding: 0; list-style: none; }

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

body {
  margin: 0; background: var(--crema); color: var(--tinta);
  font-family: var(--ff-body); font-size: 16px; line-height: 1.65;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }

h1, h2, h3 { font-family: var(--ff-head); font-weight: 700; line-height: 1.2; letter-spacing: -.02em; }
:focus-visible { outline: 2px solid var(--naranja); outline-offset: 3px; border-radius: 4px; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -9999px; top: 12px; z-index: 99; background: var(--verde); color: #fff; padding: 10px 18px; border-radius: var(--r-sm); }
.skip-link:focus { left: 12px; }

/* ---------- 03 Utilidades ---------- */
.container { padding-inline: var(--edge); }
.section { padding-block: var(--section-y); }

.section__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: clamp(26px, 3.2vw, 44px); }
.section__title { font-size: clamp(26px, 3vw, 40px); }

.eyebrow {
  display: flex; align-items: center; gap: 9px; margin-bottom: 11px;
  font-family: var(--ff-head); font-size: 11.5px; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase; color: var(--naranja);
}
.eyebrow::before { content: ''; width: 20px; height: 2px; background: var(--naranja); border-radius: 2px; }

/* En la referencia el eyebrow del hero no lleva raya ni mayúsculas */
.eyebrow--hero {
  font-family: var(--ff-body); font-size: 15px; font-weight: 500;
  letter-spacing: 0; text-transform: none; color: var(--gris);
}
.eyebrow--hero::before { display: none; }

.icon { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.icon--md { width: 28px; height: 28px; stroke-width: 1.5; }

.btn {
  display: inline-flex; align-items: center; gap: 9px; flex: none;
  padding: 15px 28px; border-radius: 999px;
  font-family: var(--ff-head); font-size: 15px; font-weight: 700; white-space: nowrap;
  transition: background-color .2s, color .2s, transform .2s, box-shadow .2s;
}
.btn .icon { width: 16px; height: 16px; transition: transform .2s; }
.btn:hover .icon { transform: translateX(3px); }
.btn--verde { background: var(--verde); color: #fff; }
.btn--verde:hover { background: var(--verde-claro); transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0, 48, 36, .28); }
.btn--naranja { background: var(--naranja); color: #fff; }
.btn--naranja:hover { background: var(--naranja-osc); transform: translateY(-2px); box-shadow: 0 10px 24px rgba(234, 102, 36, .32); }

.link-arrow {
  display: inline-flex; align-items: center; gap: 7px; flex: none;
  font-family: var(--ff-head); font-size: 13.5px; font-weight: 600; color: var(--verde);
}
.link-arrow .icon { width: 15px; height: 15px; transition: transform .2s; }
.link-arrow:hover .icon { transform: translateX(4px); }
.link-arrow--claro { color: #fff; }

.grid { display: grid; gap: clamp(16px, 1.8vw, 24px); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

.estrellas { display: inline-flex; gap: 1px; color: #F0A73C; }
.estrellas .icon { width: 14px; height: 14px; }

/* ---------- 04 Header ---------- */
.site-header { background: var(--blanco); border-bottom: 1px solid var(--linea); }
.site-header__inner {
  padding: 16px var(--edge);
  display: flex; align-items: center; gap: clamp(16px, 3vw, 40px);
}
.logo { display: inline-flex; align-items: center; gap: 10px; flex: none; }
.logo__mark { width: 34px; height: 34px; flex: none; color: var(--verde); fill: currentColor; stroke: none; }
.logo__text { display: flex; flex-direction: column; line-height: 1; font-family: var(--ff-head); font-size: 24px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.logo__text small { font-size: 8px; font-weight: 600; letter-spacing: .34em; opacity: .55; margin-top: 5px; }
.logo--claro .logo__mark { color: #fff; }

.nav { display: flex; align-items: center; gap: clamp(14px, 2vw, 32px); margin-inline: auto; }
.nav__link { position: relative; font-size: 15.5px; font-weight: 500; color: var(--gris); padding-block: 4px; transition: color .2s; }
.nav__link:hover, .nav__link.is-active { color: var(--verde); }
.nav__link.is-active::after { content: ''; position: absolute; left: 0; right: 0; bottom: -3px; height: 2px; background: var(--naranja); border-radius: 2px; }

.site-header__actions { display: flex; align-items: center; gap: 6px; flex: none; }
.icon-btn { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; color: var(--verde); transition: background-color .2s; }
.icon-btn:hover { background: var(--crema); }
.icon-btn--cart { position: relative; }
.badge {
  position: absolute; top: 3px; right: 2px;
  min-width: 17px; height: 17px; padding: 0 4px; border-radius: 999px;
  background: var(--naranja); color: #fff;
  font-family: var(--ff-head); font-size: 10px; font-weight: 700; line-height: 17px; text-align: center;
}
.icon-btn--menu { display: none; }
.icon-btn--menu .icon-close { display: none; }

/* ---------- 05 Hero ---------- */
.hero { position: relative; display: grid; grid-template-areas: "media" "panel"; background: var(--panel-hero); }
.hero__media { grid-area: media; display: block; }
.hero__media img { width: 100%; height: auto; }
.hero__body { grid-area: panel; padding: clamp(32px, 5vw, 56px) var(--edge); }
.hero__title { font-size: clamp(36px, 4.7vw, 64px); line-height: 1.07; letter-spacing: -.035em; color: var(--verde); }
.hero__title em { font-style: normal; color: var(--naranja); }
.hero__lead { margin: 20px 0 30px; max-width: 42ch; color: var(--gris); font-size: 17px; line-height: 1.7; }

/* ---------- 06 Beneficios ---------- */
.beneficios { background: var(--blanco); padding-block: clamp(26px, 3vw, 34px); }
.beneficios__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(18px, 2.4vw, 36px); }
.beneficio { display: flex; align-items: center; gap: 14px; padding-left: clamp(18px, 2.4vw, 36px); border-left: 1px solid var(--linea); }
.beneficio:first-child { padding-left: 0; border-left: 0; }
.beneficio .icon { color: var(--verde); }
.beneficio h3 { font-size: 16.5px; }
.beneficio p { font-size: 14px; color: var(--gris); }

/* ---------- 07 Categorías ---------- */
.categorias { background: var(--verde); color: #fff; padding-block: var(--section-y); }
.categorias__inner { display: grid; grid-template-columns: 1fr 1.55fr; gap: clamp(28px, 4vw, 60px); align-items: center; }
.categorias__texto { margin: 16px 0 24px; color: rgba(255, 255, 255, .72); font-size: 15.5px; line-height: 1.7; max-width: 34ch; }
.categorias__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.categoria {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  padding: 22px 10px; border-radius: var(--r-md); background: var(--blanco); color: var(--verde);
  transition: transform .22s, box-shadow .22s;
}
.categoria:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(0, 20, 14, .28); }
.categoria span { font-family: var(--ff-head); font-size: 13.5px; font-weight: 600; text-align: center; }

/* ---------- 08 Productos ---------- */
.productos { background: var(--crema); }
.mas-vendidos { background: var(--blanco); }

.producto {
  position: relative; display: flex; flex-direction: column;
  background: var(--blanco); border: 1px solid var(--linea); border-radius: var(--r-md); overflow: hidden;
  transition: transform .25s, box-shadow .25s;
}
.mas-vendidos .producto { background: var(--crema); }
.producto:hover { transform: translateY(-4px); box-shadow: var(--sombra); }
.producto__media { display: block; overflow: hidden; }
.producto__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: transform .4s; }
.producto__media:hover img { transform: scale(1.05); }
.producto__body { padding: 14px 16px 18px; }
.producto__body h3 { font-size: 15px; font-weight: 600; line-height: 1.4; }
.producto__body h3 a { transition: color .2s; }
.producto__body h3 a:hover { color: var(--naranja); }
.precio { margin-top: 7px; font-family: var(--ff-head); font-size: 20px; font-weight: 700; color: var(--verde); }
.puntaje { display: flex; align-items: center; gap: 6px; margin-top: 4px; }
.puntaje small { font-size: 12.5px; color: var(--gris); }
.agregar {
  position: absolute; right: 14px; bottom: 14px;
  display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%;
  background: var(--verde); color: #fff; transition: background-color .2s, transform .2s;
}
.agregar:hover { background: var(--naranja); transform: scale(1.08); }
.agregar .icon { width: 17px; height: 17px; }

/* ---------- 09 Bandas full-width ----------
   Grid de 2 filas en mobile/tablet (imagen › texto).
   En desktop colapsan a una celda y el texto se apoya sobre el
   panel que ya viene quemado en cada foto.                        */
.banda { display: grid; grid-template-areas: "media" "panel"; background: var(--banda-bg); }
.banda--promo { --banda-bg: var(--panel-promo); }
.banda--coleccion { --banda-bg: var(--panel-coleccion); }
.banda--novedades { --banda-bg: var(--panel-novedades); color: #fff; }

.banda__media { grid-area: media; position: relative; display: block; }
.banda__media img { width: 100%; height: auto; }
.banda__panel { grid-area: panel; padding: clamp(32px, 5vw, 52px) var(--edge); }
.banda__title { font-size: clamp(26px, 2.8vw, 40px); line-height: 1.14; color: var(--verde); }
.banda__text { margin: 16px 0 28px; max-width: 42ch; color: var(--gris); font-size: 16px; line-height: 1.7; }
.banda--novedades .banda__title { color: #fff; }
.banda--novedades .banda__text { color: rgba(255, 255, 255, .74); }

.checklist { display: grid; gap: 10px; margin-bottom: 26px; }
.checklist li { display: flex; align-items: center; gap: 10px; font-size: 15.5px; font-weight: 500; }
.checklist .icon { width: 19px; height: 19px; color: var(--verde); }

/* ---------- 10 Por qué elegirnos ---------- */
.porque { position: relative; isolation: isolate; background: var(--panel-hojas); padding-block: var(--section-y); }
.porque__fondo { position: absolute; inset: 0; z-index: -1; display: block; }
.porque__fondo img { width: 100%; height: 100%; object-fit: cover; }
.porque__inner { text-align: center; }
.porque__title { margin-bottom: clamp(28px, 3.4vw, 46px); }
.porque__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(18px, 2.4vw, 34px); }
.valor { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.valor__icono { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--durazno); color: var(--naranja-osc); }
.valor h3 { font-size: 15.5px; font-weight: 600; line-height: 1.45; color: var(--verde); }

/* ---------- 11 Testimonios ---------- */
.testimonios { background: var(--crema); }
.resena { padding: 22px 24px; background: var(--blanco); border: 1px solid var(--linea); border-radius: var(--r-md); }
.resena figcaption { display: flex; align-items: center; gap: 12px; }
.resena__quien { display: flex; flex-direction: column; line-height: 1.35; }
.resena__quien strong { font-family: var(--ff-head); font-size: 14.5px; font-weight: 600; }
.resena__quien small { font-size: 12px; color: var(--gris); }
.avatar { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 50%; background: var(--verde); color: #fff; font-family: var(--ff-head); font-size: 14px; font-weight: 700; }
.resena .estrellas { margin: 14px 0 10px; }
.resena blockquote { font-size: 15px; line-height: 1.75; color: var(--gris); }

/* ---------- 12 Newsletter ---------- */
.newsletter { background: var(--verde); color: #fff; padding-block: clamp(34px, 4vw, 48px); }
.newsletter__inner { display: flex; align-items: center; justify-content: space-between; gap: 28px; flex-wrap: wrap; }
.newsletter__texto { display: flex; align-items: center; gap: 16px; }
.newsletter__texto .icon { color: var(--naranja); }
.newsletter__texto h2 { font-size: clamp(19px, 2vw, 25px); }
.newsletter__texto p { margin-top: 4px; color: rgba(255, 255, 255, .7); font-size: 14px; }
.newsletter__form { display: flex; gap: 8px; flex: 1; min-width: 280px; max-width: 460px; }
.newsletter input {
  flex: 1 1 0; min-width: 0; width: 100%; padding: 13px 18px; border: 0; border-radius: 999px;
  background: var(--blanco); color: var(--tinta); font-size: 14px;
}
.newsletter input::placeholder { color: #9AA8A0; }

/* ---------- 13 Footer ---------- */
.site-footer { background: var(--verde-osc); color: #fff; padding-block: clamp(46px, 5.5vw, 70px) 24px; }
.site-footer__cols { display: grid; grid-template-columns: 1.5fr 1fr 1.2fr 1.2fr; gap: 34px 30px; padding-bottom: clamp(30px, 4vw, 44px); }
.site-footer__marca p { margin: 16px 0 20px; color: rgba(255, 255, 255, .6); font-size: 14px; }
.site-footer h3 { margin-bottom: 18px; font-size: 15px; }
.site-footer__cols a { color: rgba(255, 255, 255, .62); font-size: 14px; transition: color .2s; }
.site-footer__cols a:hover { color: var(--naranja); }
.site-footer__cols nav li + li { margin-top: 10px; }

.redes { display: flex; gap: 10px; }
.redes a { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: rgba(255, 255, 255, .08); color: #fff; transition: background-color .2s; }
.redes a:hover { background: var(--naranja); }
.redes .icon { width: 16px; height: 16px; }

.contacto-lista li { display: flex; gap: 10px; color: rgba(255, 255, 255, .62); font-size: 14px; }
.contacto-lista li + li { margin-top: 10px; }
.contacto-lista .icon { width: 17px; height: 17px; margin-top: 4px; color: var(--naranja); }

.site-footer__pie {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px;
  padding-top: 22px; border-top: 1px solid var(--linea-osc);
  font-size: 12.5px; color: rgba(255, 255, 255, .5);
}
.pagos { display: flex; gap: 8px; }
.pagos li { display: grid; place-items: center; width: 40px; height: 26px; border-radius: 5px; background: rgba(255, 255, 255, .1); color: rgba(255, 255, 255, .8); }
.pagos .icon { width: 17px; height: 17px; }

/* ============================================================
   14 RESPONSIVE
   ============================================================ */

/* --- Desktop: el texto se apoya sobre el panel quemado en la foto --- */
@media (min-width: 1200px) {
  .hero, .banda { grid-template-areas: "media"; }
  .hero__body, .banda__panel { grid-area: media; place-self: center start; z-index: 2; }

  /* El ancho de cada panel está topeado por hasta dónde llega el panel
     quemado en su propia foto (medido: hero 37%, colección 50%,
     novedades 47%, promo desde el 45% hacia la derecha). */
  .hero__body { width: 47%; padding: 0 0 0 var(--edge); }
  .banda--promo .banda__panel { place-self: center end; width: 34%; padding: 0 var(--edge) 0 0; }
  .banda--coleccion .banda__panel { width: 46%; padding: 0 0 0 var(--edge); }
  .banda--novedades .banda__panel { width: 44%; padding: 0 0 0 var(--edge); }
}

/* --- Tablet --- */
@media (max-width: 1080px) {
  .grid--4 { grid-template-columns: repeat(3, 1fr); }
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .categorias__inner { grid-template-columns: 1fr; }
  .categorias__grid { grid-template-columns: repeat(4, 1fr); }
  .site-footer__cols { grid-template-columns: 1fr 1fr; }
  .site-footer__marca { grid-column: span 2; }
}

/* --- Menú mobile --- */
@media (max-width: 900px) {
  .icon-btn--menu { display: grid; }
  .site-header { position: relative; }
  .nav {
    position: absolute; top: 100%; left: 0; right: 0; z-index: 20;
    flex-direction: column; align-items: stretch; gap: 0; margin: 0;
    padding: 8px; background: var(--blanco); border-bottom: 1px solid var(--linea);
    box-shadow: var(--sombra);
    opacity: 0; visibility: hidden; transform: translateY(-8px);
    transition: opacity .22s, transform .22s, visibility .22s;
  }
  .nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .nav__link { padding: 13px 16px; border-radius: var(--r-sm); font-size: 15px; }
  .nav__link:hover { background: var(--crema); }
  .nav__link.is-active::after { display: none; }
  .nav__link.is-active { background: rgba(234, 102, 36, .1); color: var(--naranja-osc); }
  .icon-btn[aria-expanded="true"] .icon-open { display: none; }
  .icon-btn[aria-expanded="true"] .icon-close { display: block; }
}

/* --- Mobile --- */
@media (max-width: 560px) {
  /* Con el logo agrandado, logo + 4 botones no entran en pantallas chicas */
  .logo__mark { width: 28px; height: 28px; }
  .logo__text { font-size: 20px; }
  .site-header__actions .icon-btn { width: 36px; height: 36px; }
  .site-header__actions { gap: 2px; }
}

@media (max-width: 767px) {
  :root { --gutter: 16px; --edge: 16px; }

  .hero__media img, .banda__media img { aspect-ratio: 4 / 5; object-fit: cover; }
  .hero__lead { font-size: 14.5px; }

  .beneficios__grid { grid-template-columns: 1fr; gap: 0; }
  .beneficio { padding: 14px 0; border-left: 0; border-top: 1px solid var(--linea); }
  .beneficio:first-child { border-top: 0; }

  .section__head { flex-direction: column; align-items: flex-start; gap: 14px; }

  /* En e-commerce 2 columnas en mobile es lo esperable: con 1 sola,
     12 productos harían la página interminable. */
  .grid--4, .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .categorias__grid { grid-template-columns: repeat(2, 1fr); }
  .producto__body { padding: 12px 12px 16px; }
  .producto__body h3 { font-size: 13.5px; }
  .precio { font-size: 15.5px; }
  .agregar { right: 10px; bottom: 10px; width: 32px; height: 32px; }

  .porque__grid { grid-template-columns: repeat(2, 1fr); gap: 26px 14px; }
  .valor__icono { width: 56px; height: 56px; }

  .testimonios .grid--3 { grid-template-columns: 1fr; }

  .newsletter__inner { display: block; }
  .newsletter__form { max-width: none; min-width: 0; margin-top: 20px; }

  .site-footer__cols { grid-template-columns: 1fr; gap: 28px; }
  .site-footer__marca { grid-column: auto; }
  .site-footer__pie { flex-direction: column; align-items: flex-start; }
}
