/* =========================================================
   Anarchy & Lace — base.css
   Gallery-only production stylesheet
   Mobile-first, accessible, and free of obsolete commerce/auth rules
   ========================================================= */

/* =========================================================
   1. THEME TOKENS
   ========================================================= */

:root {
  color-scheme: light;

  --bg-image: url("/static/background_images/anarchylace_background_white.458c7de8a032.webp");
  --bg-overlay: rgba(255, 255, 255, 0.28);

  --ink: #141414;
  --ink-muted: #5f5f5f;

  --panel-rgb: 255 255 255;
  --panel-bg: rgba(255, 255, 255, 0.76);
  --panel-bg-strong: rgba(255, 255, 255, 0.94);
  --panel-border: rgba(20, 20, 20, 0.12);

  --gold: #c8a14a;
  --gold-bright: #e3bd68;
  --gold-soft: rgba(200, 161, 74, 0.22);

  --danger: #b44545;
  --success: #557d51;

  --shadow-sm: 0 8px 24px rgba(20, 20, 20, 0.10);
  --shadow: 0 20px 50px rgba(20, 20, 20, 0.14);
  --shadow-deep: 0 26px 70px rgba(20, 20, 20, 0.22);

  --radius-xs: 8px;
  --radius-sm: 12px;
  --radius: 18px;
  --radius-lg: 24px;

  --focus-ring: 0 0 0 4px var(--gold-soft);

  --container-max: 1100px;
  --wide-max: 1200px;
  --container-pad: 12px;

  --nav-height: 76px;
  --page-top-gap: clamp(0.35rem, 1.2vw, 0.8rem);

  --transition-fast: 160ms ease;
  --transition: 220ms ease;
}

@media (min-width: 480px) {
  :root {
    --container-pad: 16px;
  }
}

@media (min-width: 900px) {
  :root {
    --container-pad: 24px;
    --nav-height: 84px;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;

    --bg-image: url("/static/background_images/anarchylace_background_black.d187b67c02a1.webp");
    --bg-overlay: rgba(0, 0, 0, 0.24);

    --ink: #f4f4f4;
    --ink-muted: #b9b9b9;

    --panel-rgb: 10 10 10;
    --panel-bg: rgba(16, 16, 16, 0.76);
    --panel-bg-strong: rgba(13, 13, 13, 0.96);
    --panel-border: rgba(255, 255, 255, 0.15);

    --gold: #e0b45f;
    --gold-bright: #f2ce7b;
    --gold-soft: rgba(224, 180, 95, 0.28);

    --shadow-sm: 0 10px 28px rgba(0, 0, 0, 0.38);
    --shadow: 0 20px 60px rgba(0, 0, 0, 0.56);
    --shadow-deep: 0 28px 80px rgba(0, 0, 0, 0.72);
  }
}

html[data-theme="light"] {
  color-scheme: light;

  --bg-image: url("/static/background_images/anarchylace_background_white.458c7de8a032.webp");
  --bg-overlay: rgba(255, 255, 255, 0.28);

  --ink: #141414;
  --ink-muted: #5f5f5f;

  --panel-rgb: 255 255 255;
  --panel-bg: rgba(255, 255, 255, 0.76);
  --panel-bg-strong: rgba(255, 255, 255, 0.94);
  --panel-border: rgba(20, 20, 20, 0.12);

  --gold: #c8a14a;
  --gold-bright: #e3bd68;
  --gold-soft: rgba(200, 161, 74, 0.22);

  --shadow-sm: 0 8px 24px rgba(20, 20, 20, 0.10);
  --shadow: 0 20px 50px rgba(20, 20, 20, 0.14);
  --shadow-deep: 0 26px 70px rgba(20, 20, 20, 0.22);
}

html[data-theme="dark"] {
  color-scheme: dark;

  --bg-image: url("/static/background_images/anarchylace_background_black.d187b67c02a1.webp");
  --bg-overlay: rgba(0, 0, 0, 0.24);

  --ink: #f4f4f4;
  --ink-muted: #b9b9b9;

  --panel-rgb: 10 10 10;
  --panel-bg: rgba(16, 16, 16, 0.76);
  --panel-bg-strong: rgba(13, 13, 13, 0.96);
  --panel-border: rgba(255, 255, 255, 0.15);

  --gold: #e0b45f;
  --gold-bright: #f2ce7b;
  --gold-soft: rgba(224, 180, 95, 0.28);

  --shadow-sm: 0 10px 28px rgba(0, 0, 0, 0.38);
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.56);
  --shadow-deep: 0 28px 80px rgba(0, 0, 0, 0.72);
}

