:root {
  color-scheme: dark;
}

body {
  min-height: 100vh;
}

a {
  text-decoration: none;
}

.page-shell {
  padding-top: 3rem;
  padding-bottom: 3rem;
}

.grid-background {
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(circle at center, rgba(0, 0, 0, 0.8), transparent 95%);
  opacity: 0.9;
}

.footer-bg {
  height: 420px;
  background:
    radial-gradient(circle at center, rgba(168, 85, 247, 0.18), transparent 50%),
    radial-gradient(circle at 20% 30%, rgba(168, 85, 247, 0.08), transparent 35%);
  filter: blur(10px);
}

.surface-panel {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 1.5rem;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(18px);
}

.panel-label {
  font-size: 0.72rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
  margin-bottom: 0.45rem;
}

.hero-shell {
  position: relative;
}

.hero-slide {
  display: none;
}

.hero-slide.is-active {
  display: block;
}

.hero-dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 180ms ease;
}

.hero-dot.is-active {
  width: 2rem;
  background: hsl(var(--primary));
}

.product-tile {
  height: 100%;
  padding: 1rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.025));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.5rem;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.22);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.product-tile:hover {
  transform: translateY(-4px);
  border-color: rgba(168, 85, 247, 0.45);
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.3);
}

.product-media {
  display: block;
  overflow: hidden;
  border-radius: 1.25rem;
  aspect-ratio: 4 / 3;
  background: rgba(255, 255, 255, 0.03);
}

.search-result-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  width: 100%;
  padding: 0.9rem;
  border-radius: 0.95rem;
  transition: background-color 180ms ease;
}

.search-result-item:hover {
  background: rgba(255, 255, 255, 0.04);
}

.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.empty-state {
  min-height: 18rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 0.75rem;
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 1.5rem;
  background: rgba(255, 255, 255, 0.02);
}

.stat-card {
  padding: 1.5rem;
  border-radius: 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.18);
}

.detail-card {
  border-radius: 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  padding: 1.2rem;
}

.order-step {
  position: relative;
  padding-left: 1.5rem;
}

.order-step::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.45rem;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 999px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
}

.order-step::after {
  content: "";
  position: absolute;
  left: 0.32rem;
  top: 1.45rem;
  bottom: -1.15rem;
  width: 1px;
  background: rgba(255, 255, 255, 0.14);
}

.order-step:last-child::after {
  display: none;
}

.order-step[data-state="done"]::before {
  border-color: rgba(34, 197, 94, 0.7);
  background: rgba(34, 197, 94, 0.25);
}

.order-step[data-state="active"]::before {
  border-color: rgba(168, 85, 247, 0.85);
  background: rgba(168, 85, 247, 0.25);
}

.order-step[data-state="danger"]::before {
  border-color: rgba(248, 113, 113, 0.9);
  background: rgba(248, 113, 113, 0.2);
}

#cart-drawer [data-cart-panel] {
  transform: translateX(100%);
  transition: transform 220ms ease;
}

#cart-drawer[data-state="open"] [data-cart-panel] {
  transform: translateX(0);
}

.table-shell {
  overflow: auto;
  border-radius: 1.2rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

table {
  border-collapse: collapse;
}

th,
td {
  white-space: nowrap;
}

details[open] {
  background: rgba(168, 85, 247, 0.05);
  border-color: rgba(168, 85, 247, 0.22);
}

@media (max-width: 640px) {
  .page-shell {
    padding-top: 2rem;
    padding-bottom: 2.5rem;
  }

  .product-tile {
    padding: 0.9rem;
  }
}
