/*
|--------------------------------------------------------------------------
| Integrity Storefront Styles
|--------------------------------------------------------------------------
| EXISTING FILE: replace the whole file on the server.
| Location: integritybook/assets/css/storefront.css
| (Added for the new Figma design, 16 September 2026. Updated the same day
|  for the Reader Reflections carousel and the Annalyxx logo; text made
|  bigger and clearer, especially on phones, 17 September 2026.)
|--------------------------------------------------------------------------
| Used by index.php, checkout.php and success.php only.
| Admin pages keep using style.css.
| Design tokens match the Figma design (unify-ruby-64917070.figma.site).
*/

:root {
    --background: #ffffff;
    --foreground: #182033;
    --primary: #0f766e;
    --primary-fg: #ffffff;
    --primary-tint: rgba(15, 118, 110, 0.06);
    --primary-soft: rgba(15, 118, 110, 0.15);
    --muted: #f2f2f0;
    --muted-fg: #5b6270; /* was #6b7280: darker grey, easier to read (17 Sept 2026) */
    --border: #e5e5e2;
    --border-strong: #c8d0cc;
    --body-text: #3a3a3a;
    --success: #23703f; /* was #2d8a4e: darker green so "In stock" / "Free" read clearly (17 Sept 2026) */
    --danger: #b91c1c;
    --field-bg: #fafaf8;

    --f-ui: "Helvetica Neue", Helvetica, Arial, sans-serif;
    --f-serif: "Lora", Georgia, serif;

    --t-xs: 13px; /* was 12px (17 Sept 2026) */
    --t-sm: 16px;
    --t-md: 20px;
    --t-lg: 24px;
    --t-xl: 32px;
    --t-2xl: 40px;

    --sp-1: 4px;
    --sp-2: 8px;
    --sp-3: 12px;
    --sp-4: 16px;
    --sp-5: 20px;
    --sp-6: 24px;
    --sp-8: 32px;
    --sp-10: 40px;
    --sp-12: 48px;
    --sp-16: 64px;

    --ease: cubic-bezier(0.4, 0, 0.2, 1);

    color-scheme: light;
}

/*
| Larger, clearer text on phones (owner request, 17 September 2026).
| Every text size on the pages comes from the --t-* tokens, so changing
| them here enlarges the small print, body text and quotes on phones only.
| Headings and prices (--t-lg and up) are already large and stay the same.
*/
@media (max-width: 720px) {
    :root {
        --t-xs: 14px;
        --t-sm: 17px;
        --t-md: 21px;
        --muted-fg: #4f5663;
        --body-text: #262626;
    }
}

/* ---------- Base ---------- */

.sf *,
.sf *::before,
.sf *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 84px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    font-kerning: normal;
}

body.sf {
    margin: 0;
    background: var(--background);
    color: var(--foreground);
    font-family: var(--f-ui);
    font-size: var(--t-sm);
    line-height: 1.5;
    animation: pageFadeIn 0.22s ease-out both;
}

.sf img {
    max-width: 100%;
}

.sf input,
.sf button,
.sf select,
.sf textarea {
    font-family: var(--f-ui);
}

.sf a:focus-visible,
.sf button:focus-visible,
.sf summary:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.sf-visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

/* Parts that only make sense with / without JavaScript */
html:not(.js) .sf-js-only {
    display: none !important;
}

.js .sf-no-js-only {
    display: none !important;
}

.sf [hidden] {
    display: none !important;
}

::-webkit-scrollbar {
    width: 3px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #d4d4d0;
    border-radius: 2px;
}

@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pageFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.sf-animate {
    animation: fadeSlideIn 0.18s var(--ease);
}

.sf-muted {
    color: var(--muted-fg);
}

.sf-eyebrow {
    font-size: var(--t-xs);
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted-fg);
    margin-bottom: var(--sp-4);
}

/* ---------- Buttons ---------- */

.sf-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--sp-2);
    padding: var(--sp-4) var(--sp-6);
    border: 0;
    border-radius: 50px;
    background: var(--primary);
    color: var(--primary-fg);
    font-size: var(--t-xs);
    font-weight: 500;
    letter-spacing: -0.01em;
    line-height: 1.2;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.1s var(--ease);
}

.sf-btn:hover:not(:disabled) {
    opacity: 0.85;
}

.sf-btn:active:not(:disabled) {
    transform: scale(0.975);
}

.sf-btn:disabled {
    background: var(--border-strong);
    cursor: not-allowed;
}

.sf-btn--lg {
    padding: var(--sp-5) var(--sp-8);
    font-size: var(--t-sm);
}

.sf-btn--full {
    display: flex;
    width: 100%;
}

/* ---------- Header ---------- */

.sf-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.96);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}

.sf-header__inner {
    max-width: 1320px;
    height: 60px;
    margin: 0 auto;
    padding: 0 var(--sp-10);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-4);
}

.sf-logo {
    font-family: var(--f-serif);
    font-weight: 600;
    font-size: var(--t-md);
    letter-spacing: -0.02em;
    color: var(--primary);
    text-decoration: none;
}

/*
| Annalyxx Global logo (added 16 September 2026).
| Same icon, name and tagline as the main website annalyxx.global, at the
| same proportions (icon : name : tagline). Links to the main website.
| Header: icon + ANNALYXX / GLOBAL LTD. Footer: full logo with tagline.
*/
.sf-brand {
    display: inline-flex;
    flex-direction: column;
    flex-shrink: 0;
    color: #0c1e2c;
    font-family: "Inter", var(--f-ui);
    text-decoration: none;
    transition: opacity 0.2s;
}

.sf-brand:hover {
    opacity: 0.85;
}

.sf-brand__top {
    display: flex;
    align-items: center;
    gap: 7px;
}

.sf-brand__icon {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
}

