/* Flora prototype – brand tokens from the Figma file, reworked UI:
   1. one primary colour (pink), a flat modern button system
   2. 44px+ tap targets, 48px full-width fields, sticky full-width CTA
   3. explicit selected states (real radios with indicator + fill)
   4. type hierarchy: readable prices, real section headings
   5. calmer product cards, simple details page, neutral stepper
   6. light period picker, labelled progress, order receipt on thanks
   7. consistent colours, hero scrim */
:root {
  --brown-2: #422c00;
  --brown-3: #755e43;
  --brown-6: #e5cdc5;
  --grey-5: #bbbaa6;
  --cream: #fffee8;
  --tonal: #f1ecc8;        /* soft fill for secondary controls */
  --tonal-hover: #e9e2b6;
  --green-7: #d7e49c;
  --orange-5: #f1ab14;
  --orange-tint: #fff1c7;
  --pink-6: #ff5cb0;
  --pink-ink: #420042;
  --info-red: #c8282b;

  --font: "Quicksand", system-ui, sans-serif;
  --font-display: "Calistoga", Georgia, serif;

  --menubar-h: 58px;
  --tap: 44px;
  --btn-h: 52px;
  --field-h: 48px;
  --pad: 20px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--cream);
  color: var(--brown-2);
  font-family: var(--font);
  font-weight: 500;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

img { display: block; }
button { font: inherit; color: inherit; cursor: pointer; }
button:disabled { cursor: default; }
a { color: inherit; text-decoration: none; }
p, h1, h2, h3, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
legend { padding: 0; }
[hidden] { display: none !important; }

:focus-visible { outline: 3px solid var(--pink-6); outline-offset: 2px; }

.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;
}

.app {
  max-width: 480px;
  min-height: 100dvh;
  margin: 0 auto;
  background: var(--cream);
  padding-bottom: calc(var(--menubar-h) + env(safe-area-inset-bottom));
  overflow-x: clip;
}

