:root {
  color-scheme: light;
  --bg: #f5f5f5;
  --surface: #ffffff;
  --surface-soft: #f5f5f5;
  --ink: #111111;
  --muted: #666666;
  --line: #dddddd;
  --accent: #ff7b00;
  --accent-strong: #d86400;
  --charcoal: #111111;
  --charcoal-soft: #2b2b2b;
  --amber: #d88b22;
  --blue: #3f657d;
  --done: #617134;
  --shadow: 0 18px 48px rgba(36, 36, 32, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(48, 49, 45, 0.86), rgba(245, 242, 238, 0.96) 420px),
    linear-gradient(90deg, rgba(244, 122, 24, 0.18), rgba(255, 255, 255, 0) 36%),
    url("https://images.unsplash.com/photo-1504917595217-d4dc5ebe6122?auto=format&fit=crop&w=1600&q=70") center/cover fixed;
}

body.admin-page {
  background: #f5f5f5;
}

button,
input,
textarea {
  font: inherit;
}

button {
  touch-action: manipulation;
}

.topbar,
.app-shell {
  width: min(1180px, calc(100% - 28px));
  margin: 0 auto;
}

.topbar {
  min-height: 150px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: #ffffff;
}

.app-shell {
  padding-bottom: 36px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(330px, 0.95fr);
  gap: 18px;
}

.admin-section {
  grid-column: 1 / -1;
}

.catalog-section,
.order-section,
.admin-section {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
  padding: 22px;
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(2.2rem, 6vw, 4.8rem);
  line-height: 0.96;
}

h2 {
  margin-bottom: 0;
  font-size: 1.45rem;
}

h3 {
  margin-bottom: 5px;
  font-size: 1.05rem;
}

.section-heading,
.cart-header,
.order-topline,
.stats-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.brand-lockup {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 18px;
}

.brand-logo {
  width: clamp(120px, 17vw, 180px);
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 999px;
  background: transparent;
  filter: none;
}

.brand-subtitle {
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.84);
  font-weight: 800;
}

.mini-badge,
.order-status {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 8px 12px;
  background: #fff3e8;
  color: var(--accent-strong);
  font-size: 0.85rem;
  font-weight: 800;
  text-decoration: none;
}

.admin-entry {
  width: fit-content;
  cursor: pointer;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 800;
  list-style-position: inside;
}

.admin-entry-link {
  grid-column: 1 / -1;
  width: fit-content;
  margin: 0 auto;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-decoration: none;
}

.admin-layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
}

.admin-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: grid;
  align-content: start;
  gap: 20px;
  padding: 28px;
  background: var(--charcoal);
  color: #ffffff;
}

.admin-logo {
  width: 220px;
  max-width: 100%;
  object-fit: contain;
  filter: none;
}

.admin-sidebar h1 {
  font-size: 2.1rem;
}

.admin-nav {
  display: grid;
  gap: 8px;
}

.admin-nav a {
  border-radius: 6px;
  padding: 11px 12px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  font-weight: 800;
  text-decoration: none;
}

.admin-main {
  min-width: 0;
  padding: 28px;
}

.admin-login-page,
.admin-dashboard {
  max-width: 1180px;
}

.admin-login-page {
  display: grid;
  gap: 16px;
  width: min(520px, 100%);
  margin: 80px auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 24px;
  box-shadow: var(--shadow);
}

.admin-login-page.is-hidden,
.admin-dashboard.is-locked {
  display: none;
}

.admin-topline,
.admin-panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.admin-topline {
  margin-bottom: 18px;
}

.admin-status {
  margin: 0 0 18px;
  border: 1px solid rgba(244, 122, 24, 0.28);
  border-radius: 8px;
  background: #fff3e8;
  color: var(--accent-strong);
  padding: 12px 14px;
  font-weight: 900;
}

.admin-topline h2 {
  font-size: 2rem;
}

.admin-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow);
  padding: 20px;
  margin-bottom: 18px;
}

.admin-panel h3 {
  font-size: 1.35rem;
}

.admin-stats {
  align-items: stretch;
}

.admin-table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.admin-table {
  width: 100%;
  min-width: 900px;
  border-collapse: collapse;
  background: #ffffff;
}

.admin-table th,
.admin-table td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.admin-table th {
  color: var(--muted);
  background: var(--surface-soft);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.admin-table small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.35;
}

.admin-table select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px;
  font: inherit;
}

