/* ===== Ashury design system — classic, elegant, flat, low-gradient =====
   Ported 1:1 from the Next.js storefront globals.css so recreated markup
   (same class names) styles identically. */
:root {
  /* Palette — warm cream + near-black ink + muted Dead Sea gold */
  --bg: #faf8f4;
  --surface: #ffffff;
  --ink: #17140f;
  --ink-soft: #4c463d;
  --line: #e8e1d6;
  --gold: #96773c;       /* decorative / large text only */
  --gold-deep: #6d5322;  /* AA on cream for normal text */
  --gold-light: #b7935a; /* AA on ink/dark surfaces (6.4:1) */
  --sale: #9a2f2f;
  --img-bg: #f2ede4;     /* resting background behind product/collection imagery */

  /* Status tokens — trust-sensitive pages (checkout, order-received) */
  --success: #1f6f4a;
  --warn-bg: #fff6e5;
  --warn-ink: #6b4e00;
  --warn-border: #f0d9a8;
  --error-bg: #fdecec;
  --error-border: #f0b8b8;

  /* Type */
  --font-sans: "DM Sans", "Google Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --step--1: clamp(0.82rem, 0.79rem + 0.15vw, 0.9rem);
  --step-0: clamp(0.95rem, 0.9rem + 0.25vw, 1.05rem);
  --step-1: clamp(1.2rem, 1.1rem + 0.5vw, 1.5rem);
  --step-2: clamp(1.55rem, 1.35rem + 1vw, 2.15rem);
  --step-3: clamp(2rem, 1.6rem + 2vw, 3.15rem);
  --step-4: clamp(2.6rem, 1.9rem + 3.4vw, 4.5rem);

  /* Space + shape */
  --gap: clamp(1rem, 0.7rem + 1.5vw, 2rem);
  --pad-section: clamp(3rem, 2rem + 4vw, 6rem);
  --radius: 4px;
  --radius-sm: 3px;
  --maxw: 1240px;
  --shadow: 0 1px 2px rgba(23, 20, 15, 0.06), 0 8px 24px rgba(23, 20, 15, 0.05);
}

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

/* Rich prose (product descriptions, blog posts, static pages) */
.prose { line-height: 1.75; color: var(--ink); max-width: 72ch; }
.prose > *:first-child { margin-top: 0; }
.prose p { margin: 0 0 1.1rem; }
.prose h2 { font-size: var(--step-2); margin: 2rem 0 0.8rem; }
.prose h3 { font-size: var(--step-1); margin: 1.6rem 0 0.6rem; }
.prose h4 { font-size: var(--step-0); font-weight: 700; margin: 1.3rem 0 0.5rem; }
.prose ul, .prose ol { margin: 0 0 1.1rem 1.3rem; display: grid; gap: 0.4rem; }
.prose li { padding-left: 0.2rem; }
.prose a { color: var(--gold-deep); text-decoration: underline; text-underline-offset: 2px; }
.prose a:hover { color: var(--ink); }
.prose blockquote {
  border-left: 3px solid var(--gold); padding: 0.4rem 0 0.4rem 1.1rem;
  margin: 0 0 1.1rem; color: var(--ink-soft); font-style: italic;
}
.prose img { max-width: 100%; height: auto; border-radius: var(--radius); margin: 1rem 0; }
.prose table { width: 100%; border-collapse: collapse; margin: 0 0 1.1rem; font-size: var(--step--1); }
.prose th, .prose td { border: 1px solid var(--line); padding: 0.5rem 0.7rem; text-align: left; }

html { color-scheme: light; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: clip; }

