/* =========================================================
   ESTILOS — Katty Vilela (Horneados en Casa)
   Diseño boutique de repostería de alta densidad (sin espacios desperdiciados)
   Paleta: Crema #F6EFE6 | Marfil #FFFDF9 | Chocolate #3B2219
           Canela #9A4B32 | Cacao #6E4736 | Divisor #C8A287 | Red Velvet #7D2027
   ========================================================= */

:root {
  --bg-cream: #F6EFE6;
  --bg-cream-deep: #ECE0D0;
  --surface-ivory: #FFFDF9;
  --ink-chocolate: #3B2219;
  --ink-cacao: #6E4736;
  --accent-canela: #9A4B32;
  --accent-canela-dark: #7E3A24;
  --accent-velvet: #7D2027;
  --accent-velvet-soft: #F7E8EA;
  --divider: #C8A287;
  --divider-soft: rgba(200, 162, 135, 0.34);
  --wa-green: #1F7A4C;
  --wa-green-dark: #17613B;

  --status-pendiente-bg: #FBF1DF;
  --status-pendiente-fg: #8C5319;
  --status-confirmado-bg: #E6F2EC;
  --status-confirmado-fg: #1F6B46;
  --status-horneado-bg: #F5E6DF;
  --status-horneado-fg: #9A4B32;
  --status-entregado-bg: #ECE7E1;
  --status-entregado-fg: #5D4A40;
  --status-cancelado-bg: #F7E8EA;
  --status-cancelado-fg: #7D2027;

  --font-serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 999px;

  --shadow-card: 0 1px 4px rgba(59, 34, 25, 0.05);
  --shadow-hover: 0 8px 22px rgba(59, 34, 25, 0.1);
  --shadow-drawer: -10px 0 36px rgba(59, 34, 25, 0.18);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background-color: var(--bg-cream);
  color: var(--ink-chocolate);
  font-family: var(--font-sans);
  font-size: 14.5px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

img {
  display: block;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

[hidden] {
  display: none !important;
}

.tabular-nums {
  font-variant-numeric: tabular-nums;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* =========================================================
   CONTENEDOR AMPLIO (Estilo Boutique / Sienna Bakery)
   ========================================================= */
.container {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 14px;
}

@media (min-width: 640px) {
  .container {
    padding: 0 24px;
  }
}

@media (min-width: 1024px) {
  .container {
    padding: 0 32px;
  }
}

/* =========================================================
   BARRA DE ANUNCIO SUPERIOR
   ========================================================= */
.announcement-bar {
  background: var(--ink-chocolate);
  color: var(--bg-cream);
  font-size: 12px;
  font-weight: 500;
  text-align: center;
  padding: 7px 14px;
  letter-spacing: 0.01em;
}

.announcement-bar a {
  color: #F2D3B8;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* =========================================================
   CABECERA COMPACTA STICKY (Sin desperdiciar espacio)
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 253, 249, 0.96);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--divider-soft);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  height: 70px;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.brand-logo-img {
  height: 44px;
  width: auto;
  display: block;
}

.header-tagline {
  display: none;
  margin: 0;
  font-family: var(--font-serif);
  font-variation-settings: "SOFT" 100, "opsz" 24;
  font-style: italic;
  font-weight: 400;
  font-size: clamp(19px, 1.45vw, 23px);
  line-height: 1.15;
  color: var(--ink-chocolate);
  opacity: 0.88;
  letter-spacing: 0.005em;
  text-align: center;
}

@media (min-width: 860px) {
  .header-tagline {
    display: block;
  }
}

/* Celular / tablet: la frase va debajo del logo, en una segunda línea discreta */
@media (max-width: 859px) {
  .site-header .header-inner {
    flex-wrap: wrap;
    height: auto;
    padding: 10px 0 9px;
    row-gap: 3px;
  }

  .site-header .header-tagline {
    display: block;
    order: 3;
    flex: 1 0 100%;
    font-size: 15px;
    text-align: left;
    padding-left: 2px;
  }
}

@media (min-width: 640px) {
  .header-inner {
    height: 76px;
  }

  .brand-logo-img {
    height: 52px;
  }
}

.brand-mark {
  width: 44px;
  height: 30px;
  flex: 0 0 auto;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.brand-name {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 700;
  color: var(--ink-chocolate);
  letter-spacing: 0.01em;
}

.brand-sub {
  font-family: var(--font-serif);
  font-size: 13px;
  font-style: italic;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--ink-cacao);
}

.header-nav {
  display: none;
  align-items: center;
  gap: 20px;
}

@media (min-width: 900px) {
  .header-nav {
    display: flex;
  }
}

.header-nav a {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-cacao);
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.header-nav a:hover,
.header-nav a.is-active {
  color: var(--accent-canela);
  border-bottom-color: var(--accent-canela);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cart-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--divider);
  background: var(--bg-cream);
  color: var(--ink-chocolate);
  font-size: 13px;
  font-weight: 600;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.cart-trigger:hover {
  border-color: var(--accent-canela);
  background: var(--surface-ivory);
}

.cart-trigger.has-items {
  background: var(--accent-canela);
  border-color: var(--accent-canela);
  color: var(--surface-ivory);
}

.cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: var(--radius-pill);
  background: var(--surface-ivory);
  color: var(--ink-chocolate);
  font-size: 11.5px;
  font-weight: 700;
}

/* =========================================================
   TARJETAS DE CATEGORÍAS DIRECTAS AL INICIO (SIN HERO GIGANTE)
   ========================================================= */
.page-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.home-page {
  height: 100dvh;
  min-height: 100dvh;
  overflow: hidden;
}

.home-page .site-header {
  flex: 0 0 auto;
}

.site-header .container {
  max-width: none;
  padding: 0 18px;
}

@media (min-width: 860px) {
  .site-header .container {
    padding: 0 28px;
  }

  .header-inner {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
  }

  .brand-link {
    justify-self: start;
  }

  .header-tagline {
    justify-self: center;
  }

  .header-actions {
    justify-self: end;
  }
}

.home-page .site-footer {
  flex: 0 0 auto;
  padding: 12px 0;
}

.home-main-full {
  flex: 1 1 0;
  min-height: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  background: var(--bg-cream);
}

/* En monitor ancho: 4 columnas a alto completo; en ventana cuadrada o móvil: 2x2 */
@media (min-width: 1080px) and (min-aspect-ratio: 4/3) {
  .home-page .category-cards-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    grid-template-rows: 1fr;
  }
}

