/* Emro Science — public site */
:root {
  --ink: #0d1424;
  --ink-2: #1c2538;
  --text: #1f2737;
  --muted: #5d6779;
  --faint: #8a93a3;
  --line: #e4e2dc;
  --line-2: #efede8;
  --bg: #fbfaf7;
  --surface: #ffffff;
  --surface-2: #f4f2ed;
  --brand: #2f4fd8;
  --brand-ink: #213bb0;
  --brand-soft: #e9edfd;
  --accent: #c2410c;
  --ok: #15803d;
  --ok-soft: #e7f6ec;
  --warn: #b45309;
  --warn-soft: #fdf3e2;
  --bad: #b91c1c;
  --bad-soft: #fdecec;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(13, 20, 36, .05), 0 8px 24px -12px rgba(13, 20, 36, .14);
  --shadow-lg: 0 24px 60px -24px rgba(13, 20, 36, .35);
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --wrap: 1180px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #eef1f7;
    --ink-2: #d5dae5;
    --text: #d9dee8;
    --muted: #9ba5b7;
    --faint: #6f798b;
    --line: #262f42;
    --line-2: #1e2636;
    --bg: #0b1020;
    --surface: #111829;
    --surface-2: #161e31;
    --brand: #7b93ff;
    --brand-ink: #a5b4ff;
    --brand-soft: #1b2546;
    --accent: #fb923c;
    --ok: #4ade80;
    --ok-soft: #12291c;
    --warn: #fbbf24;
    --warn-soft: #2c2312;
    --bad: #f87171;
    --bad-soft: #2f1517;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px -12px rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font: 400 16px/1.6 var(--sans);
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { max-width: 100%; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-ink); }
h1, h2, h3, h4 { color: var(--ink); margin: 0 0 .5em; line-height: 1.2; letter-spacing: -.01em; }
h1, h2 { font-family: var(--serif); font-weight: 600; }
p { margin: 0 0 1em; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.section { padding: 72px 0; }
.section-tight { padding: 40px 0; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 12px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--brand);
  margin-bottom: 14px;
}
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 28px; flex-wrap: wrap; }
.section-head h2 { font-size: clamp(26px, 3vw, 34px); margin: 0; }
.section-head p { color: var(--muted); margin: 6px 0 0; max-width: 60ch; }
.muted { color: var(--muted); }
.small { font-size: 14px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; gap: 22px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); flex-shrink: 0; }
.brand:hover { color: var(--ink); }
.brand-mark { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; background: var(--ink); color: var(--bg); }
.brand-mark svg { width: 22px; height: 22px; }
.brand-name { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name strong { font: 700 16px/1.1 var(--sans); letter-spacing: -.01em; }
.brand-name span { font-size: 11.5px; color: var(--muted); letter-spacing: .02em; }
.nav-links { display: flex; align-items: center; gap: 4px; margin-left: 8px; }
.nav-links a, .nav-drop > summary {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 12px; border-radius: 8px; font-size: 14.5px; font-weight: 500; color: var(--text); cursor: pointer;
}
.nav-links a:hover, .nav-drop > summary:hover, .nav-links a.active { background: var(--surface-2); color: var(--ink); }
.nav-drop { position: relative; }
.nav-drop > summary { list-style: none; }
.nav-drop > summary::-webkit-details-marker { display: none; }
.nav-drop > summary svg { width: 14px; height: 14px; transition: transform .2s; }
.nav-drop[open] > summary svg { transform: rotate(180deg); }
.drop-menu {
  position: absolute; top: calc(100% + 8px); left: 0; min-width: 240px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 6px;
}
.drop-menu a { display: block; padding: 9px 12px; border-radius: 8px; font-size: 14.5px; color: var(--text); }
.drop-menu a:hover { background: var(--surface-2); color: var(--ink); }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.nav-search { position: relative; }
.nav-search input {
  width: 210px; height: 38px; padding: 0 12px 0 36px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--surface); color: var(--text); font: inherit; font-size: 14px; transition: width .2s, border-color .2s;
}
.nav-search input:focus { width: 260px; border-color: var(--brand); outline: none; }
.nav-search svg { position: absolute; left: 11px; top: 11px; width: 16px; height: 16px; color: var(--faint); pointer-events: none; }
.lang-drop .drop-menu { left: auto; right: 0; min-width: 170px; }
.lang-drop > summary { font-size: 13px; text-transform: uppercase; letter-spacing: .04em; border: 1px solid var(--line); height: 38px; }
.drop-menu a.current { color: var(--brand); font-weight: 600; }
.menu-toggle { display: none; background: none; border: 1px solid var(--line); border-radius: 10px; width: 40px; height: 38px; color: var(--ink); cursor: pointer; }
.menu-toggle svg { width: 20px; height: 20px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 20px; border-radius: 11px; border: 1px solid transparent;
  font: 600 15px/1 var(--sans); cursor: pointer; transition: transform .12s, background .2s, border-color .2s, box-shadow .2s;
  white-space: nowrap; text-decoration: none;
}
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 6px 18px -8px var(--brand); }
.btn-primary:hover { background: var(--brand-ink); color: #fff; }
.btn-dark { background: var(--ink); color: var(--bg); }
.btn-dark:hover { color: var(--bg); opacity: .9; }
.btn-ghost { background: var(--surface); border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--faint); color: var(--ink); }
.btn-tg { background: #229ed9; color: #fff; }
.btn-tg:hover { background: #1b8bc0; color: #fff; }
.btn-sm { height: 36px; padding: 0 14px; font-size: 14px; border-radius: 9px; }
.btn-lg { height: 52px; padding: 0 26px; font-size: 16px; border-radius: 13px; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; background: #0b1020; color: #e7ebf4; isolation: isolate; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(900px 480px at 85% -10%, rgba(87, 115, 255, .35), transparent 60%),
    radial-gradient(600px 400px at -5% 110%, rgba(194, 65, 12, .22), transparent 60%);
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: .5;
  background-image: linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse at 70% 30%, #000 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at 70% 30%, #000 20%, transparent 70%);
}
.hero-grid { display: grid; grid-template-columns: 1.25fr .9fr; gap: 56px; align-items: center; padding: 92px 0 100px; }
.hero h1 { color: #fff; font-size: clamp(36px, 5.2vw, 62px); line-height: 1.04; letter-spacing: -.02em; margin-bottom: 22px; }
.hero h1 em { font-style: italic; color: #a9b8ff; }
.hero .lead { font-size: clamp(17px, 1.6vw, 19px); color: #b9c2d6; max-width: 54ch; margin-bottom: 32px; }
.hero .eyebrow { color: #a9b8ff; }
.hero .btn-ghost { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.18); color: #fff; }
.hero .btn-ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 22px; margin-top: 36px; color: #9aa4ba; font-size: 14px; }
.hero-meta span { display: inline-flex; align-items: center; gap: 8px; }
.hero-meta svg { width: 16px; height: 16px; color: #7f95ff; }

.hero-card {
  position: relative; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.12);
  border-radius: 22px; padding: 22px; box-shadow: var(--shadow-lg); backdrop-filter: blur(6px);
}
.hero-card .label { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: #8d98b0; margin-bottom: 12px; display: block; }
.hero-card h3 { color: #fff; font-family: var(--serif); font-size: 21px; line-height: 1.25; margin: 16px 0 6px; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.hero-card p { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hero-card p { color: #aab3c7; font-size: 14.5px; margin: 0 0 16px; }
.hero-card .btn-row .btn { flex: 1; }
.cert-chip {
  position: absolute; right: -14px; top: -20px; display: flex; gap: 10px; align-items: center;
  background: #fff; color: #0d1424; border-radius: 14px; padding: 10px 14px 10px 10px; box-shadow: var(--shadow-lg); font-size: 13px; line-height: 1.25;
}
.cert-chip .qr { width: 40px; height: 40px; border-radius: 6px; background:
  conic-gradient(from 90deg at 2px 2px, #0d1424 25%, transparent 0) 0 0/8px 8px, #fff; border: 3px solid #0d1424; }
.cert-chip strong { display: block; font-size: 13.5px; }

/* ---------- Issue cover ---------- */
.cover {
  position: relative; aspect-ratio: 3 / 4; border-radius: 12px; overflow: hidden; color: #e8ecf6;
  background: linear-gradient(160deg, #18213a 0%, #0b1020 70%); display: flex; flex-direction: column; padding: 18px;
  border: 1px solid rgba(255,255,255,.08);
}
.cover::after { content: ""; position: absolute; inset: 0; background: radial-gradient(300px 200px at 90% 0%, rgba(98,125,255,.35), transparent 70%); }
.cover > * { position: relative; z-index: 1; }
.cover .c-top { display: flex; justify-content: space-between; font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: #9aa6c2; }
.cover .c-mark { margin: auto 0; width: 46%; color: #fff; opacity: .92; }
.cover .c-title { font: 600 clamp(12px, 1.1vw, 15px)/1.25 var(--serif); color: #fff; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.cover .c-vol { font-size: 12px; color: #a9b8ff; margin-top: 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); margin-top: -44px; position: relative; z-index: 2; box-shadow: var(--shadow); }
.stat { padding: 22px 26px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; }
.stat b { display: block; font: 600 32px/1.1 var(--serif); color: var(--ink); }
.stat span { color: var(--muted); font-size: 14px; }

/* ---------- Cards / lists ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card-pad { padding: 28px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }

.article-list { display: flex; flex-direction: column; }
.article-item { display: grid; grid-template-columns: 1fr auto; gap: 20px; padding: 22px 0; border-top: 1px solid var(--line); }
.article-item:first-child { border-top: 0; padding-top: 4px; }
.article-item h3 { font: 600 19px/1.35 var(--serif); margin: 0 0 8px; }
.article-item h3 a { color: var(--ink); }
.article-item h3 a:hover { color: var(--brand); }
.authors { display: flex; flex-wrap: wrap; gap: 4px 4px; font-size: 14.5px; color: var(--muted); margin-bottom: 8px; }
.authors a { color: var(--text); }
.authors a:hover { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }
.meta-row { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13.5px; color: var(--faint); }
.meta-row span { display: inline-flex; align-items: center; gap: 6px; }
.meta-row svg { width: 14px; height: 14px; }
.article-item .actions { display: flex; align-items: start; gap: 8px; }

.paper-card { display: flex; flex-direction: column; padding: 22px; height: 100%; transition: transform .15s, box-shadow .2s, border-color .2s; }
.paper-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); }
.paper-card h3 { font: 600 17.5px/1.35 var(--serif); margin: 10px 0 8px; }
.paper-card h3 a { color: var(--ink); }
.paper-card .authors { font-size: 14px; margin-bottom: 14px; }
.paper-card .meta-row { margin-top: auto; padding-top: 14px; border-top: 1px dashed var(--line); }

.tag { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 99px; font-size: 12.5px; font-weight: 500; background: var(--surface-2); color: var(--muted); border: 1px solid var(--line-2); }
.tag-brand { background: var(--brand-soft); color: var(--brand); border-color: transparent; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }

.badge { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 99px; font-size: 12.5px; font-weight: 600; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-submitted { background: var(--brand-soft); color: var(--brand); }
.badge-under_review { background: var(--warn-soft); color: var(--warn); }
.badge-accepted { background: var(--ok-soft); color: var(--ok); }
.badge-rejected { background: var(--bad-soft); color: var(--bad); }

/* Current issue block */
.issue-feature { display: grid; grid-template-columns: 260px 1fr; gap: 40px; align-items: start; }
.issue-feature .cover { position: sticky; top: 92px; }

/* Issue grid (archive) */
.issue-card { display: flex; flex-direction: column; gap: 12px; color: var(--text); }
.issue-card:hover { color: var(--text); }
.issue-card:hover .cover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.issue-card .cover { transition: transform .2s, box-shadow .2s; }
.issue-card h3 { font: 600 16px/1.35 var(--serif); margin: 0; color: var(--ink); }
.issue-card span { font-size: 13.5px; color: var(--muted); }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: step; }
.step { position: relative; padding: 26px 22px 24px; }
.step .num { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); margin-bottom: 18px; }
.step .num svg { width: 20px; height: 20px; }
.step h3 { font-size: 17px; margin-bottom: 8px; }
.step p { color: var(--muted); font-size: 14.5px; margin: 0; }

/* Telegram band */
.tg-band { display: grid; grid-template-columns: 1.2fr .8fr; gap: 40px; align-items: center; padding: 44px; border-radius: 24px; color: #e8f4fb;
  background: radial-gradient(500px 300px at 100% 0%, rgba(255,255,255,.18), transparent 60%), linear-gradient(135deg, #1f8ec4, #155f8a); }
.tg-band h2 { color: #fff; font-size: clamp(26px, 3vw, 34px); }
.tg-band p { color: #d5ecf8; }
.tg-band .btn-light { background: #fff; color: #155f8a; }
.tg-band .btn-light:hover { color: #0f4a6c; }
.tg-band ul { list-style: none; margin: 0 0 24px; padding: 0; display: grid; gap: 10px; }
.tg-band li { display: flex; gap: 10px; align-items: start; color: #e3f2fb; }
.tg-band li svg { width: 20px; height: 20px; flex-shrink: 0; margin-top: 2px; }
.chat { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18); border-radius: 18px; padding: 16px; display: grid; gap: 10px; font-size: 14px; }
.bubble { max-width: 85%; padding: 9px 13px; border-radius: 14px; line-height: 1.4; }
.bubble.bot { background: #fff; color: #0d1424; border-bottom-left-radius: 4px; }
.bubble.me { background: #d9fdd3; color: #0d1424; margin-left: auto; border-bottom-right-radius: 4px; }
.bubble.file { display: flex; gap: 10px; align-items: center; }
.bubble.file i { width: 34px; height: 34px; border-radius: 50%; background: #229ed9; display: grid; place-items: center; color: #fff; font-style: normal; font-size: 12px; font-weight: 700; flex-shrink: 0; }

/* ---------- Page header ---------- */
.page-head { padding: 56px 0 36px; border-bottom: 1px solid var(--line); background: linear-gradient(180deg, var(--surface-2), var(--bg)); }
.page-head h1 { font-size: clamp(30px, 4vw, 46px); margin: 0; max-width: 22ch; }
.page-head p { color: var(--muted); margin: 12px 0 0; max-width: 64ch; font-size: 17px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 13.5px; color: var(--faint); margin-bottom: 16px; }
.crumbs a { color: var(--muted); }
.crumbs > * + *::before { content: "/"; margin-right: 8px; color: var(--faint); opacity: .6; }

/* ---------- Article page ---------- */
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 48px; align-items: start; }
.article-title { font-size: clamp(28px, 3.6vw, 42px); line-height: 1.15; max-width: none; }
.article-authors { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 0; }
.author-chip { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-size: 14.5px; }
.author-chip i { width: 26px; height: 26px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; font-style: normal; font-size: 12px; font-weight: 700; }
.author-chip:hover { border-color: var(--brand); color: var(--ink); }
.abstract h2 { font: 600 13px/1 var(--sans); text-transform: uppercase; letter-spacing: .12em; color: var(--muted); margin: 0 0 14px; }
.abstract p { font: 400 18px/1.75 var(--serif); color: var(--text); white-space: pre-line; }
.side-box { padding: 22px; }
.side-box + .side-box { margin-top: 16px; }
.side-box h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: 14px; font-weight: 600; }
.side-box .btn { width: 100%; }
.side-box dl { margin: 0; display: grid; gap: 12px; }
.side-box dt { font-size: 12.5px; color: var(--faint); }
.side-box dd { margin: 0; font-size: 14.5px; color: var(--ink); font-weight: 500; }
.cite { font-size: 13.5px; line-height: 1.55; color: var(--text); background: var(--surface-2); border-radius: 10px; padding: 12px 14px; border: 1px solid var(--line-2); }
.copy-btn { margin-top: 10px; }

/* ---------- Rich content from the admin editor ---------- */
.prose { font-size: 17px; line-height: 1.75; color: var(--text); max-width: 76ch; }
.prose h1, .prose h2, .prose h3 { font-family: var(--serif); margin: 1.6em 0 .6em; }
.prose h1:first-child, .prose h2:first-child, .prose h3:first-child, .prose p:first-child { margin-top: 0; }
.prose h2 { font-size: 26px; } .prose h3 { font-size: 21px; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.1em; }
.prose li { margin: .3em 0; }
.prose a { text-decoration: underline; text-underline-offset: 3px; }
.prose img { height: auto; border-radius: 10px; }
.prose table { width: 100%; border-collapse: collapse; margin: 1em 0; font-size: 15px; display: block; overflow-x: auto; }
.prose td, .prose th { border: 1px solid var(--line); padding: 8px 10px; text-align: left; }
.prose blockquote { margin: 1em 0; padding: 4px 18px; border-left: 3px solid var(--brand); color: var(--muted); }
.prose-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 48px; align-items: start; }
.side-nav { position: sticky; top: 92px; display: flex; flex-direction: column; gap: 2px; }
.side-nav a { padding: 9px 12px; border-radius: 9px; color: var(--muted); font-size: 14.5px; }
.side-nav a:hover { background: var(--surface-2); color: var(--ink); }
.side-nav a.active { background: var(--brand-soft); color: var(--brand); font-weight: 600; }

/* ---------- Forms ---------- */
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px 20px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 14px; font-weight: 600; color: var(--ink); }
.field label .opt { font-weight: 400; color: var(--faint); margin-left: 4px; }
.field .hint { font-size: 13px; color: var(--faint); }
.input, .textarea, .select {
  width: 100%; border: 1px solid var(--line); background: var(--surface); color: var(--text);
  border-radius: 10px; padding: 11px 14px; font: inherit; font-size: 15px; transition: border-color .2s, box-shadow .2s;
}
.textarea { min-height: 150px; resize: vertical; line-height: 1.6; }
.input:focus, .textarea:focus, .select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-soft); }
.field.has-error .input, .field.has-error .textarea, .field.has-error .drop { border-color: var(--bad); }
.error { color: var(--bad); font-size: 13px; }
.drop {
  position: relative; border: 1.5px dashed var(--line); border-radius: 12px; padding: 26px; text-align: center; background: var(--surface-2);
  transition: border-color .2s, background .2s; cursor: pointer;
}
.drop:hover, .drop.drag { border-color: var(--brand); background: var(--brand-soft); }
.drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.drop svg { width: 30px; height: 30px; color: var(--brand); margin-bottom: 8px; }
.drop strong { display: block; color: var(--ink); }
.drop span { font-size: 13.5px; color: var(--muted); }
.check { display: flex; gap: 10px; align-items: start; font-size: 14.5px; color: var(--text); }
.check input { margin-top: 4px; width: 17px; height: 17px; accent-color: var(--brand); flex-shrink: 0; }
.hp { position: absolute; left: -9999px; }

.alert { display: flex; gap: 12px; padding: 14px 16px; border-radius: 12px; font-size: 15px; margin-bottom: 20px; border: 1px solid transparent; }
.alert svg { width: 20px; height: 20px; flex-shrink: 0; margin-top: 1px; }
.alert-ok { background: var(--ok-soft); color: var(--ok); border-color: color-mix(in srgb, var(--ok) 25%, transparent); }
.alert-bad { background: var(--bad-soft); color: var(--bad); border-color: color-mix(in srgb, var(--bad) 25%, transparent); }
.alert-info { background: var(--brand-soft); color: var(--brand); }

.submit-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 40px; align-items: start; }
.channel-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 24px; }
.channel { display: flex; gap: 14px; align-items: center; padding: 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); }
.channel:hover { border-color: var(--brand); color: var(--ink); }
.channel.on { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.channel .ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); flex-shrink: 0; }
.channel .ic.tg { background: #e3f3fb; color: #229ed9; }
.channel .ic svg { width: 22px; height: 22px; }
.channel b { display: block; font-size: 15px; }
.channel span { font-size: 13px; color: var(--muted); }
details.guide summary { cursor: pointer; font-weight: 600; color: var(--ink); list-style: none; display: flex; justify-content: space-between; align-items: center; }
details.guide summary::-webkit-details-marker { display: none; }
details.guide[open] summary { margin-bottom: 14px; }

/* Status timeline */
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.timeline li { position: relative; padding: 0 0 22px 36px; color: var(--faint); }
.timeline li::before { content: ""; position: absolute; left: 9px; top: 22px; bottom: 0; width: 2px; background: var(--line); }
.timeline li:last-child::before { display: none; }
.timeline .dot { position: absolute; left: 0; top: 2px; width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--line); background: var(--surface); display: grid; place-items: center; }
.timeline .dot svg { width: 12px; height: 12px; }
.timeline li.done { color: var(--ink); }
.timeline li.done .dot { background: var(--ok); border-color: var(--ok); color: #fff; }
.timeline li.done::before { background: var(--ok); }
.timeline li.now .dot { border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-soft); }
.timeline li.now { color: var(--ink); font-weight: 600; }
.timeline li.fail .dot { background: var(--bad); border-color: var(--bad); color: #fff; }
.timeline small { display: block; font-weight: 400; color: var(--faint); font-size: 13px; }

.code-box { font: 600 22px/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .06em; color: var(--ink); background: var(--surface-2); border: 1px dashed var(--line); padding: 14px 18px; border-radius: 12px; display: inline-block; }
.verify { text-align: center; }
.verify .seal { width: 72px; height: 72px; margin: 0 auto 18px; border-radius: 50%; display: grid; place-items: center; background: var(--ok-soft); color: var(--ok); }
.verify .seal svg { width: 36px; height: 36px; }
.verify dl { display: grid; grid-template-columns: 160px 1fr; gap: 14px 20px; text-align: left; margin: 28px 0; }
.verify dt { color: var(--faint); font-size: 14px; }
.verify dd { margin: 0; color: var(--ink); font-weight: 500; }

/* Pagination */
.pager { display: flex; justify-content: center; gap: 6px; margin-top: 36px; flex-wrap: wrap; }
.pager a, .pager span { min-width: 40px; height: 40px; padding: 0 12px; display: inline-grid; place-items: center; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--text); font-size: 14.5px; }
.pager a:hover { border-color: var(--brand); color: var(--brand); }
.pager .on { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.pager .off { opacity: .45; }

.empty { text-align: center; padding: 56px 20px; color: var(--muted); }
.empty svg { width: 44px; height: 44px; color: var(--faint); margin-bottom: 12px; }
.empty h3 { color: var(--ink); }

/* ---------- Footer ---------- */
.site-footer { background: #0b1020; color: #9aa4ba; margin-top: 80px; padding: 64px 0 28px; font-size: 14.5px; }
.site-footer a { color: #c8cfdd; }
.site-footer a:hover { color: #fff; }
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; }
.foot-grid h4 { color: #fff; font-size: 13px; text-transform: uppercase; letter-spacing: .12em; margin-bottom: 16px; font-weight: 600; }
.foot-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer .brand { color: #fff; }
.site-footer .brand-mark { background: #fff; color: #0b1020; }
.site-footer .brand-name span { color: #8d98b0; }
.foot-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 48px; padding-top: 22px; border-top: 1px solid #1f2840; font-size: 13.5px; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .nav-search input { width: 160px; }
  .nav-search input:focus { width: 190px; }
  .article-layout, .submit-layout { grid-template-columns: 1fr; }
  .steps, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
  .menu-toggle { display: inline-grid; place-items: center; }
  .nav-links, .nav-search { display: none; }
  .nav.open { flex-wrap: wrap; height: auto; padding: 14px 0; }
  .nav.open .nav-links { display: flex; flex-direction: column; align-items: stretch; order: 5; width: 100%; margin: 6px 0 0; }
  .nav.open .nav-search { display: block; order: 4; width: 100%; }
  .nav.open .nav-search input, .nav.open .nav-search input:focus { width: 100%; }
  .nav.open .drop-menu { position: static; box-shadow: none; border: 0; padding: 0 0 0 12px; background: transparent; }
  .hero-grid { grid-template-columns: 1fr; padding: 64px 0 88px; gap: 40px; }
  .cert-chip { right: 8px; top: -18px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .issue-feature, .prose-layout, .tg-band { grid-template-columns: 1fr; }
  .issue-feature .cover { position: static; max-width: 220px; }
  .side-nav { position: static; flex-direction: row; flex-wrap: wrap; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .tg-band { padding: 28px; }
}
@media (max-width: 600px) {
  .section { padding: 52px 0; }
  .wrap { padding: 0 16px; }
  .hero-grid { padding: 48px 16px 84px; }
  .brand-name span { display: none; }
  /* The full journal title may wrap to two lines so the language and menu buttons stay on screen. */
  .nav { gap: 10px; }
  .site-header .brand { flex-shrink: 1; min-width: 0; }
  .site-header .brand-name strong { font-size: 14.5px; }
  .grid-2, .grid-3, .grid-4, .steps, .form-grid, .channel-tabs { grid-template-columns: 1fr; }
  .article-item { grid-template-columns: 1fr; }
  .verify dl { grid-template-columns: 1fr; gap: 4px; }
  .verify dd { margin-bottom: 10px; }
  .foot-grid { grid-template-columns: 1fr; }
  .card-pad { padding: 20px; }
  .btn-row .btn { flex: 1 1 auto; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}

/* Telegram channel invitation */
.channel-band { display: grid; grid-template-columns: auto 1fr auto; gap: 22px; align-items: center; background: rgba(34,158,217,.07); border-color: rgba(34,158,217,.35); }
.channel-band p { margin: 4px 0 0; color: var(--muted); font-size: 16px; }
.channel-band .channel-icon { width: 56px; height: 56px; border-radius: 50%; background: #229ed9; color: #fff; display: flex; align-items: center; justify-content: center; }
.channel-band .channel-icon svg { width: 28px; height: 28px; }
.channel-side { border-color: rgba(34,158,217,.35); }
@media (max-width: 600px) {
  .channel-band { grid-template-columns: 1fr; gap: 14px; }
  .channel-band .btn { width: 100%; justify-content: center; }
}
