@layer reset, base, layout, components, pages, utilities;

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("/assets/fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
    U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("/assets/fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,
    U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@layer reset {
  *, *::before, *::after { box-sizing: border-box; }
  * { margin: 0; }
  img, picture, svg { display: block; max-inline-size: 100%; block-size: auto; }
  input, button, textarea, select { font: inherit; color: inherit; }
  ul[class], ol[class] { list-style: none; padding: 0; }
  a { color: inherit; }
  [hidden] { display: none !important; }
}

@layer base {
  :root {
    --brand: #18233e;
    --ink: #222;
    --ink-soft: #555;
    --muted: #666;
    --line: #e3e5e8;
    --surface: #fff;
    --surface-soft: #f6f7f9;
    --surface-muted: #f1f2f4;
    --sale: #d32f2f;
    --buy: #2eae48;
    --buy-hover: #27963d;
    /* Every colour of the site; nothing below writes one out. Text pairs meet WCAG AA (4.5:1),
       control borders 3:1. */
    --surface-hover: #eceef2;
    --line-strong: #cfd3d9;
    --control: #8b93a1;
    --muted-strong: #4d4d4d;
    --on-accent: #fff;
    --paper: #fbf9f4;
    --sale-soft: #fdecea;
    --ok-ink: #1b7a32;
    --ok-soft: #e8f5e9;
    --warn: #ffb300;
    --warn-soft: #fff8e1;
    --highlight: #ffd166;
    --ornament: #b08d3c;
    --radius: 4px;
    --shadow-cover: 0 1px 3px rgb(0 0 0 / 0.18), 0 0 0 1px rgb(0 0 0 / 0.06);
    --page-width: 80vw;
    --gutter: clamp(16px, 4vw, 24px);
    --step--1: clamp(0.8rem, 0.78rem + 0.1vw, 0.85rem);
    --step-0: clamp(0.9rem, 0.88rem + 0.1vw, 0.95rem);
    --step-1: clamp(1.05rem, 1rem + 0.25vw, 1.2rem);
    --step-2: clamp(1.3rem, 1.15rem + 0.7vw, 1.75rem);
    --step-3: clamp(1.6rem, 1.3rem + 1.2vw, 2.25rem);
    color-scheme: light;

    @media (max-width: 768px) { --page-width: 100vw; }
  }

  html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

  .price, .totals, .cart-line, .stepper, .checkout-bar, .summary-lines { font-variant-numeric: tabular-nums; }

  body {
    font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    font-size: var(--step-0);
    line-height: 1.6;
    color: var(--ink);
    background: var(--surface);
    text-rendering: optimizeLegibility;
  }

  h1, h2, h3 { line-height: 1.2; color: var(--ink); text-wrap: balance; }
  p { text-wrap: pretty; }
  a { text-underline-offset: 0.15em; }
  :focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

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

@layer layout {
  .site-header__bar, .page, .site-footer__inner, .site-footer__bottom {
    inline-size: min(100% - 2 * var(--gutter), var(--page-width));
    margin-inline: auto;
  }

  .page { padding-block: 20px 40px; min-block-size: 50vh; }

  .site-header { border-block-end: 1px solid var(--line); }

  .site-header__bar {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    grid-template-areas: "nav logo actions";
    align-items: center;
    column-gap: 24px;
    padding-block: 14px;
  }

  .logo {
    grid-area: logo;
    justify-self: center;
    img { block-size: 48px; inline-size: auto; }
  }

  .main-nav {
    grid-area: nav;
    display: flex;
    gap: 28px;

    a {
      position: relative;
      padding-block: 6px;
      color: var(--ink);
      font-size: var(--step--1);
      font-weight: 600;
      letter-spacing: 0.06em;
      text-decoration: none;
      text-transform: uppercase;
      white-space: nowrap;
      transition: color 0.15s;

      &::after {
        content: "";
        position: absolute;
        inset-inline: 0;
        inset-block-end: 0;
        block-size: 2px;
        border-radius: 1px;
        background: var(--brand);
        scale: 0 1;
        transition: scale 0.2s ease-out;
      }

      &:hover { color: var(--brand); &::after { scale: 1 1; } }
      &[aria-current="page"]::after { scale: 1 1; }
    }
  }

  .site-header__actions { grid-area: actions; justify-self: end; display: flex; align-items: center; gap: 10px; }

  @media (max-width: 1100px) {
    .site-header__bar {
      grid-template-columns: 1fr auto 1fr;
      grid-template-areas: "search logo cart" "nav nav nav";
      row-gap: 10px;
      padding-block: 10px 0;
    }
    .logo img { block-size: 40px; }
    .site-header__actions { display: contents; }
    .search-trigger { grid-area: search; justify-self: start; }
    .cart-button { grid-area: cart; justify-self: end; }
    .main-nav {
      justify-content: space-around;
      a { padding-block: 10px; }
    }
  }

  /* Phones: the menu scrolls sideways when its items do not fit, fading at the edge. */
  @media (max-width: 600px) {
    .main-nav {
      --fade-start: 0px;
      --fade-end: 28px;
      justify-content: flex-start;
      gap: 22px;
      margin-inline: calc(-1 * var(--gutter));
      padding-inline: var(--gutter);
      overflow-x: auto;
      scrollbar-width: none;
      &::-webkit-scrollbar { display: none; }
      mask-image: linear-gradient(to right, transparent, #000 var(--fade-start), #000 calc(100% - var(--fade-end)), transparent);
      @supports (animation-timeline: scroll()) { animation: chips-fade linear both; animation-timeline: scroll(self inline); }
    }
  }

  .site-footer {
    margin-block-start: 48px;
    background: var(--surface-soft);
    color: var(--ink-soft);
    font-size: var(--step--1);
  }

  .site-footer__inner {
    display: grid;
    grid-template-columns: 1.6fr repeat(3, 1fr);
    gap: 32px;
    padding-block: 48px 36px;

    @media (max-width: 900px) { grid-template-columns: 1fr 1fr; }
    @media (max-width: 520px) { grid-template-columns: 1fr; gap: 28px; }
  }

  .site-footer__brand {
    display: grid;
    align-content: start;
    gap: 12px;
    max-inline-size: 34ch;
    @media (max-width: 900px) { grid-column: 1 / -1; }
  }

  .site-footer__logo img { inline-size: 120px; block-size: auto; mix-blend-mode: multiply; }

  .site-footer__social {
    display: flex;
    gap: 8px;
    a {
      display: grid;
      place-items: center;
      inline-size: 36px;
      block-size: 36px;
      border-radius: 50%;
      background: var(--surface);
      color: var(--ink);
      transition: background-color 0.15s, color 0.15s;
      &:hover { background: var(--brand); color: var(--on-accent); }
    }
    svg { inline-size: 15px; }
  }

  .site-footer__col {
    display: grid;
    align-content: start;
    gap: 10px;
    h2 { margin-block-end: 4px; color: var(--ink); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
    a, .site-footer__link { color: var(--ink-soft); text-decoration: none; &:hover { color: var(--brand); text-decoration: underline; } }
  }

  .site-footer__link { padding: 0; border: 0; background: none; font: inherit; text-align: start; cursor: pointer; }

  .site-footer__bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    padding-block: 18px 24px;
    border-block-start: 1px solid rgb(0 0 0 / 0.06);
    color: var(--muted);
  }

  .payment-logos {
    display: flex;
    align-items: center;
    gap: 16px;
    opacity: 0.7;
    filter: grayscale(1);
  }
}

@layer components {
  .search-trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    inline-size: min(100%, 260px);
    padding: 9px 14px;
    border-radius: 999px;
    background: var(--surface-soft);
    color: var(--muted);
    font-size: var(--step--1);
    text-decoration: none;
    transition: background-color 0.15s, color 0.15s;
    svg { flex: none; inline-size: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
    span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
    &:hover { background: var(--surface-hover); color: var(--ink-soft); }

    @media (max-width: 1100px) {
      inline-size: 40px;
      block-size: 40px;
      padding: 0;
      justify-content: center;
      span { display: none; }
      svg { inline-size: 18px; }
    }
  }

  .cart-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    block-size: 40px;
    padding-inline: 14px 12px;
    border-radius: 999px;
    background: var(--surface-soft);
    color: var(--ink);
    font-size: var(--step--1);
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.15s;
    svg { flex: none; inline-size: 19px; block-size: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; stroke-linecap: round; }
    &:hover { background: var(--surface-hover); }

    @media (max-width: 480px) {
      position: relative;
      justify-content: center;
      inline-size: 40px;
      padding: 0;
      .cart-button__label { display: none; }
      .cart-count { position: absolute; inset-block-start: -4px; inset-inline-end: -6px; box-shadow: 0 0 0 2px var(--on-accent); }
    }
  }

  .cart-count {
    min-inline-size: 20px;
    padding-inline: 6px;
    border-radius: 10px;
    background: var(--buy);
    color: var(--on-accent);
    font-size: 0.75rem;
    font-weight: 600;
    text-align: center;
    line-height: 20px;
  }

  .button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 22px;
    border: 0;
    border-radius: var(--radius);
    background: var(--brand);
    color: var(--on-accent);
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.15s, transform 0.1s;

    &:active { transform: translateY(1px); }
  }

  .button--buy {
    background: var(--buy);
    min-inline-size: 150px;
    &:hover { background: var(--buy-hover); }
  }

  .button--muted { background: var(--muted); &:hover { background: var(--muted-strong); } }
  .button--small { padding: 5px 12px; font-size: var(--step--1); }

  input[type="checkbox"], input[type="radio"] {
    appearance: none;
    flex: none;
    display: inline-grid;
    place-content: center;
    inline-size: 20px;
    block-size: 20px;
    margin: 0;
    border: 1.5px solid var(--control);
    background: var(--surface);
    cursor: pointer;
    transition: background-color 0.15s, border-color 0.15s;

    &::before {
      content: "";
      inline-size: 12px;
      block-size: 12px;
      background: var(--surface);
      transform: scale(0);
      transition: transform 0.12s ease-out;
    }

    &:hover { border-color: var(--brand); }
    &:checked { background: var(--brand); border-color: var(--brand); }
    &:checked::before { transform: scale(1); }
    &:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
    &:disabled { opacity: 0.5; cursor: not-allowed; }
  }

  input[type="checkbox"] {
    border-radius: 5px;
    &::before { clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%); }
  }

  input[type="radio"] {
    border-radius: 50%;
    &::before { inline-size: 8px; block-size: 8px; border-radius: 50%; }
  }

  /* Standalone navigation links (with an arrow): underline only on hover.
     Links inside a sentence keep the default underline. */
  .nav-link {
    color: var(--muted);
    font-size: var(--step--1);
    text-decoration: none;
    &:hover, &:focus-visible { color: var(--brand); text-decoration: underline; }
    &:hover .arrow { translate: 3px 0; }
    &:hover .arrow--back { translate: -3px 0; }
  }

  /* The one arrow of the site (icons/arrow.html, arrow_back.html), centred on the text beside it. */
  .arrow {
    display: inline-block;
    inline-size: 1em;
    block-size: 1em;
    margin-inline-start: 0.35em;
    vertical-align: middle;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: translate 0.15s;
  }
  .arrow--back { margin-inline: 0 0.35em; }

  .brand-icon { fill: currentColor; stroke: none; }

  .badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: var(--radius);
    background: var(--surface-muted);
    color: var(--ink-soft);
    font-size: var(--step--1);
    font-weight: 600;
  }

  .page-title {
    margin-block-end: 16px;
    text-align: center;
    font-size: var(--step-1);
    font-weight: 700;
  }

  .section-title { margin-block: 32px 16px; text-align: center; font-size: var(--step-1); }

  .panel {
    padding: clamp(16px, 4vw, 32px);
    border: 1px solid var(--line);
    border-radius: var(--radius);
  }

  .prose {
    line-height: 1.7;
    > * + * { margin-block-start: 0.9em; }
    a { color: var(--muted); }
  }

  /* The grey band under the home slider: the storewide discount and the payment methods. */
  .promo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin: 0 0 28px;
    block-size: 60px;
    background: #e0e0e0;
    border-bottom: 1px solid #e0e0e0;
    color: #616161;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 1px;
    i { inline-size: 8px; block-size: 8px; border-radius: 50%; background: currentColor; opacity: 0.4; }
    @media (max-width: 768px) { block-size: 50px; gap: 15px; padding-inline: 10px; font-size: 12px; letter-spacing: 0.5px; i { inline-size: 6px; block-size: 6px; } }
    @media (max-width: 480px) { block-size: 40px; margin-block-end: 0; border: 0; padding-block: 5px; font-size: 10px; letter-spacing: 0.3px; text-align: center; }
  }

  /* Home banner slider: one wide picture per book, a slide at a time. Arrows (pointer devices
     only) sit on the sides, the dots over the bottom edge. */
  .hero { position: relative; overflow: hidden; margin-block: 5px 0; user-select: none; @media (max-width: 480px) { margin-block: -2px 0; } }
  .hero__track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    cursor: grab;
    &::-webkit-scrollbar { display: none; }
    &:focus-visible { outline: 2px solid var(--brand); outline-offset: -2px; }
    &[data-dragging] { cursor: grabbing; scroll-snap-type: none; a { pointer-events: none; } }
  }
  .hero__slide { flex: 0 0 100%; scroll-snap-align: start; img { display: block; inline-size: 100%; block-size: auto; } }
  .hero__arrow {
    position: absolute;
    inset-block-start: 50%;
    translate: 0 -50%;
    display: grid;
    place-items: center;
    inline-size: 40px;
    block-size: 40px;
    padding: 0;
    border: 1px solid #e0e0e0;
    border-radius: 50%;
    background: #fff;
    opacity: 0.8;
    cursor: pointer;
    transition: opacity 0.3s, background-color 0.3s, border-color 0.3s, scale 0.3s;
    &::before { content: ""; inline-size: 8px; block-size: 8px; border: solid #706f6f; border-width: 0 2px 2px 0; }
    &:hover { opacity: 1; background: #f8f9fa; border-color: #706f6f; scale: 1.1; }
    @media (hover: none), (max-width: 480px) { display: none; }
  }
  .hero__arrow--prev { inset-inline-start: 20px; &::before { rotate: 135deg; margin-inline-start: 3px; } }
  .hero__arrow--next { inset-inline-end: 20px; &::before { rotate: -45deg; margin-inline-end: 3px; } }
  .hero__dots { position: absolute; inset-block-end: 20px; inset-inline: 0; display: flex; justify-content: center; gap: 8px; pointer-events: none; @media (max-width: 480px) { inset-block-end: 10px; gap: 5px; } }
  .hero__dot {
    inline-size: 12px;
    block-size: 12px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 4px rgb(0 0 0 / 0.2);
    opacity: 0.8;
    cursor: pointer;
    pointer-events: auto;
    transition: scale 0.3s, opacity 0.3s;
    @media (max-width: 480px) { inline-size: 8px; block-size: 8px; }
    &:hover { opacity: 1; scale: 1.1; }
    &[aria-current] { background: #333; opacity: 1; scale: 1.2; box-shadow: 0 4px 8px rgb(0 0 0 / 0.2); }
  }

  .book-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr));
    gap: 36px 28px;
    padding: 0;
    list-style: none;

    @media (max-width: 600px) { grid-template-columns: repeat(2, 1fr); gap: 28px 14px; }
  }

  .book-grid--compact { grid-template-columns: repeat(auto-fill, minmax(min(100%, 180px), 1fr)); }

  .book-card {
    display: flex;
    flex-direction: column;
    gap: 4px;
    block-size: 100%;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--surface-soft);
    color: inherit;
    text-decoration: none;
    transition: background-color 0.2s, border-color 0.2s;

    &:hover {
      background: var(--surface-hover);
      border-color: var(--line-strong);
      .book-card__title { color: var(--brand); text-decoration: underline; text-underline-offset: 0.15em; }
    }
  }

  .book-card__cover {
    position: relative;
    display: block;
    aspect-ratio: 4 / 5;
    background: var(--surface);

    img {
      position: absolute;
      inset: 0;
      margin: auto;
      inline-size: auto;
      block-size: auto;
      max-inline-size: 72%;
      max-block-size: 82%;
      border-radius: 2px;
      box-shadow: 0 1px 2px rgb(0 0 0 / 0.08), 0 8px 20px rgb(0 0 0 / 0.14);
    }
  }

  /* The discount on a cover or a picture: top left, the same on every page. */
  .book-card__discount {
    z-index: 1;
    position: absolute;
    inset-block-start: 10px;
    inset-inline-start: 10px;
    padding: 2px 8px;
    border-radius: 999px;
    background: var(--sale);
    color: var(--on-accent);
    font-size: 0.75rem;
    font-weight: 700;
  }

  .book-card__body { display: flex; flex: 1; flex-direction: column; gap: 2px; padding: 14px 18px 18px; }
  .book-card__title { color: var(--ink); font-size: var(--step-0); font-weight: 600; line-height: 1.3; }
  .book-card__author { color: var(--muted); font-size: var(--step--1); }
  .book-card__foot {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 4px 10px;
    margin-block-start: auto;
    padding-block-start: 10px;
  }

  .book-card__price {
    display: flex;
    flex-direction: column;
    line-height: 1.25;
    font-variant-numeric: tabular-nums;
    del { color: var(--muted); font-size: 0.72rem; }
    strong { color: var(--ink); font-size: var(--step-0); }
  }
  .book-card__date { margin-inline-start: auto; color: var(--muted); font-size: 0.68rem; white-space: nowrap; }
  .book-card .badge { border-radius: 999px; padding-inline: 10px; }

  .catalog__bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 14px 24px;
    margin-block: -8px 28px;
  }

  .chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;

    /* Phones: one row that scrolls sideways, edge to edge. The edges fade where more chips
       are hidden: only the right at the start, both in the middle, only the left at the end. */
    @media (max-width: 719px) {
      --fade-start: 0px;
      --fade-end: 32px;
      position: relative;
      flex: 1 1 100%;
      flex-wrap: nowrap;
      min-inline-size: 0;
      margin-inline: calc(-1 * var(--gutter));
      padding-inline: var(--gutter);
      overflow-x: auto;
      overscroll-behavior-x: contain;
      scrollbar-width: none;
      &::-webkit-scrollbar { display: none; }
      mask-image: linear-gradient(to right, transparent, #000 var(--fade-start), #000 calc(100% - var(--fade-end)), transparent);
      .chip { flex: none; white-space: nowrap; }

      @supports (animation-timeline: scroll()) {
        animation: chips-fade linear both;
        animation-timeline: scroll(self inline);
      }
    }
  }

  @property --fade-start { syntax: "<length>"; inherits: false; initial-value: 0px; }
  @property --fade-end { syntax: "<length>"; inherits: false; initial-value: 32px; }
  @keyframes chips-fade {
    0% { --fade-start: 0px; --fade-end: 32px; }
    8% { --fade-start: 32px; }
    92% { --fade-end: 32px; }
    100% { --fade-start: 32px; --fade-end: 0px; }
  }

  .chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border-radius: 999px;
    background: var(--surface-soft);
    color: var(--ink);
    font-size: var(--step--1);
    font-weight: 500;
    text-decoration: none;
    transition: background-color 0.15s, color 0.15s;
    span { color: var(--muted); font-size: 0.75rem; font-variant-numeric: tabular-nums; }
    &:hover { background: var(--surface-hover); }
    &[aria-current="page"] { background: var(--brand); color: var(--on-accent); span { color: rgb(255 255 255 / 0.7); } }
  }

  /* The catalog's sort menu sits in the page header, across from the book count. */
  .catalog .shop-head {
    flex-wrap: nowrap;
    .shop-head__text { flex: 1 1 auto; min-inline-size: 0; }
    .sort-menu { flex: none; }
  }

  .sort-menu {
    position: relative;

    /* Phones: just "En yeni ⌄"; the label stays for screen readers. */
    @media (max-width: 600px) {
      .sort-menu__label { position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
    }

    summary {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      padding: 7px 12px 7px 14px;
      border-radius: 999px;
      background: var(--surface-soft);
      color: var(--muted);
      font-size: var(--step--1);
      list-style: none;
      cursor: pointer;
      user-select: none;
      &::-webkit-details-marker { display: none; }
      strong { color: var(--ink); font-weight: 600; }
      svg { flex: none; inline-size: 14px; block-size: 14px; fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: rotate 0.15s; }
      &:hover { background: var(--surface-hover); }
    }

    &[open] summary svg { rotate: 180deg; }

    ul {
      position: absolute;
      inset-block-start: calc(100% + 6px);
      inset-inline-end: 0;
      z-index: 20;
      display: grid;
      min-inline-size: 200px;
      margin: 0;
      padding: 6px;
      border-radius: 12px;
      background: var(--surface);
      box-shadow: 0 0 0 1px rgb(0 0 0 / 0.05), 0 12px 32px rgb(24 35 62 / 0.14);
      list-style: none;

    }

    a {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      padding: 8px 12px;
      border-radius: 8px;
      color: var(--ink);
      font-size: var(--step--1);
      text-decoration: none;
      &:hover { background: var(--surface-soft); }
      &[aria-current]::after { content: "✓"; color: var(--brand); font-weight: 700; }
      &[aria-current] { font-weight: 600; }
    }
  }


  .price {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 4px 12px;
  }

  .price__line { display: inline-flex; align-items: center; gap: 10px; }
  .price__now { font-size: var(--step-2); font-weight: 600; font-variant-numeric: tabular-nums; }
  .price__was { color: var(--muted); font-size: var(--step--1); font-variant-numeric: tabular-nums; }
  .price__save { color: var(--sale); font-weight: 600; }
  .price__off {
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--sale);
    color: var(--on-accent);
    font-size: 0.8rem;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
  }

  /* The book page: price and discount on the first line, the old price and the saving below. */
  .buy-box .price { flex-direction: column; align-items: start; gap: 2px; }

  .buy-box {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px 24px;

    .button--buy { min-inline-size: 180px; }

    @media (max-width: 719px) {
      position: fixed;
      inset-inline: 0;
      inset-block-end: 0;
      z-index: 15;
      block-size: var(--buy-bar-height);
      flex-wrap: nowrap;
      margin: 0;
      padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
      background: var(--surface);
      box-shadow: 0 -4px 16px rgb(0 0 0 / 0.1);
      .price__now { font-size: var(--step-1); }
      .price { gap: 0; }
      .price__line { gap: 8px; }
      .price__off { padding: 2px 8px; font-size: 0.75rem; }
      .price__off-word, .price__save { display: none; }
      .button--buy { min-inline-size: 140px; padding-block: 12px; }
    }
  }

  .stepper--large {
    button { inline-size: 44px; block-size: 44px; font-size: 1.3rem; }
    span { padding-inline: 10px; font-weight: 600; white-space: nowrap; }
  }

  .coming-soon {
    padding: 10px 14px;
    border-inline-start: 4px solid var(--warn);
    background: var(--warn-soft);
  }

  .empty-state { padding-block: 48px; text-align: center; > * + * { margin-block-start: 16px; } }
}

