/* Забіг Звіздарів · Полтава — лендинг. Палітра айдентики 2026: StarLight, Off Black, колір міста (Полтава — жовтий), золоті 3D-звізди, шум. */
body.pl {
  --yellow: #E9CF4A;
  --yellow-2: color-mix(in srgb, var(--yellow) 78%, #fff);
  --cream: #FFFCF1;
  --offblack: #1E1E1E;
  --ink-2: #3A3833;
  --gold: #C8B27A;
  --muted-d: rgba(30, 30, 30, 0.64);
  --muted-l: rgba(255, 252, 241, 0.66);
  /* токени для діалогів (темні) */
  --bg: #1E1E1E; --surface: #2A2927; --surface-2: #34322F; --text: #FFFCF1;
  --text-2: rgba(255,252,241,.72); --text-3: rgba(255,252,241,.5);
  --line: rgba(255,252,241,.1); --line-strong: rgba(255,252,241,.24);
  --accent: var(--yellow); --accent-2: var(--yellow-2); --accent-soft: color-mix(in srgb, var(--yellow) 20%, transparent);
  --gold-soft: color-mix(in srgb, var(--yellow) 20%, transparent);
  --pl-wrap: 1240px;
  --pl-gut: clamp(1.1rem, 4.5vw, 3rem);
  background: var(--cream);
  color: var(--offblack);
  font-family: "Inter", system-ui, sans-serif;
}
body.pl .btn-primary { background: var(--yellow); border-color: var(--yellow); color: var(--offblack); }
body.pl .btn-primary:hover { background: var(--yellow-2); border-color: var(--yellow-2); color: var(--offblack); }
body.pl .alert-gold { background: color-mix(in srgb, var(--yellow) 14%, transparent); border-color: color-mix(in srgb, var(--yellow) 50%, transparent); color: var(--cream); }
body.pl .dialog-panel { background: var(--offblack); color: var(--cream); }
body.pl :focus-visible { outline-color: var(--offblack); }
body.pl .pl-ink :focus-visible, body.pl .dialog :focus-visible { outline-color: var(--yellow); }

.pl-wrap { width: min(100% - 2 * var(--pl-gut), var(--pl-wrap)); margin-inline: auto; }

/* Шум, як на афішах (Noise duo: 000000 13% + FFFCF1 25%) */
.pl-noise { position: relative; isolation: isolate; }
.pl-noise::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .2; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 .55 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* ---------- Навігація ---------- */
.pl-nav { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--yellow) 92%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid rgba(30,30,30,.08); }
.pl-nav-in { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 64px; }
.pl-brand { display: inline-flex; align-items: center; gap: .6rem; text-decoration: none; font-weight: 700; letter-spacing: -.01em; }
.pl-brand img { width: 34px; height: 34px; }
.pl-brand b { font-weight: 500; opacity: .7; }
.pl-links { display: none; list-style: none; margin: 0; padding: 0; gap: 1.6rem; }
.pl-links a { text-decoration: none; font-size: .92rem; font-weight: 500; opacity: .8; }
.pl-links a:hover { opacity: 1; text-decoration: underline; text-underline-offset: .3em; }
@media (min-width: 960px) { .pl-links { display: flex; } }
@media (max-width: 420px) { .pl-brand span { font-size: .9rem; } .pl-brand b { display: none; } }

/* ---------- Кнопки ---------- */
.pl-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: .8rem 1.6rem; border-radius: 999px; font-weight: 700; font-size: 1rem; text-decoration: none; border: 2px solid transparent; transition: transform .18s ease, background .18s ease, color .18s ease; cursor: pointer; }
.pl-btn:hover { transform: translateY(-2px); }
.pl-btn:active { transform: translateY(0); }
.pl-btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; }
.pl-btn-sm { min-height: 40px; padding: .45rem 1.1rem; font-size: .9rem; }
.pl-btn-ink { background: var(--offblack); color: var(--cream); }
.pl-btn-ink:hover { background: #000; }
.pl-btn-line { border-color: var(--offblack); color: var(--offblack); background: transparent; }
.pl-btn-line:hover { background: var(--offblack); color: var(--cream); }
.pl-btn-yellow { background: var(--yellow); color: var(--offblack); }
.pl-btn-yellow:hover { background: var(--yellow-2); }
.pl-btn-line-light { border-color: var(--cream); color: var(--cream); background: transparent; }
.pl-btn-line-light:hover { background: var(--cream); color: var(--offblack); }
.pl-row { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }

/* ---------- Леттеринг (маски з айдентики) ---------- */
.wm { display: block; background: currentColor; -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }
.wm-zabih { --m: url("/assets/images/poltava/wm-zabih.png"); aspect-ratio: 428 / 118; }
.wm-zvizdariv { --m: url("/assets/images/poltava/wm-zvizdariv.png"); aspect-ratio: 768 / 150; }
.wm-pzh { --m: url("/assets/images/partners/povernys-zhyvym.png"); aspect-ratio: 443 / 199; }
.pl-fund-logo { display: inline-block; margin-top: 2rem; color: var(--cream); width: clamp(160px, 30vw, 240px); opacity: .92; }
.pl-fund-logo:hover, .pl-fund-logo:focus-visible { opacity: 1; }
.pl-fund-logo .wm { width: 100%; }
.wm-poltava { --m: url("/assets/images/poltava/wm-poltava.png"); aspect-ratio: 743 / 121; }

/* ---------- Hero ---------- */
.pl-hero { background: var(--yellow); color: var(--offblack); overflow: hidden; }
.pl-hero-in { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr auto auto; min-height: calc(100svh - 64px); padding-block: clamp(1.5rem, 4vw, 3rem) clamp(1.5rem, 4vw, 2.5rem); }
.pl-wordmark { margin: 0; position: relative; z-index: 1; --W: min(100%, 860px); }
.pl-wordmark .wm-zvizdariv { width: var(--W); margin-left: calc(var(--W) * .1); }
.pl-wordmark .wm-zabih { width: calc(var(--W) * .557); margin-bottom: calc(var(--W) * .01); }

.pl-hero-star { position: absolute; z-index: 2; left: 50%; top: 52%; width: clamp(260px, 52vmin, 560px); translate: -50% -50%; filter: drop-shadow(0 30px 40px rgba(80, 60, 10, .28)); pointer-events: none; }
.pl-hero-star img { width: 100%; height: auto; animation: pl-sway 9s ease-in-out infinite; transform-origin: 50% 50%; }
@keyframes pl-sway { 0%, 100% { transform: rotate(-4deg) translateY(0); } 50% { transform: rotate(4deg) translateY(-10px); } }
/* Полтава: звізда повільно обертається, як колядницька звізда на жердині */
body:not(.is-city) .pl-hero-star img { animation: pl-spin 24s linear infinite; }
@keyframes pl-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .pl-hero-star img { animation: none; } }
.pl-hero-foot { position: relative; z-index: 3; display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-top: auto; }
.pl-hero-city .wm-poltava { width: clamp(200px, 40vw, 520px); }
.pl-hero-time, .pl-hero-date { font-weight: 800; font-weight: 700; letter-spacing: -.04em; line-height: .9; font-size: clamp(2.6rem, 8vw, 6.2rem); font-variant-numeric: tabular-nums; }
.pl-hero-time { display: block; margin: .35em 0 0 .6em; }
.pl-hero-cta { position: relative; z-index: 3; display: grid; gap: 1.1rem; margin-top: clamp(1.25rem, 3vw, 2rem); padding-top: clamp(1rem, 2.5vw, 1.6rem); border-top: 2px solid var(--offblack); }
.pl-lead { margin: 0; max-width: 46ch; font-size: clamp(1.02rem, .95rem + .4vw, 1.25rem); line-height: 1.45; font-weight: 500; }
@media (min-width: 860px) { .pl-hero-cta { grid-template-columns: 1fr auto; align-items: center; } }