@media (min-width: 481px) {
  body { background: #efeed6; }
  .app { box-shadow: 0 0 0 1px rgba(66, 44, 0, 0.08); }
}

.screen {
  display: flex;
  flex-direction: column;
  min-height: calc(100dvh - var(--menubar-h) - env(safe-area-inset-bottom));
}

.page-title { font-size: 26px; font-weight: 700; line-height: 1.2; }

/* ---------- Icons recoloured to the text colour (mask over the Figma SVGs) ---------- */
.ico {
  width: 24px;
  height: 24px;
  flex: none;
  background: currentColor;
  -webkit-mask: var(--src) center / contain no-repeat;
  mask: var(--src) center / contain no-repeat;
}
.ico--arrow  { --src: url("assets/icon-arrow-right.svg"); }
.ico--back   { --src: url("assets/icon-arrow-left.svg"); }
/* The menu and basket artwork sit off-centre in their 24px boxes (x 0–18 and x 2–24); nudge to optical centre */
.ico--menu   { --src: url("assets/icon-menu.svg"); transform: translateX(3px); }
.ico--basket { --src: url("assets/icon-basket.svg"); transform: translateX(-1px); }
.ico--minus  { --src: url("assets/icon-minus.svg"); }
.ico--add    { --src: url("assets/icon-plus.svg"); }
.ico--check  {
  --src: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

/* ---------- Top bar ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: var(--tap) 1fr var(--tap);
  align-items: center;
  justify-items: center;
  height: 60px;
  padding: 0 4px;
  background: var(--cream);
  color: var(--brown-2);
}
/* Over the hero photo: brown icons on a cream disc (same treatment as the hearts) */
.topbar--light .icon-btn { position: relative; }
.topbar--light .icon-btn::before {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 50%;
  background: rgba(255, 254, 232, 0.92);
  box-shadow: 0 1px 3px rgba(66, 44, 0, 0.2);
}
.topbar--light .icon-btn > .ico { position: relative; }
.topbar--light .count { z-index: 1; }
.topbar__logo img { width: 62px; height: 39px; }
.icon-btn {
  display: grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  color: inherit;
}

/* ---------- Wave edges ---------- */
.edge { display: block; width: 100%; height: 40.507px; }
.edge--flip { transform: rotate(180deg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: var(--btn-h);
  padding: 0 28px;
  border: 0;
  border-radius: 999px;
  font-size: 17px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.1px;
  white-space: nowrap;
  transition: background-color 0.15s, transform 0.1s, box-shadow 0.15s;
}
.btn:active:not(:disabled) { transform: scale(0.97); }

/* Primary: flat brand pink, soft neutral lift instead of a pink glow */
.btn--primary {
  background: var(--pink-6);
  color: var(--pink-ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), 0 1px 2px rgba(66, 44, 0, 0.12), 0 4px 12px rgba(66, 44, 0, 0.08);
}
.btn--primary:hover:not(:disabled) { background: #ff4aa6; }
.btn--primary:disabled { background: var(--tonal); color: #8f876b; box-shadow: none; }

/* Secondary: tonal fill, no outline */
.btn--secondary {
  height: var(--tap);
  padding: 0 20px;
  background: var(--tonal);
  color: var(--brown-2);
  font-size: 16px;
}
.btn--secondary:hover { background: var(--tonal-hover); }
.btn--secondary .ico { width: 20px; height: 20px; }

.btn--hero { min-width: 240px; }
.btn--block { width: 100%; }

/* Text link with arrow (for "Se alla") */
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: var(--tap);
  padding: 0 8px;
  font-size: 16px;
  font-weight: 700;
}
.text-link .ico { width: 20px; height: 20px; transition: transform 0.15s; }
.text-link:hover .ico { transform: translateX(2px); }

/* Sticky full-width action area, sits just above the menubar */
.actionbar {
  position: sticky;
  bottom: calc(var(--menubar-h) + env(safe-area-inset-bottom));
  z-index: 5;
  margin-top: auto;
  padding: 12px var(--pad) 16px;
  background: var(--bg, var(--cream));
}
.actionbar--green { --bg: var(--green-7); }

/* Segmented control (Buketter / Vaser) */
.tabs {
  display: inline-flex;
  padding: 4px;
  border-radius: 999px;
  background: var(--tonal);
}
.tab {
  min-width: 120px;
  height: var(--tap);
  padding: 0 20px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--brown-3);
  font-size: 16px;
  font-weight: 700;
  transition: background-color 0.15s, color 0.15s, box-shadow 0.15s;
}
.tab[aria-selected="true"] {
  background: var(--orange-5);
  color: var(--brown-2);
  box-shadow: 0 1px 2px rgba(66, 44, 0, 0.15);
}

/* Quantity stepper – tonal circles */
.qty { display: flex; align-items: center; gap: 2px; }
.qty__btn {
  display: grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--tonal);
  color: var(--brown-2);
  transition: background-color 0.15s;
}
.qty__btn:hover:not(:disabled) { background: var(--tonal-hover); }
.qty__btn .ico { width: 20px; height: 20px; }
.qty__btn:disabled { color: #b9b195; }
.qty__value { width: 32px; font-size: 20px; font-weight: 700; text-align: center; }

/* Heart – 44px target, cream disc so it reads on any photo */
.heart {
  position: relative;
  display: grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  padding: 0;
  border: 0;
  background: none;
}
.heart::before {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  background: rgba(255, 254, 232, 0.92);
  box-shadow: 0 1px 3px rgba(66, 44, 0, 0.2);
  transition: background-color 0.15s;
}
.heart img { position: relative; width: 22px; height: 22px; }
.heart[aria-pressed="true"] img { animation: heart-pop 0.3s cubic-bezier(0.2, 1.6, 0.4, 1); }
@keyframes heart-pop { 40% { transform: scale(1.25); } }

/* Sold-out badge */
.badge {
  position: absolute;
  left: 8px;
  bottom: 8px;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 4px 10px 4px 4px;
  border-radius: 999px;
  background: var(--cream);
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 1px 3px rgba(66, 44, 0, 0.2);
}
.badge img { width: 20px; height: 20px; }

/* ---------- Selectable options (real radios) ---------- */
.option {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 68px;
  padding: 12px 18px;
  border: 2px solid transparent;
  border-radius: 16px;
  background: var(--cream);
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s;
}
.option input { position: absolute; opacity: 0; pointer-events: none; }
.option:has(input:checked) { background: var(--orange-tint); border-color: var(--brown-2); }
.option:has(input:focus-visible) { outline: 3px solid var(--pink-6); outline-offset: 2px; }

.radio {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  flex: none;
  border: 2px solid var(--brown-2);
  border-radius: 50%;
  background: #fff;
}
.radio::after {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--brown-2);
  transform: scale(0);
  transition: transform 0.15s;
}
.option input:checked ~ .radio::after { transform: scale(1); }

.option__text { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.option__title { font-size: 17px; font-weight: 700; }
.option__sub { font-size: 14px; font-weight: 500; color: var(--brown-3); }
.option__price { font-size: 17px; font-weight: 700; white-space: nowrap; }
.option__icon { width: 28px; height: 28px; flex: none; }

/* ---------- Home ---------- */
.hero { position: relative; height: 370px; }
.hero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* Scrim: darkens the top for the logo/icons and the middle for the headline */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom, rgba(40, 24, 0, 0.55) 0%, rgba(40, 24, 0, 0) 28%),
    linear-gradient(to bottom, rgba(40, 24, 0, 0) 25%, rgba(40, 24, 0, 0.28) 50%, rgba(40, 24, 0, 0.05) 85%);
}
.hero__layer {
  position: absolute;
  inset: 0 0 40px; /* stop above the wave edge */
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}
.hero__title { margin-top: auto; }
.hero__layer > .btn { margin-bottom: auto; }
.hero__layer .topbar { position: static; background: transparent; width: 100%; }
.hero__title {
  max-width: 100%;
  padding: 0 var(--pad);
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(40px, 13vw, 54px);
  line-height: 1.08;
  letter-spacing: 0.5px;
  color: var(--cream);
  text-align: center;
  text-wrap: balance;
  text-shadow: 0 2px 12px rgba(40, 24, 0, 0.35);
}
.hero .edge { position: absolute; left: 0; right: 0; bottom: 0; }

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px 0 var(--pad);
}
.section-head { gap: 8px; }
.section-head h2 { font-size: clamp(19px, 6vw, 22px); font-weight: 700; line-height: 1.2; white-space: nowrap; }
.section-head .text-link { flex: none; white-space: nowrap; }

