:root {
    --ink: #171715;
    --muted: #74736d;
    --line: #d8d5cc;
    --soft-line: #e8e5dd;
    --paper: #f3f0e9;
    --surface: #ffffff;
    --surface-soft: #f8f6f1;
    --accent: #9d8e70;
    --success: #58715f;
    --danger: #9a4d43;
    --warning: #9a7745;
    --sidebar-width: 290px;
    --radius: 2px;
    --shadow: 0 18px 50px rgba(23, 23, 21, 0.08);
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    background: var(--paper);
    color: var(--ink);
    font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

body {
    min-height: 100vh;
    margin: 0;
}

button,
input {
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
}

h1,
h2,
p {
    margin-top: 0;
}

h1,
h2 {
    font-family: Georgia, "Times New Roman", serif;
    font-weight: 400;
    letter-spacing: -0.035em;
}

code {
    padding: 2px 5px;
    background: #efede7;
    border-radius: 2px;
    font-size: 0.9em;
}

.eyebrow,
.section-number,
.nav-label,
.preview-label {
    margin: 0;
    color: var(--muted);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    line-height: 1.4;
    text-transform: uppercase;
}

/* Login */
.login-page {
    background:
        linear-gradient(90deg, rgba(23, 23, 21, 0.028) 1px, transparent 1px) 0 0 / 9vw 100%,
        var(--paper);
}

.login-shell {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(420px, 0.8fr);
    min-height: 100vh;
}

.login-brand {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(48px, 8vw, 120px);
    border-right: 1px solid var(--line);
}

.brand-frame {
    background: transparent;
}

.brand-frame--large {
    width: min(420px, 70vw);
    margin-bottom: 52px;
}

.brand-frame--large img {
    display: block;
    width: 100%;
    height: auto;
    background: transparent;
    object-fit: contain;
}

.login-brand h1 {
    max-width: 680px;
    margin: 10px 0 18px;
    font-size: clamp(4rem, 8vw, 8rem);
    line-height: 0.92;
}

.login-intro {
    max-width: 500px;
    margin-bottom: 0;
    color: var(--muted);
    font-size: 1rem;
    line-height: 1.7;
}

.login-panel {
    display: grid;
    place-items: center;
    padding: clamp(28px, 6vw, 80px);
    background: rgba(255, 255, 255, 0.58);
}

.login-card {
    width: min(100%, 450px);
}

.login-card h2 {
    margin: 14px 0 34px;
    font-size: clamp(2.8rem, 4vw, 4.5rem);
}

.form-stack {
    display: grid;
    gap: 22px;
}

.field {
    display: grid;
    gap: 9px;
}

.field-label {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.field-input {
    width: 100%;
    min-height: 52px;
    padding: 14px 0;
    border: 0;
    border-bottom: 1px solid var(--ink);
    outline: none;
    background: transparent;
    color: var(--ink);
    transition: border-color 160ms ease, box-shadow 160ms ease;
}

.field-input:focus {
    border-color: var(--accent);
    box-shadow: 0 1px 0 var(--accent);
}

.field-error {
    margin: 0;
    color: var(--danger);
    font-size: 0.78rem;
}

.password-field {
    position: relative;
}

.password-field .field-input {
    padding-right: 95px;
}

.password-toggle {
    position: absolute;
    right: 0;
    bottom: 16px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--muted);
    cursor: pointer;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.checkbox-row {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--muted);
    cursor: pointer;
    font-size: 0.88rem;
}

.checkbox-row input {
    width: 16px;
    height: 16px;
    accent-color: var(--ink);
}

.button {
    min-height: 52px;
    padding: 14px 22px;
    border: 1px solid transparent;
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    transition: transform 150ms ease, background 150ms ease;
}

.button:hover {
    transform: translateY(-1px);
}

.button--primary {
    background: var(--ink);
    color: #fff;
}

.button--primary:hover {
    background: #2b2b28;
}

.button--full {
    width: 100%;
}

.flash-stack {
    display: grid;
    gap: 8px;
    margin-bottom: 22px;
}

.flash {
    padding: 13px 15px;
    border-left: 3px solid var(--ink);
    background: var(--surface);
    color: var(--ink);
    font-size: 0.88rem;
    line-height: 1.5;
}

.flash--error {
    border-color: var(--danger);
}

.flash--success {
    border-color: var(--success);
}

.flash--warning {
    border-color: var(--warning);
}

/* Admin */
.admin-page {
    background: var(--paper);
}

.admin-shell {
    display: grid;
    grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
    min-height: 100vh;
}

.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 50;
    display: flex;
    width: var(--sidebar-width);
    flex-direction: column;
    border-right: 1px solid var(--line);
    background: #fcfbf8;
}

.sidebar-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 30px 28px 18px;
}

.sidebar-brand {
    display: block;
    width: 150px;
}

.sidebar-brand img {
    display: block;
    width: 100%;
    height: auto;
    background: transparent;
    object-fit: contain;
}

.sidebar-brand span {
    display: block;
    margin-top: 10px;
    color: var(--muted);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-align: center;
    text-transform: uppercase;
}

.sidebar-close {
    display: none;
    border: 0;
    background: transparent;
    cursor: pointer;
    font-size: 2rem;
    font-weight: 200;
}

.sidebar-nav {
    flex: 1;
    overflow-y: auto;
    padding: 12px 18px 26px;
}

.nav-label {
    padding: 18px 12px 8px;
}

