:root {
  color-scheme: light dark;
  --page: #07121f; --page-glow: #12344a; --surface: #0b1b2b; --surface-strong: #102438;
  --text: #eefcf8; --muted: #a8bbb5; --line: rgb(255 255 255 / 0.13);
  --accent: #5be5be; --accent-ink: #052018;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
:root[data-theme="light"] { --page: #edf5f2; --page-glow: #c9f5e7; --surface: #ffffff; --surface-strong: #f3faf7; --text: #11231d; --muted: #526760; --line: rgb(17 35 29 / 0.15); --accent: #087f61; --accent-ink: #ffffff; color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }
@media (prefers-color-scheme: light) { :root[data-theme="system"] { --page: #edf5f2; --page-glow: #c9f5e7; --surface: #ffffff; --surface-strong: #f3faf7; --text: #11231d; --muted: #526760; --line: rgb(17 35 29 / 0.15); --accent: #087f61; --accent-ink: #ffffff; } }
* { box-sizing: border-box; }
body { min-width: 280px; margin: 0; color: var(--text); background: radial-gradient(circle at top, var(--page-glow), var(--page) 44rem) fixed; }
button, input, select { font: inherit; }
a { color: inherit; }
.topbar { position: sticky; z-index: 2; top: 0; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 0.85rem clamp(1rem, 4vw, 3rem); border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--page), transparent 10%); backdrop-filter: blur(16px); }
.brand { color: var(--accent); font-size: 0.82rem; font-weight: 800; letter-spacing: 0.16em; text-decoration: none; }
.tool-nav { display: flex; align-items: center; gap: 0.3rem; padding: 0.25rem; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.tool-nav a { padding: 0.48rem 0.75rem; color: var(--muted); border-radius: 999px; text-decoration: none; font-size: 0.86rem; font-weight: 750; }
.tool-nav a[aria-current="page"] { color: var(--accent-ink); background: var(--accent); }
.tool-nav a:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent), transparent 55%); outline-offset: 2px; }
.global-controls { display: flex; align-items: end; gap: 0.7rem; }
.global-controls label { display: grid; gap: 0.25rem; color: var(--muted); font-size: 0.75rem; }
.global-controls select { min-width: 8.5rem; }
.page { width: min(820px, calc(100% - 2rem)); margin: 0 auto; padding: clamp(2rem, 7vw, 5rem) 0; }
.hero { padding-bottom: 2rem; }
.hero h1 { max-width: 12ch; margin: 0.2rem 0 1rem; font-size: clamp(2.5rem, 9vw, 5.8rem); line-height: 0.92; letter-spacing: -0.055em; }
.eyebrow, .step-label { margin: 0 0 0.55rem; color: var(--accent); font-size: 0.75rem; font-weight: 800; letter-spacing: 0.17em; }
.lead { max-width: 62ch; color: var(--muted); font-size: clamp(1.05rem, 3vw, 1.3rem); line-height: 1.55; }
.flow { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.65rem; margin: 1.5rem 0 0; padding: 0; list-style: none; counter-reset: flow; }
.flow li { display: flex; align-items: center; gap: 0.75rem; color: var(--muted); counter-increment: flow; }
.flow li::before { display: grid; flex: 0 0 1.8rem; width: 1.8rem; height: 1.8rem; place-items: center; color: var(--accent-ink); border-radius: 50%; background: var(--accent); content: counter(flow); font-size: 0.78rem; font-weight: 800; }
.steps { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1rem; }
.card { min-width: 0; padding: clamp(1rem, 4vw, 1.8rem); border: 1px solid var(--line); border-radius: 20px; background: color-mix(in srgb, var(--surface), transparent 4%); box-shadow: 0 1.2rem 3rem rgb(0 0 0 / 0.16); }
.card h2 { margin: 0 0 0.65rem; font-size: clamp(1.35rem, 4vw, 1.8rem); }
.card h3 { margin-top: 0; }
.muted { color: var(--muted); line-height: 1.5; }
.control-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.9rem; }
.field { display: grid; gap: 0.4rem; color: var(--muted); }
input, select { width: 100%; min-height: 2.75rem; padding: 0.65rem 0.75rem; color: var(--text); border: 1px solid var(--line); border-radius: 11px; outline: none; background: var(--surface-strong); }
input:focus, select:focus, button:focus-visible { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent), transparent 72%); }
input[type="color"] { min-height: 3.15rem; padding: 0.25rem; }
input[type="range"] { padding-inline: 0; }
.check { display: flex; align-items: flex-start; gap: 0.65rem; color: var(--muted); line-height: 1.45; }
.check input { flex: 0 0 auto; width: 1.15rem; min-height: 1.15rem; margin-top: 0.15rem; }
.field-error { min-height: 1.2em; margin: 0.35rem 0 0; color: #ff9b9b; }
.preview { --chat-font-family: system-ui, sans-serif; --chat-font-size: 20px; --chat-font-weight: 600; --chat-text-color: #eefcf8; --chat-accent-color: #5be5be; --preview-bg: #07121f00; --chat-radius: 10px; --chat-border-width: 0px; --chat-gap: 8px; --chat-shadow: none; display: flex; min-height: 280px; flex-direction: column; justify-content: end; gap: var(--chat-gap); padding: clamp(0.8rem, 3vw, 1.3rem); overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: linear-gradient(145deg, #694f9e, #23505c 55%, #102438); font-family: var(--chat-font-family); font-size: var(--chat-font-size); color: var(--chat-text-color); }
.preview-message { width: fit-content; max-width: 100%; padding: 0.3em 0.62em; overflow-wrap: anywhere; border: var(--chat-border-width) solid var(--chat-accent-color); border-radius: var(--chat-radius); background: var(--preview-bg); box-shadow: var(--chat-shadow); }
.preview-message strong { color: var(--chat-accent-color); font-weight: var(--chat-font-weight); }
.preview[data-align="center"] { align-items: center; text-align: center; }
.preview[data-align="right"] { align-items: end; text-align: right; }
.preview[data-theme="minimal"] .preview-message { padding-inline: 0; }
.preview[data-theme="subtitle"] .preview-message { text-shadow: 0 0.08em 0.22em rgb(0 0 0 / 0.95); }
.preview[data-theme="neon"] .preview-message { box-shadow: 0 0 0.9em color-mix(in srgb, var(--chat-accent-color), transparent 45%); }
.warning { margin: 1rem 0; padding: 1rem; border: 1px solid color-mix(in srgb, #f4bf58, transparent 35%); border-radius: 14px; background: color-mix(in srgb, #f4bf58, transparent 90%); }
.warning p, .warning details { color: var(--muted); line-height: 1.55; }
.warning summary { color: var(--text); cursor: pointer; font-weight: 700; }
.acknowledgement { margin: 1rem 0; }
.url { margin-bottom: 0.8rem; font-family: ui-monospace, Consolas, monospace; font-size: 0.82rem; }
button { min-height: 2.8rem; padding: 0.7rem 1rem; color: var(--accent-ink); border: 1px solid var(--accent); border-radius: 11px; background: var(--accent); cursor: pointer; font-weight: 800; }
button:disabled { cursor: not-allowed; opacity: 0.42; }
@media (max-width: 760px) { .topbar { position: static; align-items: flex-start; flex-wrap: wrap; } .global-controls { width: 100%; } }
@media (max-width: 620px) { .global-controls { flex-direction: column; align-items: stretch; } .global-controls select { min-width: 7.5rem; } .tool-nav { order: 2; } }