.preview { display: flex; flex-direction: column; gap: 12px; padding: 8px 0 28px; }
.preview__row {
  display: flex;
  gap: 12px;
  padding: 4px var(--pad);
  overflow-x: auto;
  scroll-snap-type: x proximity;
  scroll-padding-inline: var(--pad);
  scrollbar-width: none;
}
.preview__row::-webkit-scrollbar { display: none; }
.preview__item { flex: none; width: 112px; display: flex; flex-direction: column; gap: 4px; scroll-snap-align: start; }
.preview__item img { width: 100px; height: 100px; margin-bottom: 8px; border-radius: 50%; object-fit: cover; }
.preview__name { font-size: 15px; font-weight: 700; line-height: 1.2; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.preview__price { font-size: 14px; font-weight: 600; line-height: 1.2; }

.info__body { background: var(--green-7); padding: 20px 0; margin: -1px 0; }
.info__list { display: flex; flex-direction: column; gap: 28px; padding: 0 25px; }
.info__row { display: flex; gap: 15px; align-items: flex-start; }
.info__row img { width: 42px; height: 42px; flex: none; }
.info__text { display: flex; flex-direction: column; gap: 8px; max-width: 260px; }
.info__text h3 { font-size: 17px; font-weight: 700; line-height: 1.4; }
.info__text p { font-size: 15px; font-weight: 500; line-height: 1.6; color: var(--brown-2); }

.cta { display: flex; justify-content: center; padding: 26px 0; }

/* ---------- Product list ---------- */
.products { display: flex; flex-direction: column; align-items: center; gap: 24px; padding: 8px 0 28px; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 16px; width: 100%; padding: 0 var(--pad); }
.card { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.card__pic { position: relative; aspect-ratio: 140 / 165; }
.card__pic > a { position: absolute; inset: 0; }
.card__pic > a img { width: 100%; height: 100%; border-radius: 20px; object-fit: cover; }
.card__pic .heart { position: absolute; top: 4px; right: 4px; }
.card--soldout .card__pic > a img { filter: grayscale(0.6); opacity: 0.55; }
.card__info { display: flex; flex-direction: column; gap: 4px; padding: 0 4px; }
.card__name { font-size: 16px; font-weight: 700; line-height: 1.25; }
.card__price { font-size: 16px; font-weight: 600; line-height: 1.25; }
.card--soldout .card__info { color: var(--brown-3); }
.empty { padding: 40px 30px; text-align: center; font-weight: 600; color: var(--brown-3); }

/* ---------- Product details ---------- */
.detail { display: flex; flex-direction: column; gap: 20px; padding: 8px var(--pad) 8px; }
.detail__pic { position: relative; aspect-ratio: 4 / 5; max-height: 440px; width: 100%; }
.detail__pic > img { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 24px; object-fit: cover; }
.detail__pic .heart { position: absolute; top: 10px; right: 10px; }
.detail__pic .badge { left: 12px; bottom: 12px; }
.detail__pic--soldout > img { filter: grayscale(0.6); opacity: 0.55; }
.detail__body { display: flex; flex-direction: column; gap: 14px; }
.detail__head { display: flex; flex-direction: column; gap: 6px; }
.detail__name { font-size: 28px; font-weight: 700; line-height: 1.15; }
.detail__price { font-size: 20px; font-weight: 700; }
.detail__price span { font-size: 15px; font-weight: 500; color: var(--brown-3); }
.detail__desc { font-size: 15px; font-weight: 500; line-height: 1.6; }
.detail__actions {
  position: sticky;
  bottom: calc(var(--menubar-h) + env(safe-area-inset-bottom));
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: auto;
  padding: 12px var(--pad) 16px;
  background: var(--cream);
}
.detail__actions .btn { flex: 1; padding: 0 16px; }

/* ---------- Basket ---------- */
.basket { flex: 1; display: flex; flex-direction: column; gap: 28px; padding-top: 8px; }
.basket > .page-title, .basket__items, .basket__total, .basket__empty { margin: 0 var(--pad); }
.basket__summary { display: flex; flex-direction: column; gap: 16px; }
.basket__items { display: flex; flex-direction: column; gap: 12px; }
/* Basket item card: the interval picker belongs to the bouquet */
.bitem { display: flex; flex-direction: column; gap: 14px; padding: 14px; border-radius: 20px; background: var(--tonal); }
.bitem__top { display: flex; align-items: center; gap: 14px; }
.bitem__top > img { width: 72px; height: 72px; flex: none; border-radius: 50%; object-fit: cover; }
.bitem__col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.bitem__row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.bitem__name { font-size: 17px; font-weight: 700; }
.bitem__price { font-size: 16px; font-weight: 600; white-space: nowrap; }
.bitem .qty__btn { background: var(--cream); }
.bitem .qty__btn:hover:not(:disabled) { background: #fff; }
.bitem__period { display: flex; flex-direction: column; gap: 6px; }
.bitem__label { font-size: 14px; font-weight: 700; color: var(--brown-3); }
.basket__total { padding-top: 4px; }
.basket__total div { display: flex; justify-content: space-between; align-items: baseline; font-size: 16px; font-weight: 600; }
.basket__total div span:last-child { font-size: 20px; font-weight: 700; }
.basket__total p { margin-top: 4px; font-size: 14px; color: var(--brown-3); }
.basket__empty { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; font-size: 16px; font-weight: 600; }

/* ---------- Checkout (shared) ---------- */
.checkout { flex: 1; display: flex; flex-direction: column; gap: 32px; padding-top: 12px; }
.checkout > form, .checkout > .panel-wrap { flex: 1; display: flex; flex-direction: column; }
.steps-head { display: flex; flex-direction: column; align-items: center; gap: 16px; }
.steps-head h1 { font-size: 24px; font-weight: 700; line-height: 1.25; text-align: center; }

/* Progress: done ✓ / current / upcoming, with labels */
.steps { display: grid; grid-template-columns: repeat(3, 92px); }
.step { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; }
/* Connector runs between the dots (not through them), with an 8px gap each side */
.step + .step::before {
  content: "";
  position: absolute;
  top: 11px;
  left: calc(-50% + 20px);
  right: calc(50% + 20px);
  height: 2px;
  border-radius: 1px;
  background: var(--brown-6);
}
.step--done + .step::before, .step--done + .step--current::before { background: var(--brown-2); }
.step__dot {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--brown-6);
  font-size: 13px;
  font-weight: 700;
}
.step__dot .ico { width: 14px; height: 14px; }
.step--done .step__dot { background: var(--brown-2); color: var(--cream); }
.step--current .step__dot { background: var(--orange-5); box-shadow: 0 0 0 4px rgba(241, 171, 20, 0.3); }
.step__label { font-size: 13px; font-weight: 600; color: var(--brown-3); }
.step--current .step__label { font-weight: 700; color: var(--brown-2); }

.panel { flex: 1; display: flex; flex-direction: column; background: var(--green-7); margin-top: -1px; }

/* Full-width fields, two-up only where values are short */
.form { display: flex; flex-direction: column; gap: 18px; padding: 8px var(--pad); }
.form__pair { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label { font-size: 16px; font-weight: 600; line-height: 1.2; }
.field input {
  width: 100%;
  height: var(--field-h);
  padding: 0 14px;
  border: 1.5px solid var(--brown-2);
  border-radius: 12px;
  background: #fff;
  font: 500 16px/1 var(--font); /* 16px stops iOS zooming on focus */
  color: var(--brown-2);
}
.field input:focus { outline: 3px solid var(--orange-5); outline-offset: 0; }
.field input:user-invalid { border-color: var(--info-red); border-width: 2px; }
.field small { font-size: 13px; font-weight: 600; line-height: 1.3; color: var(--brown-3); }

.options { display: flex; flex-direction: column; gap: 12px; padding: 8px var(--pad); }
.card-form { padding-top: 16px; }

/* ---------- Thanks ---------- */
.thanks { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 28px; padding-top: 12px; }
.thanks h1 { font-size: 32px; font-weight: 700; line-height: 1.25; text-align: center; }
.thanks__panel { width: 100%; flex: 1; display: flex; flex-direction: column; }
.thanks__body {
  flex: 1;
  background: var(--green-7);
  margin-top: -1px;
  padding: 16px var(--pad) 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}
.thanks__body > p { font-size: 22px; font-weight: 700; line-height: 1.3; text-align: center; }
.flower-check { position: relative; width: 130px; height: 165.8px; }
.flower-check__flowers {
  position: absolute;
  inset: 0 0 21.6% 0;
  background: var(--orange-5);
  -webkit-mask: url("assets/flowers-mask.png") no-repeat 0 0 / 130px 130px;
  mask: url("assets/flowers-mask.png") no-repeat 0 0 / 130px 130px;
}
.flower-check > img { position: absolute; top: 45.06%; left: 15.52%; width: 89.6px; height: 89.6px; }

.receipt {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 16px;
  border-radius: 20px;
  background: var(--cream);
}
.receipt__highlight {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--orange-tint);
}
.receipt__highlight span { font-size: 14px; font-weight: 600; color: var(--brown-3); }
.receipt__highlight strong { font-size: 19px; font-weight: 700; }
.receipt__highlight strong::first-letter { text-transform: uppercase; }
.receipt dl { display: flex; flex-direction: column; gap: 8px; }
.receipt dl div { display: flex; justify-content: space-between; gap: 12px; font-size: 15px; font-weight: 600; }
.receipt dd { white-space: nowrap; }
.receipt__total { padding-top: 10px; border-top: 1px solid rgba(66, 44, 0, 0.15); font-size: 17px !important; font-weight: 700 !important; }
.receipt__meta div { font-size: 14px !important; font-weight: 500 !important; color: var(--brown-3); }
.receipt__meta dd { font-weight: 700; color: var(--brown-2); }

/* ---------- Menubar ---------- */
.menubar {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  width: 100%;
  max-width: 480px;
  height: calc(var(--menubar-h) + env(safe-area-inset-bottom));
  padding: 4px 10px env(safe-area-inset-bottom);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  background: var(--cream);
  border-top: 1px solid var(--grey-5);
}
.menubar__item {
  width: 115px;
  min-height: 50px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
}
.menubar__item img { width: 26px; height: 26px; }

@media (prefers-reduced-motion: no-preference) {
  #view > .screen { animation: fade 0.2s ease-out; }
  @keyframes fade { from { opacity: 0; transform: translateY(4px); } }
}

/* =====================================================================
   Additions: basket count, notices, profile, subscriptions, dialogs,
   hamburger drawer and the simulated payment apps
   ===================================================================== */
body.is-locked { overflow: hidden; }

/* Basket count on the top-bar icon */
.icon-btn--badge { position: relative; }
.count {
  position: absolute;
  top: 4px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--brown-2);
  color: var(--cream);
  font-size: 11px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
}
.count--inline { position: static; display: inline-block; margin-left: 8px; vertical-align: 2px; }

/* Current section in the bottom menubar */
.menubar__item { position: relative; color: var(--brown-3); }
.menubar__item img { opacity: 0.7; }
.menubar__item[aria-current="page"] { color: var(--brown-2); font-weight: 700; }
.menubar__item[aria-current="page"] img { opacity: 1; }
.menubar__item[aria-current="page"]::before {
  content: "";
  position: absolute;
  top: -5px;
  width: 32px;
  height: 3px;
  border-radius: 0 0 3px 3px;
  background: var(--orange-5);
}

.btn--sm { height: var(--tap); padding: 0 18px; font-size: 15px; }
.btn--danger { height: var(--tap); background: #fbe1df; color: #8f1d20; font-size: 16px; }
.btn--danger:hover { background: #f7d2cf; }

.demo-note {
  margin: 16px var(--pad) 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255, 254, 232, 0.6);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--brown-3);
}

.thanks__actions { width: 100%; display: flex; flex-direction: column; gap: 10px; }

/* ---------- Profile ---------- */
.profile { display: flex; flex-direction: column; gap: 28px; padding: 8px var(--pad) 32px; }
.profile__head { display: flex; align-items: center; gap: 14px; }
.profile__head h1 { font-size: 26px; font-weight: 700; line-height: 1.2; }
.profile__head p { font-size: 14px; color: var(--brown-3); }
.avatar {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  flex: none;
  border-radius: 50%;
  background: var(--orange-5);
  font-size: 20px;
  font-weight: 700;
}
.profile__section { display: flex; flex-direction: column; gap: 12px; scroll-margin-top: 72px; }
.profile__section h2 { font-size: 20px; font-weight: 700; }
.profile__section-head { display: flex; align-items: center; justify-content: space-between; }
.profile__empty {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 20px;
  border-radius: 20px;
  background: var(--tonal);
  font-size: 15px;
  line-height: 1.5;
}
.profile__info, .sub__rows { display: flex; flex-direction: column; }
.profile__info { padding: 4px 16px; border-radius: 16px; background: var(--tonal); }
.profile__info div, .sub__rows div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  font-size: 15px;
}
.profile__info div + div, .sub__rows div + div { border-top: 1px solid rgba(66, 44, 0, 0.1); }
.profile__info dt, .sub__rows dt { color: var(--brown-3); font-weight: 500; }
.profile__info dd, .sub__rows dd { font-weight: 700; text-align: right; }
.sub__rows dd::first-letter { text-transform: uppercase; }

