@font-face {
  font-family: "Bannikova";
  src: url("/fonts/BannikovaC.otf") format("opentype");
  font-display: swap;
}

:root {
  color-scheme: dark;
  --bg: #050505;
  --surface: #0d0d0d;
  --surface-raised: #151515;
  --text: #f4f4f2;
  --muted: #92928d;
  --line: rgba(255, 255, 255, .11);
  --line-strong: rgba(255, 255, 255, .22);
  --accent: #f2efe8;
  --danger: #ff8d8d;
  --radius: 22px;
  --page: min(1440px, calc(100% - 48px));
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 75% -10%, rgba(255, 255, 255, .09), transparent 30rem),
    var(--bg);
  color: var(--text);
  font: 15px/1.55 Inter, -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
}

body.overlayOpen { overflow: hidden; }

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

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

button { cursor: pointer; }

a { color: inherit; }

img { max-width: 100%; }

[hidden] { display: none !important; }

:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

.skipLink {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 200;
  padding: 10px 14px;
  border-radius: 10px;
  background: #fff;
  color: #000;
  transform: translateY(-150%);
}

.skipLink:focus { transform: none; }

.shopHeader {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: var(--page);
  min-height: 88px;
  margin: 0 auto;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  width: 112px;
  filter: brightness(0) invert(1);
}

.brand img {
  display: block;
  width: 100%;
  height: auto;
}

.headerNav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.headerNav > a {
  color: var(--muted);
  text-decoration: none;
}

.headerNav > a:hover { color: var(--text); }

.cartButton {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  padding: 0 8px 0 18px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(255, 255, 255, .06);
  color: var(--text);
}

.cartCount {
  display: grid;
  min-width: 28px;
  height: 28px;
  padding: 0 7px;
  place-items: center;
  border-radius: 999px;
  background: var(--accent);
  color: #080808;
  font-size: 12px;
  font-weight: 700;
}

.hero {
  display: grid;
  min-height: clamp(540px, 75vh, 820px);
  width: var(--page);
  margin: 0 auto;
  padding: clamp(100px, 13vw, 190px) 0 90px;
  align-content: center;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 900px;
  margin: 0;
  font-family: "Bannikova", Georgia, serif;
  font-size: clamp(58px, 9vw, 142px);
  font-weight: 400;
  letter-spacing: -.05em;
  line-height: .85;
  white-space: pre-line;
}

.heroText {
  max-width: 600px;
  margin: 38px 0 30px;
  color: #b7b7b2;
  font-size: clamp(16px, 2vw, 20px);
}

.primaryLink,
.primaryButton,
.secondaryButton {
  display: inline-flex;
  min-height: 52px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 14px;
  font-weight: 700;
  text-decoration: none;
}

.primaryLink {
  width: fit-content;
  padding: 0 24px;
  background: var(--accent);
  color: #090909;
}

.primaryButton {
  width: 100%;
  padding: 0 22px;
  background: var(--accent);
  color: #090909;
}

.secondaryButton {
  padding: 0 20px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--text);
}

