.brand-logo {
	width: 22px;
	height: auto;
}
:root {
    --bg: #f6f7fb;
    --surface: #ffffff;
    --surface2: #fbfbfe;
    --text: #0f1115;
    --muted: rgba(15, 17, 21, 0.66);
    --border: rgba(15, 17, 21, 0.10);
    --shadow: 0 10px 30px rgba(15, 17, 21, 0.08);
    --accent: #f2c94c;
    --accent2: #e9b825;
    --accentText: #121212;
    --focus: rgba(242, 201, 76, 0.55);
    --radius: 16px;

    --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    --sans: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
}

[data-theme="dark"] {
    --bg: #0b0d10;
    --surface: #101319;
    --surface2: #0d1016;
    --text: rgba(255,255,255,0.92);
    --muted: rgba(255,255,255,0.62);
    --border: rgba(255,255,255,0.10);
    --shadow: 0 14px 40px rgba(0,0,0,0.55);
    --accent: #eecb5a;
    --accent2: #d9ae2a;
    --accentText: #111111;
    --focus: rgba(238, 203, 90, 0.55);
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
    margin: 0;
    font-family: var(--sans);
    color: var(--text);
    background: var(--bg);
    line-height: 1.35;
}

a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; }
::selection { background: rgba(242, 201, 76, 0.35); }

.page { position: relative; min-height: 100vh; padding-bottom: 60px; }
.container { max-width: 760px; margin: 0 auto; padding: 24px 18px 42px; }

.h1 {
    margin: 0;
    font-size: 28px;
    letter-spacing: -0.02em;
}
.h2 {
    margin: 0;
    font-size: 18px;
    letter-spacing: -0.01em;
}
.h2:focus { outline: none; }
.subtle { color: var(--muted); font-size: 14px; }
.mono { font-family: var(--mono); }
.mt-6 { margin-top: 6px; }
.mt-8 { margin-top: 8px; }
.mt-10 { margin-top: 10px; }
.mt-18 { margin-top: 18px; }

.intro {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin: 18px 0 18px;
}
.intro p { margin: 8px 0 0; max-width: 520px; }

.theme {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.theme-label { font-size: 12px; }

.segmented {
    display: inline-flex;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 3px;
    box-shadow: 0 6px 18px rgba(15, 17, 21, 0.06);
}
[data-theme="dark"] .segmented { box-shadow: 0 10px 26px rgba(0,0,0,0.35); }

.seg-btn {
    position: relative;
    border: 0;
    background: transparent;
    color: var(--muted);
    padding: 8px 12px;
    border-radius: 999px;
    cursor: pointer;
    font-size: 13px;
    outline: none;
}
.seg-btn[aria-checked="true"] {
    background: linear-gradient(180deg, var(--accent), var(--accent2));
    color: var(--accentText);
    box-shadow: 0 10px 24px rgba(242, 201, 76, 0.26);
}
.seg-btn:focus-visible { box-shadow: 0 0 0 4px var(--focus); }


.topbar {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(10px);
    background: color-mix(in srgb, var(--bg) 78%, transparent);
    border-bottom: 1px solid var(--border);
}
.topbar-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 12px 18px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 14px;
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-width: 140px;
}
.brand-mark {
    width: 26px; height: 26px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center; justify-content: center;
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: 0 10px 20px rgba(15, 17, 21, 0.06);
}
.brand-mark svg { color: var(--accent2); }
.brand-text { font-weight: 650; letter-spacing: -0.01em; }

.nav { display: inline-flex; align-items: center; gap: 10px; justify-content: center; }
.nav-item { position: relative; }
.nav-trigger {
    border: 1px solid transparent;
    background: transparent;
    color: var(--muted);
    padding: 10px 10px;
    border-radius: 10px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    outline: none;
}
.nav-trigger:hover { color: var(--text); background: color-mix(in srgb, var(--surface) 70%, transparent); }
.nav-trigger:focus-visible { box-shadow: 0 0 0 4px var(--focus); border-color: color-mix(in srgb, var(--accent) 40%, var(--border)); }