.admin-product-form {
  margin: 16px 0;
  display: grid;
  grid-template-columns: 1.1fr 1.4fr 0.7fr 0.9fr 0.7fr 0.6fr 1fr;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  padding: 14px;
}

.category-admin-form {
  margin: 16px 0;
  display: grid;
  grid-template-columns: minmax(240px, 1fr) auto auto;
  align-items: end;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  padding: 14px;
}

.quick-edit-box {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  align-items: end;
  gap: 12px;
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 14px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 9px;
}

.checkbox-label input {
  width: auto;
}

.compact-btn {
  width: auto;
}

.admin-product-photo,
.admin-product-code {
  width: 52px;
  height: 52px;
  border-radius: 8px;
}

.admin-product-photo {
  object-fit: cover;
}

.admin-product-code {
  display: grid;
  place-items: center;
  background: var(--charcoal);
  color: #ffffff;
  font-weight: 900;
}

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

.admin-section:not([open]) {
  border-color: transparent;
  background: rgba(255, 255, 255, 0.54);
  box-shadow: none;
  padding: 10px 14px;
}

.admin-section[open] .admin-entry {
  margin-bottom: 16px;
  color: var(--accent-strong);
}

.admin-heading {
  margin-bottom: 18px;
}

.product-list {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.category-filter {
  margin-top: 16px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.category-chip {
  flex: 0 0 auto;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #ffffff;
  color: var(--charcoal);
  padding: 0 13px;
  font-weight: 900;
  cursor: pointer;
}

.category-chip.active {
  border-color: var(--accent);
  background: var(--accent);
  color: #ffffff;
}

.search-box {
  margin-top: 14px;
}

.featured-section {
  margin-top: 18px;
}

.featured-section.is-hidden {
  display: none;
}

.featured-section h3 {
  margin-bottom: 10px;
}

.featured-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.product-card {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  padding: 14px;
  cursor: pointer;
}

.product-card:focus-visible {
  outline: 3px solid rgba(255, 123, 0, 0.3);
  outline-offset: 2px;
}

.product-icon {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--charcoal);
  color: #ffffff;
  font-weight: 900;
  font-size: 0.9rem;
  overflow: hidden;
}

.product-icon.has-photo {
  background: #ffffff;
}

.product-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-body {
  min-width: 0;
  display: grid;
  gap: 12px;
}

.product-description,
.order-detail,
.order-time,
.cart-item small {
  color: var(--muted);
  line-height: 1.35;
}

.product-description {
  margin-bottom: 0;
}

.product-meta {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 10px;
}

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

.qty-label {
  max-width: 96px;
  font-size: 0.78rem;
}

label {
  display: grid;
  gap: 7px;
  color: #334139;
  font-size: 0.92rem;
  font-weight: 800;
}

input,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfcfb;
  color: var(--ink);
  padding: 12px 13px;
  outline: none;
}

textarea {
  resize: vertical;
}

input:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(244, 122, 24, 0.18);
}

.primary-btn,
.secondary-btn,
.ghost-btn,
.status-btn,
.link-button,
.whatsapp-fallback {
  min-height: 42px;
  border-radius: 6px;
  padding: 0 14px;
  font-weight: 800;
  cursor: pointer;
}

.primary-btn,
.secondary-btn {
  width: 100%;
  border: 0;
}

.primary-btn {
  background: var(--accent);
  color: #ffffff;
}

.whatsapp-actions {
  display: none;
  grid-template-columns: 1fr;
  gap: 10px;
}

.whatsapp-actions.is-visible {
  display: grid;
}

.whatsapp-actions .ghost-btn {
  width: 100%;
}

.whatsapp-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #1f9d55;
  color: #ffffff;
  text-decoration: none;
}

.whatsapp-fallback.web {
  background: var(--charcoal);
}

.whatsapp-message-preview {
  display: none;
  min-height: 138px;
  font-size: 0.9rem;
  line-height: 1.4;
}

.whatsapp-message-preview.is-visible {
  display: block;
}

.product-detail-sheet {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: none;
  align-items: end;
  justify-content: center;
}

.product-detail-sheet.is-visible {
  display: flex;
}

.product-detail-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 17, 17, 0.52);
}

.product-detail-card {
  position: relative;
  z-index: 1;
  width: min(100%, 520px);
  max-height: 88vh;
  overflow-y: auto;
  border-radius: 16px 16px 0 0;
  background: #ffffff;
  box-shadow: 0 -18px 50px rgba(17, 17, 17, 0.28);
}