body {
  font-family: var(--font-sans);
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

h1, h2, h3, h4 { line-height: 1.12; font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: var(--step-4); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); }
p { max-width: 68ch; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

:focus-visible { outline: 2px solid var(--gold-deep); outline-offset: 3px; border-radius: 2px; }

.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: clamp(1rem, 0.5rem + 2vw, 2.5rem); }
.section { padding-block: var(--pad-section); }
.eyebrow { font-size: var(--step--1); letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold-deep); font-weight: 600; display: inline-block; }
.link { color: var(--gold-deep); font-weight: 600; font-size: var(--step--1); text-transform: uppercase; letter-spacing: 0.1em; border-bottom: 1px solid transparent; }
.link:hover { border-color: var(--gold-deep); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  font: inherit; font-weight: 600; font-size: var(--step-0);
  padding: 0.85em 1.9em; border-radius: var(--radius); cursor: pointer;
  border: 1px solid var(--ink); transition: background-color 0.18s, color 0.18s, border-color 0.18s;
  text-align: center;
}
.btn-primary { background: var(--ink); color: var(--bg); transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease; }
.btn-primary:hover { background: #000; transform: translateY(-1px); box-shadow: var(--shadow); }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--bg); }
.btn:disabled { cursor: not-allowed; opacity: 0.45; box-shadow: none; }
.btn-primary:disabled:hover { background: var(--ink); transform: none; box-shadow: none; }
.qty button:disabled { opacity: 0.35; cursor: not-allowed; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: saturate(1.1) blur(8px); border-bottom: 1px solid var(--line); }
.site-header .bar { display: flex; align-items: center; justify-content: space-between; gap: var(--gap); height: 72px; }
.wordmark { font-size: 1.5rem; font-weight: 700; letter-spacing: 0.32em; text-transform: uppercase; }
.main-nav { display: flex; gap: clamp(1rem, 0.5rem + 1.4vw, 2.4rem); font-size: var(--step--1); text-transform: uppercase; letter-spacing: 0.12em; font-weight: 600; }
.main-nav > li { position: relative; }
.main-nav > li > a { display: inline-block; padding-block: 0.4rem; border-bottom: 2px solid transparent; }
.main-nav > li > a:hover { border-color: var(--gold-deep); }
.header-actions { display: flex; align-items: center; gap: 1.1rem; font-size: var(--step--1); font-weight: 600; text-transform: uppercase; letter-spacing: 0.12em; }
.header-actions a, .header-actions button { padding-block: 0.4rem; border-bottom: 2px solid transparent; background: none; border-top: 0; border-left: 0; border-right: 0; font: inherit; color: inherit; cursor: pointer; text-transform: inherit; letter-spacing: inherit; }
.header-actions a:hover, .header-actions button:hover { border-bottom-color: var(--gold-deep); }
.cart-link { position: relative; display: inline-flex; align-items: center; gap: 0.4rem; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 8px; top: -60px; z-index: 200; background: var(--ink); color: var(--bg); padding: 0.7em 1.2em; border-radius: var(--radius); font-weight: 600; transition: top 0.15s ease; }
.skip-link:focus { top: 8px; }
.cart-badge {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 20px; height: 20px; padding: 0 6px;
  background: var(--ink); color: #fff; border-radius: 999px;
  font-size: 0.7rem; font-weight: 700; line-height: 1;
}
@media (max-width: 760px) { .main-nav { display: none; } }

/* Product grid + card */
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: var(--gap); }
.product-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: box-shadow 0.2s, transform 0.2s; position: relative; }
.product-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.product-card .media { position: relative; aspect-ratio: 1 / 1; background: var(--img-bg); display: block; }
.product-card .media img { width: 100%; height: 100%; object-fit: cover; }
.product-card .body { padding: 0.9rem 1rem 1.1rem; display: flex; flex-direction: column; gap: 0.35rem; flex: 1; }
.product-card .cat { font-size: var(--step--1); color: var(--gold-deep); letter-spacing: 0.08em; text-transform: uppercase; font-weight: 600; }
.product-card .title { font-size: var(--step-0); font-weight: 600; line-height: 1.3; color: var(--ink); }
.product-card .price { margin-top: auto; font-weight: 700; }
.product-card .price .was { color: var(--ink-soft); text-decoration: line-through; font-weight: 400; font-size: var(--step--1); margin-right: 0.5rem; }
.product-card .price .now.sale { color: var(--sale); font-weight: 700; }
.badge-sale { position: absolute; top: 0.6rem; left: 0.6rem; background: var(--sale); color: #fff; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; padding: 0.25rem 0.5rem; border-radius: 2px; text-transform: uppercase; z-index: 2; }

/* Footer */
.site-footer { margin-top: auto; background: var(--ink); color: #d9d2c6; padding-block: clamp(2.5rem, 2rem + 2vw, 4rem); }
.site-footer a { color: #cdc5b7; }
.site-footer a:hover { color: #fff; }
.footer-brand { max-width: 34ch; margin-bottom: clamp(2rem, 1.4rem + 2vw, 3rem); }
.footer-logo-link { display: inline-flex; }
.footer-logo { height: 26px; width: auto; filter: brightness(0) invert(1); opacity: 0.95; }
.footer-wordmark { font-size: 1.4rem; font-weight: 700; letter-spacing: 0.32em; text-transform: uppercase; color: #fff; }
.footer-tagline { margin-top: 1rem; font-size: var(--step--1); color: #a49c8e; line-height: 1.6; max-width: none; }
.footer-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: var(--gap); }
.footer-cols h2 { color: #fff; font-size: var(--step--1); font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; margin-bottom: 1rem; }
.footer-cols ul { list-style: none; display: flex; flex-direction: column; gap: 0.3rem; font-size: var(--step--1); }
.footer-cols li a { display: inline-block; padding-block: 4px; }
.footer-bottom {
  margin-top: clamp(2rem, 1.4rem + 2vw, 3rem);
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255,255,255,0.12);
  font-size: var(--step--1);
  color: #a49c8e;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.5rem;
  justify-content: space-between;
  align-items: center;
}
.footer-trust { letter-spacing: 0.04em; }

/* Generic page prose wrapper */
.page-wrap { padding-block: var(--pad-section); }
.breadcrumb { font-size: var(--step--1); color: var(--ink-soft); margin-bottom: 1.2rem; display: flex; flex-wrap: wrap; gap: 0.4rem; }
.breadcrumb a { color: var(--gold-deep); }
.breadcrumb a:hover { text-decoration: underline; }

@media (prefers-reduced-motion: reduce) {
  .product-card { transition: none; }
  .product-card:hover { transform: none; }
}