/* =========================================================
   2. RESET / GLOBAL
   ========================================================= */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background:
    linear-gradient(var(--bg-overlay), var(--bg-overlay)),
    var(--bg-image) center / cover no-repeat fixed;
}

body {
  min-height: 100%;
  margin: 0;
  background: transparent;
  color: var(--ink);
  overflow-x: clip;
  text-rendering: optimizeLegibility;
}

img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

button,
input,
textarea,
select {
  font: inherit;
}

button,
summary,
a {
  -webkit-tap-highlight-color: transparent;
}

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

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0 0 0.65rem;
  color: var(--ink);
  line-height: 1.12;
  letter-spacing: -0.02em;
}

p,
li,
td,
th,
label,
small,
figcaption {
  color: var(--ink-muted);
  line-height: 1.65;
}

p {
  margin-top: 0;
}

:where(a, button, input, textarea, select, summary):focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

::selection {
  background: var(--gold-soft);
  color: var(--ink);
}

@media (max-width: 768px) {
  html {
    background-attachment: scroll;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* =========================================================
   3. LAYOUT
   ========================================================= */

.page {
  min-height: 100svh;
  padding-top: var(--page-top-gap);
  padding-bottom: clamp(2.5rem, 6vw, 4rem);
  position: relative;
  z-index: 1;
}

@supports (min-height: 100dvh) {
  .page {
    min-height: 100dvh;
  }
}

.shell {
  width: min(var(--container-max), calc(100% - (var(--container-pad) * 2)));
  margin-inline: auto;
}

.shell--wide {
  width: min(var(--wide-max), calc(100% - (var(--container-pad) * 2)));
  margin-inline: auto;
}

/* =========================================================
   4. NAVIGATION
   ========================================================= */

.topbar {
  position: sticky;
  top: 0;
  z-index: 10000;
  min-height: var(--nav-height);
  overflow: visible;

  background: color-mix(in srgb, var(--panel-bg-strong) 90%, transparent);
  border-bottom: 1px solid var(--panel-border);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);

  backdrop-filter: blur(18px) saturate(120%);
  -webkit-backdrop-filter: blur(18px) saturate(120%);
}

.topbar .container,
.topbar .shell {
  overflow: visible;
  padding-inline: var(--container-pad);
}

.nav-wrap {
  min-height: var(--nav-height);
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
  position: relative;
  overflow: visible;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  max-width: 62%;
  flex: 1 1 auto;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.brand-logo {
  width: auto;
  height: 60px;
  flex: 0 0 auto;
  object-fit: contain;
}

.brand-text {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(1.1rem, 2vw, 1.55rem);
  font-weight: 600;
}

.brand-mark {
  color: var(--ink);
}

.brand-amp {
  margin-inline: 0.24em;
  color: var(--gold);
}

.nav-desktop {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 8px 11px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  color: var(--ink-muted);
  font-size: 0.9rem;
  transition:
    color var(--transition-fast),
    border-color var(--transition-fast),
    background var(--transition-fast),
    transform var(--transition-fast);
}

.nav-link:hover {
  color: var(--ink);
  border-color: var(--panel-border);
  background: rgb(var(--panel-rgb) / 10%);
}

.nav-link.active {
  color: var(--ink);
  border-color: var(--gold-soft);
  background: color-mix(in srgb, var(--gold) 15%, transparent);
}

.theme-toggle,
.nav-mobile__trigger {
  min-width: 48px;
  min-height: 48px;
  border: 1px solid color-mix(in srgb, var(--gold) 35%, var(--panel-border));
  border-radius: var(--radius-sm);
  background: var(--panel-bg-strong);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition:
    transform var(--transition-fast),
    border-color var(--transition-fast),
    background var(--transition-fast);
}

.theme-toggle {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
}

.theme-toggle:hover,
.nav-mobile__trigger:hover {
  transform: translateY(-1px);
  border-color: var(--gold);
}

.theme-toggle__icon {
  font-size: 1.15rem;
  line-height: 1;
}

.nav-mobile {
  display: none;
  position: relative;
  margin-left: auto;
  flex: 0 0 auto;
  overflow: visible;
}

.nav-mobile__trigger {
  list-style: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding-inline: 14px;
  user-select: none;
}

.nav-mobile summary::-webkit-details-marker {
  display: none;
}

.nav-mobile[open] .nav-mobile__trigger {
  border-color: var(--gold);
  box-shadow: var(--focus-ring), var(--shadow-sm);
}

.nav-mobile__panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 10020;

  width: min(320px, calc(100vw - (var(--container-pad) * 2)));
  max-height: min(70vh, 520px);
  overflow-y: auto;

  display: grid;
  gap: 4px;
  padding: 10px;

  border: 1px solid color-mix(in srgb, var(--gold) 40%, var(--panel-border));
  border-radius: var(--radius);
  background: var(--panel-bg-strong);
  box-shadow: var(--shadow-deep);

  backdrop-filter: blur(22px) saturate(125%);
  -webkit-backdrop-filter: blur(22px) saturate(125%);
}

.nav-link--block {
  width: 100%;
  justify-content: flex-start;
  padding: 12px 14px;
}

.nav-mobile__divider {
  height: 1px;
  margin: 6px;
  background: linear-gradient(
    90deg,
    transparent,
    color-mix(in srgb, var(--gold) 62%, transparent),
    transparent
  );
}

/* The dropdown is absolute, so opening it never pushes the hero down. */
@media (max-width: 900px) {
  .nav-desktop {
    display: none !important;
  }

  .nav-mobile {
    display: block;
  }

  .nav-wrap {
    gap: 8px;
  }

  .brand {
    max-width: 58%;
  }

  .brand-logo {
    height: 52px;
  }
}

@media (max-width: 480px) {
  :root {
    --nav-height: 70px;
  }

  .brand {
    max-width: 44%;
  }

  .brand-text,
  .nav-mobile__label {
    display: none;
  }

  .brand-logo {
    height: 52px;
  }

  .nav-mobile__trigger {
    padding-inline: 12px;
  }

  .theme-toggle,
  .nav-mobile__trigger {
    min-width: 48px;
    min-height: 48px;
  }

  .nav-mobile__panel {
    position: fixed;
    top: calc(var(--nav-height) + 8px);
    right: var(--container-pad);
    left: var(--container-pad);
    width: auto;
  }
}

@media (prefers-color-scheme: dark) {
  .brand-logo {
    filter: invert(1) hue-rotate(180deg);
  }
}

html[data-theme="dark"] .brand-logo {
  filter: invert(1) hue-rotate(180deg);
}

html[data-theme="light"] .brand-logo {
  filter: none;
}

/* =========================================================
   5. PANELS, BUTTONS, MESSAGES
   ========================================================= */

.glass-panel,
.mag-glass {
  background:
    radial-gradient(
      125% 125% at 50% 35%,
      rgb(var(--panel-rgb) / 16%) 0%,
      rgb(var(--panel-rgb) / 9%) 48%,
      rgb(var(--panel-rgb) / 3%) 100%
    );
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px) saturate(120%);
  -webkit-backdrop-filter: blur(14px) saturate(120%);
}

