#modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 60;
    padding: var(--space-8) var(--space-4);
    overflow: hidden;
}
#modal.active {
    display: flex;
}
.modal-backdrop {
    position: fixed;
    inset: 0;
    background-color: rgb(0 0 0 / 0.5);
    pointer-events: auto;
    z-index: -1;
    backdrop-filter: blur(2px);
}
.modal-content {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
    max-height: calc(100dvh - 4rem);
    overflow: hidden;
    position: relative;
    width: 100%;
    animation: modal-in 0.15s ease;
}
@keyframes modal-in {
    from {
        opacity: 0;
        transform: scale(0.97) translateY(-4px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}
.modal-content > form {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
}
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-4) var(--space-6);
    border-bottom: 1px solid var(--color-border);
    flex-shrink: 0;
}
.modal-title {
    font-size: var(--font-size-lg);
    font-weight: 600;
    letter-spacing: -0.015em;
    color: var(--color-fg);
    margin: 0;
    line-height: 1.3;
}
.modal-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: var(--radius);
    border: none;
    background: transparent;
    color: var(--color-muted-fg);
    cursor: pointer;
    flex-shrink: 0;
    margin-left: var(--space-4);
    transition:
        background-color var(--transition),
        color var(--transition);
}
.modal-close:hover {
    background-color: var(--color-muted);
    color: var(--color-fg);
}
.modal-body {
    flex: 1 1 auto;
    padding: var(--space-6);
    overflow-y: auto;
    overflow-x: auto;
    min-height: 0;
}
.modal-body-flush {
    padding: 0;
}
.modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: var(--space-2);
    padding: var(--space-4) var(--space-6);
    border-top: 1px solid var(--color-border);
    flex-shrink: 0;
    background-color: var(--color-muted);
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}
.modal-sm {
    max-width: 400px;
}
.modal-600 {
    max-width: 600px;
}
.modal-md {
    max-width: 720px;
}
.modal-lg {
    max-width: 960px;
}
.modal-full {
    max-width: calc(100vw - var(--space-8));
    width: calc(100vw - var(--space-8));
}
@media (max-width: 640px) {
    #modal {
        padding: 0;
        align-items: flex-end;
    }
    .modal-content {
        border-radius: var(--radius-lg) var(--radius-lg) 0 0;
        max-height: 92vh;
        width: 100%;
    }
    .modal-600,
    .modal-full {
        max-width: 100%;
        width: 100%;
    }
}
.toast {
    position: fixed;
    bottom: -80px;
    right: 1.25rem;
    padding: 0.6rem 1rem;
    border-radius: var(--radius-sm);
    font-size: var(--font-size-sm);
    font-weight: 500;
    max-width: 360px;
    box-shadow: 0 4px 12px rgb(0 0 0 / 0.15);
    transition:
        bottom 0.25s cubic-bezier(0.34, 1.56, 0.64, 1),
        opacity 0.25s ease;
    opacity: 0;
    cursor: pointer;
    z-index: 70;
    border: 1px solid transparent;
}
.toast-success {
    background-color: var(--color-success-subtle);
    color: var(--color-success-text);
    border-color: var(--color-success-border);
}
.toast-error {
    background-color: var(--color-destructive-subtle);
    color: var(--color-destructive-text);
    border-color: var(--color-destructive-border);
}
.toast.show {
    bottom: 1.5rem;
    opacity: 1;
}
:root {
    --color-text: #1a1a1a;
    --color-background: #fafafa;
    --font-serif: "Libre Baskerville", serif;
    --font-sans: "Inter", system-ui, -apple-system, sans-serif;
}
html,
body {
    margin: 0;
    padding: 0;
    background: var(--color-background);
}
body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-family: var(--font-sans);
    color: var(--color-text);
    min-height: 100dvh;
    box-sizing: border-box;
    padding: 40px 20px;
}
main {
    max-width: 720px;
}
h1 {
    font-family: var(--font-serif);
    font-weight: 700;
    font-size: 2.4rem;
    letter-spacing: 0.04em;
}
p {
    line-height: 1.9;
    font-size: 1.1rem;
    font-weight: 300;
}
p br {
    display: block;
    margin-bottom: 0.8rem;
}
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 300;
    font-display: swap;
    src: url('/fonts/inter/inter-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 300;
    font-display: swap;
    src: url('/fonts/inter/inter-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('/fonts/inter/inter-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('/fonts/inter/inter-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: 'Libre Baskerville';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('/fonts/libre-baskerville/libre-baskerville-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'Libre Baskerville';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('/fonts/libre-baskerville/libre-baskerville-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: 'Libre Baskerville';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('/fonts/libre-baskerville/libre-baskerville-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'Libre Baskerville';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('/fonts/libre-baskerville/libre-baskerville-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
