html, body {
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
    background: rgb(21 22 53);
}

a, .btn-link {
    color: #005bbb;
}

    a:hover, .btn-link:hover {
        color: #004a97;
    }

    /* Keep Bootstrap defaults for buttons; page-specific components can theme their own CTAs. */

    .btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
        box-shadow: 0 0 0 0.1rem rgba(255,255,255,0.35), 0 0 0 0.25rem rgba(0, 91, 187, 0.20);
    }

.content {
    padding-top: 1.1rem;
}

h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.register-input,
.forgot-input,
.login-input {
    width: 100%;
    max-width: 400px;
    margin: auto;
    color: white;
    margin-bottom: 10px;
    line-height: 25px;
    border: 1px solid #929292;
    padding: 10px;
    border-radius: 15px;
    background: #232443;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred.";
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

.login-shell {
    min-height: 100vh;
    width: 100%;
    text-align: center;
}

.login-card {
    color: rgba(255, 255, 255, 0.92);
}

.login-header {
    display: grid;
    justify-items: center;
    gap: 0.45rem;
    margin-bottom: 1.1rem;
}

.login-logo {
    width: 350px;
    height: 350px;
}

.login-welcome {
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: rgba(255, 255, 255, 0.86);
}

.login-club {
    font-size: 1.75rem;
    font-weight: 850;
    letter-spacing: 0.01em;
    text-align: center;
    color: #f6c26a;
    text-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.register-form,
.login-form {
    display: grid;
    margin-top: 0.75rem;
    max-width: 400px;
    margin: auto;
}

.register-field,
.login-field {
    position: relative;
}

.forgot-button,
.register-button,
.login-button {
    display: block;
    margin-top: 1rem;
    border-radius: 14px;
    padding: 5px;
    line-height: 45px;
    width: 100%;
    font-weight: 900;
    font-size: 1.15rem;
    background: #eea933;
    color: white;
    margin: auto;
}

.login-forgot {
    margin-top: 0.5rem;
    display: block;
    text-align: center;
    color: rgba(255, 255, 255, 0.86);
    text-decoration: none;
}

    .login-forgot:hover {
        text-decoration: underline;
        color: rgba(255, 255, 255, 0.95);
    }

.login-contact {
    margin-top: 1.1rem;
    text-align: center;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.72);
}

    .login-contact a {
        color: rgba(255, 255, 255, 0.86);
        text-decoration: underline;
    }

:global(.text-danger) {
    color: #ffd1d1 !important;
}

:global(.validation-message) {
    font-size: 0.85rem;
}

.register-shell {
    min-height: 100vh;
    width: 100%;
    text-align: center;
}

.register-card {
    color: rgba(255, 255, 255, 0.92);
}

.register-header {
    display: grid;
    justify-items: center;
    gap: 0.45rem;
    margin-bottom: 1.1rem;
}

.register-logo {
    width: 350px;
    height: 350px;
}

.register-welcome {
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: rgba(255, 255, 255, 0.86);
}

/* Logs table */
.logs-table-wrap {
    width: 100%;
    overflow: auto;
    border: 1px solid rgba(255, 255, 255, 0.10);
    border-radius: 14px;
    background: rgba(35, 36, 67, 0.65);
}

.logs-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.95rem;
}

    .logs-table thead th {
        position: sticky;
        top: 0;
        z-index: 1;
        text-align: left;
        font-weight: 800;
        letter-spacing: 0.01em;
        padding: 0.75rem 0.9rem;
        background: rgba(24, 25, 60, 0.95);
        border-bottom: 1px solid rgba(255, 255, 255, 0.12);
        white-space: nowrap;
    }

    .logs-table tbody td {
        padding: 0.7rem 0.9rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }

    .logs-table tbody td .logs-user-time {
        font-size: 12px;
    }

    .logs-table tbody tr:nth-child(odd) {
        background: rgba(255, 255, 255, 0.03);
    }

    .logs-table tbody tr:hover {
        background: rgba(246, 194, 106, 0.08);
    }