.header-notice {
  display: none;
  font-size: 12.5px;
  color: var(--ink-cacao);
  font-weight: 500;
}

@media (min-width: 640px) {
  .header-notice {
    display: inline;
  }
}

.home-intro-strip {
  padding: 12px 0 10px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.home-tagline {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(22px, 2.8vw, 30px);
  font-weight: 700;
  font-style: italic;
  color: var(--ink-chocolate);
  line-height: 1.15;
}

.category-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  width: 100%;
  height: 100%;
  gap: 4px;
  padding: 0;
  background: var(--bg-cream);
}

.cat-card {
  position: relative;
  display: block;
  min-width: 0;
  min-height: 0;
  width: 100%;
  height: 100%;
  border-radius: 0;
  overflow: hidden;
  background: var(--ink-chocolate);
  border: 0;
}

.cat-card-media {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--ink-chocolate);
}

.cat-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  transition: transform 0.35s ease;
}

.cat-card:hover .cat-card-media img {
  transform: scale(1.03);
}

/* Sombra muy corta solo en el borde inferior para que el texto sea legible sin lavar la foto */
.cat-card-media::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 38%;
  background: linear-gradient(180deg, rgba(36, 18, 12, 0) 0%, rgba(36, 18, 12, 0.72) 100%);
  pointer-events: none;
}

