/* YDS Kelime: calm, low-glare, dyslexia-friendly styles. iPad first. */

/* ---------- Fonts (self-hosted so the app works offline) ---------- */
@font-face { font-family: "Lexend"; src: url("../fonts/lexend-latin.woff2") format("woff2"); font-weight: 100 900; font-display: swap;
  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; }
@font-face { font-family: "Lexend"; src: url("../fonts/lexend-latin-ext.woff2") format("woff2"); font-weight: 100 900; font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Atkinson Hyperlegible"; src: url("../fonts/atkinson-latin.woff2") format("woff2"); font-weight: 200 800; font-display: swap;
  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; }
@font-face { font-family: "Atkinson Hyperlegible"; src: url("../fonts/atkinson-latin-ext.woff2") format("woff2"); font-weight: 200 800; font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

/* ---------- Tokens ---------- */
:root {
  --bg: #FAF8F2; --ink: #2B2B2B; --ink-2: #5C574D; --surface: #FFFDF8; --sunk: #F3EEE2;
  --line: #E7E0D0; --line-2: #D5CBB6;
  --accent: #2F6F6A; --accent-2: #255A56; --accent-soft: #DCECE9; --on-accent: #FFFFFF;
  --ok-bg: #DDF0DF; --ok-ink: #27562F; --warn-bg: #FDEFC8; --warn-ink: #6B4C00; --try-bg: #FBE6D1; --try-ink: #73450F;
  --fiil-bg: #DCE8F8; --fiil-ink: #22466F;
  --isim-bg: #DDF0DF; --isim-ink: #27562F;
  --sifat-bg: #FBE6D1; --sifat-ink: #73450F;
  --zarf-bg: #E8E0F5; --zarf-ink: #48367A;
  --phrasal-bg: #F9DEE6; --phrasal-ink: #782C46;
  --kalip-bg: #D9EEEE; --kalip-ink: #1F5458;
  --font: "Lexend", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --fs: 19px; --ls: 0.03em; --lh: 1.7;
  --r: 18px; --tap: 48px;
  --shadow: 0 1px 2px rgba(60, 50, 30, .06), 0 6px 18px rgba(60, 50, 30, .06);
}
html[data-font="atkinson"] { --font: "Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", sans-serif; }
html[data-font="system"] { --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { font-size: var(--fs); -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-weight: 400; letter-spacing: var(--ls); line-height: var(--lh);
  word-spacing: 0.06em; -webkit-tap-highlight-color: transparent;
  min-height: 100vh; min-height: 100dvh; overflow-wrap: anywhere;
}
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
h1 { font-size: 1.45rem; font-weight: 600; line-height: 1.3; }
h2 { font-size: 1.15rem; font-weight: 600; line-height: 1.35; }
h3 { font-size: 1rem; font-weight: 600; }
button, input, select { font: inherit; letter-spacing: inherit; color: inherit; }
button { cursor: pointer; touch-action: manipulation; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 10px; }
.muted { color: var(--ink-2); }
.small { font-size: .86rem; }
.en { font-feature-settings: "liga" 0; }
.skip { position: absolute; left: -999px; top: 0; background: var(--surface); padding: 12px 16px; z-index: 99; }
.skip:focus { left: 12px; top: 12px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap {
  max-width: 1080px; margin: 0 auto;
  padding: 20px max(18px, env(safe-area-inset-right)) calc(56px + env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left));
}
.stack > * + * { margin-top: 18px; }
.stack-lg > * + * { margin-top: 30px; }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.row--between { justify-content: space-between; }
.grow { flex: 1 1 auto; min-width: 0; }

/* ---------- Top bar ---------- */
#topbar {
  position: sticky; top: 0; z-index: 20; background: rgba(250, 248, 242, .94);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line);
  padding: calc(8px + env(safe-area-inset-top)) max(14px, env(safe-area-inset-right)) 8px max(14px, env(safe-area-inset-left));
}
.topbar { max-width: 1080px; margin: 0 auto; display: flex; align-items: center; gap: 8px; min-height: var(--tap); }
.topbar__title { flex: 1 1 auto; min-width: 0; font-weight: 600; font-size: 1rem; line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--tap); min-width: var(--tap); padding: 8px 18px;
  border: 1.5px solid var(--line-2); border-radius: 14px; background: var(--surface); color: var(--ink);
  font-weight: 500; line-height: 1.25; text-align: center; text-decoration: none;
  transition: background .15s, border-color .15s, transform .08s;
}
.btn:active { transform: scale(.98); background: var(--sunk); }
.btn--primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn--primary:active { background: var(--accent-2); }
.btn--quiet { border-color: transparent; background: transparent; }
.btn--soft { background: var(--accent-soft); border-color: transparent; color: var(--accent-2); }
.btn--big { min-height: 60px; padding: 12px 22px; font-size: 1.05rem; border-radius: 16px; }
.btn--block { display: flex; width: 100%; }
.btn--icon { padding: 8px; }
.btn[disabled] { opacity: .45; cursor: default; }
.btn svg { width: 22px; height: 22px; flex: none; }
.btn--know { background: var(--ok-bg); border-color: transparent; color: var(--ok-ink); }
.btn--more { background: var(--warn-bg); border-color: transparent; color: var(--warn-ink); }
.btn--hard { background: var(--try-bg); border-color: transparent; color: var(--try-ink); }

