:root {
  --bg: #f7f7f2;
  --surface: #ffffff;
  --surface-alt: #eceee8;
  --text: #121212;
  --muted: #686868;
  --line: #d8d8d2;
  --accent: #0a5f55;
  --accent-text: #ffffff;
  --danger: #b42318;
  --success: #0f766e;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 34px;
  --shadow: 0 28px 90px rgba(18, 18, 18, 0.14);
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-family:
    Helvetica Neue,
    Helvetica,
    Arial,
    sans-serif;
  line-height: 1.4;
  letter-spacing: 0;
}

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

button {
  color: inherit;
}

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

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

.site-shell {
  width: min(100%, 1440px);
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 24px;
  min-height: 76px;
  padding: 16px clamp(18px, 4vw, 56px);
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 92%, white);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 12px;
  min-width: 0;
  font-weight: 700;
  text-transform: uppercase;
}

.brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  background: var(--accent);
  color: var(--accent-text);
  font-size: 13px;
  line-height: 1;
}

.brand-text {
  overflow: hidden;
  max-width: 34vw;
  font-size: 13px;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.main-nav {
  display: flex;
  justify-content: center;
  gap: clamp(14px, 3vw, 34px);
  color: var(--muted);
  font-size: 13px;
  text-transform: uppercase;
}

.main-nav a:hover {
  color: var(--text);
}

.cart-trigger {
  justify-self: end;
}

.icon-button {
  position: relative;
  display: inline-grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--surface);
  cursor: pointer;
  transition:
    border-color 160ms ease,
    background 160ms ease,
    color 160ms ease;
}

.icon-button:hover {
  border-color: var(--text);
}

.icon-button svg {
  width: 18px;
  height: 18px;
}

.cart-count {
  position: absolute;
  right: -8px;
  top: -8px;
  display: grid;
  min-width: 22px;
  height: 22px;
  place-items: center;
  padding: 0 6px;
  border: 1px solid var(--bg);
  background: var(--accent);
  color: var(--accent-text);
  font-size: 11px;
  font-weight: 700;
}

.hero-band {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  min-height: min(74vh, 720px);
  border-bottom: 1px solid var(--line);
}

.hero-copy {
  display: flex;
  min-height: 520px;
  flex-direction: column;
  justify-content: center;
  padding: clamp(36px, 8vw, 100px) clamp(18px, 5vw, 72px);
}

.kicker,
.section-index {
  margin: 0 0 18px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 28px;
  font-size: clamp(44px, 6vw, 88px);
  font-weight: 700;
  line-height: 0.96;
  letter-spacing: 0;
}

.hero-copy p:not(.kicker) {
  max-width: 620px;
  margin-bottom: 34px;
  color: var(--muted);
  font-size: clamp(17px, 1.7vw, 22px);
}

.primary-action,
.ghost-action {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--text);
  border-radius: 0;
  padding: 12px 18px;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
}

.primary-action {
  background: var(--text);
  color: var(--bg);
}

.primary-action:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-text);
}

.primary-action:disabled,
.ghost-action:disabled {
  cursor: not-allowed;
  opacity: 0.46;
}

.ghost-action {
  background: transparent;
  color: var(--text);
}

.ghost-action:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.hero-media {
  position: relative;
  min-height: 520px;
  overflow: hidden;
  border-left: 1px solid var(--line);
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--line) 36%, transparent) 1px, transparent 1px),
    linear-gradient(color-mix(in srgb, var(--line) 36%, transparent) 1px, transparent 1px),
    var(--surface-alt);
  background-size: 72px 72px;
}

.hero-grid {
  display: grid;
  height: 100%;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(2, 1fr);
}

.hero-grid span {
  border-right: 1px solid color-mix(in srgb, var(--text) 16%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--text) 16%, transparent);
}

.hero-grid span:nth-child(1) {
  background: color-mix(in srgb, var(--accent) 15%, transparent);
}

.hero-grid span:nth-child(2) {
  background: var(--surface);
}

.hero-grid span:nth-child(3) {
  background: color-mix(in srgb, var(--text) 8%, transparent);
}

.hero-grid span:nth-child(4) {
  background: color-mix(in srgb, var(--accent) 24%, white);
}

.hero-card {
  position: absolute;
  right: clamp(22px, 4vw, 52px);
  bottom: clamp(22px, 4vw, 52px);
  width: min(280px, calc(100% - 44px));
  padding: 22px;
  border: 1px solid var(--text);
  background: var(--surface);
}

.hero-card span,
.hero-card small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.hero-card strong {
  display: block;
  margin: 18px 0 4px;
  font-size: 88px;
  line-height: 0.86;
}

.shop-section,
.info-band,
.legal-band {
  padding: clamp(36px, 6vw, 76px) clamp(18px, 4vw, 56px);
  border-bottom: 1px solid var(--line);
}

.section-head,
.info-band,
.legal-band {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: clamp(24px, 5vw, 72px);
}

.section-head {
  margin-bottom: 34px;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(30px, 4vw, 58px);
  line-height: 1;
}