.glass-panel {
  padding: clamp(14px, 2.5vw, 22px);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 15px;

  border: 1px solid var(--panel-border);
  border-radius: var(--radius-sm);
  background: var(--panel-bg-strong);
  color: var(--ink);

  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;

  transition:
    transform var(--transition-fast),
    border-color var(--transition-fast),
    background var(--transition-fast),
    box-shadow var(--transition-fast);
}

.button:hover {
  transform: translateY(-1px);
  border-color: var(--gold);
  box-shadow: var(--shadow-sm);
}

.button--gold {
  border-color: color-mix(in srgb, var(--gold) 65%, var(--panel-border));
  background: color-mix(in srgb, var(--gold) 18%, var(--panel-bg-strong));
}

.button--gold:hover {
  background: color-mix(in srgb, var(--gold) 25%, var(--panel-bg-strong));
}

.flash-stack {
  position: fixed;
  top: calc(var(--nav-height) + 10px);
  left: 50%;
  z-index: 9000;
  width: min(900px, calc(100% - (var(--container-pad) * 2)));
  transform: translateX(-50%);
  display: grid;
  gap: 10px;
  pointer-events: none;
}

.flash,
.message {
  padding: 12px 14px;
  border: 1px solid var(--gold-soft);
  border-radius: var(--radius-sm);
  background: var(--panel-bg-strong);
  color: var(--ink);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.flash {
  pointer-events: auto;
  font-weight: 600;
}

.messages {
  display: grid;
  gap: 10px;
  margin-bottom: 16px;
}

.message {
  font-size: 0.9rem;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.message.success,
.flash--success {
  border-color: rgba(85, 125, 81, 0.44);
  background: color-mix(in srgb, var(--success) 14%, var(--panel-bg-strong));
}

.message.error,
.flash--error,
.flash--danger {
  border-color: rgba(180, 69, 69, 0.48);
  background: color-mix(in srgb, var(--danger) 15%, var(--panel-bg-strong));
}

.message-hide {
  opacity: 0;
  transform: translateY(-6px);
}

/* =========================================================
   6. FORMS / CONTACT
   ========================================================= */

input,
textarea,
select {
  width: 100%;
  min-height: 46px;
  padding: 11px 13px;
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--panel-bg-strong) 92%, transparent);
  color: var(--ink);
  transition:
    border-color var(--transition-fast),
    background var(--transition-fast),
    box-shadow var(--transition-fast);
}

