/* Chasing Flavours, public site. Mobile first: base styles are for phones,
   media queries add layout for larger screens. */

:root {
  --purple: #7f4aa4;
  --purple-dark: #5e3480;
  --purple-tint: #f6f2fa;
  --gold: #f5d73a;
  --gold-dark: #d9b912;
  --ink: #2b2233;
  --muted: #6b5a7a;
  --line: #e7dff0;
  --white: #fff;
  --ok: #217a4a;
  --err: #b42335;
  --radius: 2px; /* corners are kept barely there across the site */
  --shadow: 0 6px 24px rgba(63, 30, 92, .10);
  --font: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --script: "Great Vibes", "Brush Script MT", cursive;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.6; color: var(--ink); background: var(--white);
  min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; -webkit-font-smoothing: antialiased; }
main { flex: 1 0 auto; }
body > * { flex-shrink: 0; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--purple); text-underline-offset: .15em; }
a:hover { color: var(--purple-dark); }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; text-wrap: balance; }
p { text-wrap: pretty; }
p { margin: 0 0 1em; }
.wrap { width: 100%; max-width: 1140px; margin: 0 auto; padding: 0 16px; }
.wrap.narrow { max-width: 720px; }
.script { font-family: var(--script); font-weight: 400; }
.center { text-align: center; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.plain { list-style: none; margin: 0; padding: 0; }
.skip { position: absolute; left: -999px; top: 0; background: var(--gold); padding: 8px 12px; z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--purple); color: var(--white); box-shadow: 0 2px 10px rgba(0,0,0,.12); }
.header-row { display: flex; align-items: center; justify-content: space-between; min-height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--gold); text-decoration: none; font-family: var(--script); font-size: 1.8rem; }
.brand:hover { color: var(--gold); }
.nav-toggle { display: flex; flex-direction: column; gap: 5px; background: none; border: 0; padding: 10px; cursor: pointer; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--white); transition: transform .2s, opacity .2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--purple-dark); padding: 8px 16px 16px; }
.site-nav.open { display: block; }
.site-nav a { display: block; padding: 12px 4px; color: var(--white); text-decoration: none; border-bottom: 1px solid rgba(255,255,255,.12); }
.site-nav a:last-child { border-bottom: 0; }
.site-nav a[aria-current="page"] { color: var(--gold); }
.site-nav .nav-cta { color: var(--gold); font-weight: 600; }
.no-js .site-nav { display: block; position: static; }

@media (min-width: 860px) {
  .nav-toggle { display: none; }
  .site-nav { display: flex; position: static; background: none; padding: 0; gap: 4px; align-items: center; }
  .site-nav a { border: 0; padding: 8px 12px; border-radius: var(--radius); }
  .site-nav a:hover { background: rgba(255,255,255,.12); }
  .site-nav .nav-cta, .site-nav .nav-cta[aria-current="page"] { background: var(--gold); color: var(--ink); margin-left: 8px; }
  .site-nav .nav-cta:hover { background: var(--white); }
}

/* Buttons */
.btn { display: inline-block; background: var(--purple); color: var(--white); border: 2px solid var(--purple); border-radius: var(--radius);
  padding: 12px 24px; font: 600 1rem/1.2 var(--font); text-decoration: none; cursor: pointer; text-align: center;
  transition: background .15s, color .15s, transform .1s; -webkit-appearance: none; appearance: none; }