.info-band p:not(.section-index),
.legal-band p:not(.section-index) {
  max-width: 880px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: clamp(18px, 2vw, 28px);
  line-height: 1.22;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.product-card {
  display: grid;
  min-width: 0;
  grid-template-rows: auto 1fr;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.product-image {
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border: 0;
  background: var(--surface-alt);
  cursor: pointer;
  padding: 0;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 260ms ease;
}

.product-card:hover .product-image img {
  transform: scale(1.025);
}

.product-body {
  display: flex;
  min-height: 260px;
  flex-direction: column;
  padding: clamp(18px, 2.4vw, 28px);
}

.product-type {
  margin-bottom: 18px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.product-title {
  margin-bottom: 14px;
  font-size: clamp(22px, 2vw, 30px);
  line-height: 1.05;
}

.product-description {
  margin-bottom: 24px;
  color: var(--muted);
}

.product-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 12px;
  margin-top: auto;
  margin-bottom: 20px;
}

.price {
  font-size: 22px;
  font-weight: 700;
}

.old-price {
  color: var(--muted);
  font-size: 14px;
  text-decoration: line-through;
}

.product-actions,
.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.secondary-action {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  background: transparent;
  padding: 10px 14px;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
}

.secondary-action:hover {
  border-color: var(--text);
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  align-items: center;
  justify-content: center;
  padding: clamp(14px, 3vw, 34px);
  background: rgba(10, 10, 10, 0.42);
}

.modal-backdrop.is-open {
  display: flex;
}

.modal {
  position: relative;
  width: min(100%, 840px);
  max-height: min(88vh, 980px);
  border: 1px solid var(--text);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.scrollable-modal {
  overflow: auto;
}

.modal-close {
  position: absolute;
  right: 16px;
  top: 16px;
  z-index: 2;
}

.modal-header,
.admin-head {
  padding: 34px 34px 20px;
  border-bottom: 1px solid var(--line);
}

.modal-header h2,
.admin-head h2 {
  padding-right: 46px;
}

.product-modal {
  width: min(100%, 980px);
}

.product-modal-content {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
}

.product-modal-image {
  min-height: 560px;
  background: var(--surface-alt);
}

.product-modal-image img {
  width: 100%;
  height: 100%;
  min-height: 560px;
  object-fit: cover;
}

.product-modal-info {
  display: flex;
  flex-direction: column;
  padding: clamp(28px, 4vw, 50px);
}

.product-modal-info h2 {
  margin-bottom: 20px;
}

.spec-list {
  display: grid;
  gap: 1px;
  margin: 28px 0;
  border: 1px solid var(--line);
  background: var(--line);
}

.spec-row {
  display: grid;
  grid-template-columns: minmax(90px, 0.7fr) minmax(0, 1.3fr);
  gap: 16px;
  padding: 12px;
  background: var(--surface);
}

.spec-row span:first-child {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.cart-modal,
.gate-modal,
.payment-modal,
.admin-modal {
  width: min(100%, 760px);
}

.admin-modal {
  width: min(100%, 1080px);
}

.checkout-modal.payment-modal {
  width: min(100%, 1240px);
  background: #ffffff;
  color: #080808;
}

.checkout-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 78px;
  padding: 18px 94px 18px clamp(22px, 4vw, 46px);
  border-bottom: 1px solid #dedede;
  background: #ffffff;
}

.checkout-topbar svg {
  width: 24px;
  height: 24px;
}

.checkout-logo {
  font-weight: 800;
  text-transform: uppercase;
}

.checkout-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 420px);
  min-height: 680px;
}

.checkout-main {
  padding: clamp(28px, 4vw, 52px);
}

.checkout-summary {
  display: flex;
  flex-direction: column;
  gap: 22px;
  border-left: 1px solid #dedede;
  background: #f6f6f6;
  padding: clamp(24px, 4vw, 42px);
}

.checkout-section {
  margin-bottom: 34px;
}

.checkout-section h2 {
  overflow: hidden;
  position: absolute;
  width: 1px;
  height: 1px;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.checkout-section h3 {
  margin-bottom: 18px;
  font-size: clamp(28px, 2.8vw, 40px);
  line-height: 1.05;
}

.checkout-section p {
  margin-bottom: 18px;
  color: #6f6f6f;
  font-size: 16px;
}

.express-section {
  text-align: center;
}

.express-section p {
  color: #6f6f6f;
  font-size: 19px;
}

.gpay-button {
  display: inline-flex;
  width: min(100%, 520px);
  min-height: 58px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 8px;
  background: #000000;
  color: #ffffff;
  font-size: 28px;
  cursor: pointer;
}

.gpay-button span {
  color: #4285f4;
  font-weight: 800;
}

.or-divider {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  margin: 28px 0 0;
  color: #737373;
  font-size: 18px;
  text-transform: uppercase;
}

.or-divider::before,
.or-divider::after {
  height: 1px;
  background: #dedede;
  content: "";
}

.checkout-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.text-link,
.checkout-links button {
  border: 0;
  background: transparent;
  padding: 0;
  color: #080808;
  text-decoration: underline;
  cursor: pointer;
}

.checkout-modal input,
.checkout-modal select {
  height: 56px;
  border-color: #d9d9d9;
  border-radius: 8px;
  background: #ffffff;
  color: #111111;
  font-size: 16px;
}

.checkout-modal form label {
  color: #6a6a6a;
}

.checkout-check {
  margin-top: 16px;
  font-size: 16px;
}

.shipping-note {
  display: grid;
  min-height: 86px;
  place-items: center;
  border-radius: 8px;
  background: #f4f4f4;
  color: #777777;
  padding: 18px;
  text-align: center;
}

.muted-copy {
  color: #737373;
}

.payment-method-box {
  overflow: hidden;
  border: 1px solid #d9d9d9;
  border-radius: 8px;
}

.payment-method-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 70px;
  border: 1px solid #111111;
  border-radius: 8px 8px 0 0;
  padding: 16px 22px;
}

.radio-line {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  color: #111111;
  font-size: 18px;
  text-transform: none;
}

.radio-line input {
  width: 18px;
  height: 18px;
}

.card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.card-badges span {
  display: grid;
  min-width: 44px;
  height: 30px;
  place-items: center;
  border: 1px solid #dddddd;
  border-radius: 4px;
  background: #ffffff;
  font-size: 12px;
  font-weight: 800;
}

.payment-card-fields {
  background: #f4f4f4;
  padding: 20px;
}

.payment-method-row {
  display: flex;
  min-height: 64px;
  align-items: center;
  border-top: 1px solid #d9d9d9;
  padding: 18px 22px;
  font-size: 18px;
}

.pay-now {
  min-height: 58px;
  border-radius: 8px;
  font-size: 18px;
  text-transform: none;
}

.checkout-links {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  margin-top: 34px;
  padding-top: 22px;
  border-top: 1px solid #dedede;
}

.cart-items {
  display: grid;
  gap: 1px;
  max-height: 48vh;
  overflow: auto;
  border-bottom: 1px solid var(--line);
  background: var(--line);
}

.cart-item {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px 34px;
  background: var(--surface);
}

.cart-item img {
  width: 72px;
  height: 72px;
  object-fit: cover;
}

.cart-item h3 {
  margin-bottom: 4px;
  font-size: 17px;
}

.cart-controls {
  display: inline-grid;
  grid-template-columns: 36px 42px 36px;
  align-items: center;
  border: 1px solid var(--line);
}

.cart-controls button {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.cart-controls span {
  text-align: center;
  font-weight: 700;
}

.cart-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 24px 34px 34px;
}

.cart-footer span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.cart-footer strong {
  font-size: 30px;
}

.empty-state {
  grid-column: 1 / -1;
  padding: 36px;
  color: var(--muted);
  background: var(--surface);
}

form label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

input,
textarea,
select {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--surface);
  color: var(--text);
  outline: 0;
}

input,
select {
  height: 44px;
  padding: 0 12px;
}

select {
  appearance: none;
}

textarea {
  min-height: 96px;
  resize: vertical;
  padding: 12px;
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--accent);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.wide {
  grid-column: 1 / -1;
}

.admin-login,
.admin-form {
  padding: 28px 34px 34px;
}

.payment-summary {
  display: grid;
  gap: 18px;
}

.summary-line {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  background: transparent;
  color: #111111;
}

.summary-line strong {
  white-space: nowrap;
}

.summary-product {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: start;
}

.summary-thumb {
  position: relative;
}

.summary-thumb img {
  width: 68px;
  height: 68px;
  border: 1px solid #dedede;
  border-radius: 8px;
  object-fit: cover;
}

.summary-qty {
  position: absolute;
  right: -8px;
  top: -8px;
  display: grid;
  min-width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 999px;
  background: #111111;
  color: #ffffff;
  font-size: 12px;
}

.summary-product h3 {
  margin: 0 0 4px;
  font-size: 16px;
  line-height: 1.25;
}

.summary-product p,
.summary-note {
  margin: 0;
  color: #747474;
  font-size: 14px;
}

.summary-total strong {
  font-size: 26px;
}

.discount-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
}

.discount-row .secondary-action {
  min-height: 56px;
  border-color: #d9d9d9;
  border-radius: 8px;
  background: #ffffff;
  color: #777777;
}

.divider {
  height: 1px;
  margin: 26px 0;
  background: var(--line);
}

.checkbox-line {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 10px;
  color: var(--muted);
  text-transform: none;
}

.checkbox-line input {
  width: 18px;
  height: 18px;
  margin-top: 1px;
}

.full-action {
  width: 100%;
  margin-top: 20px;
}

.payment-state,
.form-error,
.smtp-status {
  min-height: 24px;
  margin: 18px 0 0;
  color: var(--muted);
}

.payment-state.is-error,
.form-error.is-error,
.smtp-status.is-error {
  color: var(--danger);
}

.payment-state.is-loading {
  color: var(--text);
}

.loader {
  display: inline-block;
  width: 18px;
  height: 18px;
  margin-right: 10px;
  border: 2px solid var(--line);
  border-top-color: var(--accent);
  vertical-align: middle;
  animation: spin 800ms linear infinite;
}

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

.admin-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.tabs {
  display: flex;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
}

.tab-button {
  flex: 1;
  min-width: 130px;
  border: 0;
  border-right: 1px solid var(--line);
  background: var(--surface);
  padding: 16px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
}

.tab-button.is-active {
  background: var(--text);
  color: var(--bg);
}

.admin-panel {
  display: none;
}

.admin-panel.is-active {
  display: block;
}

fieldset {
  margin: 0 0 24px;
  padding: 0;
  border: 0;
}