.cat-card-content {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  padding: 18px 20px;
  color: var(--surface-ivory);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.cat-card-title {
  margin: 0;
  font-family: var(--font-serif);
  font-variation-settings: "SOFT" 100, "opsz" 36;
  font-size: clamp(24px, 2.5vw, 34px);
  font-weight: 600;
  line-height: 1.08;
  color: var(--surface-ivory);
  text-shadow: 0 2px 10px rgba(24, 10, 5, 0.55);
}

.cat-card-arrow {
  flex: 0 0 auto;
  font-size: 22px;
  color: var(--surface-ivory);
  opacity: 0.9;
  transition: transform 0.18s ease;
}

.cat-card:hover .cat-card-arrow {
  transform: translateX(4px);
}

.cat-card-empty {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, #4B2D22 0%, #341D15 100%);
  color: rgba(255, 253, 249, 0.65);
  font-size: 13px;
  letter-spacing: 0.04em;
}

/* =========================================================
   SECCIONES Y GRILLA DENSA DE PRODUCTOS (2 col móvil, 4 col desktop)
   ========================================================= */
.catalog-main {
  padding-bottom: 72px;
}

.category-section {
  scroll-margin-top: 76px;
  margin-bottom: 30px;
}

.section-bar {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 8px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--divider-soft);
}

.section-bar-left {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}

.section-title {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 700;
  color: var(--ink-chocolate);
  line-height: 1.1;
}

.section-sub {
  font-size: 12.5px;
  color: var(--ink-cacao);
}

.section-price {
  flex: 0 0 auto;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-canela);
  background: var(--surface-ivory);
  border: 1px solid var(--divider-soft);
  padding: 3px 10px;
  border-radius: var(--radius-pill);
}

.category-section--velvet .section-price {
  color: var(--accent-velvet);
  border-color: rgba(125, 32, 39, 0.3);
}

.category-page-title {
  margin: 0 0 18px;
  font-family: var(--font-serif);
  font-variation-settings: "SOFT" 100;
  font-size: clamp(26px, 3vw, 34px);
  font-weight: 600;
  line-height: 1.12;
  color: var(--ink-chocolate);
  letter-spacing: -0.01em;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  column-gap: 12px;
  row-gap: 28px;
}

@media (min-width: 680px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    column-gap: 18px;
    row-gap: 36px;
  }
}

@media (min-width: 1024px) {
  .product-grid {
    grid-template-columns: repeat(4, 1fr);
    column-gap: 20px;
    row-gap: 38px;
  }
}

@media (min-width: 1240px) {
  .product-grid--dense {
    grid-template-columns: repeat(5, 1fr);
    gap: 14px;
  }
}

/* Tarjeta editorial limpia: foto 100% libre arriba + texto directo sobre fondo crema (sin caja blanca) */
.product-card {
  display: flex;
  flex-direction: column;
  background: transparent;
  border: none;
  border-radius: 0;
  overflow: visible;
  box-shadow: none;
  transition: transform 0.2s ease;
}

.product-card:hover {
  transform: translateY(-2px);
}

.product-thumb-link {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 6px;
  background: var(--bg-cream-deep);
  overflow: hidden;
  transition: box-shadow 0.2s ease;
}

.product-thumb-link img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.35s ease, opacity 0.25s ease;
}

.product-thumb-link .img-hover {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.product-card:hover .product-thumb-link .img-hover {
  opacity: 1;
}

.product-card:hover .product-thumb-link .img-main {
  transform: scale(1.03);
}

.thumb-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 16px;
  text-align: center;
  background: linear-gradient(145deg, #F3E8DA 0%, #E7D6C1 100%);
  color: var(--ink-cacao);
}

.thumb-placeholder-name {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 700;
  color: var(--ink-chocolate);
}

.thumb-placeholder-tag {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-canela);
}

.thumb-badge {
  position: absolute;
  left: 8px;
  top: 8px;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  background: var(--accent-velvet);
  color: var(--surface-ivory);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.product-info {
  padding: 11px 2px 4px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
}

@media (min-width: 640px) {
  .product-info {
    padding: 12px 2px 6px;
  }
}

.product-name-link {
  font-family: var(--font-serif);
  font-variation-settings: "SOFT" 100;
  font-size: 19px;
  font-weight: 600;
  line-height: 1.18;
  color: var(--ink-chocolate);
}

.product-name-link:hover {
  color: var(--accent-canela);
}

.product-price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.product-card-desc {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.42;
  color: var(--ink-cacao);
  flex: 1;
}

.product-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 6px;
  padding-top: 0;
  border-top: none;
}