.chev {
    width: 10px; height: 10px;
    display: inline-block;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    opacity: 0.7;
    margin-top: -2px;
}

.dropdown-panel {
    position: absolute;
    top: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%);
    min-width: 220px;
    padding: 10px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    box-shadow: var(--shadow);
    display: none;
}
.dropdown-panel.open { display: block; animation: pop 120ms ease-out; }

@keyframes pop {
    from { opacity: 0; transform: translateX(-50%) translateY(-6px); }
    to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 10px;
    border-radius: 12px;
    color: var(--text);
    outline: none;
}
.menu-item:hover { background: color-mix(in srgb, var(--accent) 12%, var(--surface)); }
.menu-item:focus-visible { box-shadow: 0 0 0 4px var(--focus); }

.topbar-actions {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    min-width: 180px;
}
.link.subtle { font-size: 13px; color: var(--muted); }
.link.subtle:hover { color: var(--text); }

.btn {
    border: 1px solid transparent;
    border-radius: 12px;
    padding: 10px 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-weight: 600;
    letter-spacing: -0.01em;
    outline: none;
    user-select: none;
}
.btn-primary {
    background: linear-gradient(180deg, var(--accent), var(--accent2));
    color: var(--accentText);
    box-shadow: 0 14px 26px rgba(242, 201, 76, 0.20);
}
.btn-primary:hover { filter: brightness(0.98); }
.btn-primary:focus-visible { box-shadow: 0 0 0 4px var(--focus), 0 14px 26px rgba(242, 201, 76, 0.20); }

.btn-secondary {
    background: var(--surface);
    color: var(--text);
    border-color: var(--border);
}
.btn-secondary:hover { background: color-mix(in srgb, var(--surface) 80%, var(--accent) 8%); }
.btn-secondary:focus-visible { box-shadow: 0 0 0 4px var(--focus); }

.btn-ghost {
    background: transparent;
    color: var(--muted);
    border-color: transparent;
    padding: 10px 8px;
}
.btn-ghost:hover { color: var(--text); background: color-mix(in srgb, var(--surface) 70%, transparent); }
.btn-ghost:focus-visible { box-shadow: 0 0 0 4px var(--focus); }

.btn[disabled] { opacity: 0.7; cursor: not-allowed; }
.btn .spinner {
    width: 14px; height: 14px;
    border-radius: 999px;
    border: 2px solid color-mix(in srgb, var(--accentText) 30%, transparent);
    border-top-color: color-mix(in srgb, var(--accentText) 85%, transparent);
    display: none;
    animation: spin 0.8s linear infinite;
}
.btn.loading .spinner { display: inline-block; }
.btn.loading .btn-label { opacity: 0.85; }

@keyframes spin { to { transform: rotate(360deg); } }


.card {
    margin-top: 14px;
    background: color-mix(in srgb, var(--surface) 92%, transparent);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 18px;
}

.steps { margin-bottom: 16px; }
.steps-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
    margin-bottom: 10px;
}
.step-pill {
    font-size: 12.5px;
    padding: 10px 10px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: var(--surface2);
    color: var(--muted);
    text-align: center;
}
.step-pill[aria-selected="true"] {
    background: color-mix(in srgb, var(--accent) 16%, var(--surface));
    color: var(--text);
    border-color: color-mix(in srgb, var(--accent) 30%, var(--border));
}

.progress {
    height: 8px;
    border-radius: 999px;
    background: color-mix(in srgb, var(--border) 55%, transparent);
    overflow: hidden;
}
.progress-bar {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent), var(--accent2));
}

.step { padding: 10px 2px 2px; }
.hidden { display: none !important; }

