/* Suprice Gifts admin - design system (reference: Sabstation admin) */
:root {
  --a-page: #f4f5f7; --a-surface: #ffffff; --a-subtle: #f8f9fb; --a-line: #e5e7eb;
  --a-fg: #111827; --a-muted: #6b7280; --a-accent: #4f46e5; --a-accent-fg: #ffffff; --a-accent-soft: #eef2ff;
  --a-side: #0f172a; --a-side-hover: #1e293b; --a-green: #059669; --a-red: #dc2626; --a-amber: #d97706;
  --a-shadow: 0 1px 2px rgba(16,24,40,.05); --a-shadow-lg: 0 20px 50px rgba(15,23,42,.25);
  --side-w: 256px;
}
:root[data-theme="dark"] {
  --a-page: #0b1020; --a-surface: #121933; --a-subtle: #182040; --a-line: #26305a;
  --a-fg: #e8ecf8; --a-muted: #98a2c3; --a-accent: #818cf8; --a-accent-fg: #0b1020; --a-accent-soft: #232b57;
  --a-side: #070b18; --a-side-hover: #151c38; --a-green: #34d399; --a-red: #f87171; --a-amber: #fbbf24;
  --a-shadow: 0 1px 2px rgba(0,0,0,.4);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body.a-body { margin: 0; background: var(--a-page); color: var(--a-fg); font-family: Inter, -apple-system, "Segoe UI", Roboto, "Noto Sans Devanagari", sans-serif; font-size: 14px; line-height: 1.45; }
.a-body a { color: inherit; }
.a-body :focus-visible { outline: 2px solid var(--a-accent); outline-offset: 2px; }
.a-ic { width: 18px; height: 18px; flex: none; }
.a-muted { color: var(--a-muted); }
.a-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.a-skel { background: linear-gradient(90deg, var(--a-subtle), var(--a-line), var(--a-subtle)); background-size: 200% 100%; animation: a-sh 1.2s infinite; border-radius: 6px; }
@keyframes a-sh { to { background-position: -200% 0; } }
@keyframes a-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes a-slide-r { from { transform: translateX(100%); } to { transform: none; } }
@keyframes a-slide-l { from { transform: translateX(-100%); } to { transform: none; } }
@keyframes a-pop { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }

/* ---------- shell ---------- */
.a-side { position: fixed; inset: 0 auto 0 0; width: var(--side-w); background: var(--a-side); color: #94a3b8; z-index: 40; display: flex; flex-direction: column; transition: width .2s, transform .2s; }
.a-side .a-brand { height: 64px; display: flex; align-items: center; gap: 10px; padding: 0 16px; border-bottom: 1px solid rgba(255,255,255,.08); text-decoration: none; }
.a-logo { width: 38px; height: 38px; border-radius: 8px; background: #fff; overflow: hidden; color: #fff; display: grid; place-items: center; flex: none; }
.a-brand b { display: block; color: #fff; font-size: 14px; letter-spacing: .02em; }
.a-brand small { display: block; font-size: 10px; letter-spacing: .15em; text-transform: uppercase; color: #94a3b8; }
.a-nav { flex: 1; overflow-y: auto; padding: 12px 8px; display: flex; flex-direction: column; gap: 2px; }
.a-nav a, .a-side-foot a, .a-side-foot button { position: relative; display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 8px; color: #94a3b8; text-decoration: none; font-weight: 500; font-size: 14px; background: none; border: 0; cursor: pointer; width: 100%; font-family: inherit; }
.a-nav a:hover, .a-side-foot a:hover, .a-side-foot button:hover { background: rgba(30,41,59,.75); color: #fff; }
.a-nav a.on { background: var(--a-side-hover); color: #fff; }
.a-nav a.on::before { content: ""; position: absolute; left: 0; top: 50%; width: 3px; height: 20px; transform: translateY(-50%); background: #818cf8; border-radius: 0 3px 3px 0; }
.a-nav a.on .a-ic { color: #a5b4fc; }
.a-nav .a-count { margin-left: auto; background: #6366f1; color: #fff; border-radius: 999px; font-size: 11px; padding: 1px 7px; }
.a-nav .a-sep { margin: 10px 12px 4px; font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: #64748b; }
.a-side-foot { padding: 8px; border-top: 1px solid rgba(255,255,255,.08); }
.a-main { margin-left: var(--side-w); min-height: 100vh; transition: margin .2s; }
.a-collapsed { --side-w: 72px; }
.a-collapsed .a-brand span, .a-collapsed .a-nav span, .a-collapsed .a-side-foot span, .a-collapsed .a-sep, .a-collapsed .a-count { display: none; }
.a-collapsed .a-nav a, .a-collapsed .a-side-foot a, .a-collapsed .a-side-foot button { justify-content: center; padding: 10px 0; }
.a-top { position: sticky; top: 0; z-index: 30; height: 64px; display: flex; align-items: center; gap: 10px; padding: 0 20px; background: color-mix(in srgb, var(--a-surface) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--a-line); }
.a-top .a-iconbtn { display: inline-grid; }
.a-gsearch { position: relative; flex: 1; max-width: 420px; }
.a-gsearch input { width: 100%; height: 38px; padding: 0 12px 0 36px; border: 1px solid var(--a-line); border-radius: 10px; background: var(--a-subtle); color: var(--a-fg); font: inherit; }
.a-gsearch .a-ic { position: absolute; left: 11px; top: 10px; color: var(--a-muted); width: 17px; height: 17px; }
.a-spacer { flex: 1; }
.a-content { padding: 24px; max-width: 1440px; margin: 0 auto; animation: a-fade .25s; }
.a-overlay { display: none; }
@media (max-width: 1023px) {
  .a-side { transform: translateX(-100%); width: 280px; --side-w: 280px; }
  .a-main { margin-left: 0 !important; }
  .a-nav-open .a-side { transform: none; animation: a-slide-l .2s; box-shadow: var(--a-shadow-lg); }
  .a-nav-open .a-overlay { display: block; position: fixed; inset: 0; background: rgba(15,23,42,.55); z-index: 35; animation: a-fade .2s; }
  .a-collapsed .a-brand span, .a-collapsed .a-nav span, .a-collapsed .a-side-foot span { display: inline; }
  .a-collapsed .a-nav a { justify-content: flex-start; padding: 9px 12px; }
  .a-content { padding: 16px; }
  .a-top { padding: 0 12px; }
  .a-hide-m { display: none !important; }
}
@media (min-width: 1024px) { .a-only-m { display: none !important; } }

/* ---------- primitives ---------- */
.a-page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.a-page-head h1 { margin: 0; font-size: 22px; letter-spacing: -.01em; }
.a-page-head p { margin: 2px 0 0; color: var(--a-muted); }
.a-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.a-card { background: var(--a-surface); border: 1px solid var(--a-line); border-radius: 14px; box-shadow: var(--a-shadow); }
.a-card.pad { padding: 16px; }
.a-card-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 14px 16px; border-bottom: 1px solid var(--a-line); }
.a-card-h h2 { margin: 0; font-size: 15px; }
.a-card-h p { margin: 2px 0 0; font-size: 12px; color: var(--a-muted); }
.a-stack > * + * { margin-top: 16px; }
.a-grid { display: grid; gap: 16px; }
.a-g2 { grid-template-columns: repeat(2, minmax(0,1fr)); } .a-g3 { grid-template-columns: repeat(3, minmax(0,1fr)); } .a-g4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
.a-g-main { grid-template-columns: minmax(0,2fr) minmax(0,1fr); }
@media (max-width: 1100px) { .a-g4 { grid-template-columns: repeat(2, minmax(0,1fr)); } .a-g-main, .a-g3 { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .a-g2, .a-g4 { grid-template-columns: 1fr; } }

.a-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 38px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--a-line); background: var(--a-surface); color: var(--a-fg); font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s, transform .05s; }
.a-btn:hover { background: var(--a-subtle); } .a-btn:active { transform: translateY(1px); }
.a-btn.primary { background: var(--a-accent); border-color: var(--a-accent); color: var(--a-accent-fg); } .a-btn.primary:hover { filter: brightness(1.08); background: var(--a-accent); }
.a-btn.danger { background: var(--a-red); border-color: var(--a-red); color: #fff; } .a-btn.danger:hover { background: var(--a-red); filter: brightness(1.08); }
.a-btn.ghost { border-color: transparent; background: transparent; } .a-btn.ghost:hover { background: var(--a-subtle); }
.a-btn.green { background: var(--a-green); border-color: var(--a-green); color: #fff; } .a-btn.green:hover { background: var(--a-green); filter: brightness(1.08); }
.a-btn.sm { height: 30px; padding: 0 10px; font-size: 12.5px; border-radius: 8px; }
.a-btn.icon { width: 34px; height: 34px; padding: 0; } .a-btn.icon.sm { width: 30px; height: 30px; }
.a-btn.block { width: 100%; } .a-btn[disabled] { opacity: .5; pointer-events: none; }
.a-iconbtn { width: 38px; height: 38px; border-radius: 10px; border: 0; background: none; color: var(--a-muted); cursor: pointer; place-items: center; } .a-iconbtn:hover { background: var(--a-subtle); color: var(--a-fg); }

.a-field { display: block; margin-bottom: 12px; }
.a-field > span, .a-label { display: block; font-size: 12.5px; font-weight: 600; margin-bottom: 5px; color: var(--a-fg); }
.a-field small { display: block; margin-top: 4px; color: var(--a-muted); font-size: 12px; }
.a-in, .a-sel, .a-ta { width: 100%; height: 38px; padding: 0 12px; border: 1px solid var(--a-line); border-radius: 10px; background: var(--a-surface); color: var(--a-fg); font: inherit; }
.a-ta { height: auto; padding: 10px 12px; resize: vertical; }
.a-in:focus, .a-sel:focus, .a-ta:focus { outline: 2px solid color-mix(in srgb, var(--a-accent) 45%, transparent); border-color: var(--a-accent); }
.a-sel { padding-right: 28px; }
.a-in.sm, .a-sel.sm { height: 32px; font-size: 13px; border-radius: 8px; }
.a-form-row { display: flex; gap: 12px; flex-wrap: wrap; } .a-form-row > * { flex: 1; min-width: 140px; }
.a-check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 500; }
.a-check input { width: 16px; height: 16px; accent-color: var(--a-accent); }
.a-switch { position: relative; width: 38px; height: 22px; display: inline-block; flex: none; }
.a-switch input { opacity: 0; position: absolute; inset: 0; margin: 0; cursor: pointer; z-index: 2; }
.a-switch i { position: absolute; inset: 0; background: var(--a-line); border-radius: 999px; transition: background .15s; }
.a-switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .15s; box-shadow: 0 1px 2px rgba(0,0,0,.3); }
.a-switch input:checked + i { background: var(--a-green); } .a-switch input:checked + i::after { transform: translateX(16px); }

.a-badge { display: inline-flex; align-items: center; gap: 6px; padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; background: color-mix(in srgb, var(--c, #6b7280) 13%, transparent); color: var(--c, #6b7280); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--c, #6b7280) 25%, transparent); }
.a-badge.dot::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.t-gray { --c: #6b7280; } .t-green { --c: #059669; } .t-amber { --c: #d97706; } .t-red { --c: #dc2626; } .t-blue { --c: #2563eb; } .t-violet { --c: #7c3aed; } .t-indigo { --c: #4f46e5; } .t-sky { --c: #0284c7; } .t-pink { --c: #db2777; }
:root[data-theme="dark"] .t-gray { --c: #cbd5e1; } :root[data-theme="dark"] .t-green { --c: #6ee7b7; } :root[data-theme="dark"] .t-amber { --c: #fcd34d; } :root[data-theme="dark"] .t-red { --c: #fca5a5; } :root[data-theme="dark"] .t-blue { --c: #93c5fd; } :root[data-theme="dark"] .t-violet { --c: #c4b5fd; } :root[data-theme="dark"] .t-indigo { --c: #a5b4fc; } :root[data-theme="dark"] .t-sky { --c: #7dd3fc; } :root[data-theme="dark"] .t-pink { --c: #f9a8d4; }

/* stat cards */
.a-stat { padding: 16px; transition: box-shadow .15s, transform .15s; } .a-stat:hover { box-shadow: 0 6px 18px rgba(15,23,42,.08); transform: translateY(-1px); }
.a-stat .top { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; }
.a-stat .lbl { font-size: 12px; font-weight: 600; color: var(--a-muted); }
.a-stat .val { font-size: 26px; font-weight: 700; letter-spacing: -.02em; margin-top: 4px; }
.a-stat .ico { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: color-mix(in srgb, var(--c, #4f46e5) 12%, transparent); color: var(--c, #4f46e5); }
.a-stat .foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 10px; margin-top: 10px; font-size: 12px; color: var(--a-muted); }
.a-stat svg.spark { width: 84px; height: 30px; }

/* tabs */
.a-tabs { display: inline-flex; gap: 4px; padding: 4px; background: var(--a-subtle); border: 1px solid var(--a-line); border-radius: 12px; flex-wrap: wrap; }
.a-tab { display: inline-flex; align-items: center; gap: 7px; padding: 7px 14px; border-radius: 9px; border: 0; background: none; color: var(--a-muted); font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; }
.a-tab:hover { color: var(--a-fg); } .a-tab.on { background: var(--a-surface); color: var(--a-fg); box-shadow: 0 1px 3px rgba(0,0,0,.1); }
.a-tab em { font-style: normal; font-size: 11px; padding: 1px 7px; border-radius: 999px; background: var(--a-line); color: var(--a-muted); } .a-tab.on em { background: var(--a-accent-soft); color: var(--a-accent); }

/* toolbar + table */
.a-toolbar { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--a-line); align-items: center; }
.a-search { position: relative; flex: 1 1 240px; max-width: 340px; } .a-search .a-ic { position: absolute; left: 10px; top: 8px; width: 16px; height: 16px; color: var(--a-muted); }
.a-search input { width: 100%; height: 34px; padding: 0 10px 0 32px; border: 1px solid var(--a-line); border-radius: 9px; background: var(--a-surface); color: var(--a-fg); font: inherit; }
.a-tablewrap { overflow-x: auto; }
table.a-table { width: 100%; border-collapse: collapse; min-width: 640px; }
.a-table th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--a-muted); font-weight: 600; background: var(--a-subtle); padding: 10px 14px; border-bottom: 1px solid var(--a-line); white-space: nowrap; }
.a-table th[data-sort] { cursor: pointer; user-select: none; } .a-table th[data-sort]:hover { color: var(--a-fg); }
.a-table th .a-ic { width: 12px; height: 12px; vertical-align: -2px; margin-left: 3px; opacity: .45; } .a-table th.asc .a-ic, .a-table th.desc .a-ic { opacity: 1; }
.a-table td { padding: 11px 14px; border-bottom: 1px solid var(--a-line); vertical-align: middle; }
.a-table tbody tr:last-child td { border-bottom: 0; } .a-table tbody tr:hover { background: color-mix(in srgb, var(--a-subtle) 80%, transparent); }
.a-table tr[data-drawer] { cursor: pointer; }
.a-table .r { text-align: right; } .a-table .c { text-align: center; }
.a-table .strong { font-weight: 600; } .a-table .acc { color: var(--a-accent); font-weight: 600; }
.a-pager { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 14px; border-top: 1px solid var(--a-line); color: var(--a-muted); font-size: 13px; }
.a-pager .pg { display: flex; gap: 4px; }
.a-pager .pg button { min-width: 30px; height: 30px; border: 0; border-radius: 8px; background: none; color: var(--a-muted); font: inherit; font-weight: 600; cursor: pointer; } .a-pager .pg button:hover { background: var(--a-subtle); } .a-pager .pg button.on { background: var(--a-accent); color: var(--a-accent-fg); } .a-pager .pg button[disabled] { opacity: .4; pointer-events: none; }
.a-empty { text-align: center; padding: 44px 16px; color: var(--a-muted); } .a-empty .a-ic { width: 38px; height: 38px; opacity: .5; margin-bottom: 8px; } .a-empty h3 { margin: 0 0 4px; color: var(--a-fg); font-size: 15px; }
.a-thumb { width: 40px; height: 40px; border-radius: 9px; object-fit: cover; background: var(--a-subtle); border: 1px solid var(--a-line); flex: none; display: inline-grid; place-items: center; color: var(--a-muted); }
.a-thumbs { display: inline-flex; } .a-thumbs .a-thumb { margin-left: -10px; border: 2px solid var(--a-surface); } .a-thumbs .a-thumb:first-child { margin-left: 0; }
.a-cell { display: flex; align-items: center; gap: 10px; min-width: 0; } .a-cell b { display: block; font-weight: 600; } .a-cell small { display: block; color: var(--a-muted); font-size: 12px; }
@media (max-width: 767px) { .a-hide-s { display: none; } }

/* menu */
.a-menu { position: relative; display: inline-block; }
.a-menu-list { position: absolute; right: 0; top: calc(100% + 4px); min-width: 190px; background: var(--a-surface); border: 1px solid var(--a-line); border-radius: 12px; box-shadow: var(--a-shadow-lg); padding: 5px; z-index: 60; display: none; animation: a-pop .12s; }
.a-menu.open .a-menu-list { display: block; }
.a-menu-list a, .a-menu-list button { display: flex; align-items: center; gap: 9px; width: 100%; padding: 8px 10px; border: 0; background: none; border-radius: 8px; font: inherit; color: var(--a-fg); text-align: left; cursor: pointer; text-decoration: none; } .a-menu-list a:hover, .a-menu-list button:hover { background: var(--a-subtle); } .a-menu-list .a-ic { width: 16px; height: 16px; color: var(--a-muted); }

/* drawer + modal */
.a-drawer-ov, .a-modal-ov { position: fixed; inset: 0; background: rgba(15,23,42,.55); z-index: 80; animation: a-fade .15s; display: flex; }
.a-drawer-ov { justify-content: flex-end; }
.a-drawer { width: min(680px, 100%); height: 100%; background: var(--a-surface); box-shadow: var(--a-shadow-lg); display: flex; flex-direction: column; animation: a-slide-r .22s; }
.a-drawer-h { padding: 16px 20px; border-bottom: 1px solid var(--a-line); display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.a-drawer-h h2 { margin: 0; font-size: 17px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; } .a-drawer-h p { margin: 3px 0 0; color: var(--a-muted); font-size: 13px; }
.a-drawer-b { flex: 1; overflow-y: auto; }
.a-sec { padding: 16px 20px; border-bottom: 1px solid var(--a-line); } .a-sec:last-child { border-bottom: 0; }
.a-sec > h3 { margin: 0 0 10px; font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--a-muted); }
.a-modal-ov { align-items: center; justify-content: center; padding: 16px; }
.a-modal { width: min(440px, 100%); background: var(--a-surface); border-radius: 16px; padding: 22px; box-shadow: var(--a-shadow-lg); animation: a-pop .18s; }
.a-modal.wide { width: min(640px, 100%); max-height: 90vh; overflow: auto; }
.a-modal h3 { margin: 0 0 6px; font-size: 17px; } .a-modal p { margin: 0 0 18px; color: var(--a-muted); }
.a-modal .a-actions { justify-content: flex-end; }
.a-kv { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; } .a-kv dt { color: var(--a-muted); font-size: 12px; } .a-kv dd { margin: 2px 0 0; font-weight: 500; word-break: break-word; }
.a-items { list-style: none; margin: 0; padding: 0; border: 1px solid var(--a-line); border-radius: 12px; } .a-items li { display: flex; gap: 12px; align-items: center; padding: 10px 12px; border-bottom: 1px solid var(--a-line); } .a-items li:last-child { border-bottom: 0; } .a-items img.a-thumb { width: 52px; height: 52px; }
.a-sum { margin: 12px 0 0; } .a-sum div { display: flex; justify-content: space-between; padding: 4px 0; } .a-sum .tot { border-top: 1px solid var(--a-line); margin-top: 6px; padding-top: 8px; font-weight: 700; font-size: 15px; }
.a-note { border-radius: 12px; padding: 12px; background: var(--a-subtle); border: 1px solid var(--a-line); }

/* toast */
.a-toasts { position: fixed; right: 16px; bottom: 16px; z-index: 120; display: flex; flex-direction: column; gap: 8px; max-width: min(380px, calc(100vw - 32px)); }
.a-toast { display: flex; gap: 10px; align-items: flex-start; background: var(--a-surface); border: 1px solid var(--a-line); border-left: 4px solid var(--c, var(--a-accent)); border-radius: 12px; padding: 11px 14px; box-shadow: var(--a-shadow-lg); animation: a-pop .2s; }
.a-toast.ok { --c: var(--a-green); } .a-toast.err { --c: var(--a-red); }

/* progress, charts, misc */
.a-bar { height: 8px; border-radius: 999px; background: var(--a-subtle); overflow: hidden; border: 1px solid var(--a-line); } .a-bar i { display: block; height: 100%; border-radius: 999px; background: var(--c, var(--a-accent)); transition: width .6s; }
.a-chart { position: relative; width: 100%; } .a-chart svg { width: 100%; height: 100%; display: block; overflow: visible; }
.a-chart .tip { position: absolute; pointer-events: none; background: var(--a-fg); color: var(--a-page); padding: 6px 9px; border-radius: 8px; font-size: 12px; white-space: nowrap; transform: translate(-50%, -110%); opacity: 0; transition: opacity .1s; z-index: 5; }
.a-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 10px; font-size: 12.5px; } .a-legend i { display: inline-block; width: 9px; height: 9px; border-radius: 3px; margin-right: 6px; }
.a-range { display: inline-flex; gap: 4px; padding: 3px; background: var(--a-surface); border: 1px solid var(--a-line); border-radius: 10px; } .a-range a { padding: 5px 11px; border-radius: 7px; text-decoration: none; font-weight: 600; font-size: 13px; color: var(--a-muted); } .a-range a.on { background: var(--a-accent); color: var(--a-accent-fg); }
.a-chip { display: inline-flex; gap: 6px; align-items: center; padding: 3px 10px; border-radius: 999px; background: var(--a-accent-soft); color: var(--a-accent); font-size: 12px; font-weight: 600; }
.a-itemcard { display: flex; gap: 12px; padding: 12px; border: 1px solid var(--a-line); border-radius: 12px; background: var(--a-subtle); position: relative; margin-bottom: 10px; }
.a-itemcard .a-thumb { width: 64px; height: 64px; }
.a-slot-col { border: 1px solid var(--a-line); border-radius: 14px; background: var(--a-surface); } .a-slot-col h3 { margin: 0; padding: 12px 14px; font-size: 14px; border-bottom: 1px solid var(--a-line); display: flex; justify-content: space-between; align-items: center; }
.a-del { padding: 12px 14px; border-bottom: 1px solid var(--a-line); } .a-del:last-child { border-bottom: 0; }
.a-upl { border: 2px dashed var(--a-line); border-radius: 12px; padding: 14px; text-align: center; color: var(--a-muted); cursor: pointer; display: block; } .a-upl:hover { border-color: var(--a-accent); color: var(--a-accent); } .a-upl input { display: none; }
.a-gal { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; } .a-gal figure { margin: 0; border: 1px solid var(--a-line); border-radius: 12px; overflow: hidden; background: var(--a-subtle); } .a-gal img { width: 100%; height: 110px; object-fit: cover; display: block; } .a-gal figcaption { display: flex; gap: 4px; padding: 6px; justify-content: space-between; }
.a-pgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; padding: 14px; } .a-pcard { border: 1px solid var(--a-line); border-radius: 14px; overflow: hidden; background: var(--a-surface); transition: box-shadow .15s, transform .15s; cursor: pointer; } .a-pcard:hover { box-shadow: 0 8px 22px rgba(15,23,42,.1); transform: translateY(-2px); } .a-pcard img, .a-pcard .ph { width: 100%; aspect-ratio: 4/3; object-fit: cover; background: var(--a-subtle); display: grid; place-items: center; color: var(--a-muted); } .a-pcard .bd { padding: 10px 12px; }
.a-hero-login { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.a-hero-login .l { background: linear-gradient(140deg, #312e81, #4f46e5 55%, #7c3aed); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.a-hero-login .r { display: grid; place-items: center; padding: 24px; background: var(--a-page); }
@media (max-width: 860px) { .a-hero-login { grid-template-columns: 1fr; } .a-hero-login .l { display: none; } }
@media print { .a-side, .a-top, .a-actions, .a-toolbar, .a-pager, .a-toasts { display: none !important; } .a-main { margin: 0 !important; } }

.a-lrow { padding: 12px 14px; border-bottom: 1px solid var(--a-line); transition: background .15s; } .a-lrow:last-child { border-bottom: 0; } .a-lrow.dirty { background: var(--a-accent-soft); } .a-lrow.off .a-in { opacity: .65; }
.a-lrow .a-rf { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; } .a-lrow .a-rf .a-in { flex: 1 1 150px; min-width: 120px; }
.a-lrow .meta { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 6px; font-size: 12.5px; color: var(--a-muted); }

.a-chat { display: flex; flex-direction: column; gap: 8px; max-height: 340px; overflow-y: auto; padding: 4px; }
.a-bub { max-width: 82%; padding: 8px 11px; border-radius: 14px; background: var(--a-subtle); border: 1px solid var(--a-line); white-space: pre-wrap; word-break: break-word; font-size: 13.5px; }
.a-bub.out { align-self: flex-end; background: var(--a-accent-soft); border-color: color-mix(in srgb, var(--a-accent) 25%, transparent); }
.a-bub small { display: block; margin-top: 3px; color: var(--a-muted); font-size: 11px; }
.a-avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--a-accent-soft); color: var(--a-accent); display: inline-grid; place-items: center; font-weight: 700; flex: none; }

.a-card-h h2 .a-ic, .a-page-head h1 .a-ic, .a-sec > h3 .a-ic, .a-empty h3 .a-ic, b > .a-ic, .a-muted > .a-ic, .a-cell .a-ic { vertical-align: -3px; margin-right: 4px; }
.a-tab .a-ic { margin-right: 0; width: 16px; height: 16px; }
.a-nav a, .a-btn, .a-badge { white-space: nowrap; }
.a-badge .a-ic { width: 13px; height: 13px; }

.a-bub.fail { border-color: var(--a-red); background: color-mix(in srgb, var(--a-red) 8%, var(--a-surface)); }

/* order form */
.a-err { color: var(--a-red); font-size: 12.5px; margin-top: 4px; min-height: 0; } .a-err:empty { display: none; }
.a-err.block { padding: 10px 12px; border: 1px solid var(--a-red); border-radius: 10px; background: color-mix(in srgb, var(--a-red) 8%, var(--a-surface)); margin-bottom: 14px; font-size: 13.5px; }
.a-combo { position: relative; } .a-combo .cb-input { padding-right: 34px; }
.cb-clear { position: absolute; right: 6px; top: 6px; width: 26px; height: 26px; border: 0; border-radius: 8px; background: none; color: var(--a-muted); cursor: pointer; } .cb-clear:hover { background: var(--a-subtle); color: var(--a-fg); }
.cb-list { position: absolute; left: 0; right: 0; top: calc(100% + 4px); max-height: 320px; overflow-y: auto; background: var(--a-surface); border: 1px solid var(--a-line); border-radius: 12px; box-shadow: var(--a-shadow-lg); z-index: 70; padding: 4px; }
.cb-opt { display: flex; align-items: center; gap: 10px; padding: 7px 9px; border-radius: 9px; cursor: pointer; } .cb-opt:hover, .cb-opt.on { background: var(--a-accent-soft); }
.cb-opt .a-thumb { width: 34px; height: 34px; font-size: 13px; } .cb-t { flex: 1; min-width: 0; } .cb-t b { display: block; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .cb-t small { display: block; color: var(--a-muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .cb-p { font-weight: 600; white-space: nowrap; }
.cb-extra { border-top: 1px dashed var(--a-line); margin-top: 2px; }
.cb-meta { color: var(--a-muted); font-size: 12px; display: block; margin-top: 3px; } .f-default { display: block; margin-top: 3px; color: var(--a-muted); font-size: 12px; } .f-default a { color: var(--a-accent); }
.a-picks { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; } .a-pick { position: relative; display: block; border: 1px solid var(--a-line); border-radius: 12px; overflow: hidden; background: var(--a-subtle); cursor: pointer; } .a-pick img { width: 100%; height: 88px; object-fit: cover; display: block; } .a-pick small { display: block; padding: 4px 6px; font-size: 11px; color: var(--a-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .a-pick input { position: absolute; top: 6px; left: 6px; width: 18px; height: 18px; accent-color: var(--a-accent); z-index: 2; } .a-pick:has(input:checked) { border-color: var(--a-accent); box-shadow: 0 0 0 2px var(--a-accent-soft); }
.a-spin { display: inline-block; width: 14px; height: 14px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: a-rot .7s linear infinite; vertical-align: -2px; } @keyframes a-rot { to { transform: rotate(360deg); } }
.sl { display: flex; justify-content: space-between; gap: 8px; padding: 2px 0; }
.a-lb { position: fixed; inset: 0; z-index: 130; background: rgba(2,6,23,.86); display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 20px; gap: 12px; animation: a-fade .15s; } .a-lb img { max-width: min(96vw, 1100px); max-height: 80vh; border-radius: 12px; background: #fff; } .a-lb .cap { color: #e2e8f0; max-width: 700px; text-align: center; white-space: pre-wrap; }
@media (max-width: 1000px) { #orderForm { grid-template-columns: 1fr !important; } #orderForm .sticky-col { position: static !important; } }
@media (max-width: 640px) {
  /* order form on phones: full-width search, readable (wrapping) product names, touch-sized clear button */
  .a-itemcard { flex-direction: column; gap: 8px; }
  .a-itemcard > .a-thumb { display: none; }
  .a-itemcard.has-img > .a-thumb { display: flex; width: 56px; height: 56px; }
  .cb-clear { width: 36px; height: 36px; top: 2px; right: 2px; }
  .cb-list { max-height: 50vh; }
  .cb-opt { padding: 10px 8px; }
  .cb-t b, .cb-t small { white-space: normal; }
}
