/* Panel klienta — „Your orders”.
 *
 * Tokeny to marka ze strony głównej (css/desktop.css:38-59) w spokojniejszym
 * wariancie nieba ze stron approve/feedback. Jedyny głośny element strony to
 * półka z książkami stojącymi okładką do przodu (.ledge); reszta ma być cicha.
 */

:root {
  --sky-1: #EAF3FB;
  --sky-paper: #F7FBFF;
  --ink: #33414F;
  --ink-soft: #4A5A78;
  /* #6B7A90 z feedback.css ma na tym tle 4.1:1 — za mało na drobny tekst. */
  --ink-muted: #5F6E85;
  --head-blue: #1F4E79;
  --gold: #B08A3E;
  --gold-soft: #E7C77F;
  --gold-ink: #5C4212;
  --plum: #503A55;
  --line: rgba(31, 78, 121, .12);
  --glass-bg: rgba(255, 255, 255, .42);
  --glass-border: rgba(255, 255, 255, .65);
  --glass-shadow: 0 20px 50px rgba(120, 80, 90, .14), inset 0 1px 0 rgba(255, 255, 255, .85);
  --maxw: 1080px;
  --book: 168px;
  color-scheme: light;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  min-height: 100vh;
  font-family: 'Nunito Sans', system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background:
    radial-gradient(110% 50% at 12% 0%, #D9EAFA 0%, rgba(217, 234, 250, 0) 62%),
    linear-gradient(180deg, var(--sky-1) 0%, var(--sky-paper) 38%, #FFFFFF 100%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
}
body.has-tray { padding-bottom: 110px; }
h1, h2, h3.serif { font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 600; line-height: 1.1; color: var(--head-blue); }
a { color: inherit; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }
.muted { color: var(--ink-muted); font-size: 15px; }

:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 6px; }

/* ---------------------------------------------------------------- przyciski */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font: 800 .95rem/1.2 'Nunito Sans', system-ui, sans-serif; letter-spacing: .01em;
  padding: .74em 1.45em; border-radius: 99px; cursor: pointer; text-decoration: none; white-space: nowrap;
  color: #fff; border: 1px solid rgba(255, 255, 255, .6);
  background: linear-gradient(160deg, rgba(94, 147, 196, .92), rgba(46, 109, 164, .95));
  box-shadow: 0 10px 24px rgba(46, 109, 164, .3);
  transition: transform .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 14px 30px rgba(46, 109, 164, .4); }
.btn.gold {
  color: var(--gold-ink);
  background: linear-gradient(160deg, rgba(231, 199, 127, .95), rgba(214, 167, 74, .97));
  box-shadow: 0 10px 24px rgba(214, 167, 74, .35);
}
.btn.gold:hover { box-shadow: 0 14px 30px rgba(214, 167, 74, .45); }
.btn.ghost { color: var(--ink); background: rgba(255, 255, 255, .6); border-color: rgba(31, 78, 121, .14); box-shadow: none; }
.btn.ghost:hover { background: #fff; }
.btn.sm { font-size: .86rem; padding: .58em 1.15em; }

.link {
  font: inherit; font-weight: 700; color: var(--head-blue); background: none; border: 0; padding: 0; cursor: pointer;
  text-decoration: underline; text-decoration-color: rgba(31, 78, 121, .3); text-underline-offset: 3px;
}
.link:hover { text-decoration-color: currentColor; }
/* Anulowanie zamówienia: ta sama waga co inne akcje w rzędzie, ale kolorem
   mówi, że to nie jest zmiana szczegółu (account.js action()). */
.link.danger { color: #9B1C2E; text-decoration-color: rgba(155, 28, 46, .3); }

/* --------------------------------------------------------------------- nav */

.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .55);
  backdrop-filter: blur(20px) saturate(1.5); -webkit-backdrop-filter: blur(20px) saturate(1.5);
  border-bottom: 1px solid rgba(255, 255, 255, .7);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 70px; gap: 16px; }