.btn:hover { background: var(--purple-dark); border-color: var(--purple-dark); color: var(--white); }
.btn:active { transform: translateY(1px); }
.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.btn-gold:hover { background: var(--white); border-color: var(--white); color: var(--ink); }
.btn-outline { background: transparent; color: var(--purple); }
.btn-outline:hover { background: var(--purple); color: var(--white); }
.btn-outline-light { background: transparent; border-color: var(--white); color: var(--white); }
.btn-outline-light:hover { background: var(--white); color: var(--purple); }
.btn-sm { padding: 8px 16px; font-size: .9rem; }
.btn-block { display: block; width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* Hero */
.hero { background: var(--purple); color: var(--white); padding: 32px 0 48px; overflow: hidden; }
.hero-inner { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 16px; }
.hero-logo { width: 200px; border-radius: var(--radius); box-shadow: 0 10px 40px rgba(0,0,0,.25); }
.hero h1 { color: var(--gold); font-size: 2.8rem; line-height: 1.1; margin: 0; }
.hero .lead { font-size: 1.05rem; max-width: 34em; opacity: .95; }
.hero .btn-row { justify-content: center; }
@media (min-width: 860px) {
  .hero { padding: 64px 0 80px; }
  .hero-inner { flex-direction: row; text-align: left; gap: 48px; }
  .hero-logo { width: 300px; }
  .hero h1 { font-size: 4rem; }
  .hero .btn-row { justify-content: flex-start; }
}

.page-head { background: var(--purple); color: var(--white); padding: 28px 0 28px; text-align: center; }
@media (min-width: 860px) { .page-head { padding: 40px 0 36px; } .page-head h1 { font-size: 3.6rem; } }
.page-head h1 { color: var(--gold); font-size: 3rem; line-height: 1.1; margin: 0; }
.page-head p { margin: 4px auto 0; max-width: 40em; }
.page-head a { color: var(--gold); }

/* Sections */
.section { padding: 40px 0; }
@media (min-width: 860px) { .section { padding: 64px 0; } }
.section-tint { background: var(--purple-tint); }
.section-title { text-align: center; font-size: 1.6rem; color: var(--purple-dark); margin-bottom: 24px; }
.section-title.left { text-align: left; margin-top: 0; }
.grid + .section-title { margin-top: 40px; }
.grid + .center, .grid + .pager { margin-top: 28px; margin-bottom: 0; }
.cta-band { background: linear-gradient(135deg, var(--purple), var(--purple-dark)); color: var(--white); }
.cta-band h2 { color: var(--gold); font-size: 2.6rem; }
.empty { text-align: center; color: var(--muted); padding: 32px 0; }

/* Grids and cards */
.grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
.gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 600px) { .product-grid { grid-template-columns: repeat(2, 1fr); } .gallery-grid { grid-template-columns: repeat(3, 1fr); gap: 16px; } }
@media (min-width: 960px) { .product-grid { grid-template-columns: repeat(4, 1fr); } }
.card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.product-card, .photo-card { transition: transform .2s, box-shadow .2s; }
@media (hover: hover) { .product-card:hover, .photo-card:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgba(63, 30, 92, .16); } }
.card-body { padding: 16px; }
.photo-card { margin: 0; }
.photo-card img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; transition: transform .3s; }
.photo-card a { display: block; overflow: hidden; }
.photo-card a:hover img { transform: scale(1.04); }
.photo-card figcaption { padding: 8px 12px 12px; font-weight: 500; font-size: .95rem; }
.photo-card small { display: block; color: var(--muted); font-weight: 400; font-size: .8rem; }
.product-card { display: flex; flex-direction: column; }
.product-card img, .img-placeholder { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.img-placeholder { display: flex; align-items: center; justify-content: center; padding: 16px; text-align: center;
  background: radial-gradient(circle at 30% 20%, #fff 0, var(--purple-tint) 70%); color: var(--purple); font-family: var(--script); font-size: 2.2rem; line-height: 1.1; }
.product-card .card-body { display: flex; flex-direction: column; flex: 1; }
.product-card h3 { font-size: 1.1rem; }
.product-card p { color: var(--muted); font-size: .92rem; }
.card-foot { margin-top: auto; padding-top: 4px; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.price { font-weight: 600; color: var(--purple-dark); }
.price small { display: block; font-weight: 400; color: var(--muted); font-size: .78rem; }

.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; counter-reset: s; }
.steps li { background: var(--white); border-radius: var(--radius); padding: 20px 20px 20px 72px; position: relative; box-shadow: var(--shadow); counter-increment: s; }
.steps li::before { content: counter(s); position: absolute; left: 20px; top: 18px; width: 38px; height: 38px; border-radius: var(--radius);
  background: var(--gold); color: var(--ink); font-weight: 600; display: flex; align-items: center; justify-content: center; }
.steps strong { display: block; color: var(--purple-dark); }
@media (min-width: 760px) { .steps { grid-template-columns: repeat(3, 1fr); } }

/* Our Work: a photo tile per category. On phones two across, and when the
   count is odd the first tile runs full width so no tile sits alone. */
.covers { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 40px; }
.cover { position: relative; display: block; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--radius); background: var(--purple-tint); color: var(--white); text-decoration: none; }
.cover:first-child:nth-last-child(odd) { grid-column: 1 / -1; aspect-ratio: 16 / 9; }
.cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(43, 20, 60, .78), rgba(43, 20, 60, 0) 55%); }
.cover span { position: absolute; left: 12px; right: 12px; bottom: 10px; z-index: 1; font-weight: 600; font-size: 1rem; line-height: 1.25; }
.cover small { display: block; margin-top: 2px; font-weight: 400; font-size: .8rem; color: var(--gold); }
.cover:hover, .cover:focus-visible { color: var(--white); }
.cover:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
@media (hover: hover) { .cover:hover img { transform: scale(1.05); } }
@media (min-width: 760px) {
  .covers { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-bottom: 56px; }
  .cover, .cover:first-child:nth-last-child(odd) { grid-column: auto; aspect-ratio: 1 / 1; }
  .cover span { left: 16px; bottom: 14px; font-size: 1.15rem; }
}
.latest-title { color: var(--purple-dark); }
.pager { display: flex; justify-content: center; gap: 12px; margin-top: 24px; }