.nav-item {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) auto;
    align-items: center;
    min-height: 46px;
    margin: 2px 0;
    padding: 10px 12px;
    border-left: 2px solid transparent;
    color: #4f4e49;
    font-size: 0.87rem;
    gap: 10px;
}

.nav-item:hover:not(.is-disabled),
.nav-item.is-active {
    border-color: var(--ink);
    background: #f0eee8;
    color: var(--ink);
}

.nav-item.is-disabled {
    color: #aaa79f;
    cursor: not-allowed;
}

.nav-item small {
    color: #aaa79f;
    font-size: 0.62rem;
    font-weight: 700;
}

.nav-icon {
    color: #96938c;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 0.73rem;
}

.sidebar-footer {
    display: grid;
    gap: 16px;
    padding: 22px 28px 28px;
    border-top: 1px solid var(--soft-line);
}

.user-mini {
    display: flex;
    align-items: center;
    min-width: 0;
    gap: 12px;
}

.user-avatar {
    display: grid;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    font-family: Georgia, "Times New Roman", serif;
}

.user-mini > span:last-child {
    min-width: 0;
}

.user-mini strong,
.user-mini small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-mini strong {
    font-size: 0.8rem;
}

.user-mini small {
    margin-top: 3px;
    color: var(--muted);
    font-size: 0.68rem;
}

.text-button {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--muted);
    cursor: pointer;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.admin-main {
    grid-column: 2;
    min-width: 0;
}

.admin-topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    min-height: 84px;
    align-items: center;
    padding: 14px clamp(22px, 4vw, 54px);
    border-bottom: 1px solid var(--line);
    background: rgba(243, 240, 233, 0.91);
    backdrop-filter: blur(16px);
    gap: 16px;
}

.topbar-title {
    margin: 3px 0 0;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.1rem;
}

.phase-badge {
    margin-left: auto;
    padding: 7px 10px;
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.menu-button {
    display: none;
    width: 38px;
    height: 38px;
    padding: 9px;
    border: 1px solid var(--line);
    background: transparent;
    cursor: pointer;
}

.menu-button span {
    display: block;
    width: 100%;
    height: 1px;
    margin: 5px 0;
    background: var(--ink);
}

.admin-content {
    width: min(1600px, 100%);
    margin: 0 auto;
    padding: clamp(28px, 4.5vw, 70px) clamp(22px, 4vw, 54px) 80px;
}

.page-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 42px;
    gap: 30px;
}

.page-heading h1 {
    margin: 12px 0 14px;
    font-size: clamp(3rem, 6vw, 6rem);
    line-height: 0.95;
}

.page-heading p:last-child {
    max-width: 720px;
    margin-bottom: 0;
    color: var(--muted);
    line-height: 1.7;
}

.status-pill {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    padding: 8px 10px;
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    gap: 7px;
}

.status-pill i {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
}

.status-pill--ready {
    color: var(--success);
}

.metric-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-bottom: 24px;
    border-top: 1px solid var(--line);
    border-left: 1px solid var(--line);
}

.metric-card {
    position: relative;
    min-height: 220px;
    padding: 24px;
    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.58);
}

.metric-index {
    position: absolute;
    top: 20px;
    right: 20px;
    color: #aaa79f;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 0.72rem;
}

.metric-card p {
    margin: 0;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.metric-card strong {
    display: block;
    margin: 34px 0 24px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 4.5rem;
    font-weight: 400;
    line-height: 1;
}

.metric-card small {
    color: var(--muted);
    line-height: 1.5;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(300px, 0.7fr);
    gap: 24px;
}

.panel {
    min-width: 0;
    padding: clamp(24px, 3vw, 38px);
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.62);
}

.panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 32px;
    gap: 20px;
}

.panel-head h2 {
    margin: 8px 0 0;
    font-size: 2.5rem;
}

.check-list {
    border-top: 1px solid var(--line);
}

.check-row {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    padding: 20px 0;
    border-bottom: 1px solid var(--soft-line);
    gap: 14px;
}

.check-row > span {
    color: var(--success);
    font-size: 1rem;
}

.check-row strong,
.check-row small {
    display: block;
}

.check-row strong {
    margin-bottom: 6px;
    font-size: 0.9rem;
}

.check-row small {
    color: var(--muted);
    line-height: 1.5;
}

.empty-state {
    text-align: center;
}

.empty-state--compact {
    padding: 24px 4px 6px;
}

.empty-mark {
    display: grid;
    width: 52px;
    height: 52px;
    margin: 0 auto 18px;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.4rem;
}

.empty-state strong {
    display: block;
    margin-bottom: 8px;
}

.empty-state p,
.empty-state small {
    color: var(--muted);
    line-height: 1.6;
}

.sidebar-backdrop {
    display: none;
}

/* Public */
.public-page {
    background:
        linear-gradient(90deg, rgba(23, 23, 21, 0.025) 1px, transparent 1px) 0 0 / 25vw 100%,
        var(--paper);
}

.public-shell {
    width: min(100%, 900px);
    min-height: 100vh;
    margin: 0 auto;
    padding: 0 clamp(18px, 5vw, 58px);
}

.public-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    padding: 32px 0 26px;
    border-bottom: 1px solid var(--ink);
    gap: 24px;
}

.public-logo {
    width: 160px;
    padding: 0;
    background: transparent;
}

.public-logo img {
    display: block;
    width: 100%;
    height: auto;
    background: transparent;
    object-fit: contain;
}