.logs-time {
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
    color: rgba(255, 255, 255, 0.86);
}

.logs-user,
.logs-action {
    white-space: nowrap;
}

.logs-details {
    white-space: pre-wrap;
    word-break: break-word;
    min-width: 280px;
}

.logs-badge {
    display: inline-block;
    padding: 0.18rem 0.55rem;
    border-radius: 999px;
    font-weight: 900;
    letter-spacing: 0.02em;
    font-size: 0.8rem;
    border: 1px solid transparent;
}

    .logs-badge.is-ok {
        background: rgba(38, 176, 80, 0.18);
        border-color: rgba(38, 176, 80, 0.45);
        color: #bdf4cd;
    }

    .logs-badge.is-fail {
        background: rgba(229, 0, 0, 0.16);
        border-color: rgba(229, 0, 0, 0.45);
        color: #ffd1d1;
    }

/* Alarm loops table */
.loops-table-wrap {
    width: 100%;
    overflow: auto;
    border: 1px solid rgba(255, 255, 255, 0.10);
    border-radius: 14px;
    background: rgba(35, 36, 67, 0.65);
}

.loops-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    color: rgba(255, 255, 255, 0.92);
    font-size: 0.95rem;
}

    .loops-table thead th {
        position: sticky;
        top: 0;
        z-index: 1;
        text-align: left;
        font-weight: 800;
        letter-spacing: 0.01em;
        padding: 0.75rem 0.9rem;
        background: rgba(24, 25, 60, 0.95);
        border-bottom: 1px solid rgba(255, 255, 255, 0.12);
        white-space: nowrap;
    }

    .loops-table tbody td {
        padding: 0.7rem 0.9rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        vertical-align: top;
    }

    .loops-table tbody tr:nth-child(odd) {
        background: rgba(255, 255, 255, 0.03);
    }

    .loops-table tbody tr:hover {
        background: rgba(246, 194, 106, 0.08);
    }

.loops-name {
    white-space: nowrap;
    font-weight: 600;
}

.loops-badge {
    display: inline-block;
    padding: 0.18rem 0.55rem;
    border-radius: 999px;
    font-weight: 900;
    letter-spacing: 0.02em;
    font-size: 0.8rem;
    border: 1px solid transparent;
}

    .loops-badge.is-ok {
        background: rgba(38, 176, 80, 0.18);
        border-color: rgba(38, 176, 80, 0.45);
        color: #bdf4cd;
    }

    .loops-badge.is-fail {
        background: rgba(229, 0, 0, 0.16);
        border-color: rgba(229, 0, 0, 0.45);
        color: #ffd1d1;
    }

.forgot-shell {
    min-height: 100vh;
    width: 100%;
    text-align: center;
}

.forgot-card {
    padding: 1.6rem 1.6rem 1.25rem;
    color: rgba(255, 255, 255, 0.92);
}

.forgot-header {
    display: grid;
    justify-items: center;
    gap: 0.45rem;
    margin-bottom: 1.1rem;
}

.forgot-logo {
    width: 350px;
    height: 350px;
}

.forgot-welcome {
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: rgba(255, 255, 255, 0.86);
}

.forgot-club {
    font-size: 1.75rem;
    font-weight: 850;
    letter-spacing: 0.01em;
    text-align: center;
    color: #f6c26a;
    text-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.forgot-form {
    display: grid;
    margin-top: 0.75rem;
    width: 400px;
    margin: auto;
}

.register-secondary,
.forgot-secondary {
    margin-top: 0.5rem;
    display: block;
    text-align: center;
    color: rgba(255, 255, 255, 0.86);
    text-decoration: none;
}

    .register-secondary:hover,
    .forgot-secondary:hover {
        text-decoration: underline;
        color: rgba(255, 255, 255, 0.95);
    }

:global(.text-danger) {
    color: #ffd1d1 !important;
}

:global(.validation-message) {
    font-size: 0.85rem;
}
