:root {
  color-scheme: light;
  --bg: #fff9fb;
  --surface: #ffffff;
  --surface-2: #fff0f5;
  --ink: #24161a;
  --muted: #76656b;
  --line: #ead5dc;
  --accent: #b51649;
  --accent-2: #f6c3d1;
  --good: #237a57;
  --shadow: 0 18px 60px rgba(181, 22, 73, 0.12);
  --radius: 16px;
  --pill: 999px;
  font-family:
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(180deg, #fff9fb 0%, #ffffff 42%, #fff6f9 100%);
  color: var(--ink);
}

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

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

button {
  cursor: pointer;
}

.shell {
  min-height: 100dvh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto auto minmax(220px, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 14px clamp(16px, 4vw, 44px);
  background: rgba(255, 249, 251, 0.9);
  border-bottom: 1px solid rgba(234, 213, 220, 0.88);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 186px;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  box-shadow: 0 12px 28px rgba(181, 22, 73, 0.22);
}

.brand strong,
.brand small {
  display: block;
}

.brand small {
  margin-top: 1px;
  color: var(--muted);
  font-size: 12px;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.main-nav a,
.cart-link,
.chip,
.secondary-button,
.ghost-button {
  border: 1px solid var(--line);
  border-radius: var(--pill);
  background: rgba(255, 255, 255, 0.75);
  color: var(--ink);
  transition:
    border-color 0.16s ease,
    transform 0.16s ease,
    background 0.16s ease;
}

.main-nav a {
  padding: 10px 14px;
  font-size: 14px;
}

.main-nav a:hover,
.cart-link:hover,
.chip:hover,
.secondary-button:hover,
.ghost-button:hover {
  border-color: rgba(181, 22, 73, 0.5);
  transform: translateY(-1px);
}

.quick-search {
  display: grid;
  grid-template-columns: 1fr auto;
  min-width: 0;
  max-width: 520px;
  justify-self: end;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--pill);
  background: var(--surface);
  overflow: hidden;
}

.quick-search input {
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 12px 16px;
  background: transparent;
}

.quick-search button,
.primary-button {
  border: 0;
  border-radius: var(--pill);
  background: var(--accent);
  color: #fff;
  font-weight: 750;
  box-shadow: 0 12px 30px rgba(181, 22, 73, 0.18);
}

.quick-search button {
  margin: 4px;
  padding: 8px 16px;
}

.cart-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px 9px 16px;
  white-space: nowrap;
}

.cart-link strong {
  display: grid;
  min-width: 28px;
  height: 28px;
  place-items: center;
  border-radius: var(--pill);
  background: var(--accent);
  color: #fff;
  font-size: 13px;
}

main {
  min-height: calc(100dvh - 74px);
  outline: 0;
}

.page {
  padding: clamp(24px, 4vw, 56px);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.86fr) minmax(320px, 1.14fr);
  gap: clamp(24px, 5vw, 74px);
  align-items: center;
  max-width: 1420px;
  min-height: calc(100dvh - 126px);
  margin: 0 auto;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

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

h1 {
  max-width: 790px;
  margin-bottom: 22px;
  font-size: clamp(42px, 5.8vw, 82px);
  line-height: 1;
  letter-spacing: 0;
}

.lead {
  max-width: 680px;
  color: var(--muted);
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.55;
}

.hero-actions,
.section-head,
.product-actions,
.cart-row-actions,
.widget-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.hero-actions {
  margin-top: 30px;
}

.primary-button,
.secondary-button,
.ghost-button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 18px;
}

.secondary-button,
.ghost-button {
  font-weight: 720;
}

.ghost-button {
  background: transparent;
}

.hero-board {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 0.72fr;
  gap: 14px;
  align-items: stretch;
}

.hero-photo {
  min-height: 560px;
  overflow: hidden;
  border-radius: 24px;
  background: #f4dbe3;
  box-shadow: var(--shadow);
}

.hero-photo img,
.product-card img,
.product-detail-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-side {
  display: grid;
  gap: 14px;
  align-content: end;
}

.mini-panel,
.floating-note,
.metric,
.product-card,
.filters,
.cart-panel,
.detail-panel,
.info-band {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
}

.mini-panel {
  padding: 18px;
}

.mini-panel strong {
  display: block;
  font-size: 26px;
}

.mini-panel span,
.metric span,
.product-card p,
.muted {
  color: var(--muted);
}

.floating-note {
  position: absolute;
  right: 8%;
  bottom: 8%;
  max-width: 260px;
  padding: 18px;
  transform: rotate(-2deg);
}

.section {
  max-width: 1420px;
  margin: 0 auto;
  padding: 24px 0 42px;
}

.section-head {
  justify-content: space-between;
  margin-bottom: 18px;
}

.section-head h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 54px);
  line-height: 1;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 34px;
}

.metric {
  padding: 18px;
}

.metric strong {
  display: block;
  margin-bottom: 5px;
  font-size: 28px;
}