/* ---------- Секції ---------- */
.pl-sec { padding-block: clamp(4rem, 9vw, 7.5rem); }
.pl-cream { background: var(--cream); color: var(--offblack); }
.pl-ink { background: var(--offblack); color: var(--cream); }
.pl-yellow { background: var(--yellow); color: var(--offblack); }
.pl-eyebrow { margin: 0 0 .9rem; font-size: .78rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; opacity: .62; }
.pl-ink .pl-eyebrow { color: var(--yellow); opacity: 1; }
.pl-h2 { margin: 0 0 1.5rem; font-weight: 700; font-size: clamp(2.1rem, 1.3rem + 3.6vw, 4.2rem); line-height: 1; letter-spacing: -.045em; text-wrap: balance; }
.pl-h3 { margin: 0 0 .6rem; font-weight: 700; font-size: clamp(1.35rem, 1.1rem + 1vw, 1.9rem); letter-spacing: -.03em; line-height: 1.08; }
.pl-muted { color: var(--muted-d); }
.pl-ink .pl-muted { color: var(--muted-l); }
.pl-maxw { max-width: 42ch; margin: 0; }
.pl-split { display: grid; gap: 2rem; }
@media (min-width: 900px) { .pl-split { grid-template-columns: 5fr 7fr; gap: 4rem; } }
.pl-prose p { font-size: 1.05rem; line-height: 1.6; }
.pl-big { font-size: clamp(1.2rem, 1.05rem + .7vw, 1.6rem) !important; line-height: 1.35 !important; font-weight: 500; letter-spacing: -.015em; }
.pl-facts { list-style: none; padding: 0; margin: 2rem 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1px; background: rgba(30,30,30,.14); border: 1px solid rgba(30,30,30,.14); border-radius: 18px; overflow: hidden; }
.pl-facts li { background: var(--cream); padding: 1.2rem 1.3rem; display: grid; gap: .25rem; }
.pl-facts b { font-size: 1.7rem; letter-spacing: -.04em; }
.pl-facts span { font-size: .9rem; color: var(--muted-d); }