.sf-brand__name {
    display: flex;
    flex-direction: column;
    text-transform: uppercase;
    white-space: nowrap;
}

.sf-brand__main {
    font-size: 17px;
    font-weight: 900;
    letter-spacing: 1px;
    line-height: 0.9;
}

.sf-brand__sub {
    margin-top: 2px;
    font-size: 11px;
    font-weight: 400;
    letter-spacing: 2px;
    line-height: 1.1;
}

.sf-brand__tagline {
    margin-top: var(--sp-2);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-align: center;
    text-transform: uppercase;
    white-space: nowrap;
}

.sf-brand--full .sf-brand__top {
    gap: 10px;
}

.sf-brand--full .sf-brand__icon {
    width: 52px;
    height: 52px;
}

.sf-brand--full .sf-brand__main {
    font-size: 26px;
    letter-spacing: 1.5px;
}

.sf-brand--full .sf-brand__sub {
    font-size: 16px;
    letter-spacing: 3px;
}

@media (max-width: 720px) {
    .sf .sf-badge {
        font-size: 12px;
    }

    /* Edition list: the badge (LIMITED, 10 COPIES...) sits under the edition
       name, lined up with it, so every row looks the same with the larger text. */
    .sf-edition .sf-edition__left {
        display: grid;
        grid-template-columns: 16px auto;
        align-items: center;
        gap: var(--sp-1) var(--sp-3);
    }

    .sf-edition .sf-edition__left .sf-badge {
        grid-column: 2;
        justify-self: start;
    }

    .sf-header .sf-btn {
        font-size: 13px;
    }
}

@media (max-width: 380px) {
    .sf-header .sf-brand__top {
        gap: 6px;
    }

    .sf-header .sf-brand__icon {
        width: 30px;
        height: 30px;
    }

    .sf-header .sf-brand__main {
        font-size: 15px;
    }

    .sf-header .sf-brand__sub {
        font-size: 9.5px;
        letter-spacing: 1.6px;
    }

    .sf-header .sf-btn {
        padding: var(--sp-3) var(--sp-4);
        white-space: nowrap;
    }
}

/* Very narrow screens (e.g. 280px): let the header button wrap so it stays on screen */
@media (max-width: 300px) {
    .sf-header .sf-btn {
        white-space: normal;
    }
}

.sf-nav {
    display: flex;
    align-items: center;
    gap: var(--sp-10);
}

.sf-nav a {
    font-size: var(--t-xs);
    letter-spacing: -0.01em;
    color: var(--muted-fg);
    text-decoration: none;
    transition: color 0.2s;
}

.sf-nav a:hover {
    color: var(--foreground);
}

/* ---------- Product page layout ---------- */

.sf-main {
    position: relative;
    max-width: 1320px;
    margin: 0 auto;
    padding: 100px var(--sp-10) 0;
}

.sf-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 400px;
    gap: 128px;
    align-items: start;
}

.sf-edit-col {
    order: 1;
    min-width: 0;
    max-width: 600px;
}

.sf-buy-col {
    order: 2;
    position: sticky;
    top: 84px;
    max-height: calc(100vh - 100px);
    overflow-y: auto;
    scrollbar-width: none;
}

.sf-buy-col::-webkit-scrollbar {
    display: none;
}

.sf-divider {
    height: 1px;
    margin: var(--sp-16) 0;
    border: 0;
    background: var(--border);
}

.sf-body {
    font-size: var(--t-sm);
    line-height: 1.75;
    letter-spacing: -0.01em;
    color: var(--body-text);
}

.sf-body + .sf-body {
    margin-top: var(--sp-4);
}

/* About the author */

.sf-author {
    display: flex;
    align-items: flex-start;
    gap: var(--sp-6);
}

.sf-author__photo {
    width: 88px;
    height: 88px;
    flex-shrink: 0;
    border-radius: 50%;
    border: 1px solid var(--border);
    object-fit: cover;
    background: var(--muted);
}

.sf-author__name {
    font-family: var(--f-serif);
    font-weight: 600;
    font-size: var(--t-lg);
    letter-spacing: -0.02em;
    margin-bottom: var(--sp-1);
}

.sf-author__role {
    font-size: var(--t-xs);
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--muted-fg);
    margin-bottom: var(--sp-4);
}

.sf-stats {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-10);
    margin-top: var(--sp-8);
    padding-left: 112px;
    list-style: none;
}

.sf-stat__num {
    font-family: var(--f-serif);
    font-weight: 600;
    font-size: var(--t-xl);
    line-height: 1;
    letter-spacing: -0.02em;
    color: var(--primary);
    margin-bottom: var(--sp-1);
}

.sf-stat__label {
    font-size: var(--t-xs);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted-fg);
}

/* Why this book */

.sf-question {
    font-family: var(--f-serif);
    font-weight: 500;
    font-style: italic;
    font-size: clamp(24px, 3vw, 40px);
    line-height: 1.2;
    letter-spacing: -0.02em;
    margin-bottom: var(--sp-6);
}

/* Numbered sections */

.sf-section-head {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    margin-bottom: var(--sp-6);
}

.sf-section-num {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--primary);
    color: #ffffff;
    font-size: var(--t-xs);
    font-weight: 600;
}

.sf-section-title {
    font-family: var(--f-serif);
    font-weight: 600;
    font-size: var(--t-lg);
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.sf-section-sub {
    margin-top: 2px;
    font-size: var(--t-xs);
    letter-spacing: -0.01em;
    color: var(--muted-fg);
}

.sf-argument .sf-body {
    line-height: 1.78;
}

.sf-quote {
    margin: var(--sp-10) 0 0;
    padding: 0 0 0 var(--sp-5);
    border-left: 3px solid var(--primary);
}

.sf-quote p,
.sf-reflection__quote {
    font-family: var(--f-serif);
    font-style: italic;
    font-weight: 400;
    font-size: var(--t-md);
    line-height: 1.65;
    letter-spacing: -0.01em;
}

.sf-quote footer {
    margin-top: var(--sp-3);
    font-size: var(--t-xs);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted-fg);
}

