/* ═══════════════════════════════════════════════════════════
   SS Events LLC — 2026 Muted Pastel Design System
   Palette: Dusty rose · sage green · warm cream · soft violet
   ═══════════════════════════════════════════════════════════ */

/* ── Variables ─────────────────────────────────────────── */
:root {
  /* Brand — SS Events navy (from logo) */
  --brand:        #1e4a72;   /* deep navy */
  --brand-dark:   #12334f;   /* darker navy */
  --brand-mid:    #3a6d9e;   /* mid navy */
  --brand-light:  #ddeaf7;   /* light blue tint */
  --brand-xlight: #f0f6fc;   /* very light blue */

  /* Gold accent (from logo) */
  --gold:         #c9a84c;
  --gold-dark:    #a8893a;
  --gold-light:   #f7edcc;
  --gold-xlight:  #fdf8ec;

  /* Warm rose accent */
  --rose:         #c97b84;
  --rose-dark:    #a85e67;
  --rose-light:   #fceef0;
  --rose-xlight:  #fff7f8;

  /* Sage */
  --sage:         #7aaa8a;
  --sage-dark:    #5a8a6a;
  --sage-light:   #eaf3ec;

  /* Neutrals — pearl/white like the logo background */
  --cream:        #f8f8f6;
  --cream-2:      #f0efea;
  --cream-3:      #e4e2da;
  --text:         #0f2236;   /* very dark navy */
  --text-2:       #3a5068;
  --text-3:       #7a94a8;
  --bg:           #f8f9fb;   /* clean near-white */
  --bg-card:      #ffffff;
  --border:       #d8e6f0;
  --border-2:     #b8cfe0;

  /* Radius */
  --r-xs:  6px;
  --r-sm:  10px;
  --r-md:  16px;
  --r-lg:  22px;
  --r-xl:  32px;

  /* Shadow */
  --sh-sm: 0 1px 4px rgba(15,34,54,.07);
  --sh-md: 0 4px 16px rgba(15,34,54,.10);
  --sh-lg: 0 8px 32px rgba(30,74,114,.16);
}

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

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: #f6f8fb;
  color: var(--text);
  min-height: 100vh;
  line-height: 1.65;
}