.field { margin-top: 14px; }
.label {
    display: inline-block;
    font-size: 13px;
    color: color-mix(in srgb, var(--text) 92%, var(--muted));
    margin-bottom: 8px;
}
.req { color: color-mix(in srgb, var(--accent2) 90%, #000); }
.hint { margin-top: 8px; }
.error {
    margin-top: 8px;
    color: #c03b3b;
    font-size: 12.5px;
    min-height: 16px;
}
[data-theme="dark"] .error { color: #ff7a7a; }

.input-wrap { position: relative; }
.prefix {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted);
    font-weight: 600;
}
.input {
    width: 100%;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    padding: 12px 12px;
    outline: none;
    box-shadow: 0 8px 18px rgba(15, 17, 21, 0.05);
}
.input-prefix { padding-left: 28px; }
.textarea { resize: vertical; min-height: 96px; }
.input.mono { font-family: var(--mono); }
.input:focus-visible {
    box-shadow: 0 0 0 4px var(--focus), 0 8px 18px rgba(15, 17, 21, 0.05);
    border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
}
.input.readonly {
    background: color-mix(in srgb, var(--surface) 70%, var(--bg));
    color: color-mix(in srgb, var(--text) 92%, var(--muted));
}


.input[type="number"]::-webkit-outer-spin-button,
.input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    appearance: none;
    margin: 0;
}
.input[type="number"] {
    -moz-appearance: textfield;
    appearance: textfield;
}


.numstep .input { padding-right: 84px; }
.numstep-btns {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    display: grid;
    grid-template-columns: 34px 34px;
    gap: 6px;
}
.numstep-btn {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: color-mix(in srgb, var(--surface) 88%, var(--bg));
    color: var(--text);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    outline: none;
    box-shadow: 0 8px 18px rgba(15, 17, 21, 0.05);
}
[data-theme="dark"] .numstep-btn {
    box-shadow: 0 12px 26px rgba(0,0,0,0.35);
}
.numstep-btn:hover {
    background: color-mix(in srgb, var(--surface) 80%, var(--accent) 10%);
}
.numstep-btn:focus-visible {
    box-shadow: 0 0 0 4px var(--focus), 0 8px 18px rgba(15, 17, 21, 0.05);
    border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
}
.numstep-btn svg { width: 16px; height: 16px; opacity: 0.9; }


.cselect { position: relative; }
.cselect-btn {
    width: 100%;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    padding: 12px 12px;
    outline: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    box-shadow: 0 8px 18px rgba(15, 17, 21, 0.05);
}
.cselect-btn:focus-visible {
    box-shadow: 0 0 0 4px var(--focus), 0 8px 18px rgba(15, 17, 21, 0.05);
    border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
}
.cselect-value { color: color-mix(in srgb, var(--text) 90%, var(--muted)); }
.cselect.has-value .cselect-value { color: var(--text); }

.cselect-panel {
    position: absolute;
    z-index: 10;
    left: 0;
    right: 0;
    margin-top: 10px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    box-shadow: var(--shadow);
    padding: 8px;
    display: none;
    max-height: 280px;
    overflow: auto;
}
.cselect-panel.open { display: block; animation: pop2 120ms ease-out; }
@keyframes pop2 { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: translateY(0); } }

.cselect-group { padding: 6px; }
.cselect-group-title {
    font-size: 11px;
    color: var(--muted);
    padding: 6px 8px 8px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.cselect-option {
    padding: 10px 10px;
    border-radius: 12px;
    cursor: pointer;
    outline: none;
}
.cselect-option:hover { background: color-mix(in srgb, var(--accent) 12%, var(--surface)); }
.cselect-option[aria-selected="true"] {
    background: color-mix(in srgb, var(--accent) 18%, var(--surface));
    border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--border));
}
.cselect-option:focus-visible { box-shadow: 0 0 0 4px var(--focus); }


.checklist {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    padding: 6px 0 2px;
}
@media (max-width: 560px) {
    .checklist { grid-template-columns: 1fr; }
}

.cbox {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 10px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: var(--surface);
    cursor: pointer;
    user-select: none;
    box-shadow: 0 8px 18px rgba(15, 17, 21, 0.04);
}
.cbox-native {
    position: absolute;
    opacity: 0;
    width: 1px; height: 1px;
    pointer-events: none;
}
.cbox-ui {
    width: 18px; height: 18px;
    border-radius: 6px;
    border: 1px solid color-mix(in srgb, var(--border) 90%, transparent);
    background: var(--surface2);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--border) 40%, transparent);
}
.cbox-text { font-size: 13px; color: var(--text); }