@layer pages {
  .book {
    display: grid;
    grid-template-columns: minmax(0, 300px) minmax(0, 1fr);
    grid-template-areas: "gallery info" "gallery about";
    grid-template-rows: auto 1fr;
    gap: 28px 56px;
    padding-block-start: 16px;

    @media (max-width: 860px) { grid-template-columns: 1fr; grid-template-areas: "gallery" "info" "about"; grid-template-rows: none; gap: 24px; }
  }

  .book__gallery {
    grid-area: gallery;
    align-self: start;
    display: grid;
    justify-items: center;
    gap: 14px;
    @media (min-width: 861px) { position: sticky; inset-block-start: 24px; }
  }

  .book__cover {
    inline-size: 100%;
    block-size: auto;
    box-shadow: 0 1px 3px rgb(0 0 0 / 0.12), 0 8px 24px rgb(0 0 0 / 0.1);
    @media (max-width: 860px) { inline-size: min(60vw, 240px); }
  }

  .book__preview { display: inline-flex; align-items: center; gap: 6px; svg { inline-size: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; } }

  .book__info { grid-area: info; display: flex; flex-direction: column; gap: 4px; min-inline-size: 0; }

  .book__crumbs {
    display: flex;
    gap: 8px;
    margin-block-end: 8px;
    color: var(--muted);
    font-size: var(--step--1);
    a { color: inherit; text-decoration: none; &:hover { color: var(--brand); text-decoration: underline; } }
  }

  .book__title { font-size: var(--step-2); font-weight: 600; line-height: 1.25; color: var(--ink); }
  .book__subtitle { color: var(--ink-soft); font-size: var(--step-0); }
  .book__authors {
    color: var(--ink-soft);
    a { color: var(--brand); text-decoration: none; &:hover { text-decoration: underline; } }
  }

  .book__purchase {
    margin-block: 20px 4px;
    padding-block: 18px;
    border-block: 1px solid var(--line);
    @media (max-width: 719px) { margin: 0; padding: 0; border: 0; }
  }

  .book__cookie-notice { margin: 14px 0 0; font-size: var(--step--1); }

  .book__perks {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 18px;
    margin: 14px 0 0;
    padding: 0;
    color: var(--ink-soft);
    font-size: var(--step--1);
    list-style: none;
    li { display: inline-flex; align-items: center; gap: 6px; }
    li::before { content: ""; flex: none; inline-size: 10px; block-size: 10px; background: var(--ornament); clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%); }
    @media (max-width: 719px) { margin-block-start: 4px; }
  }

  .book__facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 24px;
    margin: 20px 0 0;
    padding: 20px 24px;
    border-radius: 16px;
    background: var(--surface-soft);
    > dl { display: grid; align-content: start; gap: 14px; margin: 0; min-inline-size: 0; }
    dl > div { display: grid; gap: 2px; min-inline-size: 0; }
    dt { color: var(--muted); font-size: 0.75rem; }
    dd { margin: 0; font-size: var(--step--1); font-weight: 500; overflow-wrap: anywhere; }
    @media (max-width: 340px) { grid-template-columns: 1fr; }
    @media (max-width: 719px) { padding: 18px; }
  }

  .book__about {
    grid-area: about;
    display: grid;
    align-content: start;
    gap: 32px;
    max-inline-size: 72ch;
    .prose p + p { margin-block-start: 14px; }
    .prose { line-height: 1.75; }
  }

  .book-grid--related {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px 20px;
    @media (max-width: 600px) { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 14px; }
  }

  .press__list { display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; }

  .press__item {
    display: grid;
    gap: 8px;
    padding: 16px 20px;
    border-inline-start: 3px solid var(--brand);
    border-radius: 0 12px 12px 0;
    background: var(--surface-soft);
  }

  .press__quote { margin: 0; line-height: 1.6; }

  .press__source {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 12px;
    color: var(--muted);
    font-size: var(--step--1);
    cite { color: var(--ink); font-weight: 600; }
  }

  /* Share: one row of round icon buttons beside the heading; Goodreads below as an arrow link. */
  .share {
    display: grid;
    gap: 14px;
    padding-block: 20px;
    border-block: 1px solid var(--line);
  }

  .share__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; }
  .share__title { font-size: var(--step-0); font-weight: 600; }
  .share__list { display: flex; align-items: center; gap: 10px; margin: 0; padding: 0; list-style: none; }

  .share__link {
    position: relative;
    display: grid;
    place-items: center;
    inline-size: 44px;
    block-size: 44px;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: var(--surface);
    color: var(--ink);
    font: inherit;
    cursor: pointer;
    transition: background-color 0.15s, border-color 0.15s, color 0.15s;
    svg { inline-size: 18px; block-size: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
    .brand-icon { fill: currentColor; stroke: none; }
    &:hover, &:focus-visible { border-color: var(--brand); background: var(--brand); color: var(--on-accent); }
  }

  /* The copy button's name, shown as a small bubble once the link is copied. */
  .share__tip { position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .share__link[data-copied] .share__tip {
    inset-block-end: calc(100% + 8px);
    inset-inline-start: 50%;
    translate: -50% 0;
    inline-size: auto;
    block-size: auto;
    padding: 4px 10px;
    border-radius: 6px;
    background: var(--ink);
    color: var(--on-accent);
    font-size: 0.75rem;
    clip-path: none;
  }

  .share__goodreads {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    justify-self: start;
    font-size: var(--step--1);
    line-height: 1;
    .brand-icon { flex: none; inline-size: 16px; block-size: 16px; fill: currentColor; }
    .arrow { margin: 0; }
  }

  .book__section-title { margin-block-end: 10px; font-size: var(--step-0); font-weight: 600; }

  .author {
    display: grid;
    gap: 24px;
    align-items: start;
    @media (min-width: 769px) { grid-template-columns: 180px 1fr; gap: 48px; padding: 40px; }
  }

  .author__body { display: grid; gap: 32px; }

  .author-books {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 32px;

    li { inline-size: clamp(130px, 30%, 200px); }

    a {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 12px;
      color: var(--muted);
      text-align: center;
      &:hover span { color: var(--brand); }
    }

    img { padding: 5px; background: var(--surface); box-shadow: var(--shadow-cover); }
  }

  .author__photo {
    inline-size: min(180px, 60vw);
    justify-self: center;
    padding: 5px;
    box-shadow: var(--shadow-cover);
  }

  .author-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-inline: clamp(0px, 3vw, 40px);

    @media (max-width: 1024px) { grid-template-columns: repeat(2, 1fr); gap: 20px; }
    @media (max-width: 480px) { grid-template-columns: 1fr; }
  }

  .author-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 24px 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    text-decoration: none;
    transition: box-shadow 0.2s;

    img { inline-size: min(100%, 180px); aspect-ratio: 1; object-fit: cover; box-shadow: var(--shadow-cover); padding: 4px; }
    &:hover { box-shadow: 0 6px 18px rgb(0 0 0 / 0.08); }
  }

  .author-card__name { font-weight: 600; text-align: center; }

}

