/* Portal Bebras components (after bebras-design/orange-proposals/portal-v1).
   Written once, against role tokens only (tokens.css). No colour, radius,
   shadow or font is hard-coded here, except translucent overlays. */

:root { --pad-card: 22px 24px; --gap: 20px; --row-y: 12px; }
body { background: var(--bg); color: var(--ink); font: 400 15px/1.55 var(--font); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 8px 14px; border-radius: 8px; background: var(--tip-bg); color: var(--tip-ink); font-weight: 700; }
.skip:focus { top: 12px; }
::selection { background: var(--accent-soft); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.icon { width: 18px; height: 18px; }
.muted { color: var(--ink-3); }
.small { font-size: 13px; }
.gap-top { margin-top: 14px; }
a { color: var(--link); text-underline-offset: 3px; }
strong, b { font-weight: 700; }
code, kbd { font-family: var(--font-mono); font-size: .92em; }

/* ---------- sidebar ---------- */
.sidebar { background: var(--sb-bg); color: var(--sb-ink); border-right: var(--sb-border); padding: 24px 16px 18px; gap: 18px; }
.sb-head { padding: 0 4px 0 8px; min-height: 38px; }
.sb-brand { width: 124px; color: var(--sb-logo); }
.sb-brand .mark { width: 32px; }
.icon-btn { width: 38px; height: 38px; border: 0; border-radius: var(--r-control); background: none; color: inherit; }
.sidebar .icon-btn { color: var(--sb-ink-2); }
.sidebar .icon-btn:hover { background: var(--sb-hover); color: var(--sb-ink); }
.sidebar :focus-visible { outline-color: var(--sb-ink); }
.sb-label { font-size: 11.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--sb-label); margin: 18px 12px 6px; }
.sb-group:first-child .sb-label { margin-top: 4px; }
.nav-item { gap: 12px; padding: 10px 12px; margin-bottom: 2px; border-radius: var(--r-nav); font-size: 14.5px; font-weight: 400; color: var(--sb-ink); transition: background .15s, color .15s; position: relative; }
.nav-item:hover { background: var(--sb-hover); }
.nav-item.is-active { background: var(--sb-active-bg); color: var(--sb-active-ink); box-shadow: var(--sb-active-shadow); font-weight: 700; }
.nav-icon .icon { width: 19px; height: 19px; }
.nav-badge { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--badge-bg); color: var(--badge-ink); font-size: 11.5px; font-weight: 700; display: grid; place-items: center; }
.sb-foot { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--sb-rule); display: flex; flex-direction: column; gap: 8px; }
.sb-org { padding: 4px 12px 0; font-size: 13px; font-weight: 700; color: var(--sb-ink-2); }
.sb-org small { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--sb-label); }
.sb-help { padding: 0 12px; font-size: 13px; color: var(--sb-ink-2); }
.sb-help a { color: var(--sb-ink); }
@media (min-width: 901px) {
  .app.is-collapsed .sidebar { padding: 20px 12px; overflow: visible; z-index: 20; }
  .app.is-collapsed .sb-head { gap: 12px; padding: 0; }
  .app.is-collapsed .sb-brand { width: auto; }
  .app.is-collapsed .sb-org, .app.is-collapsed .sb-help { display: none; }
  .app.is-collapsed .nav-item { padding: 12px; }
  .app.is-collapsed .nav-item:hover::after, .app.is-collapsed .nav-item:focus-visible::after {
    content: attr(data-label); position: absolute; left: calc(100% + 12px); top: 50%; transform: translateY(-50%); z-index: 60;
    padding: 5px 10px; border-radius: 6px; background: var(--tip-bg); color: var(--tip-ink); font-size: 13px; font-weight: 400; white-space: nowrap; pointer-events: none; }
  .app.is-collapsed .sb-group + .sb-group { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--sb-rule); }
}

