@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  --background:   hsl(220 13% 9%);
  --foreground:   hsl(220 9% 98%);
  --card:         hsl(220 13% 11%);
  --primary:      hsl(35 84% 62%);
  --primary-fg:   hsl(220 13% 9%);
  --secondary:    hsl(220 10% 15%);
  --muted:        hsl(220 8% 14%);
  --muted-fg:     hsl(220 5% 65%);
  --accent:       hsl(220 8% 18%);
  --border:       hsl(220 8% 20%);
  --radius:       0.75rem;
  --shadow-glass: 0 8px 32px rgba(0,0,0,.3), inset 0 1px 0 rgba(255,255,255,.1);
  --shadow-elev:  0 20px 25px -5px rgba(0,0,0,.4), 0 10px 10px -5px rgba(0,0,0,.2);
  --shadow-glow:  0 0 40px hsl(35 84% 62% / .3);
  --transition:   all .3s cubic-bezier(.4,0,.2,1);
  --grad-primary: linear-gradient(135deg, hsl(35 84% 62%), hsl(25 75% 55%));
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; border-color: var(--border); }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--background);
  color: var(--foreground);
  -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(circle at 20% 80%, hsl(35 84% 62% / .05) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, hsl(25 75% 55% / .05) 0%, transparent 50%);
  min-height: 100vh;
}

a { color: inherit; text-decoration: none; }

/* ─── Glass ─────────────────────────────── */
.glass {
  background: rgba(255,255,255,.05);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,.1);
  box-shadow: var(--shadow-glass);
}
.glass-strong {
  background: rgba(255,255,255,.1);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,.15);
  box-shadow: var(--shadow-glass);
}

/* ─── Gradient text ──────────────────────── */
.gradient-text {
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ─── Hover effects ──────────────────────── */
.hover-lift { transition: var(--transition); }
.hover-lift:hover { transform: translateY(-4px); box-shadow: var(--shadow-elev); }
.hover-glow:hover { box-shadow: var(--shadow-glow); }

/* ─── Watch card ─────────────────────────── */
.watch-card {
  position: relative;
  overflow: hidden;
  transition: var(--transition);
  border-radius: var(--radius);
}
.watch-card::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(circle, hsl(35 84% 62% / .15), transparent 70%);
  opacity: 0;
  transition: var(--transition);
  z-index: 1;
  pointer-events: none;
}
.watch-card:hover::before { opacity: 1; }
.watch-card > * { position: relative; z-index: 2; }
.watch-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-elev); }

/* ─── Status badges ──────────────────────── */
.status-available  { background: hsl(142 71% 45% / .2); color: hsl(142 71% 65%); border: 1px solid hsl(142 71% 45% / .3); }
.status-order      { background: hsl(38 92% 50% / .2);  color: hsl(38 92% 70%);  border: 1px solid hsl(38 92% 50% / .3); }
.status-sold       { background: hsl(0 72% 58% / .2);   color: hsl(0 72% 75%);   border: 1px solid hsl(0 72% 58% / .3); }

/* ─── Nav ────────────────────────────────── */
nav.site-nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 50;
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1280px; margin: 0 auto; padding: 0 1rem;
  height: 4rem; display: flex; align-items: center; justify-content: space-between;
}
.nav-logo { display: flex; align-items: center; gap: .5rem; }
.nav-logo-icon {
  width: 2rem; height: 2rem;
  background: linear-gradient(135deg, hsl(35 84% 62%), hsl(33 90% 50%));
  border-radius: .5rem;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: .875rem;
  color: var(--primary-fg);
}
.nav-links { display: flex; gap: 2rem; }
.nav-links a {
  font-size: .875rem; font-weight: 500;
  color: var(--muted-fg);
  transition: color .2s;
  position: relative;
}
.nav-links a:hover, .nav-links a.active { color: var(--foreground); }
.nav-links a.active { color: var(--primary); }
.nav-links a.active::after {
  content: '';
  position: absolute; bottom: -2px; left: 0; right: 0;
  height: 2px;
  background: var(--grad-primary);
  border-radius: 9999px;
}
.nav-actions { display: flex; gap: .5rem; align-items: center; }