@layer pages {
  .consent {
    position: fixed;
    inset: auto 16px 16px;
    z-index: 30;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 24px;
    inline-size: fit-content;
    max-inline-size: calc(100% - 32px);
    margin-inline: auto;
    padding: 14px 18px;
    border-radius: 12px;
    background: var(--surface);
    box-shadow: 0 8px 30px rgb(0 0 0 / 0.18);
    font-size: var(--step--1);
  }

  .consent__actions {
    display: flex;
    gap: 10px;
    @media (max-width: 520px) { flex: 1 1 100%; .button { flex: 1; } }
  }

  .toast {
    position: fixed;
    inset-block-end: 20px;
    inset-inline: 0;
    display: grid;
    justify-items: center;
    pointer-events: none;
    z-index: 20;
  }

  .toast__body {
    pointer-events: auto;
    padding: 12px 18px;
    border-radius: var(--radius);
    background: var(--brand);
    color: var(--on-accent);
    box-shadow: 0 8px 24px rgb(0 0 0 / 0.2);
    animation: toast-in 0.2s ease-out;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 16px;
    font-size: var(--step-0);
    line-height: 1.3;
    a { color: var(--on-accent); font-weight: 600; }
  }

  .toast__actions {
    display: flex;
    align-items: center;
    gap: 8px;

    a {
      display: inline-flex;
      align-items: center;
      min-block-size: 34px;
      padding-inline: 8px;
      border-radius: var(--radius);
    }
  }

  @media (max-width: 719px) {
    body:has(.buy-box) {
      --buy-bar-height: calc(72px + env(safe-area-inset-bottom));
      padding-block-end: var(--buy-bar-height);
    }

    body:has(.buy-box) .toast {
      inset-block-end: var(--buy-bar-height);
      justify-items: stretch;
    }

    body:has(.buy-box) .toast__body {
      justify-content: space-between;
      padding: 12px 16px;
      border-radius: 0;
      box-shadow: 0 -4px 16px rgb(0 0 0 / 0.12);
    }
  }
  .toast__primary {
    padding-inline: 14px;
    background: var(--buy);
    text-decoration: none;
  }

  @keyframes toast-in { from { opacity: 0; transform: translateY(10px); } }

  .notice {
    margin-block-end: 16px;
    padding: 10px 14px;
    border-radius: var(--radius);
    background: var(--warn-soft);
    border-inline-start: 4px solid var(--warn);
  }

  .notice--ok { background: var(--ok-soft); border-color: var(--buy); }

  .alert {
    margin-block-end: 16px;
    padding: 10px 14px;
    border-radius: var(--radius);
    background: var(--sale-soft);
    border-inline-start: 4px solid var(--sale);
  }

  .field-error { display: block; margin-block-start: 4px; color: var(--sale); font-size: var(--step--1); }
  .hint { color: var(--muted); font-size: var(--step--1); }

  .link-button {
    padding: 0;
    border: 0;
    background: none;
    color: var(--muted);
    text-decoration: underline;
    cursor: pointer;
    font-size: var(--step--1);
  }

  .button--wide { inline-size: 100%; margin-block-start: 12px; }
  .button:disabled { opacity: 0.6; cursor: wait; }

  .cart { max-inline-size: 1100px; margin-inline: auto; }

  .empty-cart {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px 20px;
    padding: 20px 24px;
    border-radius: var(--radius);
    background: var(--surface-soft);
  }

  .empty-cart__icon {
    flex: none;
    inline-size: 28px;
    padding: 12px;
    border-radius: 50%;
    background: var(--surface);
    fill: none;
    stroke: var(--muted);
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    box-sizing: content-box;
  }

  .empty-cart__text { flex: 1 1 260px; color: var(--ink-soft); }
  .empty-cart__title { color: var(--ink); font-size: var(--step-1); }

  @media (max-width: 600px) {
    .empty-cart { padding: 18px; }
    .empty-cart__icon { display: none; }
    .empty-cart .button { inline-size: 100%; }
  }

  .qty {
    display: inline-block;
    margin-inline-start: 4px;
    padding: 1px 7px;
    border-radius: 999px;
    background: var(--surface-soft);
    color: var(--ink-soft);
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
    vertical-align: 1px;
  }

  .button--icon {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    svg { inline-size: 14px; fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; }
  }

  .button--ghost {
    background: transparent;
    color: var(--brand);
    box-shadow: inset 0 0 0 1px var(--line);
    &:hover { background: var(--surface-soft); }
  }

  .suggestions { margin-block-start: 32px; }
  .suggestions__head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-block-end: 16px; }
  .suggestions__title { font-size: var(--step-2); font-weight: 700; letter-spacing: -0.01em; }
  .shop-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px 32px;
    margin-block: 8px 28px;
    padding-block-end: 20px;
    border-block-end: 1px solid var(--line);
  }

  .shop-head__title { font-size: var(--step-3); font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; }
  .shop-head__subtitle { margin-block-start: 6px; color: var(--muted); strong { color: var(--ink); font-weight: 600; } }

  .steps {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0;
    list-style: none;
    color: var(--muted);
    font-size: var(--step--1);
    font-weight: 500;
  }

  .steps__item {
    display: flex;
    align-items: center;
    gap: 8px;
    & + &::before { content: ""; inline-size: 28px; block-size: 1px; margin-inline-end: 0; background: var(--line); }
  }

  .steps__dot {
    display: grid;
    place-items: center;
    inline-size: 24px;
    block-size: 24px;
    border: 1.5px solid var(--line);
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: 700;
  }

  .steps__item--current { color: var(--ink); .steps__dot { border-color: var(--brand); background: var(--brand); color: var(--on-accent); } }
  .steps__item--done { color: var(--ink-soft); .steps__dot { border-color: var(--buy); background: var(--buy); color: var(--on-accent); } }
  .steps__dot svg { inline-size: 14px; fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }

  @media (max-width: 600px) {
    .shop-head { margin-block-start: 0; padding-block-end: 16px; }
    .shop-head__title { font-size: var(--step-2); }
    .steps { inline-size: 100%; }
  }

  .cart__layout {
    display: grid;
    gap: 24px;
    align-items: start;
    @media (min-width: 900px) { grid-template-columns: 1fr 320px; gap: 40px; }
  }

  .cart__summary {
    display: grid;
    gap: 14px;
    @media (min-width: 900px) { position: sticky; inset-block-start: 16px; }
  }

  .shipping-progress {
    padding-block: 4px 12px;
    p { margin-block-end: 8px; }
  }

  .shipping-progress__track {
    position: relative;
    display: block;
    margin-block-start: 14px;
    margin-inline-end: 28px;
  }

  .shipping-progress__truck {
    position: absolute;
    inset-block-start: -22px;
    inset-inline-start: var(--progress, 0%);
    inline-size: 28px;
    translate: -50% 0;
    svg { display: block; inline-size: 100%; fill: var(--warn); transition: fill 0.4s; }
    circle { fill: var(--ink); }
  }

  .shipping-progress--done .shipping-progress__truck svg { fill: var(--buy); }

  .shipping-progress__bar {
    display: block;
    block-size: 6px;
    border-radius: 3px;
    background: var(--line);
    overflow: hidden;

    span {
      display: block;
      inline-size: var(--progress, 0%);
      block-size: 100%;
      background: var(--warn);
      border-radius: inherit;
      transition: background-color 0.4s;
    }
  }

  .shipping-progress--done .shipping-progress__bar span { background: var(--buy); }

  .cart-lines { display: grid; margin-block: 8px 16px; }

  .cart-line {
    display: grid;
    grid-template-columns: 64px 1fr auto 96px 36px;
    grid-template-areas: "cover info stepper total remove";
    gap: 8px 16px;
    align-items: center;
    padding-block: 16px;
    border-block-end: 1px solid var(--line);

    @media (max-width: 600px) {
      grid-template-columns: 64px 1fr 36px;
      grid-template-areas: "cover info remove" "cover stepper total";
      align-items: start;
      .cart-line__stepper { align-self: end; }
      .cart-line__total { align-self: end; padding-block-end: 6px; }
    }
  }

  .cart-line__cover {
    grid-area: cover;
    img { inline-size: 64px; block-size: 96px; object-fit: cover; box-shadow: var(--shadow-cover); }
  }

  .cart-line__info { grid-area: info; display: flex; flex-direction: column; gap: 4px; min-inline-size: 0; }
  .cart-line__title { font-weight: 600; line-height: 1.35; text-decoration: none; &:hover { text-decoration: underline; } }
  .cart-line__unit { color: var(--ink-soft); font-size: var(--step--1); del { color: var(--muted); } }
  .cart-line__stepper { grid-area: stepper; }
  .cart-line__total { grid-area: total; justify-self: end; font-size: var(--step-0); }
  .cart-line__remove { grid-area: remove; justify-self: end; }

  .icon-button {
    display: grid;
    place-items: center;
    inline-size: 32px;
    block-size: 32px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: none;
    color: var(--muted);
    cursor: pointer;
    svg {
      inline-size: 18px;
      fill: none;
      stroke: currentColor;
      stroke-width: 1.75px;
      stroke-linecap: round;
      vector-effect: non-scaling-stroke;
      shape-rendering: geometricPrecision;
    }
    path { vector-effect: non-scaling-stroke; }
    &:hover { background: var(--surface-muted); color: var(--sale); }
  }

  .stepper {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    border: 1px solid var(--line);
    border-radius: var(--radius);

    button {
      inline-size: 34px;
      block-size: 34px;
      border: 0;
      background: var(--surface-soft);
      cursor: pointer;
      font-size: 1.1rem;
      &:disabled { opacity: 0.4; cursor: default; }
    }
    span { min-inline-size: 34px; text-align: center; font-weight: 600; }
  }

  .stepper--large span { min-inline-size: 72px; }

  .upsell {
    margin-block-end: 16px;
    padding: 16px;
    border-radius: var(--radius);
    background: var(--warn-soft);
  }

  .upsell__head { display: grid; grid-template-columns: 92px 1fr; align-items: center; gap: 16px; margin-block-end: 16px; }

  .upsell__icon {
    display: grid;
    flex: none;
    place-items: center;
    justify-self: center;
    inline-size: 44px;
    block-size: 44px;
    border-radius: 50%;
    background: var(--warn);
    svg { inline-size: 24px; fill: var(--on-accent); }
    circle { fill: var(--ink); }
  }

  .upsell__title {
    font-size: var(--step-2);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.02em;
    mark {
      padding-inline: 2px;
      background: linear-gradient(transparent 58%, var(--highlight) 58%, var(--highlight) 92%, transparent 92%);
      color: inherit;
    }
  }
  .upsell__text { margin-block-start: 4px; color: var(--ink-soft); font-size: var(--step--1); strong { color: var(--ink); font-weight: 700; } }

  .upsell__list { display: grid; gap: 14px; }

  .upsell__item {
    display: grid;
    grid-template-columns: 92px 1fr auto;
    gap: 16px;
    align-items: center;
  }

  @media (max-width: 600px) {
    .upsell__item { grid-template-columns: 92px 1fr; }
    .upsell__item form { grid-column: 1 / -1; }
    .upsell__item .button { inline-size: 100%; }
    .upsell__item:nth-child(n + 3) { display: none; }
  }

  .upsell__covers {
    display: flex;
    justify-content: center;
    a + a { position: relative; margin-inline-start: -20px; }
  }

  .upsell__cover img {
    inline-size: 56px;
    block-size: 84px;
    object-fit: cover;
    border: 1px solid rgb(0 0 0 / 0.08);
    border-radius: 2px;
    box-shadow: 0 1px 2px rgb(0 0 0 / 0.08), 0 4px 10px rgb(0 0 0 / 0.12);
  }

  .upsell__info { display: flex; flex-direction: column; gap: 2px; min-inline-size: 0; }
  .upsell__line { font-size: var(--step--1); line-height: 1.35; }
  .upsell__name { font-weight: 500; text-decoration: none; &:hover { text-decoration: underline; } }
  .upsell__and { color: var(--muted); font-style: italic; }
  .upsell__meta { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; margin-block-start: 4px; }
  .upsell__price { color: var(--muted); font-size: var(--step--1); font-variant-numeric: tabular-nums; white-space: nowrap; strong { color: var(--ink); font-weight: 500; } }
  .badge--discount { background: var(--sale); color: var(--on-accent); font-size: 0.7rem; font-weight: 600; }

  .badge--ok {
    padding: 0;
    background: none;
    color: var(--ok-ink);
    font-size: var(--step--1);
    font-weight: 500;
    &::before { content: "✓ "; }
  }



  .totals__saving { color: var(--buy); }

  .trust {
    padding-block-start: 12px;
    border-block-start: 1px solid var(--line);
    color: var(--muted);
    font-size: var(--step--1);
    line-height: 1.5;
  }

  .trust__title {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-block-end: 6px;
    color: var(--ink-soft);
    font-weight: 600;
    svg { flex: none; inline-size: 14px; fill: none; stroke: currentColor; stroke-width: 2; }
  }

  .trust__methods {
    display: grid;
    gap: 4px;
    padding: 0;
    list-style: none;

    li {
      display: flex;
      align-items: center;
      gap: 8px;
      &::before {
        content: "";
        flex: none;
        inline-size: 12px;
        block-size: 12px;
        background: var(--buy);
        clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
      }
    }
  }

  .checkout-bar { display: none; }

  .checkout-bar__method {
    color: var(--ink-soft);
    span { display: none; }
  }

  .checkout__form:has([name="payment_method"][value="iyzico"]:checked) .checkout-bar__method [data-for="iyzico"],
  .checkout__form:has([name="payment_method"][value="ptt"]:checked) .checkout-bar__method [data-for="ptt"],
  .checkout__form:has([name="payment_method"][value="bank_transfer"]:checked) .checkout-bar__method [data-for="bank_transfer"] { display: inline; }

  @media (max-width: 899px) {
    .checkout-bar {
      position: fixed;
      inset-inline: 0;
      inset-block-end: 0;
      z-index: 15;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
      background: var(--surface);
      box-shadow: 0 -4px 16px rgb(0 0 0 / 0.1);
    }
    .checkout-bar__total { display: flex; flex-direction: column; line-height: 1.2; small { color: var(--muted); } strong { font-size: var(--step-1); } }
    .checkout-bar .button { min-inline-size: 160px; padding-block: 12px; }
    /* The room the fixed bar covers belongs to the footer, so its colour runs down to the bar. */
    body:has(.checkout-bar) .site-footer { padding-block-end: calc(88px + env(safe-area-inset-bottom)); }
  }

  .totals {
    display: grid;
    grid-template-columns: 1fr auto;
    row-gap: 6px;
    dd { text-align: end; padding-inline-start: 16px; }
  }

  .totals__grand { padding-block-start: 8px; border-block-start: 1px solid var(--line); font-weight: 700; font-size: var(--step-1); }

  .checkout { max-inline-size: 1100px; margin-inline: auto; }

  .checkout__form {
    display: grid;
    gap: 24px;
    align-items: start;
    @media (min-width: 900px) {
      grid-template-columns: 1fr 340px;
      gap: 40px;
      .checkout__summary { position: sticky; inset-block-start: 16px; }
    }
  }

  .checkout__main { display: grid; gap: 20px; }
  .checkout__summary { display: grid; gap: 14px; }

  .checkout-step__title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-block-end: 16px;
    font-size: var(--step-1);

    span {
      display: grid;
      place-items: center;
      inline-size: 28px;
      block-size: 28px;
      border-radius: 50%;
      background: var(--brand);
      color: var(--on-accent);
      font-size: var(--step--1);
    }
  }

  .fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
    gap: 12px 16px;
    margin-block: 8px 12px;

    label { display: flex; flex-direction: column; gap: 4px; font-size: var(--step--1); color: var(--ink-soft); }
    input, textarea {
      padding: 9px 10px;
      border: 1px solid var(--line-strong);
      border-radius: var(--radius);
      font-size: var(--step-0);
      color: var(--ink);
      &:focus-visible { outline: 2px solid var(--brand); outline-offset: 0; border-color: var(--brand); }
    }
  }

  .fields__wide { grid-column: 1 / -1; }

  .fields--pairs {
    grid-template-columns: 1fr 1fr;
    @media (max-width: 560px) { grid-template-columns: 1fr; }
  }

  .check { display: flex; gap: 10px; align-items: start; margin-block: 8px; cursor: pointer; input { margin-block-start: 2px; } }

  .card-fields { display: none; }

  .invoice {
    margin: 20px 0 0;
    padding: 20px 0 0;
    border: 0;
    border-block-start: 1px solid var(--line);
  }

  .invoice__legend { float: left; inline-size: 100%; margin-block-end: 10px; padding: 0; font-weight: 600; }
  .invoice__choice { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; clear: both; }

  .invoice__box {
    display: none;
    margin-block-start: 14px;
    padding: 16px 18px 18px;
    border-radius: var(--radius);
    background: var(--surface-soft);
  }

  .invoice:has([name="corporate_invoice"][value="1"]:checked) .invoice__box { display: block; }
  .invoice__title { margin-block-end: 10px; font-weight: 600; }
  .field-hint { color: var(--muted); font-size: 0.75rem; }
  .checkout__form:has([name="payment_method"][value="ptt"]:checked) .card-fields {
    display: grid;
    margin-block-start: 16px;
    padding: 16px;
    border-radius: var(--radius);
    background: var(--surface-soft);
  }

  .methods { display: grid; gap: 8px; }

  .method {
    display: flex;
    gap: 10px;
    align-items: start;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    cursor: pointer;
    span { display: flex; flex-direction: column; }
    small { color: var(--muted); }
    &:has(input:checked) { border-color: var(--brand); background: var(--surface-soft); }
    input { margin-block-start: 2px; }
  }

  .section-heading { font-size: var(--step-0); margin-block-end: 10px; }

  .summary-lines {
    display: grid;
    gap: 6px;
    margin-block: 8px 12px;
    grid-template-columns: 1fr auto auto;
    column-gap: 12px;
    font-size: var(--step--1);
    li { display: grid; grid-template-columns: subgrid; grid-column: 1 / -1; align-items: start; }
    li > :last-child { text-align: end; }
    .qty { margin: 0; justify-self: start; }
  }

  .panel.result { max-inline-size: 640px; margin-inline: auto; > * + * { margin-block-start: 12px; } }
  .panel.result--pending { border-inline-start: 4px solid var(--warn); }

  .result__card {
    display: grid;
    justify-items: center;
    gap: 14px;
    max-inline-size: 680px;
    margin-inline: auto;
    padding: 40px 32px 32px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface);
    box-shadow: 0 1px 2px rgb(0 0 0 / 0.04), 0 12px 32px rgb(24 35 62 / 0.06);
    text-align: center;
  }

  .result__icon {
    inline-size: 72px;
    fill: none;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    circle { stroke-dasharray: 151; stroke-dashoffset: 151; animation: draw 0.6s ease-out forwards; }
    path { stroke-dasharray: 40; stroke-dashoffset: 40; animation: draw 0.35s 0.5s ease-out forwards; }
  }

  .result__icon--ok { stroke: var(--buy); circle { fill: var(--ok-soft); } }
  .result__icon--fail { stroke: var(--sale); circle { fill: var(--sale-soft); } }

  @keyframes draw { to { stroke-dashoffset: 0; } }

  @media (prefers-reduced-motion: reduce) {
    .result__icon circle, .result__icon path { animation: none; stroke-dashoffset: 0; }
  }

  .result__spinner {
    inline-size: 56px;
    block-size: 56px;
    border: 4px solid var(--line);
    border-block-start-color: var(--brand);
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
  }

  @keyframes spin { to { rotate: 1turn; } }

  .result__title { font-size: var(--step-2); font-weight: 700; letter-spacing: -0.01em; }
  .result__lead { max-inline-size: 46ch; color: var(--ink-soft); }
  .result__note { max-inline-size: 46ch; color: var(--muted); font-size: var(--step--1); }

  .result__facts {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    inline-size: 100%;
    margin-block: 8px;
    > div {
      display: grid;
      justify-items: center;
      gap: 2px;
      padding: 14px 10px;
      border-radius: 10px;
      background: var(--surface-soft);
    }
    svg { inline-size: 20px; margin-block-end: 4px; fill: none; stroke: var(--muted); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
    dt { color: var(--muted); font-size: 0.75rem; }
    dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; }
  }


  .result__books {
    display: grid;
    gap: 10px;
    inline-size: 100%;
    padding: 0;
    list-style: none;
    li { display: grid; grid-template-columns: 40px 1fr auto; align-items: center; gap: 14px; text-align: start; font-size: var(--step--1); }
    li > span { display: contents; }
    img { inline-size: 40px; block-size: 60px; object-fit: cover; border-radius: 2px; box-shadow: 0 1px 2px rgb(0 0 0 / 0.08), 0 4px 10px rgb(0 0 0 / 0.12); }
    a { text-decoration: none; &:hover { text-decoration: underline; } }
    .qty { justify-self: end; }
  }



  .timeline {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    inline-size: 100%;
    margin-block: 12px 4px;
    padding: 0;
    list-style: none;
    color: var(--muted);
    font-size: var(--step--1);
  }

  .timeline__step {
    position: relative;
    display: grid;
    justify-items: center;
    gap: 8px;
    &::before {
      content: "";
      position: relative;
      z-index: 1;
      inline-size: 14px;
      block-size: 14px;
      border: 2px solid var(--line);
      border-radius: 50%;
      background: var(--surface);
    }
    & + &::after {
      content: "";
      position: absolute;
      inset-block-start: 6px;
      inset-inline: -50% 50%;
      block-size: 2px;
      background: var(--line);
    }
  }

  .timeline__step--done { color: var(--ink); &::before { border-color: var(--buy); background: var(--buy); } }
  .timeline__step--current {
    color: var(--ink);
    font-weight: 600;
    &::before { border-color: var(--buy); box-shadow: 0 0 0 4px var(--ok-soft); }
    &::after { background: var(--buy) !important; }
  }

  .result__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-block-start: 8px; }

  @media (max-width: 600px) {
    .result__card { padding: 28px 18px 22px; }
    .result__facts { gap: 6px; > div { padding: 12px 4px; } dd { font-size: var(--step--1); } }
    .result__actions .button { inline-size: 100%; }
  }

  .bank {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 6px 16px;
    dt { color: var(--ink-soft); }
    code { font-size: var(--step-0); }
  }

  .order-status { max-inline-size: 640px; margin-inline: auto; > .panel > * + * { margin-block-start: 14px; } }

  .lookup {
    display: grid;
    gap: 12px;
    label { display: flex; flex-direction: column; gap: 4px; font-size: var(--step--1); color: var(--ink-soft); }
    input { padding: 9px 10px; border: 1px solid var(--line-strong); border-radius: var(--radius); }
  }
}