input:hover,
textarea:hover,
select:hover {
  border-color: color-mix(in srgb, var(--gold) 35%, var(--panel-border));
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--gold);
  background: var(--panel-bg-strong);
}

textarea {
  min-height: 150px;
  resize: vertical;
}

.contact {
  width: min(var(--container-max), calc(100% - (var(--container-pad) * 2)));
  margin-inline: auto;
}

.contact .form-label {
  display: block;
  margin-bottom: 6px;
  color: var(--ink-muted);
  font-size: 0.9rem;
}

.contact form {
  display: grid;
  gap: 12px;
}

/* =========================================================
   7. KINTSUGI DETAILS / FOOTER
   ========================================================= */

.kintsugi-line {
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    color-mix(in srgb, var(--gold) 65%, transparent),
    transparent
  );
}

.footer,
.site-footer {
  margin-top: clamp(2.5rem, 6vw, 4rem);
  padding: 1.35rem 0;
  border-top: 1px solid var(--panel-border);
  background: rgb(var(--panel-rgb) / 4%);
  color: var(--ink-muted);
}

.footer-inner {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding-inline: var(--container-pad);
  text-align: center;
  opacity: 0.86;
}

.footer-brand {
  font-weight: 600;
  letter-spacing: 0.05em;
}

.footer-copy {
  font-style: italic;
}

/* =========================================================
   8. LANDING PAGE
   ========================================================= */

.hero {
  position: relative;
  z-index: 1;
  padding-top: 0;
}

.hero__panel {
  margin-top: 0;
  margin-bottom: clamp(18px, 3vw, 30px);
  padding: clamp(16px, 3vw, 34px);
  border-color: color-mix(in srgb, var(--gold-bright) 82%, var(--panel-border));
}

.hero__panel--gallery {
  padding: clamp(14px, 2.5vw, 22px);
  border-color: color-mix(in srgb, var(--gold) 58%, var(--panel-border));
}

.hero__top {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.hero__spark {
  color: var(--gold);
}

.hero__title {
  max-width: 22ch;
  margin-bottom: 10px;
  font-size: clamp(2.1rem, 5.2vw, 3.5rem);
  line-height: 1.02;
}

.hero__gold {
  position: relative;
  display: inline-block;
  color: var(--gold);
  isolation: isolate;
}

.hero__gold::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0.08em;
  left: 0;
  z-index: -1;
  height: 0.18em;
  border-radius: 999px;
  background: var(--gold-soft);
}

.hero__lead {
  max-width: 72ch;
  margin: 6px 0 18px;
  font-size: clamp(0.98rem, 2vw, 1.125rem);
}

.hero__actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.hero__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(14px, 2vw, 20px);
  align-items: stretch;
}

.hero-card {
  min-height: 200px;
  display: flex;
  flex-direction: column;
  padding: clamp(16px, 2vw, 20px);
  border-color: color-mix(in srgb, var(--gold-bright) 82%, var(--panel-border));
  transition:
    transform var(--transition),
    border-color var(--transition),
    box-shadow var(--transition);
}

.hero-card:hover {
  transform: translateY(-3px);
  border-color: var(--gold);
  box-shadow: var(--shadow-deep);
}