.product-card .product-cta-compact .btn-add {
  width: auto;
  padding: 6px 13px;
  font-size: 12px;
  background: var(--surface-ivory);
  border-color: var(--divider);
  color: var(--ink-chocolate);
}

.product-card .product-cta-compact .btn-add:hover {
  background: var(--accent-canela);
  border-color: var(--accent-canela);
  color: #FFF9F2;
}

.product-card--velvet .product-cta-compact .btn-add:hover {
  background: var(--accent-velvet);
  border-color: var(--accent-velvet);
  color: #FFF9F2;
}

.product-card .product-cta-compact .stepper {
  width: auto;
  gap: 6px;
  padding: 2px;
  background: var(--surface-ivory);
}

.product-cta-compact .stepper-btn {
  width: 24px;
  height: 24px;
  font-size: 15px;
}

.product-cta-compact .stepper-qty {
  min-width: 18px;
  font-size: 12.5px;
}

.product-price {
  font-size: 15px;
  font-weight: 700;
  color: var(--accent-canela);
}

.product-card--velvet .product-price {
  color: var(--accent-velvet);
}

.product-ver-link {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--ink-cacao);
}

.product-ver-link:hover {
  color: var(--accent-canela);
  text-decoration: underline;
}

.product-cta {
  margin-top: auto;
  padding-top: 4px;
}

/* =========================================================
   SUBPÁGINA DE PRODUCTO (PDP — 2 columnas compactas)
   ========================================================= */
.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 14px 0 12px;
  font-size: 12.5px;
  color: var(--ink-cacao);
}

.breadcrumb a:hover {
  color: var(--accent-canela);
  text-decoration: underline;
}

.pdp-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  background: var(--surface-ivory);
  border: 1px solid var(--divider-soft);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow-card);
}

@media (min-width: 768px) {
  .pdp-grid {
    grid-template-columns: 5fr 6fr;
    gap: 32px;
    padding: 26px;
    align-items: start;
  }
}

.pdp-gallery {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pdp-main-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  max-height: 520px;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-cream-deep);
}

.pdp-main-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.pdp-thumbs {
  display: flex;
  gap: 8px;
}

.pdp-thumb {
  width: 68px;
  height: 68px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 2px solid transparent;
  padding: 0;
  background: var(--bg-cream-deep);
}

.pdp-thumb.is-active {
  border-color: var(--accent-canela);
}

.pdp-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pdp-details {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.pdp-eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-canela);
}

.pdp-title {
  margin: 2px 0 0;
  font-family: var(--font-serif);
  font-variation-settings: "SOFT" 100, "opsz" 48;
  font-size: clamp(28px, 4vw, 38px);
  font-weight: 600;
  line-height: 1.08;
  color: var(--ink-chocolate);
}

.pdp-price {
  font-size: 24px;
  font-weight: 700;
  color: var(--accent-canela);
}

.pdp-desc {
  margin: 0;
  font-size: 15px;
  color: var(--ink-cacao);
  line-height: 1.55;
}

.pdp-bullets {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 13.5px;
  color: var(--ink-chocolate);
}

.pdp-bullets li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pdp-bullets li::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-canela);
  flex: 0 0 auto;
}

.pdp-notice {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--bg-cream);
  border: 1px solid var(--divider-soft);
  font-size: 12.5px;
  color: var(--ink-cacao);
}

.pdp-buy-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.pdp-qty-box {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--divider);
  border-radius: var(--radius-pill);
  background: var(--bg-cream);
  padding: 3px;
}

.pdp-qty-box button {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 0;
  background: var(--surface-ivory);
  font-size: 18px;
  font-weight: 700;
}

.pdp-qty-box span {
  min-width: 32px;
  text-align: center;
  font-weight: 700;
}

