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

:root {
  --bg: #F7F7F5;
  --surface: #ECEAE6;
  --border: #D9D5CF;
  --muted: #8A857D;
  --text: #111111;
  --font: 'Inter', 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

html {
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}

/* ── PAGE TRANSITIONS ── */
body {
  opacity: 0;
  animation: fd-fade-in 180ms ease forwards;
}

@keyframes fd-fade-in {
  to { opacity: 1; }
}

body.fd-leaving {
  opacity: 0;
  transition: opacity 150ms ease;
  pointer-events: none;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-weight: 300;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

button {
  cursor: pointer;
  font-family: var(--font);
  font-weight: 300;
}

/* ── NAV ── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 56px;
}

.nav-logo {
  font-size: 13px;
  letter-spacing: 0.18em;
  font-weight: 400;
}

.nav-center {
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.nav-right {
  display: flex;
  gap: 32px;
  font-size: 11px;
  letter-spacing: 0.12em;
}

.nav-right a {
  color: var(--muted);
  transition: color 120ms;
}

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

.nav-hamburger {
  display: none;
  background: none;
  border: none;
  font-size: 18px;
  color: var(--text);
  cursor: pointer;
}

/* Mobile menu */
.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 200;
  flex-direction: column;
  padding: 56px 48px 48px;
}

.mobile-menu.open {
  display: flex;
}

.mobile-menu-close {
  position: absolute;
  top: 18px;
  right: 48px;
  background: none;
  border: none;
  font-size: 20px;
  color: var(--text);
  cursor: pointer;
}

.mobile-menu a {
  font-size: 28px;
  letter-spacing: 0.08em;
  font-weight: 300;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

/* ── MAIN ── */
main {
  flex: 1;
  padding: 64px 48px;
  max-width: 1440px;
  width: 100%;
  margin: 0 auto;
}

/* ── PRODUCT GRID ── */
.grid-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 48px;
}

.grid-title {
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 48px 32px;
}

/* ── PRODUCT CARD ── */
.product-card {
  display: block;
  cursor: pointer;
}

.product-card-image {
  width: 100%;
  aspect-ratio: 3/4;
  background: var(--surface);
  overflow: hidden;
  margin-bottom: 16px;
}

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

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

.product-card-placeholder {
  width: 100%;
  height: 100%;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 180ms ease;
}

.product-card:hover .product-card-placeholder {
  transform: scale(1.03);
}

.placeholder-label {
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--border);
}

.product-card-name {
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--muted);
  margin-bottom: 4px;
}

.product-card-price {
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--text);
}

/* ── PRODUCT PAGE ── */
.product-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}

.product-image-main {
  width: 100%;
  aspect-ratio: 3/4;
  background: var(--surface);
  overflow: hidden;
}

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

.product-image-placeholder {
  width: 100%;
  height: 100%;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-details {
  padding-top: 16px;
}

.product-name {
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--muted);
  margin-bottom: 12px;
}

.product-price {
  font-size: 22px;
  font-weight: 300;
  letter-spacing: 0.04em;
  margin-bottom: 40px;
}

.size-label {
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--muted);
  margin-bottom: 12px;
}

.size-options {
  display: flex;
  gap: 8px;
  margin-bottom: 40px;
}

.size-btn {
  width: 44px;
  height: 44px;
  border: 1px solid var(--border);
  background: none;
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--text);
  transition: border-color 120ms, background 120ms;
}

.size-btn:hover,
.size-btn.selected {
  border-color: var(--text);
  background: var(--text);
  color: var(--bg);
}

.add-to-cart-btn {
  width: 100%;
  height: 52px;
  background: var(--text);
  color: var(--bg);
  border: none;
  font-size: 11px;
  letter-spacing: 0.18em;
  margin-bottom: 48px;
  transition: opacity 120ms;
}

.add-to-cart-btn:hover {
  opacity: 0.85;
}

.product-description {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.8;
  border-top: 1px solid var(--border);
  padding-top: 32px;
}

/* ── CART ── */
.page-heading {
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--muted);
  margin-bottom: 48px;
}

.cart-items {
  border-top: 1px solid var(--border);
}

.cart-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 0;
  border-bottom: 1px solid var(--border);
}

.cart-item-left {
  display: flex;
  gap: 24px;
  align-items: center;
}

.cart-item-thumb {
  width: 72px;
  height: 96px;
  background: var(--surface);
  flex-shrink: 0;
  overflow: hidden;
}

.cart-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-item-name {
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--muted);
  margin-bottom: 4px;
}

.cart-item-meta {
  font-size: 11px;
  color: var(--muted);
}

