:root {
    color-scheme: dark;
    font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    --bg: #101114;
    --surface: #181a1f;
    --surface-alt: #20232a;
    --border: #30343d;
    --text: #f3f4f6;
    --muted: #9ca3af;
    --accent: #f59e0b;
    --accent-text: #111111;
    --danger: #ef4444;
    --success: #22c55e;
    --disabled: #6b7280;
    --radius: 12px;
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    background: var(--bg);
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    line-height: 1.5;
}

a {
    color: var(--accent);
}

a:hover {
    text-decoration: none;
}

button,
input {
    font: inherit;
}

.shell {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.site-header {
    border-bottom: 1px solid var(--border);
    background: var(--surface);
}

.header-inner {
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.brand {
    color: var(--text);
    font-size: 1.05rem;
    font-weight: 700;
    text-decoration: none;
}

.main-content {
    padding-top: 32px;
    padding-bottom: 48px;
}

.page-heading {
    margin-bottom: 28px;
}

.page-heading h1 {
    margin-bottom: 8px;
}

.page-heading p {
    margin-top: 0;
    color: var(--muted);
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(
        auto-fit,
        minmax(280px, 1fr)
    );
    gap: 18px;
}

.project-card,
.detail-panel,
.login-panel,
.preview-panel {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
}

.project-card {
    padding: 22px;
}

.project-card-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.project-card h2 {
    margin-top: 0;
    margin-bottom: 4px;
}

.muted {
    color: var(--muted);
}

.status {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 4px 9px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.status.enabled {
    background: rgba(34, 197, 94, 0.14);
    color: var(--success);
}

.status.disabled {
    background: rgba(107, 114, 128, 0.18);
    color: #d1d5db;
}

.metadata {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 7px 18px;
    margin: 20px 0;
}

.metadata dt {
    color: var(--muted);
}

.metadata dd {
    margin: 0;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    border: 1px solid transparent;
    border-radius: 8px;
    padding: 8px 14px;
    cursor: pointer;
    font-weight: 650;
    text-decoration: none;
}

.button.primary {
    background: var(--accent);
    color: var(--accent-text);
}

.button.secondary {
    border-color: var(--border);
    background: var(--surface-alt);
    color: var(--text);
}

.button:disabled {
    cursor: wait;
    opacity: 0.65;
}

.detail-panel {
    padding: 24px;
}

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.notice {
    margin-top: 24px;
    border-left: 4px solid var(--disabled);
    border-radius: 6px;
    background: var(--surface-alt);
    padding: 14px 16px;
    color: var(--muted);
}

.health-panel {
    margin-top: 30px;
    border-top: 1px solid var(--border);
    padding-top: 22px;
}

.health-panel h2 {
    margin-top: 0;
}

.health-ok {
    color: var(--success);
}

.health-error {
    color: var(--danger);
}

.login-panel {
    width: min(460px, 100%);
    margin: 48px auto;
    padding: 28px;
}

.login-panel h1 {
    margin-top: 0;
}

.login-panel form {
    display: grid;
    gap: 10px;
    margin-top: 24px;
}

.login-panel input {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface-alt);
    color: var(--text);
    padding: 10px 12px;
}

.login-panel input:focus {
    outline: 2px solid var(--accent);
    outline-offset: 1px;
}

.messages {
    margin-bottom: 20px;
}

.message {
    border-radius: 8px;
    padding: 12px 14px;
}

.message.error {
    border: 1px solid rgba(239, 68, 68, 0.45);
    background: rgba(239, 68, 68, 0.10);
}

.preview-panel {
    overflow: hidden;
    height: calc(100vh - 190px);
    min-height: 480px;
}

.preview-panel iframe {
    width: 100%;
    height: 100%;
    border: 0;
    background: #ffffff;
}

@media (max-width: 640px) {
    .shell {
        width: min(100% - 20px, 1180px);
    }

    .header-inner {
        min-height: 58px;
    }

    .main-content {
        padding-top: 22px;
    }

    .project-card,
    .detail-panel,
    .login-panel {
        padding: 18px;
    }

    .metadata {
        grid-template-columns: 1fr;
        gap: 2px;
    }

    .metadata dd {
        margin-bottom: 10px;
    }
}

/* Spontaan platform foundation */
.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.78rem;
    font-weight: 700;
}
.spontaan-summary { margin-bottom: 1.5rem; }
.spontaan-grid { margin-bottom: 1.5rem; }
.spontaan-preview {
    display: block;
    width: min(100%, 880px);
    height: auto;
    margin-top: 1rem;
    border-radius: 12px;
}
.hash-value {
    overflow-wrap: anywhere;
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
}

