/* WallBox — app.css
   Hand-written additions layered on top of the pre-compiled style.css.
   Reuses the same design tokens (obsidian/graphite/titanium/accent) for
   forms, tables, alerts, the admin dashboard, and cart/checkout affordances
   introduced by the backend build-out. No build step — plain CSS. */

/* Tells the browser this whole site is dark-themed, so native form controls
   (select dropdown popups, checkboxes, scrollbars, etc.) render with
   dark-appropriate default colors instead of the browser/OS light-mode
   defaults — fixes the admin Category <select> being hard to read. */
html { color-scheme: dark; }

/* Product page "Technical Specifications" cards — a thin accent-colored top
   edge gives each spec its own visually separated card instead of a plain
   stacked list. */
.spec-card { position: relative; overflow: hidden; }
.spec-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, rgba(94, 234, 212, 0.6), transparent);
}

/* Inter and Space Grotesk have no Georgian (Mkhedruli) letterforms, so
   Georgian text was silently falling back to whatever generic font the
   visitor's OS happens to ship — inconsistent with the rest of the design.
   Appending Noto Sans Georgian to the same stacks fixes this for free: the
   browser only reaches for it on characters Inter/Space Grotesk can't
   render, so Latin text is completely unaffected. */
.font-display { font-family: 'Space Grotesk', 'Noto Sans Georgian', system-ui, sans-serif; }
.font-sans { font-family: 'Inter', 'Noto Sans Georgian', system-ui, sans-serif; }

/* #spotlight-track's height is set via Tailwind arbitrary-value classes
   (h-[356px] / sm:h-[372px]) that were introduced when the card was made
   taller to fix name-overflow — but this project has no live Tailwind build,
   so any class not already in the pre-compiled style.css simply has no
   effect. Without an explicit height here the track (and everything
   absolutely-positioned/h-full inside it) collapsed to 0px, which is why the
   card rendered as an empty sliver: only content with its own intrinsic
   height (the badge/category row) stayed visible, and overflow-hidden
   clipped everything else. */
.h-\[356px\] { height: 356px; }
@media (min-width: 640px) {
  .sm\:h-\[372px\] { height: 372px; }
}

/* Hero spotlight card — a breathing glow keeps the card feeling alive at
   rest. Deliberately box-shadow only, no transform/animated pseudo-element:
   this card uses glass-strong (backdrop-filter: blur), and animating
   `transform` on the same element — or a pseudo-element inside it — is a
   known WebKit/Safari rendering hazard where the blurred content can simply
   fail to composite and render invisible. Cost some visual flourish for
   guaranteed-correct rendering everywhere. */
.spotlight-card-anim { animation: spotlightGlow 4s ease-in-out infinite; }

@keyframes spotlightGlow {
  0%, 100% { box-shadow: 0 0 60px -15px rgba(94, 234, 212, 0.35); }
  50% { box-shadow: 0 0 75px -12px rgba(94, 234, 212, 0.55); }
}

.spotlight-nav-btn {
  transform: translateY(-50%) scale(1);
  transition: transform 0.2s ease, color 0.2s ease, background-color 0.2s ease;
}
.spotlight-nav-btn:hover { transform: translateY(-50%) scale(1.1); }
.spotlight-nav-btn:active { transform: translateY(-50%) scale(0.88); }

/* A couple of utility classes referenced by existing templates but missing
   from the original compiled style.css (harmless gap — filled in here). */