/* ---------- top bar ---------- */
.topbar { min-height: 66px; padding: 10px 32px; gap: 12px; background: var(--top-bg); border-bottom: var(--top-border); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.crumbs { font-size: 13.5px; color: var(--ink-3); }
.crumbs strong { color: var(--ink); font-weight: 700; }
.crumb-sep { color: var(--line-strong); }
.topbar .icon-btn { color: var(--ink-2); }
.topbar .icon-btn:hover { background: var(--surface); }
.account { position: relative; flex: none; }
.account > summary { list-style: none; display: inline-flex; align-items: center; gap: 10px; height: 42px; padding: 0 10px 0 4px; border: 1px solid var(--line); border-radius: var(--r-control); background: var(--surface); color: var(--ink); cursor: pointer; font-size: 13.5px; max-width: 260px; }
.account > summary::-webkit-details-marker { display: none; }
.account > summary:hover { border-color: var(--line-strong); }
.account-avatar { width: 32px; height: 32px; flex: none; display: grid; place-items: center; border-radius: var(--r-avatar); background: var(--accent-soft); color: var(--info-ink); font-weight: 700; font-size: 12px; }
.account-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account > summary .icon { width: 15px; height: 15px; color: var(--ink-3); }
.account-pop { position: absolute; right: 0; top: calc(100% + 8px); width: 280px; padding: 8px; z-index: 30; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 24px 60px -20px rgba(13, 24, 33, .35); }
.account-id { padding: 8px 10px 10px; border-bottom: 1px solid var(--line); margin-bottom: 6px; font-size: 13px; color: var(--ink-3); }
.account-id strong { display: block; color: var(--ink); font-size: 14px; overflow-wrap: anywhere; }
.menu-link { width: 100%; display: flex; align-items: center; gap: 10px; padding: 9px 10px; border: 0; border-radius: 8px; background: none; color: var(--ink); font-size: 14px; text-align: left; text-decoration: none; }
.menu-link:hover { background: var(--surface-2); }
.menu-link .icon { color: var(--ink-3); width: 17px; height: 17px; }

/* ---------- page ---------- */
.content { padding: 32px 40px 88px; max-width: 1320px; width: 100%; }
.page-head { margin-bottom: 26px; }
.kicker { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--kicker); margin-bottom: 8px; }
.page-title { font-family: var(--font-display); font-weight: var(--display-weight); font-size: var(--title-size); letter-spacing: var(--title-track); line-height: 1.08; }
.page-lede { margin-top: 10px; color: var(--ink-2); font-size: 16px; max-width: 66ch; }
.page > * + * { margin-top: var(--gap); }
.page > .page-head + * { margin-top: 0; }
.messages { display: flex; flex-direction: column; gap: 8px; margin-bottom: var(--gap); }
.back-link { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; text-decoration: none; margin-bottom: 14px; }
.back-link:hover { text-decoration: underline; }

/* ---------- buttons ---------- */
.btn { min-height: 42px; padding: 0 18px; border: 1px solid transparent; border-radius: var(--r-btn); font-size: 14px; font-weight: 700; line-height: 1.2; transition: background .15s, border-color .15s, box-shadow .15s, transform .15s; }
.btn .icon { width: 17px; height: 17px; }
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: var(--btn-shadow); }
.btn-primary:hover:not(:disabled) { background: var(--accent-hover); }
.btn-secondary { background: var(--surface); color: var(--ink); border-color: var(--line-strong); }
.btn-secondary:hover:not(:disabled) { border-color: var(--ink-3); }
.btn-ghost { background: none; color: var(--ink-2); }
.btn-ghost:hover { background: var(--surface-2); color: var(--ink); }
.btn-danger { background: var(--bad-soft); color: var(--bad-ink); }
.btn-hero { background: var(--hero-btn-bg); color: var(--hero-btn-ink); }
.btn-hero-2 { background: transparent; color: var(--hero-ink); border-color: var(--hero-line); }
.btn:hover:not(:disabled) { transform: var(--btn-lift); }
.btn:disabled { opacity: .45; }
.btn-sm { min-height: 34px; padding: 0 12px; font-size: 13px; }
.btn-block { width: 100%; }
.link { display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; background: none; color: var(--link); font: inherit; font-size: 13.5px; font-weight: 700; text-decoration: none; cursor: pointer; }
.link:hover { text-decoration: underline; }
.link .icon { width: 15px; height: 15px; }
.link-quiet { color: var(--ink-3); font-weight: 400; }
.link-bad { color: var(--bad-ink); }
.inline-form { display: inline; margin: 0; }