.profile__form { display: flex; flex-direction: column; gap: 16px; padding: 16px; border-radius: 16px; background: var(--green-7); }
.form--flush { padding: 0; }
.profile__form-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.profile__form-actions .btn { height: var(--btn-h); }

/* Subscription card */
.sub {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px;
  border-radius: 20px;
  background: var(--green-7);
}
.sub__head { display: flex; align-items: center; gap: 12px; margin-bottom: 4px; }
.sub__thumbs { display: flex; flex: none; }
.sub__thumbs img { width: 44px; height: 44px; border: 2px solid var(--green-7); border-radius: 50%; object-fit: cover; }
.sub__thumbs img + img { margin-left: -16px; }
.sub__title { flex: 1; min-width: 0; }
.sub__title h3 { font-size: 16px; font-weight: 700; line-height: 1.3; }
.sub__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-top: 4px; font-size: 13px; font-weight: 600; color: var(--brown-3); }
/* Interval tag, styled like the selected interval in the basket */
.interval {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--orange-5);
  color: var(--brown-2);
  font-size: 13px;
  font-weight: 700;
}
.sub__rows div + div { border-top-color: rgba(66, 44, 0, 0.12); }
.sub__note { margin: 4px 0 8px; font-size: 13px; color: var(--brown-3); line-height: 1.4; }