.text-titanium-500 { color: #6d717b; }
.text-titanium-600 { color: #4f525a; }
.text-red-400 { color: #f87171; }
.text-red-300 { color: #fca5a5; }
.hover\:text-red-300:hover { color: #fca5a5; }
.line-through { text-decoration: line-through; }
.line-clamp-2 { overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.items-end { align-items: flex-end; }
.z-20 { z-index: 20; }
.select-none { user-select: none; }
.touch-pan-y { touch-action: pan-y; }

/* ---------------------------------------------------------------------- */
/* Animated brand logotype (header, footer, admin sidebar)                */
/* ---------------------------------------------------------------------- */
.brand-logo {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  overflow: hidden;
  padding: 2px 1px;
  transition: transform 0.25s ease;
}
.brand-logo:hover { transform: scale(1.05); }

.brand-logo-text {
  background: linear-gradient(110deg, #c7cad1 25%, #ffffff 50%, #c7cad1 75%);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: brandShimmer 6s ease-in-out infinite;
}
@keyframes brandShimmer {
  0%, 40% { background-position: 200% 0; }
  60%, 100% { background-position: -200% 0; }
}

/* "BOX" reads like a charging indicator rather than a generic glow: it sits
   dim most of the cycle, then briefly flashes bright — an infrequent,
   purposeful pulse instead of a constant ambient breathing effect. */
.brand-logo-accent {
  color: #5eead4;
  animation: brandCharge 4.5s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}
@keyframes brandCharge {
  0%, 70%, 100% { text-shadow: 0 0 4px rgba(94, 234, 212, 0.25); }
  78% { text-shadow: 0 0 18px rgba(94, 234, 212, 1), 0 0 36px rgba(94, 234, 212, 0.6); }
  88% { text-shadow: 0 0 6px rgba(94, 234, 212, 0.3); }
}

/* A one-shot energy sweep on hover — current flowing through the logo, tying
   into the EV-charging brand — instead of a diagonal glint running on a
   permanent loop whether or not anyone's actually looking at it. */
.brand-logo::after {
  content: "";
  position: absolute;
  top: -60%;
  left: -60%;
  width: 30%;
  height: 220%;
  background: linear-gradient(115deg, transparent 25%, rgba(255, 255, 255, 0.85) 50%, transparent 75%);
  transform: skewX(-20deg);
  opacity: 0;
  pointer-events: none;
}
.brand-logo:hover::after {
  animation: brandShine 0.7s ease-out;
}
@keyframes brandShine {
  0% { left: -60%; opacity: 1; }
  100% { left: 130%; opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .brand-logo-text, .brand-logo-accent, .brand-logo::after { animation: none; }
}

/* ---------------------------------------------------------------------- */
/* Homepage "Shop by Category" tiles                                       */
/* ---------------------------------------------------------------------- */
.category-tile-grid {
  background-image:
    linear-gradient(rgba(94, 234, 212, 0.14) 1px, transparent 1px),
    linear-gradient(90deg, rgba(94, 234, 212, 0.14) 1px, transparent 1px);
  background-size: 16px 16px;
  -webkit-mask-image: radial-gradient(circle at 50% 0%, black, transparent 75%);
  mask-image: radial-gradient(circle at 50% 0%, black, transparent 75%);
}

/* Horizontal swipe row, same on every device (not just mobile) — fixed-ish
   item widths (min() against the viewport) mean the next item always peeks
   in from the edge, which is what visually reads as "swipeable" without
   needing dots or JS. */
.swipe-row {
  display: flex;
  flex-wrap: nowrap;
  gap: 1rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 10px 4px 8px;
}
.swipe-row::-webkit-scrollbar { display: none; }
.swipe-row > * {
  scroll-snap-align: start;
  flex: 0 0 auto;
}
.swipe-row.swipe-row-cards > * { width: min(320px, 82vw); }
.swipe-row.swipe-row-tiles > * { width: min(160px, 40vw); }

.swipe-row { cursor: grab; }
.swipe-row.swipe-row-grabbing { cursor: grabbing; scroll-snap-type: none; }

.swipe-hint {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #6d717b;
  margin-top: 10px;
}
@keyframes swipeHintNudge {
  0%, 100% { transform: translateX(0); opacity: 0.6; }
  50% { transform: translateX(4px); opacity: 1; }
}
.swipe-hint-icon { display: inline-flex; animation: swipeHintNudge 1.4s ease-in-out infinite; }

/* Mobile-only swipe row: unlike .swipe-row above, this keeps its normal grid
   layout on tablet/desktop (where everything already fits fine) and only
   switches to a horizontal peeking-card scroller below the sm breakpoint —
   for sections like the trust-badges row where 4 columns is the right call
   on wider screens but too tall stacked full-width on a phone. */
@media (max-width: 639px) {
  .swipe-row-mobile {
    display: flex;
    flex-wrap: nowrap;
    gap: 1rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 4px 4px 10px;
    background: none;
    border: none;
    border-radius: 0;
  }
  .swipe-row-mobile::-webkit-scrollbar { display: none; }
  .swipe-row-mobile > * {
    scroll-snap-align: start;
    flex: 0 0 auto;
    width: min(280px, 78vw);
    border: 1px solid hsla(0, 0%, 100%, 0.07);
    border-radius: 20px;
  }
}

/* ---------------------------------------------------------------------- */
/* Add-to-cart "fly" animation + cart icon bump                           */
/* ---------------------------------------------------------------------- */
.cart-fly-item {
  position: fixed;
  width: 44px;
  height: 44px;
  border-radius: 9999px;
  background-color: #5eead4;
  background-size: cover;
  background-position: center;
  box-shadow: 0 8px 30px -6px rgba(0, 0, 0, 0.5);
  z-index: 9999;
  pointer-events: none;
  transition: transform 0.65s cubic-bezier(0.22, 0.9, 0.3, 1), opacity 0.65s ease;
}
@keyframes cartBump {
  0% { transform: scale(1); }
  40% { transform: scale(1.3); }
  100% { transform: scale(1); }
}
.cart-bump { animation: cartBump 0.4s ease; }

/* ---------------------------------------------------------------------- */
/* Chat widget (site visitor <-> Telegram bridge)                         */
/* ---------------------------------------------------------------------- */
.chat-bubble {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 9990;
  width: 56px;
  height: 56px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #5eead4;
  color: #08090b;
  border: none;
  cursor: pointer;
  box-shadow: 0 12px 30px -8px rgba(94, 234, 212, 0.5);
}
.chat-bubble:hover { transform: translateY(-2px) scale(1.04); }

@keyframes chatBubblePulse {
  0%, 100% { transform: scale(1); }
  30% { transform: scale(1.18); }
  60% { transform: scale(0.94); }
}
.chat-bubble-alert { animation: chatBubblePulse 0.55s ease; }

.chat-unread-dot {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 12px;
  height: 12px;
  border-radius: 9999px;
  background: #f87171;
  border: 2px solid #08090b;
}
@keyframes chatDotPing {
  0% { box-shadow: 0 0 0 0 rgba(248, 113, 113, 0.65); }
  100% { box-shadow: 0 0 0 9px rgba(248, 113, 113, 0); }
}
.chat-unread-dot:not(.hidden) { animation: chatDotPing 1.4s ease-out infinite; }

/* Proactive teaser bubble — pops up a few seconds after arrival so a first-
   time visitor doesn't feel like they're the only one on the site. Purely a
   nudge: dismissible, and clicking it just opens the same chat panel. */
.chat-teaser {
  position: fixed;
  right: 24px;
  bottom: 92px;
  z-index: 9989;
  max-width: 230px;
  padding: 12px 22px 12px 16px;
  border-radius: 16px;
  border: 1px solid hsla(0, 0%, 100%, 0.1);
  background: #14161a;
  box-shadow: 0 20px 50px -15px rgba(0, 0, 0, 0.55);
  cursor: pointer;
  animation: chatTeaserIn 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.chat-teaser.hidden { display: none; }
.chat-teaser::after {
  content: "";
  position: absolute;
  bottom: -7px;
  right: 22px;
  width: 14px;
  height: 14px;
  background: #14161a;
  border-right: 1px solid hsla(0, 0%, 100%, 0.1);
  border-bottom: 1px solid hsla(0, 0%, 100%, 0.1);
  transform: rotate(45deg);
}
.chat-teaser p {
  margin: 0;
  font-size: 13px;
  line-height: 1.4;
  color: #e4e4e7;
}
.chat-teaser-close {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  background: transparent;
  border: none;
  padding: 0;
  color: rgba(255, 255, 255, 0.45);
  cursor: pointer;
}
.chat-teaser-close:hover { color: #fff; background: hsla(0, 0%, 100%, 0.08); }

@keyframes chatTeaserIn {
  0% { opacity: 0; transform: translateY(10px) scale(0.94); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

.chat-panel {
  position: fixed;
  right: 24px;
  bottom: 92px;
  z-index: 9991;
  width: 340px;
  max-width: calc(100vw - 48px);
  height: 460px;
  max-height: calc(100vh - 140px);
  display: flex;
  flex-direction: column;
  border-radius: 24px;
  border: 1px solid hsla(0, 0%, 100%, 0.1);
  background: #0c0d10;
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.6);
  overflow: hidden;
}
/* Higher specificity than .chat-panel alone, so the "hidden" utility class
   (same specificity as display:flex above) reliably wins when both are present. */
.chat-panel.hidden { display: none; }

@keyframes chatPanelIn {
  0% { opacity: 0; transform: translateY(16px) scale(0.96); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}
.chat-panel-opening { animation: chatPanelIn 0.28s cubic-bezier(0.2, 0.8, 0.2, 1); }

.chat-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid hsla(0, 0%, 100%, 0.07);
}
.chat-intake {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
  padding: 20px;
}
.chat-intake-text { font-size: 13px; line-height: 1.6; color: #a9adb6; }
.chat-intake-form { display: flex; flex-direction: column; gap: 10px; }
.chat-intake-form input {
  background: hsla(0, 0%, 100%, 0.03);
  border: 1px solid hsla(0, 0%, 100%, 0.1);
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 13px;
  color: #fff;
}
.chat-intake-form input::placeholder { color: #5f6672; }
.chat-intake-form input:focus { outline: none; border-color: rgba(94, 234, 212, 0.4); }
.chat-intake-form select {
  background: hsla(0, 0%, 100%, 0.03);
  border: 1px solid hsla(0, 0%, 100%, 0.1);
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 13px;
  color: #fff;
  color-scheme: dark;
}
.chat-intake-form select:invalid { color: #5f6672; }
.chat-intake-form select:focus { outline: none; border-color: rgba(94, 234, 212, 0.4); }
.chat-intake-form select option { color: #0c0d10; background-color: #ffffff; }

.chat-phone-input {
  display: flex;
  align-items: stretch;
  background: hsla(0, 0%, 100%, 0.03);
  border: 1px solid hsla(0, 0%, 100%, 0.1);
  border-radius: 12px;
  overflow: hidden;
}
.chat-phone-input:focus-within { border-color: rgba(94, 234, 212, 0.4); }
.chat-phone-prefix {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 10px 10px 14px;
  font-size: 13px;
  color: #a9adb6;
  border-right: 1px solid hsla(0, 0%, 100%, 0.08);
  white-space: nowrap;
}
.chat-phone-input input {
  flex: 1;
  min-width: 0;
  border: none;
  background: none;
  padding: 10px 14px;
  font-size: 13px;
  color: #fff;
}
.chat-phone-input input::placeholder { color: #5f6672; }
.chat-phone-input input:focus { outline: none; }
.chat-intake-error { font-size: 12px; color: #f87171; margin-top: -4px; }

.chat-thread {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
/* Same specificity fix as .chat-panel.hidden above. */
.chat-intake.hidden, .chat-thread.hidden { display: none; }

.chat-panel-close {
  color: #8b8f99;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
}
.chat-panel-close:hover { color: #fff; }

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
@keyframes chatMessageIn {
  0% { opacity: 0; transform: translateY(8px) scale(0.96); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}
.chat-message {
  max-width: 80%;
  padding: 8px 12px;
  border-radius: 14px;
  font-size: 13px;
  line-height: 1.5;
  overflow-wrap: break-word;
  animation: chatMessageIn 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.chat-message-visitor {
  align-self: flex-end;
  background: #5eead4;
  color: #08090b;
  border-bottom-right-radius: 4px;
}
.chat-message-admin {
  align-self: flex-start;
  background: #17181c;
  color: #e5e7ea;
  border: 1px solid hsla(0, 0%, 100%, 0.07);
  border-bottom-left-radius: 4px;
}

.chat-form {
  display: flex;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid hsla(0, 0%, 100%, 0.07);
}
.chat-form input {
  flex: 1;
  min-width: 0;
  background: hsla(0, 0%, 100%, 0.03);
  border: 1px solid hsla(0, 0%, 100%, 0.1);
  border-radius: 9999px;
  padding: 8px 14px;
  font-size: 13px;
  color: #fff;
}
.chat-form input::placeholder { color: #5f6672; }
.chat-form input:focus { outline: none; border-color: rgba(94, 234, 212, 0.4); }
.chat-form button {
  width: 36px;
  height: 36px;
  border-radius: 9999px;
  background: #5eead4;
  color: #08090b;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}

/* Tactile press feedback on every chat widget button — bubble, close,
   "Start Chat", send — so pressing any of them visibly reacts, not just
   opening the bubble. */
.chat-bubble,
.chat-panel-close,
.chat-intake-form button,
.chat-form button {
  transition: transform 0.15s ease;
}
.chat-bubble:active,
.chat-panel-close:active,
.chat-intake-form button:active,
.chat-form button:active {
  transform: scale(0.88);
}

@media (max-width: 480px) {
  .chat-panel { width: calc(100vw - 32px); right: 16px; bottom: 84px; }
  .chat-bubble { right: 16px; bottom: 16px; }
  /* Keep the teaser a small corner bubble on phones — never a banner that
     covers the page. Capped narrower than the panel itself and nudged left
     so its speech-bubble tail still lines up over the chat button. */
  .chat-teaser {
    right: 16px;
    bottom: 84px;
    max-width: min(190px, calc(100vw - 88px));
    padding: 10px 20px 10px 14px;
  }
  .chat-teaser::after { right: 18px; }
  .chat-teaser p { font-size: 12.5px; }
}

/* ---------------------------------------------------------------------- */
/* Forms                                                                   */
/* ---------------------------------------------------------------------- */
.form-label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #a9adb6;
}

.form-input {
  width: 100%;
  border-radius: 14px;
  border: 1px solid hsla(0, 0%, 100%, 0.1);
  background: hsla(0, 0%, 100%, 0.03);
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  color: #ffffff;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.form-input::placeholder { color: #5f6672; }

/* Checkout's phone field — Georgian flag + "+995" prefix, matching the chat
   widget's phone input pattern for visual consistency across the site. */
.phone-input-group {
  display: flex;
  align-items: stretch;
  border-radius: 14px;
  border: 1px solid hsla(0, 0%, 100%, 0.1);
  background: hsla(0, 0%, 100%, 0.03);
  overflow: hidden;
  transition: border-color 0.2s ease;
}
.phone-input-group:focus-within { border-color: rgba(94, 234, 212, 0.4); }
.phone-input-prefix {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 1rem;
  font-size: 0.875rem;
  color: #a9adb6;
  border-right: 1px solid hsla(0, 0%, 100%, 0.08);
  white-space: nowrap;
}
.phone-input-group input {
  flex: 1;
  min-width: 0;
  border: none;
  background: none;
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  color: #fff;
}
.phone-input-group input::placeholder { color: #5f6672; }
.phone-input-group input:focus { outline: none; }

.form-input:focus {
  outline: none;
  border-color: rgba(94, 234, 212, 0.45);
  background: hsla(0, 0%, 100%, 0.05);
}

/* Without this, the native <select> dropdown popup (and other native
   controls) render with the browser/OS's light-mode colors by default —
   e.g. the admin product form's Category picker showing near-unreadable
   dark-on-dark or light-popup-on-dark-page text. color-scheme:dark alone
   isn't enough on Windows: the popup list itself still renders on a native
   white background regardless, so <option> text (inherited white from
   .form-input) becomes invisible except on the one hovered/highlighted row
   the OS repaints with its own selection color. Setting explicit dark
   text + white background on the options themselves guarantees every row
   stays readable no matter which theming path the browser actually takes. */
select.form-input { cursor: pointer; color-scheme: dark; }
select.form-input option { color: #0c0d10; background-color: #ffffff; }

textarea.form-input { resize: vertical; min-height: 120px; }

.form-alert {
  border-radius: 16px;
  padding: 1rem 1.25rem;
  font-size: 0.8125rem;
  line-height: 1.6;
}

.form-alert ul { padding-left: 1.1rem; list-style: disc; }

.form-alert-error {
  border: 1px solid rgba(248, 113, 113, 0.3);
  background: rgba(248, 113, 113, 0.08);
  color: #fca5a5;
}

.form-alert-success {
  border: 1px solid rgba(94, 234, 212, 0.3);
  background: rgba(94, 234, 212, 0.08);
  color: #5eead4;
}

/* Quantity stepper (product page + cart lines) */
.qty-stepper {
  display: flex;
  align-items: center;
  border-radius: 9999px;
  border: 1px solid hsla(0, 0%, 100%, 0.1);
}

/* Loading state: swapped in by main.js on form submit */
.btn-loading-target[disabled] { opacity: 0.6; pointer-events: none; }
.btn-loading-target .btn-spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 9999px;
  border: 2px solid hsla(0, 0%, 100%, 0.3);
  border-top-color: #08090b;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------------------------------------------------------------------- */
/* Status badges                                                          */
/* ---------------------------------------------------------------------- */
.status-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 9999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border: 1px solid hsla(0, 0%, 100%, 0.1);
  color: #a9adb6;
}
.status-pending { border-color: rgba(250, 204, 21, 0.35); background: rgba(250, 204, 21, 0.08); color: #facc15; }
.status-processing { border-color: rgba(94, 234, 212, 0.35); background: rgba(94, 234, 212, 0.08); color: #5eead4; }
.status-completed { border-color: rgba(74, 222, 128, 0.35); background: rgba(74, 222, 128, 0.08); color: #4ade80; }
.status-cancelled { border-color: rgba(248, 113, 113, 0.35); background: rgba(248, 113, 113, 0.08); color: #f87171; }

.status-filter-btn {
  border-radius: 9999px;
  border: 1px solid hsla(0, 0%, 100%, 0.08);
  padding: 0.375rem 0.875rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: #8b8f99;
  transition: all 0.2s ease;
}
.status-filter-btn:hover { border-color: hsla(0, 0%, 100%, 0.2); color: #fff; }
.status-filter-btn.active-filter { border-color: rgba(94, 234, 212, 0.4); background: rgba(94, 234, 212, 0.1); color: #fff; }

/* ---------------------------------------------------------------------- */
/* Data tables (account + admin)                                          */
/* ---------------------------------------------------------------------- */
/* Wrap any <table class="data-table"> in <div class="table-scroll"> — on a
   narrow phone a multi-column table would otherwise get crushed illegibly or
   force the whole page to scroll horizontally. This lets just the table
   scroll sideways within its own box instead. */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.data-table { width: 100%; min-width: 480px; border-collapse: collapse; font-size: 0.8125rem; }
.data-table thead th {
  text-align: left;
  padding: 0.875rem 1.25rem;
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #6d717b;
  border-bottom: 1px solid hsla(0, 0%, 100%, 0.07);
}
.data-table tbody td {
  padding: 0.875rem 1.25rem;
  border-bottom: 1px solid hsla(0, 0%, 100%, 0.05);
  color: #c7cad1;
}
.data-table tbody tr:last-child td { border-bottom: none; }
.data-table tbody tr:hover { background: hsla(0, 0%, 100%, 0.02); }

/* ---------------------------------------------------------------------- */
/* Cart lines                                                              */
/* ---------------------------------------------------------------------- */
.cart-line {
  display: grid;
  grid-template-columns: 72px 1fr auto auto;
  align-items: center;
  gap: 1rem;
  border-radius: 20px;
  border: 1px solid hsla(0, 0%, 100%, 0.07);
  background: rgba(18, 19, 23, 0.5);
  padding: 1rem;
}
.cart-line-media { width: 72px; height: 72px; border-radius: 14px; overflow: hidden; border: 1px solid hsla(0, 0%, 100%, 0.07); }
.cart-line-info { min-width: 0; }
.cart-line-name { display: block; font-weight: 600; color: #e5e7ea; font-size: 0.9375rem; }
.cart-line-name:hover { color: #fff; }
.cart-line-tagline { font-size: 0.75rem; color: #6d717b; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cart-line-remove { margin-top: 6px; font-size: 0.75rem; color: #f87171; }
.cart-line-remove:hover { color: #fca5a5; }
.cart-line-price { font-family: 'Space Grotesk', system-ui, sans-serif; font-weight: 600; color: #fff; white-space: nowrap; }

@media (max-width: 640px) {
  .cart-line { grid-template-columns: 56px 1fr; }
  .cart-line-media { width: 56px; height: 56px; }
  .cart-line-qty, .cart-line-price { grid-column: 2; }
}

/* ---------------------------------------------------------------------- */
/* Admin dashboard shell                                                  */
/* ---------------------------------------------------------------------- */
.admin-shell { display: flex; min-height: 100vh; }

.admin-sidebar {
  display: flex;
  flex-direction: column;
  width: 240px;
  flex-shrink: 0;
  padding: 1.75rem 1.25rem;
  border-right: 1px solid hsla(0, 0%, 100%, 0.06);
  background: #0c0d10;
  position: sticky;
  top: 0;
  height: 100vh;
}

.admin-logo { font-family: 'Space Grotesk', system-ui, sans-serif; font-weight: 600; font-size: 1.05rem; color: #e5e7ea; letter-spacing: -0.02em; }
.admin-logo-tag { font-size: 0.625rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.1em; color: #6d717b; }

.admin-nav-link {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  border-radius: 12px;
  padding: 0.625rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #a9adb6;
  transition: all 0.2s ease;
}
.admin-nav-link:hover { background: hsla(0, 0%, 100%, 0.04); color: #fff; }
.admin-nav-link.is-active { background: rgba(94, 234, 212, 0.08); color: #5eead4; }

.admin-main { flex: 1; min-width: 0; padding: 2.5rem; }

/* Below tablet width, the fixed 240px sidebar would crush the main content
   into a sliver — turn it into a horizontally-scrollable top bar instead so
   the admin panel stays fully usable on a phone. */
@media (max-width: 768px) {
  .admin-shell { flex-direction: column; }
  .admin-sidebar {
    position: static;
    width: 100%;
    height: auto;
    flex-direction: row;
    align-items: center;
    gap: 1rem;
    padding: 0.875rem 1rem;
    overflow-x: auto;
    border-right: none;
    border-bottom: 1px solid hsla(0, 0%, 100%, 0.06);
  }
  .admin-sidebar > .admin-logo { flex-shrink: 0; }
  .admin-sidebar > nav {
    flex-direction: row;
    flex-shrink: 0;
    margin-top: 0 !important;
    gap: 0.375rem;
  }
  .admin-nav-link { white-space: nowrap; }
  .admin-sidebar > div {
    flex-direction: row;
    flex-shrink: 0;
    margin-top: 0 !important;
    border-top: none;
    border-left: 1px solid hsla(0, 0%, 100%, 0.07);
    padding-top: 0 !important;
    padding-left: 0.75rem;
  }
  .admin-main { padding: 1.25rem; }
}

.admin-topbar { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem; }

.admin-stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; margin-top: 1.5rem; }
.admin-stat-card { border-radius: 20px; border: 1px solid hsla(0, 0%, 100%, 0.07); background: rgba(18, 19, 23, 0.5); padding: 1.5rem; display: flex; flex-direction: column; gap: 0.5rem; }
.admin-stat-label { font-size: 0.6875rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: #6d717b; }
.admin-stat-value { font-family: 'Space Grotesk', system-ui, sans-serif; font-size: 1.75rem; font-weight: 600; color: #fff; }

.admin-panel { border-radius: 20px; border: 1px solid hsla(0, 0%, 100%, 0.07); background: rgba(18, 19, 23, 0.5); overflow: hidden; }
.admin-panel-header { display: flex; align-items: center; justify-content: space-between; padding: 1.25rem 1.5rem; border-bottom: 1px solid hsla(0, 0%, 100%, 0.06); }

.admin-thumb { width: 44px; height: 44px; border-radius: 10px; overflow: hidden; border: 1px solid hsla(0, 0%, 100%, 0.08); background: #0c0d10; }
.admin-thumb img { width: 100%; height: 100%; object-fit: cover; }
.admin-thumb-fallback { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; color: #5eead4; }

.admin-actions { display: flex; align-items: center; gap: 0.875rem; font-size: 0.8125rem; }
.admin-delete-form { display: inline; }

.admin-image-preview {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  border: 1px dashed hsla(0, 0%, 100%, 0.12);
  background: #0c0d10;
  overflow: hidden;
  text-align: center;
  padding: 1rem;
}
.admin-image-preview img { width: 100%; height: 100%; object-fit: cover; }

.admin-image-tile {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid hsla(0, 0%, 100%, 0.08);
  background: #0c0d10;
}
.admin-image-tile img { width: 100%; height: 100%; object-fit: cover; }
.admin-image-remove-check {
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 6px;
  font-size: 11px;
  color: #fca5a5;
  background: rgba(8, 9, 11, 0.75);
  cursor: pointer;
}