.public-header h1 {
    margin: 6px 0 0;
    font-size: clamp(2rem, 7vw, 4rem);
    text-align: right;
}

.date-navigator {
    display: grid;
    grid-template-columns: 50px minmax(0, 1fr) 50px;
    align-items: center;
    margin-top: 24px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.64);
}

.date-navigator button {
    align-self: stretch;
    border: 0;
    background: transparent;
    color: #aaa79f;
    font-size: 1.25rem;
}

.date-navigator button:first-child {
    border-right: 1px solid var(--line);
}

.date-navigator button:last-child {
    border-left: 1px solid var(--line);
}

.date-navigator div {
    padding: 16px;
    text-align: center;
}

.date-navigator span,
.date-navigator strong {
    display: block;
}

.date-navigator span {
    margin-bottom: 4px;
    color: var(--muted);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.date-navigator strong {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1rem;
    font-weight: 400;
}

.public-empty {
    padding: clamp(50px, 10vw, 100px) 0;
}

.public-empty h2 {
    margin: 10px 0 18px;
    font-size: clamp(3rem, 9vw, 6rem);
    line-height: 0.95;
}

.public-empty > p {
    max-width: 680px;
    color: var(--muted);
    line-height: 1.75;
}

.preview-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    margin-top: 42px;
    padding: 24px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.68);
    gap: 20px;
}

.preview-card strong {
    display: block;
    margin-top: 8px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 2.5rem;
    font-weight: 400;
}