.status {
  flex: none;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}
.status--active { background: var(--cream); color: #2c6a10; }
.status--active::before { content: "● "; color: #3a9a12; }
.status--ending { background: var(--orange-tint); color: var(--brown-2); }
.status--ended { background: var(--tonal); color: var(--brown-3); }

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--menubar-h) + env(safe-area-inset-bottom) + 84px);
  z-index: 200;
  transform: translateX(-50%);
  padding: 12px 18px;
  border-radius: 999px;
  background: var(--brown-2);
  color: var(--cream);
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: 0 6px 20px rgba(40, 24, 0, 0.25);
  animation: toast-in 0.2s ease-out;
  transition: opacity 0.3s;
}
.toast--out { opacity: 0; }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 8px); } }

/* ---------- Confirm sheet (native dialog) ---------- */
.sheet {
  width: min(480px, 100%);
  max-width: 100%;
  margin: auto auto 0;
  padding: 24px var(--pad) calc(20px + env(safe-area-inset-bottom));
  border: 0;
  border-radius: 24px 24px 0 0;
  background: var(--cream);
  color: var(--brown-2);
  font-family: var(--font);
  animation: sheet-in 0.22s ease-out;
}
.sheet::backdrop { background: rgba(40, 24, 0, 0.45); }
.sheet h2 { font-size: 21px; font-weight: 700; margin-bottom: 8px; }
.sheet p { font-size: 15px; line-height: 1.5; color: var(--brown-3); margin-bottom: 20px; }
.sheet p::first-letter { text-transform: none; }
.sheet__actions { display: flex; flex-direction: column; gap: 10px; }
.sheet__actions .btn { height: var(--btn-h); }
@keyframes sheet-in { from { transform: translateY(100%); } }

