@font-face { font-family: Poppins; font-weight: 400; font-display: swap; src: url(fonts/poppins-400.woff2) format("woff2"); }
@font-face { font-family: Poppins; font-weight: 500; font-display: swap; src: url(fonts/poppins-500.woff2) format("woff2"); }
@font-face { font-family: Poppins; font-weight: 700; font-display: swap; src: url(fonts/poppins-700.woff2) format("woff2"); }

/* Brand book colours: #000000 #6C3728 #824733 #B16336 #DCA962 */
:root {
  --black: #000; --dark: #6c3728; --brown: #824733; --copper: #b16336; --gold: #dca962;
  --ink: #21160f; --muted: #6a574b; --cream: #fbf6ee; --line: #e8dccb; --card: #fff;
  --ok: #2f6b3a; --warn: #9a3412; --r: 14px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 400 16px/1.6 Poppins, system-ui, sans-serif; color: var(--ink); background: var(--cream); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brown); }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; font-weight: 700; }
h1 { font-size: clamp(1.8rem, 5vw, 3rem); }
h2 { font-size: clamp(1.4rem, 3.5vw, 2rem); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.skip { position: absolute; left: -999px; } .skip:focus { left: 16px; top: 8px; z-index: 99; background: #fff; padding: 8px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.muted { color: var(--muted); } .small { font-size: .875rem; }
.kicker { text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; font-weight: 500; color: var(--copper); margin: 0 0 .4em; }

/* header */
.hdr { background: var(--black); color: #fff; position: sticky; top: 0; z-index: 20; }
.hdr-in { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.logo { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 700; font-size: 1.15rem; }
.logo img { width: 52px; }
.nav { display: flex; gap: 4px; margin-left: auto; flex-wrap: wrap; }
.nav a { color: #f3e6d4; text-decoration: none; padding: 8px 10px; border-radius: 8px; font-size: .95rem; }
.nav a:hover, .nav a[aria-current] { color: var(--gold); }
.bag { background: var(--brown); color: #fff; text-decoration: none; padding: 8px 14px; border-radius: 999px; font-weight: 500; white-space: nowrap; }
.bag span { background: var(--gold); color: var(--black); border-radius: 999px; padding: 0 7px; margin-left: 4px; font-size: .8rem; }
.roastbar { margin: 0; background: #140d09; color: #e9d7bf; text-align: center; font-size: .85rem; padding: 6px 16px; }
.roastbar strong { color: var(--gold); }
@media (max-width: 640px) { .hdr { position: static; } .nav { order: 3; width: 100%; margin: 0 0 8px; justify-content: space-between; } .hdr-in { flex-wrap: wrap; } .bag { margin-left: auto; } }

/* buttons & forms */
.btn { display: inline-block; border: 2px solid var(--brown); background: transparent; color: var(--brown); font: inherit; font-weight: 500;
  padding: 10px 20px; border-radius: 999px; text-decoration: none; cursor: pointer; text-align: center; }
.btn-primary { background: var(--brown); color: #fff; }
.btn-primary:hover { background: var(--dark); border-color: var(--dark); }
.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--black); }
.btn-lg { padding: 14px 28px; font-size: 1.05rem; } .btn-sm { padding: 6px 14px; font-size: .9rem; } .btn-block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
label { font-weight: 500; font-size: .95rem; }
input, select, textarea { font: inherit; width: 100%; padding: 10px 12px; border: 1.5px solid #cdb9a3; border-radius: 10px; background: #fff; color: var(--ink); }
input[type=radio], input[type=checkbox] { width: auto; accent-color: var(--brown); }
.field { margin-bottom: 14px; } .field small { color: var(--muted); }
.field.err input, .field.err select { border-color: var(--warn); }
.field.err::after { content: "Please fill this in correctly"; color: var(--warn); font-size: .85rem; }
.grid2 { display: grid; gap: 0 16px; grid-template-columns: 1fr 1fr; } @media (max-width: 560px) { .grid2 { grid-template-columns: 1fr; } }
.flash { background: #fff3dc; border: 1px solid var(--gold); padding: 10px 14px; border-radius: 10px; margin: 16px 0; }

/* hero */
.hero { background: var(--black); color: #f6ead9; padding: 48px 0 56px; overflow: hidden; }
.hero-in { display: grid; grid-template-columns: 1.1fr .9fr; gap: 32px; align-items: center; }
.hero h1 span { color: var(--gold); }
.hero p { color: #e2d0b8; max-width: 34em; }
.hero-art img { width: 100%; max-width: 420px; margin: 0 auto; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin: 20px 0; }
.hero .btn:not(.btn-primary) { color: var(--gold); border-color: var(--gold); }
.countdown { display: inline-flex; gap: 10px; align-items: center; background: #1b120d; border: 1px solid #3a271c; padding: 8px 14px; border-radius: 999px; }
.countdown b { color: var(--gold); font-size: 1.4rem; }
@media (max-width: 760px) { .hero-in { grid-template-columns: 1fr; } .hero-art { order: -1; } .hero-art img { max-width: 220px; } }

.sec { padding-top: 48px; padding-bottom: 48px; }
.sec-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }

/* product cards */
.grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; display: flex; flex-direction: column; }
.card-art { background: #f3e9dc; padding: 20px; display: block; }
.card-art img { max-height: 280px; margin: 0 auto; border-radius: 6px; box-shadow: 0 8px 20px rgba(60, 30, 10, .18); }
.card-body { padding: 16px 18px 18px; display: flex; flex-direction: column; flex: 1; }
.card-body h3 { margin: 0 0 6px; } .card-body h3 a { color: var(--ink); text-decoration: none; }
.card-foot { margin-top: auto; display: flex; justify-content: space-between; align-items: center; gap: 8px; padding-top: 12px; }
.price { font-weight: 700; font-size: 1.1rem; }
.notes { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.notes li { background: #f6ecdf; color: var(--dark); border-radius: 999px; padding: 2px 10px; font-size: .8rem; }
.tag { display: inline-block; background: var(--warn); color: #fff; font-size: .75rem; padding: 2px 8px; border-radius: 999px; }

/* subscription band */
.band { background: var(--dark); color: #fbeedd; }
.band .kicker { color: var(--gold); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; padding: 0; list-style: none; counter-reset: s; }
.steps li { background: rgba(0,0,0,.2); border-radius: var(--r); padding: 18px; counter-increment: s; }
.steps li::before { content: counter(s); display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--gold); color: var(--black); font-weight: 700; margin-bottom: 8px; }
.steps b { display: block; }
@media (max-width: 700px) { .steps { grid-template-columns: 1fr; } }

/* finder */
.quiz { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; }
.quiz fieldset { border: 0; padding: 0; margin: 0 0 16px; }
.quiz legend { font-weight: 700; margin-bottom: 8px; }
.opts { display: flex; flex-wrap: wrap; gap: 8px; }
.opts label { display: flex; gap: 6px; align-items: center; border: 1.5px solid var(--line); border-radius: 999px; padding: 6px 14px; cursor: pointer; font-weight: 400; }
.opts label:has(input:checked) { border-color: var(--brown); background: #f6ecdf; }
.match { display: grid; grid-template-columns: 140px 1fr; gap: 20px; align-items: center; margin-top: 16px; background: #f6ecdf; border-radius: var(--r); padding: 16px; }

/* product page */
.crumbs { font-size: .9rem; margin: 20px 0; }
.pdp { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; padding-bottom: 48px; }
.pdp-art { background: #f3e9dc; border-radius: var(--r); padding: 32px; }
.pdp-art img { max-height: 520px; margin: 0 auto; border-radius: 8px; box-shadow: 0 12px 30px rgba(60, 30, 10, .2); }
@media (max-width: 760px) { .pdp { grid-template-columns: 1fr; gap: 20px; } .pdp-art img { max-height: 340px; } }
.sizes { border: 0; padding: 0; margin: 16px 0; display: grid; gap: 10px; }
.sizes legend { font-weight: 700; margin-bottom: 8px; }
.size { display: flex; gap: 12px; align-items: center; border: 1.5px solid var(--line); border-radius: 12px; padding: 12px 14px; background: #fff; cursor: pointer; }
.size:has(input:checked) { border-color: var(--brown); box-shadow: 0 0 0 2px #f0dcc5; }
.size .p { margin-left: auto; text-align: right; } .size .p small { display: block; color: var(--muted); font-weight: 400; }
.buy-row { display: grid; grid-template-columns: 90px 1fr; gap: 12px; align-items: end; }
.buy-btns { display: grid; gap: 10px; margin-top: 16px; }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 4px 16px; margin: 20px 0; }
.facts dt { color: var(--muted); } .facts dd { margin: 0; font-weight: 500; }
.brew { border-top: 1px solid var(--line); margin-top: 24px; padding-top: 16px; }
.brew table { width: 100%; border-collapse: collapse; font-size: .9rem; } .brew td, .brew th { text-align: left; padding: 6px 4px; border-bottom: 1px solid var(--line); vertical-align: top; }

/* cart drawer: opens via #cart, no JS needed */
.drawer { position: fixed; inset: 0; z-index: 50; display: none; }
.drawer:target { display: block; }
.drawer-bg { position: absolute; inset: 0; background: rgba(0,0,0,.5); }
.drawer-panel { position: absolute; right: 0; top: 0; bottom: 0; width: min(420px, 100%); background: var(--cream); padding: 20px; overflow-y: auto; display: flex; flex-direction: column; animation: slide .2s ease-out; }
@keyframes slide { from { transform: translateX(40px); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .drawer-panel { animation: none; } }
.drawer-head { display: flex; justify-content: space-between; align-items: center; }
.close { font-size: 1.8rem; text-decoration: none; color: var(--ink); line-height: 1; padding: 4px 8px; }
.line { display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.line img { border-radius: 4px; }
.line form { display: flex; gap: 6px; align-items: center; } .line input { width: 64px; padding: 6px; }
.linkbtn { background: none; border: 0; color: var(--brown); text-decoration: underline; cursor: pointer; font: inherit; font-size: .85rem; padding: 0; }
.totals { margin-top: auto; padding-top: 16px; }
.row { display: flex; justify-content: space-between; gap: 12px; } .row.total { font-weight: 700; font-size: 1.15rem; border-top: 1px solid var(--line); padding-top: 8px; margin-top: 8px; }

/* checkout */
.co { display: grid; grid-template-columns: 1.3fr 1fr; gap: 32px; padding-top: 32px; padding-bottom: 56px; align-items: start; }
@media (max-width: 820px) { .co { grid-template-columns: 1fr; } .co aside { order: -1; } }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; }
.rate { display: flex; gap: 12px; align-items: center; border: 1.5px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; background: #fff; cursor: pointer; }
.rate:has(input:checked) { border-color: var(--brown); }
.rate .p { margin-left: auto; font-weight: 700; }
.steps-mini { display: flex; gap: 8px; font-size: .9rem; color: var(--muted); margin-bottom: 16px; } .steps-mini b { color: var(--brown); }
.status { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .8rem; font-weight: 500; background: #eee; }
.status.paid, .status.active { background: #e3f1e5; color: var(--ok); } .status.shipped, .status.delivered { background: #e5eef8; color: #1e4f86; }
.status.pending, .status.paused { background: #fff3dc; color: #7a4e00; } .status.cancelled, .status.failed { background: #fbe4e1; color: var(--warn); }
.timeline { list-style: none; padding: 0; } .timeline li { padding: 6px 0; border-bottom: 1px dashed var(--line); }

.addr-find { position: relative; }
.suggest { position: absolute; z-index: 5; left: 0; right: 0; top: 76px; margin: 0; padding: 4px 0; list-style: none; background: #fff; border: 1.5px solid #cdb9a3; border-radius: 10px; box-shadow: 0 8px 20px rgba(60, 30, 10, .15); }
.suggest li { padding: 8px 12px; cursor: pointer; font-size: .95rem; }
.suggest li:hover, .suggest li[aria-selected="true"] { background: #f6ecdf; }

/* footer */
.ftr { background: var(--black); color: #cdb9a3; padding: 40px 0 24px; margin-top: 48px; font-size: .9rem; }
.ftr a { color: var(--gold); }
.ftr-in { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 24px; }
.ftr h2 { font-size: 1rem; color: #fff; } .ftr ul { list-style: none; padding: 0; margin: 0; }
@media (max-width: 640px) { .ftr-in { grid-template-columns: 1fr; } }

/* admin */
.adm { background: #f7f3ee; }
.adm .hdr { position: static; }
.adm main { padding: 24px 16px 48px; }
table.t { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: 10px; font-size: .9rem; }
.t th, .t td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.t th { background: #f3ebe1; font-weight: 500; }
.t input { padding: 6px 8px; min-width: 80px; }
.scroll { overflow-x: auto; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin-bottom: 24px; }
.tile { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 14px; } .tile b { display: block; font-size: 1.5rem; }
.warnbox { background: #fbe4e1; border: 1px solid #e8b4ab; border-radius: 10px; padding: 10px 14px; margin: 10px 0; }
.inline { display: inline-flex; gap: 6px; align-items: center; } .inline select, .inline input { width: auto; }
pre.mail { white-space: pre-wrap; background: #fff; border: 1px solid var(--line); padding: 10px; font-size: .8rem; max-height: 240px; overflow: auto; }

/* name tile for products without a photo */
.tile { aspect-ratio: 300 / 472; width: 100%; margin: 0 auto; background: var(--black); color: var(--gold); border-radius: 8px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 12px; text-align: center; font-weight: 700; line-height: 1.25; box-shadow: 0 8px 20px rgba(60, 30, 10, .18); }
.tile img { width: 40%; max-width: 60px; }
.line .tile { font-size: .5rem; padding: 4px; gap: 4px; }
.card-art .tile { max-height: 280px; font-size: 1.05rem; }
.pdp-art .tile { max-height: 520px; font-size: 1.6rem; }
