:root {
    --paper: #f3f6ef;
    --ink: #18271d;
    --muted: #5d675e;
    --line: #d7dece;
    --forest: #1b2a1f;
    --cream: #f4f7f0;
    --lime: #d7edb3;
    --olive: #6d7f58;
    --video: #6d4f96;
    --video-wash: #f4eef8;
    --search: #3d5c2e;
    --search-wash: #eef4e6;
    --danger: #8f3926;
}
* { box-sizing: border-box; }
body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(820px 360px at 0% -10%, rgba(215, 237, 179, 0.65), transparent 60%),
        radial-gradient(640px 320px at 100% 0%, rgba(109, 79, 150, 0.08), transparent 55%),
        var(--paper);
    color: var(--ink);
    font: 16px/1.6 Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
a:focus-visible, button:focus-visible, summary:focus-visible {
    outline: 3px solid #7359a6;
    outline-offset: 3px;
}
button { font: inherit; cursor: pointer; }
.skip:not(:focus) {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
}
.bar, .foot, .shell { width: min(1120px, calc(100% - 40px)); margin: 0 auto; }
.bar, .foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px 24px;
    flex-wrap: wrap;
}
.bar { min-height: 80px; }
.brand {
    color: var(--ink);
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.06em;
    text-decoration: none;
}
.brand sup { font-size: 10px; }
.bar nav { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.bar nav a, .bar button, .foot { color: var(--muted); font-size: 14px; font-weight: 650; text-decoration: none; }
.bar button {
    min-height: 40px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: white;
    color: var(--ink);
}
.bar form { margin: 0; }
.shell { padding-bottom: 48px; }
.eyebrow {
    margin: 0 0 10px;
    color: var(--olive);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}
h1 {
    margin: 0;
    font-family: "Instrument Serif", Georgia, serif;
    font-size: clamp(46px, 6vw, 76px);
    font-weight: 400;
    letter-spacing: -0.045em;
    line-height: 0.94;
}
h1 em { font-style: italic; color: #3f6a32; }
h2 { margin: 0; font-size: 22px; letter-spacing: -0.04em; }
.gate {
    max-width: 680px;
    margin: 28px 0 40px;
    padding: 48px 40px;
    background: white;
    border: 1px solid rgba(24, 39, 29, 0.08);
    border-radius: 28px;
    box-shadow: 0 24px 60px rgba(24, 39, 29, 0.06);
}
.gate p, .welcome p { margin: 16px 0 0; color: var(--muted); max-width: 46ch; }
.gate-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 22px; margin-top: 28px; }
button.button, .button, .next a, .tool .button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 0 18px;
    border-radius: 12px;
    background: var(--ink);
    color: white;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
}
button.button { border: 0; }
.button.danger { background: var(--danger); }
.quiet { font-weight: 700; }
.check { display: flex; gap: 10px; align-items: flex-start; margin: 12px 0; font-size: 14px; }
.check input { margin-top: 4px; }
.error { color: var(--danger); font-weight: 650; }
.welcome {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin: 12px 0 22px;
}
.pill {
    margin: 0;
    padding: 8px 14px;
    border-radius: 999px;
    background: var(--lime);
    color: var(--forest);
    font-size: 13px;
    font-weight: 750;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.pill.wait { background: #efe6c8; }
.pill.paused, .pill.closed { background: #f3e4df; color: var(--danger); }
.notice {
    margin: 0 0 22px;
    padding: 14px 16px;
    border-radius: 14px;
    background: white;
    border: 1px solid var(--line);
    color: var(--ink);
    font-size: 14px;
}
.notice a { font-weight: 750; }
.notice.warn { background: #fbf6f1; border-color: #ead8cf; }
.stats, .tools, .next { display: grid; gap: 14px; }
.stats { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-bottom: 14px; }
.stats article, .tool, .next article, .setup {
    min-width: 0;
    background: white;
    border: 1px solid rgba(24, 39, 29, 0.08);
    border-radius: 20px;
}
.stats article { padding: 18px 18px 16px; }
.stats span, .secret span, .state {
    display: block;
    color: var(--olive);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.stats strong {
    display: block;
    margin-top: 8px;
    font-size: clamp(22px, 2vw, 28px);
    letter-spacing: -0.04em;
}
.stats small, .secret p, details p, .empty, .pin, .next p {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.5;
    overflow-wrap: anywhere;
}
.tools { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.tool { padding: 22px; display: flex; flex-direction: column; gap: 14px; }
.tool header { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.tool.video { background: linear-gradient(180deg, var(--video-wash), white 90px); }
.tool.search { background: linear-gradient(180deg, var(--search-wash), white 90px); }
.mark {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: var(--video);
    color: white;
    font-family: Georgia, serif;
    font-size: 24px;
    font-style: italic;
    font-weight: 700;
}
.tool.search .mark { background: #d7e7b8; color: var(--search); }
.tool header p { margin: 2px 0 0; }
.state { text-align: right; }
.secret-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center; margin-top: 8px; }
code {
    display: block;
    min-width: 0;
    padding: 10px 12px;
    border-radius: 10px;
    background: #f7f8f4;
    border: 1px solid var(--line);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 13px;
    overflow-wrap: anywhere;
}
.secret-row button, details summary {
    min-height: 42px;
    border: 0;
    border-radius: 10px;
    background: var(--forest);
    color: white;
    font-weight: 700;
    padding: 0 12px;
}
details summary { display: flex; align-items: center; width: fit-content; cursor: pointer; list-style: none; }
details summary::-webkit-details-marker { display: none; }
.tool .button { margin-top: auto; }
.copy-status { min-height: 1.4em; margin: 8px 0 0; color: var(--olive); font-size: 13px; font-weight: 650; }
.next { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 14px; }
.next article { padding: 22px; }
.next a { margin-top: 16px; }
.setup { margin-top: 14px; padding: 8px 22px 18px; }
.setup summary { cursor: pointer; min-height: 48px; display: flex; align-items: center; font-weight: 750; }
.setup dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 18px; margin: 8px 0 0; }
.setup dt { color: var(--olive); font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.setup dd { margin: 3px 0 0; overflow-wrap: anywhere; }
.foot { min-height: 64px; color: var(--olive); font-size: 13px; }
@media (max-width: 800px) {
    .stats, .tools, .next, .setup dl { grid-template-columns: 1fr; }
    .welcome { align-items: flex-start; flex-direction: column; }
    .gate { padding: 32px 22px; }
}
@media (max-width: 560px) {
    .bar, .foot, .shell { width: min(100% - 28px, 1120px); }
    .tool header { grid-template-columns: auto minmax(0, 1fr); }
    .state { grid-column: 2; text-align: left; }
    .secret-row { grid-template-columns: 1fr; }
    .tool .button, .next a, .gate .button { width: 100%; }
}

.atmosphere { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.atmosphere span { position: absolute; border-radius: 50%; filter: blur(46px); }
.atmosphere span:nth-child(1) { width: 480px; height: 480px; left: -140px; top: -160px; background: rgba(215, 237, 179, 0.72); animation: drift-a 18s ease-in-out infinite; }
.atmosphere span:nth-child(2) { width: 380px; height: 380px; right: -110px; top: 8%; background: rgba(109, 79, 150, 0.16); animation: drift-b 22s ease-in-out infinite; }
.atmosphere span:nth-child(3) { width: 320px; height: 320px; left: 34%; bottom: -160px; background: rgba(94, 121, 70, 0.14); animation: drift-c 20s ease-in-out infinite; }
.bar, .shell, .foot { position: relative; z-index: 1; }
.bar, .shell > .gate, .shell > .welcome, .shell > .notice, .stats article, .tool, .next article, .setup, .foot { animation: rise 0.85s cubic-bezier(0.22, 1, 0.36, 1) backwards; }
.bar { animation-delay: 0.02s; }
.shell > .gate, .shell > .welcome { animation-delay: 0.08s; }
.shell > .notice { animation-delay: 0.18s; }
.stats article:nth-child(1) { animation-delay: 0.2s; }
.stats article:nth-child(2) { animation-delay: 0.28s; }
.stats article:nth-child(3) { animation-delay: 0.36s; }
.tool:nth-child(1) { animation-delay: 0.42s; }
.tool:nth-child(2) { animation-delay: 0.52s; }
.next article:nth-child(1) { animation-delay: 0.6s; }
.next article:nth-child(2) { animation-delay: 0.68s; }
.setup { animation-delay: 0.76s; }
.foot { animation-delay: 0.2s; }
.line { display: block; overflow: hidden; padding-bottom: 0.08em; }
.line > span, .line > em { display: block; animation: line-up 0.95s cubic-bezier(0.22, 1, 0.36, 1) 0.16s backwards; }
.line + .line > em, .line + .line > span { animation-delay: 0.28s; }
.gate > p, .gate-actions, .welcome p, .pill { animation: rise 0.7s cubic-bezier(0.22, 1, 0.36, 1) backwards; }
.gate > .eyebrow { animation-delay: 0.18s; }
.gate > p { animation-delay: 0.38s; }
.gate-actions { animation-delay: 0.48s; }
.welcome .eyebrow { animation-delay: 0.16s; }
.welcome p { animation-delay: 0.34s; }
.pill { animation-delay: 0.42s; }
.pill.active { animation: rise 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.42s backwards, pulse 2.8s ease-out 1.1s infinite; }
.tool, .stats article, .next article, .button, .bar button, .bar nav a, .secret-row button {
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease, background 0.3s ease, border-color 0.3s ease;
}
.tool:hover, .stats article:hover, .next article:hover { transform: translateY(-5px); box-shadow: 0 18px 40px rgba(24, 39, 29, 0.08); }
.button:hover, .bar button:hover, .secret-row button:hover { transform: translateY(-2px); }
.button span { display: inline-block; transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1); }
.button:hover span { transform: translateX(4px); }
.mark { animation: bob 5.6s ease-in-out 1s infinite; }
details[open] > :not(summary) { animation: rise 0.4s cubic-bezier(0.22, 1, 0.36, 1) backwards; }
.copy-status.is-shown { animation: rise 0.4s cubic-bezier(0.22, 1, 0.36, 1) both; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes line-up { from { transform: translateY(115%); } to { transform: none; } }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(94, 121, 70, 0.35); } 100% { box-shadow: 0 0 0 12px rgba(94, 121, 70, 0); } }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
@keyframes drift-a { 0%, 100% { transform: translate3d(0, 0, 0) scale(1); } 50% { transform: translate3d(48px, 36px, 0) scale(1.08); } }
@keyframes drift-b { 0%, 100% { transform: translate3d(0, 0, 0); } 50% { transform: translate3d(-36px, 28px, 0) scale(1.06); } }
@keyframes drift-c { 0%, 100% { transform: translate3d(0, 0, 0); } 50% { transform: translate3d(24px, -30px, 0) scale(1.05); } }
@media (prefers-reduced-motion: reduce) {
    .atmosphere span, .bar, .shell > .gate, .shell > .welcome, .shell > .notice, .stats article, .tool, .next article, .setup, .foot, .line > span, .line > em, .gate > p, .gate-actions, .welcome p, .pill, .pill.active, .mark, details[open] > :not(summary), .copy-status.is-shown { animation: none; }
    .tool, .stats article, .next article, .button, .bar button, .bar nav a, .secret-row button, .button span { transition: none; }
    .line { overflow: visible; }
}
