/* =========================================================
   CHANCE ATELIER, main stylesheet
   Change the look here: colours and fonts are in :root.
   No animations on purpose (version 1).
   ========================================================= */

:root {
  --cream: #f5f2eb;        /* page background */
  --paper: #ece8de;        /* cards, placeholders */
  --ink: #1f241e;          /* main text */
  --muted: #6b7266;        /* secondary text */
  --sage: #8aab78;         /* Chance sage (logo) */
  --sage-deep: #4f6b45;    /* links, buttons */
  --sage-dark: #2c3a28;    /* announcement bar, footer */
  --line: #d8d3c6;

  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Jost", "Futura", "Helvetica Neue", Arial, sans-serif;

  --header-h: 72px;
  --pad: clamp(16px, 3vw, 40px);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--cream);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.6;
  letter-spacing: .02em;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
h1, h2, h3 { font-family: var(--serif); font-weight: 500; letter-spacing: .04em; margin: 0; }
.wrap { padding: 0 var(--pad); }
.eyebrow { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.serif-title { font-family: var(--serif); font-size: clamp(30px, 4vw, 48px); text-transform: uppercase; text-align: center; color: var(--sage-dark); }
.btn {
  display: inline-block; padding: 14px 34px; border-radius: 999px;
  background: var(--sage-dark); color: var(--cream);
  font-size: 12px; letter-spacing: .18em; text-transform: uppercase;
}
.btn:hover { background: var(--sage-deep); }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--ink); }
.btn.light { background: var(--cream); color: var(--ink); }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.link { text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Announcement bar ---------- */
.announce {
  background: var(--sage-dark); color: var(--cream);
  text-align: center; font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
  padding: 9px var(--pad);
}
.announce a:hover { text-decoration: underline; }

/* ---------- Header ---------- */
.header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: 0 var(--pad);
  background: var(--cream);
  border-bottom: 1px solid var(--line);
}
.header.over { position: relative; background: transparent; border-color: transparent; color: #fff; }
body[data-hero] #site-header { position: absolute; top: 0; left: 0; right: 0; z-index: 50; }
.header .left, .header .right { display: flex; align-items: center; gap: 22px; }
.header .right { justify-content: flex-end; }
.header .hbtn { display: flex; align-items: center; gap: 8px; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
.header svg { width: 19px; height: 19px; stroke: currentColor; fill: none; stroke-width: 1.4; }
.header .logo img { height: 42px; width: auto; }
.header .count { font-size: 11px; min-width: 14px; }
@media (max-width: 700px) {
  .header .hbtn span.lbl { display: none; }
  .header .logo img { height: 32px; }
  .header .right { gap: 14px; } .header .left { gap: 14px; }
  .header .hide-sm { display: none; }
}

/* ---------- Menu drawer + search panel ---------- */
.overlay { position: fixed; inset: 0; background: rgba(31, 36, 30, .35); z-index: 90; display: none; }
.overlay.open { display: block; }
.drawer {
  position: fixed; top: 0; left: 0; bottom: 0; width: min(420px, 90vw);
  background: var(--cream); z-index: 100; padding: 26px var(--pad) 40px;
  display: none; overflow-y: auto;
}
.drawer.open { display: block; }
.drawer .close { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 36px; }
.drawer nav a, .drawer nav .sub-title {
  display: block; font-family: var(--serif); font-size: 28px; line-height: 1.5; color: var(--ink);
}
.drawer nav a:hover { color: var(--sage-deep); }
.drawer nav .sub { padding-left: 18px; margin-bottom: 6px; }
.drawer nav .sub a { font-size: 21px; }
.drawer .drawer-foot { margin-top: 40px; border-top: 1px solid var(--line); padding-top: 22px; font-size: 13px; }
.drawer .drawer-foot a { display: block; padding: 4px 0; }

.search-panel {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100; background: var(--cream);
  padding: 22px var(--pad) 34px; display: none; max-height: 90vh; overflow-y: auto;
}
.search-panel.open { display: block; }
.search-panel .bar { display: flex; gap: 16px; align-items: center; border-bottom: 1px solid var(--ink); }
.search-panel input {
  flex: 1; border: 0; background: transparent; font-family: var(--serif); font-size: 30px; padding: 10px 0; outline: none; color: var(--ink);
}
.search-panel .results { margin-top: 26px; }

/* ---------- Hero ---------- */
.hero { position: relative; height: 100vh; min-height: 560px; overflow: hidden; background: var(--sage-dark); }
.hero > img.bg { width: 100%; height: 100%; object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; background: rgba(20, 26, 18, .22); }
.hero .giant {
  position: absolute; z-index: 2; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: min(78vw, 1100px);
}
.hero .hero-cta { position: absolute; z-index: 2; bottom: 9vh; left: 0; right: 0; text-align: center; color: #fff; }
.hero .hero-cta .eyebrow { color: #fff; display: block; margin-bottom: 14px; }

/* ---------- Sections ---------- */
.section { padding: clamp(56px, 8vw, 110px) 0; }
.section-head { text-align: center; margin-bottom: 44px; }
.section-head p { color: var(--muted); max-width: 560px; margin: 12px auto 0; }

/* ---------- Product grid ---------- */
.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 34px 20px; }
@media (max-width: 1000px) { .grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 700px) { .grid { grid-template-columns: repeat(2, 1fr); gap: 26px 12px; } }
.card { display: block; text-align: center; }
.card .media { position: relative; aspect-ratio: 4 / 5; background: var(--paper); border-radius: 14px; overflow: hidden; }
.card .media img { width: 100%; height: 100%; object-fit: cover; }
.card .tag { position: absolute; top: 12px; left: 12px; background: rgba(245, 242, 235, .92); padding: 2px 9px; border-radius: 999px; font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--ink); }
.card .fav { position: absolute; top: 10px; right: 10px; width: 30px; height: 30px; border-radius: 50%; background: rgba(245, 242, 235, .92); display: flex; align-items: center; justify-content: center; }
.card .fav svg { width: 15px; height: 15px; stroke: var(--ink); fill: none; stroke-width: 1.3; }
.card .fav.on svg { fill: var(--ink); }
.card .name { margin-top: 14px; font-size: 13px; letter-spacing: .06em; }
.card .price { margin-top: 2px; font-size: 13px; font-weight: 500; }
.card .colour { font-size: 12px; color: var(--muted); }

/* Placeholder visual, shown until real photos are added */
.ph {
  width: 100%; height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  color: rgba(255, 255, 255, .92); text-align: center; padding: 20px;
  filter: saturate(.75);
}
.ph .ph-mark { font-family: var(--serif); font-size: 13px; letter-spacing: .5em; text-transform: uppercase; opacity: .8; }
.ph .ph-name { font-family: var(--serif); font-size: clamp(22px, 2.6vw, 34px); letter-spacing: .08em; text-transform: uppercase; line-height: 1.1; }
.ph .ph-note { font-size: 10px; letter-spacing: .2em; text-transform: uppercase; opacity: .7; }
.ph.light { color: rgba(31, 36, 30, .75); }

/* ---------- Collection tiles ---------- */
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 800px) { .tiles { grid-template-columns: 1fr; } }
.tile { position: relative; display: block; aspect-ratio: 4 / 5; overflow: hidden; border-radius: 14px; background: var(--paper); }
.tile img { width: 100%; height: 100%; object-fit: cover; }
.tile .tile-text { position: absolute; left: 0; right: 0; bottom: 0; padding: 26px; color: #fff; background: linear-gradient(transparent, rgba(0, 0, 0, .45)); text-align: center; }
.tile h3 { font-size: 38px; text-transform: uppercase; }
.tile .eyebrow { color: #fff; }

/* ---------- Split block (image + text) ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 5vw, 80px); align-items: center; }
.split img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 14px; }
.split .text { max-width: 460px; }
.split .text h2 { font-size: clamp(32px, 4vw, 52px); text-transform: uppercase; color: var(--sage-dark); margin: 10px 0 18px; line-height: 1.05; }
.split .text p { color: var(--muted); }
@media (max-width: 800px) { .split { grid-template-columns: 1fr; } }

/* ---------- Page header (listing pages) ---------- */
.page-head { text-align: center; padding: 56px var(--pad) 36px; }
.page-head h1 { font-size: clamp(34px, 5vw, 60px); text-transform: uppercase; color: var(--sage-dark); }
.page-head p { color: var(--muted); max-width: 620px; margin: 12px auto 0; }
.count-line { text-align: right; font-size: 12px; color: var(--muted); margin-bottom: 18px; }
.filters { display: flex; justify-content: center; gap: 22px; flex-wrap: wrap; margin-bottom: 30px; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; }
.filters a { padding-bottom: 3px; border-bottom: 1px solid transparent; }
.filters a.on { border-color: var(--ink); }

/* Collection banner */
.banner { position: relative; height: 70vh; min-height: 420px; overflow: hidden; background: var(--sage-dark); }
.banner img { width: 100%; height: 100%; object-fit: cover; object-position: center 35%; }
.banner::after { content: ""; position: absolute; inset: 0; background: rgba(20, 26, 18, .25); }
.banner .banner-text { position: absolute; inset: 0; z-index: 2; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #fff; text-align: center; }
.banner h1 { font-size: clamp(48px, 9vw, 120px); text-transform: uppercase; }
.banner .eyebrow { color: #fff; }
.story { max-width: 680px; margin: 0 auto; text-align: center; font-family: var(--serif); font-size: 21px; line-height: 1.6; }
.story p { margin: 0 0 18px; }

/* ---------- Product page ---------- */
.pdp { display: grid; grid-template-columns: 1.1fr 1fr; min-height: calc(100vh - var(--header-h)); }
.pdp .gallery { display: grid; gap: 4px; background: var(--paper); }
.pdp .gallery .shot { aspect-ratio: 4 / 5; background: var(--paper); }
.pdp .gallery .shot img { width: 100%; height: 100%; object-fit: cover; }
.pdp .info { position: sticky; top: var(--header-h); align-self: start; padding: 56px clamp(20px, 6vw, 90px); text-align: center; }
.pdp .info h1 { font-size: clamp(28px, 3vw, 40px); text-transform: uppercase; margin-top: 8px; }
.pdp .info .price { font-size: 17px; font-weight: 500; margin-top: 6px; }
.pdp .info .colour { margin-top: 26px; color: var(--muted); font-size: 13px; }
.pdp .info .colour b { color: var(--ink); font-weight: 400; }
.sizes { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin: 22px 0 6px; }
.sizes button { min-width: 52px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 999px; font-size: 12px; letter-spacing: .08em; }
.sizes button.on { border-color: var(--ink); background: var(--ink); color: var(--cream); }
.size-msg { min-height: 20px; font-size: 12px; color: #9a3b2c; }
.add-row { display: flex; gap: 10px; justify-content: center; align-items: center; margin-top: 8px; }
.add-row .btn { flex: 1; max-width: 360px; }
.fav-btn { width: 48px; height: 48px; border: 1px solid var(--line); border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.fav-btn svg { width: 18px; height: 18px; stroke: var(--ink); fill: none; stroke-width: 1.3; }
.fav-btn.on svg { fill: var(--ink); }
.added { margin-top: 14px; font-size: 13px; min-height: 22px; }
.pdp .desc { margin-top: 34px; text-align: left; border-top: 1px solid var(--line); }
.pdp details { border-bottom: 1px solid var(--line); padding: 16px 0; }
.pdp summary { cursor: pointer; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; list-style: none; display: flex; justify-content: space-between; }
.pdp summary::after { content: "+"; }
.pdp details[open] summary::after { content: "\2212"; }
.pdp details p, .pdp details ul { color: var(--muted); margin: 12px 0 0; }
.pdp details ul { padding-left: 18px; }
.secure-note { margin-top: 22px; font-size: 12px; color: var(--muted); }
@media (max-width: 900px) {
  .pdp { grid-template-columns: 1fr; }
  .pdp .info { position: static; padding-top: 34px; }
}

.badge { display: inline-block; margin-bottom: 12px; padding: 4px 12px; border: 1px solid var(--sage-deep); border-radius: 999px; color: var(--sage-deep); font-size: 10px; letter-spacing: .2em; text-transform: uppercase; }
.badge + .eyebrow { display: block; }
.addon { display: flex; justify-content: center; align-items: center; gap: 8px; margin: 4px 0 14px; font-size: 13px; cursor: pointer; }
.addon input { accent-color: var(--sage-dark); width: 16px; height: 16px; }
.addon b { font-weight: 500; }
.stock { margin-top: 6px; font-size: 12px; color: var(--sage-deep); }

/* ---------- Cart ---------- */
.cart { display: grid; grid-template-columns: 1.6fr 1fr; gap: clamp(24px, 5vw, 70px); padding-bottom: 90px; }
.cart-line { display: grid; grid-template-columns: 110px 1fr auto; gap: 20px; padding: 20px 0; border-bottom: 1px solid var(--line); }
.cart-line .thumb { aspect-ratio: 4 / 5; border-radius: 10px; overflow: hidden; background: var(--paper); }
.cart-line .thumb .ph .ph-name { font-size: 14px; }
.cart-line .thumb .ph .ph-mark, .cart-line .thumb .ph .ph-note { display: none; }
.cart-line .meta { font-size: 13px; color: var(--muted); }
.cart-line .meta b { color: var(--ink); font-weight: 500; display: block; font-size: 14px; }
.qty { display: inline-flex; align-items: center; gap: 14px; margin-top: 12px; border: 1px solid var(--line); border-radius: 999px; padding: 4px 14px; }
.remove { margin-top: 10px; font-size: 12px; text-decoration: underline; color: var(--muted); display: block; }
.summary { background: var(--paper); border-radius: 14px; padding: 30px; align-self: start; position: sticky; top: calc(var(--header-h) + 20px); }
.summary .row { display: flex; justify-content: space-between; padding: 6px 0; }
.summary .total { border-top: 1px solid var(--line); margin-top: 10px; padding-top: 14px; font-weight: 500; font-size: 16px; }
.summary .btn { width: 100%; margin-top: 22px; text-align: center; }
.summary .small { font-size: 12px; color: var(--muted); margin-top: 16px; }
.summary .msg { font-size: 13px; color: #9a3b2c; margin-top: 12px; }
.empty { text-align: center; padding: 40px 0 100px; }
@media (max-width: 900px) { .cart { grid-template-columns: 1fr; } .summary { position: static; } }

/* ---------- Text pages (legal, contact, world) ---------- */
.text-page { max-width: 760px; margin: 0 auto; padding: 20px var(--pad) 100px; }
.text-page h2 { font-size: 26px; margin: 40px 0 10px; color: var(--sage-dark); }
.text-page h3 { font-size: 20px; margin: 26px 0 6px; }
.text-page p, .text-page li { color: #3c4239; }
.text-page .updated { color: var(--muted); font-size: 12px; text-align: center; }
.todo { background: #fff3c4; color: #6b5200; padding: 0 4px; border-radius: 3px; }
.contact-card { background: var(--paper); border-radius: 14px; padding: 34px; text-align: center; margin: 20px 0 30px; }
.contact-card .big { font-family: var(--serif); font-size: 28px; color: var(--sage-dark); }

/* ---------- Footer ---------- */
.footer { background: var(--sage-dark); color: #dfe4d9; padding: 64px var(--pad) 30px; font-size: 13px; }
.footer .cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 34px; }
.footer h4 { font-family: var(--sans); font-weight: 500; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; margin: 0 0 14px; color: #fff; }
.footer a { display: block; padding: 3px 0; color: #dfe4d9; }
.footer a:hover { color: #fff; }
.footer .flogo { width: 190px; margin-bottom: 16px; }
.footer .bottom { margin-top: 50px; padding-top: 22px; border-top: 1px solid rgba(255, 255, 255, .15); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: 12px; color: #b6bfae; }
@media (max-width: 800px) { .footer .cols { grid-template-columns: 1fr 1fr; } }
