/* ==========================================================================
   rubies&pearls, design tokens
   Colours pulled directly from the brand logo, not a generic antique palette.
   Display: Fraunces (soft, wonky-optical antique serif)
   Body: Jost (warm geometric sans, clean counterpoint)
   ========================================================================== */

:root {
  --parchment:        #F8EFE8;
  --parchment-deep:    #EFDED3;
  --card:              #FFFBF7;
  --ink:               #3A2A26;
  --ink-soft:          #6B5850;
  --oxblood:           #621E2D;
  --oxblood-deep:      #451420;
  --brass:             #AD8A5C;
  --brass-light:       #CBAE85;
  --rose-dust:         #BB8F86;

  --font-display: "Fraunces", "Georgia", serif;
  --font-body: "Jost", "Helvetica Neue", sans-serif;

  --radius: 2px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --container: 1180px;
}

@media (prefers-color-scheme: dark) {
  /* Intentionally not implementing a dark theme, the brand lives in warm parchment light. */
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  background: var(--parchment);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  position: relative;
  overflow-x: hidden;
}

/* ---------- textured, animated background ---------- */
.grain-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.5;
  mix-blend-mode: multiply;
}
.grain-layer svg { width: 100%; height: 100%; }

.light-sweep {
  position: fixed;
  inset: -20% -20%;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(ellipse 60% 45% at 20% 15%, rgba(217, 189, 140, 0.28), transparent 60%),
              radial-gradient(ellipse 50% 40% at 85% 70%, rgba(107, 36, 56, 0.10), transparent 65%);
  animation: driftLight 32s ease-in-out infinite alternate;
}
@keyframes driftLight {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(-3%, 2%) scale(1.06); }
}

main, header, footer { position: relative; z-index: 1; }

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

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

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--oxblood-deep);
  font-weight: 500;
  margin: 0 0 0.4em;
  letter-spacing: -0.01em;
}

.eyebrow {
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.72rem;
  color: var(--brass);
  font-weight: 500;
}

p { margin: 0 0 1em; color: var(--ink-soft); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 30px;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 500;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), background 0.35s var(--ease), color 0.35s var(--ease);
}
.btn-primary {
  background: var(--oxblood);
  color: var(--parchment);
  box-shadow: 0 1px 0 rgba(0,0,0,0.15);
}
.btn-primary:hover {
  background: var(--oxblood-deep);
  transform: translateY(-2px);
  box-shadow: 0 10px 24px -8px rgba(74, 24, 38, 0.55);
}
.btn-ghost {
  background: transparent;
  border-color: var(--oxblood);
  color: var(--oxblood);
}
.btn-ghost:hover {
  background: var(--oxblood);
  color: var(--parchment);
  transform: translateY(-2px);
}

/* ---------- header / nav ---------- */
.site-header {
  padding: 22px 0;
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(243, 233, 220, 0.82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(107, 36, 56, 0.08);
}
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand {
  display: flex;
  align-items: center;
}
.brand-mark {
  height: 92px;
  width: auto;
  display: block;
  transition: transform 0.4s var(--ease);
}
.brand:hover .brand-mark { transform: scale(1.03); }
.brand-mark-sm .brand-mark { height: 68px; }

.nav-links {
  display: flex;
  gap: 34px;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.86rem;
  letter-spacing: 0.03em;
}
.nav-links a {
  position: relative;
  padding-bottom: 4px;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0; height: 1px;
  background: var(--brass);
  transition: width 0.35s var(--ease);
}
.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }
.nav-links a.active { color: var(--oxblood); }

.nav-actions { display: flex; align-items: center; gap: 20px; }
.cart-link { position: relative; font-size: 0.86rem; }
.cart-count {
  position: absolute;
  top: -9px; right: -14px;
  background: var(--oxblood);
  color: var(--parchment);
  font-size: 0.62rem;
  width: 17px; height: 17px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}

.nav-toggle {
  display: none;
  background: none; border: none; cursor: pointer;
  flex-direction: column; gap: 5px; padding: 6px;
}
.nav-toggle span { width: 22px; height: 1.5px; background: var(--oxblood-deep); display: block; }

/* ---------- hero ---------- */
.hero {
  padding: 72px 0 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
}
.hero-media {
  position: relative;
  aspect-ratio: 4/5;
  overflow: hidden;
  border-radius: var(--radius);
}
.hero-media img {
  width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.08);
  animation: heroZoom 1.6s var(--ease) forwards;
}
@keyframes heroZoom { to { transform: scale(1); } }
.hero-media::after {
  content: "";
  position: absolute; inset: 0;
  box-shadow: inset 0 0 0 1px rgba(184, 147, 91, 0.4);
  border-radius: var(--radius);
}

