/* ── Custom properties ──────────────────────────────────────────────────────── */
:root {
  --bg:            #faf9f6;
  --surface:       #ffffff;
  --border:        #e8e3d8;
  --text:          #1c1a17;
  --text-2:        #5c5850;
  --text-3:        #9a9488;
  --accent:        #b8860b;
  --accent-hi:     #daa520;
  --link:          #7a6010;
  --radius:        12px;
  --radius-sm:     6px;
  --shadow:        0 1px 2px rgba(0,0,0,0.06), 0 4px 16px rgba(0,0,0,0.07);
  --shadow-hover:  0 2px 4px rgba(0,0,0,0.08), 0 8px 24px rgba(0,0,0,0.12);
  --header-bg:     #1c1a17;
  --header-text:   #e8e0cc;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:            #131210;
    --surface:       #1e1c18;
    --border:        #2e2b24;
    --text:          #ede6d8;
    --text-2:        #a09880;
    --text-3:        #605a50;
    --accent:        #c89a20;
    --accent-hi:     #daa520;
    --link:          #c8a030;
    --shadow:        0 1px 3px rgba(0,0,0,0.4), 0 4px 16px rgba(0,0,0,0.35);
    --shadow-hover:  0 2px 6px rgba(0,0,0,0.5), 0 8px 28px rgba(0,0,0,0.45);
    --header-bg:     #0d0c0a;
    --header-text:   #e8e0cc;
  }
}

/* ── Reset & base ───────────────────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 0.9375rem;
  line-height: 1.6;
  background: var(--bg);
  color: var(--text);
  min-height: 100dvh;
}

img { display: block; max-width: 100%; }

a {
  color: var(--link);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}
a:hover { color: var(--accent-hi); }

/* ── Header ─────────────────────────────────────────────────────────────────── */
.site-header {
  background: var(--header-bg);
  color: var(--header-text);
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.header-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.site-header h1 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--accent-hi);
}

.header-sub {
  font-size: 0.8125rem;
  color: rgba(232, 224, 204, 0.55);
  margin-top: 0.15rem;
}

/* ── Main layout ────────────────────────────────────────────────────────────── */
.site-main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

/* ── Empty state ────────────────────────────────────────────────────────────── */
.empty-state {
  text-align: center;
  color: var(--text-3);
  font-style: italic;
  padding: 3rem 0;
}

/* ── Sections ───────────────────────────────────────────────────────────────── */
.item-section + .item-section {
  margin-top: 3rem;
}

.section-header {
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.section-header h2 {
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--accent);
  margin-bottom: 0.25rem;
}

.section-note {
  font-size: 0.8125rem;
  color: var(--text-2);
}

.section-note a {
  color: var(--link);
}

/* ── Card grid ──────────────────────────────────────────────────────────────── */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

/* ── Item card ──────────────────────────────────────────────────────────────── */
.item-card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s, transform 0.2s;
}

.item-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

/* ── Card media ─────────────────────────────────────────────────────────────── */
.card-media {
  position: relative;
  background: var(--border);
  line-height: 0;
}

/* Scroll-snap image strip */
.img-strip {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  aspect-ratio: 4 / 3;
}

.img-strip::-webkit-scrollbar { display: none; }

.img-strip img {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  scroll-snap-align: start;
  cursor: zoom-in;
  line-height: 0;
}

/* Dot indicators */
.img-dots {
  position: absolute;
  bottom: 8px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 5px;
  pointer-events: none;
}

.dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.45);
  transition: background 0.2s, transform 0.2s;
}

.dot.active {
  background: #fff;
  transform: scale(1.25);
}

/* Price pill — top-right of image */
.price-pill {
  position: absolute;
  top: 10px;
  right: 10px;
  background: rgba(10, 9, 7, 0.72);
  color: var(--accent-hi);
  font-size: 0.8125rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  letter-spacing: 0.01em;
  line-height: 1.6;
}

/* ── Card body ──────────────────────────────────────────────────────────────── */
.card-body {
  padding: 1rem 1.125rem 1.125rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.card-title {
  font-size: 1rem;
  font-weight: 650;
  letter-spacing: -0.01em;
  line-height: 1.3;
  color: var(--text);
}

.card-subtitle {
  font-size: 0.8125rem;
  color: var(--text-2);
  margin-top: -0.25rem;
}

.card-details {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.card-details li {
  font-size: 0.8125rem;
  color: var(--text-2);
  padding-left: 1em;
  position: relative;
}

.card-details li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: var(--text-3);
}

.card-notes {
  font-size: 0.8125rem;
  color: var(--text-2);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.card-links {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  margin-top: auto;
  padding-top: 0.25rem;
}

.card-links a {
  font-size: 0.8125rem;
}

/* ── Lightbox ───────────────────────────────────────────────────────────────── */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(8, 7, 5, 0.93);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  cursor: zoom-out;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.lightbox img {
  max-width: 95vw;
  max-height: 95dvh;
  object-fit: contain;
  border-radius: var(--radius-sm);
  cursor: default;
  box-shadow: 0 8px 48px rgba(0,0,0,0.6);
}

.lb-close {
  position: absolute;
  top: 1rem;
  right: 1.25rem;
  font-size: 1.5rem;
  line-height: 1;
  color: rgba(255,255,255,0.7);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  transition: color 0.15s;
}

.lb-close:hover { color: #fff; }

/* ── Swish button ───────────────────────────────────────────────────────────── */
.btn-swish {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  margin-top: auto;
  padding: 8px 14px;
  background: linear-gradient(135deg, #7B3FBF, #C0307A);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 650;
  cursor: pointer;
  letter-spacing: 0.01em;
  transition: filter 0.15s;
}
.btn-swish:hover { filter: brightness(1.1); }
.btn-swish svg { flex-shrink: 0; }

/* ── Swish modal ────────────────────────────────────────────────────────────── */
.swish-modal {
  position: fixed;
  inset: 0;
  background: rgba(8, 7, 5, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1001;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  padding: 1rem;
}

.swish-modal-inner {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 1.75rem;
  max-width: 340px;
  width: 100%;
  position: relative;
  text-align: center;
  box-shadow: 0 8px 48px rgba(0,0,0,0.4);
}

.swish-close {
  position: absolute;
  top: 0.875rem;
  right: 1rem;
  font-size: 1.25rem;
  line-height: 1;
  color: var(--text-3);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  transition: color 0.15s;
}
.swish-close:hover { color: var(--text); }

.swish-label {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #9B50BF;
  margin-bottom: 0.35rem;
}

.swish-modal-inner h3 {
  font-size: 1rem;
  font-weight: 650;
  color: var(--text);
  margin-bottom: 0.2rem;
}

.swish-price {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent-hi);
  margin-bottom: 1.25rem;
}

.swish-qr-area {
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.swish-qr-img {
  width: 220px;
  height: 220px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.swish-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-3);
  font-size: 0.875rem;
}

.swish-spinner {
  display: block;
  width: 28px;
  height: 28px;
  border: 3px solid var(--border);
  border-top-color: #9B50BF;
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.swish-error {
  color: var(--text-2);
  font-size: 0.8125rem;
  line-height: 1.5;
  padding: 0 0.5rem;
}

.swish-instructions {
  font-size: 0.8125rem;
  color: var(--text-3);
}

/* ── Utilities ──────────────────────────────────────────────────────────────── */
.hidden { display: none !important; }
