:root {
    --ink: #0B1626;
    --slate: #5B6B84;
    --slate-deep: #46536B;
    --cyan: #06B6D4;
    --cyan-deep: #0891B2;
    --cyan-text: #0E7490;
    --cyan-tint: #E0F5FA;
    --mist: #EEF2F6;
    --paper: #FBFCFE;
    --surface: #FFFFFF;
    --border: #E2E8F0;
    --warn: #B45309;
    --warn-tint: #FEF3C7;
    --success: #0E9F6E;
    --danger: #DC2626;
    --font-display: "Space Grotesk", "Arial", sans-serif;
    --font-ui: "Instrument Sans", system-ui, sans-serif;
    --radius-sm: 8px;
    --radius-lg: 14px;
    --shadow-card: 0 1px 2px rgba(11, 22, 38, 0.05), 0 16px 40px rgba(11, 22, 38, 0.08);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
}

body {
    font-family: var(--font-ui);
    color: var(--ink);
    background:
        radial-gradient(1200px 480px at 50% -10%, rgba(6, 182, 212, 0.16), transparent 55%),
        var(--mist);
}

.host-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.card {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    padding: 32px;
}

.lockup {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--ink);
    min-height: 40px;
}

.lockup .logo {
    flex-shrink: 0;
}

.word {
    font-family: var(--font-display);
    font-size: 24px;
    letter-spacing: -0.02em;
}

.w-a {
    font-weight: 500;
}

.w-b {
    font-weight: 700;
}

.tagline {
    margin: 0 0 6px;
    font-size: 13px;
    line-height: 1.45;
    color: var(--slate);
}

.field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.label {
    font-size: 13px;
    font-weight: 500;
    color: var(--ink);
}

input[type="text"],
input[type="password"],
input[type="email"] {
    height: 40px;
    padding: 0 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface);
    font-family: var(--font-ui);
    font-size: 14px;
    color: var(--ink);
}

input[type="text"]:focus,
input[type="password"]:focus,
input[type="email"]:focus {
    outline: none;
    border-color: var(--cyan-deep);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.25);
}

.hint {
    font-size: 12px;
    color: var(--slate);
}

.btn-primary,
.btn-secondary,
.tool-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 44px;
    padding: 0 16px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font-ui);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}

.btn-primary {
    width: 100%;
    background: var(--ink);
    color: #fff;
}

.btn-primary:hover {
    background: #1c2b45;
}

.btn-secondary {
    background: transparent;
    color: var(--slate-deep);
}

.btn-secondary:hover {
    background: var(--mist);
    color: var(--ink);
}

.version {
    margin: 4px 0 0;
    font-size: 12px;
    font-style: italic;
    color: var(--slate);
    text-align: center;
}

.remember {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--ink);
    cursor: pointer;
}

.remember input {
    width: 16px;
    height: 16px;
    accent-color: var(--cyan-deep);
}

.user-line {
    font-size: 13px;
    color: var(--slate);
    line-height: 1.45;
}

.user-line strong {
    color: var(--ink);
    font-weight: 600;
}

.tools {
    list-style: none;
    margin: 4px 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tool-link {
    width: 100%;
    justify-content: flex-start;
    gap: 12px;
    background: var(--paper);
    border: 1px solid var(--border);
    color: var(--ink);
}

.tool-link:hover {
    border-color: var(--cyan-deep);
    background: var(--cyan-tint);
}

.tool-link .tool-name {
    font-weight: 600;
}

.tool-link .tool-meta {
    margin-left: auto;
    font-size: 12px;
    font-weight: 500;
    color: var(--slate);
}

.card-foot {
    display: flex;
    justify-content: flex-end;
    margin-top: 8px;
}

.database-alert {
    max-width: 520px;
    background: var(--warn-tint);
    color: var(--warn);
    padding: 16px 20px;
    border: 1px solid #f3d48a;
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: var(--shadow-card);
}