.cart-item-price {
  font-size: 13px;
  letter-spacing: 0.04em;
}

.cart-remove {
  background: none;
  border: none;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-left: 24px;
  padding: 0;
  transition: color 120ms;
}

.cart-remove:hover {
  color: var(--text);
}

.cart-footer {
  padding-top: 40px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 24px;
}

.cart-total {
  display: flex;
  gap: 80px;
  font-size: 13px;
  letter-spacing: 0.08em;
}

.cart-total-label {
  color: var(--muted);
}

.checkout-btn {
  display: inline-block;
  padding: 0 48px;
  height: 52px;
  background: var(--text);
  color: var(--bg);
  border: none;
  font-size: 11px;
  letter-spacing: 0.18em;
  line-height: 52px;
  transition: opacity 120ms;
}

.checkout-btn:hover {
  opacity: 0.85;
}

.cart-empty {
  padding: 80px 0;
  font-size: 13px;
  color: var(--muted);
  letter-spacing: 0.08em;
}

/* ── CHECKOUT ── */
.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 80px;
  align-items: start;
}

.form-section {
  margin-bottom: 48px;
}

.form-section-title {
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--muted);
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.form-row.full {
  grid-template-columns: 1fr;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.form-group input,
.form-group select {
  height: 48px;
  border: 1px solid var(--border);
  background: var(--bg);
  padding: 0 16px;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 300;
  color: var(--text);
  outline: none;
  border-radius: 0;
  appearance: none;
  transition: border-color 120ms;
}

.form-group input:focus,
.form-group select:focus {
  border-color: var(--text);
}

.order-summary {
  background: var(--surface);
  padding: 32px;
}

.order-summary-title {
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--muted);
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.order-line {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.order-line-name {
  color: var(--muted);
  letter-spacing: 0.08em;
}

.order-total-line {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding-top: 20px;
  margin-top: 4px;
}

.order-total-line .label {
  color: var(--muted);
  letter-spacing: 0.1em;
}

.place-order-btn {
  width: 100%;
  height: 52px;
  background: var(--text);
  color: var(--bg);
  border: none;
  font-size: 11px;
  letter-spacing: 0.18em;
  margin-top: 32px;
  transition: opacity 120ms;
}

.place-order-btn:hover {
  opacity: 0.85;
}

/* ── ABOUT / STATIC PAGES ── */
.static-page {
  max-width: 480px;
}

.static-heading {
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--muted);
  margin-bottom: 48px;
}

.static-body {
  font-size: 15px;
  line-height: 2;
  color: var(--text);
  font-weight: 300;
}

.static-body p {
  margin-bottom: 24px;
}

.static-body p:last-child {
  margin-bottom: 0;
}

.static-meta {
  font-size: 12px;
  color: var(--muted);
  margin-top: 48px;
  line-height: 2;
}

/* ── CONTACT ── */
.contact-email {
  font-size: 15px;
  font-weight: 300;
  margin-bottom: 48px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 48px;
}

.contact-socials {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact-socials a {
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--muted);
  transition: color 120ms;
}

.contact-socials a:hover {
  color: var(--text);
}

/* ── INFO PAGES (shipping / returns) ── */
.info-block {
  margin-bottom: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--border);
}

.info-block:last-child {
  border-bottom: none;
}

.info-block-title {
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--muted);
  margin-bottom: 16px;
}

.info-block-body {
  font-size: 14px;
  color: var(--text);
  line-height: 1.9;
  font-weight: 300;
}

/* ── FOOTER ── */
footer {
  border-top: 1px solid var(--border);
  padding: 40px 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-links {
  display: flex;
  gap: 32px;
}

.footer-links a {
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--muted);
  transition: color 120ms;
}

.footer-links a:hover {
  color: var(--text);
}

.footer-copy {
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--border);
}

/* ── RESPONSIVE ── */
@media (max-width: 1100px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  nav {
    padding: 0 24px;
  }

  .nav-center,
  .nav-right {
    display: none;
  }

  .nav-hamburger {
    display: block;
  }

  main {
    padding: 40px 24px;
  }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px 16px;
  }

  .product-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .checkout-layout {
    grid-template-columns: 1fr;
    gap: 48px;
  }

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

  footer {
    padding: 32px 24px;
    flex-direction: column;
    gap: 24px;
    align-items: flex-start;
  }

  .footer-links {
    flex-wrap: wrap;
    gap: 20px;
  }

  .mobile-menu {
    padding: 64px 24px 48px;
  }

  .mobile-menu-close {
    right: 24px;
  }
}