.locket {
  position: absolute;
  width: 96px; height: 96px;
  right: -30px; bottom: -30px;
  filter: drop-shadow(0 12px 20px rgba(74,24,38,0.35));
  animation: swing 6s ease-in-out infinite;
  transform-origin: 50% 0%;
}
@keyframes swing {
  0%, 100% { transform: rotate(-4deg); }
  50% { transform: rotate(4deg); }
}

.hero h1 {
  font-size: clamp(2.3rem, 4vw, 3.4rem);
  line-height: 1.1;
  opacity: 0;
  animation: riseIn 0.9s var(--ease) 0.15s forwards;
}
.hero p.lede {
  font-size: 1.08rem;
  max-width: 46ch;
  opacity: 0;
  animation: riseIn 0.9s var(--ease) 0.35s forwards;
}
.hero .cta-row {
  display: flex; gap: 16px; margin-top: 8px;
  opacity: 0;
  animation: riseIn 0.9s var(--ease) 0.5s forwards;
}
@keyframes riseIn {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- spine label (signature element) ---------- */
/* A rotated catalogue-spine strip anchored to the hero, standing in for the
   old full-width centered tagline banner, which is the single most common
   pattern on this style of storefront and the biggest tell of a template. */
.spine-label {
  position: absolute;
  left: -18px;
  top: 50%;
  transform: translateY(-50%) rotate(-90deg);
  transform-origin: left center;
  white-space: nowrap;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 0.92rem;
  letter-spacing: 0.03em;
  color: var(--brass);
  margin: 0;
}
.spine-label .reveal-word {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.4em);
  filter: blur(3px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease), filter 0.7s var(--ease);
}
.spine-label.in-view .reveal-word {
  opacity: 1; transform: translateY(0); filter: blur(0);
}
@media (max-width: 900px) {
  .spine-label { display: none; }
}

/* ---------- spotlight (single featured piece) ---------- */
.spotlight {
  display: grid;
  grid-template-columns: minmax(0, 46vw) 1fr;
  align-items: center;
  margin: 20px 0 100px;
}
.spotlight-media {
  aspect-ratio: 3/4;
  overflow: hidden;
  background: var(--parchment-deep);
}
.spotlight-media img {
  width: 100%; height: 100%; object-fit: cover;
}
.spotlight-copy {
  padding: 0 0 0 60px;
  max-width: 46ch;
}
.spotlight-lot {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--brass);
  margin: 10px 0 4px;
}
.spotlight-copy h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); margin-bottom: 10px; }
.spotlight-note { max-width: 40ch; }
.spotlight-row {
  display: flex; align-items: center; gap: 22px; margin-top: 18px;
}
.spotlight-row .price { font-size: 1.3rem; color: var(--oxblood-deep); font-family: var(--font-display); }
@media (max-width: 900px) {
  .spotlight { grid-template-columns: 1fr; margin-bottom: 70px; }
  .spotlight-media { aspect-ratio: 4/3; }
  .spotlight-copy { padding: 30px 32px 0; max-width: none; }
}

/* ---------- story section ---------- */
.story {
  padding: 90px 0;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 70px;
  align-items: start;
}
.story-mark {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--brass);
  font-size: 5rem;
  line-height: 1;
  margin-bottom: 10px;
}
.story h2 { font-size: 2.1rem; }
.story p { font-size: 1.02rem; }

/* ---------- product grid ---------- */
.shop-toolbar {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 34px; flex-wrap: wrap; gap: 16px;
}
.filter-row {
  display: flex; gap: 10px; flex-wrap: wrap;
}
.filter-chip {
  padding: 8px 18px;
  border: 1px solid rgba(107,36,56,0.25);
  border-radius: 999px;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  cursor: pointer;
  background: transparent;
  transition: all 0.3s var(--ease);
}
.filter-chip:hover { border-color: var(--oxblood); }
.filter-chip.active {
  background: var(--oxblood);
  color: var(--parchment);
  border-color: var(--oxblood);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 30px;
}

.product-card {
  background: var(--card);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  box-shadow: 0 1px 2px rgba(74,24,38,0.06);
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
  opacity: 0;
  transform: translateY(24px);
}
.product-card.in-view { opacity: 1; transform: translateY(0); }
.product-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 40px -18px rgba(74,24,38,0.35);
}
.product-media {
  aspect-ratio: 1/1;
  overflow: hidden;
  background: var(--parchment-deep);
  position: relative;
}
.product-media img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.7s var(--ease);
}
.product-card:hover .product-media img { transform: scale(1.06); }

