/*
 * ============================================================
 * PATH: /software/information-police/assets/app.css
 * ASSET: Information Police — Main Stylesheet
 * VERSION: 001-R12-LAKE-REVEAL-EVIDENCE
 * PURPOSE
 * - Style Microsoft Office Mobile launcher and Workday Rail.
 * - Keep checklist in normal page flow on mobile and desktop.
 * - Provide grayscale print and history dialog styles.
 * DEVELOPMENT RULES
 * - Readable, non-minified CSS and UTF-8 encoding.
 * ============================================================
 */
:root {
    --bg:#071a2b;
    --cyan:#00cfff;
    --green:#67ff66;
    --yellow:#ffe000
}

* {
    box-sizing:border-box
}

body {
    margin:0;
    background:linear-gradient(#061425,#102e49);
    color:#fff;
    font:15px system-ui,-apple-system,Arial,sans-serif
}

header {
    background:#28527b;
    border-bottom:3px solid var(--yellow)
}

.head {
    max-width:1100px;
    margin:auto;
    padding:14px;
    display:flex;
    align-items:center;
    justify-content:space-between
}

.head h1 {
    margin:2px 0;
    font-size:1.6rem
}

.head small {
    color:#d4e5f2
}

.wrap {
    max-width:1100px;
    margin:auto;
    padding:12px
}

.layout {
    display:grid;
    grid-template-columns:minmax(0,1.7fr) minmax(260px,1fr);
    gap:12px
}

.panel {
    background:linear-gradient(#0d2c47,#081d30);
    border:1px solid #3e6f91;
    border-radius:12px;
    padding:16px;
    margin:10px 0;
    min-width:0
}

.panel h2 {
    font-size:1.15rem;
    margin:0 0 12px
}

.tiles {
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(125px,1fr));
    gap:9px
}

.tile {
    background:#103b5c;
    border:1px solid #3c7caa;
    border-radius:10px;
    min-height:110px;
    padding:12px;
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    text-align:center;
    color:white;
    text-decoration:none;
    font-size:1.9rem
}

.tile b {
    font-size:.9rem
}

.tile small {
    font-size:.68rem;
    color:#bed7e9
}

.inactive {
    opacity:.6
}

.muted {
    color:#b8cad9;
    font-size:.8rem
}

label {
    display:block;
    font-weight:700;
    margin:10px 0;
    font-size:.85rem
}

input,select,textarea {
    width:100%;
    padding:10px;
    background:#061827;
    color:#fff;
    border:1px solid #64819a;
    border-radius:7px;
    margin-top:5px;
    font:inherit
}

textarea {
    min-height:85px;
    resize:vertical
}

.two {
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:10px
}

button,.btn {
    display:inline-block;
    cursor:pointer;
    color:#fff;
    font-weight:800;
    text-decoration:none;
    background:linear-gradient(#0d6f9d,#074d74);
    border:1px solid var(--cyan);
    padding:9px 12px;
    border-radius:7px;
    font:inherit
}

.green {
    background:linear-gradient(#199d20,#076d11);
    border-color:var(--green)
}

.actions {
    display:flex;
    gap:8px;
    flex-wrap:wrap;
    margin:9px 0
}

.item {
    background:#081f32;
    border:1px solid #36536a;
    padding:12px;
    border-radius:8px;
    margin:9px 0;
    overflow-wrap:anywhere
}

.item small {
    display:block;
    color:#a9bfd0
}

.item details {
    margin-top:8px
}

.item summary {
    cursor:pointer;
    color:var(--cyan)
}

.pill {
    display:inline-block;
    font-size:.7rem;
    border:1px solid #59758a;
    padding:3px 8px;
    border-radius:99px
}

.side {
    position:sticky;
    top:10px;
    align-self:start;
    max-height:calc(100vh - 20px);
    overflow:auto
}

.check button {
    width:100%;
    text-align:left;
    margin-bottom:5px
}

.login {
    max-width:440px;
    margin:9vh auto
}

.error {
    color:#ffaaaa
}

footer {
    text-align:center;
    color:#b8cad9;
    font-size:.75rem;
    padding:20px
}

@media(max-width:740px) {
    .layout {
    grid-template-columns:1fr
}

.side {
    position:sticky;
    bottom:0;
    top:auto;
    max-height:185px;
    z-index:10;
    box-shadow:0 -8px 25px #0008
}

.two {
    grid-template-columns:1fr
}


}

@media print {
    @page {
    size:letter;
    margin:.5in
}

body {
    background:white!important;
    color:#000!important
}

header,.side,button,form,.tiles,footer {
    display:none!important
}

.layout {
    display:block
}

.panel,.item {
    background:#fff!important;
    color:#000!important;
    border:1px solid #888;
    break-inside:avoid
}

.muted {
    color:#333!important
}


}



/* R03: single column with a non-floating Workday Rail. */
.layout {
    display: block;
}
.main-column {
    width: 100%;
}
.side, .side.expanded, .workday-rail {
    position: static;
    top: auto;
    bottom: auto;
    left: auto;
    right: auto;
    height: auto;
    max-height: none;
    overflow: visible;
    box-shadow: none;
}
.tile-icon {
    font-size: 1.9rem;
}
.app-tile {
    gap: 5px;
}
.app-open {
    width: 100%;
    padding: 7px;
    margin-top: 6px;
    font-size: .8rem;
}
.web-fallback {
    color: #c9edff;
    font-size: .75rem;
}
.checklist {
    display: grid;
    gap: 8px;
}
.check-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    padding: 12px;
    background: #103b5c;
    border: 1px solid #3c7caa;
    border-radius: 8px;
    cursor: pointer;
}
.check-row input {
    width: 23px;
    height: 23px;
    margin: 0;
    flex: none;
    accent-color: #1baf43;
}
.rail-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 12px 0;
}
.rail-actions button {
    flex: 1 1 125px;
}
.success-note {
    color: #9affaa;
    font-weight: 700;
}
#historyDialog {
    background: #0a253c;
    color: white;
    border: 2px solid #438bb3;
    border-radius: 12px;
    padding: 18px;
    width: min(700px, 95vw);
    max-height: 80vh;
    overflow: auto;
}
#historyDialog::backdrop {
    background: #000a;
}
.history-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.history-row {
    padding: 12px 0;
    border-bottom: 1px solid #45637b;
}
.history-row small {
    display: block;
    color: #b8cad9;
    margin-top: 5px;
}
.history-row li {
    margin: 5px 0;
}
@media (max-width: 740px) {
    .tiles {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .wrap {
        padding-bottom: 12px;
    }
}
@media print {
    .rail-actions, #historyDialog, .app-tile {
        display: none !important;
    }
}


