:root {
    color-scheme: dark;
    --bg: #09090b;
    --bg-elevated: #0c0c10;
    --surface: #111114;
    --surface-2: #18181b;
    --surface-hover: #1c1c21;
    --text: #fafafa;
    --text-2: #a1a1aa;
    --text-3: #71717a;
    --border: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.14);
    --primary: #f43f5e;
    --primary-hover: #e11d48;
    --primary-fg: #fff;
    --primary-soft: rgba(244, 63, 94, 0.14);
    --success: #34d399;
    --success-soft: rgba(52, 211, 153, 0.14);
    --warning: #fbbf24;
    --warning-soft: rgba(251, 191, 36, 0.14);
    --ring: 0 0 0 3px rgba(244, 63, 94, 0.32);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.45);
    --topbar-h: 56px;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --font: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
    --serif: "Fraunces", "Times New Roman", serif;
}
html[data-theme="light"] {
    color-scheme: light;
    --bg: #f4f4f5;
    --bg-elevated: #ffffff;
    --surface: #ffffff;
    --surface-2: #f4f4f5;
    --surface-hover: #ececee;
    --text: #09090b;
    --text-2: #52525b;
    --text-3: #71717a;
    --border: rgba(9, 9, 11, 0.08);
    --border-strong: rgba(9, 9, 11, 0.14);
    --primary-soft: rgba(244, 63, 94, 0.1);
    --success: #059669;
    --success-soft: rgba(16, 185, 129, 0.12);
    --warning: #d97706;
    --warning-soft: rgba(245, 158, 11, 0.12);
    --ring: 0 0 0 3px rgba(244, 63, 94, 0.22);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.1);
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; min-height: 100%; }
html, body, button, input, select { font-family: var(--font); }
body {
    background:
        radial-gradient(900px 420px at 12% -8%, rgba(244, 63, 94, 0.18), transparent 58%),
        radial-gradient(720px 380px at 92% 0%, rgba(244, 63, 94, 0.08), transparent 52%),
        var(--bg);
    color: var(--text);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}
html[data-theme="light"] body {
    background:
        radial-gradient(900px 420px at 12% -8%, rgba(244, 63, 94, 0.12), transparent 58%),
        radial-gradient(720px 380px at 92% 0%, rgba(244, 63, 94, 0.06), transparent 52%),
        var(--bg);
}
a { color: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: none; box-shadow: var(--ring); }

.app { min-height: 100vh; display: flex; flex-direction: column; }
.topbar {
    height: var(--topbar-h);
    display: flex; align-items: center; gap: 12px;
    padding: 0 16px;
    border-bottom: 1px solid var(--border);
    background: color-mix(in srgb, var(--bg-elevated) 82%, transparent);
    backdrop-filter: blur(16px);
    position: sticky; top: 0; z-index: 20;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; min-width: 0; }
.logo {
    width: 32px; height: 32px; border-radius: 9px;
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    display: grid; place-items: center;
    box-shadow: 0 6px 16px rgba(244, 63, 94, 0.35);
    overflow: hidden; flex-shrink: 0;
}
.logo img { width: 100%; height: 100%; object-fit: cover; }
.logo svg { width: 16px; height: 16px; }
.brand-copy strong { display: block; font-size: 13px; font-weight: 700; }
.brand-copy span { display: block; font-size: 11px; color: var(--text-3); font-weight: 500; }
.crumbs { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-3); font-weight: 500; }
.crumbs strong { color: var(--text); font-weight: 600; }
.top-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.header-link {
    display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px;
    border-radius: 10px; border: 1px solid var(--border); background: var(--surface);
    color: var(--text); font-size: 13px; font-weight: 600; text-decoration: none;
}
.header-link svg { width: 16px; height: 16px; flex-shrink: 0; }
.icon-btn {
    width: 36px; height: 36px; border-radius: 10px;
    border: 1px solid var(--border); background: var(--surface); color: var(--text-2);
    display: grid; place-items: center; cursor: pointer; text-decoration: none;
}
.icon-btn:hover { background: var(--surface-hover); color: var(--text); }
.icon-btn svg { width: 16px; height: 16px; }