.sold-ribbon {
  position: absolute; top: 14px; left: -34px;
  background: var(--oxblood);
  color: var(--parchment);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 5px 40px;
  transform: rotate(-40deg);
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}

/* provenance hangtag, signature hover motif */
.hangtag {
  position: absolute;
  top: 10px; right: 10px;
  width: 30px; height: 46px;
  transform-origin: top center;
  transform: rotate(8deg);
  transition: transform 0.5s var(--ease);
  pointer-events: none;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.2));
}
.product-card:hover .hangtag { transform: rotate(-6deg) translateY(2px); }

.product-info { padding: 20px 20px 22px; }
.product-lot {
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brass);
  margin-bottom: 6px;
}
.product-info h3 {
  font-size: 1.12rem;
  margin-bottom: 4px;
}
.product-note {
  font-size: 0.86rem;
  color: var(--ink-soft);
  margin-bottom: 10px;
}
.product-price-row {
  display: flex; align-items: center; justify-content: space-between;
}
.price { font-family: var(--font-display); font-size: 1.15rem; color: var(--oxblood-deep); }
.add-btn {
  border: 1px solid var(--oxblood);
  background: none;
  color: var(--oxblood);
  width: 34px; height: 34px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 1;
  transition: all 0.3s var(--ease);
}
.add-btn:hover { background: var(--oxblood); color: var(--parchment); transform: rotate(90deg); }
.add-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.add-btn:disabled:hover { background: none; color: var(--oxblood); transform: none; }

/* ---------- zoom / magnify ---------- */
.product-media { cursor: zoom-in; }

.zoom-lightbox {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(58, 42, 38, 0.92);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none;
  transition: opacity 0.35s var(--ease);
}
.zoom-lightbox.open { opacity: 1; pointer-events: auto; }
.zoom-stage {
  position: relative;
  width: min(78vw, 640px);
  height: min(78vw, 640px);
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: 0 30px 70px -20px rgba(0,0,0,0.5);
  background: var(--card);
  cursor: zoom-in;
}
.zoom-stage.zoomed { cursor: zoom-out; }
.zoom-stage img {
  width: 100%; height: 100%; object-fit: cover;
  transform-origin: center;
  transition: transform 0.25s var(--ease);
}
.zoom-stage.zoomed img { transform: scale(2.2); transition: transform 0.1s linear; }
.zoom-close {
  position: absolute; top: -46px; right: 0;
  background: none; border: none; color: var(--parchment);
  font-size: 1.6rem; cursor: pointer; line-height: 1;
  font-family: var(--font-display);
}
.zoom-caption {
  position: absolute; bottom: -40px; left: 0; right: 0;
  text-align: center; color: rgba(248,239,232,0.75);
  font-size: 0.8rem; letter-spacing: 0.04em;
}
.zoom-hint {
  position: absolute; bottom: 10px; right: 10px;
  background: rgba(58,42,38,0.65);
  color: var(--parchment);
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 999px;
  pointer-events: none;
  opacity: 0.9;
}

/* ---------- mailing list ---------- */
.mailing-band {
  background: var(--oxblood);
  color: var(--parchment);
  padding: 80px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.mailing-band::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(circle at 20% 30%, rgba(217,189,140,0.15), transparent 55%);
}
.mailing-band h2 { color: var(--brass-light); font-size: 2rem; }
.mailing-band p { color: rgba(243,233,220,0.82); max-width: 48ch; margin: 0 auto 26px; }
.mail-form {
  display: flex; gap: 0; max-width: 420px; margin: 0 auto;
  border: 1px solid rgba(217,189,140,0.5);
  border-radius: var(--radius);
  overflow: hidden;
}
.mail-form input {
  flex: 1; border: none; background: transparent;
  padding: 14px 18px; color: var(--parchment); font-family: var(--font-body);
  font-size: 0.9rem;
}
.mail-form input::placeholder { color: rgba(243,233,220,0.55); }
.mail-form input:focus { outline: none; background: rgba(255,255,255,0.06); }
.mail-form button {
  border: none; background: var(--brass);
  color: var(--oxblood-deep); font-weight: 600;
  padding: 0 24px; cursor: pointer; font-size: 0.85rem;
  letter-spacing: 0.04em; text-transform: uppercase;
  transition: background 0.3s var(--ease);
}
.mail-form button:hover { background: var(--brass-light); }
.mail-note { font-size: 0.74rem; margin-top: 12px; color: rgba(243,233,220,0.6); }
.form-status { min-height: 20px; font-size: 0.82rem; margin-top: 12px; }

