:root {
  --bg: #f6f3ee;
  --surface: #ffffff;
  --surface-soft: #efeae2;
  --text: #171717;
  --muted: #6b6259;
  --line: #ddd4ca;
  --accent: #c80f16;
  --accent-strong: #8f080d;
  --gold: #c79a37;
  --danger: #b91c1c;
  --shadow: 0 18px 55px rgba(23, 23, 23, 0.14);
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.dark {
  --bg: #14120f;
  --surface: #201d19;
  --surface-soft: #2d2822;
  --text: #faf7f1;
  --muted: #bdb4aa;
  --line: #403930;
  --shadow: 0 18px 55px rgba(0, 0, 0, 0.42);
  color-scheme: dark;
}

button,
input,
select {
  font: inherit;
}

button,
a,
select,
input {
  border-radius: 8px;
}

button {
  cursor: pointer;
}

.app-shell {
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 18px;
  justify-content: space-between;
  padding: 10px clamp(14px, 3vw, 38px);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 190px;
  color: var(--text);
  text-decoration: none;
  font-weight: 800;
}

.brand-logo {
  display: block;
  width: clamp(118px, 13vw, 160px);
  max-width: 160px;
  height: 54px;
  max-height: 54px;
  object-fit: contain;
  object-position: left center;
  mix-blend-mode: multiply;
}

.brand-name {
  color: var(--accent);
  font-size: 1rem;
  font-weight: 900;
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 0;
  background: transparent;
  border: 0;
  flex: 1;
}

.main-nav a,
.nav-item > a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  color: var(--muted);
  padding: 8px 12px;
  text-decoration: none;
  font-weight: 800;
  white-space: nowrap;
}

.main-nav a:hover,
.nav-item:hover > a,
.nav-item:focus-within > a {
  color: var(--text);
  background: var(--surface-soft);
}

.nav-item {
  position: relative;
}

.submenu {
  position: absolute;
  left: 0;
  top: calc(100% + 8px);
  z-index: 40;
  display: grid;
  min-width: 190px;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
}

.submenu a {
  min-height: 34px;
  padding: 7px 10px;
  border-radius: 6px;
  color: var(--muted);
  font-size: 0.91rem;
}

.nav-item:hover .submenu,
.nav-item:focus-within .submenu {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.top-actions,
.hero-actions,
.control-row,
.toggle-row,
.drawer-header,
.coupon-row,
.gateway-strip {
  display: flex;
  align-items: center;
}

.top-actions {
  gap: 10px;
}

.icon-button,
.cart-button,
.primary-button,
.secondary-button,
.checkout-button,
.primary-link,
.secondary-link,
.coupon-row button {
  min-height: 42px;
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 800;
  text-decoration: none;
}

.icon-button {
  width: 42px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--line);
}

.cart-button {
  padding: 0 12px;
  background: var(--text);
  color: var(--bg);
}

.cart-button strong {
  display: grid;
  min-width: 24px;
  height: 24px;
  place-items: center;
  background: var(--accent);
  color: white;
  border-radius: 999px;
  font-size: 0.78rem;
}

.hero {
  min-height: clamp(520px, 72vh, 760px);
  display: flex;
  align-items: flex-end;
  padding: clamp(28px, 7vw, 86px) clamp(16px, 5vw, 70px);
  background:
    linear-gradient(90deg, rgba(10, 10, 10, 0.74), rgba(80, 8, 13, 0.4), rgba(10, 10, 10, 0.12)),
    url("https://images.unsplash.com/photo-1515886657613-9f3515b0c78f?auto=format&fit=crop&w=1800&q=80") center / cover;
  color: white;
}

.hero-copy {
  width: min(720px, 100%);
}

.eyebrow {
  margin: 0 0 10px;
  color: color-mix(in srgb, var(--accent) 75%, var(--text));
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #ffe7a4;
}

h1,
h2,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  max-width: 680px;
  font-size: clamp(2.4rem, 6.2vw, 5.8rem);
  line-height: 0.96;
  letter-spacing: 0;
}

h2 {
  margin: 0 0 12px;
  font-size: clamp(1.4rem, 2vw, 2rem);
  line-height: 1.05;
  letter-spacing: 0;
}

.hero p:not(.eyebrow) {
  max-width: 610px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(1rem, 2vw, 1.2rem);
  line-height: 1.55;
}

.hero-actions {
  gap: 12px;
  flex-wrap: wrap;
}

.primary-link,
.primary-button,
.checkout-button {
  padding: 0 18px;
  background: var(--accent);
  color: white;
}

.primary-link:hover,
.primary-button:hover,
.checkout-button:hover {
  background: var(--accent-strong);
}

.secondary-link,
.secondary-button {
  padding: 0 18px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--line);
}

.toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto minmax(170px, auto);
  gap: 12px;
  padding: 24px clamp(16px, 5vw, 70px) 8px;
  align-items: center;
}

.search-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 14px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.search-wrap input,
.coupon-row input {
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--text);
  outline: none;
}

.segmented {
  display: flex;
  gap: 4px;
  padding: 4px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow-x: auto;
}