.preview-status {
    align-self: start;
    padding: 7px 9px;
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.preview-card dl {
    display: grid;
    grid-column: 1 / -1;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin: 8px 0 0;
    border-top: 1px solid var(--line);
}

.preview-card dl div {
    padding: 20px 16px 0 0;
}

.preview-card dt {
    color: var(--muted);
    font-size: 0.72rem;
}

.preview-card dd {
    margin: 8px 0 0;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 2rem;
}

.public-footer {
    display: flex;
    justify-content: space-between;
    padding: 26px 0 34px;
    border-top: 1px solid var(--ink);
    color: var(--muted);
    font-size: 0.64rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    gap: 20px;
}

@media (max-width: 1100px) {
    .login-shell {
        grid-template-columns: 1fr 440px;
    }

    .metric-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 820px) {
    :root {
        --sidebar-width: min(88vw, 320px);
    }

    .login-shell {
        display: block;
    }

    .login-brand {
        min-height: 44vh;
        padding: 36px 26px 46px;
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .brand-frame--large {
        width: 230px;
        margin-bottom: 40px;
    }

    .login-brand h1 {
        font-size: clamp(3.7rem, 18vw, 6rem);
    }

    .login-panel {
        min-height: 56vh;
        padding: 42px 26px 60px;
    }

    .admin-shell {
        display: block;
    }

    .sidebar {
        transform: translateX(-105%);
        box-shadow: var(--shadow);
        transition: transform 220ms ease;
    }

    .sidebar-close,
    .menu-button {
        display: block;
    }

    .sidebar-backdrop {
        position: fixed;
        inset: 0;
        z-index: 40;
        display: block;
        visibility: hidden;
        background: rgba(23, 23, 21, 0.42);
        opacity: 0;
        transition: opacity 220ms ease, visibility 220ms ease;
    }

    .sidebar-is-open {
        overflow: hidden;
    }

    .sidebar-is-open .sidebar {
        transform: translateX(0);
    }

    .sidebar-is-open .sidebar-backdrop {
        visibility: visible;
        opacity: 1;
    }

    .admin-main {
        min-height: 100vh;
    }

    .page-heading {
        display: block;
    }

    .page-heading .status-pill {
        margin-top: 24px;
    }

    .public-header {
        align-items: flex-start;
    }

    .public-logo {
        width: 120px;
    }
}

@media (max-width: 560px) {
    .admin-topbar {
        min-height: 72px;
        padding-inline: 16px;
    }

    .admin-topbar .eyebrow {
        display: none;
    }

    .admin-content {
        padding: 30px 16px 58px;
    }

    .page-heading h1 {
        font-size: 3.1rem;
    }

    .metric-grid {
        grid-template-columns: 1fr;
    }

    .metric-card {
        min-height: 170px;
    }

    .metric-card strong {
        margin: 24px 0 16px;
        font-size: 3.7rem;
    }

    .panel {
        padding: 22px 18px;
    }

    .panel-head {
        display: block;
    }

    .panel-head .status-pill {
        margin-top: 18px;
    }

    .public-shell {
        padding-inline: 14px;
    }

    .public-header {
        display: block;
        padding-top: 22px;
    }

    .public-logo {
        width: 130px;
        margin-bottom: 28px;
    }

    .public-header h1 {
        text-align: left;
    }

    .date-navigator {
        grid-template-columns: 44px minmax(0, 1fr) 44px;
    }

    .public-empty {
        padding: 50px 0 70px;
    }

    .public-empty h2 {
        font-size: 3.5rem;
    }

    .preview-card dl {
        grid-template-columns: 1fr 1fr;
    }

    .preview-card dl div:last-child {
        grid-column: 1 / -1;
    }

    .public-footer {
        display: grid;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}

.error-shell {
    display: flex;
    width: min(680px, calc(100% - 36px));
    min-height: 100vh;
    margin: 0 auto;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.error-shell img {
    width: 190px;
    margin-bottom: 54px;
    background: #fff;
}

.error-shell h1 {
    margin: 14px 0 18px;
    font-size: clamp(3rem, 9vw, 6rem);
    line-height: 0.95;
}

.error-shell > p:last-child {
    color: var(--muted);
    line-height: 1.7;
}

/* Phase 2 · Imports and reservation snapshots */
.button--secondary {
    border-color: var(--ink);
    background: transparent;
    color: var(--ink);
}

.button--secondary:hover,
.button--ghost:hover {
    background: var(--surface-soft);
}

.button--ghost {
    border-color: var(--line);
    background: transparent;
    color: var(--muted);
}

.panel-actions,
.sticky-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-top: 26px;
}

.snapshot-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border-top: 1px solid var(--soft-line);
    border-left: 1px solid var(--soft-line);
}

.snapshot-summary > div {
    display: grid;
    gap: 8px;
    min-height: 94px;
    padding: 20px;
    border-right: 1px solid var(--soft-line);
    border-bottom: 1px solid var(--soft-line);
}

.snapshot-summary span,
.filter-form label > span {
    color: var(--muted);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.snapshot-summary strong {
    overflow-wrap: anywhere;
    font-size: 0.95rem;
}

.status-pill--warning i {
    background: var(--warning);
}

.status-pill--danger i {
    background: var(--danger);
}

.dashboard-grid--imports {
    grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
}

.import-panel {
    min-height: 100%;
}

.file-badge {
    padding: 7px 10px;
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.upload-form {
    display: grid;
    gap: 18px;
}

.upload-dropzone {
    display: grid;
    min-height: 240px;
    place-items: center;
    align-content: center;
    gap: 10px;
    padding: 30px;
    border: 1px dashed #aaa494;
    background: var(--surface-soft);
    cursor: pointer;
    text-align: center;
    transition: border-color 160ms ease, background 160ms ease;
}

.upload-dropzone:hover,
.upload-dropzone:focus-within {
    border-color: var(--ink);
    background: #f1eee7;
}

.upload-dropzone input[type="file"] {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

.upload-symbol {
    display: grid;
    width: 48px;
    height: 48px;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    font-size: 1.5rem;
    font-weight: 300;
}

.upload-dropzone strong {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.7rem;
    font-weight: 400;
}

.upload-dropzone small,
.muted-copy {
    color: var(--muted);
    line-height: 1.6;
}

.privacy-note {
    padding: 14px 16px;
    border-left: 2px solid var(--accent);
    background: #f7f4ed;
    color: var(--muted);
    font-size: 0.83rem;
    line-height: 1.55;
}

.privacy-note strong {
    color: var(--ink);
}

.required-columns {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin: 8px 0 22px;
}

.required-columns span {
    padding: 9px 12px;
    border: 1px solid var(--line);
    background: var(--surface-soft);
    font-size: 0.78rem;
    font-weight: 700;
}

.history-panel {
    margin-top: 24px;
}

.table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--soft-line);
}

.data-table {
    width: 100%;
    min-width: 840px;
    border-collapse: collapse;
    background: var(--surface);
    font-size: 0.84rem;
}

.data-table th,
.data-table td {
    padding: 15px 16px;
    border-bottom: 1px solid var(--soft-line);
    text-align: left;
    vertical-align: middle;
    white-space: nowrap;
}

.data-table th {
    background: var(--surface-soft);
    color: var(--muted);
    font-size: 0.67rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.data-table td small {
    display: block;
    margin-top: 4px;
    color: var(--muted);
}

.data-table tbody tr:last-child td {
    border-bottom: 0;
}

.data-table tbody tr:hover td {
    background: #fbfaf7;
}

.table-link {
    border-bottom: 1px solid var(--ink);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.batch-status,
.issue-count {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 9px;
    border: 1px solid var(--line);
    font-size: 0.67rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.batch-status--active,
.issue-count--ok {
    border-color: rgba(88, 113, 95, 0.35);
    background: rgba(88, 113, 95, 0.08);
    color: var(--success);
}

.batch-status--preview,
.issue-count--warning {
    border-color: rgba(154, 119, 69, 0.35);
    background: rgba(154, 119, 69, 0.08);
    color: var(--warning);
}

.batch-status--failed,
.issue-count--error {
    border-color: rgba(154, 77, 67, 0.35);
    background: rgba(154, 77, 67, 0.08);
    color: var(--danger);
}

.batch-status--archived {
    background: var(--surface-soft);
    color: var(--muted);
}

.metric-grid--six {
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

.metric-grid--six .metric-card {
    min-width: 0;
}

.issue-list {
    display: grid;
    gap: 10px;
}

.issue-row {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 14px;
    padding: 16px;
    border: 1px solid var(--soft-line);
    background: var(--surface-soft);
}

.issue-row > span {
    display: grid;
    width: 30px;
    height: 30px;
    place-items: center;
    border-radius: 50%;
    font-weight: 700;
}

.issue-row--error > span {
    background: rgba(154, 77, 67, 0.12);
    color: var(--danger);
}

.issue-row--warning > span {
    background: rgba(154, 119, 69, 0.12);
    color: var(--warning);
}

.issue-row p {
    margin: 5px 0 0;
    color: var(--muted);
    line-height: 1.5;
}

.cancelled-panel {
    margin-top: 24px;
}

.cancelled-panel summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    cursor: pointer;
    list-style: none;
}

.cancelled-panel summary::-webkit-details-marker {
    display: none;
}

.cancelled-panel summary > span:first-child {
    display: grid;
    gap: 7px;
}

.cancelled-panel[open] summary {
    margin-bottom: 22px;
}

.row-cancelled td {
    color: var(--muted);
    text-decoration: line-through;
    opacity: 0.72;
}

.sticky-actions {
    position: sticky;
    bottom: 18px;
    z-index: 4;
    justify-content: flex-end;
    padding: 16px;
    border: 1px solid var(--line);
    background: rgba(243, 240, 233, 0.94);
    backdrop-filter: blur(12px);
    box-shadow: var(--shadow);
}

.filter-panel {
    margin-bottom: 24px;
}

.filter-form {
    display: grid;
    grid-template-columns: minmax(180px, 0.7fr) minmax(220px, 1fr) auto auto;
    gap: 14px;
    align-items: end;
}

.filter-form label {
    display: grid;
    gap: 8px;
}

.filter-form input,
.filter-form select {
    width: 100%;
    min-height: 48px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 0;
    outline: none;
    background: var(--surface);
    color: var(--ink);
    font: inherit;
}

.filter-form input:focus,
.filter-form select:focus {
    border-color: var(--ink);
}

@media (max-width: 1280px) {
    .metric-grid--six {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .dashboard-grid--imports {
        grid-template-columns: 1fr;
    }

    .snapshot-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .filter-form {
        grid-template-columns: 1fr 1fr;
    }

    .filter-form .button {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .metric-grid--six,
    .snapshot-summary,
    .filter-form {
        grid-template-columns: 1fr;
    }

    .upload-dropzone {
        min-height: 200px;
        padding: 24px 18px;
    }

    .sticky-actions {
        bottom: 8px;
        justify-content: stretch;
    }

    .sticky-actions > *,
    .sticky-actions form,
    .sticky-actions .button {
        width: 100%;
    }
}

/* Phase 3 · Daily public housekeeping view */
.hk-shell {
    width: min(100%, 1040px);
    padding-bottom: 20px;
}

.hk-header {
    align-items: center;
}

.hk-logo img {
    display: block;
    width: 100%;
    height: auto;
}

.hk-header-copy {
    text-align: right;
}

.hk-date-navigator {
    grid-template-columns: 58px minmax(0, 1fr) 58px;
    overflow: hidden;
}

.hk-date-navigator > a {
    display: grid;
    min-height: 100%;
    place-items: center;
    color: var(--ink);
    font-size: 1.35rem;
    transition: background 150ms ease;
}

.hk-date-navigator > a:first-child {
    border-right: 1px solid var(--line);
}

.hk-date-navigator > a:last-child {
    border-left: 1px solid var(--line);
}

.hk-date-navigator > a:hover,
.hk-date-navigator > a:focus-visible {
    background: var(--surface-soft);
}

.hk-date-navigator > div {
    padding: 14px 16px 12px;
}

.hk-date-navigator strong {
    font-size: clamp(1rem, 3vw, 1.25rem);
}

.hk-date-toggle {
    margin-top: 8px;
    padding: 0;
    border: 0;
    border-bottom: 1px solid var(--muted);
    background: transparent;
    color: var(--muted);
    cursor: pointer;
    font-size: 0.7rem;
}

.hk-date-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    width: min(100%, 360px);
    margin: 12px auto 2px;
    gap: 8px;
}

.hk-date-form[hidden] {
    display: none;
}

.hk-date-form input,
.hk-date-form button {
    min-height: 42px;
    border: 1px solid var(--line);
    border-radius: 0;
    background: var(--surface);
    color: var(--ink);
}

.hk-date-form input {
    min-width: 0;
    padding: 8px 10px;
}

.hk-date-form button {
    padding: 8px 13px;
    cursor: pointer;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
}

.hk-view-nav {
    display: flex;
    margin: 12px 0 0;
    border-bottom: 1px solid var(--line);
    gap: 2px;
}

.hk-view-nav a {
    padding: 12px 16px 10px;
    border-bottom: 2px solid transparent;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.hk-view-nav a.is-active {
    border-bottom-color: var(--ink);
    color: var(--ink);
}

.hk-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin: 34px 0 0;
    border-top: 1px solid var(--line);
    border-left: 1px solid var(--line);
}

.hk-summary article {
    min-width: 0;
    padding: 18px 18px 20px;
    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.58);
}

.hk-summary span,
.hk-sync-note span,
.hk-sync-note small {
    display: block;
    color: var(--muted);
    font-size: 0.67rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hk-summary strong {
    display: block;
    margin-top: 16px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2.2rem, 6vw, 3.6rem);
    font-weight: 400;
    line-height: 1;
}

.hk-sync-note {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    margin: 14px 0 46px;
    padding: 12px 0;
    border-bottom: 1px solid var(--soft-line);
    gap: 12px;
}

.hk-sync-note strong {
    font-size: 0.76rem;
}

.hk-sync-note small {
    max-width: 260px;
    overflow: hidden;
    text-align: right;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.hk-section {
    margin: 0 0 52px;
}

.hk-section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--ink);
    gap: 20px;
}

.hk-section-head > div {
    display: flex;
    align-items: baseline;
    gap: 14px;
}

.hk-section-head span {
    color: var(--muted);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 0.76rem;
}

.hk-section-head h2 {
    margin: 0;
    font-size: clamp(1.8rem, 5vw, 3.2rem);
    line-height: 1;
}

.hk-section-head > strong {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    font-family: Georgia, "Times New Roman", serif;
    font-weight: 400;
}

.hk-card-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.hk-card {
    position: relative;
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.76);
}

.hk-card::before {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 3px;
    background: var(--accent);
    content: "";
}

.hk-card--turnover::before {
    background: var(--warning);
}

.hk-card--arrival::before {
    background: var(--success);
}

.hk-card--departure::before {
    background: var(--danger);
}

.hk-card--stay::before {
    background: #74818b;
}

.hk-card--vacant::before {
    background: var(--line);
}

.hk-card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 21px 22px 19px 25px;
    border-bottom: 1px solid var(--soft-line);
    gap: 18px;
}

.hk-status-label {
    display: block;
    margin-bottom: 7px;
    color: var(--muted);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.hk-card-head h3 {
    margin: 0;
    font-size: clamp(2rem, 6vw, 3.25rem);
    line-height: 0.95;
}

.hk-status-mark {
    width: 10px;
    height: 10px;
    margin-top: 4px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--accent);
}

.hk-card--turnover .hk-status-mark {
    background: var(--warning);
}

.hk-card--arrival .hk-status-mark {
    background: var(--success);
}

.hk-card--departure .hk-status-mark {
    background: var(--danger);
}

.hk-card--stay .hk-status-mark {
    background: #74818b;
}

.hk-card--vacant .hk-status-mark {
    background: var(--line);
}

.hk-reservation-block {
    padding: 20px 22px 22px 25px;
}

.hk-reservation-block + .hk-reservation-block {
    border-top: 1px dashed var(--line);
}

.hk-reservation-label {
    display: block;
    margin-bottom: 15px;
    color: var(--muted);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hk-date-pair,
.hk-guest-counts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.hk-date-pair {
    margin-bottom: 18px;
    border-top: 1px solid var(--soft-line);
    border-left: 1px solid var(--soft-line);
}

.hk-date-pair > div,
.hk-guest-counts > div {
    padding: 13px 12px;
    border-right: 1px solid var(--soft-line);
    border-bottom: 1px solid var(--soft-line);
}

.hk-date-pair span,
.hk-guest-counts span,
.hk-nights span,
.hk-completed-stay span {
    display: block;
    color: var(--muted);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.hk-date-pair strong {
    display: block;
    margin-top: 6px;
    font-size: 0.86rem;
}

.hk-nights {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    margin-bottom: 18px;
    padding: 16px;
    background: var(--surface-soft);
    gap: 3px 14px;
}

.hk-nights strong {
    grid-row: 1 / span 2;
    grid-column: 2;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 3.5rem;
    font-weight: 400;
    line-height: 0.9;
}

.hk-nights small {
    color: var(--muted);
    font-size: 0.75rem;
}

.hk-guest-counts {
    border-top: 1px solid var(--soft-line);
    border-left: 1px solid var(--soft-line);
}

.hk-guest-counts strong {
    display: block;
    margin-top: 7px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 2rem;
    font-weight: 400;
    line-height: 1;
}

.hk-completed-stay {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    padding: 14px 15px;
    background: var(--surface-soft);
    gap: 16px;
}

.hk-completed-stay strong {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.15rem;
    font-weight: 400;
}

.hk-turnover-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.hk-turnover-grid > div + div {
    border-left: 1px solid var(--line);
}

.hk-turnover-grid .hk-reservation-block {
    height: 100%;
}

.hk-card--turnover {
    grid-column: 1 / -1;
}

.hk-vacant-copy {
    display: grid;
    padding: 30px 25px 34px;
    gap: 8px;
}

.hk-vacant-copy strong {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.4rem;
    font-weight: 400;
}

.hk-vacant-copy span {
    color: var(--muted);
    font-size: 0.82rem;
    line-height: 1.55;
}

.hk-empty-state {
    padding: clamp(64px, 12vw, 120px) 0;
}

.hk-empty-state--day {
    padding: 48px 0 62px;
}

.hk-empty-state h2 {
    margin: 10px 0 16px;
    font-size: clamp(3rem, 9vw, 6rem);
    line-height: 0.95;
}

.hk-empty-state p {
    max-width: 620px;
    color: var(--muted);
    line-height: 1.7;
}

.hk-empty-state a {
    display: inline-block;
    margin-top: 12px;
    border-bottom: 1px solid var(--ink);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
}

.hk-footer {
    margin-top: 24px;
}

@media (max-width: 760px) {
    .hk-header {
        align-items: flex-start;
    }

    .hk-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .hk-sync-note {
        grid-template-columns: 1fr auto;
    }

    .hk-sync-note small {
        grid-column: 1 / -1;
        max-width: 100%;
        text-align: left;
    }

    .hk-card-list {
        grid-template-columns: 1fr;
    }

    .hk-card--turnover {
        grid-column: auto;
    }
}

@media (max-width: 560px) {
    .hk-header-copy {
        text-align: left;
    }

    .hk-date-navigator {
        grid-template-columns: 46px minmax(0, 1fr) 46px;
    }

    .hk-date-navigator > div {
        padding-inline: 8px;
    }

    .hk-date-form {
        grid-template-columns: 1fr;
    }

    .hk-view-nav {
        justify-content: stretch;
    }

    .hk-view-nav a {
        flex: 1;
        padding-inline: 7px;
        text-align: center;
    }

    .hk-summary article {
        padding: 15px;
    }

    .hk-section {
        margin-bottom: 42px;
    }

    .hk-section-head > div {
        gap: 10px;
    }

    .hk-section-head h2 {
        font-size: 2rem;
    }

    .hk-card-head,
    .hk-reservation-block {
        padding-right: 17px;
        padding-left: 20px;
    }

    .hk-turnover-grid {
        grid-template-columns: 1fr;
    }

    .hk-turnover-grid > div + div {
        border-top: 1px solid var(--line);
        border-left: 0;
    }

    .hk-nights strong {
        font-size: 3rem;
    }
}

/* Phase 4 — operations dashboard and public access management */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-bottom: 24px;
    border-top: 1px solid var(--line);
    border-left: 1px solid var(--line);
}

.quick-actions > a {
    display: grid;
    min-height: 132px;
    align-content: space-between;
    padding: 20px;
    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.48);
    transition: background 160ms ease, transform 160ms ease;
}

.quick-actions > a:hover {
    background: var(--surface);
    transform: translateY(-1px);
}

.quick-actions span {
    color: var(--muted);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 0.72rem;
}

.quick-actions strong,
.quick-actions small {
    display: block;
}

.quick-actions strong {
    margin-top: 20px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.25rem;
    font-weight: 400;
}

.quick-actions small {
    margin-top: 6px;
    color: var(--muted);
    line-height: 1.45;
}

.dashboard-grid--operations {
    grid-template-columns: minmax(0, 1.55fr) minmax(320px, 0.7fr);
    margin-bottom: 24px;
}

.dashboard-grid--secondary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.admin-daily-list,
.compact-list,
.token-list {
    border-top: 1px solid var(--line);
}

.admin-daily-row {
    display: grid;
    grid-template-columns: minmax(190px, 0.8fr) minmax(0, 1.2fr);
    align-items: center;
    padding: 20px 0 20px 17px;
    border-bottom: 1px solid var(--soft-line);
    border-left: 3px solid var(--line);
    gap: 24px;
}

.admin-daily-row--turnover { border-left-color: var(--warning); }
.admin-daily-row--arrival { border-left-color: var(--success); }
.admin-daily-row--departure { border-left-color: var(--danger); }
.admin-daily-row--stay { border-left-color: var(--accent); }

.daily-status-label {
    display: block;
    margin-bottom: 7px;
    color: var(--muted);
    font-size: 0.64rem;
    font-weight: 700;
    letter-spacing: 0.11em;
    text-transform: uppercase;
}

.admin-daily-row strong {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.45rem;
    font-weight: 400;
}

.daily-row-facts {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.daily-row-facts span {
    padding: 8px 10px;
    border: 1px solid var(--soft-line);
    color: var(--muted);
    font-size: 0.73rem;
}

.daily-row-facts b {
    color: var(--ink);
    font-size: 0.9rem;
}

.compact-list-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 70px;
    padding: 14px 0;
    border-bottom: 1px solid var(--soft-line);
    gap: 18px;
}

.compact-list-row strong,
.compact-list-row small {
    display: block;
}

.compact-list-row strong {
    font-size: 0.84rem;
}

.compact-list-row small {
    margin-top: 5px;
    color: var(--muted);
    font-size: 0.72rem;
}

.compact-count {
    display: grid;
    grid-template-columns: auto auto auto auto;
    align-items: baseline;
    color: var(--muted);
    gap: 4px;
}

.compact-count b {
    color: var(--ink);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.25rem;
    font-weight: 400;
}

.compact-count span {
    font-size: 0.62rem;
    font-weight: 700;
}

.snapshot-summary--compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.panel-head--compact {
    margin-bottom: 22px;
}

.filter-form--advanced {
    grid-template-columns: repeat(3, minmax(170px, 1fr));
}

.filter-form--advanced .filter-actions {
    display: flex;
    align-items: flex-end;
    gap: 8px;
}

.filter-hint {
    margin: 18px 0 0;
    color: var(--muted);
    font-size: 0.74rem;
    line-height: 1.6;
}

.reservation-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin: 0 0 24px;
    border-top: 1px solid var(--line);
    border-left: 1px solid var(--line);
}

.reservation-summary-grid > div {
    min-height: 110px;
    padding: 20px;
    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.48);
}

.reservation-summary-grid span,
.reservation-summary-grid strong {
    display: block;
}

.reservation-summary-grid span {
    color: var(--muted);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.reservation-summary-grid strong {
    margin-top: 14px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 2.4rem;
    font-weight: 400;
}

.data-table--reservations td:first-child {
    color: var(--muted);
    font-family: Georgia, "Times New Roman", serif;
}

.dashboard-grid--access {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-bottom: 24px;
}

.generated-token-card {
    margin-bottom: 24px;
    padding: clamp(24px, 3vw, 38px);
    border: 1px solid var(--success);
    background: rgba(255, 255, 255, 0.78);
}

.generated-token-card h2 {
    margin: 8px 0 10px;
    font-size: 2.4rem;
}

.generated-token-card p:last-child {
    max-width: 760px;
    color: var(--muted);
    line-height: 1.65;
}

.copy-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    margin: 24px 0 12px;
}

.copy-field input,
.token-known-url input {
    min-width: 0;
    min-height: 52px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    background: var(--surface-soft);
    color: var(--ink);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.74rem;
}

.security-note {
    padding: 16px;
    border-left: 3px solid var(--accent);
    background: var(--surface-soft);
}

.security-note strong,
.security-note p {
    display: block;
}

.security-note strong {
    margin-bottom: 6px;
    font-size: 0.82rem;
}

.security-note p {
    margin: 0;
    color: var(--muted);
    font-size: 0.74rem;
    line-height: 1.55;
}

.token-list-panel {
    margin-top: 0;
}

.token-row {
    display: grid;
    grid-template-columns: minmax(190px, 0.8fr) minmax(360px, 1.4fr) auto;
    align-items: center;
    padding: 24px 0;
    border-bottom: 1px solid var(--soft-line);
    gap: 24px;
}

.token-row--inactive {
    opacity: 0.58;
}

.token-identity {
    display: flex;
    align-items: center;
    min-width: 0;
    gap: 12px;
}

.token-indicator {
    width: 9px;
    height: 9px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--success);
}