/* ---------- footer ---------- */
.site-footer {
  padding: 60px 0 34px;
  border-top: 1px solid rgba(107,36,56,0.12);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.footer-grid h4 {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-family: var(--font-body);
  margin-bottom: 14px;
}
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; font-size: 0.88rem; }
.footer-grid ul a:hover { color: var(--oxblood); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 10px;
  font-size: 0.78rem;
  color: var(--ink-soft);
  padding-top: 24px;
  border-top: 1px solid rgba(107,36,56,0.08);
}
.footer-credit a {
  color: var(--oxblood);
  border-bottom: 1px solid var(--brass);
  padding-bottom: 1px;
}

/* ---------- page header (about, shop, legal) ---------- */
.page-head {
  padding: 60px 0 40px;
  text-align: center;
}
.page-head h1 { font-size: clamp(2rem, 4vw, 2.8rem); }

/* legal pages */
.legal-body { padding: 20px 0 90px; max-width: 74ch; margin: 0 auto; }
.legal-body h2 { font-size: 1.3rem; margin-top: 2em; }
.legal-body ul { color: var(--ink-soft); }
.legal-body li { margin-bottom: 0.4em; }

/* about page specifics */
.about-hero {
  display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 60px;
  align-items: center; padding: 40px 0 100px;
}
.about-portrait {
  aspect-ratio: 3/4; border-radius: var(--radius); overflow: hidden;
  background: var(--parchment-deep);
}
.about-portrait img { width: 100%; height: 100%; object-fit: cover; }
.founder-signoff {
  font-family: var(--font-display); font-style: italic; color: var(--oxblood);
  font-size: 1.3rem; margin-top: 24px;
}

.values-row {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px;
  padding: 0 0 100px;
}
.value-card {
  padding: 34px 28px; background: var(--card); border-radius: var(--radius);
  border-top: 2px solid var(--brass);
}
.value-card .num { font-family: var(--font-display); font-style: italic; color: var(--brass); font-size: 1.3rem; }

/* ---------- checkout / cart ---------- */
.cart-layout { display: grid; grid-template-columns: 1.6fr 1fr; gap: 50px; padding: 20px 0 100px; align-items: start; }
.cart-item { display: grid; grid-template-columns: 84px 1fr auto; gap: 18px; align-items: center; padding: 18px 0; border-bottom: 1px solid rgba(107,36,56,0.1); }
.cart-item img { width: 84px; height: 84px; object-fit: cover; border-radius: var(--radius); }
.cart-item .remove { background: none; border: none; color: var(--ink-soft); cursor: pointer; font-size: 0.78rem; text-decoration: underline; }
.summary-card { background: var(--card); padding: 30px; border-radius: var(--radius); position: sticky; top: 110px; }
.summary-row { display: flex; justify-content: space-between; margin-bottom: 12px; font-size: 0.92rem; }
.summary-row.total { font-family: var(--font-display); font-size: 1.2rem; color: var(--oxblood-deep); border-top: 1px solid rgba(107,36,56,0.15); padding-top: 14px; margin-top: 14px; }
.delivery-options { display: flex; flex-direction: column; gap: 10px; margin: 18px 0; }
.delivery-option {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px; border: 1px solid rgba(107,36,56,0.2); border-radius: var(--radius);
  cursor: pointer; font-size: 0.88rem;
}
.delivery-option input { accent-color: var(--oxblood); }
.delivery-option.selected { border-color: var(--oxblood); background: rgba(107,36,56,0.04); }
.empty-cart { text-align: center; padding: 80px 0; }

/* ---------- misc ---------- */
.section-head { text-align: center; max-width: 60ch; margin: 0 auto 50px; }
.section-head .eyebrow { display: block; margin-bottom: 10px; }

.scroll-fade { opacity: 0; transform: translateY(28px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
.scroll-fade.in-view { opacity: 1; transform: translateY(0); }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero, .story, .about-hero { grid-template-columns: 1fr; }
  .hero-media { order: -1; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .values-row { grid-template-columns: 1fr; }
  .cart-layout { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .nav-links, .nav-actions .btn-ghost { display: none; }
  .nav-toggle { display: flex; }
  .site-header.menu-open .nav-links {
    display: flex; position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; background: var(--parchment); padding: 24px 32px;
    border-bottom: 1px solid rgba(107,36,56,0.12); gap: 18px;
  }
  .container { padding: 0 20px; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .slogan-band { padding: 90px 0; }
}