legend {
  width: 100%;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

.preset-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.preset-button {
  display: grid;
  gap: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 12px;
  text-align: left;
  cursor: pointer;
}

.preset-button.is-active {
  border-color: var(--text);
}

.preset-swatches {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  height: 34px;
  border: 1px solid var(--line);
}

.preset-name {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.admin-split {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  gap: 1px;
  background: var(--line);
}

.admin-split > * {
  background: var(--surface);
}

.admin-list {
  display: grid;
  align-content: start;
  max-height: 760px;
  overflow: auto;
}

.admin-product {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.admin-product img {
  width: 68px;
  height: 68px;
  object-fit: cover;
}

.admin-product h3 {
  overflow-wrap: anywhere;
  margin-bottom: 4px;
  font-size: 16px;
}

.admin-product p {
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 13px;
}

.admin-product-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mail-products {
  display: grid;
  gap: 1px;
  margin-top: 20px;
  border: 1px solid var(--line);
  background: var(--line);
}

.mail-product {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 90px;
  gap: 12px;
  align-items: center;
  padding: 12px;
  background: var(--surface);
}

.mail-product input {
  text-align: center;
}

@media (max-width: 980px) {
  .topbar {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .main-nav {
    display: none;
  }

  .hero-band,
  .product-modal-content,
  .checkout-layout,
  .admin-split {
    grid-template-columns: 1fr;
  }

  .checkout-summary {
    order: -1;
    border-left: 0;
    border-bottom: 1px solid #dedede;
  }

  .hero-copy,
  .hero-media {
    min-height: 430px;
  }

  .hero-media {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .section-head,
  .info-band,
  .legal-band {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .preset-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .topbar {
    min-height: 66px;
    padding: 12px 14px;
  }

  .brand-text {
    max-width: 54vw;
  }

  h1 {
    font-size: 44px;
  }

  .hero-copy,
  .shop-section,
  .info-band,
  .legal-band {
    padding: 30px 14px;
  }

  .hero-copy,
  .hero-media {
    min-height: 360px;
  }

  .product-grid,
  .form-grid,
  .preset-list {
    grid-template-columns: 1fr;
  }

  .product-body {
    min-height: 220px;
  }

  .modal-backdrop {
    align-items: flex-end;
    padding: 0;
  }

  .modal {
    width: 100%;
    max-height: 92vh;
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
  }

  .modal-header,
  .admin-head,
  .admin-login,
  .admin-form {
    padding-right: 18px;
    padding-left: 18px;
  }

  .checkout-topbar {
    min-height: 64px;
    padding-right: 76px;
    padding-left: 18px;
  }

  .checkout-main,
  .checkout-summary {
    padding: 24px 18px;
  }

  .checkout-section h3 {
    font-size: 28px;
  }

  .gpay-button {
    font-size: 22px;
  }

  .summary-product,
  .discount-row {
    grid-template-columns: 1fr;
  }

  .payment-method-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .cart-item {
    grid-template-columns: 58px minmax(0, 1fr);
    padding: 14px 18px;
  }

  .cart-item img {
    width: 58px;
    height: 58px;
  }

  .cart-controls {
    grid-column: 1 / -1;
    width: max-content;
  }

  .cart-footer {
    align-items: stretch;
    flex-direction: column;
    padding: 20px 18px 24px;
  }

  .product-modal-image,
  .product-modal-image img {
    min-height: 320px;
  }

  .spec-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }

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

* {
  scrollbar-width: thin;
  scrollbar-color: color-mix(in srgb, var(--accent) 58%, var(--line)) transparent;
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-track {
  background: transparent;
}

*::-webkit-scrollbar-thumb {
  border: 3px solid transparent;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 58%, var(--line));
  background-clip: padding-box;
}

input,
textarea,
select {
  border-color: color-mix(in srgb, var(--line) 86%, transparent);
  border-radius: var(--radius-sm);
  box-shadow: inset 0 0 0 1px transparent;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    background 160ms ease;
}

select {
  padding-right: 40px;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position:
    calc(100% - 20px) 50%,
    calc(100% - 14px) 50%;
  background-size:
    6px 6px,
    6px 6px;
  background-repeat: no-repeat;
}

input:hover,
textarea:hover,
select:hover {
  border-color: color-mix(in srgb, var(--accent) 30%, var(--line));
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 14%, transparent);
}

input[type="checkbox"],
input[type="radio"] {
  display: grid;
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  place-items: center;
  margin: 0;
  border: 1px solid var(--line);
  appearance: none;
  cursor: pointer;
}

input[type="checkbox"] {
  border-radius: 6px;
}

input[type="radio"] {
  border-radius: 999px;
}

input[type="checkbox"]:checked,
input[type="radio"]:checked {
  border-color: var(--accent);
  background: var(--accent);
}

input[type="checkbox"]:checked::after {
  width: 10px;
  height: 6px;
  border: 2px solid var(--accent-text);
  border-top: 0;
  border-right: 0;
  content: "";
  transform: rotate(-45deg);
}

input[type="radio"]:checked::after {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent-text);
  content: "";
}

input[type="file"] {
  height: auto;
  padding: 10px;
}

input[type="file"]::file-selector-button {
  margin-right: 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-alt);
  color: var(--text);
  padding: 8px 12px;
  font-weight: 700;
  cursor: pointer;
}

.accordion-list {
  display: grid;
  gap: 12px;
}

.accordion-item {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.accordion-trigger {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  border: 0;
  background: transparent;
  padding: 18px 20px;
  color: var(--text);
  font-weight: 700;
  cursor: pointer;
}

.accordion-trigger svg {
  transition: transform 180ms ease;
}

.accordion-item.is-open .accordion-trigger svg {
  transform: rotate(180deg);
}

.accordion-panel {
  display: none;
  padding: 0 20px 20px;
  color: var(--muted);
}

.accordion-item.is-open .accordion-panel {
  display: block;
}

.editorial-blocks {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin: clamp(14px, 2.8vw, 34px);
}

.editorial-blocks article {
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--surface);
  padding: clamp(24px, 4vw, 42px);
}

.editorial-blocks span {
  display: inline-flex;
  margin-bottom: 34px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
}

.editorial-blocks h3 {
  margin-bottom: 14px;
  font-size: clamp(28px, 4vw, 48px);
  line-height: 1;
}

.editorial-blocks p,
.feedback-form p {
  color: var(--muted);
}

.feedback-form {
  display: grid;
  gap: 18px;
}

.product-gallery {
  position: relative;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 10px;
  padding: 10px;
  background: var(--surface);
}

.product-thumbs {
  display: grid;
  align-content: start;
  gap: 8px;
  max-height: 290px;
  overflow: auto;
}

.product-thumbs button {
  overflow: hidden;
  width: 48px;
  height: 48px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-alt);
  padding: 0;
  cursor: pointer;
}

.product-thumbs button.is-active {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 14%, transparent);
}

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

.rating-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--muted);
  font-size: 13px;
}

.stars {
  display: inline-flex;
  gap: 1px;
  color: color-mix(in srgb, var(--line) 70%, var(--muted));
  letter-spacing: 0;
}

.stars span {
  position: relative;
}

.stars .is-filled,
.stars .is-half {
  color: var(--accent);
}

.availability {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  color: var(--success);
  font-size: 13px;
  font-weight: 700;
}

.availability span {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--success);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--success) 14%, transparent);
}

.inline-qty {
  display: inline-grid;
  grid-template-columns: 38px 38px 38px;
  align-items: center;
  max-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  opacity: 0;
  transform: translateX(-8px);
  transition:
    max-width 220ms ease,
    opacity 180ms ease,
    transform 180ms ease;
}

.inline-qty.is-active {
  max-width: 118px;
  opacity: 1;
  transform: translateX(0);
}

.inline-qty button {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.inline-qty span {
  text-align: center;
  font-weight: 800;
}

.product-modal-gallery {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 12px;
  padding: 12px;
}

.modal-thumbs {
  max-height: 560px;
}

.modal-thumbs button {
  width: 62px;
  height: 62px;
}

.admin-modal {
  width: min(98vw, 1320px);
  max-height: min(92vh, 1040px);
}

.admin-layout {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  min-height: min(82vh, 920px);
}

.admin-content {
  max-height: min(92vh, 1040px);
}

.admin-dock {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
  justify-content: center;
  border-right: 1px solid var(--line);
  border-bottom: 0;
  background: color-mix(in srgb, var(--surface-alt) 45%, var(--surface));
  padding: 18px 12px;
}

.admin-dock .tab-button {
  flex: 0 0 auto;
  display: grid;
  width: 70px;
  min-width: 0;
  gap: 6px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 12px 8px;
  text-transform: none;
}

.admin-dock .tab-button svg {
  width: 18px;
  height: 18px;
}

.admin-dock .tab-button span {
  font-size: 11px;
}

.admin-head-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.admin-eye-button {
  position: fixed;
  left: 18px;
  top: 18px;
  z-index: 100;
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  box-shadow: var(--shadow);
  cursor: pointer;
}

.spec-builder {
  display: grid;
  gap: 14px;
  margin: 22px 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: color-mix(in srgb, var(--surface-alt) 40%, transparent);
}

.spec-builder-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.spec-builder-head h3 {
  margin: 0;
  font-size: 18px;
}

.spec-edit-row {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr) 42px;
  gap: 10px;
  margin-top: 10px;
}

.save-status.is-success,
.form-error.is-success {
  color: var(--success);
}

.status-icon {
  position: relative;
}

.status-icon .loader {
  display: block;
  width: 36px;
  height: 36px;
  border-width: 3px;
  border-color: color-mix(in srgb, var(--accent) 16%, transparent);
  border-top-color: var(--accent);
}

.status-icon svg {
  width: 34px;
  height: 34px;
}