/* ── Header ────────────────────────────────────────────── */
header {
  background: linear-gradient(135deg, #1e4a72 0%, #12334f 60%, #1a3f65 100%);
  border-bottom: 2px solid var(--gold);
  padding: 0 24px;
  position: sticky; top: 0; z-index: 200;
  box-shadow: 0 2px 16px rgba(15,34,54,.3);
}
.header-inner {
  max-width: 1140px; margin: 0 auto;
  display: flex; align-items: center;
  justify-content: space-between; height: 64px;
}
.brand {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.brand-logo {
  height: 44px;
  width: auto;
  display: block;
  object-fit: contain;
  /* New logo is wide landscape — constrain width so it doesn't overflow */
  max-width: 80px;
  border-radius: 4px;
}
/* Brand name text — shown on the navy header */
.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0;
  line-height: 1.15;
}
.brand-name {
  font-size: 1.05rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: .02em;
  white-space: nowrap;
}
.brand-city {
  font-size: .68rem;
  font-weight: 600;
  color: #c9a84c;
  letter-spacing: .08em;
  text-transform: uppercase;
  white-space: nowrap;
}
.brand h1 { display: none; }
.tagline   { display: none; }
@media(max-width: 480px) {
  .brand-logo { height: 36px; max-width: 64px; }
  .brand-name { font-size: .9rem; }
  .brand-city { font-size: .6rem; }
}
@media(max-width: 360px) {
  .brand-logo { height: 30px; max-width: 54px; }
  .brand-text { display: none; }  /* very tiny screens: logo only */
}

.hamburger-btn {
  background: rgba(255,255,255,.15); border: 1px solid rgba(255,255,255,.3);
  border-radius: var(--r-sm); width: 40px; height: 40px;
  font-size: 1.2rem; cursor: pointer; color: #fff;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s;
}
.hamburger-btn:hover { background: rgba(201,168,76,.4); border-color: var(--gold); }

/* ── Side Drawer ───────────────────────────────────────── */
.menu-overlay { display: none; position: fixed; inset: 0; background: rgba(45,38,64,.4); z-index: 300; }
.menu-overlay.open { display: block; }
.side-drawer {
  position: fixed; top: 0; right: -290px; width: 290px; height: 100%;
  background: #fff; z-index: 400;
  box-shadow: -6px 0 32px rgba(45,38,64,.14);
  transition: right .28s cubic-bezier(.4,0,.2,1);
  display: flex; flex-direction: column;
}
.side-drawer.open { right: 0; }
.drawer-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 2px solid var(--gold);
  background: linear-gradient(135deg, #1e4a72 0%, #12334f 100%);
}
.drawer-close {
  background: rgba(255,255,255,.15); border: 1px solid rgba(255,255,255,.25);
  font-size: 1rem; color: #fff; cursor: pointer; padding: 5px 8px;
  border-radius: var(--r-xs); transition: background .2s; line-height: 1;
}
.drawer-close:hover { background: rgba(201,168,76,.4); }
.drawer-link {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 20px;
  color: var(--text-2); text-decoration: none;
  font-size: .93rem; font-weight: 500;
  border-bottom: 1px solid var(--border);
  transition: all .15s;
}
.drawer-link:hover { background: var(--brand-xlight); color: var(--brand); padding-left: 26px; }
.drawer-link.active { background: var(--brand-light); color: var(--brand); font-weight: 700; }

/* ── Buttons ───────────────────────────────────────────── */
.btn {
  padding: 10px 22px; border: none; border-radius: var(--r-xl);
  cursor: pointer; font-size: .93rem; font-weight: 600;
  transition: all .2s; display: inline-flex; align-items: center;
  gap: 7px; text-decoration: none; white-space: nowrap;
}
.btn-primary   { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(30,74,114,.35); }
.btn-rose      { background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%); color: #fff; }
.btn-rose:hover{ filter: brightness(1.08); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(201,168,76,.4); }
.btn-sage      { background: var(--sage); color: #fff; }
.btn-sage:hover{ background: var(--sage-dark); }
.btn-outline   { background: transparent; color: var(--brand); border: 2px solid var(--brand); }
.btn-outline:hover { background: var(--brand); color: #fff; }
.btn-outline-dark { background: transparent; color: var(--text-2); border: 1.5px solid var(--border-2); }
.btn-outline-dark:hover { border-color: var(--brand); color: var(--brand); }
.btn-success   { background: var(--sage); color: #fff; }
.btn-success:hover { background: var(--sage-dark); }
.btn-danger    { background: #d45f6a; color: #fff; }
.btn-danger:hover { background: #b84d58; }
.btn-edit      { background: #d4934a; color: #fff; }
.btn-edit:hover{ background: #b87c3a; }
.btn-sm        { padding: 5px 14px; font-size: .8rem; border-radius: 50px; }

/* ── Layout ────────────────────────────────────────────── */
main { max-width: 1140px; margin: 0 auto; padding: 32px 20px 72px; }

/* ═══════════════════════════════════════════════════════
   HOME PAGE — 2026 Muted Pastel
   ═══════════════════════════════════════════════════════ */

/* ── Hero ──────────────────────────────────────────────── */
.hero {
  position: relative; overflow: hidden;
  /* Pearl white with subtle blue tint — matches logo card background */
  background: linear-gradient(160deg, #ffffff 0%, #f5f8fc 35%, #eef4fb 70%, #f8f6f0 100%);
  border-radius: var(--r-xl); padding: 60px 40px 52px;
  margin-bottom: 32px; text-align: center;
  border: 1px solid rgba(201,168,76,.2);
  box-shadow: 0 4px 32px rgba(15,34,54,.07), inset 0 1px 0 rgba(255,255,255,.9);
}
/* Gold confetti-style top border accent */
.hero::before {
  content: ''; position: absolute;
  top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--brand) 0%, var(--gold) 50%, var(--brand) 100%);
  border-radius: var(--r-xl) var(--r-xl) 0 0;
}
/* Decorative radial glow */
.hero::after {
  content: ''; position: absolute;
  top: -40px; right: -60px; width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(201,168,76,.08) 0%, transparent 65%);
  border-radius: 50%; pointer-events: none;
}
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--gold-xlight); color: var(--gold-dark);
  border: 1px solid rgba(201,168,76,.35);
  border-radius: 50px; padding: 5px 16px;
  font-size: .78rem; font-weight: 700; letter-spacing: .05em;
  text-transform: uppercase; margin-bottom: 18px;
}
.hero h2 {
  font-size: clamp(1.8rem, 5vw, 2.8rem);
  font-weight: 800; letter-spacing: -.03em;
  color: var(--text); line-height: 1.18; margin-bottom: 14px;
}
.hero h2 .hl-rose   { color: var(--gold); }
.hero h2 .hl-violet { color: var(--brand); }
.hero-sub {
  color: var(--text-2); font-size: 1.05rem;
  max-width: 500px; margin: 0 auto 28px; line-height: 1.7;
}
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; position: relative; z-index: 1; }

/* ── Hero badges ───────────────────────────────────────── */
.hero-badges { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 28px; position: relative; z-index: 1; }
.badge {
  background: rgba(255,255,255,.85); backdrop-filter: blur(4px);
  border: 1px solid rgba(200,190,220,.4);
  color: var(--text-2); border-radius: 50px;
  padding: 6px 14px; font-size: .8rem; font-weight: 600;
  box-shadow: var(--sh-sm); transition: all .2s;
}
.badge:hover { border-color: var(--brand); color: var(--brand); background: var(--brand-xlight); transform: translateY(-1px); }

/* ── Stat strip ────────────────────────────────────────── */
.stat-strip {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 14px; margin-bottom: 32px;
}
@media(max-width:640px){ .stat-strip { grid-template-columns: repeat(2,1fr); } }
.stat-card {
  background: #fff; border: 1px solid var(--border);
  border-top: 3px solid var(--gold);
  border-radius: var(--r-md); padding: 20px 16px; text-align: center;
  box-shadow: var(--sh-sm); transition: box-shadow .2s, transform .2s;
}
.stat-card:hover { box-shadow: var(--sh-lg); transform: translateY(-3px); }
.stat-num { font-size: 1.5rem; font-weight: 800; color: var(--brand); margin-bottom: 4px; }
.stat-label { font-size: .75rem; color: var(--text-3); font-weight: 500; }

/* ── Date picker ───────────────────────────────────────── */
.date-picker-section { margin: 0 0 28px; }
.date-picker-card {
  background: #fff; border: 1.5px solid var(--border);
  border-radius: var(--r-md); padding: 22px 28px;
  display: flex; align-items: center; gap: 18px;
  flex-wrap: wrap; box-shadow: var(--sh-sm);
}
.date-picker-card label { font-weight: 700; color: var(--brand); font-size: .95rem; flex: 1; min-width: 200px; }
.date-picker-card input[type=date] {
  padding: 10px 18px; border: 1.5px solid var(--border);
  border-radius: var(--r-sm); font-size: 1rem; color: var(--text);
  outline: none; transition: border .2s; background: var(--brand-xlight); cursor: pointer;
}
.date-picker-card input[type=date]:focus { border-color: var(--brand); }
.date-hint { color: var(--text-3); font-size: .85rem; margin-top: 8px; width: 100%; }

/* ── Items grid ────────────────────────────────────────── */
.items-section h3 { font-size: 1.15rem; font-weight: 700; color: var(--text); margin-bottom: 18px; }
.items-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px,1fr)); gap: 18px; }
.item-card {
  background: #fff; border-radius: var(--r-md);
  border: 1px solid var(--border); overflow: hidden;
  box-shadow: var(--sh-sm); transition: transform .2s, box-shadow .2s;
}
.item-card:hover { transform: translateY(-4px); box-shadow: var(--sh-lg); }
.item-card img { width: 100%; height: 164px; object-fit: cover; background: var(--brand-light); }
.item-card .no-img {
  width: 100%; height: 164px;
  background: linear-gradient(135deg,var(--rose-xlight),var(--brand-xlight));
  display: flex; align-items: center; justify-content: center; font-size: 2.8rem;
}
.item-card-body { padding: 14px 16px; }
.item-card-body h4 { font-size: .93rem; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.item-card-body .price { color: var(--brand); font-weight: 800; font-size: 1.05rem; margin-bottom: 6px; }
.item-card-body .avail { font-size: .78rem; color: var(--text-3); margin-bottom: 10px; }

/* Qty control */
.qty-control { display: flex; align-items: center; gap: 10px; }
.qty-control button {
  width: 32px; height: 32px; border-radius: 50%;
  border: 1.5px solid var(--brand); background: #fff;
  color: var(--brand); font-size: 1.1rem; cursor: pointer;
  font-weight: 700; transition: all .15s;
  display: flex; align-items: center; justify-content: center;
}
.qty-control button:hover { background: var(--brand); color: #fff; }
.qty-control .qty-num { font-size: 1rem; font-weight: 700; min-width: 24px; text-align: center; }

/* ── Order form ────────────────────────────────────────── */
.form-section {
  background: #fff; border-radius: var(--r-lg);
  padding: 32px; margin-top: 32px;
  border: 1px solid var(--border); box-shadow: var(--sh-md);
}
.form-section h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 22px; color: var(--brand); }
.order-summary {
  background: linear-gradient(135deg,var(--brand-xlight),var(--rose-xlight));
  border-radius: var(--r-md); padding: 18px 22px;
  margin-bottom: 22px; border: 1px solid var(--border);
}
.order-summary h4 { font-size: 1rem; font-weight: 700; margin-bottom: 10px; color: var(--text); }
.order-summary ul { list-style: none; padding: 0; }
.order-summary li { padding: 5px 0; border-bottom: 1px solid rgba(124,106,173,.1); font-size: .9rem; color: var(--text-2); }
.order-summary .total { font-weight: 800; margin-top: 10px; color: var(--brand); font-size: 1.05rem; }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; margin-bottom: 6px; font-weight: 600; font-size: .88rem; color: var(--text); }
.form-group input, .form-group textarea, .form-group select {
  width: 100%; padding: 11px 16px; border: 1.5px solid var(--border);
  border-radius: var(--r-sm); font-size: .95rem; color: var(--text);
  outline: none; transition: border .2s; background: #fff;
  font-family: inherit;
}
.form-group input:focus, .form-group textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(124,106,173,.1); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media(max-width:600px) { .form-row { grid-template-columns: 1fr; } }
.checkbox-group label { display: flex; align-items: flex-start; gap: 10px; font-weight: 500; cursor: pointer; }
.checkbox-group input[type=checkbox] { width: auto; margin-top: 3px; accent-color: var(--brand); }
.delivery-note { color: var(--text-3); font-size: .82rem; }
.error-msg { color: var(--rose); font-size: .85rem; margin-top: 5px; }