/* ─── Buttons ────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .5rem 1rem; border-radius: var(--radius);
  font-size: .875rem; font-weight: 500;
  cursor: pointer; transition: var(--transition);
  border: 1px solid transparent;
  white-space: nowrap;
}
.btn-lg { padding: .75rem 1.5rem; font-size: 1rem; }
.btn-sm { padding: .375rem .75rem; font-size: .75rem; }
.btn-icon { width: 2.25rem; height: 2.25rem; padding: 0; }
.btn-icon-sm { width: 2rem; height: 2rem; padding: 0; }

.btn-primary {
  background: var(--primary);
  color: var(--primary-fg);
}
.btn-primary:hover { filter: brightness(1.1); box-shadow: var(--shadow-glow); }

.btn-outline {
  border-color: var(--border);
  color: var(--foreground);
  background: transparent;
}
.btn-outline:hover { background: var(--accent); }

.btn-ghost { background: transparent; color: var(--foreground); }
.btn-ghost:hover { background: var(--accent); }

.btn-danger { background: hsl(0 72% 58%); color: white; }
.btn-danger:hover { filter: brightness(1.1); }

button:disabled { opacity: .5; cursor: not-allowed; }

/* ─── Cards ──────────────────────────────── */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

/* ─── Forms ──────────────────────────────── */
.input, .textarea, .select {
  width: 100%;
  background: rgba(255,255,255,.05);
  border: 1px solid var(--border);
  border-radius: .5rem;
  padding: .5rem .75rem;
  color: var(--foreground);
  font-size: .875rem;
  font-family: inherit;
  transition: border-color .2s, box-shadow .2s;
  outline: none;
}
.input::placeholder, .textarea::placeholder { color: var(--muted-fg); }
.input:focus, .textarea:focus, .select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px hsl(35 84% 62% / .15);
}
.textarea { resize: vertical; min-height: 120px; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e"); background-repeat: no-repeat; background-position: right .5rem center; background-size: 1.5em 1.5em; padding-right: 2.5rem; cursor: pointer; }
.select option { background: hsl(220 13% 11%); }

label { font-size: .875rem; font-weight: 500; display: block; margin-bottom: .5rem; }

/* ─── Badge ──────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; gap: .25rem;
  padding: .25rem .625rem;
  border-radius: 9999px;
  font-size: .75rem; font-weight: 500;
  background: var(--secondary); color: var(--foreground);
  border: 1px solid var(--border);
}
.badge-primary {
  background: hsl(35 84% 62% / .2);
  color: var(--primary);
  border-color: hsl(35 84% 62% / .3);
}

/* ─── Container ──────────────────────────── */
.container { max-width: 1280px; margin: 0 auto; padding: 0 1rem; }

/* ─── Grid utilities ─────────────────────── */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }

@media (max-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .nav-links { display: none; }
}

/* ─── Mobile nav ─────────────────────────── */
.mobile-menu { display: none; padding: 1rem 0; border-top: 1px solid var(--border); }
.mobile-menu.open { display: block; }
.mobile-menu a {
  display: block; padding: .5rem .75rem; border-radius: .375rem;
  font-size: .875rem; font-weight: 500;
  color: var(--muted-fg); margin-bottom: .25rem;
  transition: background .2s, color .2s;
}
.mobile-menu a:hover { background: var(--accent); color: var(--foreground); }
.mobile-menu a.active { background: hsl(35 84% 62% / .1); color: var(--primary); }