@media (max-width: 980px) {
  .editorial-blocks,
  .admin-layout {
    grid-template-columns: 1fr;
  }

  .admin-dock {
    position: sticky;
    top: 0;
    z-index: 3;
    flex-direction: row;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

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

  .product-thumbs,
  .modal-thumbs {
    display: flex;
    max-height: none;
    overflow-x: auto;
  }
}

@media (max-width: 640px) {
  .editorial-blocks {
    margin: 14px;
  }

  .spec-edit-row {
    grid-template-columns: 1fr;
  }
}

.site-shell {
  width: min(100%, 1480px);
}

.topbar {
  top: 12px;
  margin: 12px clamp(12px, 2.6vw, 34px) 0;
  min-height: 68px;
  border: 1px solid color-mix(in srgb, var(--line) 82%, transparent);
  border-radius: var(--radius-lg);
  background: color-mix(in srgb, var(--bg) 88%, white);
  box-shadow: 0 16px 50px rgba(18, 18, 18, 0.06);
}

.brand-avatar-wrap {
  position: relative;
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
}

.brand-avatar-wrap > * {
  grid-area: 1 / 1;
}

.brand-mark,
.brand-avatar,
.footer-avatar {
  border-radius: 999px;
}

.brand-avatar {
  width: 38px;
  height: 38px;
  object-fit: cover;
}

.brand-mark {
  width: 38px;
  height: 38px;
}

.icon-button,
.primary-action,
.ghost-action,
.secondary-action,
input,
textarea,
select,
.cart-controls,
.preset-button {
  border-radius: var(--radius-sm);
}

.primary-action,
.ghost-action,
.secondary-action {
  min-height: 46px;
  padding-right: 20px;
  padding-left: 20px;
}

.hero-band,
.shop-section,
.info-band,
.legal-band,
.site-footer {
  margin: clamp(14px, 2.8vw, 34px);
}

.hero-band {
  overflow: hidden;
  min-height: min(70vh, 680px);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--surface);
}

.hero-copy {
  min-height: 480px;
}

.hero-media {
  min-height: 480px;
  border-left: 1px solid var(--line);
  border-radius: 0 var(--radius-xl) var(--radius-xl) 0;
}

.hero-card {
  border-color: var(--line);
  border-radius: var(--radius-lg);
  box-shadow: 0 18px 50px rgba(18, 18, 18, 0.08);
}

.shop-section,
.info-band,
.legal-band {
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: color-mix(in srgb, var(--surface) 72%, transparent);
}

.product-grid {
  gap: 18px;
  border: 0;
}

.product-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  transition:
    border-color 160ms ease,
    transform 160ms ease,
    box-shadow 160ms ease;
}

.product-card:hover {
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
  box-shadow: 0 18px 48px rgba(18, 18, 18, 0.08);
  transform: translateY(-2px);
}

.product-image {
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.legal-summary {
  display: grid;
  gap: 22px;
}

.legal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.site-footer {
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--text);
  color: var(--bg);
  padding: clamp(28px, 5vw, 64px);
}

.footer-brand-block {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 18px 24px;
  align-items: center;
  margin-bottom: clamp(34px, 5vw, 64px);
}

.footer-avatar {
  width: 76px;
  height: 76px;
  grid-row: span 3;
  object-fit: cover;
}

.footer-brand-block .kicker {
  margin: 0;
  color: color-mix(in srgb, var(--accent) 76%, var(--bg));
}

.footer-brand-block h2 {
  max-width: 760px;
  font-size: clamp(40px, 7vw, 96px);
}

.footer-brand-block p:not(.kicker) {
  max-width: 720px;
  margin: 0;
  color: color-mix(in srgb, var(--bg) 72%, transparent);
  font-size: clamp(17px, 2vw, 24px);
}

.footer-columns {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  padding: 28px 0;
  border-top: 1px solid color-mix(in srgb, var(--bg) 20%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--bg) 20%, transparent);
}

.footer-columns h3 {
  margin-bottom: 18px;
  color: color-mix(in srgb, var(--bg) 62%, transparent);
  font-size: 12px;
  text-transform: uppercase;
}

.footer-columns a,
.footer-columns button {
  display: block;
  width: fit-content;
  border: 0;
  background: transparent;
  padding: 7px 0;
  color: var(--bg);
  font-size: 18px;
  text-align: left;
  cursor: pointer;
}

.footer-columns a:hover,
.footer-columns button:hover {
  color: color-mix(in srgb, var(--accent) 72%, var(--bg));
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding-top: 24px;
  color: color-mix(in srgb, var(--bg) 62%, transparent);
  font-size: 13px;
}

.modal-backdrop {
  background: rgba(4, 4, 4, 0.76);
  backdrop-filter: blur(8px);
}

.status-backdrop {
  z-index: 90;
  background: rgba(4, 4, 4, 0.84);
}

.modal {
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--line) 78%, transparent);
  border-radius: var(--radius-xl);
}

.scrollable-modal {
  overflow: auto;
}

.modal-close {
  border-radius: 999px;
}

.product-modal-image,
.product-modal-image img {
  border-radius: var(--radius-xl) 0 0 var(--radius-xl);
}

.spec-list,
.cart-items,
.mail-products {
  overflow: hidden;
  border-radius: var(--radius-md);
}

.cart-item img,
.admin-product img {
  border-radius: var(--radius-sm);
}

.checkout-modal.payment-modal {
  border-radius: var(--radius-xl);
  background: #ffffff;
}

.checkout-topbar {
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
}

.checkout-layout {
  grid-template-columns: minmax(0, 1fr) minmax(340px, 430px);
}

.secure-label {
  color: #777777;
  font-size: 14px;
}

.payment-method-box,
.payment-method-head,
.checkout-modal input,
.checkout-modal select,
.shipping-note,
.discount-row .secondary-action {
  border-radius: 14px;
}

.payment-method-head {
  border-color: #d9d9d9;
}

.payment-method-row {
  display: none;
}

.payment-card-fields {
  border-radius: 0 0 14px 14px;
}

.pay-now:disabled {
  background: #c9c9c9;
  border-color: #c9c9c9;
  color: #ffffff;
}

.document-modal {
  width: min(100%, 820px);
}

.document-content {
  padding: clamp(24px, 4vw, 46px);
  color: var(--muted);
  font-size: clamp(16px, 1.6vw, 20px);
  line-height: 1.65;
  white-space: pre-wrap;
}

.status-modal {
  width: min(100%, 440px);
  padding: 42px;
  text-align: center;
}

.status-modal h2 {
  margin-bottom: 12px;
  font-size: clamp(26px, 4vw, 36px);
}

.status-modal p {
  margin: 0;
  color: var(--muted);
}

.status-icon {
  display: grid;
  width: 72px;
  height: 72px;
  place-items: center;
  margin: 0 auto 24px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 12%, var(--surface));
  color: var(--accent);
}

.status-icon .loader {
  width: 32px;
  height: 32px;
  margin: 0;
}

.status-icon.is-error {
  background: color-mix(in srgb, var(--danger) 12%, white);
  color: var(--danger);
}

.avatar-admin-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: color-mix(in srgb, var(--surface-alt) 50%, transparent);
}

.avatar-admin-row img {
  width: 58px;
  height: 58px;
  border-radius: 999px;
  object-fit: cover;
}

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

@media (max-width: 980px) {
  .hero-media {
    border-left: 0;
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
  }

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

  .footer-brand-block {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .topbar {
    top: 0;
    margin: 0;
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  }

  .hero-band,
  .shop-section,
  .info-band,
  .legal-band,
  .site-footer {
    margin: 14px;
    border-radius: var(--radius-lg);
  }

  .modal {
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }

  .status-backdrop {
    align-items: center;
    padding: 18px;
  }

  .status-modal {
    border-radius: var(--radius-lg);
  }

  .product-modal-image,
  .product-modal-image img {
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }
}

.catalog-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 360px);
  gap: 18px;
  align-items: end;
  margin: -10px 0 28px;
}

.product-theme-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.product-theme-filters button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  padding: 8px 15px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  cursor: pointer;
  transition:
    border-color 160ms ease,
    background 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

.product-theme-filters button:hover,
.product-theme-filters button.is-active {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--accent-text);
  transform: translateY(-1px);
}

.catalog-search {
  min-width: 0;
}

.catalog-search input {
  height: 50px;
  border-radius: 999px;
  padding: 0 18px;
}

.product-card {
  max-height: 660px;
}