/* ── CATALOG PAGE ──────────────────────────────────────── */
.catalog-toolbar {
  margin: 0 0 24px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap;
}
.catalog-toolbar input {
  flex: 1; min-width: 220px; padding: 11px 18px;
  border: 1.5px solid var(--border); border-radius: 50px;
  font-size: .93rem; outline: none; transition: border .2s; background: #fff;
}
.catalog-toolbar input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(124,106,173,.1); }

/* Masonry-style gallery grid */
.catalog-grid {
  columns: 4 200px; column-gap: 14px;
}
@media(max-width:900px)  { .catalog-grid { columns: 3 160px; } }
@media(max-width:580px)  { .catalog-grid { columns: 2 140px; } }

.catalog-card {
  break-inside: avoid; margin-bottom: 14px;
  border-radius: var(--r-md); overflow: hidden;
  position: relative; cursor: zoom-in;
  background: var(--cream-2);
  box-shadow: var(--sh-sm);
  transition: transform .22s, box-shadow .22s;
}
.catalog-card:hover { transform: scale(1.025); box-shadow: var(--sh-lg); z-index: 2; }
.catalog-img-wrap { position: relative; display: block; line-height: 0; }
.catalog-img-wrap img {
  width: 100%; display: block;
  object-fit: cover; border-radius: var(--r-md);
  transition: filter .22s;
}
.catalog-card:hover .catalog-img-wrap img { filter: brightness(.88); }
.catalog-overlay {
  position: absolute; inset: 0; border-radius: var(--r-md);
  background: rgba(45,38,64,.0); display: flex;
  align-items: center; justify-content: center;
  transition: background .22s;
}
.catalog-card:hover .catalog-overlay { background: rgba(45,38,64,.28); }
.catalog-overlay span {
  background: rgba(255,255,255,.92); color: var(--brand);
  padding: 7px 16px; border-radius: 50px; font-size: .85rem;
  font-weight: 700; opacity: 0; transform: scale(.8);
  transition: opacity .2s, transform .2s;
}
.catalog-card:hover .catalog-overlay span { opacity: 1; transform: scale(1); }
.catalog-card-body {
  padding: 10px 14px 12px;
  background: #fff;
  border-radius: 0 0 var(--r-md) var(--r-md);
}
.catalog-card-body h4 { font-size: .88rem; font-weight: 700; color: var(--text); margin-bottom: 2px; }
.catalog-card-body p  { font-size: .78rem; color: var(--text-3); line-height: 1.4; }
.catalog-loading { text-align: center; padding: 60px; color: var(--text-3); font-size: 1rem; }
.catalog-empty   { text-align: center; padding: 60px; color: var(--text-3); font-size: 1rem; }