.product-detail-close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 999px;
  background: rgba(17, 17, 17, 0.84);
  color: #ffffff;
  font-weight: 900;
}

.product-detail-media {
  height: 210px;
  display: grid;
  place-items: center;
  background: var(--charcoal);
  color: #ffffff;
  font-size: 1.8rem;
  font-weight: 900;
  overflow: hidden;
}

.product-detail-media.has-photo {
  background: #ffffff;
}

.product-detail-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-detail-body {
  display: grid;
  gap: 12px;
  padding: 18px;
}

.product-detail-body h3 {
  margin: 0;
  font-size: 1.45rem;
}

.product-detail-body p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.detail-pill {
  width: fit-content;
  border-radius: 999px;
  background: #fff0e2;
  color: var(--accent-strong);
  padding: 7px 10px;
  font-size: 0.8rem;
  font-weight: 900;
}

.detail-actions {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 10px;
  align-items: end;
}

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

.secondary-btn {
  background: #fff0e2;
  color: var(--accent-strong);
}

.ghost-btn,
.status-btn,
.link-button {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--charcoal);
}

.link-button {
  min-height: 34px;
}

.cart-box {
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  padding: 14px;
}

.cart-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.cart-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 78px;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: 6px;
  background: var(--surface);
}

.cart-item strong,
.cart-item small {
  display: block;
}

.total-row {
  margin: 14px 0 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.order-form {
  margin-top: 18px;
  display: grid;
  gap: 14px;
}

.location-tools {
  display: grid;
  gap: 8px;
}

.location-status {
  min-height: 20px;
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
  line-height: 1.35;
}

.location-status.is-ok {
  color: var(--done);
}

.location-status.is-error {
  color: var(--accent-strong);
}

.address-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 112px;
  gap: 10px;
}

.form-message {
  min-height: 22px;
  margin: 0;
  color: var(--accent-strong);
  font-weight: 800;
}

.stats-row {
  margin: 18px 0;
}

.product-admin {
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  padding: 14px;
}

.admin-login {
  margin-top: 18px;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  align-items: end;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  padding: 14px;
}

.admin-login .primary-btn {
  width: auto;
}

.admin-login.is-hidden,
.admin-content.is-locked {
  display: none;
}

.admin-session-row {
  margin-top: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 12px;
}

.admin-session-row span {
  color: var(--accent-strong);
  font-weight: 900;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.product-admin summary {
  cursor: pointer;
  color: var(--charcoal);
  font-size: 1.05rem;
  font-weight: 900;
}

.product-form {
  margin-top: 14px;
  display: grid;
  grid-template-columns: 1.2fr 1.6fr 0.8fr 0.8fr 0.7fr 1fr;
  gap: 12px;
}

.photo-preview-box {
  grid-column: 1 / -1;
  display: none;
  align-items: center;
  gap: 12px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 10px;
}

.photo-preview-box.is-visible {
  display: flex;
}

.photo-preview-box span {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
}

#product-photo-preview {
  display: none;
  width: 72px;
  height: 72px;
  border-radius: 8px;
  object-fit: cover;
}

#product-photo-preview.is-visible {
  display: block;
}

#remove-product-photo {
  display: none;
}

#remove-product-photo.is-visible {
  display: inline-block;
}

.product-form-actions {
  grid-column: 1 / -1;
  display: flex;
  gap: 10px;
}

.product-form-actions .primary-btn,
.product-form-actions .ghost-btn {
  width: auto;
}

#cancel-product-edit {
  display: none;
}

#cancel-product-edit.is-visible,
#cancel-category-edit.is-visible {
  display: inline-block;
}

#cancel-category-edit {
  display: none;
}

.product-admin-list {
  margin-top: 14px;
  display: grid;
  gap: 10px;
}

.product-admin-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 12px;
}

.product-admin-row strong,
.product-admin-row small {
  display: block;
}

.product-admin-row small {
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.35;
}

.product-admin-actions {
  flex: 0 0 auto;
  display: flex;
  gap: 8px;
}

.status-btn.danger {
  color: #9d2f1f;
}

.stats-row > div {
  flex: 1;
  min-width: 0;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}

.stats-row span {
  display: block;
  font-size: 1.5rem;
  font-weight: 900;
}

.stats-row small {
  color: var(--muted);
  font-weight: 800;
}

.orders-list {
  display: grid;
  gap: 12px;
}