.primaryLink:hover,
.primaryButton:hover { background: #fff; }

.secondaryButton:hover { background: rgba(255, 255, 255, .08); }

.catalog {
  padding: 0 0 clamp(80px, 10vw, 160px);
}

.catalogStatus {
  width: var(--page);
  min-height: 200px;
  margin: 0 auto;
  padding: 80px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  text-align: center;
}

.catalogStatus.isError { color: var(--danger); }

.catalogSection {
  width: var(--page);
  margin: 0 auto;
  padding: clamp(74px, 9vw, 130px) 0;
  border-top: 1px solid var(--line);
}

.sectionHeading {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(280px, 500px);
  gap: 40px;
  margin-bottom: 42px;
  align-items: end;
}

.sectionHeading h2 {
  margin: 0;
  font-family: "Bannikova", Georgia, serif;
  font-size: clamp(48px, 6vw, 88px);
  font-weight: 400;
  letter-spacing: -.04em;
  line-height: .95;
}

.sectionHeading > p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

.designRail {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(230px, 22vw);
  gap: 18px;
  overflow-x: auto;
  padding: 2px 2px 18px;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x proximity;
  scrollbar-color: rgba(255, 255, 255, .25) transparent;
  scrollbar-width: thin;
}

.productRail {
  display: grid;
  gap: 22px;
}

.productCard,
.designCard {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(145deg, #121212, #090909);
  scroll-snap-align: start;
}

.productCard {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(290px, .65fr);
}

.productVisual,
.designVisual {
  position: relative;
  display: grid;
  overflow: hidden;
  place-items: center;
  background: #111;
}

.productVisual { aspect-ratio: 16 / 9; }
.designVisual { aspect-ratio: 1; }

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

.cordCard .productVisual img { object-fit: contain; }
.designVisual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.abstractVisual {
  background:
    radial-gradient(circle at 50% 40%, transparent 0 19%, rgba(255, 255, 255, .18) 19.3% 19.8%, transparent 20.1%),
    repeating-radial-gradient(circle at 50% 40%, transparent 0 38px, rgba(255, 255, 255, .035) 39px 40px),
    linear-gradient(140deg, #1a1a1a, #080808);
}

.abstractVisual::after {
  content: "";
  position: absolute;
  width: 34%;
  aspect-ratio: 1;
  border: 1px solid rgba(255, 255, 255, .24);
  border-radius: 50%;
  box-shadow: 0 0 70px rgba(255, 255, 255, .08);
}

.visualLabel {
  position: relative;
  z-index: 1;
  max-width: 70%;
  color: rgba(255, 255, 255, .64);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
  text-align: center;
  text-transform: uppercase;
}

.stockBadge {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 999px;
  background: rgba(0, 0, 0, .7);
  color: #d8d8d3;
  font-size: 11px;
  backdrop-filter: blur(10px);
}

.stockBadge.out { color: #b9b9b4; }

.productBody {
  display: flex;
  min-height: 0;
  padding: 30px;
  flex-direction: column;
}

.productBody h3,
.designBody h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.25;
}

.productDescription {
  margin: 10px 0 24px;
  color: var(--muted);
  font-size: 13px;
}

.productFooter {
  display: flex;
  gap: 16px;
  margin-top: auto;
  align-items: center;
  justify-content: space-between;
}

.price {
  font-size: 18px;
  white-space: nowrap;
}

.addButton {
  min-height: 44px;
  padding: 0 18px;
  border: 0;
  border-radius: 12px;
  background: var(--accent);
  color: #080808;
  font-weight: 700;
}

.addButton:disabled {
  cursor: not-allowed;
  opacity: .4;
}

.designBody { padding: 18px; }

.designNumber {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.shopFooter {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  width: var(--page);
  margin: 0 auto;
  padding: 46px 0 max(46px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}

.footerBrand { width: 92px; }

.shopFooter p { margin: 0; }

.shopFooter > div {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  flex-direction: column;
}

.shopFooter a:not(.brand) { text-underline-offset: 3px; }

.backdrop,
.modalBackdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(0, 0, 0, .76);
  backdrop-filter: blur(8px);
}

.drawer {
  position: fixed;
  inset: 0 0 0 auto;
  z-index: 90;
  display: flex;
  width: min(520px, 100%);
  height: 100dvh;
  border-left: 1px solid var(--line);
  background: #0b0b0b;
  transform: translateX(102%);
  transition: transform .28s ease;
  flex-direction: column;
}

.drawer.open { transform: none; }

.drawerHeader,
.modalHeader {
  display: flex;
  padding: 26px 28px;
  border-bottom: 1px solid var(--line);
  align-items: center;
  justify-content: space-between;
}

.drawerHeader h2,
.modalHeader h2,
.successModal h2 {
  margin: 0;
  font-family: "Bannikova", Georgia, serif;
  font-size: 40px;
  font-weight: 400;
  letter-spacing: -.03em;
  line-height: 1;
}

.drawerHeader .eyebrow,
.modalHeader .eyebrow { margin-bottom: 7px; }

.iconButton {
  display: grid;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
  color: var(--text);
  place-items: center;
}

.iconButton svg {
  width: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.7;
}

.drawerBody {
  overflow-y: auto;
  padding: 24px 28px max(28px, env(safe-area-inset-bottom));
}

.cartItems {
  display: flex;
  gap: 12px;
  flex-direction: column;
}

.cartItem {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
}

.cartItemTop {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  justify-content: space-between;
}

.cartItem h3 {
  margin: 0;
  font-size: 15px;
}

.cartMeta {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.removeButton {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cartItemBottom {
  display: flex;
  margin-top: 16px;
  align-items: center;
  justify-content: space-between;
}

.quantityControl {
  display: inline-grid;
  grid-template-columns: 36px 36px 36px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.quantityControl button,
.quantityControl output {
  display: grid;
  min-height: 36px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  place-items: center;
}

.quantityControl button:hover { background: rgba(255, 255, 255, .08); }

.cartEmpty {
  padding: 60px 0;
  color: var(--muted);
  text-align: center;
}

.cartEmpty .secondaryButton { margin-top: 12px; }

.checkout {
  margin-top: 28px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
}

.checkout h3 { margin: 28px 0 16px; }

.cartTotal {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}

.cartTotal strong { font-size: 24px; }

.serverNote {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 11px;
}

.field { margin-bottom: 15px; }

.field label {
  display: block;
  margin-bottom: 7px;
  color: #c8c8c3;
  font-size: 12px;
  font-weight: 600;
}

.field label span {
  color: var(--muted);
  font-weight: 400;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 11px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  outline: 0;
  background: rgba(255, 255, 255, .06);
  color: var(--text);
}

.field textarea {
  min-height: 86px;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus { border-color: #fff; }

.consent {
  display: grid;
  margin: 20px 0;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
}

.consent input {
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
}

.formError {
  min-height: 1.4em;
  margin: 0 0 10px;
  color: var(--danger);
  font-size: 12px;
}

.modalBackdrop {
  z-index: 110;
  display: grid;
  overflow-y: auto;
  padding: 20px;
  place-items: center;
}

.modal {
  width: min(540px, 100%);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #0c0c0c;
  box-shadow: 0 30px 100px rgba(0, 0, 0, .7);
}

.modal form { padding: 24px 28px 28px; }

.configSummary {
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.configSummary strong {
  display: block;
  font-size: 18px;
}

.configSummary span {
  color: var(--muted);
  font-size: 13px;
}

.qtyField { max-width: 130px; }

.successModal {
  padding: 38px;
  text-align: center;
}

.successModal .eyebrow { margin-bottom: 12px; }

.successModal > p:not(.eyebrow) { color: var(--muted); }

.orderNumber {
  display: block;
  margin: 20px 0;
  font-size: clamp(30px, 8vw, 48px);
  letter-spacing: .04em;
  overflow-wrap: anywhere;
}

.successText { margin-bottom: 26px; }

.visuallyHidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

@media (max-width: 720px) {
  :root { --page: calc(100% - 32px); }

  .shopHeader { min-height: 72px; }
  .brand { width: 86px; }
  .headerNav { gap: 12px; }
  .headerNav > a { display: none; }

  .hero {
    min-height: 600px;
    padding: 100px 0 70px;
  }

  .hero h1 {
    font-size: clamp(54px, 19vw, 86px);
    line-height: .9;
  }

  .heroText { margin-top: 28px; }

  .catalogSection { padding: 72px 0; }

  .sectionHeading {
    grid-template-columns: 1fr;
    gap: 18px;
    margin-bottom: 28px;
  }

  .sectionHeading h2 { font-size: 52px; }

  .productRail {
    display: grid;
  }

  .productCard {
    display: block;
    min-height: 0;
  }

  .productVisual {
    min-height: 0;
    aspect-ratio: 16 / 9;
  }

  .productBody { min-height: 220px; padding: 22px; }

  .designRail {
    grid-auto-columns: minmax(220px, 72vw);
    margin-right: -16px;
  }

  .shopFooter {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .shopFooter > div { align-items: flex-start; }

  .drawerHeader,
  .modalHeader { padding: 20px 18px; }

  .drawerBody { padding: 20px 18px max(24px, env(safe-area-inset-bottom)); }

  .modalBackdrop {
    padding: 0;
    place-items: end center;
  }

  .modal {
    max-height: calc(100dvh - 12px);
    overflow-y: auto;
    border-radius: 22px 22px 0 0;
  }

  .modal form { padding: 20px 18px max(24px, env(safe-area-inset-bottom)); }
  .successModal { padding: 34px 22px max(28px, env(safe-area-inset-bottom)); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}