/* ── Lightbox ──────────────────────────────────────────── */
.lightbox-overlay {
  display: none; position: fixed; inset: 0; z-index: 2000;
  background: rgba(20,15,35,.92); backdrop-filter: blur(8px);
  align-items: center; justify-content: center; gap: 12px;
}
.lightbox-overlay[style*="flex"] { display: flex !important; }
.lightbox-content {
  max-width: min(90vw, 860px); max-height: 90vh;
  border-radius: var(--r-lg); overflow: hidden;
  position: relative; box-shadow: 0 24px 80px rgba(0,0,0,.5);
  background: #fff;
}
.lightbox-content img {
  width: 100%; max-height: 80vh; object-fit: contain; display: block;
}
.lightbox-caption {
  padding: 14px 20px; background: #fff;
  font-size: .9rem; color: var(--text-2); text-align: center;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px;
}
.lightbox-caption strong { color: var(--brand); font-size: 1rem; }
.lightbox-caption span { font-size: .82rem; color: var(--text-3); }
.lightbox-close {
  position: fixed; top: 20px; right: 20px;
  background: rgba(255,255,255,.15); border: 1.5px solid rgba(255,255,255,.25);
  color: #fff; width: 40px; height: 40px; border-radius: 50%;
  font-size: 1rem; cursor: pointer; z-index: 10;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s;
}
.lightbox-close:hover { background: rgba(255,255,255,.3); }
.lightbox-prev, .lightbox-next {
  background: rgba(255,255,255,.12); border: 1.5px solid rgba(255,255,255,.2);
  color: #fff; width: 48px; height: 48px; border-radius: 50%;
  font-size: 1.6rem; cursor: pointer; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s; line-height: 1;
}
.lightbox-prev:hover, .lightbox-next:hover { background: rgba(255,255,255,.25); }

/* ── Admin page ────────────────────────────────────────── */
.tabs {
  display: flex; gap: 6px; flex-wrap: wrap;
  margin-bottom: 24px; padding: 12px 16px;
  background: #fff; border-radius: var(--r-md);
  border: 1px solid var(--border); box-shadow: var(--sh-sm);
}
.tab-btn {
  padding: 7px 16px; border: 1.5px solid var(--border);
  border-radius: 50px; cursor: pointer; background: #fff;
  color: var(--text-2); font-weight: 600; font-size: .83rem;
  transition: all .2s;
}
.tab-btn:hover { border-color: var(--brand); color: var(--brand); background: var(--brand-xlight); }
.tab-btn.active { background: var(--brand); color: #fff; border-color: var(--brand); box-shadow: 0 2px 8px rgba(30,74,114,.28); }

.section-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 20px; flex-wrap: wrap; gap: 12px;
}
.section-header h3 { font-size: 1.1rem; font-weight: 700; color: var(--text); }