.empty-state {
  margin: 0;
  padding: 34px 18px;
  border: 1px dashed #bbc6be;
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
  background: var(--surface-soft);
}

.empty-state.compact {
  padding: 18px 12px;
}

.order-card {
  border: 1px solid var(--line);
  border-left: 5px solid var(--accent);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
}

.order-card[data-status="En preparacion"] {
  border-left-color: var(--amber);
}

.order-card[data-status="Despachado"] {
  border-left-color: var(--blue);
}

.order-card[data-status="Entregado"] {
  border-left-color: var(--done);
}

.order-time {
  margin: 4px 0 0;
  font-size: 0.86rem;
}

.order-products {
  margin-top: 12px;
  display: grid;
  gap: 4px;
}

.order-products p,
.order-detail,
.order-total {
  margin-bottom: 0;
}

.order-total {
  margin-top: 9px;
  font-weight: 900;
}

.order-actions {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.status-btn {
  min-height: 36px;
  font-size: 0.86rem;
}

.status-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

@media (max-width: 900px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .admin-layout {
    grid-template-columns: 1fr;
  }

  .admin-sidebar {
    position: static;
    height: auto;
  }

  .admin-product-form {
    grid-template-columns: 1fr 1fr;
  }

  .category-admin-form {
    grid-template-columns: 1fr;
  }

  .quick-edit-box {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  body {
    background-attachment: scroll;
  }

  .topbar,
  .app-shell {
    width: min(100% - 20px, 1180px);
  }

  .topbar,
  .section-heading,
  .stats-row,
  .product-meta,
  .product-admin-row,
  .product-admin-actions,
  .product-form-actions,
  .admin-login,
  .admin-session-row {
    align-items: stretch;
    flex-direction: column;
  }

  .topbar {
    min-height: 190px;
    justify-content: center;
  }

  .brand-lockup {
    align-items: flex-start;
  }

  .brand-logo {
    width: 82px;
  }

  .mini-badge,
  .ghost-btn {
    width: 100%;
    text-align: center;
  }

  .catalog-section,
  .order-section,
  .admin-section {
    padding: 16px;
  }

  .product-list {
    grid-template-columns: 1fr;
  }

  .featured-list {
    grid-template-columns: 1fr;
  }

  .product-form {
    grid-template-columns: 1fr;
  }

  .admin-main {
    padding: 14px;
  }

  .app-brand-row {
    grid-template-columns: 132px minmax(0, 1fr) 46px;
  }

  .app-logo {
    width: 132px;
    height: 86px;
  }

  .admin-product-form {
    grid-template-columns: 1fr;
  }

  .category-admin-form {
    grid-template-columns: 1fr;
  }

  .quick-edit-box {
    grid-template-columns: 1fr;
  }

  .admin-topline,
  .admin-panel-heading,
  .table-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .product-form-actions .primary-btn,
  .product-form-actions .ghost-btn,
  .admin-login .primary-btn {
    width: 100%;
  }

  .product-card {
    grid-template-columns: 48px minmax(0, 1fr);
    padding: 12px;
  }

  .product-icon {
    width: 48px;
    height: 48px;
  }

  .qty-label {
    max-width: none;
  }

  .order-topline {
    align-items: flex-start;
  }
}

/* Mobile app client experience */
.client-page {
  min-height: 100vh;
  padding: env(safe-area-inset-top) 0 calc(82px + env(safe-area-inset-bottom));
  background: var(--bg);
}

.client-page .app-header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 8px 12px 8px;
  background: rgba(17, 17, 17, 0.98);
  color: #ffffff;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.2);
}

.app-brand-row {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr) 46px;
  align-items: center;
  gap: 10px;
}

.app-logo {
  width: 118px;
  height: 76px;
  object-fit: contain;
  filter: none;
}

.client-page h1 {
  margin: 0;
  font-size: 1.14rem;
  line-height: 1.05;
}

.cart-shortcut {
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #ffffff;
  font-size: 1rem;
  font-weight: 900;
}

.app-search {
  margin-top: 8px;
  gap: 6px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.78rem;
}

.app-search input {
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  background: #ffffff;
  padding: 0 16px;
}

.header-menu {
  display: flex;
  gap: 8px;
  margin: 8px -12px 0;
  padding: 0 12px 2px;
  overflow-x: auto;
}

.header-menu button {
  flex: 0 0 auto;
  min-height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  padding: 0 12px;
  font-size: 0.78rem;
  font-weight: 900;
}