.workspace {
    flex: 1; padding: 28px 20px 40px;
    width: 100%; max-width: 560px; margin: 0 auto;
}
.workspace.wide { max-width: 680px; }
.workspace.portal { max-width: 1120px; }
.page-head { margin-bottom: 22px; max-width: 640px; }
.page-head h1 {
    margin: 0 0 8px;
    font-family: var(--serif);
    font-size: clamp(30px, 4.2vw, 44px);
    letter-spacing: -0.03em;
    line-height: 1.12;
    font-weight: 500;
    text-align: left;
}
.page-head h1 em {
    font-style: italic;
    font-weight: 400;
    color: color-mix(in srgb, var(--text) 78%, var(--primary));
}
.page-head p { margin: 0; color: var(--text-2); font-size: 15px; line-height: 1.65; }
.layout {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.95fr);
    gap: 14px;
    align-items: start;
}
.stack { display: flex; flex-direction: column; gap: 12px; }
.feature {
    display: flex; gap: 12px; padding: 14px;
    border-radius: 14px; border: 1px solid var(--border); background: var(--bg-elevated);
}
.icon-tile {
    width: 40px; height: 40px; border-radius: 12px;
    display: grid; place-items: center; flex: 0 0 auto;
    background: var(--primary-soft); color: var(--primary);
}
.icon-tile svg { width: 18px; height: 18px; }
.feature h3 { margin: 0 0 2px; font-size: 14px; font-weight: 700; }
.feature p { margin: 0; font-size: 12.5px; color: var(--text-2); line-height: 1.5; }
.module-photo {
    position: relative;
    min-height: 220px;
    margin: 0;
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
    background: var(--surface-2);
}
.module-photo img {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    object-fit: cover;
}
.module-photo figcaption {
    position: absolute; left: 14px; right: 14px; bottom: 14px;
    padding: 12px 14px; border-radius: 12px;
    background: color-mix(in srgb, var(--bg) 70%, transparent);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    font-size: 12.5px; font-weight: 650;
}
.card {
    background: color-mix(in srgb, var(--surface) 92%, transparent);
    border: 1px solid var(--border);
    border-radius: 18px; padding: 26px 24px;
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(10px);
}
.card > h2 { margin: 0 0 6px; font-size: 16px; letter-spacing: -0.02em; font-weight: 700; text-align: left; }
.school-mark {
    display: flex;
    justify-content: center;
    margin: 0 0 16px;
}
.school-mark img {
    max-width: 96px;
    max-height: 96px;
    width: auto;
    height: auto;
    object-fit: contain;
}
.card-intro { text-align: center; }
.eyebrow {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    font-size: 12px; font-weight: 600; color: var(--primary);
    letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: 10px;
}
.card-intro .eyebrow,
.status-card .eyebrow { width: 100%; }
.eyebrow i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 4px var(--primary-soft); }
h1 {
    margin: 0 0 8px;
    font-family: var(--serif);
    font-size: clamp(26px, 3.4vw, 34px);
    letter-spacing: -0.03em;
    font-weight: 500;
    line-height: 1.15;
    text-align: center;
}
h1 em { font-style: italic; font-weight: 400; color: color-mix(in srgb, var(--text) 78%, var(--primary)); }
.desc { margin: 0 0 20px; color: var(--text-2); font-size: 14px; line-height: 1.6; text-align: center; }
.accent { color: var(--primary); }

