:root {
    font-family: Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
    color: #16233a;
    background: #f4f7fc;
    font-synthesis: none;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased
}

* {
    box-sizing: border-box
}

body {
    margin: 0;
    min-width: 280px
}

button, input, select {
    font: inherit
}

button {
    cursor: pointer
}

    button:focus-visible, input:focus-visible, select:focus-visible {
        outline: 3px solid #80b6fc;
        outline-offset: 2px
    }

.shell {
    width: min(100%,660px);
    padding: 26px 16px 20px;
    margin: auto
}

.app-card {
    background: #fff;
    border: 1px solid #e1e7f0;
    box-shadow: 0 16px 48px #1829410c;
    border-radius: 22px;
    padding: 22px
}

.app-header, .brand, .selected-header, .picker-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px
}

.brand {
    justify-content: flex-start
}

.brand-icon {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 13px;
    color: #355c9a;
    background: #eaf2ff;
    font-size: 30px;
    font-weight: 600
}

.app-header h1 {
    margin: 0;
    font-size: 23px;
    letter-spacing: -.6px
}

.app-header p, .app-footer {
    color: #77849a;
    font-size: 12px;
    margin: 3px 0 0
}

.loaded-badge, .status-badge {
    white-space: nowrap;
    font-size: 11px;
    font-weight: 700;
    padding: 7px 10px;
    border-radius: 20px
}

.badge-loaded, .badge-work {
    color: #147b4b;
    background: #e4f7ed
}

.badge-neutral {
    color: #707b8c;
    background: #eef1f5
}

.badge-split {
    color: #9a5810;
    background: #fff1dc
}

.badge-free {
    color: #bd3441;
    background: #ffe8ea
}

.selected-header {
    border-top: 1px solid #edf0f5;
    padding-top: 20px;
    margin-top: 21px;
    margin-bottom: 14px
}

.eyebrow {
    font-size: 10px;
    letter-spacing: .9px;
    font-weight: 800;
    color: #8490a1
}

.selected-header h2 {
    margin: 5px 0 0;
    font-size: 19px;
    letter-spacing: -.4px;
    line-height: 1.25
}

.shift-card {
    background: #f4f7fb;
    border-radius: 16px;
    min-height: 194px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px 12px
}

.day-content {
    width: 100%;
    min-height: 156px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 8px;
    text-align: center
}

.clock-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    white-space: nowrap;
    font-size: 26px;
    font-weight: 750;
    letter-spacing: -.7px;
    font-variant-numeric: tabular-nums
}

.clock-main {
    font-size: 34px
}

.arrow {
    font-size: 21px;
    font-weight: 400;
    color: #9aa9bd
}

.day-content p, .worked {
    margin: 0;
    color: #77849a;
    font-size: 13px
}

.work-summary {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    column-gap: 8px;
    row-gap: 3px;
    color: #77849a;
    font-size: 13px
}

.summary-separator {
    color: #9ba8ba
}

.pause-duration {
    white-space: nowrap
}

.day-heading {
    font-size: 22px;
    font-weight: 750
}

.day-symbol {
    font-size: 29px;
    color: #8b99ad
}

.red {
    color: #d94a56
}

.split-content {
    gap: 7px
}

.shift-number {
    color: #7b899d;
    font-size: 12px
}

.split-entry {
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 2px
}

.worked {
    font-size: 12px;
    padding-top: 3px
}

.picker-heading {
    margin: 23px 0 12px
}

    .picker-heading h3, .upload-heading h3 {
        font-size: 15px;
        margin: 0
    }

.today-button {
    background: #fff;
    border: 1px solid #dbe2ed;
    color: #40516c;
    padding: 9px 13px;
    border-radius: 10px;
    font-weight: 650;
    font-size: 12px
}

    .today-button:hover {
        background: #f4f7fb
    }

.week-days {
    display: grid;
    grid-template-columns: repeat(7,minmax(0,1fr));
    gap: 7px
}

.date-tile {
    border: 1px solid transparent;
    border-radius: 12px;
    background: #f3f6fa;
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 9px;
    padding: 13px 1px 11px;
    min-width: 0;
    color: #263953
}

    .date-tile:hover {
        background: #e9f1fb
    }

    .date-tile.is-selected {
        border: 1.5px solid #83b1ff;
        background: #e9f2ff
    }

.weekday {
    font-size: 11px;
    color: #8a98aa
}

.date-number {
    font-size: 19px;
    font-weight: 750;
    line-height: 1
}

.day-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex: none;
    background: #c7cdd6
}

    .day-dot.work {
        background: #34996c
    }

    .day-dot.split {
        background: #e69c3e
    }

    .day-dot.free {
        background: #df5560
    }

    .day-dot.none {
        background: #c7cdd6
    }

.jump-controls {
    margin: 17px 0 13px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 12px
}

    .jump-controls label {
        font-size: 12px;
        color: #62718a;
        font-weight: 650
    }

    .jump-controls select, .jump-controls input {
        min-width: 0;
        width: 100%;
        background: #fff;
        border: 1px solid #dce3ef;
        border-radius: 10px;
        color: #283b57;
        height: 42px;
        padding: 0 10px
    }

    .jump-controls label:nth-of-type(1) {
        grid-column: 1
    }

    .jump-controls label:nth-of-type(2) {
        grid-column: 2;
        grid-row: 1
    }

.legend {
    display: flex;
    justify-content: center;
    gap: 13px;
    flex-wrap: wrap;
    padding: 10px 0 19px;
    border-bottom: 1px solid #edf0f5
}

    .legend span {
        display: flex;
        align-items: center;
        gap: 5px;
        font-size: 11px;
        color: #7c8999
    }

