/* ==========================================================================
   OfficePoint.Web / wwwroot / app.css
   ========================================================================== */

html, body {
    font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
    margin: 0;
}

h1:focus { outline: none; }

/* -------------------------------------------------------------- wordmark */
.op-mark { display: inline-flex; align-items: center; gap: 10px; }
.op-mark .txt { font-size: 1.35rem; font-weight: 800; letter-spacing: -.4px; }
.op-mark .txt .pt { color: #F47B20; font-style: italic; }

/* ------------------------------------------------------- sign-in pages */
.op-auth-page {
    min-height: 100vh;
    background: #1B3A6B;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    box-sizing: border-box;
}

.op-auth-logo {
    min-width: 104px; max-width: 280px; height: 104px;
    margin: 0 auto 20px;
    background: #fff;
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    overflow: hidden;
    padding: 12px 20px;
    box-sizing: border-box;
}
.op-auth-logo img { max-width: 100%; max-height: 100%; object-fit: contain; }

.op-auth-org {
    color: #fff; font-size: 1.55rem; font-weight: 700;
    text-align: center; margin: 0 0 4px; letter-spacing: -.2px;
}
.op-auth-sys {
    color: rgba(255,255,255,.7); font-size: .8rem; letter-spacing: 2.2px;
    text-align: center; margin: 0 0 30px; text-transform: uppercase;
}

.op-auth-card {
    width: 100%; max-width: 420px;
    background: #fff; color: #0F172A;
    border-radius: 12px;
    padding: 34px 36px;
    box-shadow: 0 6px 28px rgba(0,0,0,.25);
    box-sizing: border-box;
}

.op-h1 { font-size: 1.35rem; font-weight: 700; margin: 0 0 8px; color: #0F172A; }
.op-lead { color: #475569; font-size: .92rem; margin: 0 0 22px; line-height: 1.5; }

.op-field { margin-bottom: 18px; }
.op-field label { display: block; font-size: .85rem; font-weight: 700; color: #1B3A6B; margin-bottom: 7px; }
.op-field input {
    width: 100%; box-sizing: border-box;
    padding: 12px 14px;
    border: 1px solid #CBD5E1; border-radius: 8px;
    font-size: 1rem; color: #0F172A; font-family: inherit;
}
.op-field input:focus, .op-code:focus {
    outline: none; border-color: #F47B20; box-shadow: 0 0 0 3px rgba(244,123,32,.25);
}
.op-field .op-help { color: #475569; font-size: .8rem; margin-top: 5px; }
.op-val, .op-field .validation-message { display: block; color: #B91C1C; font-size: .8rem; margin-top: 5px; }

.op-row {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 22px; font-size: .9rem;
}
.op-row label { display: flex; align-items: center; gap: 8px; color: #334155; }

.op-link { color: #1D4ED8; text-decoration: none; }
.op-link:hover { text-decoration: underline; }
.op-center { text-align: center; margin-top: 16px; font-size: .9rem; }

.op-submit {
    width: 100%; padding: 14px;
    border: 0; border-radius: 8px; cursor: pointer;
    background: #1B3A6B; color: #fff;
    font-size: 1rem; font-weight: 700; font-family: inherit;
}
.op-submit:hover { background: #122848; }
.op-submit:focus-visible { outline: 3px solid #F47B20; outline-offset: 2px; }

.op-secondary {
    padding: 13px 20px; border: 1px solid #CBD5E1; border-radius: 8px;
    background: #fff; color: #1B3A6B; font-size: .95rem; font-weight: 700;
    cursor: pointer; text-decoration: none; display: inline-flex; align-items: center;
}

.op-error, .op-success, .op-info, .op-warn {
    padding: 11px 13px; border-radius: 4px; font-size: .88rem; margin-bottom: 20px; line-height: 1.45;
}
.op-error   { background: #FEE2E2; border-left: 4px solid #DC2626; color: #991B1B; }
.op-success { background: #DCFCE7; border-left: 4px solid #047857; color: #14532D; }
.op-info    { background: #E0F2FE; border-left: 4px solid #0369A1; color: #0C4A6E; }
.op-warn    { background: #FEF3C7; border-left: 4px solid #B45309; color: #78350F; }

.op-code {
    width: 100%; box-sizing: border-box; padding: 14px;
    border: 1px solid #CBD5E1; border-radius: 8px;
    font-size: 1.5rem; letter-spacing: 8px; text-align: center; font-family: inherit;
}
.op-code.recovery { font-family: ui-monospace, Consolas, monospace; font-size: 1.05rem; letter-spacing: 1px; }

.op-qr { display: flex; justify-content: center; margin: 0 0 18px; }
.op-qr img { border: 1px solid #E2E8F0; border-radius: 8px; padding: 10px; background: #fff; }
.op-key, .op-codes {
    background: #F1F5F9; border: 1px solid #E2E8F0; border-radius: 6px; padding: 12px 16px;
    font-family: ui-monospace, Consolas, monospace; letter-spacing: 1px; word-break: break-all; margin: 0 0 18px;
}
.op-codes { line-height: 2.1; font-size: 1.05rem; }
.op-step { font-size: .95rem; font-weight: 700; color: #1B3A6B; margin: 0 0 6px; }
.op-rule { border: 0; border-top: 1px solid #E2E8F0; margin: 22px 0; }

.op-auth-footer { margin-top: 36px; text-align: center; }
.op-auth-by {
    color: rgba(255,255,255,.6); font-size: .72rem; letter-spacing: 2px;
    font-style: italic; text-transform: uppercase; margin-top: 6px;
}

@media print {
    .op-auth-page { background: #fff; padding: 0; min-height: 0; }
    .op-auth-org, .op-auth-sys, .op-auth-footer, .op-auth-logo, .no-print { display: none !important; }
    .op-auth-card { box-shadow: none; padding: 0; }
}

/* -------------------------------------------------------------- app body */
.op-tile { min-width: 190px; }
.op-tile:focus-visible { outline: 3px solid #F47B20; outline-offset: 2px; }

#blazor-error-ui {
    background: #FEF3C7; bottom: 0; box-shadow: 0 -1px 2px rgba(0,0,0,.2);
    display: none; left: 0; padding: .6rem 1.25rem .7rem; position: fixed; width: 100%; z-index: 2000;
}
#blazor-error-ui .dismiss { cursor: pointer; position: absolute; right: .75rem; top: .5rem; }

/* ------------------------------------------------------------- timesheet */
.op-ts { width: 100%; border-collapse: collapse; font-size: .9rem; }
.op-ts th, .op-ts td { padding: 6px 8px; border-bottom: 1px solid var(--mud-palette-table-lines, #E2E8F0); text-align: right; white-space: nowrap; }
.op-ts thead th {
    background: #1B3A6B; color: #fff; font-weight: 600; font-size: .8rem;
    position: sticky; top: 0; z-index: 1;
}
.op-ts .date { text-align: left; min-width: 120px; font-weight: 600; }
.op-ts .date .dow { display: inline-block; width: 34px; color: var(--mud-palette-text-secondary); font-weight: 500; }
.op-ts .sub { font-size: .72rem; font-weight: 500; color: var(--mud-palette-text-secondary); white-space: normal; }
.op-ts .status { text-align: left; }
.op-ts .comment { text-align: left; min-width: 180px; white-space: normal; }
.op-ts .comment input { width: 100%; min-width: 160px; }
.op-ts .tot { font-weight: 700; }
.op-ts .ro { color: var(--mud-palette-text-secondary); }
.op-ts tr.closed td, .op-ts tr.closed th { background: rgba(100,116,139,.10); }
.op-ts tr.holiday td, .op-ts tr.holiday th { background: rgba(244,123,32,.08); }
.op-ts tr.week th, .op-ts tr.week td { background: rgba(27,58,107,.06); font-size: .8rem; font-weight: 600; }
.op-ts tfoot th, .op-ts tfoot td { border-top: 2px solid #1B3A6B; font-weight: 700; background: rgba(27,58,107,.08); }
.op-ts td.short { color: #B45309; }
.op-ts td.long  { color: #0369A1; }
.op-ts tr.clickable { cursor: pointer; }
.op-ts tr.clickable:hover td, .op-ts tr.clickable:hover th { background: rgba(27,58,107,.05); }
.op-ts tr.clickable:focus-visible { outline: 3px solid #F47B20; outline-offset: -3px; }

.op-hrs, .op-ts .comment input {
    box-sizing: border-box; padding: 5px 6px; font: inherit;
    border: 1px solid #CBD5E1; border-radius: 6px; background: var(--mud-palette-surface, #fff); color: inherit;
}
.op-hrs { width: 72px; text-align: right; -moz-appearance: textfield; }
.op-hrs::-webkit-outer-spin-button, .op-hrs::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.op-hrs:focus, .op-ts .comment input:focus { outline: none; border-color: #F47B20; box-shadow: 0 0 0 3px rgba(244,123,32,.25); }
.op-hrs.bad { border-color: #DC2626; background: #FEF2F2; }

.op-bal { width: 100%; border-collapse: collapse; font-size: .88rem; }
.op-bal th, .op-bal td { padding: 4px 4px; text-align: right; }
.op-bal thead th { font-size: .72rem; color: var(--mud-palette-text-secondary); font-weight: 600; }
.op-bal tbody th { text-align: left; font-weight: 600; }
.op-bal tr.over td, .op-bal tr.over th { color: #DC2626; }

/* ---------------------------------------------------------- payroll entry */
.op-ts tr.done td, .op-ts tr.done th { background: rgba(4,120,87,.07); }
.op-ts tr.pending td, .op-ts tr.pending th { background: rgba(250,204,21,.12); }
.op-check { width: 20px; height: 20px; accent-color: #1B3A6B; cursor: pointer; }
.op-check:disabled { cursor: not-allowed; }