.switch { display: inline-flex; align-items: center; gap: 10px; min-height: var(--tap); padding: 6px 4px; border: 0; background: none; text-align: left; }
.switch__track { flex: none; width: 52px; height: 30px; border-radius: 15px; background: var(--line-2); position: relative; transition: background .15s; }
.switch__track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .15s; }
.switch[aria-checked="true"] .switch__track { background: var(--accent); }
.switch[aria-checked="true"] .switch__track::after { transform: translateX(22px); }

/* ---------- Surfaces ---------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; box-shadow: var(--shadow); }
.panel--flat { box-shadow: none; }
.panel--soft { background: var(--accent-soft); border-color: transparent; box-shadow: none; }
.hero { padding: 26px 22px; }
.hero p { max-width: 46ch; }
.section-title { display: flex; align-items: baseline; gap: 10px; margin-bottom: 12px; }

.grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); }
.grid--cards { grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); align-items: start; }

.tile {
  display: flex; flex-direction: column; gap: 8px; width: 100%; min-height: 96px; text-align: left;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; box-shadow: var(--shadow);
}
.tile:active { background: var(--sunk); }
.tile__no { font-size: .8rem; font-weight: 600; color: var(--accent-2); letter-spacing: .08em; }
.tile__title { font-weight: 600; line-height: 1.35; }
.tile__meta { font-size: .86rem; color: var(--ink-2); }
.tile--row { flex-direction: row; align-items: center; gap: 14px; min-height: 76px; }
.tile__num { flex: none; width: 46px; height: 46px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-2); display: grid; place-items: center; font-weight: 600; }
.tile--done .tile__num { background: var(--ok-bg); color: var(--ok-ink); }

.bar { height: 10px; border-radius: 5px; background: var(--sunk); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 5px; background: var(--accent); transition: width .3s; }
.bar--thin { height: 6px; }

/* ---------- Badges & chips ---------- */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 12px; border-radius: 999px; font-size: .8rem; font-weight: 600; line-height: 1.5; white-space: nowrap; }
.pos-fiil { background: var(--fiil-bg); color: var(--fiil-ink); }
.pos-isim { background: var(--isim-bg); color: var(--isim-ink); }
.pos-sifat { background: var(--sifat-bg); color: var(--sifat-ink); }
.pos-zarf, .pos-baglac { background: var(--zarf-bg); color: var(--zarf-ink); }
.pos-phrasal { background: var(--phrasal-bg); color: var(--phrasal-ink); }
.pos-kalip { background: var(--kalip-bg); color: var(--kalip-ink); }
.badge--trap { background: var(--warn-bg); color: var(--warn-ink); border: 1.5px solid #E9C766; }
.badge--trap svg { width: 15px; height: 15px; }
.badge--core { background: var(--accent-soft); color: var(--accent-2); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; min-height: 40px; padding: 4px 14px; border-radius: 999px; background: var(--sunk); border: 1px solid var(--line); font-size: .92rem; line-height: 1.3; }
button.chip { min-height: 44px; border-color: var(--line-2); background: var(--surface); }
button.chip:active { background: var(--sunk); }
.chip small { color: var(--ink-2); margin-left: 6px; }
.chip--part { border-radius: 12px; background: var(--surface); }
.chip--on { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }

/* ---------- Word card ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; box-shadow: var(--shadow); }
.card__head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; }
.card__word { font-size: 1.6rem; font-weight: 600; line-height: 1.25; letter-spacing: .02em; margin-right: 4px; }
.card__word--bundle { font-size: 1.25rem; }
.card__word span { display: block; }
.card__syl { margin-top: 4px; color: var(--ink-2); font-size: 1rem; letter-spacing: .06em; }
.card__pron { color: var(--ink-2); font-size: .92rem; }
html.hide-pron .card__pron, html.hide-syl .card__syl { display: none; }
.card__audio { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px; }
.card__tr { margin-top: 14px; font-size: 1.25rem; font-weight: 500; line-height: 1.4; }
.card__toggle { margin-top: 12px; width: 100%; justify-content: space-between; }
.card__toggle svg { transition: transform .15s; }
.card__toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.details { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 4px; }
.details section { padding: 14px 0; border-bottom: 1px dashed var(--line); }
.details section:last-child { border-bottom: 0; padding-bottom: 0; }
.details h4 { margin: 0 0 6px; font-size: .8rem; font-weight: 600; letter-spacing: .08em; color: var(--accent-2); }
.hook { background: var(--warn-bg); border-radius: 12px; padding: 12px 14px; }
.example__en { font-size: 1.08rem; }
mark { background: var(--accent-soft); color: inherit; padding: 1px 6px; border-radius: 6px; font-weight: 600; }
.example__tr { margin-top: 4px; color: var(--ink-2); }
.conf { background: var(--try-bg); color: var(--try-ink); border-radius: 12px; padding: 12px 14px; }
.btn--audio { min-height: 44px; padding: 6px 14px; font-size: .9rem; background: var(--accent-soft); border-color: transparent; color: var(--accent-2); }
.btn--audio.is-speaking { background: var(--accent); color: var(--on-accent); }

/* ---------- Packet / calm mode ---------- */
.packet-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.calm { max-width: 640px; margin: 0 auto; touch-action: pan-y; }
.calm .card { padding: 28px 24px; }
.calm .card__word { font-size: 2rem; }
.calm__nav { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; margin-top: 16px; }
.calm__pos { text-align: center; color: var(--ink-2); }
.recall { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.recall .btn { flex-direction: column; gap: 2px; min-height: 84px; }
.recall .btn small { font-weight: 400; color: var(--ink-2); font-size: .82rem; }

details.fold { border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
details.fold > summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 56px; padding: 8px 18px; cursor: pointer; font-weight: 600; }
details.fold > summary::-webkit-details-marker { display: none; }
details.fold > summary svg { width: 22px; height: 22px; transition: transform .15s; }
details.fold[open] > summary svg { transform: rotate(180deg); }
details.fold > .fold__body { padding: 0 12px 12px; }

/* ---------- SVG maps ---------- */
.map { position: relative; background: var(--bg); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.map svg { display: block; width: 100%; height: auto; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.map.is-zoomed svg, .map--full svg { touch-action: none; cursor: grab; }
.map__tools { display: flex; justify-content: flex-end; gap: 6px; padding: 4px 8px 8px; }
.map__tools .btn { min-height: 44px; min-width: 44px; padding: 6px; border-radius: 12px; background: rgba(255, 253, 248, .95); }
.map__hint { padding: 6px 12px 0; }
.map--full { position: fixed; inset: 0; z-index: 60; border-radius: 0; border: 0; display: flex; align-items: center; min-height: 0; padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left); }
.map--full svg { width: 100%; height: 100%; }
.map--full .map__tools { position: absolute; padding: 0; right: max(12px, env(safe-area-inset-right)); bottom: max(12px, env(safe-area-inset-bottom)); }
.map text { font-family: var(--font); letter-spacing: .02em; }
.map { min-height: 60px; }
.map .node { cursor: pointer; }
.map .node--static { cursor: default; }
.map .link { fill: none; stroke: var(--line-2); stroke-width: 2; }
.map .link--dash { stroke-dasharray: 6 6; }

/* ---------- Flashcards ---------- */
.flash { max-width: 640px; margin: 0 auto; }
.flash__stage { perspective: 1400px; touch-action: pan-y; }
.flash__card { display: grid; min-height: 340px; transform-style: preserve-3d; transition: transform .45s; cursor: pointer; will-change: transform; touch-action: pan-y; }
.flash__card.is-flipped { transform: rotateY(180deg); }
.flash__card.is-dragging { transition: none; }
.flash__face {
  grid-area: 1 / 1; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 28px 22px; box-shadow: var(--shadow);
  -webkit-backface-visibility: hidden; backface-visibility: hidden;
}
.flash__face--back { transform: rotateY(180deg); }
.flash__word { font-size: 2.1rem; font-weight: 600; line-height: 1.25; }
.flash__tr { font-size: 1.5rem; font-weight: 500; line-height: 1.35; }
.flash__rate { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 16px; }
.flash__rate .btn { min-height: 64px; padding: 8px 6px; }
.flash__tip { text-align: center; margin-top: 12px; min-height: 1.7em; }
.swipe-tag { position: absolute; top: 16px; padding: 4px 14px; border-radius: 999px; font-weight: 600; font-size: .9rem; opacity: 0; transition: opacity .1s; pointer-events: none; }
.swipe-tag--r { right: 16px; background: var(--ok-bg); color: var(--ok-ink); }
.swipe-tag--l { left: 16px; background: var(--try-bg); color: var(--try-ink); }

/* ---------- Quiz ---------- */
.quiz { max-width: 680px; margin: 0 auto; }
.quiz__sentence { font-size: 1.3rem; line-height: 1.7; }
.blank { display: inline-block; min-width: 5.5em; border-bottom: 3px solid var(--accent); margin: 0 4px; text-align: center; font-weight: 600; color: var(--accent-2); }
.options { display: grid; gap: 12px; margin-top: 20px; }
.option { justify-content: flex-start; text-align: left; min-height: 62px; font-size: 1.1rem; padding: 10px 20px; }
.option[disabled] { opacity: 1; }
.option[disabled]:not(.is-right):not(.is-wrong) { opacity: .55; }
.option.is-right { background: var(--ok-bg); border-color: #9CCDA2; color: var(--ok-ink); }
.option.is-wrong { background: var(--warn-bg); border-color: #E9C766; color: var(--warn-ink); }
.feedback { margin-top: 18px; border-radius: 14px; padding: 16px 18px; }
.feedback--ok { background: var(--ok-bg); color: var(--ok-ink); }
.feedback--try { background: var(--warn-bg); color: var(--warn-ink); }

/* ---------- Matching ---------- */
.match { max-width: 760px; margin: 0 auto; }
.match__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 22px; }
.match__item { width: 100%; min-height: 62px; justify-content: center; padding: 8px 12px; border-width: 2px; }
.match__item.is-picked { border-color: var(--accent); background: var(--accent-soft); }
.match__item.is-miss { animation: nudge .3s; border-color: #E9C766; }
.match__item.is-done { cursor: default; border-color: transparent; opacity: 1; }
.match__item.c0 { background: var(--fiil-bg); color: var(--fiil-ink); } .match__item.c1 { background: var(--isim-bg); color: var(--isim-ink); }
.match__item.c2 { background: var(--sifat-bg); color: var(--sifat-ink); } .match__item.c3 { background: var(--zarf-bg); color: var(--zarf-ink); }
.match__item.c4 { background: var(--phrasal-bg); color: var(--phrasal-ink); } .match__item.c5 { background: var(--kalip-bg); color: var(--kalip-ink); }
@keyframes nudge { 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }

.summary { text-align: center; padding: 30px 22px; }
.summary__big { font-size: 1.5rem; font-weight: 600; line-height: 1.35; }
.summary .row { justify-content: center; margin-top: 20px; }
.empty { text-align: center; padding: 34px 20px; }

/* ---------- Drawer, sheet, toast ---------- */
.scrim { position: fixed; inset: 0; z-index: 40; background: rgba(43, 43, 43, .32); }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 41; width: min(420px, 100%); background: var(--bg);
  border-left: 1px solid var(--line); box-shadow: -8px 0 30px rgba(60, 50, 30, .14); overflow-y: auto; -webkit-overflow-scrolling: touch;
  padding: calc(14px + env(safe-area-inset-top)) max(18px, env(safe-area-inset-right)) calc(24px + env(safe-area-inset-bottom)) 18px;
}
.drawer h2 { font-size: 1.2rem; }
.field { padding: 14px 0; border-bottom: 1px solid var(--line); }
.field > label, .field > .label { display: flex; justify-content: space-between; gap: 10px; font-weight: 600; margin-bottom: 8px; }
.field output { font-weight: 400; color: var(--ink-2); }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.seg .btn { padding: 8px 6px; font-size: .92rem; }
.seg .btn[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
input[type="range"] { width: 100%; height: 44px; accent-color: var(--accent); margin: 0; }
select { width: 100%; min-height: var(--tap); border: 1.5px solid var(--line-2); border-radius: 12px; background: var(--surface); padding: 6px 12px; }
.preview { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; }

.sheet {
  position: fixed; left: 50%; bottom: 0; z-index: 51; transform: translateX(-50%); width: min(680px, 100%); max-height: 88vh; max-height: 88dvh;
  overflow-y: auto; -webkit-overflow-scrolling: touch; background: var(--bg); border: 1px solid var(--line); border-bottom: 0; border-radius: 22px 22px 0 0;
  padding: 14px 16px calc(22px + env(safe-area-inset-bottom)); box-shadow: 0 -10px 40px rgba(60, 50, 30, .18);
}
.sheet .scrim { z-index: 50; }
.dialog { position: fixed; left: 50%; top: 50%; z-index: 71; transform: translate(-50%, -50%); width: min(460px, calc(100% - 32px)); background: var(--surface); border-radius: 20px; padding: 24px; box-shadow: 0 20px 60px rgba(60, 50, 30, .25); }
.dialog + .scrim, .scrim--top { z-index: 70; }

#toast { position: fixed; left: 50%; bottom: calc(22px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 90; pointer-events: none; }
#toast > div { background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 14px; font-size: .92rem; max-width: min(520px, 92vw); text-align: center; }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
@media (max-width: 560px) {
  .card__word { font-size: 1.4rem; }
  .hide-narrow { display: none; }
  .flash__rate .btn { font-size: .86rem; }
  .match__cols { gap: 10px 10px; }
}

/* ---------- Print sheet (A4, room for stylus notes) ---------- */
.sheet-page { max-width: 980px; margin: 0 auto; }
.pcards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; }
.pcard { border: 1px solid #CFC7B5; border-radius: 10px; padding: 9px 11px; break-inside: avoid; page-break-inside: avoid; background: #fff; font-size: .8rem; line-height: 1.5; }
.pcard__word { font-size: 1.05rem; font-weight: 600; }
.pcard__tr { font-weight: 600; }
.pcard .badge { font-size: .66rem; padding: 1px 8px; }
.pgroup { margin-top: 22px; }
.pgroup > h2 { break-after: avoid; page-break-after: avoid; border-bottom: 2px solid var(--line-2); padding-bottom: 4px; margin-bottom: 10px; }
.notes-lines { height: 46px; border-bottom: 1px dotted #B9B09B; background: repeating-linear-gradient(to bottom, transparent 0 21px, #D9D2C0 21px 22px); margin-top: 6px; }

@page { size: A4; margin: 14mm 30mm 14mm 14mm; }
@media print {
  html { font-size: 12pt; }
  body { background: #fff; letter-spacing: .02em; }
  #topbar, .no-print, #toast, .map__tools { display: none !important; }
  .wrap { max-width: none; padding: 0; }
  .map { border: 0; break-inside: avoid; }
  .panel, .card { box-shadow: none; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