/* ---------- Традиція ---------- */
.pl-trad { display: grid; gap: 1px; background: rgba(255,252,241,.14); border-block: 1px solid rgba(255,252,241,.14); margin-top: 1rem; }
@media (min-width: 760px) { .pl-trad { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1100px) { .pl-trad { grid-template-columns: repeat(4, 1fr); } }
.pl-trad-item { background: var(--offblack); padding: 1.8rem 1.4rem 2rem 0; }
@media (min-width: 760px) { .pl-trad-item { padding: 2rem 1.6rem; } .pl-trad-item:first-child { padding-left: 0; } }
.pl-trad-item h3 { font-size: 1.3rem; letter-spacing: -.02em; margin: .9rem 0 .6rem; }
.pl-trad-item p { color: var(--muted-l); margin: 0; line-height: 1.6; }
.pl-num { font-weight: 700; color: var(--yellow); font-variant-numeric: tabular-nums; }
.pl-dress { display: grid; gap: 1.5rem; margin-top: clamp(3rem, 6vw, 4.5rem); padding: clamp(1.5rem, 4vw, 2.5rem); border-radius: 22px; background: #2A2927; }
@media (min-width: 900px) { .pl-dress { grid-template-columns: 4fr 8fr; gap: 3rem; } }
.pl-dress-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .8rem; }
.pl-dress-list li { position: relative; padding-left: 2rem; line-height: 1.5; }
.pl-dress-list li::before { position: absolute; left: 0; top: .05em; width: 1.35rem; height: 1.35rem; border-radius: 50%; display: grid; place-items: center; font-size: .8rem; font-weight: 700; }
.pl-dress-list .ok::before { content: "✓"; background: var(--yellow); color: var(--offblack); }
.pl-dress-list .no::before { content: "✕"; background: rgba(255,252,241,.12); color: var(--cream); }

/* ---------- Звізди ---------- */
.pl-head-row { display: grid; gap: 1rem; margin-bottom: 2.2rem; }
@media (min-width: 900px) { .pl-head-row { grid-template-columns: 1fr auto; align-items: end; } }
.pl-star-feature { display: grid; gap: 2rem; align-items: center; margin-bottom: 1.5rem; }
@media (min-width: 860px) { .pl-star-feature { grid-template-columns: 6fr 5fr; gap: 3.5rem; } }
.pl-star-big { background: var(--c); border-radius: 26px; aspect-ratio: 5 / 4; display: grid; place-items: center; overflow: hidden; }
.pl-star-big img { width: min(70%, 380px); height: auto; filter: drop-shadow(0 24px 30px rgba(80,60,10,.25)); transition: transform .6s cubic-bezier(.2,.7,.2,1); }
.pl-star-big:hover img { transform: rotate(10deg) scale(1.03); }
.pl-star-text p:last-child { font-size: 1.1rem; line-height: 1.55; margin: 0; }
.pl-star-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .9rem; }
@media (min-width: 700px) { .pl-star-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1100px) { .pl-star-grid { grid-template-columns: repeat(5, 1fr); } }
.pl-star-card { margin: 0; background: var(--c); border-radius: 18px; padding: 1.3rem 1rem 1rem; display: grid; gap: .9rem; justify-items: center; border: 1px solid rgba(30,30,30,.06); }
.pl-star-card img { width: min(70%, 135px); height: auto; aspect-ratio: 1; object-fit: contain; filter: drop-shadow(0 12px 14px rgba(60,45,10,.22)); transition: transform .5s cubic-bezier(.2,.7,.2,1); }
.pl-star-card:hover img { transform: rotate(-12deg); }
.pl-star-card figcaption { display: grid; text-align: center; gap: .1rem; }
.pl-star-card figcaption b { font-size: .98rem; }
.pl-star-card figcaption span { font-size: .82rem; opacity: .66; }
.pl-credit { margin: 1.4rem 0 0; font-size: .85rem; color: var(--muted-d); }

/* ---------- Деталі ---------- */
.pl-cards { display: grid; gap: .9rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .pl-cards { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1100px) { .pl-cards { grid-template-columns: repeat(4, 1fr); } }
.pl-card { background: var(--cream); border-radius: 18px; padding: 1.4rem 1.4rem 1.5rem; display: grid; align-content: start; gap: .35rem; min-height: 150px; }
.pl-card .k { font-size: .76rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; opacity: .55; }
.pl-card .v { font-size: clamp(1.35rem, 1.1rem + 1vw, 1.9rem); font-weight: 700; letter-spacing: -.035em; line-height: 1.1; }
.pl-card .s { font-size: .9rem; color: var(--muted-d); line-height: 1.45; }
.pl-rules { display: grid; gap: 1.6rem; margin-top: 2.6rem; padding-top: 2rem; border-top: 2px solid var(--offblack); }
@media (min-width: 900px) { .pl-rules { grid-template-columns: repeat(3, 1fr); gap: 2.5rem; } }
.pl-rule h3 { font-size: 1.2rem; letter-spacing: -.02em; margin: 0 0 .5rem; font-weight: 700; }
.pl-rule p { margin: 0; line-height: 1.55; }

/* ---------- Збір ---------- */
.pl-goal { display: grid; gap: .3rem; margin-top: 1.5rem; }
.pl-goal b { font-size: clamp(3.2rem, 2rem + 6vw, 6.5rem); line-height: .9; letter-spacing: -.06em; color: var(--yellow); font-variant-numeric: tabular-nums; }
.pl-goal span { color: var(--muted-l); max-width: 30ch; }
#fund .pl-prose b { color: var(--yellow); }

/* ---------- Реєстрація ---------- */
.pl-reg { display: grid; gap: 2rem; align-items: center; }
@media (min-width: 900px) { .pl-reg { grid-template-columns: 5fr 7fr; gap: 4rem; } }
.pl-reg-star { justify-self: center; width: min(78%, 420px); }
.pl-reg-star img { width: 100%; height: auto; filter: drop-shadow(0 26px 34px rgba(80,60,10,.28)); animation: pl-sway 11s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) { .pl-reg-star img { animation: none; } }
.pl-steps { list-style: none; counter-reset: s; padding: 0; margin: 0 0 2rem; display: grid; gap: .9rem; }
.pl-steps li { counter-increment: s; position: relative; padding: .35rem 0 0 3.3rem; min-height: 2.4rem; font-size: 1.08rem; line-height: 1.45; }
.pl-steps li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 2.4rem; height: 2.4rem; border-radius: 50%; background: var(--offblack); color: var(--yellow); display: grid; place-items: center; font-weight: 700; }
.pl-reg-status { margin: 1.1rem 0 0; font-size: .95rem; font-weight: 500; opacity: .75; }

/* ---------- FAQ ---------- */
.pl-faq details { border-top: 1px solid rgba(30,30,30,.16); }
.pl-faq details:last-child { border-bottom: 1px solid rgba(30,30,30,.16); }
.pl-faq summary { list-style: none; cursor: pointer; padding: 1.25rem 2.5rem 1.25rem 0; position: relative; font-size: 1.15rem; font-weight: 600; letter-spacing: -.015em; }
.pl-faq summary::-webkit-details-marker { display: none; }
.pl-faq summary::after { content: "+"; position: absolute; right: .2rem; top: 50%; translate: 0 -50%; font-size: 1.6rem; font-weight: 400; transition: rotate .2s ease; }
.pl-faq details[open] summary::after { rotate: 45deg; }
.pl-faq p { margin: 0 0 1.3rem; max-width: 62ch; color: var(--muted-d); line-height: 1.6; }