/* Reader reflections */

.sf-reflection + .sf-reflection {
    margin-top: var(--sp-10);
}

.sf-reflection__quote {
    margin-bottom: var(--sp-5);
}

.sf-reflection__by {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
}

.sf-reflection__initials {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #e0e0de;
    color: #4f5663;
    font-size: var(--t-xs);
    font-weight: 600;
}

.sf-reflection__name {
    font-size: var(--t-xs);
    font-weight: 500;
    letter-spacing: -0.01em;
}

.sf-reflection__title {
    margin-top: 2px;
    font-size: var(--t-xs);
    color: var(--muted-fg);
}

/* The part of the book a quote is about, e.g. "On Chapter 3" */
.sf-reflection__part {
    margin-bottom: var(--sp-3);
    font-size: var(--t-xs);
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--primary);
}

/*
| Reader reflections carousel (added 16 September 2026).
| With JavaScript: one set at a time, all sets stacked in the same grid cell
| so the section keeps the height of the tallest set and the page never jumps.
| Without JavaScript: every set is listed, each quote once.
*/

html:not(.js) .sf-reflections__slide + .sf-reflections__slide {
    margin-top: var(--sp-10);
}

html:not(.js) .sf-reflection--repeat {
    display: none;
}

html:not(.js) .sf-reflection--repeat + .sf-reflection {
    margin-top: 0;
}

.js .sf-reflections {
    display: flex;
    flex-direction: column;
}

.js .sf-reflections__track {
    order: 1;
    display: grid;
    touch-action: pan-y pinch-zoom;
}

.js .sf-reflections__slide {
    grid-area: 1 / 1;
    visibility: hidden;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.2s var(--ease), transform 0.2s var(--ease), visibility 0s linear 0.2s;
}

.js .sf-reflections__slide.is-active {
    visibility: visible;
    opacity: 1;
    transform: none;
    transition: opacity 0.4s var(--ease) 0.2s, transform 0.4s var(--ease) 0.2s, visibility 0s linear 0s;
}

.sf-reflections__controls {
    order: 2;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-4);
    margin-top: var(--sp-8);
}

.sf-reflections__dots,
.sf-reflections__buttons {
    display: flex;
    align-items: center;
}

.sf-reflections__dots {
    gap: var(--sp-1);
}

.sf-reflections__buttons {
    gap: var(--sp-2);
}

.sf-reflections__dot {
    position: relative;
    width: 24px;
    height: 24px;
    border: 0;
    background: transparent;
    cursor: pointer;
}

.sf-reflections__dot::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 8px;
    height: 8px;
    border-radius: 4px;
    background: #8a9390;
    transform: translate(-50%, -50%);
    transition: width 0.2s var(--ease), background-color 0.2s;
}

.sf-reflections__dot:hover::before {
    background: var(--foreground);
}

.sf-reflections__dot.is-active::before {
    width: 18px;
    background: var(--primary);
}

.sf-reflections__btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid var(--border);
    border-radius: 50%;
    background: #ffffff;
    color: var(--foreground);
    cursor: pointer;
    transition: background-color 0.15s, border-color 0.15s;
}

.sf-reflections__btn:hover {
    background: var(--muted);
    border-color: var(--border-strong);
}

.sf-reflections__icon-play,
.sf-reflections.is-paused .sf-reflections__icon-pause {
    display: none;
}

.sf-reflections.is-paused .sf-reflections__icon-play {
    display: block;
}

/* Author video */

.sf-note {
    padding-bottom: 128px;
}

.sf-note .sf-body {
    margin-bottom: var(--sp-6);
}

.sf-video {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: 20px;
    background: #0f0f0f;
}

.sf-video__poster {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.55;
    transition: opacity 0.3s;
}

.sf-video.is-playing .sf-video__poster {
    opacity: 0;
}

.sf-video__overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--sp-4);
    border: 0;
    background: none;
    color: #ffffff;
    text-decoration: none;
}

a.sf-video__overlay {
    cursor: pointer;
}

.sf-video__icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.8);
    transition: transform 0.2s var(--ease), background-color 0.2s;
}

a.sf-video__overlay:hover .sf-video__icon {
    transform: scale(1.05);
    background: rgba(255, 255, 255, 0.08);
}

.sf-video__icon svg {
    margin-left: 3px;
}

.sf-video__label {
    font-size: var(--t-xs);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7);
}

.sf-video iframe,
.sf-video video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    background: #0f0f0f;
}

/* ---------- Purchase card ---------- */

.sf-purchase__cover {
    margin-bottom: var(--sp-6);
}

.sf-purchase__cover img {
    display: block;
    width: 100%;
    max-width: 210px;
    height: auto;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    border-radius: 16px;
    background: var(--muted);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 0 20px 48px rgba(0, 0, 0, 0.12), -4px 0 0 rgba(0, 0, 0, 0.05);
}

.sf-purchase__title {
    font-family: var(--f-serif);
    font-weight: 700;
    font-size: var(--t-lg);
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin-bottom: var(--sp-1);
}

.sf-purchase__subtitle {
    font-size: var(--t-xs);
    line-height: 1.5;
    letter-spacing: -0.01em;
    color: var(--muted-fg);
    margin-bottom: var(--sp-1);
}

.sf-purchase__author {
    font-size: var(--t-xs);
    letter-spacing: -0.01em;
    margin-bottom: var(--sp-3);
}

.sf-rating {
    display: flex;
    align-items: center;
    gap: var(--sp-1);
}

.sf-rating__text {
    margin-left: var(--sp-2);
    font-size: var(--t-xs);
    color: var(--muted-fg);
}

/* Editions */