.brand img { height: 62px; width: auto; display: block; }
/* Jak w css/desktop.css (nagłówek strony głównej): ten sam przycisk, ta sama cena. */
.nav .wrap { max-width: 1180px; } /* szerokość nagłówka z /, treść panelu zostaje 1080 px */
.nav-cta { display: flex; align-items: center; gap: 18px; }
.nav .btn {
  padding: .55em 1.25em; font-size: 1rem; line-height: normal; /* jak <button> na / */
  background: linear-gradient(160deg, rgba(94, 147, 196, .88), rgba(46, 109, 164, .92));
  box-shadow: 0 12px 30px rgba(46, 109, 164, .35);
}
.nav .btn:hover { transform: translateY(-2px); box-shadow: 0 16px 36px rgba(46, 109, 164, .45); }
.nav-price { font: 600 .95rem 'Cormorant Garamond', Georgia, serif; color: var(--ink-soft); white-space: nowrap; }
.nav-email { font-size: .95rem; font-weight: 700; color: var(--ink-soft); max-width: 26ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-cta .link { font-size: .95rem; font-weight: 700; white-space: nowrap; }
/* Grupa bez własnego pudełka: e-mail i „Sign out” dzielą odstępy nav-cta z ceną i przyciskiem. */
.nav-user { display: contents; }

/* ------------------------------------------------------------------ okładka */

/* Twarda okładka widziana z przodu: ciemniejszy grzbiet z lewej, krawędź
   kartek z prawej. Rozmiar daje rodzic przez width; reszta jest w cqi, żeby
   pusta okładka skalowała napis razem z książką. */
.book {
  position: relative; aspect-ratio: 1; width: 100%; container-type: inline-size;
  border-radius: 3px 7px 7px 3px; background: #FBF8F1;
  box-shadow:
    3px 1px 0 -1px #F3EEE2, 5px 2px 0 -2px #E0D6C2,
    0 16px 22px -14px rgba(40, 50, 80, .5), 0 2px 5px rgba(40, 50, 80, .16);
}
.book img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.book::before {
  content: ""; position: absolute; inset: 0 auto 0 0; width: 7%; border-radius: 3px 0 0 3px; z-index: 1;
  background: linear-gradient(90deg, rgba(0, 0, 0, .2), rgba(255, 255, 255, .28) 45%, rgba(0, 0, 0, .06) 75%, transparent);
}
/* Książka, której jeszcze nie ma: akwarelowa plama zamiast okładki. */
.book.blank {
  display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  /* Procent, nie cqi: cqi własnego paddingu liczy się do kontenera PRZODKA,
     a bez niego do szerokości okna — okładka rosła wtedy do 300px. */
  padding: 10%;
  background:
    radial-gradient(circle at 28% 24%, rgba(231, 199, 127, .55), rgba(231, 199, 127, 0) 52%),
    radial-gradient(circle at 76% 72%, rgba(127, 169, 220, .45), rgba(127, 169, 220, 0) 58%),
    #FBF8F1;
}
.book.blank b { font: italic 500 15cqi/1.05 'Cormorant Garamond', Georgia, serif; color: var(--head-blue); }
.book.blank small { margin-top: 4cqi; font-size: max(11px, 7.5cqi); line-height: 1.3; font-weight: 700; color: var(--ink-soft); }

/* Miejsce na książkę, której jeszcze nie ma (pusty panel). */
.book.ghost { background: rgba(255, 255, 255, .35); border: 2px dashed rgba(176, 138, 62, .45); box-shadow: none; }
.book.ghost::before { display: none; }

/* Zakładka-wstążka wystająca spod książki, jak w prawdziwym wydaniu: znak,
   że książka idzie do druku, i ile kopii. Spod, nie z góry — u góry okładki
   jest tytuł. */
.ribbon {
  position: absolute; bottom: -30px; right: 16%; z-index: 2; width: 30px; height: 44px;
  display: flex; justify-content: center; align-items: flex-end; padding-bottom: 13px;
  font-size: 12px; font-weight: 800; color: var(--gold-ink);
  background: linear-gradient(180deg, #D3A957, #E9CB86);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 80%, 0 100%);
  filter: drop-shadow(0 2px 2px rgba(92, 66, 18, .25));
}

/* ------------------------------------------------------- nagłówek sytuacji */

.lead {
  display: grid; grid-template-columns: 236px minmax(0, 1fr); gap: 48px; align-items: center;
  padding: 56px 0 8px;
}
/* Okładka w nagłówku stoi na krótkim odcinku tej samej półki co niżej. */
.lead-book .book { width: 200px; margin: 0 18px -3px; }
.lead-book .board { border-radius: 4px 4px 6px 6px; }
.lead h1 { font-size: clamp(2.1rem, 3.6vw, 2.6rem); max-width: 22ch; letter-spacing: -.01em; }
.lead p { margin-top: 12px; max-width: 48ch; font-size: 19px; color: var(--ink-soft); }
.lead .actions { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 14px 22px; align-items: center; }
.lead.no-cover { grid-template-columns: minmax(0, 1fr); }

/* ---------------------------------------------------------------- sekcje */

.panel section + section { margin-top: 64px; }
.panel h2 { font-size: 1.7rem; margin-bottom: 18px; }

/* --------------------------------------------------------------- zamówienia */

.sheet {
  background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: 22px;
  box-shadow: var(--glass-shadow);
  backdrop-filter: blur(24px) saturate(1.5); -webkit-backdrop-filter: blur(24px) saturate(1.5);
}
.order {
  display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; column-gap: 22px; row-gap: 16px;
  padding: 24px 28px;
}
.order + .order { border-top: 1px solid var(--line); }
.order .book { width: 64px; }
.o-main { align-self: center; min-width: 0; }
.o-title { font: 600 1.32rem/1.2 'Cormorant Garamond', Georgia, serif; color: var(--ink); }
.o-meta { margin-top: 3px; font-size: 14.5px; color: var(--ink-muted); }
.o-side { align-self: center; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; text-align: right; }
.o-status { font-size: 15px; font-weight: 800; color: var(--head-blue); }
.o-status.act { color: var(--gold-ink); }
.o-status.warn { color: var(--plum); }
.o-status.off { color: var(--ink-muted); }
.o-wide { grid-column: 2 / -1; min-width: 0; }
.o-detail { margin-top: 12px; font-size: 15px; color: var(--ink-soft); }
.o-detail:first-child { margin-top: 0; }
.more { margin-top: 16px; font-size: 15px; }
.copies-of { font-size: 15px; color: var(--ink-soft); }

/* Oś kroków. To prawdziwa sekwencja, więc ma kroki; etykiety znikają na
   telefonie na rzecz jednego zdania „Step 3 of 6”. */
.steps { list-style: none; display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); }
.steps li {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 8px;
  font-size: 13px; line-height: 1.25; text-align: center; color: var(--ink-muted);
}
.steps li::before {
  content: ""; position: absolute; top: 6px; right: 50%; width: 100%; height: 2px; background: #D3DDE9; z-index: 0;
}
.steps li:first-child::before { display: none; }
.steps .dot {
  position: relative; z-index: 1; width: 14px; height: 14px; border-radius: 50%;
  background: #fff; border: 2px solid #B9C7D8;
}
.steps .done::before, .steps .now::before { background: var(--head-blue); }
.steps .done .dot { background: var(--head-blue); border-color: var(--head-blue); }
.steps .now { color: var(--ink); font-weight: 800; }
.steps .now .dot { border: 4px solid var(--head-blue); box-shadow: 0 0 0 4px rgba(31, 78, 121, .14); }
.steps.act .now .dot { border-color: var(--gold); box-shadow: 0 0 0 4px rgba(214, 167, 74, .25); }
.steps.warn .now .dot { border-color: var(--plum); box-shadow: 0 0 0 4px rgba(80, 58, 85, .16); }
.steps-now { display: none; font-size: 14px; font-weight: 700; color: var(--ink); }

/* -------------------------------------------------------------------- półka */

.shelf-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 24px; margin-bottom: 8px; }
.shelf-head h2 { margin-bottom: 0; }
.shelf-head p { font-size: 15.5px; color: var(--ink-soft); }