/* ---------- Hamburger drawer ---------- */
.drawer { position: fixed; inset: 0; z-index: 60; display: flex; justify-content: center; pointer-events: none; }
.drawer--open { pointer-events: auto; }
.drawer__frame { position: relative; width: 100%; max-width: 480px; overflow: hidden; }
.drawer__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(40, 24, 0, 0.45);
  opacity: 0;
  transition: opacity 0.2s;
}
.drawer__panel {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: min(84%, 340px);
  display: flex;
  flex-direction: column;
  padding: 8px 12px calc(16px + env(safe-area-inset-bottom));
  background: var(--cream);
  box-shadow: 8px 0 32px rgba(40, 24, 0, 0.2);
  transform: translateX(-100%);
  transition: transform 0.22s ease-out;
}
.drawer--open .drawer__backdrop { opacity: 1; }
.drawer--open .drawer__panel { transform: none; }
.drawer__head { display: flex; align-items: center; justify-content: space-between; height: 60px; padding: 0 4px 0 8px; }
.drawer__list { display: flex; flex-direction: column; padding: 8px 0; }
.drawer__list + .drawer__list { border-top: 1px solid rgba(66, 44, 0, 0.12); }
.drawer__list a {
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 0 12px;
  border-radius: 12px;
  font-size: 19px;
  font-weight: 700;
}
.drawer__list a:hover { background: var(--tonal); }
.drawer__list--secondary a { font-size: 17px; font-weight: 600; }
.drawer__foot { margin-top: auto; padding: 0 12px; font-size: 13px; color: var(--brown-3); }