.sf-editions {
    min-width: 0;
    margin-top: var(--sp-6);
    border: 0;
}

.sf-editions > legend {
    padding: 0;
    margin-bottom: var(--sp-3);
}

.sf-edition-list {
    display: flex;
    flex-direction: column;
    gap: var(--sp-2);
}

.sf-edition {
    position: relative;
}

.sf-edition__input {
    position: absolute;
    top: 50%;
    left: 20px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.sf-edition__option {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-3);
    padding: var(--sp-3) var(--sp-4);
    border: 1.5px solid var(--border);
    border-radius: 50px;
    background: transparent;
    cursor: pointer;
    transition: border-color 0.2s var(--ease), background-color 0.2s var(--ease);
}

.sf-edition__option:hover {
    border-color: var(--border-strong);
    background: var(--muted);
}

.sf-edition__left {
    min-width: 0;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--sp-2) var(--sp-3);
}

.sf-radio {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    border: 1.5px solid #b8bfbb;
    border-radius: 50%;
    transition: border 0.2s var(--ease);
}

.sf-edition__name {
    font-size: var(--t-xs);
    font-weight: 400;
    letter-spacing: -0.01em;
    transition: color 0.2s var(--ease);
}

.sf-badge {
    padding: 2px var(--sp-2);
    border-radius: 50px;
    background: var(--muted);
    color: var(--muted-fg);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    white-space: nowrap;
    transition: color 0.2s, background-color 0.2s;
}

.sf-edition__price {
    flex-shrink: 0;
    font-family: var(--f-serif);
    font-size: var(--t-sm);
    font-weight: 700;
    letter-spacing: -0.02em;
    transition: color 0.2s var(--ease);
}

.sf-edition__input:checked + .sf-edition__option {
    border: 2px solid var(--primary);
    background: var(--primary-tint);
}

.sf-edition__input:checked + .sf-edition__option .sf-radio {
    border: 5px solid var(--primary);
}

.sf-edition__input:checked + .sf-edition__option .sf-edition__name {
    font-weight: 600;
    color: var(--primary);
}

.sf-edition__input:checked + .sf-edition__option .sf-badge {
    color: var(--primary);
    background: rgba(15, 118, 110, 0.1);
}

.sf-edition__input:checked + .sf-edition__option .sf-edition__price {
    color: var(--primary);
}

.sf-edition__input:focus-visible + .sf-edition__option {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.sf-edition__input:disabled + .sf-edition__option {
    opacity: 0.5;
    cursor: not-allowed;
}

.sf-edition__input:disabled + .sf-edition__option:hover {
    border-color: var(--border);
    background: transparent;
}

/* Edition details: inline panel (phones/tablets, or without JavaScript) */

.sf-edition__details {
    margin: var(--sp-2) var(--sp-3) 0;
    padding: var(--sp-4);
    border: 1px solid var(--primary-soft);
    border-radius: 16px;
    background: var(--muted);
}

.js .sf-edition__details {
    display: none;
}

@media (max-width: 1024px) {
    .js .sf-edition.is-expanded .sf-edition__details {
        display: block;
        animation: fadeSlideIn 0.18s var(--ease);
    }
}

.sf-details__title {
    display: none;
    margin-bottom: var(--sp-1);
    font-size: var(--t-xs);
    font-weight: 600;
    color: var(--foreground);
}

.sf-details__note {
    margin-bottom: var(--sp-3);
    font-size: var(--t-xs);
    line-height: 1.65;
    color: #555555;
}

.sf-check-list {
    display: flex;
    flex-direction: column;
    gap: var(--sp-2);
    list-style: none;
}

.sf-check-list li {
    display: flex;
    gap: var(--sp-2);
    font-size: var(--t-xs);
    line-height: 1.5;
    color: #444444;
}

.sf-check-list svg {
    flex-shrink: 0;
    margin-top: 3px;
}

.sf-details__max {
    margin-top: var(--sp-3);
    font-size: var(--t-xs);
    font-weight: 500;
    color: var(--primary);
}

/* Edition details: floating tooltip on large screens (added by storefront.js) */

.sf-tip {
    position: fixed;
    z-index: 200;
    width: 244px;
    padding: var(--sp-4);
    border: 1px solid var(--border);
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.10), 0 2px 8px rgba(0, 0, 0, 0.05);
    pointer-events: none;
    animation: fadeSlideIn 0.14s ease;
}

.sf-tip::after {
    content: "";
    position: absolute;
    top: var(--arrow-top, 50%);
    width: 10px;
    height: 10px;
    background: #ffffff;
    border: 1px solid var(--border);
}

.sf-tip--left::after {
    right: -6px;
    transform: translateY(-50%) rotate(45deg);
    border-left: 0;
    border-bottom: 0;
}

.sf-tip--right::after {
    left: -6px;
    transform: translateY(-50%) rotate(45deg);
    border-right: 0;
    border-top: 0;
}

.sf-tip .sf-details__title {
    display: block;
}

.sf-tip .sf-details__note {
    line-height: 1.6;
}

.sf-tip .sf-check-list {
    gap: var(--sp-1);
}

/* Price box */

.sf-pricebox {
    margin-top: var(--sp-5);
    padding: var(--sp-5);
    border-radius: 20px;
    background: var(--muted);
}

.sf-pricebox__row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--sp-3);
    margin-bottom: var(--sp-4);
}

.sf-pricebox__each {
    display: flex;
    align-items: baseline;
    gap: var(--sp-2);
}

.sf-pricebox__price {
    font-family: var(--f-serif);
    font-weight: 700;
    font-size: var(--t-2xl);
    line-height: 1;
    letter-spacing: -0.03em;
    color: var(--primary);
}

.sf-per-copy,
.sf-pricebox__total-label,
.sf-qty__hint,
.sf-included {
    font-size: var(--t-xs);
    letter-spacing: -0.01em;
    color: var(--muted-fg);
}