.mobile-shell {
  width: min(100%, 720px);
  margin: 0 auto;
  padding: 10px 10px 0;
}

.app-view {
  display: none;
}

.app-view.is-active {
  display: block;
}

.view-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.view-heading h2 {
  font-size: 1.28rem;
}

.hero-banner {
  position: relative;
  display: grid;
  gap: 16px;
  min-height: 260px;
  margin-bottom: 12px;
  border-radius: 8px;
  overflow: hidden;
  padding: 22px;
  color: #ffffff;
  background:
    linear-gradient(90deg, rgba(17, 17, 17, 0.94), rgba(17, 17, 17, 0.72) 58%, rgba(17, 17, 17, 0.24)),
    url("https://images.unsplash.com/photo-1504917595217-d4dc5ebe6122?auto=format&fit=crop&w=1200&q=75") center/cover;
  box-shadow: 0 14px 32px rgba(17, 17, 17, 0.18);
}

.hero-kicker {
  margin-bottom: 10px;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.hero-banner h2 {
  max-width: 11ch;
  margin-bottom: 10px;
  font-size: 2.25rem;
  line-height: 0.98;
}

.hero-banner p:not(.hero-kicker) {
  max-width: 23rem;
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.88);
  font-weight: 800;
}

.hero-btn {
  align-self: end;
  width: min(100%, 220px);
}

.app-order-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  border-radius: 8px;
  background: linear-gradient(135deg, #111111, #2a2a2a);
  color: #ffffff;
  padding: 14px;
}

.app-order-panel span {
  display: block;
  margin-bottom: 4px;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.app-order-panel strong {
  display: block;
  max-width: 18ch;
  font-size: 1.08rem;
  line-height: 1.12;
}

.catalog-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(116px, 1fr));
  gap: 8px;
  margin: 12px 0;
  overflow-x: auto;
  padding-bottom: 4px;
}

.category-tile {
  min-height: 86px;
  display: grid;
  align-content: end;
  gap: 5px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  color: #ffffff;
  text-align: left;
  overflow: hidden;
  background: var(--charcoal);
  box-shadow: 0 8px 18px rgba(17, 17, 17, 0.1);
}

.category-tile span {
  font-size: 0.9rem;
  font-weight: 900;
  line-height: 1.05;
}

.category-tile small {
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.7rem;
  font-weight: 800;
  line-height: 1.25;
}