.hero-card__title {
  margin-bottom: 8px;
  font-size: 1.05rem;
  transition: color var(--transition-fast);
}

.hero-card:hover .hero-card__title {
  color: var(--gold);
}

.hero-card p {
  margin: 0;
}

.hero-card__link {
  display: inline-flex;
  margin-top: auto;
  padding-top: 14px;
  color: var(--ink-muted);
  transition: color var(--transition-fast), transform var(--transition-fast);
}

.hero-card__link:hover {
  color: var(--gold);
  transform: translateX(2px);
}

.hero__footer {
  margin-top: 18px;
}

.hero__fineprint {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 12px 2px 0;
  color: var(--ink-muted);
  font-size: 0.78rem;
}

.hero__dot {
  opacity: 0.6;
}

.fabric-card__img {
  height: clamp(160px, 32vw, 220px);
  border-radius: 14px;
  background-position: center;
  background-size: cover;
  filter: saturate(1.05) contrast(1.02);
}

.image_button {
  width: min(196px, 100%);
  aspect-ratio: 49 / 24;
  margin: 14px auto 10px;

  border: 1px solid var(--panel-border);
  border-radius: 14px;

  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;

  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.20),
    0 8px 18px rgba(0, 0, 0, 0.16);

  opacity: 0.94;
  filter: saturate(1.08) contrast(1.04);

  transition:
    opacity var(--transition),
    transform var(--transition),
    box-shadow var(--transition);
}

.hero-card:hover .image_button {
  opacity: 1;
  transform: scale(1.02);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.22),
    0 14px 28px rgba(0, 0, 0, 0.22);
}

@media (max-width: 1100px) {
  .hero__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .hero__grid {
    grid-template-columns: 1fr;
  }

  .image_button {
    width: min(300px, 100%);
  }
}

@media (max-width: 480px) {
  .hero__panel {
    padding: 14px;
  }

  .hero__grid {
    gap: 14px;
  }

  .hero-card {
    min-height: 0;
    padding: 16px;
  }

  .image_button {
    width: 100%;
    max-width: 320px;
  }
}

/* =========================================================
   9. GALLERY LISTING
   ========================================================= */

.shop {
  width: min(var(--wide-max), calc(100% - (var(--container-pad) * 2)));
  margin-inline: auto;
  padding: clamp(0.6rem, 2vw, 1.6rem) 0 2rem;
}

.shop-header {
  margin-bottom: 1.25rem;
}

.shop-top {
  margin-bottom: 18px;
  padding: clamp(14px, 2.6vw, 22px);
}

.shop-header h1 {
  margin-bottom: 6px;
}

.shop-header p {
  margin-bottom: 0;
}

.collections {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 0;
}

.collections a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 13px;
  border: 1px solid var(--panel-border);
  border-radius: 999px;
  background: rgb(var(--panel-rgb) / 10%);
  color: var(--ink-muted);
  transition:
    transform var(--transition-fast),
    border-color var(--transition-fast),
    color var(--transition-fast),
    background var(--transition-fast);
}

.collections a:hover {
  transform: translateY(-1px);
  border-color: var(--gold);
  color: var(--ink);
}

.collections a.active {
  border-color: var(--gold);
  background: color-mix(in srgb, var(--gold) 16%, transparent);
  color: var(--ink);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
  gap: clamp(14px, 2vw, 22px);
  padding: 12px 0 6px;
  align-items: stretch;
}

.product-card {
  width: 100%;
  max-width: 380px;
  margin-inline: auto;
  overflow: hidden;

  display: flex;
  flex-direction: column;

  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  background:
    radial-gradient(
      125% 125% at 50% 28%,
      rgb(var(--panel-rgb) / 16%) 0%,
      rgb(var(--panel-rgb) / 9%) 55%,
      rgb(var(--panel-rgb) / 3%) 100%
    );
  box-shadow: var(--shadow);

  backdrop-filter: blur(13px);
  -webkit-backdrop-filter: blur(13px);

  transition:
    transform var(--transition),
    border-color var(--transition),
    box-shadow var(--transition);
}

.product-card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--gold) 55%, var(--panel-border));
  box-shadow: var(--shadow-deep);
}

.product-media {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-bottom: 1px solid var(--panel-border);
  background: rgb(var(--panel-rgb) / 6%);
}