/* ---------- Партнери ---------- */
.pl-partners { display: grid; gap: 1px; background: rgba(255,252,241,.12); border: 1px solid rgba(255,252,241,.12); border-radius: 22px; overflow: hidden; grid-template-columns: 1fr; }
@media (min-width: 640px) { .pl-partners { grid-template-columns: repeat(2, 1fr); } .pl-partner.is-main { grid-column: 1 / -1; } }
@media (min-width: 1100px) { .pl-partners { grid-template-columns: 1.4fr repeat(4, 1fr); } .pl-partner.is-main { grid-column: auto; } }
.pl-partner { min-width: 0; background: var(--offblack); padding: 1.5rem 1.4rem; min-height: 150px; display: flex; flex-direction: column; justify-content: space-between; gap: 1.4rem; text-decoration: none; color: var(--cream); transition: background .2s ease; }
.pl-partner:hover { background: #2A2927; }
.pl-partner .r { font-size: .76rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted-l); }
.pl-partner.is-main .r { color: var(--yellow); }
.pl-logo { display: block; height: 38px; max-width: 100%; background: var(--cream); -webkit-mask: var(--m) left center / contain no-repeat; mask: var(--m) left center / contain no-repeat; }
.pl-partner.is-main .pl-logo { height: 48px; }
.pl-logo-row { display: flex; align-items: center; gap: .7rem; min-height: 38px; }
.pl-logo-row img { width: 40px; height: 40px; border-radius: 10px; }
.pl-logo-row img.pl-org-logo { width: auto; height: 48px; max-width: 100%; border-radius: 0; object-fit: contain; }
.pl-logo.pl-logo-pzh { height: 64px; background: var(--yellow); }
.pl-mark { display: block; height: 44px; background: var(--yellow); -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }
.pl-logo-row b { font-size: 1.35rem; font-weight: 800; letter-spacing: -.03em; line-height: 1.05; }

/* ---------- Футер ---------- */
.pl-foot { background: var(--offblack); color: var(--cream); padding-block: 2.5rem 6rem; border-top: 1px solid rgba(255,252,241,.1); }
@media (min-width: 900px) { .pl-foot { padding-bottom: 2.5rem; } }
.pl-foot-in { display: grid; gap: 1.5rem; }
@media (min-width: 900px) { .pl-foot-in { grid-template-columns: 1fr auto; } }
.pl-foot p { margin: 0 0 .4rem; max-width: 62ch; font-size: .92rem; }
.pl-foot-links { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .5rem 1.4rem; font-size: .92rem; }
.pl-foot-links a { color: var(--muted-l); }
.pl-foot-links a:hover { color: var(--cream); }

/* ---------- Мобільна кнопка ---------- */
.pl-mcta { position: fixed; left: 1rem; right: 1rem; bottom: max(1rem, env(safe-area-inset-bottom)); z-index: 40; display: flex; justify-content: center; align-items: center; min-height: 54px; border-radius: 999px; background: var(--offblack); color: var(--cream); font-weight: 700; text-decoration: none; box-shadow: 0 12px 30px rgba(0,0,0,.3); transition: opacity .2s ease, translate .2s ease; }
.pl-mcta.is-hidden { opacity: 0; translate: 0 120%; pointer-events: none; }
@media (min-width: 900px) { .pl-mcta { display: none; } }

/* ---------- Мобільний hero (в кінці, щоб перекрити базові правила) ---------- */
@media (max-width: 640px) {
  .pl-wordmark { --W: 88%; } .pl-wordmark .wm-zvizdariv { margin-left: 10%; }
  .pl-hero-in { min-height: 0; }
  .pl-hero-star { position: relative; left: auto; top: auto; translate: none; width: min(82vw, 360px); justify-self: center; margin: -1.2rem 0 -2.6rem; z-index: 0; }
  .pl-hero-foot { margin-top: 0; }
}
@media (max-width: 600px) { .pl-facts { grid-template-columns: 1fr; } }

