/* ==========================================================================
   Design tokens.

   The palette comes from the shop itself rather than a generic accent set:
   the deep rose of a peony head, the grey-green of eucalyptus stems, the
   brass of florist's scissors, and the faintly warm white of tissue wrap.
   Named for what they are, so a future edit knows what it is changing.
   ========================================================================== */
:root {
    --ink: #1E1A1B;          /* near-black with a plum cast — all text */
    --tissue: #FAF7F5;       /* wrapping tissue — page background */
    --peony: #B23A5B;        /* deep rose — primary accent, CTAs */
    --peony-dark: #8E2A46;
    --eucalyptus: #2E5E4E;   /* stem green — secondary, success */
    --eucalyptus-dark: #1F4438;
    --brass: #A6803F;        /* florist's scissors — points, highlights */
    --blush: #F4E6E8;        /* card fills, quiet surfaces */
    --sage: #E4EAE3;         /* alternate quiet surface */
    --warn: #9A6114;
    --danger: #A32020;
    --line: rgba(30, 26, 27, 0.14);
    --shadow: 0 2px 10px rgba(30, 26, 27, 0.07);
    --shadow-lift: 0 12px 28px rgba(30, 26, 27, 0.13);

    /* Bodoni's high contrast reads as a flower counter rather than a cafe;
       Karla's slightly odd grotesque letterforms keep the UI from feeling
       like a default system stack. */
    --font-display: 'Bodoni Moda', 'Playfair Display', Georgia, serif;
    --font-body: 'Karla', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

    /* Rotating accents for catalogue sections — three, matching the three
       sections, so each one keeps its own colour rather than cycling. */
    --sec-0: #B23A5B;
    --sec-1: #2E5E4E;
    --sec-2: #A6803F;

    --radius: 4px;      /* nearly square: paper, not bubbles */
    --radius-pill: 999px;
    --cut: 18px;        /* size of the folded-corner cut on cards */
    --container: 1140px;
}

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

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    margin: 0;
    background: var(--tissue);
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.01em;
    margin: 0 0 0.4em;
}

p { margin: 0 0 1em; }

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