.product-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 1 !important;
  visibility: visible !important;
  filter: saturate(1.04) contrast(1.03);
  transition: transform 300ms ease, filter 300ms ease;
}

.product-card:hover .product-img {
  transform: scale(1.035);
  filter: saturate(1.08) contrast(1.05);
}

.img-placeholder {
  min-height: 180px;
  display: grid;
  place-items: center;
  color: var(--ink-muted);
  text-align: center;
}

.product-meta {
  padding: 14px 15px 16px;
}

.product-title {
  margin: 0;
  color: var(--ink);
  font-size: 1.05rem;
}

/* Historical template compatibility: prices remain invisible. */
.product-price {
  display: none !important;
}

/* =========================================================
   10. PRODUCT DETAIL / IMAGE VIEWER
   ========================================================= */

.pd {
  width: min(var(--wide-max), calc(100% - (var(--container-pad) * 2)));
  margin-inline: auto;
  padding: clamp(0.6rem, 2vw, 1.6rem) 0 2rem;

  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  gap: clamp(16px, 2.2vw, 28px);
  align-items: start;
}

.pd-gallery {
  padding: clamp(14px, 2vw, 18px);
}

.pd-viewerbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-bottom: 12px;
}

.pd-viewerbtn {
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid var(--panel-border);
  border-radius: 999px;
  background: rgb(var(--panel-rgb) / 10%);
  color: var(--ink);
  cursor: pointer;
  font-size: 0.84rem;
  transition:
    transform var(--transition-fast),
    border-color var(--transition-fast),
    background var(--transition-fast);
}

.pd-viewerbtn:hover {
  transform: translateY(-1px);
  border-color: var(--gold);
}

.pd-viewerbtn.is-active {
  border-color: var(--gold);
  background: color-mix(in srgb, var(--gold) 16%, transparent);
}

.pd-main {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;

  display: flex;
  align-items: center;
  justify-content: center;

  border: 1px solid var(--panel-border);
  border-radius: 16px;
  background: rgb(var(--panel-rgb) / 6%);
}

.pd-main-img {
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 100%;
  padding: 14px;
  object-fit: contain;
  object-position: center;
}

.pd-main.is-fill .pd-main-img {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  padding: 0;
  object-fit: cover;
}

.pd-main-placeholder {
  color: var(--ink-muted);
}

.pd-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(74px, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.pd-thumb {
  display: grid;
  place-items: center;
  padding: 6px;

  border: 1px solid var(--panel-border);
  border-radius: 12px;
  background: rgb(var(--panel-rgb) / 8%);

  cursor: pointer;
  transition:
    transform var(--transition-fast),
    border-color var(--transition-fast);
}

.pd-thumb:hover {
  transform: translateY(-1px);
  border-color: var(--gold);
}

.pd-thumb img {
  width: 100%;
  height: 62px;
  border-radius: 9px;
  object-fit: cover;
}

@media (max-width: 1024px) {
  .pd {
    grid-template-columns: 1fr;
  }

  .pd-main {
    aspect-ratio: 4 / 5;
  }
}

/* =========================================================
   11. KIMONO HISTORY MAGAZINE
   ========================================================= */

.mag-page {
  max-width: var(--container-max);
  margin-inline: auto;
  padding:
    clamp(0.7rem, 2vw, 1.4rem)
    var(--container-pad)
    clamp(2rem, 5vw, 3rem);
}

.mag-kicker {
  margin: 0 0 0.6rem;
  color: var(--ink-muted);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.mag-title {
  margin: 0 0 0.8rem;
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.05;
}

.mag-meta {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.mag-tag {
  padding: 0.35rem 0.62rem;
  border: 1px solid var(--panel-border);
  border-radius: 999px;
  background: rgb(var(--panel-rgb) / 10%);
  color: var(--ink);
  font-size: 0.8rem;
}

.mag-hero,
.mag-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(260px, 0.9fr);
  gap: clamp(1rem, 2.4vw, 1.6rem);
  align-items: start;
}

.mag-hero {
  margin-bottom: 2rem;
}

.mag-grid {
  margin: 2.2rem 0;
}

.mag-hero__text,
.mag-body,
.mag-note,
.mag-quote,
.timeline__item {
  padding: clamp(16px, 2.4vw, 22px);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  background:
    radial-gradient(
      125% 125% at 50% 38%,
      rgb(var(--panel-rgb) / 18%) 0%,
      rgb(var(--panel-rgb) / 12%) 48%,
      rgb(var(--panel-rgb) / 6%) 100%
    );
  box-shadow: var(--shadow);
  backdrop-filter: blur(13px) saturate(120%);
  -webkit-backdrop-filter: blur(13px) saturate(120%);
}

.mag-dek {
  max-width: 62ch;
  color: var(--ink-muted);
  font-size: 1.05rem;
}

.mag-dek p {
  margin-bottom: 0.9rem;
}

.mag-dek p:last-child {
  margin-bottom: 0;
}

.mag-hero__image,
.mag-figure {
  margin: 0;
}

.mag-hero__frame {
  max-height: 880px;
  overflow: hidden;
  border: 1px solid var(--panel-border);
  border-radius: 22px;
  background: rgb(var(--panel-rgb) / 6%);
}

.mag-hero__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mag-hero__image figcaption,
.mag-figure figcaption {
  margin-top: 0.6rem;
  color: var(--ink-muted);
  font-size: 0.85rem;
  line-height: 1.5;
}

.mag-list {
  margin: 0.6rem 0 0;
  padding-left: 1.1rem;
}

.mag-note--featured {
  padding-left: 1.4rem;
  border-left: 3px solid var(--gold);
}

.mag-note--cta {
  position: sticky;
  top: calc(var(--nav-height) + 1rem);
}

.mag-quote-inline {
  margin: 1rem 0;
  padding: 14px 16px;
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-sm);
  background: rgb(var(--panel-rgb) / 10%);
}

.mag-quote-inline p {
  margin: 0;
  color: var(--ink);
}

.mag-quote-inline footer {
  margin-top: 8px;
  color: var(--ink-muted);
  font-size: 0.9rem;
  line-height: 1.45;
}

.mag-quote-inline footer span {
  display: block;
  margin-top: 2px;
  opacity: 0.9;
}

.mag-quote {
  margin: 2.4rem 0;
  text-align: center;
}

.mag-quote blockquote {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.2rem, 2.2vw, 1.8rem);
  line-height: 1.25;
}