/* ─── Animations ─────────────────────────── */
@keyframes fadeIn   { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp  { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
@keyframes scaleIn  { from { opacity: 0; transform: scale(.95); } to { opacity: 1; transform: scale(1); } }
@keyframes bounce   { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
@keyframes glowPulse { 0%,100% { background: var(--primary); } 50% { background: hsl(35 84% 75%); } }

.anim-fade   { animation: fadeIn .5s ease both; }
.anim-up     { animation: slideUp .5s ease both; }
.anim-scale  { animation: scaleIn .4s ease both; }
.anim-bounce { animation: bounce 2s infinite; }

/* ─── Thumbnail strip ────────────────────── */
.thumb-strip { display: grid; grid-template-columns: repeat(5, 1fr); gap: .5rem; }
.thumb {
  aspect-ratio: 1; overflow: hidden; cursor: pointer;
  border-radius: .5rem; border: 2px solid transparent; transition: border-color .2s;
}
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb.active { border-color: var(--primary); }
.thumb:hover:not(.active) { border-color: hsl(35 84% 62% / .5); }

/* ─── Process thumbnails ─────────────────── */
.process-thumbs { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; }

/* ─── Filter sidebar ─────────────────────── */
.filter-group { margin-bottom: 1.25rem; }
.filter-title { font-size: .75rem; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; color: var(--muted-fg); margin-bottom: .625rem; }
.filter-item { display: flex; align-items: center; gap: .5rem; padding: .25rem 0; cursor: pointer; }
.filter-item input[type=checkbox] { accent-color: var(--primary); width: 14px; height: 14px; cursor: pointer; }
.filter-item span { font-size: .875rem; color: var(--muted-fg); transition: color .2s; }
.filter-item:hover span { color: var(--foreground); }

/* ─── Spec grid ──────────────────────────── */
.spec-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; }
.spec-item {
  display: flex; align-items: center; gap: .75rem;
  padding: .75rem; border-radius: .5rem;
}
.spec-icon { width: 1.25rem; height: 1.25rem; color: var(--primary); flex-shrink: 0; }
.spec-label { font-size: .75rem; color: var(--muted-fg); }
.spec-value { font-size: .875rem; font-weight: 500; }

/* ─── Hero scroll indicator ──────────────── */
.scroll-indicator {
  position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%);
  animation: bounce 2s infinite;
}
.scroll-dot {
  width: 1.5rem; height: 2.5rem;
  border: 2px solid hsl(35 84% 62% / .3);
  border-radius: 9999px;
  display: flex; justify-content: center; padding-top: .5rem;
}
.scroll-dot::before {
  content: '';
  width: .25rem; height: .75rem;
  background: var(--primary);
  border-radius: 9999px;
  animation: glowPulse 2s infinite;
}

/* ─── Alert boxes ────────────────────────── */
.alert-success {
  padding: 1rem; border-radius: .5rem;
  background: hsl(142 71% 45% / .1);
  border: 1px solid hsl(142 71% 45% / .3);
  color: hsl(142 71% 65%);
  display: flex; align-items: center; gap: .75rem;
}
.alert-error {
  padding: 1rem; border-radius: .5rem;
  background: hsl(0 72% 58% / .1);
  border: 1px solid hsl(0 72% 58% / .3);
  color: hsl(0 72% 75%);
}

/* ─── Table ──────────────────────────────── */
.watch-row {
  display: flex; align-items: center; gap: 1rem;
  padding: 1rem;
}
.watch-thumb {
  width: 4rem; height: 4rem; border-radius: .5rem;
  overflow: hidden; flex-shrink: 0; background: var(--accent);
}
.watch-thumb img { width: 100%; height: 100%; object-fit: cover; }

/* ─── Complication badge ─────────────────── */
.compl-badge {
  font-size: .75rem; padding: .25rem .5rem;
  border-radius: .25rem;
  background: var(--accent); color: var(--muted-fg);
}

/* ─── Utility ────────────────────────────── */
.text-primary  { color: var(--primary); }
.text-muted    { color: var(--muted-fg); }
.text-sm       { font-size: .875rem; }
.text-xs       { font-size: .75rem; }
.text-lg       { font-size: 1.125rem; }
.text-xl       { font-size: 1.25rem; }
.text-2xl      { font-size: 1.5rem; }
.text-3xl      { font-size: 1.875rem; }
.text-4xl      { font-size: 2.25rem; }
.font-bold     { font-weight: 700; }
.font-semibold { font-weight: 600; }
.font-medium   { font-weight: 500; }
.capitalize    { text-transform: capitalize; }
.truncate      { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.flex          { display: flex; }
.flex-col      { flex-direction: column; }
.items-center  { align-items: center; }
.items-start   { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.justify-center  { justify-content: center; }
.flex-1        { flex: 1; }
.flex-wrap     { flex-wrap: wrap; }
.gap-1  { gap: .25rem; }
.gap-2  { gap: .5rem; }
.gap-3  { gap: .75rem; }
.gap-4  { gap: 1rem; }
.gap-6  { gap: 1.5rem; }
.gap-8  { gap: 2rem; }
.gap-12 { gap: 3rem; }
.mt-1  { margin-top: .25rem; }
.mt-2  { margin-top: .5rem; }
.mt-3  { margin-top: .75rem; }
.mt-4  { margin-top: 1rem; }
.mt-6  { margin-top: 1.5rem; }
.mt-8  { margin-top: 2rem; }
.mb-1  { margin-bottom: .25rem; }
.mb-2  { margin-bottom: .5rem; }
.mb-3  { margin-bottom: .75rem; }
.mb-4  { margin-bottom: 1rem; }
.mb-6  { margin-bottom: 1.5rem; }
.mb-8  { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }
.p-4   { padding: 1rem; }
.p-6   { padding: 1.5rem; }
.p-8   { padding: 2rem; }
.py-8  { padding-top: 2rem; padding-bottom: 2rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }
.py-20 { padding-top: 5rem; padding-bottom: 5rem; }
.px-4  { padding-left: 1rem; padding-right: 1rem; }
.pt-24 { padding-top: 6rem; }
.pb-12 { padding-bottom: 3rem; }
.pb-20 { padding-bottom: 5rem; }
.w-full { width: 100%; }
.max-w-md  { max-width: 28rem; }
.max-w-xl  { max-width: 36rem; }
.max-w-2xl { max-width: 42rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-6xl { max-width: 72rem; }
.mx-auto   { margin-left: auto; margin-right: auto; }
.text-center { text-align: center; }
.relative  { position: relative; }
.overflow-hidden { overflow: hidden; }
.rounded-lg { border-radius: var(--radius); }
.rounded-xl { border-radius: 1rem; }
.rounded-full { border-radius: 9999px; }
.border     { border: 1px solid var(--border); }
.space-y-3 > * + * { margin-top: .75rem; }
.space-y-4 > * + * { margin-top: 1rem; }
.space-y-5 > * + * { margin-top: 1.25rem; }
.space-y-6 > * + * { margin-top: 1.5rem; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border-width: 0; }

.bg-gradient-surface {
  background: linear-gradient(135deg, hsl(220 13% 11%), hsl(220 15% 13%));
}

.hidden { display: none !important; }

@media (min-width: 768px) {
  .md\:grid-2 { grid-template-columns: repeat(2, 1fr); }
  .md\:hidden { display: none !important; }
  .md\:flex   { display: flex !important; }
  .show-mobile { display: none !important; }
}
@media (max-width: 767px) {
  .hide-mobile { display: none !important; }
  .show-mobile { display: block !important; }

  /* Gallery layout: stack sidebar above grid */
  .gallery-layout {
    flex-direction: column !important;
  }
  .gallery-sidebar {
    width: 100% !important;
    position: static !important;
  }

  /* Search bar: stack controls on small screens */
  .gallery-search-bar {
    flex-direction: column !important;
    align-items: stretch !important;
  }
  .gallery-search-bar > div:first-child {
    max-width: 100% !important;
  }
}