/* ============================================================
 * R04 — Numbered history, snapshot loading, and dedicated log.
 * ============================================================ */
.history-header-actions,
.history-entry-heading,
.log-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.history-entry-title {
    flex: 1;
    min-width: 0;
}

.history-number {
    flex: none;
    padding: 7px 9px;
    border: 1px solid #6b9abb;
    border-radius: 7px;
    font-weight: 800;
}

.history-load {
    flex: none;
    background: linear-gradient(#199d20, #076d11);
    border-color: var(--green);
}

.icon-share {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 45px;
    min-height: 43px;
}

.history-footer {
    display: flex;
    justify-content: flex-end;
    padding-top: 18px;
}

.status-list {
    padding-left: 35px;
    list-style: none;
}

.status-list li {
    margin: 7px 0;
}

.status-log-page {
    max-width: 100%;
}

@media (max-width: 740px) {
    .history-top h2 {
        font-size: 1.2rem;
    }

    .history-entry-heading {
        flex-wrap: wrap;
    }

    .log-header {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media print {
    .history-footer,
    .history-header-actions,
    .history-load,
    .log-header .actions {
        display: none !important;
    }
}

/* R05 retained: matching Status History Share and Close button heights. */
.history-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
.history-header-actions button {
    height: 48px;
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* R06: local To Do's modal and in-page navigation. */
#prepared-todos {
    scroll-margin-top: 16px;
}
.local-todos-tile .btn {
    border: 1px solid var(--cyan);
    background: transparent;
    text-align: center;
    text-decoration: none;
}
.local-todos-tile .web-fallback {
    text-decoration: underline;
}
#todosDialog {
    background: #0a253c;
    color: white;
    border: 2px solid #438bb3;
    border-radius: 12px;
    padding: 18px;
    width: min(700px, 95vw);
    max-height: 80vh;
    overflow: auto;
}
#todosDialog::backdrop {
    background: #000a;
}
#todosModalContent .item {
    margin: 10px 0;
}
@media print {
    #todosDialog {
        display: none !important;
    }
}