.mag-quote__byline {
  margin: 0.8rem 0 0;
  color: var(--ink-muted);
  font-size: 0.9rem;
}

.mag-timeline h2 {
  margin-bottom: 1rem;
}

.timeline {
  display: grid;
  gap: 1rem;
}

.timeline__item {
  display: grid;
  grid-template-columns: minmax(150px, 200px) 1fr;
  gap: 1rem;
}

.timeline__date {
  color: var(--ink);
  font-weight: 700;
}

.timeline__content h3 {
  margin: 0 0 0.35rem;
}

.mag-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin: 2.2rem 0;
}

.mag-page .img-placeholder {
  min-height: 220px;
  height: auto;
  padding: 1rem;
  border: 1px dashed color-mix(in srgb, var(--panel-border) 62%, transparent);
  border-radius: var(--radius);
  background: rgb(var(--panel-rgb) / 6%);
}

.mag-page .img-placeholder--tall {
  min-height: 420px;
}

.mag-figure img {
  width: 100%;
  border: 1px solid var(--panel-border);
  border-radius: 18px;
}

.mag-figure figcaption {
  display: inline-block;
  padding: 0.45rem 0.65rem;
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-sm);
  background: rgb(var(--panel-rgb) / 10%);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.mag-grid--end {
  margin-top: 2.6rem;
}