.product-body {
  min-height: 0;
  max-height: 360px;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.product-actions {
  align-items: center;
}

.product-actions .inline-qty {
  max-width: 118px;
  opacity: 1;
  transform: none;
}

.product-modal-content {
  min-height: 0;
}

.product-modal-info {
  min-height: 0;
  max-height: min(88vh, 980px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.product-more {
  margin: 0 0 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: color-mix(in srgb, var(--surface-alt) 42%, transparent);
}

.product-more summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 15px 16px;
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
  list-style: none;
  text-transform: uppercase;
  cursor: pointer;
}

.product-more summary::-webkit-details-marker {
  display: none;
}

.product-more summary svg {
  width: 18px;
  height: 18px;
  transition: transform 180ms ease;
}

.product-more[open] summary svg {
  transform: rotate(180deg);
}

.product-more-panel {
  display: grid;
  gap: 12px;
  padding: 0 16px 16px;
  color: var(--muted);
}

.product-more-panel p {
  margin: 0;
}

.product-more-panel ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 18px;
}

.modal-backdrop {
  display: flex;
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 280ms ease,
    visibility 0s linear 280ms;
}

.modal-backdrop.is-open {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
  transition-delay: 0s;
}

.modal {
  overflow: auto;
  opacity: 0;
  transform: translateY(18px) scale(0.985);
  transition:
    opacity 300ms cubic-bezier(0.22, 1, 0.36, 1),
    transform 300ms cubic-bezier(0.22, 1, 0.36, 1);
}

.modal-backdrop.is-open .modal {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.accordion-panel {
  display: grid;
  grid-template-rows: 0fr;
  padding: 0 20px;
  color: var(--muted);
  transition:
    grid-template-rows 260ms ease,
    padding-bottom 260ms ease;
}

.accordion-panel > p {
  min-height: 0;
  margin: 0;
  overflow: hidden;
}

.accordion-item.is-open .accordion-panel {
  display: grid;
  grid-template-rows: 1fr;
  padding-bottom: 20px;
}

.editorial-blocks {
  gap: 22px;
}

.editorial-card {
  position: relative;
  overflow: hidden;
  min-height: 360px;
  border-radius: var(--radius-xl);
  isolation: isolate;
}

.editorial-card::before {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--line) 52%, transparent) 1px, transparent 1px),
    linear-gradient(color-mix(in srgb, var(--line) 44%, transparent) 1px, transparent 1px);
  background-size: 42px 42px;
  content: "";
  opacity: 0.55;
}

.editorial-card::after {
  position: absolute;
  right: -1px;
  bottom: -1px;
  width: 52%;
  height: 46%;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
  background: color-mix(in srgb, var(--accent) 11%, var(--surface));
  content: "";
  z-index: -1;
}

.editorial-visual {
  display: grid;
  gap: 10px;
  width: min(100%, 320px);
  margin-bottom: clamp(34px, 5vw, 74px);
}

.editorial-tick {
  display: block;
  width: 64%;
  height: 12px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--text) 16%, transparent);
}

.editorial-tick.is-long {
  width: 88%;
  background: color-mix(in srgb, var(--accent) 28%, transparent);
}

.editorial-product-mini {
  width: 116px;
  aspect-ratio: 4 / 3;
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent) 28%, white), transparent),
    var(--surface-alt);
  box-shadow: 18px 18px 0 color-mix(in srgb, var(--text) 8%, transparent);
}

.identity-chip {
  display: inline-block;
  width: 64px;
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
}

.identity-chip:nth-child(2) {
  width: 92px;
  background: var(--accent);
}

.identity-chip:nth-child(3) {
  width: 48px;
  background: var(--text);
}

.identity-stripe {
  width: min(100%, 280px);
  height: 76px;
  margin-top: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background:
    linear-gradient(90deg, var(--surface) 0 30%, var(--surface-alt) 30% 58%, var(--accent) 58% 76%, var(--text) 76%);
}

.editorial-number {
  display: inline-grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
}

.footer-columns {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.footer-info-block ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-info-block li {
  position: relative;
  padding-left: 18px;
  color: color-mix(in srgb, var(--bg) 82%, transparent);
  font-size: 16px;
  line-height: 1.35;
}

.footer-info-block li::before {
  position: absolute;
  left: 0;
  top: 0.58em;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 72%, var(--bg));
  content: "";
}

.theme-picker {
  position: relative;
}

.theme-picker-button,
.theme-picker-menu button {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--text);
  padding: 12px;
  text-align: left;
  cursor: pointer;
}

.theme-picker-button {
  min-height: 56px;
  justify-content: space-between;
}

.theme-picker-button > span:not(.theme-swatches) {
  margin-right: auto;
  font-weight: 800;
}

.theme-picker-button svg {
  width: 18px;
  height: 18px;
  color: var(--muted);
  transition: transform 180ms ease;
}

.theme-picker.is-open .theme-picker-button svg {
  transform: rotate(180deg);
}