/* Visible keyboard focus everywhere. */
a:focus-visible, button:focus-visible, input:focus-visible,
select:focus-visible, textarea:focus-visible, summary:focus-visible {
    outline: 3px solid var(--peony);
    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;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 22px;
    border-radius: var(--radius-pill);
    border: 1.5px solid transparent;
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 0.92rem;
    letter-spacing: 0.01em;
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.14s ease, background-color 0.14s ease, color 0.14s ease;
    white-space: nowrap;
}
.btn:active { transform: scale(0.975); }
.btn--primary { background: var(--peony); color: #fff; }
.btn--primary:hover { background: var(--peony-dark); }
.btn--secondary { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn--secondary:hover { background: var(--ink); color: var(--tissue); }
.btn--green { background: var(--eucalyptus); color: #fff; }
.btn--green:hover { background: var(--eucalyptus-dark); }
.btn--ghost { background: transparent; color: var(--ink); padding: 8px 12px; font-weight: 600; }
.btn--ghost:hover { background: var(--blush); }
.btn--danger { background: var(--danger); color: #fff; }
.btn--danger:hover { background: #7d1818; }
.btn--sm { padding: 7px 14px; font-size: 0.82rem; }
.btn--block { width: 100%; }
.btn[disabled] { opacity: 0.45; cursor: not-allowed; }

/* ==========================================================================
   Header
   ========================================================================== */
.site-nav {
    background: var(--tissue);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 40;
}
.site-nav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
    gap: 14px;
}
.site-nav__brand {
    font-family: var(--font-display);
    font-size: 1.45rem;
    font-weight: 600;
    letter-spacing: -0.015em;
    text-decoration: none;
    color: var(--ink);
    line-height: 1.05;
}
.site-nav__links {
    display: flex;
    align-items: center;
    gap: 4px;
    list-style: none;
    margin: 0;
    padding: 0;
}
.site-nav__link {
    text-decoration: none;
    color: var(--ink);
    font-weight: 600;
    padding: 8px 12px;
    border-radius: var(--radius-pill);
    font-size: 0.92rem;
}
.site-nav__link:hover { background: var(--blush); }
.cart-badge {
    background: var(--peony);
    color: #fff;
    border-radius: var(--radius-pill);
    font-size: 0.68rem;
    font-weight: 700;
    padding: 1px 7px;
    margin-left: 4px;
}

/* Language switcher — three short codes, always visible. Hiding it in a
   menu would make it invisible to the people who most need it. */
.lang-switch { display: flex; gap: 2px; align-items: center; }
.lang-switch__link {
    text-decoration: none;
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    padding: 5px 8px;
    border-radius: var(--radius);
    color: rgba(30, 26, 27, 0.5);
}
.lang-switch__link:hover { background: var(--blush); color: var(--ink); }
.lang-switch__link--active { background: var(--ink); color: var(--tissue); }

/* ==========================================================================
   Status banners
   ========================================================================== */
.status-banner {
    padding: 12px 18px;
    font-size: 0.9rem;
    font-weight: 600;
    text-align: center;
}
.status-banner--pending { background: #F7ECD8; color: #6E4708; }
.status-banner--suspended { background: #F6E2D6; color: #7B3B12; }
.status-banner--blacklisted { background: #F5DCDC; color: #6E1616; }

/* ==========================================================================
   Hero
   ========================================================================== */
.hero { padding: 56px 0 34px; }
.hero__eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--peony);
    margin-bottom: 12px;
}
.hero__title {
    font-size: clamp(2.2rem, 6.5vw, 4rem);
    max-width: 16ch;
    margin-bottom: 0.25em;
}
.hero__subtitle {
    font-size: 1rem;
    color: rgba(30, 26, 27, 0.68);
    max-width: 52ch;
    margin: 0;
}
.hero__note { display: block; margin-top: 6px; font-size: 0.9rem; color: var(--peony); }

/* ==========================================================================
   Signature element: the stem divider.

   A hairline that swells into a small leaf at its centre — the mark a
   florist's stem makes on a page. Used once between sections so it reads as
   structure ("a new section starts here"), not decoration.
   ========================================================================== */
.stem-divider {
    position: relative;
    height: 1px;
    background: var(--line);
    margin: 44px 0 0;
}
.stem-divider::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: 22px;
    height: 22px;
    transform: translate(-50%, -50%) rotate(45deg);
    background: var(--tissue);
    border: 1.5px solid var(--divider-color, var(--peony));
    /* A leaf: round on two opposite corners, pointed on the other two. */
    border-radius: 0 60% 0 60%;
}

/* ==========================================================================
   Catalogue
   ========================================================================== */
.section-nav {
    position: sticky;
    top: 57px;
    z-index: 30;
    background: rgba(250, 247, 245, 0.97);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--line);
}
.section-nav__inner {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding: 9px 18px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}
.section-nav__inner::-webkit-scrollbar { height: 3px; }
.section-nav__inner::-webkit-scrollbar-thumb { background: var(--line); }
.section-nav__link {
    flex: 0 0 auto;
    text-decoration: none;
    color: var(--ink);
    font-size: 0.83rem;
    font-weight: 700;
    padding: 6px 13px;
    border-radius: var(--radius-pill);
    background: var(--blush);
    white-space: nowrap;
}
.section-nav__link:hover { background: var(--ink); color: var(--tissue); }
.section-nav__link--active { background: var(--peony); color: #fff; }

.catalogue-section { padding: 36px 0 4px; }
.catalogue-section__header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}
.catalogue-section__title {
    font-size: clamp(1.7rem, 4.5vw, 2.5rem);
    color: var(--section-color, var(--ink));
    margin: 0;
}
.catalogue-section__count {
    font-size: 0.82rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-weight: 700;
    color: rgba(30, 26, 27, 0.45);
}

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

/* The folded corner is the card's one flourish: a diagonal cut at the top
   right, the way a sheet of wrapping paper is folded back over a stem. */
.product-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.16s ease, box-shadow 0.16s ease;
    clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, 0 100%);
}
.product-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lift); }

.product-card__image {
    aspect-ratio: 4 / 3;
    background: var(--sage);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(46, 94, 78, 0.5);
    font-family: var(--font-display);
    font-size: 0.9rem;
    text-align: center;
    padding: 8px;
    overflow: hidden;
}
.product-card__image img { width: 100%; height: 100%; object-fit: cover; }

.product-card__body {
    padding: 14px 16px 16px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    flex: 1;
}
.product-card__name {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
}
.product-card__desc {
    font-size: 0.85rem;
    color: rgba(30, 26, 27, 0.6);
    margin: 0;
    flex: 1;
}
.product-card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 10px;
}
.product-card__price {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--peony);
    white-space: nowrap;
}