/* ============================================================
 * R07 — Mobile tint, readable To-Do numbering and inclusion.
 * ============================================================ */
html {
    background-color: #071a2b;
    color-scheme: dark;
}
body {
    background-color: #071a2b;
    background-image: linear-gradient(#061425, #102e49);
}
.panel, .item, form, label {
    min-width: 0;
}
input[type="datetime-local"], .due-input {
    display: block;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
}
.task-heading {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}
.task-heading-content {
    flex: 1;
    min-width: 0;
}
.morning-inclusion {
    display: flex;
    align-items: center;
    gap: 10px;
}
.morning-inclusion input {
    width: 22px;
    height: 22px;
    margin: 0;
    flex: none;
    accent-color: #1baf43;
}
.danger {
    margin-top: 10px;
    border-color: #ee9999;
    background: #722d36;
}
@media print {
    html, body {
        background: #fff !important;
        color: #000 !important;
        color-scheme: light;
    }
}


/* ============================================================
 * R10 — Prepared To-Dos Input Geometry
 * Match the Title and Due outer dimensions on iOS Safari.
 * Keep this rule scoped to the Prepared To-Dos form.
 * ============================================================ */
#prepared-todos input[name="title"],
#prepared-todos input[name="due"] {
    display: block;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    height: 48px;
    min-height: 48px;
    max-height: 48px;
    padding: 0 12px;
    margin-top: 5px;
    box-sizing: border-box;
}

#prepared-todos input[name="due"] {
    -webkit-appearance: none;
    appearance: none;
    font-size: 16px;
}

/* ============================================================
 * R11 — Workday Tools & Resources launcher
 * Preserve R10 field geometry and all prior dialog styles.
 * ============================================================ */