.sf-pricebox__total {
    text-align: right;
}

.sf-pricebox__total-value {
    font-family: var(--f-serif);
    font-weight: 700;
    font-size: var(--t-lg);
    letter-spacing: -0.02em;
    color: var(--primary);
}

.sf-qty {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--sp-3);
    margin-bottom: var(--sp-4);
}

.sf-stepper {
    display: inline-flex;
    align-items: center;
    overflow: hidden;
    border: 1.5px solid var(--border);
    border-radius: 50px;
    background: #ffffff;
}

.sf-stepper__btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    background: transparent;
    color: var(--foreground);
    font-size: var(--t-md);
    cursor: pointer;
    transition: background-color 0.15s;
}

.sf-stepper__btn:first-child {
    border-right: 1px solid var(--border);
}

.sf-stepper__btn:last-child {
    border-left: 1px solid var(--border);
}

.sf-stepper__btn:hover:not(:disabled) {
    background: var(--muted);
}

.sf-stepper__btn:disabled {
    color: #cccccc;
    cursor: not-allowed;
}

.sf-stepper__input {
    width: 44px;
    height: 40px;
    border: 0;
    background: transparent;
    color: var(--foreground);
    font-size: var(--t-sm);
    font-weight: 500;
    text-align: center;
    -moz-appearance: textfield;
    appearance: textfield;
}

.sf-stepper__input:focus {
    outline: none;
    background: var(--primary-tint);
}

.sf-stepper__input::-webkit-outer-spin-button,
.sf-stepper__input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.sf-qty__hint.is-max {
    color: var(--primary);
    font-weight: 500;
}

.sf-included {
    margin-bottom: var(--sp-4);
}

.sf-stock {
    display: flex;
    align-items: center;
    gap: var(--sp-2);
    margin-top: var(--sp-3);
    font-size: var(--t-xs);
    font-weight: 500;
    color: var(--success);
}

.sf-stock__dot {
    width: 7px;
    height: 7px;
    flex-shrink: 0;
    border-radius: 50%;
    background: currentColor;
}

.sf-stock.is-out {
    color: var(--danger);
}

.sf-trust {
    margin-top: var(--sp-4);
    padding: var(--sp-3) var(--sp-4);
    list-style: none;
}

.sf-trust li {
    font-size: var(--t-xs);
    line-height: 1.75;
    color: var(--muted-fg);
}

/* Mobile sticky buy bar */

.sf-sticky-bar {
    display: none;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 90;
    padding: var(--sp-3) var(--sp-5) calc(var(--sp-5) + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.97);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.32, 0, 0.67, 0);
}

.sf-sticky-bar.is-visible {
    transform: translateY(0);
}

.sf-sticky-bar__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-4);
}

.sf-sticky-bar__total {
    font-family: var(--f-serif);
    font-weight: 700;
    font-size: var(--t-lg);
    line-height: 1;
    letter-spacing: -0.02em;
    color: var(--primary);
}

.sf-sticky-bar__copies {
    margin-top: 2px;
    font-size: var(--t-xs);
    color: var(--muted-fg);
}

/* Back to top */

.sf-to-top {
    position: fixed;
    left: 50%;
    bottom: var(--sp-10);
    z-index: 200;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    background: var(--primary);
    color: #ffffff;
    box-shadow: 0 4px 16px rgba(15, 118, 110, 0.35);
    cursor: pointer;
    transform: translateX(-50%);
    transition: opacity 0.2s;
}

.sf-to-top__tip {
    position: absolute;
    left: 50%;
    bottom: calc(100% + 8px);
    padding: var(--sp-1) var(--sp-3);
    border-radius: var(--sp-2);
    background: var(--foreground);
    color: #ffffff;
    font-size: var(--t-xs);
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transform: translateX(-50%);
    transition: opacity 0.15s;
}

.sf-to-top__tip::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid var(--foreground);
}

.sf-to-top:hover .sf-to-top__tip,
.sf-to-top:focus-visible .sf-to-top__tip {
    opacity: 1;
}

/* Footer */

.sf-footer {
    max-width: 1320px;
    margin: 0 auto;
    padding: var(--sp-8) var(--sp-10);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-4);
    border-top: 1px solid var(--border);
}

.sf-footer__copy {
    font-size: var(--t-xs);
    color: var(--muted-fg);
}

.sf-footer__links {
    display: flex;
    gap: var(--sp-6);
}

.sf-footer__links a,
.sf-trust a,
.sf-hint a {
    color: var(--muted-fg);
    text-decoration: none;
    transition: color 0.2s;
}

.sf-footer__links a {
    font-size: var(--t-xs);
}

.sf-footer__links a:hover,
.sf-trust a:hover,
.sf-hint a:hover {
    color: var(--foreground);
    text-decoration: underline;
}

/* ---------- Policy page (policy.php) ---------- */

.sf-policy {
    max-width: 720px;
    margin: 0 auto;
    padding: 110px var(--sp-5) var(--sp-16);
}

.sf-policy__title {
    font-family: var(--f-serif);
    font-weight: 600;
    font-size: clamp(28px, 4vw, 40px);
    line-height: 1.2;
    letter-spacing: -0.02em;
    margin-bottom: var(--sp-2);
}

.sf-policy__updated {
    font-size: var(--t-xs);
    color: var(--muted-fg);
    margin-bottom: var(--sp-12);
}

.sf-policy__section {
    scroll-margin-top: 84px;
}

.sf-policy__heading {
    margin: var(--sp-8) 0 var(--sp-3);
    font-family: var(--f-serif);
    font-weight: 600;
    font-size: var(--t-md);
    letter-spacing: -0.01em;
}

.sf-policy__list {
    padding-left: var(--sp-5);
    font-size: var(--t-sm);
    line-height: 1.75;
    color: var(--body-text);
}