/* ── Data table ────────────────────────────────────────── */
.data-table { width: 100%; border-collapse: collapse; font-size: .86rem; }
.data-table th {
  background: var(--brand); color: #fff;
  padding: 10px 14px; text-align: left;
  font-size: .8rem; font-weight: 600; white-space: nowrap;
}
.data-table th:first-child { border-radius: 8px 0 0 0; }
.data-table th:last-child  { border-radius: 0 8px 0 0; }
.data-table td { padding: 10px 14px; border-bottom: 1px solid var(--border); vertical-align: top; }
.data-table tr:hover td { background: var(--bg); }
.data-table tr:last-child td { border-bottom: none; }
.data-table img { width: 54px; height: 42px; object-fit: cover; border-radius: 6px; }
tr.row-unpaid td { background: #fffbeb !important; }
tr.row-unpaid td:first-child { border-left: 3px solid #f59e0b; }

/* ── Modals ────────────────────────────────────────────── */
.modal-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(20,15,40,.5); z-index: 1000;
  align-items: center; justify-content: center;
  backdrop-filter: blur(3px);
}
.modal-overlay[style*="flex"] { display: flex !important; }
.modal {
  background: #fff; border-radius: var(--r-lg);
  padding: 32px; width: 90%; max-width: 520px;
  max-height: 90vh; overflow-y: auto;
  box-shadow: 0 24px 64px rgba(45,38,64,.2);
  animation: modalIn .2s ease-out;
}
@keyframes modalIn { from { opacity:0; transform:scale(.95) translateY(10px); } to { opacity:1; transform:none; } }
.modal h2 { font-size: 1.2rem; font-weight: 800; margin-bottom: 20px; color: var(--text); }
.modal-actions { display: flex; gap: 10px; margin-top: 24px; flex-wrap: wrap; }
.modal-actions .btn { flex: 1; min-width: 120px; justify-content: center; }

/* ── KPI ───────────────────────────────────────────────── */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(180px,1fr)); gap: 14px; margin-bottom: 24px; }
.kpi-card { background: #fff; border-radius: var(--r-md); padding: 20px; text-align: center; border: 1px solid var(--border); box-shadow: var(--sh-sm); }
.kpi-icon { font-size: 1.7rem; margin-bottom: 6px; }
.kpi-val { font-size: 1.5rem; font-weight: 800; color: var(--brand); margin-bottom: 4px; }
.kpi-label { font-size: .78rem; color: var(--text-3); }
.kpi-trend { font-size: .7rem; font-weight: 600; margin-top: 4px; }
.charts-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.chart-card { background: #fff; border-radius: var(--r-md); padding: 20px; border: 1px solid var(--border); box-shadow: var(--sh-sm); }
.chart-card h4 { font-size: .93rem; font-weight: 700; color: var(--text); margin-bottom: 14px; }
@media(max-width:768px) { .charts-grid { grid-template-columns: 1fr; } .kpi-grid { grid-template-columns: 1fr 1fr; } }

/* ── Calendar ──────────────────────────────────────────── */
.calendar-grid { background: #fff; border-radius: var(--r-md); overflow: hidden; border: 1px solid var(--border); }
.cal-header { display: grid; grid-template-columns: repeat(7,1fr); background: var(--brand); }
.cal-dow { color: #fff; text-align: center; padding: 9px 4px; font-size: .75rem; font-weight: 700; }
.cal-body { display: grid; grid-template-columns: repeat(7,1fr); }
.cal-cell { min-height: 76px; padding: 6px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); background: #fff; }
.cal-cell.empty { background: var(--bg); }
.cal-today { background: var(--brand-xlight) !important; border: 2px solid var(--brand) !important; }
.cal-today .cal-day-num { color: var(--brand); font-weight: 800; }
.cal-has-events { background: #fff8f0; }
.cal-day-num { font-size: .78rem; font-weight: 600; color: var(--text-2); margin-bottom: 4px; }
.cal-event { background: var(--brand); color: #fff; border-radius: 4px; padding: 2px 5px; font-size: .65rem; margin-bottom: 2px; display: flex; align-items: center; gap: 3px; white-space: nowrap; overflow: hidden; }
.cal-event-dot { width: 4px; height: 4px; border-radius: 50%; background: rgba(255,255,255,.7); flex-shrink: 0; }
.cal-event-total { opacity: .8; font-size: .6rem; margin-left: auto; }

/* ── Order sub-tabs ────────────────────────────────────── */
.order-subtabs { display: flex; gap: 4px; margin: 0 0 20px; flex-wrap: wrap; border-bottom: 2px solid var(--border); padding-bottom: 0; }
.order-subtab { padding: 8px 18px; border: none; background: none; font-size: .86rem; font-weight: 600; color: var(--text-3); cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -2px; transition: color .15s, border-color .15s; display: flex; align-items: center; gap: 6px; }
.order-subtab:hover { color: var(--brand); }
.order-subtab.active { color: var(--brand); border-bottom-color: var(--brand); }
.order-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 20px; padding: 0 5px; background: var(--brand-light); color: var(--brand); border-radius: 20px; font-size: .68rem; font-weight: 700; }
.order-subtab.active .order-badge { background: var(--brand); color: #fff; }
.order-row-empty td { text-align: center; padding: 48px 24px; color: var(--text-3); font-size: .93rem; }

/* ── Payment badges ────────────────────────────────────── */
.pay-badge-paid    { background: #d1fae5; color: #065f46; border: 1px solid #6ee7b7; border-radius: 20px; padding: 3px 10px; font-size: .72rem; font-weight: 700; white-space: nowrap; display: inline-block; }
.pay-badge-partial { background: #fef3c7; color: #92400e; border: 1px solid #fcd34d; border-radius: 20px; padding: 3px 10px; font-size: .72rem; font-weight: 700; white-space: nowrap; display: inline-block; }
.pay-badge-unpaid  { background: #fce7eb; color: #9b1c2e; border: 1px solid #fca5a5; border-radius: 20px; padding: 3px 10px; font-size: .72rem; font-weight: 700; white-space: nowrap; display: inline-block; }
.pay-badge-none    { background: var(--bg); color: var(--text-3); border: 1px solid var(--border); border-radius: 20px; padding: 3px 10px; font-size: .72rem; font-weight: 700; white-space: nowrap; display: inline-block; }
.balance-overpaid  { background: #d1fae5; border: 1.5px solid #6ee7b7; border-radius: var(--r-sm); padding: 12px; }
.balance-underpaid { background: #fef3c7; border: 1.5px solid #fcd34d; border-radius: var(--r-sm); padding: 12px; }
.balance-exact     { background: #d1fae5; border: 1.5px solid #6ee7b7; border-radius: var(--r-sm); padding: 12px; }
.balance-unpaid    { background: #fce7eb; border: 1.5px solid #fca5a5; border-radius: var(--r-sm); padding: 12px; }
.pay-pill { display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border: 1.5px solid var(--border); border-radius: 50px; cursor: pointer; font-size: .86rem; font-weight: 600; color: var(--text-2); transition: all .15s; }
.pay-pill:has(input:checked) { background: var(--brand); color: #fff; border-color: var(--brand); }
.pay-pill input { display: none; }

/* ── Reviews ───────────────────────────────────────────── */
.reviews-section { padding: 40px 0 24px; }
.reviews-track-wrap {
  overflow: hidden;
  position: relative;
  padding: 12px 0;
  /* Fade edges for seamless scroll feel */
  mask-image: linear-gradient(to right, transparent 0%, black 6%, black 94%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 6%, black 94%, transparent 100%);
}
.reviews-track {
  display: flex;
  gap: 20px;
  width: max-content;
  /* animation set by JS after content is loaded */
}
.reviews-track:hover { animation-play-state: paused; cursor: default; }
.review-card {
  background: #fff;
  border-radius: var(--r-md);
  padding: 24px 26px;
  min-width: 290px;
  max-width: 310px;
  box-shadow: var(--sh-md);
  border: 1px solid var(--border);
  border-top: 3px solid var(--gold);
  transition: transform .2s, box-shadow .2s;
  flex-shrink: 0;
}
.review-card:hover { transform: translateY(-3px); box-shadow: var(--sh-lg); }
.review-card .stars { color: #f59e0b; font-size: 1.15rem; margin-bottom: 10px; letter-spacing: 2px; }
.review-card .review-msg { color: var(--text-2); font-size: .9rem; line-height: 1.6; margin-bottom: 14px; font-style: italic; }
.review-card .review-name { font-weight: 700; color: var(--brand); font-size: .85rem; }
.review-card .review-date { font-size: .74rem; color: var(--text-3); margin-top: 2px; }
@keyframes scrollReviews { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
.submit-review { background: linear-gradient(135deg,var(--brand-xlight),var(--rose-xlight)); border-radius: var(--r-lg); padding: 32px 28px; margin: 32px auto; max-width: 520px; box-shadow: var(--sh-md); border: 1px solid var(--border); }
.submit-review h3 { margin: 0 0 16px; color: var(--brand); font-size: 1.15rem; font-weight: 800; text-align: center; }
.submit-review .star-picker { display: flex; gap: 8px; justify-content: center; margin-bottom: 16px; font-size: 1.7rem; cursor: pointer; }
.submit-review .star-picker span { color: #ddd; transition: color .15s; }
.submit-review .star-picker span.lit { color: #f59e0b; }
.review-success { text-align: center; color: var(--sage-dark); font-weight: 600; margin-top: 8px; display: none; }

/* ── Footer — compact ──────────────────────────────────── */
footer {
  background: linear-gradient(135deg, #0f2236 0%, #1e4a72 100%);
  color: #a8c4dc;
  padding: 20px 24px;
  margin-top: 48px;
  border-top: 2px solid var(--gold);
}
.footer-inner {
  max-width: 1140px; margin: 0 auto;
  display: flex; gap: 20px; flex-wrap: wrap;
  align-items: center; justify-content: space-between;
}
.footer-brand { display: flex; align-items: center; gap: 10px; }
.footer-brand img { height: 32px; width: auto; opacity: .9; }
.footer-brand strong { color: #fff; font-size: .9rem; }
.footer-brand span { display: none; }
.footer-contact { display: flex; gap: 20px; flex-wrap: wrap; align-items: center; }
.footer-contact a { color: #c9d8e8; text-decoration: none; font-size: .83rem; }
.footer-contact a:hover { color: var(--gold); }
.footer-address { font-size: .8rem; color: #7a94a8; }
.footer-copy { font-size: .72rem; color: #4a6478; }

/* ── Toast ─────────────────────────────────────────────── */
.toast { position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%); background: var(--text); color: #fff; padding: 12px 26px; border-radius: 50px; font-size: .88rem; font-weight: 600; opacity: 0; pointer-events: none; transition: opacity .3s; z-index: 9999; white-space: nowrap; box-shadow: 0 4px 20px rgba(0,0,0,.2); }
.toast.show { opacity: 1; pointer-events: auto; }
.toast.success { background: var(--sage-dark); }
.toast.error   { background: var(--rose-dark); }

/* ── Catalog ADMIN grid ────────────────────────────────── */
.catalog-admin-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(200px,1fr)); gap: 16px; }
.catalog-admin-card { background: #fff; border-radius: var(--r-md); overflow: hidden; border: 1px solid var(--border); box-shadow: var(--sh-sm); }
.catalog-admin-card img { width: 100%; height: 140px; object-fit: cover; }
.catalog-admin-body { padding: 10px 12px; }
.catalog-admin-title { font-weight: 700; font-size: .88rem; color: var(--text); }
.catalog-admin-desc  { font-size: .76rem; color: var(--text-3); margin-top: 3px; }
.catalog-admin-sort  { font-size: .72rem; color: var(--text-3); margin-top: 3px; }
.catalog-admin-actions { display: flex; gap: 6px; padding: 8px 12px; border-top: 1px solid var(--border); }

/* ── Floating socials ──────────────────────────────────── */
.floating-socials { position: fixed; bottom: 24px; right: 24px; display: flex; flex-direction: column; gap: 10px; z-index: 999; }
.float-btn { width: 48px; height: 48px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.3rem; text-decoration: none; box-shadow: 0 4px 16px rgba(0,0,0,.15); transition: transform .2s, box-shadow .2s; border: none; cursor: pointer; }
.float-btn:hover { transform: scale(1.1); box-shadow: 0 6px 22px rgba(0,0,0,.2); }
.float-wa { background: #25d366; }
.float-ig { background: linear-gradient(135deg,#f09433,#dc2743,#bc1888); }

/* ── Admin review cards ────────────────────────────────── */
.review-admin-card { background: #fff; border: 1px solid var(--border); border-radius: var(--r-md); padding: 18px 20px; margin-bottom: 12px; display: flex; gap: 16px; align-items: flex-start; }
.review-admin-card .stars { color: #f59e0b; font-size: 1rem; }
.review-admin-card .review-body { flex: 1; }
.review-admin-card .review-body .rname { font-weight: 700; color: var(--brand); }
.review-admin-card .review-body .rmsg { color: #555; margin: 5px 0; font-style: italic; font-size: .9rem; }
.review-admin-card .review-body .rdate { color: #aaa; font-size: .78rem; }
.badge-pending  { background: #fef3c7; color: #b45309; padding: 2px 10px; border-radius: 20px; font-size: .75rem; font-weight: 700; }
.badge-approved { background: #d1fae5; color: #065f46; padding: 2px 10px; border-radius: 20px; font-size: .75rem; font-weight: 700; }
.btn-sm-outline { padding: 5px 13px; border-radius: 8px; border: 1.5px solid var(--brand); color: var(--brand); background: #fff; cursor: pointer; font-size: .82rem; font-weight: 600; }
.btn-warn { border-color: #d97706; color: #b45309; }

/* ── Budget extras ─────────────────────────────────────── */
.rev-breakdown-card { background: #fff; border-radius: var(--r-md); padding: 20px 22px; border: 1px solid var(--border); }
.rev-breakdown-card h5 { margin: 0 0 14px; font-size: .88rem; font-weight: 700; color: var(--brand); display: flex; align-items: center; gap: 7px; }
.rev-row { display: flex; justify-content: space-between; align-items: center; padding: 7px 0; border-bottom: 1px solid var(--border); font-size: .86rem; }
.rev-row:last-child { border-bottom: none; }
.rev-row .rev-label { color: #666; }
.rev-row .rev-val   { font-weight: 700; color: var(--text); }
.rev-row .rev-val.green  { color: #059669; }
.rev-row .rev-val.purple { color: var(--brand); font-size: 1rem; }
.rev-row .rev-val.red    { color: var(--rose-dark); }
.rev-row .rev-val.blue   { color: #2563eb; }
.pipeline-pill { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 12px 20px; border-radius: var(--r-sm); min-width: 100px; gap: 4px; }
.pipeline-pill .pp-count { font-size: 1.5rem; font-weight: 800; }
.pipeline-pill .pp-label { font-size: .72rem; font-weight: 600; opacity: .85; }
.suggestion-item { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: .86rem; color: var(--text-2); line-height: 1.55; }
.suggestion-item:last-child { border-bottom: none; }
.suggestion-item .sug-icon { font-size: 1.1rem; flex-shrink: 0; margin-top: 1px; }
.edit-item-row { display: flex; flex-direction: column; gap: 4px; background: var(--brand-light); border-radius: 8px; padding: 10px 12px; }
.edit-item-row label { font-size: .82rem; font-weight: 600; color: var(--brand); }
.edit-item-row input { width: 70px; padding: 5px 8px; border: 1.5px solid var(--border); border-radius: 6px; font-size: .88rem; }

/* ── Fade-in tabs ──────────────────────────────────────── */
#tab-inventory, #tab-orders, #tab-catalog, #tab-coupons,
#tab-calendar, #tab-budget, #tab-delivery, #tab-reviews { animation: fadeIn .18s ease-out; }
@keyframes fadeIn { from { opacity:0; transform:translateY(4px); } to { opacity:1; transform:none; } }

/* ── Confirm card ──────────────────────────────────────── */
.confirm-order-num { color: var(--brand); font-weight: 700; font-size: 1rem; margin-bottom: 12px; }
.confirm-contact a { color: var(--brand); font-weight: 700; text-decoration: none; }

/* ── Print ─────────────────────────────────────────────── */
@media print {
  header, .tabs, .section-header button, .btn, footer, .floating-socials { display: none !important; }
  body { background: #fff; }
  .data-table th { background: var(--brand) !important; -webkit-print-color-adjust: exact; }
}
/* ════════════════════════════════════════════
   MOBILE RESPONSIVE — full breakpoint suite
   ════════════════════════════════════════════ */

/* ── Tablet: 768px and below ─────────────────── */
@media (max-width: 768px) {
  /* Layout */
  main { padding: 16px 14px 80px; }

  /* Header — tighter */
  header { padding: 0 16px; }
  .header-inner { height: 58px; }
  .brand-logo { height: 40px; }

  /* Modals */
  .modal { padding: 24px 18px; width: 95%; }
  .modal-actions { flex-direction: column; }
  .modal-actions .btn { width: 100%; min-width: 0; }

  /* Date picker stacks */
  .date-picker-card { flex-direction: column; align-items: flex-start; gap: 10px; }
  .date-picker-card label { min-width: 0; }
  .date-picker-card input[type=date] { width: 100%; }

  /* Items grid — 2 columns */
  .items-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .item-card img { height: 130px; }
  .item-card .no-img { height: 130px; }

  /* Stat strip — 2 columns */
  .stat-strip { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .stat-card { padding: 16px 12px; }
  .stat-num { font-size: 1.3rem; }

  /* Catalog masonry — 2 columns */
  .catalog-grid { columns: 2 160px; column-gap: 10px; }
  .catalog-card { margin-bottom: 10px; }

  /* Browse grid — 2 columns */
  .browse-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 12px; }

  /* Form rows stack */
  .form-row { grid-template-columns: 1fr; gap: 12px; }

  /* Charts/KPI */
  .charts-grid { grid-template-columns: 1fr; }
  .kpi-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }

  /* Admin data tables — scrollable */
  #ordersTableWrap,
  #inventoryTable,
  .data-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .data-table { font-size: .76rem; min-width: 640px; }
  .data-table th, .data-table td { padding: 8px 10px; white-space: nowrap; }

  /* Admin tabs — scrollable row */
  .tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding: 10px 12px;
    gap: 6px;
    scrollbar-width: none;
  }
  .tabs::-webkit-scrollbar { display: none; }
  .tab-btn { white-space: nowrap; flex-shrink: 0; padding: 7px 14px; font-size: .8rem; }

  /* Admin order subtabs */
  .order-subtabs { overflow-x: auto; flex-wrap: nowrap; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
  .order-subtabs::-webkit-scrollbar { display: none; }
  .order-subtab { white-space: nowrap; flex-shrink: 0; }

  /* Reviews track */
  .reviews-track-wrap { padding: 10px 0; }
  .review-card { min-width: 260px !important; max-width: 280px !important; padding: 20px 22px; }

  /* Footer */
  footer { padding: 16px; }
  .footer-inner { flex-direction: column; gap: 12px; align-items: flex-start; }
  .footer-contact { flex-direction: column; gap: 6px; }

  /* Revenue breakdown */
  #revenueBreakdown { grid-template-columns: 1fr !important; }

  /* Section header */
  .section-header { flex-direction: column; align-items: flex-start; gap: 8px; }
}

/* ── Phone: 480px and below ──────────────────── */
@media (max-width: 480px) {
  /* Typography scale down */
  body { font-size: 15px; }

  /* Header */
  header { padding: 0 12px; }
  .header-inner { height: 54px; }
  .brand-logo { height: 36px; }
  .hamburger-btn { width: 38px; height: 38px; }

  /* Main layout */
  main { padding: 12px 12px 90px; }

  /* Items grid — 1 column on very small */
  .items-grid { grid-template-columns: 1fr; gap: 10px; }
  .item-card { display: flex; flex-direction: row; }
  .item-card img { width: 110px; height: 110px; flex-shrink: 0; object-fit: cover; }
  .item-card .no-img { width: 110px; height: 110px; font-size: 2rem; flex-shrink: 0; }
  .item-card-body { padding: 12px; flex: 1; }
  .item-card-body h4 { font-size: .9rem; }
  .item-card-body .price { font-size: .95rem; }

  /* Browse grid — 1 col */
  .browse-grid { grid-template-columns: 1fr !important; }
  .browse-card .card-img { height: 180px; }
  .browse-card .no-img   { height: 180px; }

  /* Catalog — 1 col */
  .catalog-grid { columns: 1; }

  /* Stat strip — 2 col still works */
  .stat-card { padding: 14px 10px; }
  .stat-num { font-size: 1.2rem; }
  .stat-label { font-size: .68rem; }

  /* Buttons — full width on phone */
  .btn { padding: 10px 18px; font-size: .9rem; }
  .btn-sm { padding: 7px 14px; font-size: .8rem; }

  /* Modals */
  .modal { padding: 20px 16px; width: 96%; border-radius: 16px; }
  .modal h2 { font-size: 1.1rem; }

  /* Form */
  .form-section { padding: 20px 16px; }
  .form-group input, .form-group textarea { padding: 10px 13px; font-size: .92rem; }

  /* Order summary sidebar — compact */
  .order-summary { padding: 14px 16px; }

  /* Reviews */
  .review-card { min-width: 240px !important; max-width: 260px !important; padding: 18px 20px; }
  .review-card .review-msg { font-size: .88rem; }

  /* Floating socials — smaller, move up if cart bar visible */
  .floating-socials { bottom: 90px; right: 16px; }
  .float-btn { width: 44px; height: 44px; font-size: 1.15rem; }

  /* Footer compact */
  footer { padding: 14px 12px; margin-top: 32px; }
  .footer-brand img { height: 26px; }
  .footer-copy { font-size: .7rem; }
}

/* ── Very small: 360px ───────────────────────── */
@media (max-width: 360px) {
  .brand-logo { height: 30px; }
  .items-grid { grid-template-columns: 1fr; }
  .stat-strip { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .modal { width: 98%; padding: 18px 14px; }
}