.related-section {
  margin-top: 32px;
  padding-bottom: 56px;
}

/* =========================================================
   BOTONES Y STEPPER COMPACTO
   ========================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  padding: 10px 18px;
  font-weight: 600;
  font-size: 13.5px;
  line-height: 1.2;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.1s ease;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--accent-canela);
  color: var(--surface-ivory);
}

.btn-primary:hover {
  background: var(--accent-canela-dark);
}

.btn-wa {
  background: var(--wa-green);
  color: #FFFFFF;
}

.btn-wa:hover {
  background: var(--wa-green-dark);
}

.btn-outline {
  background: var(--surface-ivory);
  border-color: var(--divider);
  color: var(--ink-chocolate);
}

.btn-outline:hover {
  border-color: var(--accent-canela);
  color: var(--accent-canela);
}

.btn-ghost {
  background: transparent;
  color: var(--ink-cacao);
  padding: 7px 10px;
}

.btn-ghost:hover {
  background: var(--bg-cream-deep);
  color: var(--ink-chocolate);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12.5px;
}

.btn-block {
  width: 100%;
}

.btn-add {
  width: 100%;
  background: var(--bg-cream);
  border: 1px solid var(--divider);
  color: var(--ink-chocolate);
  padding: 7px 10px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 12.5px;
}

.btn-add:hover {
  background: var(--accent-canela);
  border-color: var(--accent-canela);
  color: var(--surface-ivory);
}

.product-card--velvet .btn-add:hover {
  background: var(--accent-velvet);
  border-color: var(--accent-velvet);
}

.stepper {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: var(--bg-cream);
  border: 1px solid var(--accent-canela);
  border-radius: var(--radius-pill);
  padding: 2px;
}

.product-card--velvet .stepper {
  border-color: var(--accent-velvet);
}

.stepper-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 0;
  background: var(--surface-ivory);
  color: var(--ink-chocolate);
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.stepper-btn--plus {
  background: var(--accent-canela);
  color: var(--surface-ivory);
}

.product-card--velvet .stepper-btn--plus {
  background: var(--accent-velvet);
}

.stepper-qty {
  font-weight: 700;
  font-size: 13px;
  min-width: 24px;
  text-align: center;
}

/* =========================================================
   DRAWER LATERAL DE CARRITO Y CHECKOUT (Compartido en toda la web)
   ========================================================= */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(59, 34, 25, 0.52);
  backdrop-filter: blur(3px);
  display: none;
  justify-content: flex-end;
}

.drawer-backdrop.is-open {
  display: flex;
}

.drawer-panel {
  width: 100%;
  max-width: 440px;
  height: 100%;
  background: var(--surface-ivory);
  box-shadow: var(--shadow-drawer);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* Modales centrados (pedidos.html) */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(59, 34, 25, 0.54);
  backdrop-filter: blur(3px);
  display: none;
  align-items: flex-end;
  justify-content: center;
}

.modal-backdrop.is-open {
  display: flex;
}

@media (min-width: 640px) {
  .modal-backdrop {
    align-items: center;
    padding: 20px;
  }
}

.modal-sheet {
  width: 100%;
  max-width: 540px;
  max-height: 92vh;
  background: var(--surface-ivory);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--divider-soft);
}

@media (min-width: 640px) {
  .modal-sheet {
    border-radius: var(--radius-lg);
  }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--divider-soft);
  background: var(--bg-cream);
}

.modal-title {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 700;
  color: var(--ink-chocolate);
}

.modal-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--divider-soft);
  background: var(--surface-ivory);
  font-size: 19px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.modal-body {
  padding: 16px 18px 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex: 1;
}

/* =========================================================
   FORMULARIOS Y RESUMEN DE CARRITO
   ========================================================= */
.form-section-title {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-canela);
}

.cart-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 11px 12px;
  border-radius: var(--radius-sm);
  background: var(--bg-cream);
  border: 1px solid var(--divider-soft);
}

.cart-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 13.5px;
}

