/* WYD registration — single hand-written stylesheet (no build step, shared-hosting friendly).
   Theme follows the WYD Seoul 2027 logo: blue #0047bb, red #f32735, sun yellow #fce64d, black. Calm surfaces, colour used sparingly. */
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/plus-jakarta-sans-latin-ext-400-normal.woff2") format("woff2"); unicode-range: U+0100-02AF, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/plus-jakarta-sans-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/plus-jakarta-sans-latin-500-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/plus-jakarta-sans-latin-ext-700-normal.woff2") format("woff2"); unicode-range: U+0100-02AF, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/plus-jakarta-sans-latin-700-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-weight: 800; font-display: swap; src: url("fonts/plus-jakarta-sans-latin-ext-800-normal.woff2") format("woff2"); unicode-range: U+0100-02AF, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Plus Jakarta Sans"; font-style: normal; font-weight: 800; font-display: swap; src: url("fonts/plus-jakarta-sans-latin-800-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
:root {
  --brand: #0047bb;
  --brand-ink: #fff;
  --brand-soft: color-mix(in srgb, var(--brand) 7%, #fff);
  --brand-dark: color-mix(in srgb, var(--brand) 80%, #000);
  --link: var(--brand);
  --accent: #f32735;
  --sun: #fce64d;
  --sun-soft: #fff7c8;
  --ink: #12162b;
  --ink-2: #3b4158;
  --muted: #636a80;
  --line: #e3e6f0;
  --line-strong: #cdd2e0;
  --field: #fff;
  --bg: #f7f8fc;
  --card: #fff;
  --ok: #0f7b4b; --ok-bg: #e4f6ec;
  --bad: #b42318; --bad-bg: #fdecea;
  --warn: #8a5300; --warn-bg: #fff3cc;
  --info: #0047bb; --info-bg: #e7efff;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(18, 22, 43, .04), 0 4px 14px rgba(18, 22, 43, .05);
  --tri: linear-gradient(90deg, var(--accent) 0 33.4%, var(--sun) 33.4% 66.7%, var(--brand) 66.7%);
  --font: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --brand-soft: color-mix(in srgb, var(--brand) 24%, #0d1226);
    --link: color-mix(in srgb, var(--brand) 45%, #fff);
    --sun-soft: #2b2710;
    --ink: #e8eaf4; --ink-2: #c6cadc; --muted: #9aa1bb; --line: #252c47; --line-strong: #323b5e; --field: #0c1226; --bg: #0b0f1f; --card: #121831;
    --ok: #4ade80; --ok-bg: #0f2a1d; --bad: #fca5a5; --bad-bg: #331616; --warn: #fcd34d; --warn-bg: #33270a; --info: #9db9ff; --info-bg: #14234a;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4);
  }
  .site-footer, .sidebar { background: #080b18; }
  .sig-pad { background: #fff; }
  .logo-badge { background: #fff; padding: 2px 6px; }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 16px/1.55 var(--font); color: var(--ink); background: var(--bg); min-height: 100vh; display: flex; flex-direction: column; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.015em; font-weight: 800; }
h1 { font-size: clamp(1.7rem, 3.4vw, 2.3rem); }
h2 { font-size: 1.22rem; } h3 { font-size: 1.04rem; margin-top: 1.4em; font-weight: 700; } h4 { font-size: .95rem; margin-top: 1.2em; color: var(--ink-2); font-weight: 700; }
p { margin: 0 0 .9em; }
a { color: var(--link); text-underline-offset: 3px; }
a:hover { color: color-mix(in srgb, var(--link) 78%, #000); }
code, .mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .88em; }
code { background: var(--brand-soft); padding: .1em .35em; border-radius: 4px; word-break: break-all; }
img { max-width: 100%; }
.nowrap { white-space: nowrap; }
.muted { color: var(--muted); } .small { font-size: .86rem; } .center { text-align: center; } .num { text-align: right; white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 0; background: var(--brand); color: #fff; padding: .5em 1em; z-index: 100; }
.skip:focus { left: 0; }
.hp { position: absolute; left: -5000px; height: 0; overflow: hidden; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--brand) 55%, transparent); outline-offset: 2px; }

.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.main { flex: 1; padding-top: 24px; padding-bottom: 48px; }

/* header / footer */
.site-header { background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.site-header::before, .site-footer::before { content: ""; display: block; height: 4px; background: var(--tri); }
.bar { display: flex; align-items: center; gap: 16px; min-height: 64px; flex-wrap: wrap; padding-top: 6px; padding-bottom: 6px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; letter-spacing: -.01em; color: var(--ink); text-decoration: none; }
.brand:hover { color: var(--ink); }
.brand img { display: block; height: 48px; width: auto; }
.logo-badge { border-radius: 12px; }
.nav { display: flex; gap: 4px; flex: 1; flex-wrap: wrap; }
.nav a { color: var(--ink-2); text-decoration: none; padding: 8px 14px; border-radius: 999px; font-weight: 600; font-size: .95rem; }
.nav a:hover { background: var(--brand-soft); color: var(--link); }
.nav a[aria-current="page"] { background: var(--brand-soft); color: var(--link); }
.bar-end { display: flex; align-items: center; gap: 8px; margin-inline-start: auto; }
.lang-form select { padding: 6px 28px 6px 12px; font-size: .9rem; width: auto; border-radius: 999px; }
.site-footer { background: #0b1030; color: #cbd2ec; padding: 0 0 22px; font-size: .9rem; }
.site-footer .foot { padding-top: 22px; align-items: center; }
.foot-brand { display: inline-flex; align-items: center; gap: 12px; }
.foot-brand img { height: 38px; width: auto; background: #fff; border-radius: 10px; padding: 3px 6px; }
.site-footer a { color: #e6e9fb; }
.foot { display: flex; gap: 16px; justify-content: space-between; flex-wrap: wrap; }
.foot-links { display: flex; gap: 16px; flex-wrap: wrap; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--brand); background: var(--brand); color: var(--brand-ink); padding: 10px 22px; border-radius: 999px; font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; line-height: 1.2; transition: filter .15s, background .15s, transform .15s; }
.btn:hover { filter: brightness(1.08); color: var(--brand-ink); }
.btn:active { transform: translateY(1px); }
.btn[disabled], .btn[aria-busy="true"] { opacity: .55; cursor: not-allowed; }
.btn-ghost { background: transparent; color: var(--link); border-color: var(--line-strong); }
.btn-ghost:hover { background: var(--brand-soft); color: var(--link); filter: none; }
.btn-ok { background: var(--ok); border-color: var(--ok); color: #fff; }
.btn-bad { background: var(--bad); border-color: var(--bad); color: #fff; }
.btn-warn { background: #b45f06; border-color: #b45f06; color: #fff; }
.btn-sun { background: var(--sun); border-color: var(--sun); color: #12162b; }
.btn-sun:hover { color: #12162b; }
.btn-ok:hover, .btn-bad:hover, .btn-warn:hover { color: #fff; }
@media (prefers-color-scheme: dark) { .btn-ok { background: #15803d; } .btn-bad { background: #b91c1c; } }
.btn-sm { padding: 6px 14px; font-size: .88rem; }
.btn-lg { padding: 14px 30px; font-size: 1.05rem; }
.btn-block { display: flex; width: 100%; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.actions.center { justify-content: center; }
form.inline { display: inline; }
.link-danger { background: none; border: 0; color: var(--bad); cursor: pointer; padding: 0 4px; }

/* cards / layout */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); margin-bottom: 18px; }
.card > :last-child { margin-bottom: 0; }
.card.narrow, .narrow { max-width: 480px; margin-inline: auto; }
.form-card { max-width: 760px; margin-inline: auto; padding: 30px; }
.form-wide { max-width: 980px; }
.table-card { padding: 0; overflow: hidden; }
.grid { display: grid; gap: 16px; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.cards { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.two-wide { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.grid > *, .two-wide > *, .review-grid > *, .template-grid > * { min-width: 0; }
.span-2 { grid-column: span 2; }
.stack { display: flex; flex-direction: column; gap: 0; } .stack-sm { display: flex; flex-direction: column; gap: 10px; }
.top-gap { margin-top: 12px; }
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.page-head h1 { margin-bottom: .2em; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.section-head h2 { margin: 0; font-size: clamp(1.35rem, 2.6vw, 1.7rem); }
.section-head p { margin: 0; }
.lead { font-size: 1.1rem; color: var(--ink-2); }
.section { margin: 56px 0; scroll-margin-top: 84px; }
.big-code { font-size: 4rem; font-weight: 800; color: var(--link); margin: 0; line-height: 1; }
.big-icon { display: inline-flex; align-items: center; justify-content: center; width: 72px; height: 72px; border-radius: 50%; background: var(--brand-soft); color: var(--link); margin-bottom: 8px; }
.big-icon.ok { background: var(--ok-bg); color: var(--ok); } .big-icon.bad { background: var(--bad-bg); color: var(--bad); }
.icon { vertical-align: -3px; flex: none; }
.debug { text-align: left; white-space: pre-wrap; background: var(--bad-bg); padding: 12px; border-radius: 8px; font-size: .8rem; }

/* home */
.hero { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, .7fr); gap: 36px; align-items: center; padding: 20px 0 8px; }
.hero h1 { font-size: clamp(2.1rem, 5.2vw, 3.4rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.06; margin-bottom: .35em; }
.hero .lead { max-width: 560px; font-size: 1.12rem; }
.hero .actions { margin-top: 24px; }
.hero-art { margin: 0; justify-self: center; width: 100%; max-width: 340px; background: #fff; border-radius: 32px; padding: 22px 26px; box-shadow: 0 2px 4px rgba(18, 22, 43, .04), 0 18px 40px rgba(0, 71, 187, .12); display: grid; place-items: center; }
.hero-art img { display: block; width: 100%; max-width: 250px; height: auto; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 5px 14px 5px 10px; border-radius: 999px; background: var(--sun-soft); color: var(--ink); font-size: .78rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; margin-bottom: 1.1em; }
.eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 0; padding: 0; list-style: none; }
.chip { display: inline-flex; align-items: center; gap: 7px; padding: 6px 14px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); font-weight: 600; font-size: .9rem; color: var(--ink-2); }
.chip .icon { color: var(--link); }
.about { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: 36px; align-items: start; }
.about p { color: var(--ink-2); font-size: 1.04rem; }
.quote { margin: 0 0 16px; padding: 20px 22px; background: var(--card); border: 1px solid var(--line); border-left: 5px solid var(--sun); border-radius: var(--radius); box-shadow: var(--shadow); }
.quote p { margin: 0 0 .4em; font-size: 1.25rem; font-weight: 700; line-height: 1.35; color: var(--ink); letter-spacing: -.01em; }
.quote cite { font-style: normal; color: var(--muted); font-size: .9rem; font-weight: 600; }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 0; }
.fact { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px 10px; text-align: center; }
.fact dt { font-weight: 800; font-size: 1.1rem; color: var(--link); letter-spacing: -.01em; line-height: 1.2; }
.fact dd { margin: 2px 0 0; color: var(--muted); font-size: .78rem; font-weight: 500; line-height: 1.3; }
.program { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.pg-item { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 18px; align-items: center; background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--brand); border-radius: var(--radius); padding: 12px 18px 12px 12px; box-shadow: var(--shadow); }
.pg-item:nth-child(3n+2) { border-left-color: var(--accent); }
.pg-item:nth-child(3n) { border-left-color: var(--sun); }
.pg-date { text-align: center; background: var(--brand-soft); border-radius: 12px; padding: 8px 4px; line-height: 1.15; }
.pg-day { display: block; font-size: 1.7rem; font-weight: 800; color: var(--link); letter-spacing: -.02em; }
.pg-mon { display: block; font-size: .76rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-2); }
.pg-to { display: block; font-size: .72rem; font-weight: 600; color: var(--muted); margin-top: 2px; }
.pg-body h3 { margin: 0 0 .2em; font-size: 1.08rem; }
.pg-body p { margin: 0; color: var(--ink-2); font-size: .95rem; }
.pg-when { display: block; font-size: .8rem; font-weight: 600; color: var(--muted); margin-bottom: 2px; }
.program-note { margin-top: 12px; }
.steps { list-style: none; counter-reset: s; padding: 0; margin: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.steps li { display: flex; gap: 14px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; }
.steps p { margin: .2em 0 0; color: var(--muted); font-size: .93rem; }
.step-n { flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--brand); color: #fff; display: grid; place-items: center; font-weight: 800; }
.pkg { display: flex; flex-direction: column; margin-bottom: 0; } .pkg h3 { margin-top: 0; font-size: 1.15rem; }
.price { font-size: 1.8rem; font-weight: 800; letter-spacing: -.03em; color: var(--link); display: block; margin: .1em 0 .5em; }
.pkg-desc { color: var(--ink-2); white-space: normal; flex: 1; }
.pkg .btn { margin-top: auto; }
.cta-band { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; background: var(--brand); color: #fff; border-radius: 24px; padding: 28px 32px; }
.cta-band h2 { margin: 0 0 .15em; font-size: 1.5rem; color: #fff; } .cta-band p { margin: 0; color: color-mix(in srgb, #fff 82%, var(--brand)); }

/* forms */
.field { margin-bottom: 14px; }
label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 5px; }
input:not([type]), input[type=text], input[type=email], input[type=tel], input[type=url], input[type=number], input[type=date], input[type=datetime-local], input[type=password], input[type=search], select, textarea {
  width: 100%; padding: 10px 14px; border: 1px solid var(--line-strong); border-radius: 12px; font: inherit; background: var(--field); color: var(--ink); }
textarea { resize: vertical; }
input[type=color] { width: 64px; height: 40px; padding: 2px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--field); }
input[type=file] { width: 100%; padding: 10px; border: 1px dashed var(--line-strong); border-radius: 12px; background: var(--brand-soft); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 25%, transparent); }
.has-error input, .has-error select, .has-error textarea { border-color: var(--bad); }
.hint { color: var(--muted); font-size: .84rem; margin: 4px 0 0; }
.err { color: var(--bad); font-size: .87rem; margin: 4px 0 0; font-weight: 500; }
.req { color: var(--bad); }
.field.check { margin-bottom: 10px; }
.check-label { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; cursor: pointer; margin-bottom: 6px; }
.check-label input { margin-top: 4px; width: 18px; height: 18px; flex: none; accent-color: var(--brand); }
fieldset { border: 0; padding: 0; margin: 0 0 14px; min-width: 0; } legend { font-weight: 600; margin-bottom: 8px; padding: 0; }
.form-actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin: 8px 0 24px; }
.callout { display: flex; gap: 12px; align-items: flex-start; background: var(--brand-soft); border: 1px solid color-mix(in srgb, var(--brand) 22%, var(--line)); border-radius: 14px; padding: 12px 14px; margin: 14px 0; }
.callout > .icon { margin-top: 3px; color: var(--link); } .callout p { margin: 0; } .callout > div, .callout > span { flex: 1; }
.pkg-choice { display: grid; gap: 10px; }
.pkg-option, .option-card { display: flex; gap: 12px; align-items: flex-start; border: 2px solid var(--line); border-radius: 14px; padding: 14px; cursor: pointer; font-weight: 400; background: var(--card); }
.pkg-option:has(input:checked), .option-card:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.pkg-option.disabled { opacity: .55; cursor: not-allowed; }
.pkg-option input, .option-card > input { margin-top: 4px; accent-color: var(--brand); width: 18px; height: 18px; flex: none; }
.pkg-body, .opt-body { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.pkg-body .price { font-size: 1.15rem; margin: 0; }
.opt-body small { color: var(--muted); }
.plans { display: grid; gap: 10px; margin-bottom: 8px; }
.preview { display: flex; flex-direction: column; gap: 2px; margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line); font-size: .86rem; }
.pv-row { display: flex; justify-content: space-between; gap: 12px; color: var(--ink-2); }
.regform .ins1, .regform[data-ins="0"] .ins1 { display: none; }
.regform[data-ins="1"] .ins1 { display: flex; }
.regform[data-ins="1"] .ins0 { display: none; }
.regform span.ins0, .regform span.ins1 { display: none; }
.regform[data-ins="0"] span.ins0 { display: inline; } .regform[data-ins="1"] span.ins1 { display: inline; }
.segmented { display: inline-flex; border: 1px solid var(--line-strong); border-radius: 999px; overflow: hidden; margin-bottom: 12px; }
.segmented label { margin: 0; padding: 8px 16px; cursor: pointer; font-weight: 600; }
.segmented input { position: absolute; opacity: 0; }
.segmented label:has(input:checked) { background: var(--brand); color: #fff; }
.sig-wrap { position: relative; border: 2px dashed var(--line-strong); border-radius: 14px; background: #fff; touch-action: none; }
.sig-pad { display: block; width: 100%; height: 160px; touch-action: none; cursor: crosshair; }
.sig-clear { position: absolute; top: 8px; right: 8px; }
.upload-preview { margin-top: 10px; border-radius: 10px; border: 1px solid var(--line); max-height: 260px; }
.tips { padding-left: 1.2em; margin: .4em 0 1em; color: var(--ink-2); } .tips li { margin-bottom: .3em; }

/* badges / alerts */
.badge { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .78rem; font-weight: 600; line-height: 1.6; text-decoration: none; white-space: nowrap; }
.badge-ok { background: var(--ok-bg); color: var(--ok); } .badge-bad { background: var(--bad-bg); color: var(--bad); }
.badge-warn { background: var(--warn-bg); color: var(--warn); } .badge-info { background: var(--info-bg); color: var(--info); }
.alert { padding: 12px 16px; border-radius: 10px; margin-bottom: 16px; border: 1px solid transparent; }
.alert-success { background: var(--ok-bg); color: var(--ok); border-color: color-mix(in srgb, var(--ok) 25%, transparent); }
.alert-error { background: var(--bad-bg); color: var(--bad); border-color: color-mix(in srgb, var(--bad) 25%, transparent); }
.alert-warn { background: var(--warn-bg); color: var(--warn); border-color: color-mix(in srgb, var(--warn) 25%, transparent); }
.alert-info { background: var(--info-bg); color: var(--info); border-color: color-mix(in srgb, var(--info) 25%, transparent); }
.ok-text { color: var(--ok); }

/* tables */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: .93rem; }
.table th { text-align: left; font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); padding: 10px 14px; border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--bg) 60%, var(--card)); white-space: nowrap; }
.table td { padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table tr:last-child td { border-bottom: 0; }
.table th.num, .table td.num { text-align: right; }
.table.compact td, .table.compact th { padding: 7px 10px; }
.table.compact td:first-child { white-space: nowrap; }
.row-bad td { background: var(--bad-bg); }
.pager { display: flex; gap: 12px; align-items: center; justify-content: center; margin: 16px 0; }
.filters { padding: 12px; } .filter-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; } .filter-row > * { width: auto; flex: 0 1 auto; } .filter-row input[type=search] { flex: 1 1 200px; }
.list { list-style: none; margin: 0 0 .8em; padding: 0; } .list li { padding: 8px 0; border-bottom: 1px solid var(--line); } .list li:last-child { border-bottom: 0; }
.kv { display: grid; grid-template-columns: minmax(110px, 38%) 1fr; gap: 8px 14px; margin: 0 0 1em; }
.kv dt { color: var(--muted); font-size: .88rem; } .kv dd { margin: 0; font-weight: 500; word-break: break-word; }
.kv.compact { gap: 5px 14px; font-size: .93rem; }
.count-pill, .count { display: inline-block; background: var(--brand); color: #fff; border-radius: 999px; padding: 0 8px; font-size: .78rem; font-weight: 700; line-height: 1.6; }

/* timeline */
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 15px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.tl-item { position: relative; display: flex; gap: 14px; padding: 0 0 18px; }
.tl-dot { flex: none; width: 32px; height: 32px; border-radius: 50%; background: var(--card); border: 2px solid var(--line); display: grid; place-items: center; color: var(--muted); z-index: 1; }
.tl-item.latest .tl-dot { border-color: var(--brand); color: var(--link); background: var(--brand-soft); }
.tli-check .tl-dot, .tli-euro .tl-dot { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 50%, var(--line)); }
.tli-x .tl-dot { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 50%, var(--line)); }
.tl-body { flex: 1; min-width: 0; padding-top: 3px; } .tl-body time { display: block; font-size: .82rem; color: var(--muted); } .tl-body p { margin: .3em 0 0; color: var(--ink-2); font-size: .93rem; }
.tl-private .tl-body { opacity: .85; }

/* money */
.balance { margin-bottom: 8px; } .bal-row { display: flex; justify-content: space-between; padding: 5px 0; font-size: 1.02rem; }
.progress { height: 10px; background: var(--line); border-radius: 99px; overflow: hidden; margin: 6px 0; } .progress.sm { height: 6px; max-width: 160px; } .progress.wide { max-width: 320px; }
.progress span { display: block; height: 100%; background: var(--brand); border-radius: 99px; }
.pay-actions { display: grid; gap: 10px; margin: 14px 0 8px; }
.next-step { border-left: 5px solid var(--sun); } .next-step h2 { display: flex; gap: 8px; align-items: center; font-size: 1.3rem; }
.doc-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; } .doc-head h2 { margin: 0; }
.doc-list { list-style: none; margin: 0; padding: 0; } .doc-list li { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; } .doc-list li > span { flex: 1; }
.doc-row { padding: 10px 0; border-bottom: 1px solid var(--line); } .doc-row .links { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 6px; }

/* admin shell */
body.admin { display: block; }
.admin-shell { display: grid; grid-template-columns: 240px minmax(0, 1fr); min-height: 100vh; }
.sidebar { background: #0b1030; color: #cbd2ec; padding: 18px 12px; display: flex; flex-direction: column; gap: 16px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.sidebar .brand { color: #fff; flex-direction: row; align-items: center; gap: 10px; padding: 4px 8px; } .sidebar .brand:hover { color: #fff; } .sidebar .brand img { height: 46px; background: #fff; border-radius: 10px; padding: 3px 6px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; } .sidebar .brand small { color: #a4acd0; font-weight: 500; }
.sidebar nav { display: flex; flex-direction: column; gap: 2px; }
.sidebar nav a { display: flex; gap: 10px; align-items: center; color: #cbd2ec; text-decoration: none; padding: 9px 14px; border-radius: 999px; font-weight: 600; font-size: .95rem; }
.sidebar nav a:hover { background: rgba(255, 255, 255, .07); } .sidebar nav a.active { background: var(--brand); color: #fff; }
.sidebar nav .count { margin-left: auto; background: var(--sun); color: #1f1a00; }
.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 10px; font-size: .88rem; padding: 0 6px; }
.side-foot .who small { display: block; color: #a4acd0; word-break: break-all; } .side-foot .btn-ghost { color: #e6e9fb; border-color: #343c66; width: 100%; }
.side-foot select { background: #151b42; color: #e6e9fb; border-color: #343c66; }
.admin-main { min-width: 0; }
.admin-top { display: flex; align-items: center; gap: 12px; padding: 18px 24px 14px; background: var(--tri) top / 100% 4px no-repeat, var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10; }
.admin-top h1 { font-size: 1.25rem; margin: 0; flex: 1; } .tz { font-size: .82rem; color: var(--muted); background: var(--brand-soft); padding: 3px 10px; border-radius: 99px; }
.nav-toggle { display: none; }
.admin-content { padding: 22px 24px 60px; max-width: 1280px; }
.tabs { display: flex; gap: 4px; flex-wrap: wrap; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.tabs a { padding: 9px 11px; text-decoration: none; color: var(--ink-2); font-weight: 700; font-size: .92rem; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.tabs a.active { color: var(--link); border-color: var(--brand); } .tabs a:hover { color: var(--link); }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; margin-bottom: 18px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; text-decoration: none; color: var(--ink); box-shadow: var(--shadow); display: flex; flex-direction: column; }
.stat:hover { border-color: var(--brand); } .stat.attention { border-color: #e0a100; background: var(--warn-bg); }
.stat-n { font-size: 1.9rem; font-weight: 800; line-height: 1.1; } .stat-l { color: var(--muted); font-size: .85rem; }
.kpi { display: flex; flex-direction: column; gap: 2px; margin: 0; } .kpi strong { font-size: 1.7rem; letter-spacing: -.02em; } .kpi.bad strong { color: var(--bad); }
.checklist ul, .checks-list { list-style: none; margin: 0; padding: 0; } .checklist li, .checks-list li { padding: 5px 0; } .checklist li .icon, .checks-list li .icon { margin-inline-end: 6px; }
li.done .icon { color: var(--ok); } li.todo .icon { color: var(--bad); }
.review-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 18px; align-items: start; }
.passport-img { width: 100%; border-radius: 10px; border: 1px solid var(--line); }
.pdf-frame { width: 100%; height: 520px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.checkable .cmp { background: color-mix(in srgb, #f59e0b 16%, transparent); border-radius: 6px; padding: 1px 6px; font-weight: 700; }
.checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 4px 20px; margin-bottom: 14px; }
.review-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.decide { white-space: nowrap; } .decide form { display: inline-block; margin: 2px 0; } .inline-decline { display: inline-flex; gap: 6px; } .inline-decline input { width: 160px; padding: 5px 8px; }
.note-form { display: flex; gap: 8px; margin-top: 12px; } .note-form input { flex: 1; }
.manual-pay { margin-top: 14px; } summary { cursor: pointer; font-weight: 600; padding: 6px 0; }
.danger-zone { border-color: color-mix(in srgb, var(--bad) 35%, var(--line)); }
.legend { display: flex; gap: 8px; margin: 8px 0 14px; }
.template-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.template-grid textarea { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .85rem; line-height: 1.5; }
.mail-preview { width: 100%; height: 520px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.vars { list-style: none; padding: 0; margin: 0 0 8px; } .vars li { padding: 4px 0; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
pre.code { background: #0b1030; color: #e6e9fb; padding: 12px; border-radius: 8px; overflow-x: auto; font-size: .82rem; white-space: pre-wrap; word-break: break-all; }
.opt-card { border: 1px solid var(--line); border-radius: 12px; padding: 14px; margin-bottom: 14px; } .opt-card legend { font-weight: 700; padding: 0 8px; }
.opt-new { border-style: dashed; } .opt-flags { display: flex; gap: 24px; flex-wrap: wrap; }
.lang-row { align-items: start; }
.trans-head { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: flex-start; }
.trans-list { display: flex; flex-direction: column; }
.trans-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.trans-row.has-error { background: var(--bad-bg); } .trans-row.changed { background: var(--warn-bg); }
.trans-src p { margin: .2em 0 0; color: var(--ink-2); } .key { font-size: .74rem; color: var(--muted); }
.sticky-actions { position: sticky; bottom: 0; background: var(--card); border-top: 1px solid var(--line); padding: 12px 16px; display: flex; gap: 14px; align-items: center; }
.device { display: flex; justify-content: space-between; gap: 10px; align-items: center; }
.pad { padding: 24px; }
.import-form label { margin: 0; }

@media (max-width: 860px) {
  .grid.two, .grid.three, .two-wide, .review-grid, .template-grid, .trans-row { grid-template-columns: 1fr; }
  .span-2 { grid-column: auto; }
  .admin-shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; inset: 0 auto 0 0; width: 260px; z-index: 40; transform: translateX(-105%); transition: transform .2s; }
  .sidebar.open { transform: none; box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .45); }
  .nav-toggle { display: inline-flex; }
  .admin-content { padding: 16px 14px 48px; } .admin-top { padding: 10px 14px; }
  .hero { grid-template-columns: 1fr; gap: 20px; padding-top: 4px; } .hero-art { order: -1; max-width: 190px; padding: 14px 16px; border-radius: 24px; justify-self: start; } .hero-art img { max-width: 160px; }
  .about { grid-template-columns: 1fr; gap: 20px; } .section { margin: 40px 0; }
  .pg-item { grid-template-columns: 74px minmax(0, 1fr); gap: 14px; } .pg-day { font-size: 1.45rem; }
  .cta-band { padding: 22px 20px; border-radius: 20px; }
  .form-card { padding: 18px; }
  .kv { grid-template-columns: 1fr; gap: 0; } .kv dt { margin-top: 8px; }
  .bar { gap: 8px; } .brand { flex: 1; min-width: 0; } .brand span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .nav { order: 3; flex: 1 1 100%; overflow-x: auto; flex-wrap: nowrap; } .nav a { white-space: nowrap; }
  .bar-end { margin-inline-start: 0; }
  .decide { white-space: normal; }
}
@media print { .site-header, .site-footer, .sidebar, .admin-top, .btn { display: none !important; } body { background: #fff; } }
[dir="rtl"] .timeline::before { left: auto; right: 15px; }
