/* App pages (login, start page, later screens). Mobile-first; colours come from theme.css variables only. */

.app-header {
    display: flex;
    align-items: center;
    gap: 12px;
    max-width: 640px;
    margin: 0 auto;
    padding: 16px 16px 0;
}
.app-header .logo { width: 120px; height: auto; }
.org-name { color: var(--muted); font-weight: 600; overflow-wrap: anywhere; }

main.center {
    max-width: 640px;
    margin: 0 auto;
    padding: 16px;
}

.card {
    background: var(--tint);
    border-top: 4px solid var(--accent);
    border-radius: 10px;
    padding: 20px;
}
.card h1 { margin: 0 0 8px; color: var(--brand); font-size: 1.6rem; line-height: 1.2; overflow-wrap: anywhere; }
.role { margin: 0 0 16px; }

.field { margin-bottom: 14px; }
.field label { display: block; margin-bottom: 4px; font-weight: 600; color: var(--brand); }
.field input {
    width: 100%;
    min-height: 46px;
    padding: 10px 12px;
    font: inherit;
    color: var(--ink);
    background: var(--white);
    border: 2px solid var(--brand);
    border-radius: 8px;
}

button.primary, button.secondary {
    min-height: 46px;
    padding: 10px 18px;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    border-radius: 8px;
    width: 100%;
}
/* White on --accent would fail AA; --on-accent (near-black) is above 5:1. */
button.primary { color: var(--on-accent); background: var(--accent); border: 2px solid var(--accent); }
button.primary:hover { background: var(--white); border-color: var(--accent-2); color: var(--accent-2); }
button.secondary { color: var(--brand); background: var(--white); border: 2px solid var(--brand); }
button.secondary:hover { background: var(--brand); color: var(--white); }
button:disabled { opacity: .6; cursor: progress; }

.message { min-height: 1.5em; margin: 0 0 12px; font-weight: 600; }
.message.error { color: var(--danger); }
.message.notice { color: var(--brand); }
.message p { margin: 0 0 4px; }
.card .hint { margin: 0 0 12px; color: var(--muted); font-size: .9rem; }

.tiles {
    display: grid;
    gap: 12px;
    margin: 0 0 20px;
    padding: 0;
    list-style: none;
}
.tile {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-height: 64px;
    padding: 14px 16px;
    color: var(--brand);
    background: var(--white);
    border: 2px solid var(--brand);
    border-radius: 8px;
    text-decoration: none;
}
.tile:hover { background: var(--brand); color: var(--white); }
.tile-title { font-size: 1.15rem; font-weight: 700; }
.tile-sub { font-size: .85rem; }

.app-footer { max-width: 640px; margin: 0 auto; padding: 8px 16px 24px; color: var(--muted); font-size: .85rem; }
.app-footer p { margin: 0; }

@media (min-width: 640px) {
    .tiles { grid-template-columns: repeat(2, 1fr); }
    button.primary, button.secondary { width: auto; }
}