.segmented button {
  white-space: nowrap;
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 9px 12px;
  font-weight: 800;
}

.segmented button.active {
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.08);
}

select,
input {
  min-height: 46px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  padding: 0 12px;
}

.catalog {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  padding: 18px clamp(16px, 5vw, 70px) 42px;
}

.product-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 12px 35px rgba(23, 23, 23, 0.08);
}

.product-card img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: top center;
  background: var(--surface-soft);
}

.zoomable-image {
  cursor: zoom-in;
}

.zoomable-image:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

.product-info {
  padding: 14px;
}

.product-meta,
.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.product-info h3 {
  margin: 10px 0 8px;
  font-size: 1rem;
  line-height: 1.2;
}

.tag {
  padding: 5px 8px;
  background: var(--surface-soft);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.rating {
  color: #a16207;
  font-weight: 900;
}

.price {
  font-weight: 900;
  font-size: 1.12rem;
}

.product-footer {
  justify-content: flex-end;
  margin-top: 12px;
}

.add-button {
  width: 42px;
  height: 42px;
  border: 0;
  background: var(--text);
  color: var(--bg);
}

.account-panel {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(320px, 1fr);
  gap: clamp(18px, 4vw, 42px);
  margin: 0 clamp(16px, 5vw, 70px) 42px;
  padding: clamp(18px, 4vw, 42px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.profile-grid,
.payment-card {
  display: grid;
  gap: 14px;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
}

label input,
label select {
  color: var(--text);
  font-weight: 600;
}

.control-row {
  gap: 12px;
}

.control-row > label {
  flex: 1;
  min-width: 0;
}

.toggle-row {
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.toggle-row label {
  display: flex;
  min-height: 46px;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
}

.toggle-row input {
  min-height: auto;
}

.account-panel {
  grid-template-columns: 0.7fr 1.3fr;
  align-items: start;
}

.muted {
  color: var(--muted);
  line-height: 1.55;
}

.small {
  margin: 0;
  font-size: 0.82rem;
}

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

.profile-grid button {
  align-self: end;
}

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 30;
  display: grid;
  grid-template-rows: auto 1fr auto auto auto;
  width: min(430px, 100vw);
  height: 100vh;
  padding: 18px;
  background: var(--surface);
  border-left: 1px solid var(--line);
  box-shadow: var(--shadow);
  transform: translateX(105%);
  transition: transform 180ms ease;
}

.drawer.open {
  transform: translateX(0);
}

.drawer-header {
  justify-content: space-between;
}

.drawer-header h2 {
  margin: 0;
}

.cart-items {
  display: grid;
  align-content: start;
  gap: 12px;
  overflow-y: auto;
  padding: 14px 0;
}

.cart-item {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 12px;
  padding: 10px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}

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

.cart-item h3 {
  margin: 0 0 5px;
  font-size: 0.96rem;
}

.cart-item p {
  margin: 0;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.35;
}

.qty-row {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
}

.qty-row button,
.remove-item {
  width: 30px;
  height: 30px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
}

.remove-item {
  color: var(--danger);
}

.coupon-row {
  gap: 8px;
  margin-bottom: 14px;
}

.coupon-row input {
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
}

.coupon-row button {
  padding: 0 12px;
  background: var(--text);
  color: var(--bg);
}

.totals {
  display: grid;
  gap: 8px;
  margin: 0 0 14px;
}

.totals div {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
}

.totals dd {
  margin: 0;
  color: var(--text);
  font-weight: 900;
}

.totals .total {
  border-top: 1px solid var(--line);
  padding-top: 10px;
  color: var(--text);
  font-size: 1.1rem;
}

.overlay {
  position: fixed;
  inset: 0;
  z-index: 20;
  background: rgba(0, 0, 0, 0.36);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.payment-modal {
  width: min(500px, calc(100vw - 28px));
  padding: 0;
  background: transparent;
  border: 0;
}

.payment-modal::backdrop {
  background: rgba(0, 0, 0, 0.5);
}

.payment-card {
  position: relative;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.close-modal {
  position: absolute;
  top: 14px;
  right: 14px;
}

.gateway-strip {
  justify-content: space-between;
  gap: 14px;
  padding: 12px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.gateway-strip span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 800;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 20px;
  z-index: 50;
  transform: translate(-50%, 22px);
  max-width: min(520px, calc(100vw - 28px));
  padding: 12px 14px;
  background: var(--text);
  color: var(--bg);
  border-radius: 8px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
  font-weight: 800;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.collection-hero {
  padding: clamp(34px, 7vw, 74px) clamp(16px, 5vw, 70px) 18px;
  background: linear-gradient(90deg, rgba(200, 15, 22, 0.1), rgba(199, 154, 55, 0.08));
  border-bottom: 1px solid var(--line);
}

.collection-hero h1 {
  max-width: 920px;
  color: var(--text);
  font-size: clamp(2.1rem, 5vw, 4.6rem);
}

.collection-hero .muted {
  max-width: 620px;
  margin: 14px 0 0;
}

.boys-collection-hero {
  background:
    linear-gradient(90deg, rgba(23, 23, 23, 0.08), rgba(200, 15, 22, 0.08)),
    var(--surface-soft);
}

.collection-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  padding: 28px clamp(16px, 5vw, 70px) 56px;
}

.collection-card {
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 12px 35px rgba(23, 23, 23, 0.08);
}

.collection-card img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: top center;
  background: var(--surface-soft);
}

.image-zoom-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: clamp(14px, 4vw, 42px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.image-zoom-modal.open {
  opacity: 1;
  pointer-events: auto;
}

.image-zoom-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
}

.image-zoom-frame {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 12px;
  width: min(980px, 100%);
  max-height: calc(100vh - 40px);
  margin: 0;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.image-zoom-photo {
  display: block;
  width: 100%;
  max-height: calc(100vh - 150px);
  object-fit: contain;
  background: var(--surface-soft);
  border-radius: 8px;
}

.image-zoom-caption {
  color: var(--muted);
  font-weight: 900;
  text-align: center;
}

.image-zoom-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

body.zoom-open {
  overflow: hidden;
}

.collection-card-body {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.collection-card h2 {
  margin: 0;
  font-size: 1rem;
  line-height: 1.2;
}

.about-hero {
  padding: clamp(42px, 8vw, 88px) clamp(16px, 5vw, 70px) clamp(22px, 4vw, 40px);
  background:
    linear-gradient(90deg, rgba(200, 15, 22, 0.12), rgba(199, 154, 55, 0.12)),
    var(--surface-soft);
  border-bottom: 1px solid var(--line);
}

.about-hero h1 {
  color: var(--text);
  font-size: clamp(2.2rem, 5.5vw, 5rem);
}

.about-hero p:not(.eyebrow) {
  max-width: 680px;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.22rem);
  line-height: 1.55;
}

.about-content {
  display: grid;
  gap: 16px;
  max-width: 980px;
  margin: 28px auto 56px;
  padding: clamp(18px, 4vw, 42px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.about-content h2 {
  margin: 20px 0 0;
}

.about-content p {
  margin: 0;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.7;
}

.about-content ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 22px;
  color: var(--muted);
  line-height: 1.55;
}

.about-content strong {
  color: var(--text);
}

.contact-panel {
  margin-top: 0;
}

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

.contact-card {
  display: grid;
  min-height: 128px;
  gap: 8px;
  padding: 16px;
  align-content: start;
  color: var(--text);
  text-decoration: none;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.contact-card i {
  color: var(--accent);
}

.contact-card span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.contact-card strong {
  font-size: 1rem;
  line-height: 1.35;
}

svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

i[data-lucide] {
  display: inline-grid;
  width: 18px;
  height: 18px;
  place-items: center;
  flex: 0 0 auto;
  font-style: normal;
  line-height: 1;
}

i[data-lucide="moon"]::before { content: "◐"; }
i[data-lucide="shopping-bag"]::before { content: "□"; }
i[data-lucide="search"]::before { content: "⌕"; }
i[data-lucide="plus"]::before { content: "+"; }
i[data-lucide="wand-sparkles"]::before { content: "*"; }
i[data-lucide="save"]::before { content: "✓"; }
i[data-lucide="x"]::before { content: "×"; }
i[data-lucide="credit-card"]::before { content: "▣"; }
i[data-lucide="shield-check"]::before { content: "✓"; }
i[data-lucide="trash-2"]::before { content: "×"; }
i[data-lucide="lock"]::before { content: "●"; }
i[data-lucide="phone"]::before { content: "☎"; }
i[data-lucide="message-circle"]::before { content: "○"; }
i[data-lucide="mail"]::before { content: "@"; }
i[data-lucide="map-pin"]::before { content: "•"; }

@media (max-width: 1050px) {
  .catalog {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

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

  .topbar {
    flex-wrap: wrap;
  }

  .brand {
    min-width: 0;
  }

  .main-nav {
    order: 3;
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 4px;
  }
}

@media (max-width: 760px) {
  .topbar {
    align-items: stretch;
    flex-wrap: wrap;
    gap: 12px;
  }

  .brand-logo {
    width: 132px;
    height: 46px;
  }

  .brand-name {
    display: none;
  }

  .main-nav a,
  .nav-item > a {
    min-height: 38px;
    padding: 7px 10px;
    font-size: 0.9rem;
  }

  .submenu {
    position: fixed;
    left: 12px;
    right: 12px;
    top: 104px;
    min-width: 0;
    max-height: 56vh;
    overflow-y: auto;
  }

  .catalog,
  .collection-grid,
  .account-panel,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .catalog {
    gap: 14px;
  }

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

  .hero {
    min-height: 620px;
    background-position: 58% center;
  }

  .control-row {
    flex-direction: column;
    align-items: stretch;
  }
}

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

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

  .cart-item {
    grid-template-columns: 60px 1fr auto;
  }

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

  .top-actions {
    margin-left: auto;
  }

  .cart-button span {
    display: none;
  }
}
