/* ─────────────────────────────────────────────────────────────────────────
 * motuzko brand — minimalist restyle of the Skoruba STS Identity UI.
 * Loaded as `AdminConfiguration:CustomThemeCss` so it lands AFTER the
 * upstream `web.min.css` and Bootswatch theme.
 * ──────────────────────────────────────────────────────────────────────── */

:root {
    --bg:           #fafaf9;
    --surface:      #ffffff;
    --ink:          #18181b;
    --ink-muted:    #71717a;
    --border:       #e4e4e7;
    --accent:       #ea580c;     /* fox-orange */
    --accent-hover: #c2410c;
    --accent-soft:  rgba(234, 88, 12, 0.12);
    --danger:       #dc2626;
    --radius:       0.5rem;
}

/* base */
html, body {
    background: var(--bg) !important;
    color: var(--ink);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; }

/* hide upstream chrome we don't want */
.menu-button, .menu .dropdown { display: none !important; }

/* header (replaces upstream `.menu` block) */
.brand-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 2rem;
    border-bottom: 1px solid var(--border);
    background: var(--surface);
}
.brand-header .brand {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--ink);
    text-decoration: none;
}
.brand-header .brand:hover { text-decoration: none; }
.brand-header .brand img {
    height: 32px;
    width: 32px;
    color: var(--ink);
}
.brand-header .brand-name {
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: 0.01em;
}
.brand-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
    font-size: 0.9rem;
    color: var(--ink-muted);
}
.brand-actions .btn-text {
    color: var(--ink-muted);
    text-decoration: none;
    padding: 0.35rem 0.75rem;
    border-radius: var(--radius);
}
.brand-actions .btn-text:hover { color: var(--accent); background: var(--accent-soft); }

/* main column — keep Bootstrap's default container width on most pages
 * (Home/Manage cards need it). Only the login page narrows the column. */

/* home page hero — Skoruba's Index.cshtml has <img class="img-fluid"> with
 * no max-width, so the SVG stretches to fill the column. Cap it. */
.welcome-block {
    margin: 2rem auto 2.5rem;
}
.welcome-block img {
    max-width: 120px;
    height: auto;
    display: block;
    margin: 0 auto 1rem;
}
.welcome-block h1 {
    font-size: 2rem;
    font-weight: 600;
    margin: 0 0 0.5rem;
}
.welcome-block .lead {
    color: var(--ink-muted);
    font-size: 1rem;
    font-weight: 400;
}

/* login page — centered narrow column with hero */
.login-page {
    max-width: 460px;
    margin: 4rem auto 6rem;
    padding: 0 1.5rem;
    text-align: center;
}
.login-hero {
    margin: 0 auto 1.25rem;
    color: var(--ink);
    width: 140px;
    height: 140px;
}
.login-page h1 {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0 0 0.25rem;
    letter-spacing: 0.01em;
}
.login-page .tagline {
    color: var(--ink-muted);
    margin: 0 0 2rem;
    font-size: 0.95rem;
}

/* forms */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    text-align: left;
    margin-top: 1.5rem;
}
.field { display: flex; flex-direction: column; gap: 0.35rem; }
.field label, .field-inline label {
    font-size: 0.8rem;
    color: var(--ink-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.field input[type="text"],
.field input[type="email"],
.field input[type="password"],
.field input:not([type]) {
    background: var(--surface);
    color: var(--ink);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.65rem 0.85rem;
    font: inherit;
    transition: border-color 0.15s, box-shadow 0.15s;
    width: 100%;
}
.field input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}
.field-inline {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--ink-muted);
    font-size: 0.9rem;
    text-transform: none;
    letter-spacing: 0;
}
.field-inline label { text-transform: none; letter-spacing: 0; font-size: 0.9rem; }
.actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.4rem;
}

/* buttons */
.btn {
    display: inline-block;
    padding: 0.6rem 1.4rem;
    border: 0;
    border-radius: var(--radius);
    font: inherit;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
    line-height: 1.3;
}
.btn-primary { background: var(--accent); color: white; }
.btn-primary:hover { background: var(--accent-hover); color: white; text-decoration: none; }
.btn-outline {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--border);
}
.btn-outline:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }
.btn-secondary {
    background: transparent;
    color: var(--ink-muted);
    border: 1px solid var(--border);
}
.btn-secondary:hover { color: var(--ink); border-color: var(--ink-muted); text-decoration: none; }
.btn-link {
    color: var(--ink-muted);
    text-decoration: none;
    font-size: 0.9rem;
    padding: 0.6rem 0;
}
.btn-link:hover { color: var(--accent); text-decoration: underline; }

/* sign-in provider list (Google / Microsoft / email) — single stacked
 * column, each row is a full-width button with brand icon + label. The
 * email button reveals the username/password form via a small inline
 * script in Login.cshtml. */
.provider-list {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin: 1.75rem 0 1rem;
}
.provider-btn {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.7rem 1rem;
    width: 100%;
    background: var(--surface);
    color: var(--ink);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font: inherit;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    text-align: left;
    transition: border-color 0.15s, background 0.15s, transform 0.05s;
}
.provider-btn:hover {
    border-color: var(--ink);
    background: var(--bg);
    color: var(--ink);
    text-decoration: none;
}
.provider-btn:active { transform: translateY(1px); }
.provider-btn:focus-visible {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}
.provider-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}
.provider-icon svg { width: 100%; height: 100%; }
.provider-label { flex: 1; }

/* the email button uses a muted icon color so brand icons (Google,
 * Microsoft) stay the visual focus when present */
.provider-email .provider-icon { color: var(--ink-muted); }

/* form reveal — `hidden` attribute already hides; on reveal we add
 * a top margin so it visually separates from the buttons */
.login-form:not([hidden]) { margin-top: 1rem; }

/* alerts */
.alert {
    background: rgba(220, 38, 38, 0.05);
    border: 1px solid rgba(220, 38, 38, 0.25);
    color: var(--danger);
    padding: 0.75rem 1rem;
    border-radius: var(--radius);
    margin-bottom: 1rem;
    text-align: left;
}
.validation-summary-errors,
.validation-summary-errors ul {
    color: var(--danger);
    list-style: none;
    padding-left: 0;
    margin: 0 0 1rem;
}

/* footer */
.brand-footer {
    text-align: center;
    color: var(--ink-muted);
    padding: 1.5rem;
    font-size: 0.85rem;
    border-top: 1px solid var(--border);
    margin-top: 4rem;
}

/* responsive */
@media (max-width: 540px) {
    .brand-header { padding: 0.85rem 1.25rem; }
    .login-page { margin: 2.5rem auto 3rem; }
    .login-hero { width: 110px; height: 110px; }
    .actions { flex-direction: column; align-items: stretch; }
    .actions .btn { text-align: center; }
}