/* ---------- Діалог успіху ---------- */
.success { display: grid; gap: 1rem; text-align: left; }
.success .number { font-size: clamp(2.4rem, 2rem + 2vw, 3.4rem); font-weight: 700; color: var(--yellow); line-height: 1; letter-spacing: -.04em; }
.success .facts { display: grid; gap: .6rem; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.success .fact { padding: .75rem 1rem; background: var(--surface); border-radius: 10px; }
.success .fact .k { display: block; font-size: .78rem; color: var(--text-3); margin-bottom: .15rem; }
.success .fact .v { font-weight: 600; }
.success .actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.manage-link { word-break: break-all; font-family: ui-monospace, Menlo, monospace; font-size: .85rem; padding: .75rem; background: rgba(255,252,241,.05); border-radius: 10px; border: 1px dashed var(--line-strong); }
body.pl .alert-gold .btn { background: var(--yellow) !important; border-color: var(--yellow) !important; color: var(--offblack) !important; }

/* ---------- Всеукраїнський забіг: карта і міста ---------- */
.pl-map-layout { display: grid; gap: 1.2rem; }
@media (min-width: 1000px) { .pl-map-layout { grid-template-columns: 1.5fr 1fr; align-items: start; } }
.pl-map-card { background: var(--cream); border-radius: 24px; padding: clamp(.8rem, 2vw, 1.4rem); }
.pl-map { position: relative; aspect-ratio: 1000 / 640; }
.pl-map svg { width: 100%; height: 100%; display: block; overflow: visible; }
.pl-map-state { position: absolute; inset: 0; display: grid; place-items: center; margin: 0; color: var(--muted-d); }
.pl-map .map-region { fill: rgba(30,30,30,.045); stroke: rgba(30,30,30,.28); stroke-width: .7; vector-effect: non-scaling-stroke; transition: fill .2s ease; }
.pl-map .map-region.has-city { fill: color-mix(in srgb, var(--yellow) 38%, transparent); }
.pl-map .marker { cursor: pointer; }
.pl-map .marker .hit { fill: transparent; }
.pl-map .marker .glow { fill: transparent; }
.pl-map .marker .ring { fill: none; stroke: transparent; stroke-width: 1.4; vector-effect: non-scaling-stroke; }
.pl-map .marker .star { fill: var(--offblack); transition: transform .2s ease; transform-box: fill-box; transform-origin: center; }
.pl-map .marker:hover .star, .pl-map .marker:focus-visible .star, .pl-map .marker.is-active .star { transform: scale(1.3); }
.pl-map .marker:focus-visible { outline: none; }
.pl-map .marker.is-active .ring, .pl-map .marker:focus-visible .ring { stroke: var(--offblack); }
.pl-map .marker .label { font: 600 12px/1 "Inter", sans-serif; fill: var(--offblack); paint-order: stroke; stroke: var(--cream); stroke-width: 3.5px; stroke-linejoin: round; pointer-events: none; }
.pl-map .marker-cancelled .star, .pl-map .marker-completed .star, .pl-map .marker-closed .star { fill: rgba(30,30,30,.35); }
.pl-map .marker-cancelled .cross { stroke: var(--offblack); stroke-width: 1.4; vector-effect: non-scaling-stroke; }
.pl-map .marker-paused .warnmark { fill: var(--cream); font-size: 9px; font-weight: 700; }
.pl-map .marker.is-home .star { fill: var(--yellow); stroke: var(--offblack); stroke-width: 1.4; vector-effect: non-scaling-stroke; transform: scale(1.55); }
.pl-map .marker.is-home .glow { fill: color-mix(in srgb, var(--yellow) 90%, transparent); }
.pl-map .marker.is-home .label { font-size: 15px; font-weight: 800; }
.pl-map-foot { display: flex; flex-wrap: wrap; gap: .5rem 1.2rem; align-items: center; margin-top: .6rem; font-size: .85rem; color: var(--muted-d); }
.pl-legend { display: inline-flex; align-items: center; gap: .45rem; }
.pl-legend i { width: 12px; height: 12px; display: inline-block; clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); background: var(--offblack); }
.pl-legend .lg-home { background: var(--yellow); outline: 1px solid var(--offblack); width: 15px; height: 15px; }
.pl-map-attr { margin-left: auto; font-size: .72rem; }
.pl-map-attr a { color: inherit; }
.pl-city-col { display: grid; gap: 1rem; }
.pl-city-meta { margin: 0; font-weight: 700; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; opacity: .6; }
.pl-city-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; max-height: 470px; overflow: auto; overscroll-behavior: contain; }
.pl-city { display: flex; align-items: center; justify-content: space-between; gap: .8rem; padding: .85rem 1rem; background: var(--cream); border-radius: 16px; border: 2px solid transparent; transition: border-color .2s ease; }
.pl-city.is-active { border-color: var(--offblack); }
.pl-city.is-home { background: var(--offblack); color: var(--cream); }
.pl-city.is-home .pl-btn-ink { background: var(--yellow); color: var(--offblack); }
.pl-city-info { display: grid; gap: .1rem; min-width: 0; }
.pl-city-info b { font-size: 1.1rem; letter-spacing: -.02em; }
.pl-city-info span { font-size: .85rem; opacity: .68; }
.pl-tag { flex: none; font-size: .8rem; font-weight: 600; padding: .35rem .7rem; border-radius: 999px; background: rgba(30,30,30,.08); white-space: nowrap; }
.pl-city .pl-btn { flex: none; white-space: nowrap; }
.pl-org-card { background: var(--offblack); color: var(--cream); border-radius: 20px; padding: 1.4rem; }
.pl-org-card h3 { margin: 0 0 .4rem; font-size: 1.3rem; letter-spacing: -.02em; }
.pl-org-card p { margin: 0 0 1rem; color: var(--muted-l); line-height: 1.5; }
.pl-org-card .pl-btn-ink { background: var(--yellow); color: var(--offblack); }