.catalog-layout {
  display: grid;
  grid-template-columns: 288px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.filters {
  position: sticky;
  top: 92px;
  padding: 18px;
}

.filters h2 {
  margin-bottom: 16px;
  font-size: 22px;
}

.field {
  display: grid;
  gap: 7px;
  margin-bottom: 13px;
}

.field label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 760;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 11px 12px;
  background: #fff;
  color: var(--ink);
  outline: 0;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: rgba(181, 22, 73, 0.65);
  box-shadow: 0 0 0 4px rgba(181, 22, 73, 0.08);
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  padding: 8px 11px;
  font-size: 13px;
}

.chip.is-active {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.catalog-tools {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 12px;
  margin-bottom: 16px;
}

.catalog-tools input,
.catalog-tools select {
  border: 1px solid var(--line);
  border-radius: var(--pill);
  padding: 13px 16px;
  background: #fff;
  outline: 0;
}

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

.product-card {
  display: grid;
  grid-template-rows: auto 1fr;
  overflow: hidden;
}

.product-media {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: #f6dde5;
}

.badge-row {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.badge {
  border-radius: var(--pill);
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  padding: 6px 9px;
  font-size: 12px;
  font-weight: 760;
}

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

.product-body h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.2;
}

.price-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: baseline;
}

.price {
  color: var(--accent);
  font-size: 20px;
  font-weight: 850;
}

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

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

.product-actions .primary-button,
.product-actions .secondary-button {
  flex: 1;
  min-width: 130px;
}

.product-detail {
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(0, 1fr);
  gap: clamp(22px, 4vw, 54px);
  max-width: 1320px;
  margin: 0 auto;
}

.product-detail-media {
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 24px;
  background: #f6dde5;
  box-shadow: var(--shadow);
}

.detail-panel {
  padding: clamp(20px, 4vw, 38px);
}

.detail-panel h1 {
  font-size: clamp(38px, 5vw, 72px);
}

.detail-list {
  display: grid;
  gap: 10px;
  margin: 24px 0;
  padding: 0;
  list-style: none;
}

.detail-list li {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
}

.cart-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 22px;
  max-width: 1280px;
  margin: 0 auto;
}

.cart-panel {
  padding: 20px;
}

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

.cart-row {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px;
  background: #fff;
}

.cart-row img {
  width: 88px;
  height: 100px;
  border-radius: 12px;
  object-fit: cover;
}

.qty {
  display: inline-grid;
  grid-template-columns: 34px 38px 34px;
  align-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--pill);
}

.qty button {
  height: 34px;
  border: 0;
  background: #fff;
}

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

.info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  max-width: 1280px;
  margin: 0 auto;
}

.info-band {
  padding: 22px;
}

.empty {
  display: grid;
  min-height: 360px;
  place-items: center;
  border: 1px dashed rgba(181, 22, 73, 0.35);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.56);
  text-align: center;
}

.notice {
  border-left: 4px solid var(--accent);
  border-radius: 14px;
  padding: 14px 16px;
  background: var(--surface-2);
  color: var(--muted);
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 70;
  max-width: min(520px, calc(100vw - 32px));
  border: 1px solid rgba(181, 22, 73, 0.25);
  border-radius: var(--pill);
  padding: 12px 18px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow);
  color: var(--ink);
  transform: translate(-50%, 120px);
  transition: transform 0.22s ease;
}

.toast.is-visible {
  transform: translate(-50%, 0);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}

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

  .main-nav,
  .quick-search {
    grid-column: 1 / -1;
    justify-self: stretch;
    max-width: none;
  }

  .hero,
  .product-detail,
  .cart-grid,
  .catalog-layout {
    grid-template-columns: 1fr;
  }

  .filters {
    position: static;
  }

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

@media (max-width: 720px) {
  .topbar {
    padding: 12px;
  }

  .brand {
    min-width: 0;
  }

  .brand small,
  .cart-link span {
    display: none;
  }

  .main-nav {
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .quick-search {
    grid-template-columns: minmax(0, 1fr) 86px;
  }

  .quick-search input {
    padding-left: 14px;
  }

  .quick-search button {
    padding-inline: 10px;
  }

  .page {
    padding: 22px 14px 34px;
  }

  .hero {
    min-height: auto;
  }

  h1 {
    font-size: clamp(42px, 14vw, 66px);
  }

  .hero-board {
    grid-template-columns: 1fr;
  }

  .hero-photo {
    min-height: 360px;
  }

  .floating-note {
    position: static;
    max-width: none;
    transform: none;
  }

  .metrics,
  .info-grid,
  .catalog-tools,
  .product-grid {
    grid-template-columns: 1fr;
  }

  .catalog-tools {
    gap: 9px;
  }

  .filters {
    overflow: hidden;
  }

  .chip-row {
    gap: 7px;
  }

  .chip {
    padding: 7px 10px;
  }

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

  .cart-row img {
    width: 72px;
    height: 84px;
  }

  .cart-row-actions {
    grid-column: 1 / -1;
  }

}