.tile-construction {
  background: linear-gradient(135deg, #111111, #4a4a4a);
}

.tile-bath {
  background: linear-gradient(135deg, #111111, #3f657d);
}

.tile-faucets {
  background: linear-gradient(135deg, #111111, #626262);
}

.tile-floors {
  background: linear-gradient(135deg, #111111, #8a7058);
}

.tile-kitchen {
  background: linear-gradient(135deg, #111111, #58644f);
}

.tile-water {
  background: linear-gradient(135deg, #111111, #245f74);
}

.tile-tools {
  background: linear-gradient(135deg, #111111, #8a4a10);
}

.tile-offers {
  background: linear-gradient(135deg, #ff7b00, #111111);
}

.client-page .featured-section,
.client-page .cart-box,
.client-page .order-form,
.account-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  padding: 12px;
  box-shadow: 0 10px 24px rgba(36, 36, 32, 0.08);
}

.client-page .featured-section {
  margin-top: 10px;
}

.client-page .product-list,
.client-page .featured-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
  margin-top: 8px;
}

.client-page .product-card {
  grid-template-columns: 68px minmax(0, 1fr);
  min-height: 112px;
  border-radius: 8px;
  padding: 10px;
  gap: 10px;
  border-top: 0;
  border-left: 4px solid var(--accent);
}

.client-page .product-icon {
  width: 68px;
  height: 76px;
  border-radius: 8px;
  font-size: 0.86rem;
}

.client-page .product-body {
  gap: 6px;
}

.client-page .product-name {
  font-size: 1rem;
  line-height: 1.12;
}

.client-page .product-description {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  font-size: 0.8rem;
  line-height: 1.25;
}

.client-page .product-price {
  font-size: 0.94rem;
  color: var(--charcoal);
}

.product-actions {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  align-items: end;
  gap: 7px;
}

.client-page .qty-label {
  max-width: none;
}

.client-page .qty-label input {
  min-height: 42px;
  padding: 0 8px;
  text-align: center;
}

.client-page .secondary-btn,
.client-page .primary-btn,
.client-page .ghost-btn,
.client-page .link-button,
.client-page .whatsapp-fallback {
  min-height: 44px;
  border-radius: 8px;
}

.client-page .secondary-btn {
  background: var(--accent);
  color: #ffffff;
}

.checkout-heading {
  display: grid;
  gap: 4px;
  margin-bottom: 2px;
}

.checkout-heading strong {
  color: var(--charcoal);
  font-size: 1rem;
}

.checkout-heading span {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
}

.benefits-section {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.benefits-section div {
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-left: 5px solid var(--accent);
  border-radius: 8px;
  background: #ffffff;
  padding: 13px 14px;
}

.benefits-section strong {
  color: var(--charcoal);
  font-size: 0.98rem;
}

.benefits-section span {
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 700;
}

.store-footer {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 12px;
  margin-top: 12px;
  border-radius: 8px;
  background: var(--charcoal);
  color: #ffffff;
  padding: 16px;
}

.store-footer img {
  width: 150px;
  height: 96px;
  object-fit: contain;
}

.store-footer p {
  margin: 4px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.86rem;
}

.store-footer a {
  color: #ffffff;
  font-weight: 900;
  text-decoration: none;
}

.footer-tags {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.footer-tags span,
.footer-tags a {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  padding: 7px 10px;
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 900;
  text-decoration: none;
}

.contact-list {
  display: grid;
  gap: 8px;
  width: 100%;
  margin-top: 4px;
}

.contact-list span,
.contact-list a {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 10px 12px;
  color: var(--charcoal);
  font-size: 0.9rem;
  font-weight: 900;
  text-decoration: none;
}

.client-page .category-filter {
  margin: 2px -12px 14px;
  padding: 2px 12px 8px;
  gap: 9px;
}

.client-page .category-chip {
  min-height: 42px;
  font-size: 0.9rem;
}

.client-page .cart-box,
.client-page .order-form {
  margin-top: 12px;
}

.client-page .cart-item {
  grid-template-columns: minmax(0, 1fr) 84px;
  min-height: 76px;
}

.client-page .cart-item input {
  min-height: 48px;
  text-align: center;
}

.client-page .order-form input,
.client-page .order-form textarea {
  min-height: 48px;
  border-radius: 8px;
}

.client-orders-list {
  display: grid;
  gap: 10px;
}

.client-order-card {
  border: 1px solid var(--line);
  border-left: 5px solid var(--accent);
  border-radius: 8px;
  background: #ffffff;
  padding: 14px;
}

.client-order-card > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.client-order-card span {
  color: var(--accent-strong);
  font-weight: 900;
}

.account-panel {
  display: grid;
  gap: 12px;
  text-align: center;
}

.account-logo {
  width: min(300px, 100%);
  border-radius: 8px;
  background: var(--charcoal);
  padding: 14px;
  margin: 0 auto;
  filter: none;
}

.bottom-nav {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 2px;
  padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 -10px 28px rgba(36, 36, 32, 0.14);
}

.cart-toast {
  position: fixed;
  right: 12px;
  bottom: calc(86px + env(safe-area-inset-bottom));
  left: 12px;
  z-index: 40;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  max-width: 520px;
  margin: 0 auto;
  border: 1px solid rgba(255, 123, 0, 0.32);
  border-radius: 8px;
  background: #111111;
  color: #ffffff;
  padding: 12px;
  box-shadow: 0 16px 34px rgba(17, 17, 17, 0.28);
  transform: translateY(18px);
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.cart-toast.is-visible {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.cart-toast strong,
.cart-toast span {
  display: block;
}

.cart-toast strong {
  font-size: 0.92rem;
}

.cart-toast span {
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.8rem;
  font-weight: 800;
}

.cart-toast-action {
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #ffffff;
  padding: 0 12px;
  font-weight: 900;
}

.bottom-nav-item {
  min-width: 0;
  min-height: 58px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  display: grid;
  place-items: center;
  gap: 3px;
  font-size: 0.68rem;
  font-weight: 900;
}

.bottom-nav-item svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.bottom-nav-item.is-active {
  background: #fff0e2;
  color: var(--accent-strong);
}

@media (min-width: 760px) {
  .client-page {
    padding-bottom: 96px;
  }

  .client-page .app-header {
    padding-inline: calc((100% - 720px) / 2 + 14px);
  }

  .header-menu {
    margin-inline: 0;
    padding-inline: 0;
  }

  .catalog-strip {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .client-page .product-list,
  .client-page .featured-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