.workday-tiles {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    align-items: stretch;
    gap: 10px;
}
.workday-tool-tile {
    min-width: 0;
    min-height: 235px;
    justify-content: flex-start;
    padding: 12px 9px;
    gap: 6px;
}
.workday-tool-tile .tile-icon {
    font-size: 1.8rem;
    line-height: 1.2;
}
.workday-tool-tile b {
    font-size: .98rem;
}
.workday-tool-tile small {
    overflow-wrap: anywhere;
}
.tool-actions {
    width: 100%;
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
    align-items: stretch;
}
.tool-actions .btn,
.tool-actions button {
    width: 100%;
    margin: 0;
    padding: 8px 5px;
    text-align: center;
    font-size: .8rem;
    font-weight: 700;
    line-height: 1.25;
}
.tool-actions .web-action {
    background: transparent;
    border-color: #6b9abb;
}
.tool-actions .install-action {
    background: linear-gradient(#199d20, #076d11);
    border-color: var(--green);
}
.tool-actions .web-fallback {
    display: block;
    text-align: center;
    padding: 5px;
    text-decoration: underline;
}
.tool-actions .disabled-action {
    cursor: default;
    opacity: .65;
    border-color: #59758a;
    background: #173348;
}
@media (max-width: 740px) {
    .workday-tiles {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .workday-tool-tile {
        min-height: 225px;
    }
}
@media (max-width: 340px) {
    .workday-tool-tile {
        padding: 9px 5px;
    }
    .tool-actions .btn,
    .tool-actions button {
        font-size: .73rem;
    }
}

/* R12 — Lake Reveal, navy visual system */
.lake-item .check-row{display:flex;align-items:center;gap:12px}
.lake-title{flex:1;min-width:0;text-align:left;border:0;background:transparent;color:#fff;padding:5px 0;font-weight:600}
.lake-toggle{flex:none;width:36px;height:36px;padding:0;background:#09283e;border:1px solid #75b5d8;border-radius:7px;display:grid;place-items:center}
.lake-triangle{width:0;height:0;border-top:7px solid transparent;border-bottom:7px solid transparent;border-right:11px solid #8bdcff;transition:transform .2s}
.lake-toggle[aria-expanded="true"] .lake-triangle{transform:rotate(-90deg)}
.lake-reveal{background:#15364f;border:1px solid #3c7caa;border-top:0;border-radius:0 0 10px 10px;padding:15px}
.lake-reveal[hidden]{display:none!important}
.lake-kicker{color:#ffe000;font-size:.75rem}
.lake-notes{background:#0b263b;padding:12px;margin:12px 0;border-radius:8px;overflow-wrap:anywhere}
.lake-upload{background:#0b263b;padding:12px;border:1px dashed #55768e;border-radius:8px}
.lake-upload input{max-width:100%}.lake-upload small{display:block;margin:8px 0}
.lake-attachment{display:block;width:100%;text-align:left;margin:8px 0}
#lakeViewer{background:#15364f;color:#fff;border:2px solid #438bb3;border-radius:12px;width:min(760px,96vw);max-height:90dvh;overflow:auto;padding:15px}
#lakeViewer::backdrop{background:#000c}.lake-viewer-top,#lakeNav{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:8px 0}
#lakeSurface{background:#0b263b;min-height:150px;display:grid;place-items:center;overflow:auto;margin:10px 0}
#lakeSurface canvas,#lakeSurface img{max-width:100%;height:auto}
@media print{.lake-upload,#lakeViewer,.lake-toggle{display:none!important}}

/* ============================================================
 * PATH: /software/morning-stand-up/assets/app.css
 * VERSION: 001-R12.1-CHECKLIST-EDIT-TILE-ALIGNMENT
 * PURPOSE: To-Do-only Edit badge and consistent launcher action baseline.
 * ============================================================ */
.check-row .lake-title { min-width: 0; flex: 1 1 auto; }
.checklist-edit-badge {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 9px;
    border: 1px solid #ffe000;
    border-radius: 2px;
    background: #10283c;
    color: #ffe000;
    font-size: .76rem;
    font-weight: 800;
    line-height: 1.1;
    text-decoration: none;
    white-space: nowrap;
}
.checklist-edit-badge:hover,
.checklist-edit-badge:focus-visible { background: #38401c; color: #ffe000; }
/* Reserve consistent copy height before the bottom-anchored action block. */
.workday-tool-tile > small { min-height: 3em; }
.workday-tool-tile > .tool-actions { margin-top: auto; }
.local-todos-tile .tool-actions { width: 100%; }
.local-todos-tile .tool-actions .web-fallback { margin: 0; }

/* ============================================================
 * PATH: /software/morning-stand-up/assets/app.css
 * VERSION: 001-R13-PRESET-CHECKLIST-MANAGEMENT
 * ============================================================ */
.preset-checklist-item .lake-title{color:#ff65d5!important;font-weight:800}
.user-checklist-item .lake-title{color:#fff!important}
.lake-reveal-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
.lake-reveal-heading .checklist-edit-badge{color:#ffe000!important;border:1px solid #ffe000;border-radius:2px;background:#0b283e;padding:5px 12px;text-decoration:none!important}
.preset-editor{background:#0b263d;border:1px solid #397ca4;border-radius:7px;margin:8px 0;overflow:hidden}
.preset-editor>summary{cursor:pointer;padding:12px;display:flex;align-items:center;gap:12px;font-weight:800;list-style:none}
.preset-editor>summary::-webkit-details-marker{display:none}
.preset-label{flex:1;color:#ff65d5}
.preset-pencil{border:1px solid #ffe000;color:#ffe000;padding:2px 7px;border-radius:2px}
.preset-edit-form{padding:0 12px 12px}
.preset-edit-form textarea{min-height:90px}
.preset-order-actions{padding:0 12px 12px;display:flex;gap:7px;flex-wrap:wrap}
.preset-order-actions button{flex:1 1 auto}
.preset-order-actions button:disabled{opacity:.45}
.preset-add>summary{color:#fff;justify-content:center;background:#075780}
.workday-tool-tile>.tool-actions{width:100%;margin-top:auto;display:flex;flex-direction:column;align-items:stretch;gap:6px}
.workday-tool-tile .tool-actions>.btn{width:100%;min-height:36px;display:flex;align-items:center;justify-content:center;margin:0;line-height:1.2}
.workday-tool-tile .tool-actions>.tool-info{cursor:default;color:#c3d9e8;font-size:.75rem}