/* ---------- cards ---------- */
.card { background: var(--surface); border: var(--card-border); border-radius: var(--r-card); box-shadow: var(--card-shadow); padding: var(--pad-card); }
.card-head { margin-bottom: 16px; align-items: center; }
.card-title { font-size: 17px; font-weight: 700; letter-spacing: -.01em; }
.card-sub { font-size: 13px; color: var(--ink-3); margin-top: 1px; }
.card > p + p, .card-body > p + p { margin-top: 8px; }
.card-body > p { color: var(--ink-2); max-width: 68ch; }
.progress { height: 6px; width: 140px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.progress span { display: block; height: 100%; background: var(--accent); border-radius: 999px; }

/* ---------- hero ---------- */
.hero { position: relative; overflow: hidden; min-height: 230px; padding: 30px 34px; display: flex; align-items: center; background: var(--hero-bg); color: var(--hero-ink); border: var(--hero-border); border-radius: var(--r-hero); }
.hero-copy { position: relative; z-index: 1; max-width: 62%; min-width: 0; }
.hero .kicker { color: var(--hero-kicker); }
.hero-title { font-family: var(--font-display); font-weight: var(--display-weight); font-size: var(--hero-size); letter-spacing: var(--title-track); line-height: 1.12; }
.hero-text { margin: 10px 0 0; color: var(--hero-ink-2); max-width: 52ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.hero-status { display: inline-flex; align-items: center; gap: 8px; margin-top: 16px; padding: 6px 12px; border-radius: 999px; background: transparent; border: 1px solid var(--hero-line); color: var(--hero-ink); font-size: 13.5px; font-weight: 700; }
.hero-status .icon { width: 16px; height: 16px; }
.tiles { position: absolute; right: 30px; top: 50%; transform: translateY(-50%); width: var(--tiles-w); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tiles svg { width: 100%; height: auto; aspect-ratio: 1; }

/* ---------- dashboard ---------- */
.dash { gap: var(--gap); align-items: start; }
.dash > .hero { grid-column: 1 / -1; }
.dash-main { grid-column: span 8; }
.dash-side { grid-column: span 4; }
.dash-full { grid-column: 1 / -1; }
.stack { gap: var(--gap); }
.next { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.next-icon { width: 46px; height: 46px; flex: none; display: grid; place-items: center; border-radius: var(--r-control); background: var(--accent-soft); color: var(--link); }
.next-text { flex: 1 1 240px; min-width: 0; }
.next-label { font-size: 18px; font-weight: 700; line-height: 1.3; }
.next-deadline { font-size: 14px; color: var(--ink-2); margin-top: 2px; }
.secret { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.secret-value { font-family: var(--font-mono); font-size: 22px; font-weight: 700; letter-spacing: .04em; padding: 8px 16px; border-radius: var(--r-control); background: var(--surface-2); border: 1px dashed var(--line-strong); color: var(--ink); overflow-wrap: anywhere; }

.dates { margin: 0; padding: 0; list-style: none; }
.date { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 10px; padding: 8px 0 8px 22px; position: relative; font-size: 14.5px; }
.date::before { content: ""; position: absolute; left: 0; top: 14px; width: 12px; height: 12px; border-radius: 50%; background: var(--surface); border: 2px solid var(--line-strong); z-index: 1; }
.date::after { content: ""; position: absolute; left: 5px; top: 26px; bottom: -14px; border-left: 2px solid var(--line); }
.date:last-child::after { display: none; }
.date-when { font-size: 13px; color: var(--ink-3); font-variant-numeric: tabular-nums; padding-top: 1px; }
.date.is-done { color: var(--ink-3); }
.date.is-done::before { background: var(--line-strong); }
.date.is-current::before { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.date.is-current .date-what { font-weight: 700; }
.date.is-current .date-when { color: var(--link); font-weight: 700; }

/* checklists: teacher-marked steps */
.checklist { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.check-item { display: flex; align-items: flex-start; gap: 14px; padding: var(--row-y) 0; border-bottom: 1px solid var(--line); }
.check-item:last-child { border-bottom: 0; padding-bottom: 0; }
.check-item form { margin: 0; flex: none; }
.check-box { width: 26px; height: 26px; margin-top: 1px; display: grid; place-items: center; padding: 0; border-radius: 50%; border: 1.5px solid var(--line-strong); background: var(--surface); color: var(--accent-ink); }
.check-box:hover { border-color: var(--accent); }
.check-box .icon { width: 14px; height: 14px; stroke-width: 3; opacity: 0; }
.check-item.is-done .check-box { background: var(--done); border-color: var(--done); }
.check-item.is-done .check-box .icon { opacity: 1; }
.check-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.check-label { font-size: 14.5px; }
.check-item.is-done .check-label { color: var(--ink-2); }
.check-meta { font-size: 12.5px; color: var(--ink-3); }
.checklist-note { font-size: 13px; color: var(--ink-3); margin-top: 12px; }
.checklist-block + .checklist-block { margin-top: 22px; }
.checklist-title { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 8px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

.news { margin: 0; padding: 0; list-style: none; }
.news-item { display: grid; grid-template-columns: 58px minmax(0, 1fr); gap: 12px; align-items: start; padding: var(--row-y) 0; border-bottom: 1px solid var(--line); }
.news-item:first-child { padding-top: 0; }
.news-item:last-child { border-bottom: 0; padding-bottom: 0; }
.news-date { font-size: 12.5px; color: var(--ink-3); padding-top: 2px; font-variant-numeric: tabular-nums; }
.news-title { font-size: 14.5px; font-weight: 700; }
.news-title a { color: var(--ink); text-decoration: none; }
.news-title a:hover { color: var(--link); text-decoration: underline; }
.news-text { font-size: 13.5px; color: var(--ink-2); margin-top: 2px; }
.pin { display: inline-flex; vertical-align: -2px; margin-right: 6px; color: var(--link); }
.pin .icon { width: 15px; height: 15px; }

.tiles-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); gap: var(--gap); }
.resource { display: flex; align-items: center; gap: 14px; padding: 18px 20px; background: var(--surface); border: var(--card-border); border-radius: var(--r-card); box-shadow: var(--card-shadow); color: inherit; text-decoration: none; transition: transform .15s; min-width: 0; }
.resource:hover { transform: var(--btn-lift); }
.resource:hover strong { color: var(--link); }
.resource-icon { width: 42px; height: 42px; flex: none; display: grid; place-items: center; border-radius: var(--r-control); background: var(--accent-soft); color: var(--link); }
.resource-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.resource-text strong { font-size: 15.5px; font-weight: 700; }
.resource-text small { font-size: 13px; color: var(--ink-2); }
.resource-arrow { color: var(--ink-3); flex: none; }

/* ---------- rows, tags, alerts, empty states ---------- */
.rows { margin: 0; padding: 0; list-style: none; }
.row-item { display: flex; align-items: center; gap: 14px; padding: var(--row-y) 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.row-item:first-child { padding-top: 0; }
.row-item:last-child { border-bottom: 0; padding-bottom: 0; }
.row-icon { width: 40px; height: 40px; flex: none; display: grid; place-items: center; border-radius: var(--r-control); background: var(--surface-2); color: var(--ink-2); }
.row-text { flex: 1 1 220px; min-width: 0; display: flex; flex-direction: column; }
.row-text strong { font-size: 14.5px; font-weight: 700; }
.row-text small { font-size: 12.5px; color: var(--ink-3); }
.row-end { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.date-box { width: 50px; height: 50px; flex: none; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.1; border-radius: var(--r-control); background: var(--accent-soft); color: var(--link); }
.date-box span { font-size: 18px; font-weight: 700; }
.date-box small { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.tag { min-height: 24px; padding: 2px 10px; border-radius: var(--r-tag); font-size: 12.5px; font-weight: 700; background: var(--neutral-soft); color: var(--ink-2); }
.tag-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.tag-ok { background: var(--ok-soft); color: var(--ok-ink); }
.tag-warn { background: var(--warn-soft); color: var(--warn-ink); }
.tag-bad { background: var(--bad-soft); color: var(--bad-ink); }
.tag-info { background: var(--info-soft); color: var(--info-ink); }
.chip { min-height: 34px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink-2); font-size: 13.5px; }
.chip:hover { border-color: var(--line-strong); color: var(--ink); }
.chip.is-active { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); font-weight: 700; }
.alert { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; border-radius: var(--r-control); background: var(--info-soft); color: var(--info-ink); font-size: 14.5px; }
.alert-ok { background: var(--ok-soft); color: var(--ok-ink); }
.alert-warn { background: var(--warn-soft); color: var(--warn-ink); }
.alert-bad { background: var(--bad-soft); color: var(--bad-ink); }
.alert-icon { width: 20px; height: 20px; flex: none; margin-top: 1px; }
.alert-text { flex: 1 1 auto; min-width: 0; }
.alert-text > * + * { margin-top: 4px; }
.alert a { color: inherit; font-weight: 700; }
.empty { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.empty-mark { width: 44px; height: 44px; display: grid; place-items: center; margin-bottom: 8px; border-radius: var(--r-control); background: var(--accent-soft); color: var(--link); }
.empty-title { font-size: 17px; font-weight: 700; }
.empty-text { color: var(--ink-2); max-width: 60ch; }
.note { padding: 14px 16px; border-left: 3px solid var(--accent); background: var(--surface-2); border-radius: 0 var(--r-control) var(--r-control) 0; color: var(--ink-2); }
.note strong { color: var(--ink); }
.quote { white-space: pre-line; }

/* ---------- status (pré-registo) ---------- */
.status-card { display: flex; gap: 18px; align-items: flex-start; flex-wrap: wrap; }
.status-mark { width: 52px; height: 52px; flex: none; display: grid; place-items: center; border-radius: var(--r-control); background: var(--neutral-soft); color: var(--ink-2); }
.status-mark .icon { width: 24px; height: 24px; }
.status-card.is-ok .status-mark { background: var(--ok-soft); color: var(--ok-ink); }
.status-card.is-warn .status-mark { background: var(--warn-soft); color: var(--warn-ink); }
.status-card.is-bad .status-mark { background: var(--bad-soft); color: var(--bad-ink); }
.status-card.is-info .status-mark { background: var(--info-soft); color: var(--info-ink); }
.status-body { flex: 1 1 300px; min-width: 0; }
.status-body > * + * { margin-top: 10px; }
.status-body p { color: var(--ink-2); max-width: 64ch; }
.status-title { font-size: 20px; font-weight: 700; line-height: 1.25; }
.summary { display: grid; grid-template-columns: minmax(0, 200px) minmax(0, 1fr); gap: 0 18px; margin: 0; }
.summary dt, .summary dd { padding: 10px 0; border-bottom: 1px solid var(--line); }
.summary dt { font-size: 13.5px; color: var(--ink-3); }
.summary dd { font-size: 14.5px; }
.summary dt:last-of-type, .summary dd:last-of-type { border-bottom: 0; }

/* ---------- forms ---------- */
.form-card { max-width: 860px; }
.form-section + .form-section { margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line); }
.form-section-title { font-size: 17px; font-weight: 700; margin-bottom: 4px; }
.form-section-lede { font-size: 14px; color: var(--ink-3); margin-bottom: 16px; max-width: 64ch; }
.field { gap: 6px; }
.field-label, legend.field-label { font-size: 14px; font-weight: 700; color: var(--ink); }
.field-label .opt { font-weight: 400; color: var(--ink-3); }
.field-hint { font-size: 13px; color: var(--ink-3); }
.field-error, .errorlist { margin: 0; padding: 0; list-style: none; font-size: 13.5px; color: var(--bad-ink); font-weight: 700; }
.field.has-error .input, .field.has-error input:not([type=checkbox]):not([type=radio]), .field.has-error select, .field.has-error textarea { border-color: var(--bad-ink); }
.input, .field input:not([type=checkbox]):not([type=radio]):not([type=hidden]), .field select, .field textarea {
  width: 100%; min-width: 0; min-height: 44px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: var(--r-control);
  background: var(--input-bg); color: var(--ink); font-size: 16px; outline: none; transition: border-color .15s, box-shadow .15s; }
.field textarea, textarea.input { min-height: 96px; padding: 10px 12px; resize: vertical; }
.field select, select.input { appearance: none; -webkit-appearance: none; padding-right: 38px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2355657F' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; background-size: 16px; }
.field select[multiple] { background-image: none; padding: 6px; min-height: 160px; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.input[readonly], .field input[readonly] { background: var(--surface-2); color: var(--ink-2); }
.field-num { max-width: 140px; }
.num-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); gap: 14px; }
.num-grid .field-label { font-size: 13.5px; }
.num-grid small { display: block; font-weight: 400; color: var(--ink-3); font-size: 12px; }
.choices { display: grid; gap: 8px; }
.choices-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }
.choices-3 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 180px), 1fr)); gap: 6px 14px; }
.choice { display: flex; align-items: flex-start; gap: 10px; padding: 11px 14px; border: 1px solid var(--line-strong); border-radius: var(--r-control); background: var(--surface); cursor: pointer; font-size: 14.5px; min-width: 0; }
.choice:hover { border-color: var(--ink-3); }
.choice:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.choice input, .check input { width: 18px; height: 18px; margin: 2px 0 0; flex: none; accent-color: var(--accent); }
.choices-3 .choice { padding: 6px 0; border: 0; background: none; }
.choices-3 .choice:has(input:checked) { background: none; }
.check { display: flex; align-items: flex-start; gap: 10px; font-size: 14.5px; cursor: pointer; }
.check span { min-width: 0; }
.declaration { padding: 14px 16px; border-radius: var(--r-control); background: var(--surface-2); }
.filter-input { margin-bottom: 8px; }
.other-school { margin-top: 10px; }
.other-school > summary { cursor: pointer; color: var(--link); font-weight: 700; font-size: 14px; width: fit-content; }
.other-school[open] > summary { margin-bottom: 12px; }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.form-foot .muted { flex: 1 1 260px; }

/* ---------- data ---------- */
.table th { padding: 10px 14px; background: var(--th-bg); border-bottom: 1px solid var(--line); font-size: 12.5px; font-weight: 700; color: var(--ink-3); white-space: nowrap; }
.table td { padding: var(--row-y) 14px; border-bottom: 1px solid var(--line); font-size: 14px; vertical-align: top; }
.table tbody tr:last-child td, .table tbody tr:last-child th { border-bottom: 0; }
.card .table-wrap { margin: 0 -24px; }
.card .table th:first-child, .card .table td:first-child { padding-left: 24px; }
.card .table th:last-child, .card .table td:last-child { padding-right: 24px; }
.matrix tbody th { text-align: left; padding: var(--row-y) 14px; border-bottom: 1px solid var(--line); font-weight: 400; background: var(--th-bg); white-space: nowrap; }
.matrix tbody th strong { display: block; font-weight: 700; font-size: 14.5px; }
.matrix tbody th small { font-size: 12px; color: var(--ink-3); }
.card .matrix tbody th { padding-left: 24px; }
.matrix td { min-width: 104px; }
.matrix td .link { display: flex; margin-bottom: 2px; }
.matrix .none { color: var(--ink-3); font-size: 13px; }

/* ---------- documents ---------- */
.prose { color: var(--ink-2); font-size: 16px; line-height: 1.65; max-width: 72ch; }
.prose > * + * { margin-top: 12px; }
.prose h1, .prose h2, .prose h3, .prose h4 { color: var(--ink); line-height: 1.25; }
.prose h1 { font-size: 28px; font-weight: 700; letter-spacing: -.01em; }
.prose h2 { font-size: 23px; font-weight: 700; margin-top: 34px; padding-top: 24px; border-top: 1px solid var(--line); scroll-margin-top: 90px; }
.prose > h2:first-child, .prose > h1 + h2 { border-top: 0; padding-top: 0; }
.prose h3 { font-size: 18px; font-weight: 700; margin-top: 24px; scroll-margin-top: 90px; }
.prose h4 { font-size: 16px; font-weight: 700; margin-top: 18px; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li + li { margin-top: 6px; }
.prose li > ul, .prose li > ol { margin-top: 6px; }
.prose strong { color: var(--ink); }
.prose img { border-radius: var(--r-control); border: 1px solid var(--line); height: auto; margin: 8px 0; }
.prose table { width: 100%; border-collapse: collapse; font-size: 14.5px; display: block; overflow-x: auto; }
.prose th, .prose td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; }
.prose blockquote { margin-left: 0; padding: 10px 16px; border-left: 3px solid var(--accent); background: var(--surface-2); }
.prose code { background: var(--surface-2); padding: 1px 5px; border-radius: 4px; }
.prose hr { border: 0; border-top: 1px solid var(--line); }
.doc { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px; align-items: start; }
.doc-toc { position: sticky; top: 90px; font-size: 14px; }
.doc-toc-label { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 8px; }
.doc-toc ol { margin: 0; padding: 0; list-style: none; }
.doc-toc a { display: block; padding: 6px 0 6px 12px; border-left: 2px solid var(--line); color: var(--ink-2); text-decoration: none; }
.doc-toc a:hover { color: var(--link); border-color: var(--accent); }
.doc-body { padding: 28px 36px 36px; }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item:last-child { border-bottom: 0; }
.faq-item summary { padding: 14px 0; font-size: 15.5px; font-weight: 700; }
.faq-item:first-child summary { padding-top: 0; }
.faq-icon { color: var(--ink-3); }
.faq-item .prose { padding: 0 0 16px; font-size: 15px; }
.pager { display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap; font-size: 14px; color: var(--ink-3); }
.webinar-desc { margin-top: 10px; font-size: 14px; }
.webinar-desc > summary { cursor: pointer; color: var(--link); font-weight: 700; width: fit-content; }
.webinar-desc .prose { margin-top: 10px; font-size: 15px; }

/* ---------- standalone pages: public entry, accounts, errors ---------- */
.solo { min-height: 100vh; display: flex; flex-direction: column; }
.solo-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 32px; }
.solo-brand { width: 132px; color: var(--accent); display: block; }
.solo-top .row { gap: 8px; }
.solo-main { flex: 1; width: 100%; max-width: 1180px; margin: 0 auto; padding: 8px 32px 56px; }
.solo-foot { padding: 22px 32px 30px; font-size: 13px; color: var(--ink-3); display: flex; gap: 8px 22px; flex-wrap: wrap; justify-content: center; }
.solo-foot a { color: var(--ink-2); }
.auth { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 480px); gap: 0; max-width: 1040px; margin: 0 auto; background: var(--surface); border-radius: var(--r-hero); box-shadow: var(--card-shadow); overflow: hidden; }
.auth-aside { position: relative; overflow: hidden; background: var(--hero-bg); color: var(--hero-ink); padding: 40px 36px; display: flex; flex-direction: column; justify-content: space-between; gap: 30px; min-height: 480px; }
.auth-aside .kicker { color: var(--hero-kicker); }
.auth-aside-title { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 28px; line-height: 1.15; letter-spacing: var(--title-track); position: relative; z-index: 1; }
.auth-aside p { color: var(--hero-ink-2); position: relative; z-index: 1; max-width: 40ch; }
.auth-aside p + p { margin-top: 10px; }
.auth-aside .tiles { position: static; transform: none; width: 180px; opacity: .95; }
.auth-panel { padding: 40px 40px 36px; min-width: 0; }
.auth-panel > * + * { margin-top: 16px; }
.auth-title { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 28px; letter-spacing: var(--title-track); line-height: 1.15; }
.auth-panel p { color: var(--ink-2); }
.auth-panel .form { gap: 16px; }
.auth-links { font-size: 14px; color: var(--ink-3); display: flex; flex-direction: column; gap: 6px; padding-top: 16px; border-top: 1px solid var(--line); }
.auth-narrow { max-width: 560px; margin: 0 auto; }
.pw-toggle { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--ink-2); cursor: pointer; width: fit-content; }
.pw-toggle input { width: 16px; height: 16px; accent-color: var(--accent); }