.sf-policy__lead {
    margin-bottom: var(--sp-4);
    font-family: var(--f-serif);
    font-style: italic;
    font-size: var(--t-md);
    line-height: 1.6;
}

.sf-policy .sf-note-box {
    margin-bottom: 0;
}

@media (max-width: 1024px) {
    .sf-nav.sf-nav--always {
        display: flex;
    }
}

@media (max-width: 720px) {
    .sf-policy {
        padding-top: 88px;
    }

    .sf-nav.sf-nav--always {
        display: none;
    }
}

/* ---------- Product page responsive ---------- */

@media (max-width: 1024px) {
    .sf-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
    }

    .sf-buy-col {
        position: static;
        max-height: none;
        overflow: visible;
    }

    .sf-nav {
        display: none;
    }
}

@media (max-width: 720px) {
    .sf-header__inner {
        padding: 0 var(--sp-5);
    }

    .sf-main {
        padding: 72px var(--sp-5) 0;
    }

    .sf-footer {
        padding: var(--sp-6) var(--sp-5);
        flex-direction: column;
        align-items: flex-start;
    }

    .sf-buy-col {
        order: -1;
        padding-bottom: var(--sp-8);
        margin-bottom: var(--sp-8);
        border-bottom: 1px solid var(--border);
    }

    .sf-edit-col {
        order: 1;
    }

    .sf-purchase__hero {
        display: flex;
        align-items: flex-start;
        gap: var(--sp-4);
        margin-bottom: var(--sp-5);
    }

    .sf-purchase__cover {
        flex-shrink: 0;
        margin-bottom: 0;
    }

    .sf-purchase__cover img {
        max-width: 100px;
    }

    .sf-purchase__meta {
        flex: 1;
        padding-top: 2px;
    }

    .sf-editions {
        margin-top: 0;
    }

    .sf-sticky-bar {
        display: block;
    }

    .sf-product .sf-to-top {
        width: 40px;
        height: 40px;
        bottom: 84px;
    }

    .sf-to-top__tip {
        display: none;
    }

    body.sf-product {
        padding-bottom: 80px;
    }
}

/* ---------- Checkout ---------- */

.sf-co-header .sf-header__inner {
    max-width: 1100px;
}

.sf-steps {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    list-style: none;
}

.sf-steps li {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    font-size: var(--t-xs);
    letter-spacing: -0.01em;
    color: var(--muted-fg);
}

.sf-steps li + li::before {
    content: "";
    width: 20px;
    height: 1px;
    background: var(--border);
}

.sf-steps li.is-current {
    color: var(--primary);
    font-weight: 500;
}

.sf-header__spacer {
    width: 149px; /* same width as the logo, so the checkout steps stay centred */
}

.sf-co-main {
    max-width: 1100px;
    margin: 0 auto;
    padding: 88px var(--sp-10) var(--sp-16);
}

.sf-back {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-2);
    margin-bottom: var(--sp-8);
    font-size: var(--t-xs);
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--muted-fg);
    text-decoration: none;
    transition: color 0.2s;
}

.sf-back:hover {
    color: var(--foreground);
}

.sf-co-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: var(--sp-16);
    align-items: start;
}

.sf-co-form {
    min-width: 0;
}

.sf-co-summary {
    position: sticky;
    top: 84px;
}

.sf-co-section {
    min-width: 0;
    margin-bottom: var(--sp-12);
    border: 0;
}

.sf-co-divider {
    height: 1px;
    margin: 0 0 var(--sp-12);
    border: 0;
    background: var(--border);
}

.sf-co-head {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    margin-bottom: var(--sp-6);
}

.sf-co-head h2 {
    font-family: var(--f-serif);
    font-weight: 600;
    font-size: var(--t-lg);
    letter-spacing: -0.02em;
}

.sf-co-lead {
    margin-bottom: var(--sp-6);
    font-size: var(--t-xs);
    line-height: 1.65;
    color: var(--muted-fg);
}

/* Your purchase switcher */

.sf-switch {
    margin-bottom: var(--sp-12);
}

.sf-switch__title {
    margin-bottom: var(--sp-3);
    font-family: var(--f-serif);
    font-weight: 600;
    font-size: var(--t-md);
    letter-spacing: -0.02em;
}

.sf-switch__summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-3);
    padding: var(--sp-4) var(--sp-5);
    border: 1.5px solid var(--border);
    border-radius: 16px;
    background: var(--muted);
    cursor: pointer;
    list-style: none;
    transition: border-color 0.2s var(--ease), background-color 0.2s var(--ease);
}

.sf-switch__summary::-webkit-details-marker {
    display: none;
}

.sf-switch__summary--static {
    cursor: default;
}

.sf-switch__change,
.sf-co-qty-static a {
    font-size: var(--t-xs);
    font-weight: 500;
    color: var(--primary);
}

.sf-co-qty-static {
    font-size: var(--t-sm);
    font-weight: 500;
}

.sf-switch[open] .sf-switch__summary {
    border-color: var(--primary);
    background: rgba(15, 118, 110, 0.04);
}

.sf-switch__label,
.sf-switch__sub,
.sf-switch__name {
    display: block;
}

.sf-switch__label {
    margin-bottom: 2px;
    font-size: var(--t-sm);
    font-weight: 500;
    letter-spacing: -0.01em;
}

.sf-switch__sub {
    font-size: var(--t-xs);
    letter-spacing: -0.01em;
    color: var(--muted-fg);
}

.sf-switch__chevron {
    flex-shrink: 0;
    transition: transform 0.22s var(--ease);
}

.sf-switch[open] .sf-switch__chevron {
    transform: rotate(180deg);
}

.sf-switch__list {
    margin-top: var(--sp-2);
    overflow: hidden;
    border: 1.5px solid var(--border);
    border-radius: 16px;
    animation: fadeSlideIn 0.18s var(--ease);
}