.cart-line-controls {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.mini-qty-btn {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid var(--divider);
  background: var(--surface-ivory);
  font-weight: 700;
  line-height: 1;
}

.cart-total-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-top: 8px;
  margin-top: 4px;
  border-top: 1px solid var(--divider-soft);
  font-weight: 700;
  font-size: 15.5px;
}

.field-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

@media (min-width: 440px) {
  .field-grid--2 {
    grid-template-columns: 1fr 1fr;
  }
}

.field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.field label {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-chocolate);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 9px 11px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--divider);
  background: var(--surface-ivory);
  color: var(--ink-chocolate);
  font-size: 14px;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent-canela);
  box-shadow: 0 0 0 3px rgba(154, 75, 50, 0.14);
}

.field-hint {
  font-size: 11.5px;
  color: var(--ink-cacao);
}

.field-hint--ok {
  color: #2B6B46;
  font-weight: 600;
}

.field-hint--error {
  color: #B43728;
  font-weight: 600;
}

.allergen-notice {
  background: #FFF6EB;
  border: 1px solid rgba(182, 108, 63, 0.38);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--ink-chocolate);
}

.segmented {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.segmented-option {
  position: relative;
}

.segmented-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.segmented-label {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 9px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--divider);
  background: var(--surface-ivory);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-cacao);
  cursor: pointer;
}

.segmented-option input:checked + .segmented-label {
  background: var(--accent-canela);
  border-color: var(--accent-canela);
  color: var(--surface-ivory);
}

.form-error {
  padding: 9px 11px;
  border-radius: var(--radius-sm);
  background: var(--accent-velvet-soft);
  border: 1px solid rgba(125, 32, 39, 0.3);
  color: var(--accent-velvet);
  font-size: 12.5px;
  font-weight: 500;
}

.confirm-box {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 11px;
}

.confirm-code {
  display: inline-block;
  padding: 7px 18px;
  border-radius: var(--radius-pill);
  background: var(--bg-cream);
  border: 1.5px dashed var(--accent-canela);
  font-family: var(--font-serif);
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--accent-canela);
}

.confirm-summary {
  width: 100%;
  text-align: left;
  background: var(--bg-cream);
  border: 1px solid var(--divider-soft);
  border-radius: var(--radius-sm);
  padding: 11px 13px;
  font-size: 13px;
}

/* =========================================================
   FOOTER COMPACTO
   ========================================================= */
.site-footer {
  border-top: 1px solid var(--divider-soft);
  background: var(--surface-ivory);
  padding: 20px 0 26px;
  font-size: 12.5px;
  color: var(--ink-cacao);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links a {
  color: var(--accent-canela);
  font-weight: 600;
}

.footer-links a:hover {
  text-decoration: underline;
}

/* =========================================================
   AGENDA PRIVADA (pedidos.html)
   ========================================================= */
.pin-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.pin-card {
  width: 100%;
  max-width: 380px;
  background: var(--surface-ivory);
  border: 1px solid var(--divider-soft);
  border-radius: var(--radius-lg);
  padding: 26px 22px;
  text-align: center;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 13px;
}

.pin-card img {
  width: 200px;
  margin: 0 auto;
}

.pin-input {
  text-align: center;
  font-size: 24px !important;
  letter-spacing: 0.35em;
  font-weight: 700;
}

.agenda-topbar {
  background: var(--surface-ivory);
  border-bottom: 1px solid var(--divider-soft);
  padding: 10px 0;
  position: sticky;
  top: 0;
  z-index: 30;
}

.agenda-topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.agenda-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.agenda-logo-img {
  height: 36px;
  width: auto;
  display: block;
}

.agenda-meta {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding-left: 14px;
  border-left: 1px solid var(--divider-soft);
}

.agenda-kicker {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-chocolate);
  line-height: 1.2;
}

.agenda-today {
  font-size: 12px;
  color: var(--ink-cacao);
  line-height: 1.2;
}

.agenda-title {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.1;
}

.sync-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  font-size: 11px;
  font-weight: 600;
  background: var(--bg-cream);
  color: var(--ink-cacao);
}

