:root {
    --od-side: #1f2a37;
    --od-side-hover: #2b3a4c;
    --od-accent: #b4532a;
    --od-bg: #f4f2ee;
    --od-card: #ffffff;
    --od-ink: #1f2933;
    --od-muted: #6b7280;
    --od-line: #e5e1d8;
}

body {
    background: var(--od-bg);
    color: var(--od-ink);
    font-size: .925rem;
}

a { color: #8a3d1d; }
a:hover { color: var(--od-accent); }

/* ---------- Shell ---------- */
.od-shell { display: flex; min-height: 100vh; }
.od-side {
    width: 230px; flex: 0 0 230px; background: var(--od-side); color: #cbd5e1;
    position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.od-brand { padding: 1.1rem 1.1rem .9rem; border-bottom: 1px solid rgba(255,255,255,.07); }
.od-brand .name { color: #fff; font-weight: 700; letter-spacing: .02em; font-size: 1.05rem; }
.od-brand .org { font-size: .75rem; color: #94a3b8; line-height: 1.2; margin-top: 2px; }
.od-brand .mark {
    display: inline-flex; width: 30px; height: 30px; border-radius: 6px; background: var(--od-accent);
    color: #fff; align-items: center; justify-content: center; margin-right: .5rem; font-size: 1rem;
}
.od-nav { list-style: none; padding: .6rem 0; margin: 0; }
.od-nav .sec { font-size: .68rem; text-transform: uppercase; letter-spacing: .09em; color: #64748b; padding: .9rem 1.1rem .3rem; }
.od-nav a {
    display: flex; align-items: center; gap: .6rem; padding: .45rem 1.1rem; color: #cbd5e1; text-decoration: none;
    border-left: 3px solid transparent;
}
.od-nav a:hover { background: var(--od-side-hover); color: #fff; }
.od-nav a.active { background: var(--od-side-hover); color: #fff; border-left-color: var(--od-accent); }
.od-nav .count { margin-left: auto; font-size: .7rem; }

.od-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.od-top {
    background: #fff; border-bottom: 1px solid var(--od-line); padding: .55rem 1.25rem;
    display: flex; align-items: center; gap: .75rem; position: sticky; top: 0; z-index: 10;
}
.od-top form { flex: 1; max-width: 520px; }
.od-content { padding: 1.25rem; flex: 1; }

@media (min-width: 992px) {
    .od-shell { background: linear-gradient(to right, var(--od-side) 230px, transparent 230px); }
}
@media (max-width: 991px) {
    .od-side { position: fixed; left: -240px; z-index: 1040; transition: left .2s; }
    .od-side.open { left: 0; box-shadow: 0 0 30px rgba(0,0,0,.3); }
}

/* ---------- Page bits ---------- */
.od-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: .75rem; margin-bottom: 1rem; }
.od-head h1 { font-size: 1.35rem; font-weight: 700; margin: 0; }
.od-head .sub { color: var(--od-muted); font-size: .85rem; margin-top: .15rem; }
.od-card { background: var(--od-card); border: 1px solid var(--od-line); border-radius: 8px; }
.od-card > .hd {
    padding: .65rem .9rem; border-bottom: 1px solid var(--od-line); font-weight: 600;
    display: flex; align-items: center; justify-content: space-between; gap: .5rem;
}
.od-card > .bd { padding: .9rem; }
.od-card .table { margin: 0; }
.od-card .table > :not(caption) > * > * { padding: .5rem .75rem; }
.od-card .table thead th { background: #faf8f4; font-weight: 600; color: #4b5563; font-size: .8rem; text-transform: uppercase; letter-spacing: .03em; border-bottom-color: var(--od-line); }

.od-stat { padding: .9rem 1rem; }
.od-stat .num { font-size: 1.6rem; font-weight: 700; line-height: 1.1; }
.od-stat .lbl { color: var(--od-muted); font-size: .8rem; }
.od-stat.warn .num { color: #b45309; }
.od-stat.bad .num { color: #b91c1c; }

.mono { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: .85em; }
.fileno { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-weight: 600; white-space: nowrap; }
.od-filters { display: flex; flex-wrap: wrap; gap: .5rem; align-items: end; }
.od-filters .form-control, .od-filters .form-select { min-width: 140px; }
.dl-grid { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1rem; margin: 0; }
.dl-grid dt { color: var(--od-muted); font-weight: 500; }
.dl-grid dd { margin: 0; }
.pre { white-space: pre-line; }
.help-block, .invalid-feedback { font-size: .8rem; }
.form-label { font-weight: 500; margin-bottom: .25rem; }
.placeholder-chip { cursor: pointer; }
.overdue { color: #b91c1c; font-weight: 600; }
.due-today { color: #b45309; font-weight: 600; }
.grid-view .pagination { margin: 0; }