.sf-switch__item {
    position: relative;
}

.sf-switch__item + .sf-switch__item {
    border-top: 1px solid var(--border);
}

.sf-switch__option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-3);
    padding: var(--sp-4) var(--sp-5);
    cursor: pointer;
    transition: background-color 0.15s var(--ease);
}

.sf-switch__option:hover {
    background: var(--muted);
}

.sf-switch__left {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
}

.sf-switch__option .sf-radio {
    width: 15px;
    height: 15px;
}

.sf-switch__name {
    margin-bottom: 2px;
    font-size: var(--t-xs);
    letter-spacing: -0.01em;
    transition: color 0.2s;
}

.sf-switch__price {
    flex-shrink: 0;
    font-family: var(--f-serif);
    font-size: var(--t-sm);
    font-weight: 700;
    letter-spacing: -0.02em;
    transition: color 0.2s;
}

.sf-switch__item .sf-edition__input:checked + .sf-switch__option {
    background: var(--primary-tint);
}

.sf-switch__item .sf-edition__input:checked + .sf-switch__option .sf-radio {
    border: 5px solid var(--primary);
}

.sf-switch__item .sf-edition__input:checked + .sf-switch__option .sf-switch__name {
    font-weight: 600;
    color: var(--primary);
}

.sf-switch__item .sf-edition__input:checked + .sf-switch__option .sf-switch__price {
    color: var(--primary);
}

.sf-switch__item .sf-edition__input:focus-visible + .sf-switch__option {
    outline: 2px solid var(--primary);
    outline-offset: -2px;
}

.sf-switch__item .sf-edition__input:disabled + .sf-switch__option {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Quantity (checkout) */

.sf-stepper--lg .sf-stepper__btn {
    width: 48px;
    height: 48px;
}

.sf-stepper--lg .sf-stepper__input {
    width: 60px;
    height: 48px;
}

.sf-co-qty-hint {
    margin-top: var(--sp-3);
    font-size: var(--t-xs);
    color: var(--muted-fg);
}

.sf-co-qty-max {
    margin-top: var(--sp-1);
    font-size: var(--t-xs);
    font-weight: 500;
    color: var(--primary);
}

/* Form fields */

.sf-card {
    display: flex;
    flex-direction: column;
    gap: var(--sp-4);
    padding: var(--sp-6);
    border-radius: 20px;
    background: var(--field-bg);
}

.sf-field label {
    display: block;
    margin-bottom: var(--sp-2);
    font-size: var(--t-xs);
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--foreground);
}

.sf-input {
    width: 100%;
    padding: var(--sp-3) var(--sp-4);
    border: 1.5px solid var(--border);
    border-radius: 12px;
    background: #ffffff;
    color: var(--foreground);
    font-size: var(--t-sm);
    letter-spacing: -0.01em;
    outline: none;
    transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease);
}

.sf-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.12);
}

.sf-input::placeholder {
    color: #9ca3af;
}

select.sf-input {
    padding-right: var(--sp-10);
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
}

.sf-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--sp-3);
}

/* Fulfilment choice cards */

.sf-choice-row {
    display: flex;
    gap: var(--sp-3);
    margin-bottom: var(--sp-5);
    border: 0;
}

.sf-choice {
    position: relative;
    flex: 1;
    min-width: 0;
}