.theme-picker-menu {
  position: absolute;
  inset: calc(100% + 8px) 0 auto;
  z-index: 12;
  display: grid;
  gap: 6px;
  max-height: 300px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  padding: 8px;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.theme-picker.is-open .theme-picker-menu {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.theme-picker-menu button {
  border-color: transparent;
  border-radius: var(--radius-sm);
}

.theme-picker-menu button:hover,
.theme-picker-menu button.is-active {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 9%, var(--surface));
}

.theme-swatches {
  display: grid;
  grid-template-columns: repeat(4, 18px);
  overflow: hidden;
  flex: 0 0 auto;
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 999px;
}

.theme-swatches span {
  display: block;
}

.product-theme-manager {
  display: grid;
  gap: 14px;
}

.theme-manager-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.admin-theme-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-theme-pill {
  display: inline-grid;
  grid-template-columns: auto auto 34px;
  gap: 8px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  padding: 6px 7px 6px 14px;
}

.admin-theme-pill span {
  font-weight: 800;
}

.admin-theme-pill small {
  color: var(--muted);
}

.admin-theme-pill .icon-button {
  width: 34px;
  height: 34px;
  border-radius: 999px;
}

.admin-product {
  cursor: pointer;
  transition:
    background 160ms ease,
    transform 160ms ease;
}

.admin-product:hover,
.admin-product:focus-visible {
  background: color-mix(in srgb, var(--accent) 8%, var(--surface));
  transform: translateX(2px);
  outline: 0;
}

.admin-product-preview-modal {
  width: min(100%, 980px);
}

.cart-item {
  grid-template-columns: 86px minmax(0, 1fr) auto;
  align-items: start;
}

.cart-item img {
  width: 86px;
  height: 86px;
}

.cart-item-info {
  min-width: 0;
}

.cart-item-info p {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.cart-item-type {
  color: var(--accent) !important;
  font-weight: 800;
  text-transform: uppercase;
}

.cart-item-pricing {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  align-items: center;
  color: var(--text);
}

.cart-item-pricing span {
  color: var(--muted);
}

.cart-breakdown {
  display: grid;
  gap: 10px;
  padding: 18px 34px;
  background: var(--surface);
}

.cart-breakdown div {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.cart-breakdown span {
  color: var(--muted);
}

.cart-breakdown .is-total {
  margin-top: 6px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.cart-breakdown .is-total strong {
  font-size: 22px;
}

.shipping-fixed {
  justify-items: center;
  gap: 6px;
}

.shipping-fixed strong {
  color: #111111;
}

.checkout-modal .checkout-check {
  display: flex;
  width: fit-content;
  max-width: 100%;
  align-items: center;
  gap: 12px;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  background: #ffffff;
  padding: 12px 14px;
  color: #4d4d4d;
}

.checkout-modal .checkout-check input {
  width: 20px;
  min-width: 20px;
  height: 20px;
  padding: 0;
}

.checkout-modal .checkout-check span {
  line-height: 1.35;
  text-transform: none;
}

.payment-state.is-error {
  border: 1px solid color-mix(in srgb, var(--danger) 32%, transparent);
  border-radius: 12px;
  background: color-mix(in srgb, var(--danger) 8%, white);
  padding: 12px 14px;
}

.status-alert-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 2px solid currentColor;
  border-radius: 999px;
  font-size: 24px;
  font-weight: 900;
  line-height: 1;
}

.admin-modal {
  overflow: visible;
}

.admin-layout {
  position: relative;
  display: block;
  min-height: min(82vh, 920px);
  padding-left: 112px;
}

.admin-content {
  overflow: auto;
  max-height: min(92vh, 1040px);
  border-left: 1px solid var(--line);
  border-radius: 0 var(--radius-xl) var(--radius-xl) 0;
  background: var(--surface);
}

.admin-dock {
  position: absolute;
  left: 18px;
  top: 28px;
  width: 76px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface);
  box-shadow: 0 18px 48px rgba(18, 18, 18, 0.12);
  padding: 10px;
}

.admin-dock .tab-button {
  width: 54px;
  border-radius: 16px;
}

@media (max-width: 980px) {
  .catalog-toolbar,
  .theme-manager-row {
    grid-template-columns: 1fr;
  }

  .product-card {
    max-height: none;
  }

  .product-body {
    max-height: 340px;
  }

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

  .admin-layout {
    display: grid;
    grid-template-columns: 1fr;
    padding-left: 0;
  }

  .admin-content {
    border-left: 0;
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
  }

  .admin-dock {
    position: sticky;
    top: 0;
    width: auto;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    box-shadow: none;
  }
}

@media (max-width: 640px) {
  .catalog-toolbar {
    margin-top: 0;
  }

  .product-theme-filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .product-theme-filters button {
    flex: 0 0 auto;
  }

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

  .modal {
    transform: translateY(24px) scale(1);
  }

  .modal-backdrop.is-open .modal {
    transform: translateY(0) scale(1);
  }

  .product-modal-info {
    max-height: none;
  }

  .cart-item {
    grid-template-columns: 64px minmax(0, 1fr);
  }

  .cart-item img {
    width: 64px;
    height: 64px;
  }

  .cart-breakdown {
    padding: 16px 18px;
  }

  .checkout-modal .checkout-check {
    width: 100%;
  }
}

.product-card {
  max-height: none;
}

.product-gallery {
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.product-card .product-thumbs {
  max-height: none;
  overflow: hidden;
}

.product-image,
.product-image img {
  border-radius: var(--radius-md);
}

.product-body {
  min-height: auto;
  max-height: none;
  overflow: visible;
}

.cart-modal {
  display: flex;
  max-height: min(88vh, 920px);
  flex-direction: column;
  overflow: hidden;
}

.cart-items {
  flex: 1 1 auto;
  min-height: 0;
  max-height: none;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.cart-footer {
  flex: 0 0 auto;
}

.admin-modal {
  width: min(calc(100vw - 150px), 1320px);
  overflow: visible;
}

.admin-layout {
  position: static;
  min-height: min(82vh, 920px);
  padding-left: 0;
}

.admin-content {
  overflow-y: auto;
  overflow-x: hidden;
  max-height: min(86vh, 920px);
  border-left: 0;
  border-radius: var(--radius-xl);
}

.admin-list {
  max-height: none;
  overflow: visible;
}

.admin-dock {
  position: absolute;
  left: -96px;
  top: 34px;
  display: grid;
  width: 72px;
  gap: 10px;
  overflow: visible;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface);
  padding: 9px;
  box-shadow: 0 22px 54px rgba(18, 18, 18, 0.16);
}

.admin-dock .tab-button {
  display: grid;
  width: 52px;
  min-width: 0;
  height: 52px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0;
}

.admin-dock .tab-button span {
  display: none;
}

.admin-dock .tab-button svg {
  width: 21px;
  height: 21px;
}

.admin-product.is-missing-theme {
  border: 1px solid color-mix(in srgb, var(--danger) 76%, var(--line));
  box-shadow: inset 4px 0 0 var(--danger);
}

.admin-product.is-missing-theme + .admin-product {
  border-top: 0;
}

.theme-warning {
  color: var(--danger) !important;
  font-weight: 800;
}

.product-theme-filters button,
.primary-action,
.secondary-action,
.ghost-action {
  white-space: nowrap;
}

@media (max-width: 980px) {
  .admin-modal {
    width: min(100%, 1080px);
    overflow: hidden;
  }

  .admin-layout {
    display: grid;
    grid-template-columns: 1fr;
  }

  .admin-dock {
    position: sticky;
    left: auto;
    top: 0;
    display: flex;
    width: auto;
    justify-content: center;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    box-shadow: none;
  }

  .admin-content {
    max-height: min(82vh, 920px);
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
  }
}

@media (max-width: 640px) {
  .product-gallery {
    border-radius: var(--radius-md);
  }

  .product-card .product-thumbs {
    overflow: hidden;
  }

  .cart-modal {
    max-height: 92vh;
  }

  .admin-content {
    max-height: 82vh;
  }
}

.editorial-blocks {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.editorial-card {
  min-height: 0;
  padding: 22px;
}

.editorial-card::before,
.editorial-card::after {
  opacity: 0.22;
}

.editorial-number {
  width: 34px;
  height: 34px;
  margin-bottom: 18px;
  font-size: 12px;
}

.editorial-blocks h3 {
  margin-bottom: 10px;
  font-size: clamp(20px, 2.1vw, 30px);
  line-height: 1.05;
}

.editorial-blocks p {
  margin: 0;
  font-size: 15px;
  line-height: 1.45;
}

.reviews-band {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: clamp(24px, 5vw, 72px);
  margin: clamp(14px, 2.8vw, 34px);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: color-mix(in srgb, var(--surface) 72%, transparent);
  padding: clamp(36px, 6vw, 76px) clamp(18px, 4vw, 56px);
}

.reviews-content,
.review-form {
  display: grid;
  gap: 18px;
}

.reviews-grid,
.reviews-modal-list {
  display: grid;
  gap: 14px;
}

.reviews-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.review-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  padding: 18px;
}

.review-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.review-card p {
  margin: 0;
  color: var(--muted);
}

.review-card small {
  display: block;
  margin-top: 14px;
  color: var(--muted);
}

.text-action {
  width: fit-content;
  border: 0;
  background: transparent;
  color: var(--accent);
  padding: 0;
  font-weight: 800;
  text-decoration: underline;
  cursor: pointer;
}

.reviews-modal {
  width: min(100%, 820px);
}

.reviews-modal-list {
  padding: clamp(22px, 4vw, 42px);
}

.product-modal {
  width: min(100%, 1080px);
  overflow-y: auto;
  overflow-x: hidden;
}

.product-modal-content {
  grid-template-columns: minmax(320px, 0.95fr) minmax(0, 1.05fr);
  align-items: start;
}

.product-modal-gallery {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  padding: 14px;
}

.product-modal-image {
  display: block;
  width: 100%;
  min-height: 0;
  overflow: hidden;
  border: 0;
  border-radius: var(--radius-xl);
  background: var(--surface-alt);
  padding: 0;
  cursor: zoom-in;
}

.product-modal-image img {
  width: 100%;
  height: auto;
  min-height: 0;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-xl);
  object-fit: cover;
}

.modal-thumbs,
.product-modal .product-thumbs {
  display: flex;
  max-height: none;
  overflow: hidden;
}

.product-modal-info {
  max-height: none;
  overflow: visible;
}

.product-modal-info .spec-list {
  margin-bottom: 22px;
}

.product-more {
  margin: 0;
}

.product-more-panel h3 {
  margin: 0 0 8px;
  color: var(--text);
  font-size: 13px;
  text-transform: uppercase;
}

.image-lightbox {
  z-index: 120;
  cursor: zoom-out;
}

.image-lightbox img {
  display: block;
  max-width: min(92vw, 1180px);
  max-height: 88vh;
  border-radius: var(--radius-lg);
  object-fit: contain;
  box-shadow: 0 34px 100px rgba(0, 0, 0, 0.34);
  opacity: 0;
  transform: scale(0.94);
  transition:
    opacity 260ms cubic-bezier(0.22, 1, 0.36, 1),
    transform 260ms cubic-bezier(0.22, 1, 0.36, 1);
}

.image-lightbox.is-open img {
  opacity: 1;
  transform: scale(1);
}

.admin-review {
  grid-template-columns: 1fr;
}

@media (max-width: 980px) {
  .editorial-blocks,
  .reviews-band,
  .reviews-grid,
  .product-modal-content {
    grid-template-columns: 1fr;
  }

  .reviews-band {
    gap: 12px;
  }
}

@media (max-width: 640px) {
  .reviews-band {
    margin: 14px;
    border-radius: var(--radius-lg);
    padding: 30px 14px;
  }

  .product-modal-image img {
    aspect-ratio: 1 / 0.78;
  }
}

.section-index,
.kicker,
.editorial-number {
  display: none !important;
}

.section-head,
.info-band,
.legal-band,
.reviews-band {
  grid-template-columns: minmax(0, 1fr);
}

.editorial-card {
  display: grid;
  gap: 12px;
  padding: 20px;
}

.editorial-card > svg {
  width: 30px;
  height: 30px;
  color: var(--accent);
}

.editorial-card h3 {
  margin: 0;
}

.site-footer {
  padding-top: clamp(24px, 4vw, 42px);
}

.footer-brand-block {
  display: grid;
  grid-template-columns: minmax(220px, 0.72fr) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  margin-bottom: 28px;
}

.footer-brand-block h2 {
  margin: 0;
  font-size: clamp(32px, 4vw, 62px);
  line-height: 0.98;
}

.footer-brand-block p:not(.kicker) {
  justify-self: end;
  max-width: 620px;
  color: color-mix(in srgb, var(--bg) 74%, transparent);
  font-size: clamp(16px, 1.4vw, 20px);
  line-height: 1.35;
}

.footer-avatar {
  grid-row: auto;
}

.reviews-grid {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.reviews-track {
  display: flex;
  transition: transform 520ms cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.reviews-track .review-card {
  flex: 0 0 100%;
  border: 0;
  border-radius: 0;
  padding: clamp(22px, 4vw, 38px);
}

.reviews-dots {
  position: absolute;
  right: 18px;
  bottom: 16px;
  display: flex;
  gap: 7px;
}

.reviews-dots span {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--muted) 38%, transparent);
  transition:
    width 180ms ease,
    background 180ms ease;
}

.reviews-dots span.is-active {
  width: 22px;
  background: var(--accent);
}

.review-form {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  padding: 18px;
}

.rating-field {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.rating-picker {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.rating-picker label {
  display: block;
}

.rating-picker input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.rating-picker span {
  display: grid;
  min-height: 44px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
  transition:
    border-color 160ms ease,
    background 160ms ease,
    color 160ms ease;
}

.rating-picker input:checked + span {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 10%, var(--surface));
  color: var(--accent);
}

.product-modal {
  scrollbar-gutter: stable;
  padding-right: 0;
}

.product-modal-content {
  grid-template-columns: minmax(360px, 1fr) minmax(0, 0.95fr);
  gap: 0;
}

.product-modal-gallery {
  grid-template-areas:
    "thumbs image"
    "more more";
  grid-template-columns: 74px minmax(0, 1fr);
  align-items: start;
  gap: 14px;
}

.product-modal-image {
  grid-area: image;
}

.modal-thumbs,
.product-modal .product-thumbs {
  grid-area: thumbs;
  display: grid;
  gap: 10px;
  align-content: start;
  overflow: hidden;
}

.modal-thumbs button {
  width: 64px;
  height: 64px;
}

.product-more {
  grid-area: more;
}

.product-modal-info .product-actions .primary-action {
  width: 100%;
  min-height: 62px;
  padding: 16px 30px;
  font-size: 17px;
}

.product-modal-info .product-actions {
  display: grid;
  width: 100%;
}

.product-modal-info .inline-qty {
  grid-template-columns: 64px minmax(0, 1fr) 64px;
  width: 100%;
  max-width: none;
  min-height: 60px;
}

.product-modal-info .inline-qty button {
  width: 100%;
  height: 58px;
}

.product-modal-info .inline-qty svg {
  width: 22px;
  height: 22px;
}

.product-modal-info .inline-qty span {
  font-size: 20px;
}

.modal,
.scrollable-modal,
.cart-items,
.admin-content,
.theme-picker-menu {
  scrollbar-gutter: stable;
}

.modal::-webkit-scrollbar,
.scrollable-modal::-webkit-scrollbar,
.cart-items::-webkit-scrollbar,
.admin-content::-webkit-scrollbar,
.theme-picker-menu::-webkit-scrollbar {
  width: 8px;
}

.modal::-webkit-scrollbar-thumb,
.scrollable-modal::-webkit-scrollbar-thumb,
.cart-items::-webkit-scrollbar-thumb,
.admin-content::-webkit-scrollbar-thumb,
.theme-picker-menu::-webkit-scrollbar-thumb {
  border-width: 2px;
}

html {
  scrollbar-gutter: stable;
}

.modal {
  overflow: hidden;
}

.scrollable-modal,
.product-modal {
  overflow-y: auto;
  overflow-x: hidden;
}

.admin-modal {
  overflow: visible;
}

.admin-content {
  overflow-y: auto;
  overflow-x: hidden;
}

*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

*::-webkit-scrollbar-track {
  margin: 6px;
  border-radius: 999px;
  background: transparent;
}

*::-webkit-scrollbar-thumb {
  min-width: 32px;
  min-height: 32px;
  border: 2px solid transparent;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 58%, var(--line));
  background-clip: padding-box;
}

*::-webkit-scrollbar-corner {
  background: transparent;
}

.modal,
.scrollable-modal,
.cart-items,
.admin-content,
.theme-picker-menu,
.product-modal-info,
.reviews-modal-list,
textarea {
  scrollbar-gutter: stable;
}

.scrollable-modal,
.cart-items,
.admin-content,
.theme-picker-menu,
.product-modal-info,
.reviews-modal-list,
textarea {
  overscroll-behavior: contain;
  background-clip: padding-box;
}

.mail-products {
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  overflow: hidden;
}

.mail-product {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  min-height: 66px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.mail-product:last-child {
  border-bottom: 0;
}

.mail-product > span {
  min-width: 0;
  overflow: hidden;
  color: var(--text);
  font-size: 14px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mail-qty.inline-qty {
  grid-template-columns: 38px 42px 38px;
  max-width: 118px;
  background: color-mix(in srgb, var(--surface-alt) 56%, var(--surface));
  opacity: 1;
  transform: none;
}

.mail-qty input {
  display: none;
}

.mail-preview-panel {
  margin-top: 22px;
  border: 1px solid var(--text);
  border-radius: var(--radius-md);
  background: var(--surface);
  overflow: hidden;
}

.mail-preview-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--text);
}

.mail-preview-head div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.mail-preview-head span,
.mail-preview-head small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.mail-preview-head strong {
  overflow: hidden;
  font-size: 18px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mail-preview-head small {
  max-width: 42%;
  overflow: hidden;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mail-preview {
  max-height: 460px;
  overflow: auto;
  padding: 18px;
  background: color-mix(in srgb, var(--surface-alt) 54%, var(--surface));
}

.message-toast {
  position: fixed;
  right: clamp(16px, 3vw, 34px);
  bottom: clamp(16px, 3vw, 34px);
  z-index: 140;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  width: min(420px, calc(100vw - 32px));
  padding: 16px;
  border: 1px solid var(--text);
  border-radius: var(--radius-sm);
  background: var(--surface);
  box-shadow: 0 24px 70px rgba(18, 18, 18, 0.22);
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.message-toast[hidden] {
  display: none;
}

.message-toast.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.message-toast-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 999px;
  background: color-mix(in srgb, var(--success) 12%, var(--surface));
  color: var(--success);
}

.message-toast.is-error .message-toast-icon {
  background: color-mix(in srgb, var(--danger) 12%, var(--surface));
  color: var(--danger);
}

.message-toast strong {
  display: block;
  margin: 0 0 3px;
  font-size: 15px;
}

.message-toast p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.scrollable-modal::-webkit-scrollbar-track,
.cart-items::-webkit-scrollbar-track,
.admin-content::-webkit-scrollbar-track,
.theme-picker-menu::-webkit-scrollbar-track,
.product-modal-info::-webkit-scrollbar-track,
.reviews-modal-list::-webkit-scrollbar-track,
.mail-preview::-webkit-scrollbar-track,
textarea::-webkit-scrollbar-track {
  margin-block: 14px;
}

.scrollable-modal::-webkit-scrollbar-thumb,
.cart-items::-webkit-scrollbar-thumb,
.admin-content::-webkit-scrollbar-thumb,
.theme-picker-menu::-webkit-scrollbar-thumb,
.product-modal-info::-webkit-scrollbar-thumb,
.reviews-modal-list::-webkit-scrollbar-thumb,
.mail-preview::-webkit-scrollbar-thumb,
textarea::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  background-clip: padding-box;
}

@media (max-width: 980px) {
  .footer-brand-block,
  .product-modal-content {
    grid-template-columns: 1fr;
  }

  .footer-brand-block p:not(.kicker) {
    justify-self: start;
  }
}

@media (max-width: 640px) {
  .rating-picker {
    grid-template-columns: repeat(5, 1fr);
  }

  .product-modal-gallery {
    grid-template-areas:
      "image"
      "thumbs"
      "more";
    grid-template-columns: 1fr;
  }

  .modal-thumbs,
  .product-modal .product-thumbs {
    display: flex;
  }

}

@media (max-width: 980px) {
  .admin-modal {
    overflow: hidden;
  }
}

.app-loader {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: grid;
  place-items: center;
  gap: 14px;
  background: var(--bg);
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.app-loader[hidden] {
  display: none;
}

.app-loader .loader {
  width: 34px;
  height: 34px;
  margin: 0;
  border-width: 3px;
}

body.is-booting {
  overflow: hidden;
}

body.is-booting .site-shell {
  visibility: hidden;
}

@media (max-width: 980px) {
  body {
    overflow-x: hidden;
  }

  .site-shell {
    width: 100%;
  }

  .topbar {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
  }

  .brand-text {
    max-width: calc(100vw - 128px);
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .checkout-modal.payment-modal,
  .admin-modal {
    width: min(100%, calc(100vw - 24px));
    max-height: calc(100dvh - 24px);
  }

  .checkout-layout {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .checkout-summary {
    order: -1;
  }

  .admin-layout {
    display: grid;
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .admin-dock {
    position: sticky;
    left: auto;
    top: 0;
    display: flex;
    width: auto;
    justify-content: flex-start;
    overflow-x: auto;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  }

  .admin-dock .tab-button {
    flex: 0 0 52px;
  }

  .admin-content {
    max-height: min(82vh, 920px);
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
  }

  .mail-preview-head {
    flex-direction: column;
  }

  .mail-preview-head small {
    max-width: 100%;
    text-align: left;
  }
}

@media (max-width: 640px) {
  h1 {
    font-size: 38px;
    line-height: 1;
  }

  h2 {
    font-size: 30px;
  }

  .topbar {
    min-height: 62px;
    padding: 10px 12px;
  }

  .brand {
    gap: 9px;
  }

  .brand-avatar-wrap,
  .brand-avatar,
  .brand-mark {
    width: 34px;
    height: 34px;
  }

  .brand-text {
    max-width: calc(100vw - 112px);
    font-size: 12px;
  }

  .hero-band,
  .shop-section,
  .info-band,
  .legal-band,
  .reviews-band,
  .site-footer {
    margin: 10px;
    border-radius: var(--radius-lg);
  }

  .hero-copy,
  .shop-section,
  .info-band,
  .legal-band,
  .reviews-band {
    padding: 24px 14px;
  }

  .hero-copy {
    min-height: auto;
  }

  .hero-media {
    min-height: 260px;
  }

  .hero-card {
    right: 14px;
    bottom: 14px;
    width: min(220px, calc(100% - 28px));
    padding: 16px;
  }

  .hero-card strong {
    font-size: 58px;
  }

  .catalog-toolbar,
  .product-grid,
  .form-grid,
  .editorial-blocks,
  .reviews-grid,
  .footer-columns,
  .footer-brand-block,
  .product-modal-content,
  .admin-split,
  .theme-manager-row,
  .discount-row,
  .mail-product {
    grid-template-columns: 1fr;
  }

  .product-card {
    border-radius: var(--radius-md);
  }

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

  .product-card .product-thumbs,
  .product-modal .product-thumbs,
  .modal-thumbs {
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
  }

  .product-body {
    padding: 18px;
  }

  .product-actions,
  .form-actions,
  .admin-head-actions {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }

  .primary-action,
  .secondary-action,
  .ghost-action {
    width: 100%;
    white-space: normal;
  }

  .modal-backdrop {
    align-items: flex-end;
    padding: 0;
  }

  .modal {
    width: 100%;
    max-height: 94dvh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }

  .product-modal-image img {
    aspect-ratio: 4 / 3;
  }

  .cart-item,
  .summary-product,
  .admin-product {
    grid-template-columns: 64px minmax(0, 1fr);
  }

  .cart-item img,
  .summary-thumb img,
  .admin-product img {
    width: 64px;
    height: 64px;
  }

  .cart-controls {
    grid-column: 1 / -1;
  }

  .checkout-modal.payment-modal,
  .admin-modal {
    width: 100%;
    max-height: 100dvh;
    border-radius: 0;
  }

  .checkout-modal.payment-modal {
    height: 100dvh;
  }

  .checkout-topbar {
    min-height: 58px;
    padding: 12px 66px 12px 16px;
    border-radius: 0;
  }

  .checkout-layout {
    display: flex;
    min-height: 0;
    flex-direction: column;
  }

  .checkout-main,
  .checkout-summary {
    padding: 20px 16px;
  }

  .checkout-section-head,
  .payment-method-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .checkout-section h3 {
    font-size: 26px;
  }

  .admin-modal {
    height: 100dvh;
    overflow: hidden;
  }

  .admin-layout {
    height: 100%;
    grid-template-rows: auto minmax(0, 1fr);
  }

  .admin-dock {
    border-radius: 0;
    padding: 8px 64px 8px 8px;
  }

  .admin-dock .tab-button {
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
  }

  .admin-content {
    max-height: none;
    min-height: 0;
    border-radius: 0;
  }

  .admin-head {
    flex-direction: column;
    padding: 22px 16px 16px;
  }

  .admin-head h2 {
    padding-right: 44px;
  }

  .admin-login,
  .admin-form {
    padding: 20px 16px;
  }

  .spec-builder {
    padding: 14px;
  }

  .spec-builder-head .form-actions {
    grid-template-columns: 1fr;
  }

  .theme-picker-menu {
    max-height: 240px;
  }

  .mail-preview {
    max-height: 360px;
    padding: 12px;
  }

  .message-toast {
    right: 12px;
    bottom: 12px;
    width: calc(100vw - 24px);
  }
}

.product-card .product-thumbs {
  max-height: 324px;
  overflow-x: hidden;
  overflow-y: auto;
  padding-right: 2px;
}

.product-modal .product-thumbs,
.modal-thumbs {
  max-height: min(56vh, 520px);
  overflow-x: hidden;
  overflow-y: auto;
  padding-right: 2px;
}

@media (max-width: 980px) {
  .product-card .product-thumbs,
  .product-modal .product-thumbs,
  .modal-thumbs {
    max-height: none;
    overflow-x: auto;
    overflow-y: hidden;
    padding-right: 0;
    padding-bottom: 2px;
  }
}

@media (max-width: 640px) {
  .image-lightbox {
    align-items: center;
    justify-content: center;
    padding: 18px;
  }

  .image-lightbox img {
    max-width: calc(100vw - 36px);
    max-height: calc(100dvh - 36px);
  }
}

.admin-product {
  grid-template-columns: 28px 68px minmax(0, 1fr);
  align-items: start;
}

.drag-handle {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 5px;
  min-height: 68px;
  border: 0;
  background: transparent;
  padding: 0;
  cursor: grab;
}

.drag-handle:active {
  cursor: grabbing;
}

.drag-handle span {
  width: 16px;
  height: 3px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--muted) 64%, var(--line));
  transition: background 160ms ease;
}

.admin-product:hover .drag-handle span,
.drag-handle:focus-visible span {
  background: var(--accent);
}

.admin-product.is-dragging {
  opacity: 0.58;
  transform: none;
}

.admin-product.is-drop-before {
  box-shadow: inset 4px 0 0 var(--accent);
}

.admin-product.is-drop-after {
  box-shadow: inset 0 -4px 0 var(--accent);
}

.inbox-admin-split {
  grid-template-columns: minmax(300px, 0.82fr) minmax(0, 1.18fr);
}

.inbox-column,
.inbox-thread {
  background: var(--surface);
}

.inbox-column {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
}

.inbox-thread {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.inbox-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 28px 34px 0;
}

.inbox-toolbar h3 {
  margin: 0;
  font-size: 18px;
}

.inbox-toolbar .secondary-action {
  min-width: 120px;
}

.inbox-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 34px 20px;
}

.inbox-meta span {
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface-alt) 72%, var(--surface));
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.inbox-list {
  border-top: 1px solid var(--line);
}

.inbox-message-card {
  display: grid;
  gap: 8px;
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
  padding: 16px 18px;
  text-align: left;
  cursor: pointer;
  transition:
    background 160ms ease,
    transform 160ms ease;
}

.inbox-message-card:hover,
.inbox-message-card:focus-visible {
  background: color-mix(in srgb, var(--accent) 8%, var(--surface));
  outline: 0;
}

.inbox-message-card.is-active {
  background: color-mix(in srgb, var(--accent) 12%, var(--surface));
}

.inbox-message-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.inbox-message-card-head strong {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
}

.inbox-message-card.is-unread .inbox-message-card-head strong::before {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
  content: "";
}

.inbox-message-card h3 {
  margin: 0;
  font-size: 16px;
  line-height: 1.3;
}

.inbox-message-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.inbox-message-panel {
  margin: 28px 34px 0;
}

.inbox-message-body {
  min-height: 280px;
}

.inbox-message-lines {
  display: grid;
  gap: 12px;
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}

.inbox-message-lines p {
  display: grid;
  gap: 4px;
  margin: 0;
}

.inbox-message-lines strong {
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
}

.inbox-message-copy {
  white-space: pre-wrap;
  color: var(--text);
  line-height: 1.6;
}

.inbox-reply-form {
  padding-top: 0;
}

@media (max-width: 980px) {
  .inbox-admin-split {
    grid-template-columns: 1fr;
  }

  .inbox-thread {
    grid-template-rows: auto auto;
  }
}

@media (max-width: 640px) {
  .admin-product {
    grid-template-columns: 28px 64px minmax(0, 1fr);
  }

  .inbox-toolbar,
  .inbox-meta {
    padding-right: 18px;
    padding-left: 18px;
  }

  .inbox-message-panel {
    margin: 24px 18px 0;
  }
}