/* Na szerokim ekranie półki stoją jedna nad drugą jak na ścianie: siatka
   rozciąga elementy do pełnego rzędu, więc odcinki deski łączą się w jedną.
   Na telefonie jeden rząd przewijany w bok (niżej, w @media). */
.ledge-scroll { padding: 26px 0 8px; }
.ledge { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(calc(var(--book) + 44px), 1fr)); row-gap: 34px; }
.ledge li { display: flex; flex-direction: column; min-width: 0; }

.pick { position: relative; display: block; width: var(--book); margin: 0 22px -3px; }
.pick input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.pick .book { transition: transform .28s cubic-bezier(.3, .7, .3, 1), box-shadow .28s; }
.pick.can { cursor: pointer; }
.pick.can:hover .book { transform: translateY(-3px); }
.ledge li.on .pick .book {
  transform: translateY(-12px);
  box-shadow:
    3px 1px 0 -1px #F3EEE2, 5px 2px 0 -2px #E0D6C2,
    0 26px 30px -16px rgba(40, 50, 80, .55), 0 4px 8px rgba(40, 50, 80, .14);
}
.pick input:focus-visible + .book { outline: 3px solid var(--gold); outline-offset: 5px; }
.veil {
  position: absolute; inset: 0; z-index: 1; border-radius: 3px 7px 7px 3px;
  display: flex; align-items: flex-end; justify-content: center; padding-bottom: 12px;
  background: rgba(247, 251, 255, .5);
}
.veil span {
  padding: 4px 12px; border-radius: 99px; font-size: 12.5px; font-weight: 800; color: var(--head-blue);
  background: rgba(255, 255, 255, .9); box-shadow: 0 2px 8px rgba(31, 78, 121, .15);
}