.mag-outro {
  min-height: 220px;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.mag-outro-action {
  display: flex;
  justify-content: center;
  margin-top: 1.6rem;
}

@media (max-width: 900px) {
  .mag-hero,
  .mag-grid {
    grid-template-columns: 1fr;
  }

  .mag-strip {
    grid-template-columns: 1fr;
  }

  .timeline__item {
    grid-template-columns: 1fr;
  }

  .mag-note--cta {
    position: static;
  }

  .mag-hero__frame {
    max-height: 520px;
  }
}

/* =========================================================
   12. SMALL-SCREEN POLISH
   ========================================================= */

@media (max-width: 600px) {
  .page {
    padding-top: 0.3rem;
  }

  .glass-panel,
  .mag-hero__text,
  .mag-body,
  .mag-note,
  .mag-quote,
  .timeline__item {
    border-radius: 16px;
  }

  .flash-stack {
    top: calc(var(--nav-height) + 8px);
  }

  .hero__title {
    font-size: clamp(2rem, 10vw, 2.8rem);
  }

  .hero__actions .button {
    width: 100%;
  }

  .collections {
    gap: 8px;
  }

  .collections a {
    flex: 1 1 auto;
    justify-content: center;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .product-card {
    max-width: 100%;
  }

  .pd-viewerbar {
    justify-content: center;
    flex-wrap: wrap;
  }
}

/* =========================================================
   13. PRINT
   ========================================================= */

@media print {
  .topbar,
  .theme-toggle,
  .nav-mobile,
  .nav-desktop,
  .site-footer,
  .footer,
  .flash-stack,
  .messages,
  .hero__actions,
  .pd-viewerbar,
  .pd-thumbs {
    display: none !important;
  }

  html,
  body {
    background: #fff !important;
    color: #000 !important;
  }

  .page,
  .mag-page,
  .shop,
  .pd {
    width: 100%;
    max-width: none;
    padding: 0;
  }

  .glass-panel,
  .mag-glass,
  .product-card,
  .mag-hero__text,
  .mag-body,
  .mag-note,
  .mag-quote,
  .timeline__item {
    box-shadow: none;
    backdrop-filter: none;
    border-color: #bbb;
  }
}

/* =========================================================
   14. MOBILE MENU VISIBILITY HOTFIX
   Strong foreground drawer with reliable contrast
   ========================================================= */

@media (max-width: 900px) {
  .topbar {
    isolation: isolate;
  }

  .nav-mobile {
    z-index: 10030;
  }

  .nav-mobile__panel {
    z-index: 10040;
    padding: 12px;
    gap: 6px;

    background:
      linear-gradient(
        180deg,
        color-mix(in srgb, var(--panel-bg-strong) 98%, var(--gold) 2%),
        var(--panel-bg-strong)
      );

    border: 1px solid color-mix(in srgb, var(--gold) 72%, var(--panel-border));
    box-shadow:
      0 2px 0 rgba(255, 255, 255, 0.08) inset,
      0 26px 70px rgba(0, 0, 0, 0.58);

    opacity: 1;
    backdrop-filter: blur(24px) saturate(135%);
    -webkit-backdrop-filter: blur(24px) saturate(135%);
  }

  .nav-mobile__panel::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border-radius: inherit;
    background: var(--panel-bg-strong);
    opacity: 0.96;
  }

  .nav-mobile__panel .nav-link {
    min-height: 52px;
    padding: 13px 15px;

    justify-content: flex-start;

    border: 1px solid transparent;
    border-radius: 12px;

    background: rgb(var(--panel-rgb) / 7%);
    color: var(--ink);

    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 0.01em;

    text-shadow: none;
  }

  .nav-mobile__panel .nav-link + .nav-link {
    margin-top: 2px;
  }

  .nav-mobile__panel .nav-link:hover,
  .nav-mobile__panel .nav-link:focus-visible,
  .nav-mobile__panel .nav-link.active {
    border-color: color-mix(in srgb, var(--gold) 70%, var(--panel-border));
    background: color-mix(in srgb, var(--gold) 18%, var(--panel-bg-strong));
    color: var(--ink);
    transform: none;
  }

  .nav-mobile__divider {
    margin: 7px 4px;
    opacity: 1;
    background: linear-gradient(
      90deg,
      transparent,
      color-mix(in srgb, var(--gold) 82%, transparent),
      transparent
    );
  }
}

@media (max-width: 480px) {
  .nav-mobile__panel {
    top: calc(var(--nav-height) + 6px);
    right: 10px;
    left: 10px;

    width: auto;
    max-height: calc(100dvh - var(--nav-height) - 20px);

    border-radius: 18px;
  }

  .nav-mobile__panel .nav-link {
    min-height: 56px;
    font-size: 1.05rem;
  }
}

html[data-theme="light"] .nav-mobile__panel {
  background: rgba(250, 247, 239, 0.98);
}

html[data-theme="dark"] .nav-mobile__panel {
  background: rgba(10, 10, 10, 0.98);
}

@media (prefers-color-scheme: light) {
  html:not([data-theme]) .nav-mobile__panel {
    background: rgba(250, 247, 239, 0.98);
  }
}

@media (prefers-color-scheme: dark) {
  html:not([data-theme]) .nav-mobile__panel {
    background: rgba(10, 10, 10, 0.98);
  }
}