.field { margin-bottom: 14px; }
.field label { display: block; margin-bottom: 8px; font-size: 12px; font-weight: 700; color: var(--text-2); }
.field input[type="text"],
.field input[type="password"],
.field input[type="email"],
.field input[type="tel"],
.field select {
    width: 100%; height: 44px; padding: 0 12px;
    border-radius: 10px; border: 1px solid var(--border);
    background: var(--bg); color: var(--text); font-size: 14px; font-weight: 600;
    appearance: none;
}
.field select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 24 24'%3E%3Cpath d='M6 9l6 6 6-6' stroke='%2371717a' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}
.field input::placeholder { color: var(--text-3); font-weight: 500; }
.field input:focus, .field select:focus { border-color: var(--primary); }
.field input[readonly] { color: var(--text-2); cursor: default; }
.field .hint {
    margin: 6px 0 0;
    font-size: 12px;
    color: var(--text-3);
    font-weight: 500;
    line-height: 1.45;
}
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 12px;
}
.form-grid .full { grid-column: 1 / -1; }
.section-head {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 6px 0 4px;
    padding-top: 14px;
    border-top: 1px solid var(--border);
}
.section-head:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.section-num {
    width: 22px; height: 22px; border-radius: 7px;
    display: grid; place-items: center; flex-shrink: 0;
    background: var(--primary-soft); color: var(--primary);
    font-size: 11px; font-weight: 800;
}
.section-head span {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-2);
}
.slug-preview {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    padding: 9px 12px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--bg);
    font-size: 12px;
    font-weight: 600;
    color: var(--text-2);
}
.slug-preview code {
    color: var(--text);
    font-family: inherit;
    font-weight: 800;
}
.steps {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
    margin: 0 0 12px;
}
.step {
    text-align: center;
    padding: 10px 8px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: var(--bg);
    font-size: 11px;
    font-weight: 700;
    color: var(--text-3);
    font-family: inherit;
    cursor: pointer;
}
.step.on {
    border-color: rgba(244, 63, 94, 0.35);
    background: var(--primary-soft);
    color: var(--text);
}
.step.done { color: var(--text-2); }
.wizard-progress {
    height: 4px;
    border-radius: 999px;
    background: var(--surface-2);
    margin: 0 0 18px;
    overflow: hidden;
}
.wizard-progress > i {
    display: block;
    height: 100%;
    width: 33.333%;
    background: var(--primary);
    transition: width 0.25s var(--ease);
}
.wizard-pane { display: none; }
.wizard-pane.active { display: block; }
.wizard-nav {
    display: flex;
    gap: 10px;
    margin-top: 8px;
}
.wizard-nav .btn { flex: 1; margin-top: 0; }
.btn.alt {
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--border);
    box-shadow: none;
}
.btn.alt:hover { background: var(--surface-hover); }
.wizard-error {
    margin: 0 0 12px;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid rgba(244, 63, 94, 0.28);
    background: var(--primary-soft);
    color: var(--text);
    font-size: 13px;
    font-weight: 600;
}
.wizard-error[hidden] { display: none; }
.review-list {
    margin: 0 0 16px;
    padding: 0;
    list-style: none;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--bg);
    overflow: hidden;
}
.review-list li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 11px 14px;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
}
.review-list li:last-child { border-bottom: 0; }
.review-list span { color: var(--text-3); font-weight: 600; }
.review-list strong { color: var(--text); font-weight: 700; text-align: right; }
.alert ul { margin: 0; padding-left: 18px; }
.alert.success {
    border-color: rgba(52, 211, 153, 0.28);
    background: var(--success-soft);
}
.next-steps {
    text-align: left;
    margin: 0 0 18px;
    padding: 14px 16px 14px 32px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: var(--bg);
    color: var(--text-2);
    font-size: 13.5px;
    line-height: 1.55;
    font-weight: 600;
}
.next-steps li { margin: 0 0 8px; }
.next-steps li:last-child { margin: 0; }
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    width: 100%; height: 44px; margin-top: 4px;
    border-radius: 10px; border: 0; background: var(--primary); color: var(--primary-fg);
    font-weight: 700; font-size: 14px; cursor: pointer; text-decoration: none;
    box-shadow: 0 8px 20px rgba(244, 63, 94, 0.28);
    font-family: inherit;
}
.btn:hover { background: var(--primary-hover); }
.btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.ghost {
    display: inline-flex; justify-content: center;
    color: var(--text-2); font-size: 13px; font-weight: 600; text-decoration: none;
}
.ghost:hover { color: var(--text); }
.links {
    margin-top: 18px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.alert {
    margin: 0 0 16px;
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid rgba(244, 63, 94, 0.28);
    background: var(--primary-soft);
    color: var(--text);
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.5;
    text-align: left;
}

.status-card {
    text-align: center;
    max-width: 440px;
    margin: 12px auto 0;
    padding: 32px 28px 28px;
    border: 1px solid var(--border-strong);
    border-radius: 24px;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.12);
}
.status-card h1 {
    margin: 0 0 8px;
    font-size: clamp(26px, 4vw, 34px);
    letter-spacing: -0.04em;
    line-height: 1.15;
    font-weight: 800;
}
.status-card .desc {
    max-width: 36ch;
    margin: 0 auto 8px;
    font-size: 15px;
    line-height: 1.6;
}
.status-card .school-mark img {
    max-width: 72px;
    max-height: 72px;
    padding: 6px;
    border-radius: 16px;
    border: 1px solid var(--border);
    background: var(--bg);
}
.status-card .btn { margin-top: 4px; }
.status-icon {
    width: 64px; height: 64px; border-radius: 18px;
    display: grid; place-items: center;
    margin: 0 auto 14px;
    border: 1px solid transparent;
}
.status-icon svg { width: 30px; height: 30px; }
.status-success {
    border-color: rgba(16, 185, 129, 0.35);
    background:
        radial-gradient(120% 80% at 50% 0%, var(--success-soft), transparent 58%),
        var(--surface);
}
.status-success .status-icon {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: var(--success);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 10px 24px rgba(16, 185, 129, 0.28);
}
.status-success .eyebrow { color: var(--success); }
.status-success .eyebrow i { box-shadow: 0 0 0 4px var(--success-soft); }
.status-success .accent { color: var(--success); }
.success-school {
    margin: -6px 0 14px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-3);
}
.status-invalid {
    border-color: rgba(244, 63, 94, 0.32);
    background:
        radial-gradient(120% 80% at 50% 0%, var(--primary-soft), transparent 58%),
        var(--surface);
}
.status-invalid .status-icon {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 10px 24px rgba(244, 63, 94, 0.28);
}
.status-invalid .eyebrow { color: var(--primary); }
.status-invalid .eyebrow i { background: var(--primary); box-shadow: 0 0 0 4px var(--primary-soft); }
.status-invalid .countdown-bar { stroke: var(--primary); }
.status-done .status-icon { background: var(--warning-soft); color: var(--warning); border-color: rgba(245, 158, 11, 0.35); }
.status-done .eyebrow { color: var(--warning); }
.status-done .eyebrow i { box-shadow: 0 0 0 4px var(--warning-soft); }