/* Forms */
.form fieldset { border: 0; padding: 0; margin: 0 0 28px; }
.form legend { font-weight: 600; font-size: 1.15rem; color: var(--purple-dark); margin-bottom: 12px; padding: 0; }
.field { display: block; margin-bottom: 14px; }
.field > span { display: block; font-weight: 500; font-size: .92rem; margin-bottom: 4px; }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 16px; /* 16px stops iOS zooming in */
  padding: 11px 12px; border: 1px solid #cfc3dc; border-radius: var(--radius); background: var(--white); color: var(--ink);
  -webkit-appearance: none; appearance: none; }
.field select { background-image: linear-gradient(45deg, transparent 50%, var(--purple) 50%), linear-gradient(135deg, var(--purple) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 32px; }
.field input[type=file] { cursor: pointer; }
.field input[type=file]::file-selector-button { font: 600 .9rem/1.2 var(--font); color: var(--purple); background: var(--white); border: 2px solid var(--purple);
  border-radius: var(--radius); padding: 7px 14px; margin-right: 12px; cursor: pointer; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--purple); outline: 0; box-shadow: 0 0 0 3px rgba(127, 74, 164, .2); }
.has-error input, .has-error textarea, .has-error select { border-color: var(--err); }
.field-error { color: var(--err); display: block; font-size: .85rem; margin-top: 4px; }
.row-2 { display: grid; gap: 0 16px; }
@media (min-width: 600px) { .row-2 { grid-template-columns: 1fr 1fr; } }
.radio-row { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-bottom: 14px; }
.radio-row label { display: flex; gap: 8px; align-items: center; cursor: pointer; }
.radio-row input { width: 20px; height: 20px; accent-color: var(--purple); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.order-items { list-style: none; margin: 0 0 16px; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.order-cat { background: var(--purple-tint); padding: 8px 14px; font-weight: 600; font-size: .85rem; color: var(--purple-dark); text-transform: uppercase; letter-spacing: .04em; }
.order-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 14px; border-top: 1px solid var(--line); }
.order-item label { flex: 1; min-width: 0; }
.oi-name { display: block; font-weight: 500; }
.oi-price { display: block; color: var(--muted); font-size: .88rem; }
.stepper { display: flex; align-items: center; flex: none; }
.stepper button { width: 38px; height: 38px; border: 1px solid #cfc3dc; background: var(--white); color: var(--purple); font-size: 1.2rem; cursor: pointer; line-height: 1; }
.stepper button:first-child { border-radius: 2px 0 0 2px; }
.stepper button:last-child { border-radius: 0 2px 2px 0; }
.stepper input { width: 46px; height: 38px; border: 1px solid #cfc3dc; border-left: 0; border-right: 0; text-align: center; font: inherit; font-size: 16px; -moz-appearance: textfield; appearance: textfield; border-radius: 0; }
.stepper input::-webkit-outer-spin-button, .stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.order-item.has-qty { background: #fffbe3; }
.order-total { font-size: 1.05rem; text-align: right; }

.track-form { display: flex; gap: 10px; align-items: flex-end; margin-bottom: 20px; }
.track-form .field { flex: 1; margin: 0; }
.progress { list-style: none; padding: 0; margin: 16px 0 20px; display: flex; justify-content: space-between; position: relative; }
.progress::before { content: ""; position: absolute; left: 10px; right: 10px; top: 10px; height: 3px; background: var(--line); }
.progress li { position: relative; flex: 1; min-width: 0; text-align: center; font-size: .7rem; line-height: 1.25; padding: 30px 2px 0; color: var(--muted); }
@media (min-width: 600px) { .progress li { font-size: .8rem; } }
.progress li::before { content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 22px; height: 22px; border-radius: 50%; background: var(--white); border: 3px solid var(--line); }
.progress li.done::before { background: var(--purple); border-color: var(--purple); }
.progress li.current { color: var(--purple-dark); font-weight: 600; }
.progress li.current::before { background: var(--gold); border-color: var(--purple); }
.line-items li { padding: 8px 0; border-bottom: 1px solid var(--line); }
.line-items li:last-child { border-bottom: 0; }
.track-card .card-body { padding: 20px; }
.track-card h2 { font-size: 1.25rem; color: var(--purple-dark); }

.alert { padding: 12px 16px; border-radius: var(--radius); margin-bottom: 16px; }
.alert-ok { background: #e6f5ec; color: var(--ok); }
.alert-error { background: #fdecee; color: var(--err); }

/* Footer */
.site-footer { background: var(--ink); color: #d9cfe3; padding: 40px 0 88px; margin-top: 0; }
@media (min-width: 860px) { .site-footer { padding-bottom: 24px; } }
.site-footer a { color: var(--gold); text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; }
.site-footer li { padding: 3px 0; }
.site-footer h3 { color: var(--white); font-size: 1rem; }
.footer-grid { display: grid; gap: 24px; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } }
.footer-brand { font-size: 2.4rem; color: var(--gold); margin: 0; }
.copyright { font-size: .8rem; opacity: .6; margin-top: 32px; padding-top: 16px;
  background: linear-gradient(rgba(255,255,255,.1), rgba(255,255,255,.1)) no-repeat 16px 0 / calc(100% - 32px) 1px; }
.wa-float { position: fixed; right: 16px; bottom: 16px; width: 56px; height: 56px; border-radius: 50%; background: #25d366; color: var(--white);
  display: flex; align-items: center; justify-content: center; box-shadow: 0 6px 20px rgba(0,0,0,.25); z-index: 60; }
.wa-float { transition: transform .15s; }
.wa-float:hover { color: var(--white); transform: scale(1.06); }

/* Lightbox */
.lightbox { position: fixed; inset: 0; background: rgba(20, 10, 30, .92); display: flex; flex-direction: column; align-items: center; justify-content: center; z-index: 200; padding: 16px; }
.lightbox img { max-height: 80vh; max-width: 100%; border-radius: var(--radius); }
.lightbox p { color: var(--white); margin-top: 12px; text-align: center; }
.lightbox button { position: absolute; top: 12px; right: 12px; background: none; border: 0; color: var(--white); font-size: 2rem; cursor: pointer; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