.sf-choice__input {
    position: absolute;
    top: 24px;
    left: 24px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.sf-choice__card {
    display: block;
    height: 100%;
    padding: var(--sp-5);
    border: 1.5px solid var(--border);
    border-radius: 20px;
    cursor: pointer;
    transition: border-color 0.2s var(--ease), background-color 0.2s var(--ease);
}

.sf-choice__title {
    display: block;
    margin-bottom: var(--sp-1);
    font-size: var(--t-sm);
    transition: color 0.2s var(--ease);
}

.sf-choice__sub {
    display: block;
    font-size: var(--t-xs);
    line-height: 1.5;
    color: var(--muted-fg);
}

.sf-choice__input:checked + .sf-choice__card {
    border: 2px solid var(--primary);
    background: rgba(15, 118, 110, 0.05);
}

.sf-choice__input:checked + .sf-choice__card .sf-choice__title {
    font-weight: 600;
    color: var(--primary);
}

.sf-choice__input:focus-visible + .sf-choice__card {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.sf-delivery-fields {
    min-width: 0;
    margin-bottom: var(--sp-5);
    border: 0;
}

.sf-delivery-fields__when {
    font-size: var(--t-sm);
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--primary);
}

.sf-note-box {
    margin-bottom: var(--sp-5);
    padding: var(--sp-4) var(--sp-5);
    border: 1px solid var(--primary-soft);
    border-radius: 16px;
    background: rgba(15, 118, 110, 0.05);
}

.sf-note-box__title {
    margin-bottom: var(--sp-2);
    font-size: var(--t-xs);
    font-weight: 500;
    color: var(--primary);
}

.sf-note-box__text {
    font-size: var(--t-sm);
    line-height: 1.65;
}

.sf-note-box__small {
    margin-top: var(--sp-2);
    font-size: var(--t-xs);
    line-height: 1.65;
    color: var(--muted-fg);
}

.sf-hint {
    margin-top: var(--sp-2);
    font-size: var(--t-xs);
    line-height: 1.6;
    text-align: center;
    color: var(--muted-fg);
}

/* Payment */

.js .sf-payment.is-collapsed {
    display: none;
}

.sf-payment.is-revealed {
    animation: fadeSlideIn 0.18s var(--ease);
}

.sf-pay-methods {
    display: flex;
    gap: var(--sp-3);
    margin-bottom: var(--sp-6);
}

.sf-pay-method {
    flex: 1;
    padding: var(--sp-4) var(--sp-5);
    border: 1.5px solid var(--border);
    border-radius: 20px;
}

.sf-pay-method__title {
    margin-bottom: var(--sp-1);
    font-size: var(--t-sm);
}

.sf-pay-method__sub {
    font-size: var(--t-xs);
    color: var(--muted-fg);
}

/* Order summary */

.sf-summary {
    padding: var(--sp-6);
    border-radius: 20px;
    background: var(--muted);
}

.sf-summary .sf-eyebrow {
    margin-bottom: var(--sp-5);
}

.sf-card .sf-eyebrow {
    margin-bottom: 0;
}

.sf-summary__book {
    display: flex;
    align-items: flex-start;
    gap: var(--sp-4);
    margin-bottom: var(--sp-6);
}

.sf-summary__book img {
    width: 52px;
    height: auto;
    flex-shrink: 0;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.sf-summary__title {
    margin-bottom: var(--sp-1);
    font-family: var(--f-serif);
    font-weight: 600;
    font-size: var(--t-sm);
    line-height: 1.3;
    letter-spacing: -0.01em;
}

.sf-summary__subtitle {
    margin-bottom: var(--sp-2);
    font-size: var(--t-xs);
    line-height: 1.5;
    color: var(--muted-fg);
}

.sf-summary__edition {
    font-size: var(--t-xs);
    letter-spacing: -0.01em;
}

.sf-summary__rows {
    display: flex;
    flex-direction: column;
    gap: var(--sp-3);
    margin-bottom: var(--sp-4);
}

.sf-summary__row {
    display: flex;
    justify-content: space-between;
    gap: var(--sp-3);
    font-size: var(--t-xs);
}

.sf-summary__row span:first-child {
    color: #555555;
}

.sf-summary__row span:last-child {
    font-weight: 500;
    text-align: right;
}

.sf-summary__row .is-free {
    color: var(--success);
}

.sf-summary__divider {
    height: 1px;
    margin: var(--sp-1) 0;
    border: 0;
    background: var(--border);
}

.sf-summary__total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin: var(--sp-4) 0 var(--sp-6);
}

.sf-summary__total-label {
    font-size: var(--t-xs);
    font-weight: 600;
}

.sf-summary__total-value {
    font-family: var(--f-serif);
    font-weight: 700;
    font-size: var(--t-xl);
    letter-spacing: -0.03em;
    color: var(--primary);
}

.sf-summary .sf-note-box {
    margin-bottom: var(--sp-4);
    padding: var(--sp-3) var(--sp-4);
    border-radius: 12px;
    background: rgba(15, 118, 110, 0.07);
}

.sf-summary .sf-note-box__title {
    margin-bottom: var(--sp-1);
}

.sf-summary .sf-note-box__text {
    font-size: var(--t-xs);
    color: #444444;
}

.sf-checkout .sf-to-top {
    bottom: var(--sp-10);
}

@media (max-width: 900px) {
    .sf-co-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .sf-co-summary {
        position: static;
    }
}

@media (max-width: 640px) {
    .sf-co-header .sf-header__inner {
        height: 52px;
        padding: 0 var(--sp-4);
    }

    .sf-steps,
    .sf-header__spacer {
        display: none;
    }

    .sf-co-main {
        padding: 72px var(--sp-5) 80px;
    }

    .sf-card {
        padding: var(--sp-5);
    }

    .sf-pay-methods {
        flex-direction: column;
    }

    .sf-checkout .sf-to-top {
        width: 40px;
        height: 40px;
        bottom: var(--sp-5);
    }

    .sf-to-top__tip {
        display: none;
    }
}

@media (max-width: 400px) {
    .sf-choice-row,
    .sf-grid-2 {
        grid-template-columns: 1fr;
    }

    .sf-choice-row {
        flex-direction: column;
    }
}

/* ---------- Order status (success.php) ---------- */

.sf-receipt {
    max-width: 560px;
    margin: 0 auto;
    padding: 100px var(--sp-5) var(--sp-16);
}

.sf-receipt__status {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    margin-bottom: var(--sp-4);
}

.sf-receipt__icon {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--primary);
    color: #ffffff;
}

.sf-receipt__icon.is-pending {
    background: #b7791f;
}

.sf-receipt__icon.is-failed {
    background: var(--danger);
}

.sf-receipt__title {
    font-family: var(--f-serif);
    font-weight: 600;
    font-size: var(--t-xl);
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.sf-receipt__lead {
    margin-bottom: var(--sp-8);
    font-size: var(--t-sm);
    line-height: 1.7;
    color: var(--body-text);
}

.sf-receipt__ref {
    font-weight: 600;
    color: var(--foreground);
    word-break: break-all;
}

.sf-receipt .sf-summary {
    margin-bottom: var(--sp-6);
}

.sf-receipt .sf-summary__rows {
    margin-bottom: 0;
}

.sf-receipt .sf-summary__row {
    font-size: var(--t-sm);
}

.sf-receipt .sf-note-box {
    margin: var(--sp-5) 0 0;
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .sf *,
    .sf *::before,
    .sf *::after,
    body.sf {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ---------- Layout fixes for the larger text (17 September 2026) ---------- */

/* Price box: "/ copy" stays on one line, and the order total moves under the
   price (still on the right) when a phone is too narrow for both */
.sf-per-copy {
    white-space: nowrap;
}

.sf-pricebox__row {
    flex-wrap: wrap;
}

.sf-pricebox__total {
    margin-left: auto;
}

/* About the author: 30+ / 22 / CBI stay on one row */
.sf-stats {
    column-gap: var(--sp-6);
}

/* Footer stacks a little earlier so it never half-wraps */
@media (max-width: 760px) {
    .sf-footer {
        padding: var(--sp-6) var(--sp-5);
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Large buttons keep their label on one line on phones */
@media (max-width: 720px) {
    .sf-btn--lg {
        font-size: 16px;
    }
}