.stepper {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--blush);
    border-radius: var(--radius-pill);
    padding: 3px 5px;
}
.stepper button {
    width: 28px; height: 28px;
    border-radius: 50%;
    border: none;
    background: #fff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    color: var(--ink);
    line-height: 1;
}
.stepper button:hover { background: var(--peony); color: #fff; }
.stepper__value { min-width: 16px; text-align: center; font-weight: 700; font-size: 0.88rem; }

/* ==========================================================================
   Shop picker
   ========================================================================== */
.shop-bar { background: var(--sage); border-bottom: 1px solid var(--line); }
.shop-bar__inner {
    display: flex; align-items: center; justify-content: space-between;
    gap: 12px; padding: 11px 18px; flex-wrap: wrap;
}
.shop-bar__label {
    font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.12em;
    color: rgba(30, 26, 27, 0.55); font-weight: 700; display: block;
}
.shop-bar__label--warn { color: var(--peony); }
.shop-bar__value { font-size: 0.95rem; font-weight: 600; }
.shop-bar__form { display: flex; gap: 7px; flex-wrap: wrap; align-items: center; }
.shop-bar__form .form-control { width: auto; min-width: 210px; font-size: 0.86rem; padding: 7px 11px; }

/* ==========================================================================
   Panels & forms
   ========================================================================== */
.panel {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 26px;
}
.panel--narrow { max-width: 430px; margin: 40px auto; }
.panel__title { font-size: 1.15rem; margin-bottom: 14px; }

.form-group { margin-bottom: 16px; }
.form-label { display: block; font-weight: 700; font-size: 0.85rem; margin-bottom: 5px; }
.form-control {
    width: 100%;
    padding: 10px 13px;
    border-radius: var(--radius);
    border: 1.5px solid var(--line);
    font-family: var(--font-body);
    font-size: 0.94rem;
    background: #fff;
    color: var(--ink);
}
.form-control:focus {
    outline: none;
    border-color: var(--peony);
    box-shadow: 0 0 0 3px rgba(178, 58, 91, 0.13);
}
.form-hint { font-size: 0.79rem; color: rgba(30, 26, 27, 0.55); margin-top: 4px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.alert {
    padding: 11px 15px;
    border-radius: var(--radius);
    font-size: 0.89rem;
    margin-bottom: 16px;
    border-left: 3px solid transparent;
}
.alert--error { background: #F7E3E3; color: #6E1616; border-left-color: var(--danger); }
.alert--success { background: #E1EBE3; color: var(--eucalyptus-dark); border-left-color: var(--eucalyptus); }
.alert--info { background: var(--blush); color: var(--ink); border-left-color: var(--peony); }

/* ==========================================================================
   Badges & small type
   ========================================================================== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: var(--radius-pill);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.badge--pending { background: #F7ECD8; color: #6E4708; }
.badge--active { background: #E1EBE3; color: var(--eucalyptus-dark); }
.badge--suspended { background: #F6E2D6; color: #7B3B12; }
.badge--blacklisted { background: #F5DCDC; color: #6E1616; }
.badge--placed { background: var(--blush); color: var(--peony-dark); }
.badge--completed { background: #E1EBE3; color: var(--eucalyptus-dark); }
.badge--cancelled { background: rgba(30,26,27,0.08); color: rgba(30,26,27,0.6); }

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.68rem;
    font-weight: 700;
    color: rgba(30, 26, 27, 0.45);
}

/* The order code is read aloud and copied by hand, so it is set in a
   monospaced face at a size that survives a phone screen in a busy shop. */
.order-code {
    font-family: ui-monospace, 'SFMono-Regular', 'Cascadia Code', Menlo, monospace;
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    color: var(--ink);
    background: var(--blush);
    padding: 6px 14px;
    border-radius: var(--radius);
    display: inline-block;
}

.points-value { font-weight: 700; color: var(--brass); }

/* Collection / delivery choice */
.fulfil-option {
    display: flex; align-items: center; gap: 10px; cursor: pointer;
    border: 1.5px solid var(--line); border-radius: var(--radius);
    padding: 12px 15px; flex: 1; min-width: 170px; background: #fff;
}
.fulfil-option:has(input:checked) { border-color: var(--peony); background: #FDF4F6; }
.fulfil-option input { width: auto; margin: 0; }

.totals-row { display: flex; justify-content: space-between; margin-bottom: 5px; }
.totals-row--grand {
    font-weight: 700; font-size: 1.15rem; margin-top: 9px;
    padding-top: 9px; border-top: 1px solid var(--line);
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
    border-top: 1px solid var(--line);
    padding: 28px 0;
    margin-top: 50px;
    font-size: 0.83rem;
    color: rgba(30, 26, 27, 0.55);
}
.site-footer__inner {
    display: flex; justify-content: space-between; align-items: center;
    gap: 14px; flex-wrap: wrap;
}

/* ==========================================================================
   Responsive. Roughly nine in ten visits are on a phone, so these are the
   sizes that matter most, not an afterthought.
   ========================================================================== */
@media (max-width: 640px) {
    .site-nav__links { gap: 0; }
    .site-nav__link { padding: 8px 9px; font-size: 0.86rem; }
    .hero { padding: 36px 0 26px; }
    .panel { padding: 18px; }
    .product-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
    .product-card__body { padding: 11px 12px 13px; }
    .product-card__name { font-size: 1rem; }
    .section-nav { top: 53px; }
    .shop-bar__inner { flex-direction: column; align-items: stretch; }
    .shop-bar__form { flex-direction: column; align-items: stretch; }
    .shop-bar__form .form-control { min-width: 0; width: 100%; }
    .form-row { grid-template-columns: 1fr; gap: 0; }
    :root { --cut: 14px; }
}

@media (max-width: 420px) {
    .site-nav__brand { font-size: 1.2rem; }
    .site-nav__link .nav-text { display: none; }
    .product-card__footer { flex-direction: column; align-items: stretch; gap: 8px; }
    .stepper { justify-content: space-between; }
}
