/* ZERO1 - Dark theme, premium streetwear */
:root {
  --bg: #0a0a0a;
  --bg-card: #111111;
  --bg-elevated: #161616;
  --border: #262626;
  --text: #fafafa;
  --text-muted: #a3a3a3;
  --accent: #22c55e;
  --accent-hover: #16a34a;
  --glow: rgba(34, 197, 94, 0.25);
  --radius: 12px;
  --font: 'Inter', 'Poppins', system-ui, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s, opacity 0.2s;
}

a:hover {
  color: var(--accent);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--text);
}

.logo span {
  color: var(--accent);
}

.nav-main {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-main a {
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
}

.nav-main a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width 0.2s;
}

.nav-main a:hover::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.btn-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.btn-icon:hover {
  border-color: var(--accent);
  box-shadow: 0 0 20px var(--glow);
}

.btn-icon .badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  background: var(--accent);
  color: var(--bg);
  font-size: 0.7rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  font-family: var(--font);
}

.btn-primary {
  background: var(--accent);
  color: var(--bg);
}

.btn-primary:hover {
  background: var(--accent-hover);
  box-shadow: 0 0 24px var(--glow);
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 2px solid var(--border);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 0 20px var(--glow);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
}

.btn-ghost:hover {
  color: var(--accent);
  background: rgba(34, 197, 94, 0.1);
}

/* Product grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.product-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.product-card:hover {
  border-color: var(--accent);
  box-shadow: 0 0 30px var(--glow);
  transform: translateY(-4px);
}

.product-card .img-wrap {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--bg-elevated);
}

.product-card .img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.product-card:hover .img-wrap img.main-img {
  opacity: 0;
}

.product-card .img-wrap img.hover-img {
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
  transition: opacity 0.4s;
}

.product-card:hover .img-wrap img.hover-img {
  opacity: 1;
}

.product-card .img-wrap .quick-actions {
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  right: 1rem;
  display: flex;
  gap: 0.5rem;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.2s, transform 0.2s;
}

.product-card:hover .quick-actions {
  opacity: 1;
  transform: translateY(0);
}

.product-card .body {
  padding: 1.25rem;
}

.product-card .title {
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.25rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card .price-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.product-card .price {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--accent);
}

.product-card .compare-at {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-decoration: line-through;
}

.product-card .badge-sale {
  background: var(--accent);
  color: var(--bg);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

/* Container */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 3rem 0;
}

.section-title {
  font-size: 1.75rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
}

/* Hero */
.hero {
  position: relative;
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--bg) 0%, var(--bg-elevated) 50%, var(--bg) 100%);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--glow) 0%, transparent 70%);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 2rem;
}

.hero-content h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 1rem;
}

.hero-content h1 span {
  color: var(--accent);
  text-shadow: 0 0 40px var(--glow);
}

.hero-content p {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 500px;
  margin: 0 auto 1.5rem;
}

/* Cart drawer */
.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  max-width: 420px;
  height: 100vh;
  background: var(--bg-card);
  border-left: 1px solid var(--border);
  z-index: 200;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  box-shadow: -10px 0 40px rgba(0,0,0,0.5);
}

.cart-drawer.open {
  transform: translateX(0);
}

.cart-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 199;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}

.cart-drawer-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.cart-drawer-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cart-drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
}

.cart-drawer-footer {
  padding: 1.5rem;
  border-top: 1px solid var(--border);
}

.cart-item {
  display: flex;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}

.cart-item:last-child {
  border-bottom: none;
}

.cart-item img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
  background: var(--bg-elevated);
}

.cart-item .info {
  flex: 1;
  min-width: 0;
}

.cart-item .qty-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.cart-item .qty-wrap button {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text);
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
}

.cart-item .qty-wrap button:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.cart-item .qty-wrap span {
  min-width: 24px;
  text-align: center;
}

/* Forms */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
textarea,
select {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.2s;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--glow);
}

label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.35rem;
  font-size: 0.9rem;
}

.form-group {
  margin-bottom: 1rem;
}

/* Footer */
.site-footer {
  margin-top: 4rem;
  padding: 3rem 0 2rem;
  border-top: 1px solid var(--border);
  background: var(--bg-card);
}

.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

.footer-inner h4 {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.footer-inner ul {
  list-style: none;
}

.footer-inner li {
  margin-bottom: 0.5rem;
}

.footer-inner a:hover {
  color: var(--accent);
}

.footer-bottom {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1.5rem 1.5rem 0;
  border-top: 1px solid var(--border);
  margin-top: 2rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Search */
.search-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(8px);
  z-index: 150;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 6rem 1rem 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.search-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.search-box-wrap {
  width: 100%;
  max-width: 560px;
}

.search-box-wrap input {
  font-size: 1.25rem;
  padding: 1rem 1.25rem;
}

.search-results {
  margin-top: 1rem;
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  max-height: 70vh;
  overflow-y: auto;
}

.search-results a {
  display: flex;
  gap: 1rem;
  padding: 1rem;
  align-items: center;
  border-bottom: 1px solid var(--border);
  transition: background 0.2s;
}

.search-results a:hover {
  background: var(--bg-elevated);
}

.search-results a:last-child {
  border-bottom: none;
}

.search-results img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 8px;
}

/* Product detail */
.product-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

@media (max-width: 900px) {
  .product-detail-grid {
    grid-template-columns: 1fr;
  }
}

.product-gallery {
  position: sticky;
  top: 100px;
}

.product-gallery .main-image {
  aspect-ratio: 1;
  background: var(--bg-elevated);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 1rem;
  border: 1px solid var(--border);
}

.product-gallery .main-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-gallery .thumbnails {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.product-gallery .thumbnails img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 8px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color 0.2s;
}

.product-gallery .thumbnails img:hover,
.product-gallery .thumbnails img.active {
  border-color: var(--accent);
}

.product-info h1 {
  font-size: 1.75rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.product-info .price-block {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.product-info .price-block .price {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--accent);
}

.product-info .variant-group {
  margin-bottom: 1.25rem;
}

.product-info .variant-group .label {
  font-weight: 600;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

.product-info .variant-options {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.product-info .variant-options input {
  display: none;
}

.product-info .variant-options label {
  display: inline-block;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  border: 2px solid var(--border);
  cursor: pointer;
  margin-bottom: 0;
  transition: all 0.2s;
}

.product-info .variant-options input:checked + label {
  border-color: var(--accent);
  background: rgba(34, 197, 94, 0.15);
  color: var(--accent);
}

.product-info .variant-options label:hover {
  border-color: var(--accent);
}

/* Filters */
.filters-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding: 1rem;
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

.filters-bar select {
  max-width: 180px;
}

/* Pagination */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}

.pagination a,
.pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 0.75rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  font-weight: 500;
  transition: all 0.2s;
}

.pagination a:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.pagination .current {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--bg);
}

.pagination .disabled {
  opacity: 0.5;
  pointer-events: none;
}

/* Alerts */
.alert {
  padding: 1rem 1.25rem;
  border-radius: var(--radius);
  margin-bottom: 1rem;
}

.alert-success {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid var(--accent);
  color: var(--accent);
}

.alert-error {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid #ef4444;
  color: #f87171;
}

/* Utility */
.text-muted { color: var(--text-muted); }
.text-accent { color: var(--accent); }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mb-2 { margin-bottom: 1rem; }

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
  animation: fadeIn 0.4s ease forwards;
}

/* Responsive */
@media (max-width: 768px) {
  .nav-main { display: none; }
  .header-actions { gap: 0.5rem; }
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }
  .product-card .body { padding: 1rem; }
}