.cbox:focus-within {
    box-shadow: 0 0 0 4px var(--focus), 0 8px 18px rgba(15, 17, 21, 0.04);
    border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
}

.cbox-native:checked + .cbox-ui {
    background: linear-gradient(180deg, var(--accent), var(--accent2));
    border-color: color-mix(in srgb, var(--accent2) 60%, var(--border));
    box-shadow: 0 10px 18px rgba(242, 201, 76, 0.18);
}
.cbox-native:checked + .cbox-ui::after {
    content: "";
    width: 9px; height: 5px;
    border-left: 2px solid var(--accentText);
    border-bottom: 2px solid var(--accentText);
    transform: rotate(-45deg);
    margin-top: -1px;
}


.radio-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
@media (max-width: 560px) {
    .radio-row { grid-template-columns: 1fr; }
}
.cradio {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 10px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: var(--surface);
    cursor: pointer;
    user-select: none;
    box-shadow: 0 8px 18px rgba(15, 17, 21, 0.04);
}
.cradio-native {
    position: absolute;
    opacity: 0;
    width: 1px; height: 1px;
    pointer-events: none;
}
.cradio-ui {
    width: 18px; height: 18px;
    border-radius: 999px;
    border: 1px solid color-mix(in srgb, var(--border) 90%, transparent);
    background: var(--surface2);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--border) 40%, transparent);
}
.cradio-text { font-size: 13px; color: var(--text); }
.cradio:focus-within {
    box-shadow: 0 0 0 4px var(--focus), 0 8px 18px rgba(15, 17, 21, 0.04);
    border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
}

.cradio-native:checked + .cradio-ui {
    background: linear-gradient(180deg, var(--accent), var(--accent2));
    border-color: color-mix(in srgb, var(--accent2) 60%, var(--border));
}
.cradio-native:checked + .cradio-ui::after {
    content: "";
    width: 8px; height: 8px;
    border-radius: 999px;
    background: var(--accentText);
}


.actions { margin-top: 18px; display: flex; justify-content: flex-end; }
.actions.between { justify-content: space-between; align-items: center; }


.strength { margin-top: 10px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.strength-bar {
    flex: 1;
    height: 8px;
    background: color-mix(in srgb, var(--border) 55%, transparent);
    border-radius: 999px;
    overflow: hidden;
}
.strength-fill {
    height: 100%;
    width: 0%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--accent), var(--accent2));
}
.strength-text { min-width: 120px; text-align: right; }


.success { padding: 8px 4px 12px; }
.success-icon {
    width: 44px; height: 44px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: color-mix(in srgb, var(--accent) 18%, var(--surface));
    border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--border));
    box-shadow: 0 12px 26px rgba(242, 201, 76, 0.16);
    margin-bottom: 10px;
}
.ref {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}
.ref-box {
    display: grid;
    gap: 6px;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: var(--surface2);
    min-width: 240px;
}


.toast-region {
    position: fixed;
    z-index: 80;
    left: 0; right: 0;
    bottom: 18px;
    display: flex;
    justify-content: center;
    pointer-events: none;
    padding: 0 18px;
}
.toast {
    pointer-events: none;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 160ms ease, transform 160ms ease;
    background: color-mix(in srgb, var(--surface) 92%, transparent);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    border-radius: 14px;
    padding: 12px 14px;
    color: var(--text);
    font-size: 13px;
    max-width: 540px;
}
.toast.show {
    opacity: 1;
    transform: translateY(0);
}


.bg-deco { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.blob {
    position: absolute;
    filter: blur(40px);
    opacity: 0.55;
    transform: translateZ(0);
    border-radius: 999px;
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--accent) 40%, transparent), transparent 60%);
}
.blob.b1 { width: 520px; height: 520px; top: -210px; left: -190px; }
.blob.b2 { width: 520px; height: 520px; bottom: -230px; right: -220px; opacity: 0.45; }


.row-between { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