/* ---------- Simulated payment apps (generic, clearly labelled demo) ---------- */
.sim {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  justify-content: center;
  background: rgba(40, 24, 0, 0.55);
}
.sim__screen {
  position: relative;
  width: 100%;
  max-width: 480px;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  padding: 16px var(--pad) calc(24px + env(safe-area-inset-bottom));
  font-family: var(--font);
}
.sim--center { align-items: center; justify-content: center; gap: 12px; text-align: center; }
.sim__body.sim--center { flex: 1; }
.sim--slide { animation: app-in 0.32s cubic-bezier(0.2, 0.8, 0.2, 1); }
@keyframes app-in { from { transform: translateY(24px) scale(0.96); opacity: 0; } }

.sim--flora { background: var(--cream); color: var(--brown-2); }
.sim--payapp { background: #ffffff; color: #1d1d1f; }
.sim--bank { background: #f4f5f7; color: #1d2433; }
.sim--idapp { background: #20242c; color: #f2f3f5; }

.sim__screen h2 { font-size: 24px; font-weight: 700; line-height: 1.25; outline: none; }
.sim__screen p { font-size: 15px; line-height: 1.5; opacity: 0.8; }

.sim__demo {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(127, 127, 127, 0.16);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  white-space: nowrap;
}
.sim--center > .sim__demo { position: absolute; top: 16px; }

.sim__apphead { display: flex; align-items: center; gap: 10px; height: 52px; font-size: 17px; font-weight: 700; white-space: nowrap; }
.sim__apphead .sim__demo { margin-left: auto; }

.sim__appicon {
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border-radius: 20px;
  background: var(--brown-2);
  color: var(--cream);
}
.sim__appicon svg { width: 55%; height: 55%; }
.sim__appicon--sm { width: 32px; height: 32px; border-radius: 9px; }
.sim--payapp .sim__appicon { background: #2b3a4a; color: #fff; }
.sim--bank .sim__appicon { background: #3c4a63; color: #fff; }
.sim--idapp .sim__appicon { background: #f2f3f5; color: #20242c; }
.sim__appicon--lg { width: 88px; height: 88px; border-radius: 26px; margin-bottom: 8px; }
.sim__appicon--pulse { animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(1.08); } }

.sim__body { display: flex; flex-direction: column; gap: 16px; padding-top: 24px; }
.sim__recipient { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: 14px; background: #f2f3f5; }
.sim__recipient div { display: flex; flex-direction: column; }
.sim__recipient span:not(.sim__avatar) { font-size: 14px; opacity: 0.7; }
.sim__avatar {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--pink-6);
  color: var(--pink-ink);
  font-weight: 700;
}
.sim__amount { font-size: 44px !important; font-weight: 700; opacity: 1 !important; text-align: center; padding: 16px 0 0; }
.sim__message { text-align: center; }

.sim__details { display: flex; flex-direction: column; padding: 4px 16px; border-radius: 14px; background: #fff; }
.sim__details div { display: flex; justify-content: space-between; padding: 12px 0; font-size: 15px; }
.sim__details div + div { border-top: 1px solid #e3e5ea; }
.sim__details dt { opacity: 0.7; }
.sim__details dd { font-weight: 700; }

.sim__actions { margin-top: auto; display: flex; flex-direction: column; gap: 8px; }
.sim__btn {
  height: 52px;
  border: 0;
  border-radius: 14px;
  font-size: 17px;
  font-weight: 700;
}
.sim__btn--text { background: transparent; }
.sim--payapp .sim__btn--primary { background: #2b3a4a; color: #fff; }
.sim--bank .sim__btn--primary { background: #3c4a63; color: #fff; }
.sim--idapp .sim__btn--primary { background: #f2f3f5; color: #20242c; }
.sim--idapp .sim__btn--text { color: #f2f3f5; }

.sim__spinner {
  width: 48px;
  height: 48px;
  border: 4px solid rgba(66, 44, 0, 0.15);
  border-top-color: var(--brown-2);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
.sim__spinner--light { border-color: rgba(255, 255, 255, 0.2); border-top-color: #fff; }
@keyframes spin { to { transform: rotate(360deg); } }

.sim__result { display: grid; place-items: center; width: 80px; height: 80px; border-radius: 50%; }
.sim__result svg { width: 44px; height: 44px; }
.sim__result--ok { background: var(--green-7); color: #2c6a10; animation: pop 0.35s cubic-bezier(0.2, 1.4, 0.4, 1); }
.sim__result--cancel { background: #fbe1df; color: #8f1d20; }
.sim--flora .btn { margin-top: 16px; }
@keyframes pop { from { transform: scale(0.4); } }

@media (prefers-reduced-motion: reduce) {
  .heart img,
  .sim--slide, .sim__appicon--pulse, .sim__result--ok, .sheet, .toast { animation: none; }
  .drawer__panel, .drawer__backdrop { transition: none; }
}

/* ---------- Favourites (profile) ---------- */
.favs { display: flex; flex-direction: column; padding: 4px 8px 4px 16px; border-radius: 16px; background: var(--tonal); }
.fav { display: flex; align-items: center; gap: 8px; }
.fav + .fav { border-top: 1px solid rgba(66, 44, 0, 0.1); }
.fav__link { flex: 1; min-width: 0; display: flex; align-items: center; gap: 14px; padding: 10px 0; }
.fav__link img { width: 52px; height: 52px; flex: none; border-radius: 50%; object-fit: cover; }
.fav--soldout .fav__link img { filter: grayscale(0.6); opacity: 0.55; }
.fav__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.fav__name { font-size: 16px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fav__price { font-size: 14px; font-weight: 600; color: var(--brown-3); }
.fav .heart::before { background: transparent; box-shadow: none; }

/* ---------- Different interval per bouquet ---------- */
/* Compact segmented radio group */
.seg { display: grid; grid-template-columns: repeat(3, 1fr); padding: 3px; border-radius: 999px; background: var(--cream); }
.seg label { position: relative; cursor: pointer; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg span {
  display: grid;
  place-items: center;
  height: var(--tap);
  border-radius: 999px;
  font-size: 15px;
  font-weight: 700;
  color: var(--brown-3);
  transition: background-color 0.15s, color 0.15s;
}
.seg input:checked + span { background: var(--orange-5); color: var(--brown-2); box-shadow: 0 1px 2px rgba(66, 44, 0, 0.15); }
.seg input:focus-visible + span { outline: 3px solid var(--pink-6); outline-offset: 1px; }

.basket__total--split { display: flex; flex-direction: column; gap: 6px; }
.basket__total--split div span:last-child { font-size: 18px; }

.receipt__rows + .receipt__rows { padding-top: 12px; border-top: 1px dashed rgba(66, 44, 0, 0.2); }
.receipt__group dt { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.4px; color: var(--brown-3); }