.token-row--inactive .token-indicator {
    background: var(--muted);
}

.token-identity strong,
.token-identity small {
    display: block;
}

.token-identity small {
    margin-top: 5px;
    color: var(--muted);
}

.token-row dl {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin: 0;
    gap: 16px;
}

.token-row dt {
    margin-bottom: 6px;
    color: var(--muted);
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.token-row dd {
    margin: 0;
    font-size: 0.76rem;
}

.token-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

.token-actions .button {
    min-height: 42px;
    padding: 10px 13px;
    font-size: 0.66rem;
}

.token-known-url,
.token-hidden-note {
    grid-column: 1 / -1;
}

.token-known-url {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 12px;
}

.token-known-url input {
    min-height: 44px;
}

.token-hidden-note {
    margin: -10px 0 0;
    color: var(--muted);
    font-size: 0.72rem;
}

@media (max-width: 1200px) {
    .quick-actions {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dashboard-grid--operations,
    .dashboard-grid--secondary,
    .dashboard-grid--access {
        grid-template-columns: 1fr;
    }

    .token-row {
        grid-template-columns: minmax(180px, 0.7fr) minmax(0, 1.3fr);
    }

    .token-actions {
        grid-column: 1 / -1;
        justify-content: flex-start;
    }
}

@media (max-width: 820px) {
    .filter-form--advanced {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .reservation-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .admin-daily-row {
        grid-template-columns: 1fr;
    }

    .daily-row-facts {
        justify-content: flex-start;
    }

    .token-row,
    .token-row dl {
        grid-template-columns: 1fr;
    }

    .token-actions {
        grid-column: auto;
    }
}

@media (max-width: 560px) {
    .quick-actions,
    .filter-form--advanced,
    .reservation-summary-grid {
        grid-template-columns: 1fr;
    }

    .quick-actions > a {
        min-height: 112px;
    }

    .copy-field,
    .token-known-url {
        grid-template-columns: 1fr;
    }

    .copy-field .button,
    .token-actions,
    .token-actions form,
    .token-actions .button {
        width: 100%;
    }

    .token-actions {
        flex-direction: column;
    }
}


/* Phase 5 — PWA and Web Push */
.hk-pwa-tools { display:flex; align-items:center; justify-content:space-between; gap:20px; margin:20px 0 12px; padding:20px; border:1px solid var(--line); background:rgba(255,255,255,.64); }
.hk-pwa-copy { display:grid; gap:5px; }
.hk-pwa-copy strong { font-family:Georgia,"Times New Roman",serif; font-size:1.25rem; font-weight:400; }
.hk-pwa-copy small { color:var(--muted); line-height:1.5; }
.hk-pwa-actions { display:flex; flex-wrap:wrap; gap:10px; justify-content:flex-end; }
.hk-pwa-actions .button { min-height:44px; padding:10px 15px; }
.hk-pwa-actions button[disabled] { opacity:.48; cursor:not-allowed; transform:none; }
.field-textarea { min-height:130px; resize:vertical; padding:14px; border:1px solid var(--line); background:var(--surface); }
.field-select { padding-right:36px; border:1px solid var(--line); background:var(--surface); }
.notification-layout { grid-template-columns:minmax(320px,.75fr) minmax(0,1.25fr); }
.notification-form { padding-top:8px; }
.form-help { margin:18px 0 0; color:var(--muted); font-size:.85rem; line-height:1.6; }
.form-help--warning { color:var(--danger); }
.device-list { display:grid; }
.device-row { display:flex; align-items:center; justify-content:space-between; gap:18px; padding:16px 0; border-bottom:1px solid var(--soft-line); }
.device-row:last-child { border-bottom:0; }
.device-row > div:first-child { display:grid; gap:5px; min-width:0; }
.device-row small { color:var(--muted); line-height:1.45; }
.device-actions { display:flex; align-items:center; gap:14px; flex-shrink:0; }
.activation-notify { display:inline-flex; align-items:center; gap:8px; margin-right:14px; color:var(--muted); font-size:.82rem; }
.activation-notify input { width:16px; height:16px; accent-color:var(--ink); }
.offline-shell { min-height:100vh; }
@media (max-width: 900px) { .notification-layout { grid-template-columns:1fr; } .hk-pwa-tools { align-items:flex-start; flex-direction:column; } .hk-pwa-actions { width:100%; justify-content:stretch; } .hk-pwa-actions .button { flex:1; } }
@media (max-width: 600px) { .device-row { align-items:flex-start; flex-direction:column; } .device-actions { width:100%; justify-content:space-between; } .hk-pwa-actions { flex-direction:column; } .hk-pwa-actions .button { width:100%; } .activation-notify { width:100%; margin:0 0 10px; } }