.upload-area {
    padding-top: 19px
}

.upload-heading p {
    font-size: 12px;
    color: #7b899d;
    margin: 6px 0 13px;
    line-height: 1.5
}

.upload-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 11px;
    border: 1px solid #2b64cb;
    border-radius: 14px;
    background: linear-gradient(135deg,#367ce6 0%,#245dc8 100%);
    box-shadow: 0 6px 16px rgba(40,100,210,.20);
    color: #fff;
    font-size: 14px;
    font-weight: 750;
    padding: 11px 16px;
    cursor: pointer;
    min-height: 54px;
    transition: background .18s,box-shadow .18s,transform .18s
}

    .upload-button:hover {
        background: linear-gradient(135deg,#4388f1 0%,#296bd6 100%);
        box-shadow: 0 8px 20px rgba(40,100,210,.28);
        transform: translateY(-1px)
    }

    .upload-button:active {
        transform: translateY(0)
    }

    .upload-button:focus-within {
        outline: 3px solid #80b6fc;
        outline-offset: 3px
    }

.upload-icon {
    width: 34px;
    height: 34px;
    flex: none;
    display: grid;
    place-items: center;
    border-radius: 0;
    background: transparent;
    border: 0
}

    .upload-icon svg {
        display: block;
        width: 21px;
        height: 21px
    }

.upload-button input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    overflow: hidden
}

.upload-disabled {
    opacity: .65;
    pointer-events: none
}

.file-info {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 11px;
    color: #667791;
    margin-top: 11px
}

    .file-info span:first-child {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        flex: 1
    }

    .file-info span:last-child {
        white-space: nowrap
    }

.privacy-note {
    font-size: 11px;
    color: #8794a5;
    line-height: 1.6;
    margin: 13px 0 0
}

.notice {
    padding: 12px;
    border-radius: 10px;
    margin-top: 17px;
    font-size: 13px;
    line-height: 1.5
}

.notice-ok {
    background: #eaf8ef;
    color: #207346
}

.notice-error {
    background: #fff0f0;
    color: #a83c43
}

.app-footer {
    text-align: center;
    padding: 16px 4px
}

.boot {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 12px
}

    .boot span {
        font-size: 13px;
        color: #748198
    }

.spinner {
    width: 28px;
    height: 28px;
    border: 3px solid #d8e5f8;
    border-top-color: #316dd0;
    border-radius: 50%;
    animation: spin 1s linear infinite
}

@keyframes spin {
    to {
        transform: rotate(360deg)
    }
}

#blazor-error-ui {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff1df;
    padding: 15px;
    font-size: 13px;
    z-index: 999
}

@media(max-width:520px) {
    .shell {
        padding: 0;
        margin: 0;
        width: 100%
    }

    .app-card {
        min-height: 100dvh;
        border: 0;
        border-radius: 0;
        padding: 20px 16px 24px;
        box-shadow: none
    }

    .app-header h1 {
        font-size: 21px
    }

    .brand-icon {
        width: 41px;
        height: 41px
    }

    .selected-header h2 {
        font-size: 17px
    }

    .shift-card {
        min-height: 191px
    }

    .day-content {
        min-height: 153px
    }

    .clock-main {
        font-size: 29px
    }

    .clock-row {
        gap: 9px;
        font-size: 24px
    }

    .date-tile {
        padding: 12px 1px 10px
    }

    .date-number {
        font-size: 17px
    }

    .week-days {
        gap: 5px
    }

    .legend {
        gap: 9px
    }

    .app-footer {
        display: none
    }
}

@media(max-width:350px) {
    .app-card {
        padding: 17px 11px
    }

    .loaded-badge, .status-badge {
        font-size: 10px;
        padding: 6px 7px
    }

    .clock-main {
        font-size: 26px
    }

    .clock-row {
        font-size: 22px;
        gap: 7px
    }

    .date-number {
        font-size: 16px
    }

    .weekday {
        font-size: 10px
    }
}

@media(prefers-color-scheme:dark) {
    :root {
        color: #edf3fd;
        background: #0d1524
    }

    .app-card {
        background: #152136;
        border-color: #2b3950
    }

    .brand-icon, .date-tile.is-selected {
        background: #243e63
    }

    .app-header p, .app-footer, .day-content p, .worked, .work-summary, .eyebrow, .weekday, .legend span, .privacy-note, .upload-heading p {
        color: #a7b6cd
    }

    .selected-header, .legend {
        border-color: #2b3950
    }

    .shift-card, .date-tile {
        background: #202e44
    }

    .date-tile {
        color: #edf3fd
    }

        .date-tile.is-selected {
            border-color: #4d89d9
        }

    .today-button, .jump-controls select, .jump-controls input {
        background: #202e44;
        color: #e6eeff;
        border-color: #41516a
    }

        .today-button:hover, .date-tile:hover {
            background: #2a3c57
        }

    .badge-loaded, .badge-work {
        background: #194d3f;
        color: #9ae7bd
    }

    .badge-free {
        background: #572930;
        color: #ffabb3
    }

    .badge-split {
        background: #513d1d;
        color: #f9d39e
    }

    .badge-neutral {
        background: #344056;
        color: #c1cbd7
    }

    .notice-ok {
        background: #164338;
        color: #c3f9da
    }

    .notice-error {
        background: #53292f;
        color: #ffd6d8
    }
}

@media(prefers-reduced-motion:reduce) {
    .upload-button {
        transition: none
    }

        .upload-button:hover {
            transform: none
        }
}

h1[tabindex="-1"]:focus {
    outline: none;
    box-shadow: none;
}