.countdown-container {
    position: relative;
    width: 120px;
    height: 120px;
    margin: 18px auto 14px;
}
.countdown-svg {
    transform: rotate(-90deg);
    width: 120px;
    height: 120px;
}
.countdown-bg {
    fill: none;
    stroke: var(--surface-2);
    stroke-width: 8;
}
.countdown-bar {
    fill: none;
    stroke: var(--primary);
    stroke-width: 8;
    stroke-linecap: round;
    stroke-dasharray: 326.73;
    stroke-dashoffset: 0;
    transition: stroke-dashoffset 1s linear;
}
.status-success .countdown-bar { stroke: var(--success); }
.status-done .countdown-bar { stroke: var(--warning); }
.countdown-text {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.04em;
    color: var(--text);
}
.countdown-hint {
    margin: -8px 0 18px;
    color: var(--text-3);
    font-size: 12px;
    font-weight: 600;
}

@media (max-width: 860px) {
    .layout { grid-template-columns: 1fr; }
    .module-photo { min-height: 180px; }
    .crumbs { display: none; }
    .header-link span { display: none; }
    .header-link { padding: 0; width: 36px; justify-content: center; }
}
@media (max-width: 640px) {
    .workspace { padding: 18px 14px 32px; }
    h1 { font-size: 22px; }
    .form-grid { grid-template-columns: 1fr; }
    .step { font-size: 10px; padding: 9px 4px; }
}
