/* Pages for search engines and first-time visitors (experiments, subjects, exam pages). Kept small. */
:root { --ink: #101828; --muted: #475467; --paper: #f6f7f9; --card: #fff; --line: #e4e7ec; --green: #0b6e4f; --green-2: #08573e; --green-t: #e7f3ee; --amber: #f5b83d;
  --sans: system-ui, -apple-system, 'Segoe UI', Roboto, 'Noto Sans', Arial, sans-serif; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 17px/1.6 var(--sans); color: var(--ink); background: var(--paper); }
a { color: var(--green); } a:hover { color: var(--green-2); }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -0.015em; text-wrap: balance; }
h1 { font-size: clamp(1.75rem, 4vw, 2.5rem); margin: .2em 0 .3em; }
h2 { font-size: 1.35rem; margin: 1.6em 0 .5em; } h2 small { color: var(--muted); font-weight: 500; }
h3 { font-size: 1.05rem; margin: 1.2em 0 .3em; }
.in { max-width: 1040px; margin: 0 auto; padding: 0 20px; }
.top { background: var(--card); border-bottom: 1px solid var(--line); }
.top .in { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; padding-top: 12px; padding-bottom: 12px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-size: 1.05rem; }
.mark { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: var(--green); color: #fff; }
.top nav { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-left: auto; align-items: center; font-size: .95rem; }
.top nav a { color: var(--muted); text-decoration: none; padding: 6px 0; } .top nav a:hover { color: var(--ink); }
.top nav a.go { color: #fff; background: var(--green); padding: 7px 14px; border-radius: 99px; font-weight: 600; }
main { max-width: 1040px; margin: 0 auto; padding: 8px 20px 48px; }
article { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: clamp(18px, 4vw, 40px); }
.lab { max-width: 820px; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 4px; padding: 0; margin: 12px 0; font-size: .875rem; color: var(--muted); }
.crumbs li + li::before { content: '›'; margin-right: 4px; }
.kicker { margin: 0; color: var(--green); font-weight: 700; font-size: .85rem; text-transform: uppercase; letter-spacing: .06em; }
.lead { font-size: 1.15rem; color: var(--muted); margin-top: 0; }
.chips { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { background: var(--green-t); color: var(--green-2); border-radius: 99px; padding: 3px 12px; font-size: .875rem; font-weight: 600; }
.cta { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0; }
.btn { display: inline-block; background: var(--green); color: #fff; text-decoration: none; font-weight: 700; padding: 12px 20px; border-radius: 12px; }
.btn:hover { background: var(--green-2); color: #fff; }
.btn.ghost { background: transparent; color: var(--green); border: 2px solid var(--green); padding: 10px 18px; }
.btn.ghost:hover { background: var(--green-t); color: var(--green-2); }
.formula { font-family: Georgia, 'Times New Roman', serif; background: var(--paper); padding: 8px 14px; border-radius: 8px; overflow-x: auto; }
table { border-collapse: collapse; margin: 10px 0; display: block; overflow-x: auto; }
th, td { border: 1px solid var(--line); padding: 6px 10px; text-align: left; }
th { background: var(--paper); }
.qs > li { margin-bottom: 14px; } .qs ol { margin: 6px 0; }
details { margin-top: 4px; } summary { cursor: pointer; color: var(--green); font-weight: 600; }
.cards { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.card { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; background: var(--card); }
.card a { text-decoration: none; } .card a:hover b { text-decoration: underline; }
.card .meta { font-size: .8rem; color: var(--green-2); font-weight: 600; }
.card span:last-child { font-size: .92rem; color: var(--muted); }
.topics { color: var(--muted); }
.jump { display: flex; flex-wrap: wrap; gap: 6px; margin: 16px 0; }
.jump a { border: 1px solid var(--line); border-radius: 99px; padding: 3px 12px; text-decoration: none; font-size: .875rem; }
.ticks { padding-left: 20px; } .ticks li { margin: 6px 0; }
.foot { background: #0f2a20; color: #cfe3da; margin-top: 24px; padding: 32px 0; font-size: .92rem; }
.foot .in { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 24px; }
.foot a { color: #fff; } .foot b { color: #fff; } .foot ul { list-style: none; padding: 0; margin: 8px 0; columns: 1; } .foot li { margin: 3px 0; }
@media (max-width: 760px) { .foot .in { grid-template-columns: 1fr; } .top nav { margin-left: 0; } body { font-size: 16px; } }
@media print { .top, .foot, .cta, .crumbs { display: none; } article { border: 0; } }
.links { columns: 2 280px; column-gap: 24px; padding-left: 18px; } .links li { margin: 4px 0; break-inside: avoid; } .links small { color: var(--muted); white-space: nowrap; }

/* formulas printed like a textbook (js/math.js) */
.frac { display: inline-flex; flex-direction: column; vertical-align: middle; text-align: center; margin: 0 .15em; line-height: 1.25; }
.frac .num { padding: 0 .2em .1em; border-bottom: 1.5px solid currentColor; }
.frac .den { padding: .1em .2em 0; }
.frac .vh, .vh-m { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sqrt { white-space: nowrap; } .sqrt .rad { display: inline-block; border-top: 1.5px solid currentColor; padding: .15em .1em 0; margin-left: -.05em; }
.formula { line-height: 2.1; }

/* school registration (/register/) */
.regform fieldset { border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px 6px; margin: 0 0 16px; display: grid; grid-template-columns: 1fr 1fr; gap: 4px 16px; }
.regform legend { font-weight: 700; padding: 0 6px; }
.regform label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 12px; }
.regform label.wide { grid-column: 1 / -1; }
.regform input:not([type=checkbox]), .regform select { display: block; width: 100%; box-sizing: border-box; margin-top: 4px; padding: 10px 12px; font: inherit; font-weight: 400; border: 1px solid #c9d6d0; border-radius: 10px; background: #fff; min-height: 44px; }
.regform input:focus, .regform select:focus { outline: 2px solid var(--green); outline-offset: 1px; }
.regform .check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
.regform .check input { width: 20px; height: 20px; margin-top: 2px; flex: none; accent-color: var(--green); }
.regform .hp { position: absolute; left: -9999px; }
.regform button.btn { border: 0; font: inherit; font-weight: 700; cursor: pointer; }
.regform button.btn:disabled { opacity: .6; cursor: wait; }
.reg .err { background: #fdecea; color: #9b1c1c; border-radius: 10px; padding: 10px 14px; }
.regdone { background: var(--green-t); border-radius: 14px; padding: 18px 20px; margin: 16px 0; }
.regdone h2 { margin-top: 0; }
@media (max-width: 640px) { .regform fieldset { grid-template-columns: 1fr; } }