/* Deska: każdy element listy rysuje swój odcinek, więc półka rośnie razem
   z liczbą książek i przewija się z nimi. Jasny wierzch, ciemniejsza krawędź. */
.board {
  /* −1px zakrywa szparę po zaokrągleniu kolumn 1fr między odcinkami. */
  height: 20px; margin-right: -1px;
  background: linear-gradient(180deg, #EEDBAE 0, #DFC287 9px, #C9A35A 9px, #AE8638 100%);
  box-shadow: 0 16px 16px -10px rgba(92, 66, 18, .28);
}
.cap { padding: 14px 22px 0; }
.cap b { display: block; font-size: 15px; font-weight: 800; color: var(--ink); }
.cap i { display: block; font: italic 500 1.05rem/1.25 'Cormorant Garamond', Georgia, serif; color: var(--ink-soft); }
.cap .link { margin-top: 6px; font-size: 14px; }

/* Jeden zaplanowany ruch na stronie: książki osiadają na półce. */
@keyframes settle { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
.ledge.settle .pick { animation: settle .5s cubic-bezier(.3, .7, .3, 1) both; animation-delay: calc(var(--i) * 70ms); }

.shelf-empty { padding: 8px 0 0; color: var(--ink-soft); }

/* ------------------------------------------------------------------- konto */

.acct { padding-bottom: 72px; }
.acct-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px 48px; }
.acct h3 { font-size: 15px; font-weight: 800; color: var(--ink); margin-bottom: 6px; }
.acct p { font-size: 16px; }
.acct .muted { margin-top: 6px; }
.addr-list { list-style: none; display: flex; flex-direction: column; gap: 10px; font-size: 16px; }

/* ------------------------------------------------------------------- pasek */

.tray {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
  background: rgba(255, 255, 255, .86);
  backdrop-filter: blur(22px) saturate(1.5); -webkit-backdrop-filter: blur(22px) saturate(1.5);
  border-top: 1px solid var(--gold-soft);
  box-shadow: 0 -12px 30px rgba(40, 50, 80, .12);
  animation: rise .28s cubic-bezier(.3, .7, .3, 1);
}
@keyframes rise { from { transform: translateY(100%); } to { transform: none; } }
.tray-inner { display: flex; align-items: center; gap: 18px; min-height: 80px; padding-top: 12px; padding-bottom: 12px; }
.tray-covers { display: flex; padding-left: 4px; }
.tray-covers .book { width: 44px; }
.tray-covers .book + .book { margin-left: -16px; }
.tray-text { flex: 1; font-weight: 700; font-size: 16px; }
.tray .link { font-size: 15px; }

/* --------------------------------------------------------------- dialogi */

dialog { border: 0; padding: 0; color: var(--ink); background: transparent; max-width: calc(100vw - 32px); }
dialog::backdrop { background: rgba(70, 60, 100, .35); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.dlg {
  width: 540px; margin: auto; border-radius: 26px; max-height: calc(100vh - 32px); overflow: auto;
  background: rgba(255, 255, 255, .94);
  border: 1px solid rgba(255, 255, 255, .8);
  box-shadow: 0 30px 70px rgba(40, 40, 80, .35);
}
.dlg[open] { animation: pop .22s ease; }
@keyframes pop { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.dlg-x { position: absolute; top: 14px; right: 16px; }
.dlg-close {
  width: 34px; height: 34px; border-radius: 50%; cursor: pointer; font-size: 14px; font-weight: 800; color: var(--ink-muted);
  background: rgba(255, 255, 255, .8); border: 1px solid rgba(31, 78, 121, .14);
}
.dlg-close:hover { color: var(--ink); background: #fff; }
.dlg-body { padding: 30px 32px 28px; }
.dlg h3 { font: 600 1.75rem/1.15 'Cormorant Garamond', Georgia, serif; color: var(--head-blue); padding-right: 36px; }
.dlg .sub { margin-top: 6px; font-size: 15.5px; color: var(--ink-soft); }

.copy-list { list-style: none; margin: 22px 0 6px; }
.copy-list li {
  display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 4px 16px; align-items: center;
  padding: 12px 0; border-top: 1px solid var(--line);
}
.copy-list .book { width: 52px; grid-row: span 2; }
.copy-list b { font: 600 1.12rem/1.2 'Cormorant Garamond', Georgia, serif; color: var(--ink); }
.copy-list small { font-size: 14px; color: var(--ink-muted); grid-column: 2; }
.stepper { display: flex; align-items: center; gap: 10px; grid-row: span 2; }
.stepper button {
  width: 34px; height: 34px; border-radius: 50%; cursor: pointer; font: 800 18px/1 'Nunito Sans', sans-serif;
  color: var(--head-blue); background: #fff; border: 1px solid rgba(31, 78, 121, .2);
}
.stepper button:disabled { color: #B9C7D8; cursor: default; }
.stepper output { min-width: 1.4em; text-align: center; font-weight: 800; font-variant-numeric: tabular-nums; }

.ship { border: 0; margin-top: 18px; }
.ship legend { font-size: 15px; font-weight: 800; margin-bottom: 10px; }
.ship-opt {
  display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; margin-bottom: 8px; cursor: pointer;
  border: 1px solid rgba(31, 78, 121, .14); border-radius: 14px; background: rgba(255, 255, 255, .7); font-size: 15px; line-height: 1.45;
}
.ship-opt:has(input:checked) { border-color: var(--gold); background: #FFFCF3; }
.ship-opt input { margin-top: 4px; accent-color: var(--head-blue); }
.ship-new { margin-top: 6px; }
.fld { display: block; margin-bottom: 14px; }
.fld[hidden] { display: none; }
.fld > span { display: block; font-size: 14px; font-weight: 700; color: var(--ink-soft); margin-bottom: 6px; }
.fld input {
  width: 100%; padding: 12px 14px; border: 1px solid rgba(31, 78, 121, .18); border-radius: 13px;
  font: 600 1rem 'Nunito Sans', sans-serif; color: var(--ink); background: rgba(255, 255, 255, .85); outline: none;
}
.fld input:focus { border-color: #8FB6D9; box-shadow: 0 0 0 4px rgba(143, 182, 217, .25); }
.fld-row { display: grid; grid-template-columns: 1.4fr 1fr; gap: 0 14px; }

.total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); font-weight: 700; }
.total strong { font-size: 1.35rem; font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; }
.dlg-foot { display: flex; justify-content: flex-end; gap: 12px; margin-top: 22px; }

.reader {
  width: min(1120px, calc(100vw - 32px)); height: min(780px, calc(100vh - 32px)); margin: auto;
  border-radius: 22px; overflow: hidden;
  background: linear-gradient(180deg, var(--sky-1), var(--sky-paper));
  box-shadow: 0 30px 70px rgba(40, 40, 80, .35);
}
.reader iframe { width: 100%; height: 100%; border: 0; display: block; }
.reader-close { position: absolute; top: 14px; right: 16px; z-index: 2; }

/* ----------------------------------------------------------------- logowanie */

.gate { min-height: calc(100vh - 70px); display: grid; place-items: center; padding: 40px 16px 80px; }
.gate-card {
  width: 100%; max-width: 27rem; padding: 34px 34px 30px; border-radius: 24px;
  background: rgba(255, 255, 255, .6); border: 1px solid var(--glass-border); box-shadow: var(--glass-shadow);
  backdrop-filter: blur(24px) saturate(1.5); -webkit-backdrop-filter: blur(24px) saturate(1.5);
}
.gate-card h1 { font-size: 2rem; }
.gate-card > p { margin: 10px 0 22px; font-size: 16px; color: var(--ink-soft); }
.gate-card .btn { width: 100%; margin-top: 4px; }
.gate-card .code { font-size: 26px; font-weight: 800; letter-spacing: .3em; text-align: center; font-variant-numeric: tabular-nums; }
.gate-err { margin: -4px 0 12px; font-size: 14.5px; font-weight: 700; color: #9B1C2E; }
/* Pytanie o adres, nie błąd: złoto zamiast czerwieni gate-err, bo nic nie jest zablokowane. */
.addr-doubt { margin: 0 0 12px; padding: 12px 14px; border-radius: 12px; font-size: 14.5px; line-height: 1.5;
  color: var(--gold-ink); background: rgba(231, 199, 127, .22); border: 1px solid var(--gold-soft); }
.addr-doubt[hidden], .addr-doubt-btns button[hidden] { display: none; }
.addr-doubt p { margin: 0; }
.addr-doubt-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }

.gate-alt { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; margin-top: 18px; font-size: 15px; }
.gate-notice { margin-top: 12px; text-align: center; font-size: 14.5px; color: var(--head-blue); }

/* -------------------------------------------------------------- responsywność */

@media (max-width: 960px) {
  .lead { grid-template-columns: 188px minmax(0, 1fr); gap: 32px; }
  .lead-book .book { width: 160px; margin: 0 14px -3px; }
  .nav-email, .nav-price { display: none; }
}

@media (max-width: 560px) {
  :root { --book: 128px; }
  .wrap { padding: 0 16px; }
  .brand img { height: 44px; }
  .nav-cta { gap: 12px; }
  /* Z „Sign out” obok przycisk nie mieści się przy 360 px w pełnym rozmiarze ze strony głównej,
     a ściskane byłoby logo (ACC-24), więc na telefonie jest mniejszy. */
  .nav .btn { font-size: .88rem; padding: .5em 1em; }
  .nav-cta .link { font-size: .88rem; }

  .lead { grid-template-columns: minmax(0, 1fr); gap: 22px; padding: 30px 0 4px; }
  .lead-book { width: 128px; }
  .lead-book .book { width: 112px; margin: 0 8px -3px; }
  .lead-book .board { height: 14px; background: linear-gradient(180deg, #EEDBAE 0, #DFC287 6px, #C9A35A 6px, #AE8638 100%); }
  .lead h1 { font-size: 1.75rem; }
  .lead p { font-size: 16.5px; }
  .lead .actions .btn { width: 100%; }

  .panel section + section { margin-top: 48px; }
  .order { grid-template-columns: 48px minmax(0, 1fr); column-gap: 14px; row-gap: 12px; padding: 18px 16px; }
  .order .book { width: 48px; }
  .o-side { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; justify-content: space-between; align-items: center; text-align: left; }
  .o-wide { grid-column: 1 / -1; }
  .steps li { font-size: 0; gap: 0; }
  .steps-now { display: block; margin-top: 10px; }

  .ledge-scroll { overflow-x: auto; scroll-snap-type: x proximity; margin: 0 -16px; padding-left: 16px; padding-right: 16px; scrollbar-width: none; }
  .ledge { display: flex; width: max-content; min-width: 100%; }
  .ledge li { width: calc(var(--book) + 28px); scroll-snap-align: start; }
  .ledge li:last-child { flex-grow: 1; }
  .pick { margin: 0 14px -3px; }
  .cap { padding: 12px 14px 0; }

  .acct-grid { grid-template-columns: 1fr; }

  .tray-covers { display: none; }
  .tray-inner { gap: 12px; }
  .tray-text { font-size: 14.5px; }
  .tray .btn { font-size: .86rem; padding: .66em 1.1em; }

  .dlg-body { padding: 26px 18px 22px; }
  .copy-list li { grid-template-columns: 44px minmax(0, 1fr); }
  .copy-list .book { width: 44px; grid-row: span 3; }
  .copy-list small { grid-row: 2; }
  .stepper { grid-row: 3; grid-column: 2; margin-top: 6px; }
  .dlg-foot .btn { flex: 1; }
  .reader { width: 100vw; height: 100dvh; max-width: 100vw; max-height: 100dvh; border-radius: 0; }
}

/* ----------------------------------------------------- komunikaty i dane */

.notice {
  margin: 22px 0 0; padding: 12px 18px; border-radius: 14px; font-weight: 700; color: var(--head-blue);
  background: var(--glass-bg); border: 1px solid var(--glass-border);
}
.hello { margin: 0 0 6px; font-weight: 800; color: var(--gold-ink); letter-spacing: .02em; }
.o-ship { margin-top: 2px; font-size: 14.5px; color: var(--ink-muted); }
.cap-acts { display: flex; flex-wrap: wrap; gap: 4px 14px; }
.name-form { margin-top: 18px; }
.name-form .btn { margin-right: 10px; }
.saved { font-size: 14px; font-weight: 800; color: #2E7D4F; }
.addr-list li { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; }
.addr-acts { display: flex; gap: 12px; flex-shrink: 0; font-size: 14px; }
#addrAdd { margin-top: 12px; }
.fld select {
  width: 100%; padding: 12px 10px; border: 1px solid rgba(31, 78, 121, .18); border-radius: 13px;
  font: 600 1rem 'Nunito Sans', sans-serif; color: var(--ink); background: rgba(255, 255, 255, .85); outline: none;
}
.fld select:focus { border-color: #8FB6D9; box-shadow: 0 0 0 4px rgba(143, 182, 217, .25); }
.fld-row3 { display: grid; grid-template-columns: 1.4fr .8fr 1fr; gap: 0 14px; }
/* Kraje bez kodu albo regionu: wiersz ma mniej komórek (applyCountry()), bez pustego miejsca. */
.fld-row3.cells-2 { grid-template-columns: 1.4fr 1fr; }
.fld-row3.cells-1 { grid-template-columns: 1fr; }
@media (max-width: 560px) {
  .fld-row3 { grid-template-columns: 1fr 1fr; }
  .fld-row3 .fld:first-child { grid-column: 1 / -1; }
  .fld-row3.cells-1 { grid-template-columns: 1fr; }
}

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

/* Co się stanie po anulowaniu — w oknie potwierdzenia (index.html #cancelDlg). */
.cancel-what { list-style: none; margin: 18px 0 14px; padding: 0; }
.cancel-what li {
  position: relative; padding: 0 0 0 22px; margin-bottom: 8px; font-size: 15px; line-height: 1.5;
}
.cancel-what li::before {
  content: '·'; position: absolute; left: 6px; top: -2px; font-size: 22px; color: var(--gold, #b08a3e);
}
.cancel-what li:last-child { font-weight: 700; }