@layer pages {
  .content-page { max-inline-size: 760px; margin-inline: auto; }

  .legal {
    font-size: var(--step--1);
    h2 { margin-block: 20px 8px; font-size: var(--step-0); }
    ul { padding-inline-start: 20px; }
  }

  .contact__layout {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
    gap: 16px;
    align-items: start;
    @media (max-width: 800px) { grid-template-columns: 1fr; }
  }

  .contact__ways { display: grid; gap: 12px; padding: 0; list-style: none; }

  .contact-way {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 16px;
    padding: 18px 20px;
    border-radius: 12px;
    background: var(--surface-soft);
    color: inherit;
    text-decoration: none;
    transition: background-color 0.15s, translate 0.15s;
    &:hover { background: var(--surface-hover); .contact-way__go { translate: 3px 0; color: var(--brand); } }
  }

  .contact-way__icon {
    display: grid;
    place-items: center;
    inline-size: 44px;
    block-size: 44px;
    border-radius: 50%;
    background: var(--surface);
    svg { inline-size: 22px; fill: none; stroke: var(--brand); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
  }

  .contact-way__text {
    display: grid;
    gap: 2px;
    min-inline-size: 0;
    small { color: var(--muted); font-size: 0.75rem; }
    strong { font-weight: 600; overflow-wrap: anywhere; }
    address { font-style: normal; font-weight: 600; line-height: 1.45; }
  }

  .contact-way--static { grid-template-columns: auto 1fr; &:hover { background: var(--surface-soft); } }

  .contact-way__go { display: flex; color: var(--muted); font-size: 1.1rem; transition: translate 0.15s, color 0.15s; .arrow { margin: 0; } }

  .contact__side { display: grid; gap: 12px; }

  .contact-tile {
    padding: 18px 20px;
    border-radius: 12px;
    background: var(--surface-soft);
  }

  .contact-tile__title { margin-block-end: 10px; font-size: var(--step-0); font-weight: 700; }
  .contact-tile__text { color: var(--ink-soft); font-size: var(--step--1); }
  .contact-tile__links { display: grid; justify-items: start; gap: 6px; margin-block-start: 10px; }

  .hours {
    display: grid;
    gap: 8px;
    margin: 0;
    > div { display: flex; justify-content: space-between; gap: 12px; }
    dt { color: var(--ink-soft); }
    dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
  }

  .hours__closed dd { color: var(--muted); font-weight: 500; }

  .contact__social { margin-block-start: 28px; }
  .contact__social-title { margin-block-end: 10px; color: var(--ink-soft); font-size: var(--step-0); font-weight: 400; }
  .social { display: flex; flex-wrap: wrap; gap: 10px; }

  .social__pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    background: var(--surface-soft);
    color: var(--ink);
    font-size: var(--step--1);
    font-weight: 500;
    text-decoration: none;
    &:hover { background: var(--surface-hover); }
    svg { inline-size: 15px; }
  }

  .faq-group { margin-block-end: 28px; }

  .faq-group__title {
    margin-block-end: 10px;
    color: var(--muted);
    font-size: var(--step--1);
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
  }

  .faq {
    display: grid;
    gap: 10px;

    details {
      border: 1px solid var(--line);
      border-radius: 10px;
      background: var(--surface);
      transition: border-color 0.15s, background-color 0.15s;
      &:hover { border-color: var(--line-strong); }
      &[open] { border-color: var(--line-strong); background: var(--surface-soft); }
    }

    summary {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      gap: 16px;
      padding: 16px 20px;
      font-weight: 600;
      line-height: 1.45;
      cursor: pointer;
      list-style: none;
      border-radius: 10px;
      &::-webkit-details-marker { display: none; }
      &:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

      &::after {
        content: "+";
        flex: none;
        display: grid;
        place-items: center;
        inline-size: 26px;
        block-size: 26px;
        margin-block: -2px;
        border-radius: 50%;
        background: var(--surface-muted);
        color: var(--brand);
        font-size: 1.1rem;
        font-weight: 500;
        line-height: 1;
        transition: background-color 0.15s, color 0.15s;
      }
    }

    details[open] summary::after { content: "−"; background: var(--brand); color: var(--on-accent); }

    .faq__answer {
      padding: 0 20px 18px;
      color: var(--ink-soft);
      line-height: 1.65;
      a { color: var(--brand); font-weight: 500; }
    }

    @media (max-width: 600px) {
      summary { padding: 14px 16px; }
      .faq__answer { padding: 0 16px 16px; }
    }
  }

  .faq-help {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px 24px;
    margin-block-start: 36px;
    padding: 22px 24px;
    border-radius: 12px;
    background: var(--surface-soft);
  }

  .faq-help__title { font-size: var(--step-1); font-weight: 700; }
  .faq-help__text { margin-block-start: 4px; color: var(--ink-soft); }
  .faq-help__links { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 20px; }

  @media (max-width: 600px) {
    .faq-help__links { inline-size: 100%; .button { inline-size: 100%; } }
  }

  /* The section heads carry their own line, so the page header drops its line and gap. */
  .site-map .shop-head { margin-block-end: 24px; padding-block-end: 0; border: 0; @media (max-width: 600px) { margin-block-end: 16px; } }
  .site-map__group { margin-block-end: 36px; }

  .site-map__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    margin-block-end: 8px;
    padding-block-end: 10px;
    border-block-end: 1px solid var(--line);
  }

  .site-map__title {
    color: var(--muted);
    font-size: var(--step--1);
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
  }

  .site-map__count {
    margin-inline-start: 6px;
    padding: 1px 8px;
    border-radius: 999px;
    background: var(--surface-muted);
    color: var(--ink-soft);
    font-size: 0.75rem;
    letter-spacing: 0;
  }

  .site-map__list {
    columns: 3 200px;
    column-gap: 32px;
    padding: 0;
    list-style: none;

    li { break-inside: avoid; }

    a {
      display: block;
      padding-block: 7px;
      color: var(--ink);
      line-height: 1.4;
      text-decoration: none;
      transition: color 0.15s;
      &:hover, &:focus-visible { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }
    }
  }

  .modal {
    inline-size: min(100% - 32px, 760px);
    max-block-size: 85vh;
    margin: auto;
    padding: 0;
    border: 0;
    border-radius: 8px;
    box-shadow: 0 20px 50px rgb(0 0 0 / 0.25);
    &::backdrop { background: rgb(24 35 62 / 0.45); }
    &[open] { display: flex; flex-direction: column; }
  }

  .modal__head, .modal__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 20px;
  }

  .modal__head { padding-inline-end: 64px; border-block-end: 1px solid var(--line); h2 { font-size: var(--step-1); } }
  .modal__foot { justify-content: flex-end; border-block-start: 1px solid var(--line); }
  .modal__body { flex: 1; overflow-y: auto; padding: 16px 20px; overscroll-behavior: contain; outline: none; }

  .modal--book {
    position: relative;
    inline-size: min(100% - 24px, 720px);
    .modal__body { padding: 28px; scrollbar-gutter: stable; }
  }

  .modal__close { position: absolute; inset-block-start: 10px; inset-inline-end: 10px; z-index: 1; background: var(--surface); }

  .preview {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 28px;
    align-items: start;
  }

  .preview__cover { inline-size: 100%; block-size: auto; aspect-ratio: 2 / 3; object-fit: cover; background: var(--surface-soft); box-shadow: var(--shadow-cover); }
  .preview__info { display: flex; flex-direction: column; gap: 8px; min-inline-size: 0; }
  .preview__title { font-size: var(--step-2); line-height: 1.2; padding-inline-end: 36px; }
  .preview__subtitle { color: var(--ink-soft); font-style: italic; }
  .preview__authors { color: var(--muted); }
  .preview__price { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: var(--step-1); del { color: var(--muted); font-size: var(--step-0); } }
  .preview__ship { color: var(--ok-ink); font-weight: 600; font-size: var(--step--1); }
  .preview__text { color: var(--ink-soft); font-size: var(--step--1); line-height: 1.6; p + p { margin-block-start: 8px; } }
  .preview__meta { color: var(--muted); font-size: var(--step--1); }
  .preview__actions { display: flex; align-items: center; flex-wrap: wrap; gap: 16px; margin-block-start: 8px; }

  @media (max-width: 600px) {
    .modal--book {
      inline-size: 100%;
      max-inline-size: 100%;
      max-block-size: 90vh;
      margin: auto 0 0;
      border-radius: 16px 16px 0 0;
      .modal__body { padding: 20px; }
    }
    .preview { grid-template-columns: 1fr; gap: 16px; }
    .preview__cover { inline-size: 120px; }
    .preview__title { font-size: var(--step-1); }
    .preview__actions .button { inline-size: 100%; }
    .preview__actions form { flex: 1 1 100%; }
  }

  .search-dialog {
    inline-size: min(100% - 24px, 640px);
    max-block-size: min(80vh, 640px);
    margin: 12vh auto auto;
    padding: 0;
    border: 0;
    border-radius: 16px;
    background: var(--surface);
    box-shadow: 0 24px 64px rgb(24 35 62 / 0.28);
    &::backdrop { background: rgb(24 35 62 / 0.4); backdrop-filter: blur(2px); }
    &[open] { display: flex; flex-direction: column; }

    @media (max-width: 600px) { inline-size: 100%; max-inline-size: 100%; max-block-size: 100dvh; margin: 0; border-radius: 0 0 16px 16px; }
  }

  .search-box {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px 14px 20px;
    border-block-end: 1px solid var(--line);

    svg { flex: none; inline-size: 20px; fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; }
    input {
      flex: 1;
      min-inline-size: 0;
      padding: 6px 0;
      border: 0;
      background: none;
      font: inherit;
      font-size: var(--step-1);
      outline: none;
      &::-webkit-search-cancel-button { display: none; }
    }
  }

  .search-box--page {
    margin-block-end: 20px;
    border: 0;
    border-radius: 12px;
    background: var(--surface-soft);
  }

  .search-box__close {
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
    kbd { display: inline-block; padding: 3px 8px; border-radius: 6px; background: var(--surface-soft); color: var(--muted); font: 600 0.7rem/1.4 inherit; font-family: inherit; }
    span { display: none; color: var(--brand); font-size: var(--step--1); font-weight: 600; }
    @media (hover: none) { kbd { display: none; } span { display: inline; } }
  }

  .search-dialog__results { overflow-y: auto; padding: 8px; overscroll-behavior: contain; }
  .search-hint { padding: 18px 14px; color: var(--muted); font-size: var(--step--1); }
  .search-group { padding: 10px 12px 4px; color: var(--muted); font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
  .search-list { display: grid; padding: 0; list-style: none; }

  .search-item {
    display: grid;
    grid-template-columns: 40px 1fr auto;
    align-items: center;
    gap: 14px;
    padding: 8px 12px;
    border-radius: 10px;
    color: var(--ink);
    text-decoration: none;
    outline: none;
    &:hover, &:focus-visible, &[aria-selected="true"] { background: var(--surface-soft); }
  }

  .search-item__thumb {
    display: grid;
    place-items: center;
    inline-size: 40px;
    img { inline-size: 36px; block-size: 54px; object-fit: cover; border-radius: 2px; box-shadow: 0 1px 2px rgb(0 0 0 / 0.1), 0 4px 10px rgb(0 0 0 / 0.12); }
  }

  .search-item__thumb--round img { inline-size: 40px; block-size: 40px; border-radius: 50%; box-shadow: none; }
  .search-item__text { display: grid; min-inline-size: 0; strong { font-weight: 600; } small { color: var(--muted); font-size: var(--step--1); } }
  .search-item__covers {
    display: flex;
    opacity: 0.7;
    transition: opacity 0.15s;
    img { inline-size: 26px; block-size: 39px; object-fit: cover; border-radius: 2px; box-shadow: 0 0 0 1.5px var(--on-accent), 0 2px 6px rgb(0 0 0 / 0.15); }
    img + img { margin-inline-start: -8px; }
  }

  .search-item:hover .search-item__covers, .search-item[aria-selected="true"] .search-item__covers { opacity: 1; }

  .search-item__price { color: var(--ink-soft); font-size: var(--step--1); font-variant-numeric: tabular-nums; white-space: nowrap; }

}

@layer utilities {
  .visually-hidden {
    position: absolute !important;
    inline-size: 1px;
    block-size: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }

  .skip-link {
    position: absolute;
    inset-inline-start: 8px;
    inset-block-start: -40px;
    padding: 8px 12px;
    background: var(--brand);
    color: var(--on-accent);
    z-index: 10;
    &:focus { inset-block-start: 8px; }
  }

}