.sync-badge--cloud {
  background: var(--status-confirmado-bg);
  color: var(--status-confirmado-fg);
}

.sync-badge--local {
  background: var(--status-pendiente-bg);
  color: var(--status-pendiente-fg);
}

.agenda-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tabs-bar {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin: 16px 0 12px;
  scrollbar-width: none;
}

.tabs-bar::-webkit-scrollbar {
  display: none;
}

/* Celular: las 4 pestañas se acomodan en dos filas en vez de cortarse */
@media (max-width: 639px) {
  .tabs-bar {
    flex-wrap: wrap;
    overflow-x: visible;
  }
}

.tab-btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 13px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--divider-soft);
  background: var(--surface-ivory);
  color: var(--ink-cacao);
  font-size: 13px;
  font-weight: 600;
}

.tab-btn.is-active {
  background: var(--ink-chocolate);
  border-color: var(--ink-chocolate);
  color: var(--surface-ivory);
}

.tab-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: var(--radius-pill);
  font-size: 11px;
  font-weight: 700;
  background: var(--bg-cream);
  color: var(--ink-chocolate);
}

.tab-btn.is-active .tab-count {
  background: var(--accent-canela);
  color: var(--surface-ivory);
}

.bake-summary-box {
  background: #FFF9F3;
  border: 1px solid var(--divider);
  border-radius: var(--radius-md);
  padding: 11px 14px;
  margin-bottom: 14px;
}

.bake-summary-title {
  margin: 0 0 6px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-canela);
}

.bake-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.bake-chip {
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--surface-ivory);
  border: 1px solid var(--divider-soft);
  font-size: 12.5px;
  font-weight: 600;
}

.orders-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-bottom: 44px;
}

.order-card {
  background: var(--surface-ivory);
  border: 1px solid var(--divider-soft);
  border-radius: var(--radius-md);
  padding: 14px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.order-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.order-code {
  font-weight: 700;
  font-size: 14.5px;
  color: var(--accent-canela);
}

.order-meta {
  font-size: 12.5px;
  color: var(--ink-cacao);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  font-size: 11.5px;
  font-weight: 700;
}

.status-pill--pendiente { background: var(--status-pendiente-bg); color: var(--status-pendiente-fg); }
.status-pill--confirmado { background: var(--status-confirmado-bg); color: var(--status-confirmado-fg); }
.status-pill--horneado { background: var(--status-horneado-bg); color: var(--status-horneado-fg); }
.status-pill--entregado { background: var(--status-entregado-bg); color: var(--status-entregado-fg); }
.status-pill--cancelado { background: var(--status-cancelado-bg); color: var(--status-cancelado-fg); }

.order-items-box {
  background: var(--bg-cream);
  border-radius: var(--radius-sm);
  padding: 9px 11px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13.5px;
}

.order-customer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13px;
}

.order-notes {
  font-size: 12.5px;
  color: var(--ink-cacao);
  background: #FAF6F0;
  border-left: 3px solid var(--divider);
  padding: 5px 9px;
  border-radius: 0 6px 6px 0;
}

.status-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding-top: 8px;
  border-top: 1px dashed var(--divider-soft);
}

.status-btn {
  padding: 5px 10px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--divider-soft);
  background: var(--surface-ivory);
  color: var(--ink-cacao);
  font-size: 12px;
  font-weight: 600;
}

.status-btn.is-current {
  background: var(--ink-chocolate);
  border-color: var(--ink-chocolate);
  color: var(--surface-ivory);
}

.empty-state {
  text-align: center;
  padding: 36px 18px;
  background: var(--surface-ivory);
  border: 1px dashed var(--divider);
  border-radius: var(--radius-md);
  color: var(--ink-cacao);
}

/* =========================================================
   TOAST
   ========================================================= */
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%) translateY(16px);
  z-index: 80;
  background: var(--ink-chocolate);
  color: var(--surface-ivory);
  padding: 9px 16px;
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 600;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  max-width: 92vw;
  text-align: center;
}

.toast.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