.public-hero { min-height: 340px; }
.public-hero .hero-copy { max-width: 60%; }
.public-hero .hero-title { font-size: 40px; }
.steps { margin: 0; padding: 0; list-style: none; counter-reset: step; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr)); gap: var(--gap); }
.step { counter-increment: step; background: var(--surface); border-radius: var(--r-card); box-shadow: var(--card-shadow); padding: 20px; min-width: 0; }
.step::before { content: counter(step); display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--accent-soft); color: var(--info-ink); font-weight: 700; margin-bottom: 10px; }
.step strong { display: block; font-size: 15.5px; }
.step p { font-size: 14px; color: var(--ink-2); margin-top: 4px; }
.section-title { font-size: 19px; font-weight: 700; margin-bottom: 14px; }
.facts .card p { margin-top: 8px; color: var(--ink-2); font-size: 14.5px; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: var(--gap); }
.error-page { max-width: 620px; margin: 6vh auto 0; text-align: left; }
.error-code { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--kicker); }

/* ---------- tablet and phone ---------- */
@media (max-width: 1180px) {
  .dash-main, .dash-side { grid-column: 1 / -1; }
}
@media (max-width: 900px) {
  .topbar { padding: 8px 12px 8px 8px; min-height: 60px; }
  .crumbs .crumb-page, .crumb-sep { display: none; }
  .account-name { display: none; }
  .account > summary { padding: 0 8px 0 4px; }
  .content { padding: 22px 16px 80px; }
  .page-title { font-size: min(var(--title-size), 30px); }
  .hero { padding: 24px 22px; min-height: 0; }
  .hero-copy, .public-hero .hero-copy { max-width: 100%; }
  .public-hero .hero-title { font-size: 30px; }
  .tiles { opacity: .16; width: 150px; right: -30px; }
  .doc { grid-template-columns: minmax(0, 1fr); }
  .doc-toc { position: static; }
  .doc-body { padding: 22px 18px; }
  .card { padding: 20px 18px; }
  .card .table-wrap { margin: 0 -18px; }
  .card .table th:first-child, .card .table td:first-child, .card .matrix tbody th { padding-left: 18px; }
  .auth { grid-template-columns: minmax(0, 1fr); }
  .auth-aside { min-height: 0; padding: 26px 22px; }
  .auth-aside .tiles { display: none; }
  .auth-panel { padding: 26px 20px 28px; }
  .solo-top { padding: 16px; }
  .solo-main { padding: 4px 16px 40px; }
  .solo-foot { padding: 18px 16px 26px; }
  .summary { grid-template-columns: minmax(0, 1fr); }
  .summary dt { border-bottom: 0; padding-bottom: 0; }
  .summary dd { padding-top: 2px; }
}
@media (max-width: 600px) {
  .tiles { display: none; }
  .date { grid-template-columns: 76px minmax(0, 1fr); }
  .solo-brand { width: 104px; }
  .solo-top .btn { padding: 0 12px; }
}
.row-split { justify-content: space-between; }
.manage-card { max-width: 640px; }
.manage-card > * + * { margin-top: 16px; }
.auth-aside a { color: var(--hero-ink); }
.en { font-weight: 400; color: var(--ink-3); font-size: .7em; letter-spacing: 0; }
.solo-top { max-width: 1180px; margin: 0 auto; width: 100%; }
.hero-status { text-decoration: none; }
.hero-status:hover { text-decoration: underline; text-underline-offset: 3px; }
.tiles-grid.dash-full { grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.gap-grid { gap: var(--gap); }
.contact-big { font-size: 22px; font-weight: 700; }
.search-form { flex: 1 1 280px; justify-content: flex-end; gap: 8px; }
.search-form .input { flex: 1 1 200px; max-width: 340px; }
.webinar-summary { font-size: 14px; color: var(--ink-2); margin-top: 6px; }
.webinar-tags { margin-top: 8px; }
.row-item.webinar { align-items: flex-start; }
.row-item.webinar .row-end { padding-top: 4px; }
.resource-card .card-head { align-items: flex-start; }
.auth { grid-template-columns: minmax(0, 400px) minmax(0, 1fr); max-width: 960px; }
@media (max-width: 900px) { .auth { grid-template-columns: minmax(0, 1fr); } }
.field select, select.input { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
/* school picker */
.school-selected { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 12px 14px; border: 1px solid var(--accent); border-radius: var(--r-control); background: var(--accent-soft); }
.school-selected .row-icon { background: var(--surface); color: var(--link); }
.school-selected .row-text small { color: var(--ink-2); }
.combo { position: relative; }
.combo-list { position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 20; margin: 0; padding: 6px; list-style: none; max-height: 320px; overflow-y: auto; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-control); box-shadow: 0 18px 40px -16px rgba(13, 24, 33, .35); }
.combo-option { display: flex; flex-direction: column; padding: 8px 10px; border-radius: 8px; cursor: pointer; }
.combo-option strong { font-size: 14.5px; }
.combo-option small { font-size: 12.5px; color: var(--ink-3); }
.combo-option:hover, .combo-option[aria-selected="true"] { background: var(--accent-soft); }
.combo-option[aria-selected="true"] small { color: var(--ink-2); }
.crumbs > span:first-child { flex: none; }

/* Definições › Aparência: two-colour preview of each skin (rail, canvas). */
.skin-swatch { display: inline-flex; flex: none; width: 40px; height: 28px; border-radius: 6px; overflow: hidden; box-shadow: inset 0 0 0 1px var(--line-strong); }
.skin-swatch span:first-child { width: 12px; }
.skin-swatch span:last-child { flex: 1; }