/* ---------- Як долучитися: шляхи ---------- */
.pl-paths { display: grid; gap: 1.2rem; }
@media (min-width: 900px) { .pl-paths { grid-template-columns: 1fr 1fr; } }
.pl-path { background: #2A2927; border-radius: 22px; padding: clamp(1.4rem, 3vw, 2.2rem); display: grid; gap: 1.4rem; align-content: start; justify-items: start; }
.pl-path h3 { margin: 0; font-size: 1.5rem; letter-spacing: -.03em; color: var(--yellow); }
.pl-chain { list-style: none; counter-reset: c; margin: 0; padding: 0; display: grid; gap: 0; width: 100%; }
.pl-chain li { counter-increment: c; position: relative; padding: 0 0 1.2rem 3.2rem; display: grid; gap: .2rem; }
.pl-chain li::before { content: counter(c); position: absolute; left: 0; top: 0; width: 2.2rem; height: 2.2rem; border-radius: 50%; background: var(--yellow); color: var(--offblack); display: grid; place-items: center; font-weight: 700; font-size: .95rem; }
.pl-chain li::after { content: ""; position: absolute; left: 1.08rem; top: 2.4rem; bottom: .2rem; width: 2px; background: rgba(255,252,241,.16); }
.pl-chain li:last-child { padding-bottom: 0; }
.pl-chain li:last-child::after { display: none; }
.pl-chain b { font-size: 1.08rem; padding-top: .2rem; }
.pl-chain span { color: var(--muted-l); line-height: 1.5; font-size: .95rem; }

/* ---------- Безпека й правила ---------- */
.pl-keys { list-style: none; margin: 0 0 1.2rem; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: .6rem; }
@media (min-width: 900px) { .pl-keys { grid-template-columns: repeat(4, 1fr); } }
.pl-keys li { background: var(--yellow); border-radius: 18px; padding: 1.1rem 1.2rem; display: grid; gap: .15rem; }
.pl-keys b { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.2rem); letter-spacing: -.04em; line-height: 1; }
.pl-keys span { font-size: .9rem; opacity: .75; }
.pl-rule-grid { display: grid; gap: .8rem; }
@media (min-width: 900px) { .pl-rule-grid { grid-template-columns: repeat(3, 1fr); } }
.pl-rule-card { background: #fff; border: 1px solid rgba(30,30,30,.08); border-radius: 22px; padding: 1.5rem; }
.pl-rule-num { display: inline-grid; place-items: center; min-width: 2.4rem; height: 2.4rem; padding: 0 .5rem; border-radius: 999px; background: var(--offblack); color: var(--yellow); font-weight: 700; font-size: .9rem; }
.pl-rule-card h3, .pl-look h3 { margin: .9rem 0 .8rem; font-size: 1.35rem; letter-spacing: -.03em; }
.pl-rule-card ul, .pl-look ul { margin: 0; padding: 0; list-style: none; display: grid; gap: .75rem; }
.pl-rule-card li { position: relative; padding-left: 1.2rem; line-height: 1.5; }
.pl-rule-card li::before { content: ""; position: absolute; left: 0; top: .6em; width: .5rem; height: .5rem; border-radius: 50%; background: var(--yellow); box-shadow: 0 0 0 1.5px var(--offblack); }
.pl-look { margin-top: .8rem; display: grid; gap: 1px; background: rgba(30,30,30,.08); border-radius: 22px; overflow: hidden; border: 1px solid rgba(30,30,30,.08); }
@media (min-width: 900px) { .pl-look { grid-template-columns: 1.1fr 1fr 1fr; } }
.pl-look > div { background: #fff; padding: 1.5rem; }
.pl-look-head p { margin: 0; line-height: 1.55; color: var(--muted-d); }
.pl-look-col h4 { margin: 0 0 1rem; font-size: 1rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.pl-look-col li { position: relative; padding-left: 2rem; line-height: 1.45; }
.pl-look-col li::before { position: absolute; left: 0; top: 0; width: 1.4rem; height: 1.4rem; border-radius: 50%; display: grid; place-items: center; font-size: .8rem; font-weight: 700; }
.pl-look-col.is-yes li::before { content: "✓"; background: var(--yellow); color: var(--offblack); }
.pl-look-col.is-no li::before { content: "✕"; background: var(--offblack); color: var(--cream); }
.pl-look-col.is-no h4 { color: var(--muted-d); }

/* ---------- Службові сторінки (умови, дані, керування, 404) у світлій темі ---------- */
body.pl-light {
  --bg: #FFFCF1; --surface: #FFFFFF; --surface-2: #F6F1E1; --text: #1E1E1E;
  --text-2: rgba(30,30,30,.72); --text-3: rgba(30,30,30,.55);
  --line: rgba(30,30,30,.1); --line-strong: rgba(30,30,30,.22);
  background: var(--cream); color: var(--offblack);
}
body.pl-light .app-main { padding-block: clamp(2.5rem, 6vw, 5rem); min-height: 60vh; }
body.pl-light .app-main .eyebrow { margin: 0 0 .9rem; font-size: .78rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--offblack); opacity: .6; }
body.pl-light .app-main h1 { font-weight: 700 !important; letter-spacing: -.045em; line-height: 1; font-size: clamp(2.2rem, 1.4rem + 3.4vw, 4rem) !important; margin-bottom: 1.6rem; }
body.pl-light .app-main h3 { margin: 2rem 0 .6rem; font-size: 1.25rem; font-weight: 700; letter-spacing: -.02em; }
body.pl-light .app-main .muted, body.pl-light .app-main .lead { color: var(--muted-d); line-height: 1.65; font-size: 1.02rem; }
body.pl-light .app-main a { color: var(--offblack); text-decoration-color: var(--yellow); text-decoration-thickness: 2px; }
body.pl-light .card { background: #fff; border: 1px solid var(--line); border-radius: 20px; }
body.pl-light .btn-primary { background: var(--offblack); border-color: var(--offblack); color: var(--cream); }
body.pl-light .btn-primary:hover { background: #000; color: var(--cream); }
body.pl-light .btn { color: var(--offblack); }
body.pl-light .btn-primary { color: var(--cream); }
body.pl-light .alert-gold { background: color-mix(in srgb, var(--yellow) 25%, transparent); border-color: var(--yellow); color: var(--offblack); }
body.pl-light .input:focus { border-color: var(--offblack); box-shadow: 0 0 0 3px color-mix(in srgb, var(--yellow) 45%, transparent); }
body.pl-light :focus-visible { outline-color: var(--offblack); }
.pl-foot-mini { padding-block: 1.6rem; }
.pl-foot-mini p { margin: 0; }
.pl-foot .pl-muted { color: var(--muted-l); }
body.pl-light .input, body.pl-light .select, body.pl-light .textarea { background: #F6F1E1; border: 1px solid rgba(30,30,30,.14); color: var(--offblack); }
@media (max-width: 639px) {
  .pl-partners { grid-template-columns: 1fr 1fr; }
  .pl-partner { min-height: 120px; padding: 1.2rem 1rem; }
  .pl-partner.is-main { grid-column: 1 / -1; }
  .pl-partner.span-tail { grid-column: 1 / -1; }
  .pl-partner .r { font-size: .68rem; }
  .pl-logo { height: 30px; }
  .pl-logo-row b { font-size: 1.1rem; }
}

/* ---------- Адмінка та кабінет організатора (світла тема) ---------- */
body.pl-app { --accent: #1E1E1E; --accent-2: #000; --accent-soft: color-mix(in srgb, var(--yellow) 35%, transparent); --gold: #1E1E1E; }
body.pl-app .app-main { padding-block: 2rem 4rem; }
body.pl-app .pl-wrap, body.pl-app .container { width: min(100% - 2 * var(--pl-gut), 1320px); }
body.pl-app .pl-nav .faint { color: rgba(30,30,30,.65); font-size: .9rem; }
body.pl-app .pl-nav .btn { background: var(--offblack); border-color: var(--offblack); color: var(--cream); border-radius: 999px; }
body.pl-app .tabs { border-bottom: 2px solid rgba(30,30,30,.1); gap: .3rem; }
body.pl-app .tab { color: rgba(30,30,30,.6); font-weight: 600; border-bottom-width: 3px; }
body.pl-app .tab[aria-selected="true"] { color: var(--offblack); border-bottom-color: var(--yellow); }
body.pl-app .card, body.pl-app .metric, body.pl-app .table-wrap { background: #fff; border: 1px solid rgba(30,30,30,.08); border-radius: 18px; }
body.pl-app .metric .v { color: var(--offblack); }
body.pl-app .table th { background: #FBF7E8; color: rgba(30,30,30,.6); }
body.pl-app .table tr:hover td { background: #FFFCF1; }
body.pl-app .empty { background: #fff; border-color: rgba(30,30,30,.15); color: var(--muted-d); }
body.pl-app .btn { border-radius: 999px; border-color: rgba(30,30,30,.2); color: var(--offblack); background: #fff; }
body.pl-app .btn:hover { border-color: var(--offblack); }
body.pl-app .btn-primary { background: var(--offblack); border-color: var(--offblack); color: var(--cream); }
body.pl-app .btn-primary:hover { background: #000; color: var(--cream); }
body.pl-app .btn-danger { border-color: #C2410C; color: #C2410C; background: #fff; }
body.pl-app .btn-ghost { background: transparent; border-color: transparent; }
body.pl-app .status-open { color: #166534; }
body.pl-app .demo-badge { border-color: #B45309; color: #B45309; }
body.pl-app .eyebrow { color: rgba(30,30,30,.6); }
body.pl-app .alert-warn { background: #FEF3C7; border-color: #F59E0B; color: #78350F; }
body.pl-app .alert-err { background: #FEE2E2; border-color: #EF4444; color: #7F1D1D; }
body.pl-app .alert-ok { background: #DCFCE7; border-color: #22C55E; color: #14532D; }
body.pl-light .dialog-panel { background: var(--cream); color: var(--offblack); border-color: rgba(30,30,30,.1); }
body.pl-light .dialog-close { color: var(--offblack); border-color: rgba(30,30,30,.2); }
body.pl-app .login-card { max-width: 460px; margin: 3rem auto; padding: 2rem; }
body.pl-app h2 { font-weight: 700; letter-spacing: -.03em; }

/* ---------- Скріншот донату ---------- */
.proof-step { display: grid; gap: .6rem; padding: 1rem 1.1rem; border-radius: 14px; border: 1px dashed var(--line-strong); }
.proof-box { display: grid; gap: .7rem; }
.proof-box .proof-head { margin: 0; color: var(--text-2); line-height: 1.5; }
.proof-box .proof-ok { margin: 0; font-weight: 700; color: #16a34a; }
.proof-row { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.proof-row .input { max-width: 190px; min-height: 44px; }
.proof-pick { position: relative; overflow: hidden; cursor: pointer; }
.proof-pick input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.proof-preview { max-height: 260px; width: auto; max-width: 100%; border-radius: 10px; border: 1px solid var(--line); }
.proof-full { display: block; max-width: 100%; max-height: 70vh; margin: 0 auto 1rem; border-radius: 12px; border: 1px solid var(--line); }

/* ---------- Адмінка: тема міста ---------- */
.theme-set { border: 0; padding: 0; margin: 0 0 1rem; }
.theme-set legend { font-weight: 600; font-size: .9rem; margin-bottom: .5rem; }
.swatches { display: flex; flex-wrap: wrap; gap: .5rem; }
.swatch { position: relative; width: 44px; height: 44px; border-radius: 50%; background: var(--sw); box-shadow: inset 0 0 0 1px rgba(30,30,30,.15); cursor: pointer; }
.swatch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.swatch:has(input:checked) { box-shadow: 0 0 0 3px var(--cream, #fff), 0 0 0 5px var(--offblack); }
.swatch:has(input:checked)::after { content: "✓"; position: absolute; inset: 0; display: grid; place-items: center; font-weight: 700; color: var(--offblack); }
.swatch:has(input:focus-visible) { outline: 2px solid var(--offblack); outline-offset: 4px; }
.star-up { display: grid; grid-template-columns: 180px 1fr; gap: 1.2rem; align-items: start; }
.star-up-prev { aspect-ratio: 1; border-radius: 20px; background: var(--sw); display: grid; place-items: center; padding: 14px; text-align: center; font-size: .85rem; color: rgba(30,30,30,.7); }
.star-up-prev img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 10px 14px rgba(0,0,0,.25)); }
.star-up-side { display: grid; gap: .6rem; }
@media (max-width: 560px) { .star-up { grid-template-columns: 1fr; } .star-up-prev { max-width: 200px; } }

/* ---------- Сторінка міста (тема з адмінки: --yellow = колір міста) ---------- */
body.is-city [data-home-only] { display: none !important; }
body:not(.is-city) [data-city-only] { display: none !important; }
.pl-hero-name { display: block; font-weight: 800; font-size: min(clamp(3rem, 1.6rem + 7vw, 7.5rem), calc((100vw - 2 * var(--pl-gut)) / (var(--len, 8) * .6))); line-height: .9; letter-spacing: -.055em; white-space: nowrap; }
.pl-hero-city { min-width: 0; }
.pl-hero-name.is-letter .wm-letter { width: clamp(240px, 64vw, 680px); }
.pl-hero-date .wm-letter { display: inline-block; height: .82em; }
.pl-map .marker.has-color .star { fill: var(--mc); stroke: var(--offblack); stroke-width: 1.2; vector-effect: non-scaling-stroke; }
.pl-city-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--mc, var(--offblack)); box-shadow: 0 0 0 1.5px var(--offblack); flex: none; }
.pl-city-info { min-width: 0; }
.pl-city > .pl-city-dot + .pl-city-info { margin-right: auto; }
@media (min-width: 1100px) { .pl-partners[data-count="6"] { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1100px) { body.is-city .pl-partners { grid-template-columns: 1.4fr repeat(var(--cols, 2), 1fr); } }
@media (min-width: 1100px) { body.is-city .pl-partners[data-count="6"] { grid-template-columns: repeat(3, 1fr); } }
body.city-pending .pl-hero-in, body.city-pending [data-home-only], body.city-pending .pl-brand { visibility: hidden; }
/* Кабінет на телефоні: таблиця не розпирає сторінку; на старті головне — номер, ім’я, донат і Check-in */
.app-grid > * { min-width: 0; }
@media (max-width: 640px) {
  .table:has(#p-body) th:nth-child(3), .table:has(#p-body) td:nth-child(3),
  .table:has(#p-body) th:nth-child(4), .table:has(#p-body) td:nth-child(4),
  .table:has(#p-body) th:nth-child(5), .table:has(#p-body) td:nth-child(5),
  .table:has(#p-body) th:nth-child(7), .table:has(#p-body) td:nth-child(7) { display: none; }
  .table:has(#p-body) th, .table:has(#p-body) td { padding-inline: .35rem; font-size: .88rem; }
  .table:has(#p-body) th { font-size: .66rem; letter-spacing: .04em; }
  .table:has(#p-body) td:first-child, .table:has(#p-body) th:first-child { padding-left: .6rem; }
  .table:has(#p-body) td .btn { min-height: 44px; padding: .25rem .55rem; font-size: .76rem; white-space: nowrap; }
  body.pl-app .pl-nav .faint { display: none; }
}
/* Кабінет: колонка донату — сума, статус, дія */
.don-cell { display: grid; gap: .35rem; justify-items: start; min-width: 150px; }
.don-sum { font-weight: 700; font-variant-numeric: tabular-nums; }
.don-acts { display: flex; flex-wrap: wrap; gap: .2rem .8rem; align-items: center; }
.pill { display: inline-flex; align-items: center; padding: .2rem .6rem; border-radius: 999px; font-size: .78rem; font-weight: 600; line-height: 1.3; white-space: nowrap; }
.pill-ok { background: #DCFCE7; color: #14532D; }
.pill-wait { background: #FEF3C7; color: #78350F; }
.pill-bad { background: #FEE2E2; color: #7F1D1D; }
.pill-none { background: rgba(30,30,30,.06); color: rgba(30,30,30,.7); }
.linkbtn { text-align: left; background: none; border: 0; padding: .35rem 0; min-height: 32px; font: inherit; font-size: .85rem; font-weight: 600; color: var(--offblack); text-decoration: underline; text-underline-offset: .2em; text-decoration-color: rgba(30,30,30,.35); cursor: pointer; }
.linkbtn:hover { text-decoration-color: var(--offblack); }
.table:has(#p-body) td { vertical-align: top; }
.table:has(#p-body) td .btn { white-space: nowrap; }
.table:has(#p-body) td.contact { white-space: nowrap; }
.table:has(#p-body) td.contact .mail { font-size: .82rem; }
.table:has(#p-body) .when { white-space: nowrap; font-size: .82rem; }
.linkbtn.linkbtn-danger { color: #B3261E; }
@media (max-width: 640px) { .don-cell { min-width: 0; } .don-cell .pill { white-space: normal; font-size: .72rem; } .table:has(#p-body) td:nth-child(2) { max-width: 7.5rem; overflow-wrap: break-word; hyphens: auto; } }
/* Адмінка: партнери міста */
.partners-edit { display: grid; gap: .8rem; }
.partner-row { display: grid; grid-template-columns: 96px 1fr; gap: .9rem; align-items: start; padding: .8rem; border: 1px solid rgba(30,30,30,.1); border-radius: 14px; background: #fff; }
.partner-logo { width: 96px; height: 64px; border-radius: 10px; background: #F6F3E8; display: grid; place-items: center; padding: 6px; font-size: .75rem; color: rgba(30,30,30,.6); text-align: center; }
.partner-logo img { max-width: 100%; max-height: 100%; object-fit: contain; }
.partner-fields { display: grid; gap: .45rem; }
.partner-fields .input { min-height: 40px; }
.partner-fields label.btn { cursor: pointer; }
@media (max-width: 560px) { .partner-row { grid-template-columns: 1fr; } }
/* Сайт: партнери міста — лого на світлій плашці, щоб будь-який логотип було видно на темному тлі */
.pl-partner-logo-tile { display: grid; place-items: center; background: var(--cream); border-radius: 12px; height: 72px; padding: 10px 14px; }
.pl-partner-logo-tile img { height: 44px; width: auto; max-width: 100%; object-fit: contain; }
.pl-partner b.pl-partner-name { font-size: 1.15rem; letter-spacing: -.01em; }
/* Футер: пропозиція платформи для організаторів забігів */
.pl-platform { display: grid; gap: 1.4rem; padding-bottom: 2.2rem; margin-bottom: 2.2rem; border-bottom: 1px solid rgba(255,252,241,.12); }
@media (min-width: 900px) { .pl-platform { grid-template-columns: 1fr auto; align-items: end; gap: 3rem; } }
.pl-platform .pl-eyebrow { color: var(--yellow); opacity: 1; margin-bottom: .6rem; }
.pl-platform-h { font-size: clamp(1.4rem, 1rem + 1.4vw, 2rem); font-weight: 700; letter-spacing: -.025em; line-height: 1.15; margin: 0 0 .6rem; max-width: 26ch; }
.pl-platform .pl-muted { color: var(--muted-l); max-width: 56ch; }
.pl-platform-links { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.pl-platform-links a { display: inline-flex; align-items: center; min-height: 44px; padding: .5rem 1.1rem; border: 1.5px solid rgba(255,252,241,.35); border-radius: 999px; color: var(--cream); text-decoration: none; font-weight: 600; font-size: .95rem; }
.pl-platform-links a:hover { border-color: var(--yellow); color: var(--yellow); }
