:root {
    /* Dark theme matching the Active Shift Retirement Dashboard (retirement.activeshiftsoftware.com,
       its "sworn" blue track) so the suite reads as one product. Every color below goes through
       these tokens - .light-page and @media print swap them back to a light set for pages that
       get printed or pasted into Word. */
    color-scheme: dark;
    --bg: #2b2b2b;
    --card: #3c3f41;
    --modal: #1e1e1e;
    --row: #2b3540;
    --border: #555555;
    --border-soft: #444444;
    --text: #eaeaea;
    --text-muted: #d6d6d6;
    --text-faint: #c4c4c4;

    --accent: #1a3a5c;
    --accent-dark: #1a2a3a;
    --badge: #2980b9;

    --success: #2ecc71;
    --success-dark: #27ae60;
    --danger: #e74c3c;
    --danger-dark: #c0392b;
    --warning: #e67e22;
    --info: #3498db;

    --secondary: #5a5d60;
    --secondary-hover: #6a6d70;
    --orange: var(--warning);
    --dark: var(--modal);

    --team-a: #c0392b;
    --team-b: #2f7d32;
    --team-c: #1f4fb0;
}

/* Pages meant to be printed or copy/pasted into Word stay light on screen too. */
.light-page {
    color-scheme: light;
    --bg: #ffffff;
    --card: #ffffff;
    --modal: #ffffff;
    --row: #f2f5fa;
    --border: #c9d2e0;
    --border-soft: #c9d2e0;
    --text: #1a1a1a;
    --text-muted: #333333;
    --text-faint: #555555;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
}

a { color: var(--info); }

/* Bootstrap-free equivalent of the retirement site's dark form skin - native defaults assume a
   light page. Checkboxes/radios are left to color-scheme. */
input:not([type="checkbox"]):not([type="radio"]), select, textarea {
    background-color: var(--row);
    color: var(--text);
    border: 1px solid var(--border-soft);
}
input:not([type="checkbox"]):not([type="radio"]):focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--badge);
    box-shadow: 0 0 0 0.2rem rgba(52, 152, 219, 0.25);
}
::placeholder { color: var(--text-faint); opacity: 1; }

.topnav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    background: var(--accent-dark);
    border-bottom: 3px solid var(--badge);
    color: white;
    padding: 0.6rem 1.5rem;
}
.topnav .brand {
    /* The logo's navy nearly disappears against the dark navbar - a muted warm ivory plate (not
       pure white, which washed out the gold) keeps it legible. Same plate as the retirement site. */
    display: flex; align-items: center; text-decoration: none;
    background: #efe8d8; padding: 6px 14px; border-radius: 8px; line-height: 0;
}
.brand-logo { height: 48px; width: auto; display: block; }
.topnav-links { display: flex; align-items: center; flex-wrap: wrap; gap: 0.4rem 1.25rem; }
.nav-button {
    display: inline-block;
    color: var(--text-muted);
    text-decoration: none;
    background: none;
    border: none;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 0;
    cursor: pointer;
}
.nav-button:hover { color: white; }
.inline-form { display: inline; }

.messages { list-style: none; margin: 0; padding: 0.75rem 1.5rem 0; max-width: 1100px; margin: 0 auto; }
.messages .message { padding: 0.5rem 0.75rem; border-radius: 0.375rem; margin-bottom: 0.4rem; }
.messages .success { background: #1c4d2e; color: #c2f5d6; border: 1px solid var(--success-dark); }
.messages .error { background: #4d1f1c; color: #f5c6c2; border: 1px solid var(--danger-dark); }
.messages .info { background: #1c3a4d; color: #b8e2f5; border: 1px solid var(--info); }

main { max-width: 1100px; margin: 0 auto; padding: 1rem 1.5rem 3rem; }

/* Board */
.board-title {
    /* Spacer and actions columns share the same 1fr track, so whichever is wider forces both to
       match - keeping the title truly centered on the header instead of just centered within
       whatever space happens to be left over after the actions column. */
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 1rem;
    background: var(--accent);
    border-bottom: 3px solid var(--badge);
    color: white;
    padding: 1rem;
    border-radius: 0.5rem 0.5rem 0 0;
}
.board-title-spacer { display: flex; align-items: center; }
.board-logo { height: 64px; width: auto; display: block; background: #efe8d8; padding: 8px 16px; border-radius: 8px; }
.board-title-text { text-align: center; }
.board-title h1 { margin: 0; font-size: 1.6rem; }
.board-title-actions { display: flex; flex-direction: column; gap: 0.5rem; justify-self: end; }
.archived-note { margin: 0.25rem 0 0; color: #ffd27a; }

.board-instructions {
    background: var(--orange);
    color: #1a1a1a;
    text-align: center;
    padding: 0.6rem 1rem;
    font-weight: 600;
}

.message-ticker-card {
    background: var(--accent-dark);
    color: white;
    overflow: hidden;
    white-space: nowrap;
    padding: 0.55rem 0;
}
.message-ticker-track {
    display: inline-block;
    padding-left: 100%;
    font-weight: 700;
    font-size: 1.05rem;
    /* Always runs, even when the text is short enough to fit - a moving ticker reads as "new /
       live" at a glance, which a static line doesn't. */
    animation: message-marquee 16s linear infinite;
}
@keyframes message-marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-100%); }
}
/* PTO board: "Now Calling Round 2" bar - flashes when the console switches the track to Round 2 */
.round-banner {
    background: var(--badge);
    color: #fff;
    text-align: center;
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 0.6rem 1rem;
}
.round-banner.round-flash { animation: round-banner-flash 1s ease-in-out 5; }
@keyframes round-banner-flash {
    0%, 100% { background: var(--badge); }
    50% { background: var(--success-dark); }
}

.message-ticker-card.message-flash {
    animation: message-card-flash 1s ease-in-out 5;
}
@keyframes message-card-flash {
    0%, 100% { background: var(--accent-dark); }
    50% { background: var(--orange); }
}

.board-banner {
    display: flex;
    position: relative;
    background: var(--dark);
    color: white;
}
/* Covers the bidder/bid-time cells once bidding is marked complete (board.js updateCompleteBanner). */
.banner-complete {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #1a3f2b, #1f4d33);
    border-top: 2px solid var(--success-dark);
    border-bottom: 2px solid var(--success-dark);
    color: #eafaf0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.6s ease, visibility 0.6s;
}
.board-banner.is-complete .banner-complete { opacity: 1; visibility: visible; }
.banner-complete-title { font-size: 1.6rem; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; }
.banner-complete-sub { font-size: 1.05rem; font-weight: 600; margin-top: 0.2rem; color: #b9e8c9; }
.banner-cell { flex: 1; padding: 0.75rem 1rem; text-align: center; border-right: 1px solid var(--border-soft); }
.banner-cell:last-child { border-right: none; }
.banner-label { font-size: 0.75rem; text-transform: uppercase; color: var(--text-faint); letter-spacing: 0.05em; }
.banner-value { font-size: 1.15rem; font-weight: 700; margin-top: 0.15rem; }
.banner-sub { font-size: 0.8rem; color: var(--text-faint); margin-top: 0.1rem; }
.captured-note { color: var(--success); font-weight: 600; }
.banner-value.captured-note { font-size: 0.95rem; }
.status-cell .banner-value { color: var(--orange); }

/* Each station is its own raised card, stacked down the board. */
#grid-container { display: flex; flex-direction: column; gap: 1rem; }
.station-card {
    background: var(--card); padding: 0.25rem 1rem 1rem; border-radius: 0.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}
/* Command Staff has no station header row, so it needs the full top padding itself. */
.station-card:not(:has(.station-row)) { padding-top: 1rem; }
#grid-container > .empty-note { background: var(--card); border-radius: 0.5rem; margin: 0; }

.grid-table { width: 100%; table-layout: fixed; border-collapse: collapse; }
/* Station name centered between two thin blue rules - reads as a section break on the board
   rather than another filled bar competing with the team colors below it. */
.station-row th { padding: 0.9rem 0 0.6rem; }
.station-row th span {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 1.05rem;
    color: var(--text);
}
.station-row th span::before, .station-row th span::after {
    content: "";
    flex: 1;
    height: 2px;
    background: var(--badge);
}
.team-header { color: white; padding: 0.4rem 0.6rem; text-align: center; }
.team-0 { background: var(--team-a); }
.team-1 { background: var(--team-b); }
.team-2 { background: var(--team-c); }
.team-header:nth-child(n+5) { background: #555; }
.role-label { background: var(--row); padding: 0.4rem 0.6rem; text-align: center; font-weight: 600; width: 20%; }
.assigned-cell { padding: 0.4rem 0.6rem; text-align: center; border: 1px solid var(--border-soft); }
.grid-table tbody tr:nth-child(even) .assigned-cell { background: rgba(255, 255, 255, 0.03); }
/* Unfilled position vs. a team that has no such position at this station - previously both were
   just a blank dark cell, which read like missing data. */
.assigned-cell.open-slot { color: #8a8d90; font-style: italic; font-size: 0.9em; }
.assigned-cell.no-slot {
    background: repeating-linear-gradient(45deg, transparent, transparent 6px, rgba(255, 255, 255, 0.04) 6px, rgba(255, 255, 255, 0.04) 12px) !important;
}
.uncertain-row .role-label { background: #4a4d50; color: var(--text-faint); font-style: italic; }
.uncertain-row .assigned-cell { background: #333537 !important; color: var(--text-faint); }

/* Newly-assigned cell pulses a blue outline for 15s so watchers can spot who just got picked */
@keyframes pulse-bid-anim {
    0%, 100% { box-shadow: inset 0 0 0 2px var(--badge), 0 0 0 0 rgba(52, 152, 219, 0); }
    50% { box-shadow: inset 0 0 0 3px var(--info), 0 0 14px 2px rgba(52, 152, 219, 0.6); background-color: rgba(41, 128, 185, 0.18); }
}
.assigned-cell.pulse-bid {
    animation: pulse-bid-anim 1s ease-in-out infinite;
    font-weight: 700;
}

/* PTO board calendar: the just-booked dates pulse with the same blue as Shift Bid's pulse-bid */
tr.pulse-bid-row td {
    animation: pulse-bid-anim 1s ease-in-out infinite;
    font-weight: 700;
}

/* Same idea as pulse-bid above, but for a whole table row (PTO board's new-booking row) */
@keyframes pulse-row-anim {
    0%, 100% { background-color: #1c4d2e; }
    50% { background-color: var(--success-dark); }
}
tr.pulse-row td {
    animation: pulse-row-anim 1s ease-in-out infinite;
    font-weight: 700;
}

/* "Bring Up Next Bidder Now" - pulses to signal it's live and clickable right now, matching the
   same green pulse language used elsewhere for "something needs your attention" */
@keyframes pulse-button-anim {
    0%, 100% { background-color: var(--success-dark); box-shadow: 0 0 0 0 rgba(46, 204, 113, 0.5); }
    50% { background-color: #1e8449; box-shadow: 0 0 0 6px rgba(46, 204, 113, 0); }
}
.pulse-button {
    animation: pulse-button-anim 1.5s ease-in-out infinite;
    background: var(--success-dark); color: white; border: none;
}

.empty-note { text-align: center; color: var(--text-faint); padding: 2rem; }
.last-updated { text-align: center; color: var(--text-faint); font-size: 0.8rem; margin-top: 0.75rem; }

/* Console / forms */
.console-status { display: flex; flex-direction: column; gap: 0.5rem; }
.console-controls { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.console-controls button {
    background: var(--badge); color: white; border: none; padding: 0.6rem 1rem; border-radius: 0.375rem; cursor: pointer;
}
.console-controls button:hover { background: var(--accent); }
.console-controls button.secondary-button { background: var(--secondary); }
.console-controls button.secondary-button:hover { background: var(--secondary-hover); }
.console-controls-link {
    display: inline-block;
    background: var(--badge); color: white; border: none; padding: 0.6rem 1rem; border-radius: 0.375rem;
    text-decoration: none; font-size: 1rem;
}
.console-controls-link:hover { background: var(--accent); }
.today-badge {
    background: var(--orange); color: #1a1a1a; font-weight: 700; font-size: 0.7rem;
    padding: 0.1rem 0.4rem; border-radius: 3px; margin-left: 0.4rem;
}
/* Cards - same treatment as the retirement site's .rd-card: raised dark panel, blue top stripe */
.console-section {
    background: var(--card); border: none; border-top: 4px solid var(--badge); border-radius: 0.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35); padding: 1rem 1.25rem; margin-bottom: 1.25rem;
}
.console-section h2 { margin-top: 0; font-size: 1.05rem; color: var(--text); }

.bid-form { display: flex; gap: 1rem; align-items: flex-end; flex-wrap: wrap; }
.bid-form label {
    display: flex; flex-direction: column; font-size: 0.85rem; color: var(--text-muted); font-weight: 600; gap: 0.25rem;
    /* Flex items default to min-width:auto, which refuses to shrink below a <select>'s content
       width (its longest option text) even when max-width is set on the select itself - that's
       why a long option label could still blow the box out past the card. min-width:0 here is
       what actually lets it shrink/wrap to fit the card. (Deliberately NOT setting flex-grow here
       - .two-line-form is a column-direction .bid-form, where flex-grow stretches height instead
       of width, which is what previously ballooned the Enter a Bid card.) */
    min-width: 0;
}
.hint { font-weight: normal; color: var(--text-faint); font-size: 0.78rem; }

.back-button {
    display: inline-block;
    background: var(--secondary);
    color: white;
    text-decoration: none;
    font-size: 0.85rem;
    padding: 0.4rem 0.9rem;
    border-radius: 0.375rem;
}
.back-button:hover { background: var(--secondary-hover); }
.bid-form select, .bid-form input, .auth-form input, .auth-form select {
    padding: 0.45rem; border: 1px solid var(--border-soft); border-radius: 0.375rem; width: 100%; min-width: 0;
    box-sizing: border-box;
}
.auth-form select, .auth-form input { min-width: 220px; width: auto; }
.bid-button { background: var(--success-dark); color: white; border: none; padding: 0.55rem 1.2rem; border-radius: 0.375rem; cursor: pointer; }
.clear-button { background: var(--danger-dark); color: white; border: none; padding: 0.55rem 1.2rem; border-radius: 0.375rem; cursor: pointer; }

.current-message-row {
    display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap;
    padding: 0.5rem 0.7rem; background: var(--row); border-radius: 0.375rem; margin-bottom: 0.75rem;
}
.message-preset-form, .message-custom-form {
    display: flex !important; gap: 0.6rem; align-items: flex-end; margin-bottom: 0.75rem;
}
.message-preset-form:last-child, .message-custom-form:last-child { margin-bottom: 0; }
.message-preset-form label, .message-custom-form label {
    display: flex; flex-direction: column; font-size: 0.85rem; color: var(--text-muted); font-weight: 600; gap: 0.25rem;
}
.message-preset-form select, .message-custom-form input {
    padding: 0.45rem; border: 1px solid var(--border-soft); border-radius: 0.375rem; width: 100%;
}
.message-preset-form button, .message-custom-form button {
    background: var(--badge); color: white; border: none; padding: 0.5rem 1.1rem; border-radius: 0.375rem; cursor: pointer;
    flex-shrink: 0;
}

.rule-edit-form { display: flex; flex-direction: column; gap: 0.6rem; }
.rule-edit-form label { display: flex; flex-direction: column; font-size: 0.85rem; color: var(--text-muted); font-weight: 600; gap: 0.25rem; }
.rule-edit-form input, .rule-edit-form textarea {
    padding: 0.45rem; border: 1px solid var(--border-soft); border-radius: 0.375rem; font-family: inherit;
}
.rule-edit-form button { align-self: flex-start; background: var(--badge); color: white; border: none; padding: 0.5rem 1.1rem; border-radius: 0.375rem; cursor: pointer; }
.overflow-status-list { list-style: none; margin: 0; padding: 0; }
.overflow-status-list li { padding: 0.4rem 0; border-bottom: 1px solid var(--border-soft); font-size: 0.9rem; }
.overflow-status-list li:last-child { border-bottom: none; }

.rule-edit-actions { display: flex; gap: 0.5rem; align-items: flex-end; }
.clear-button-big {
    background: var(--danger-dark); color: white; border: none; padding: 0.65rem 1.4rem;
    border-radius: 0.375rem; cursor: pointer; font-size: 1rem; font-weight: 700;
}
.clear-button-big:hover { background: var(--danger); }
.checkbox-label { display: flex; flex-direction: row-reverse; align-items: center; gap: 0.4rem; font-size: 0.85rem; color: var(--text-muted); justify-content: flex-end; }
.station-row-actions { display: flex; gap: 0.6rem; align-items: center; margin-top: 0.6rem; }
.save-button-big {
    background: var(--success-dark); color: white; border: none; padding: 0.65rem 1.6rem;
    border-radius: 0.375rem; cursor: pointer; font-size: 1rem; font-weight: 700;
}
.save-button-big:hover { background: #1e8449; }
.bidder-table td { vertical-align: middle; }
.bidder-table input, .bidder-table select {
    padding: 0.3rem; border: 1px solid var(--border-soft); border-radius: 0.375rem; font-size: 0.85rem; width: 100%;
}
.bidder-must-bid-cell { display: flex; flex-direction: column; gap: 0.25rem; min-width: 160px; }
.row-actions { display: flex; gap: 0.4rem; align-items: center; white-space: nowrap; }
.row-actions button { border: none; padding: 0.35rem 0.7rem; border-radius: 0.375rem; cursor: pointer; color: white; font-size: 0.85rem; }
.row-actions button[form^="update-"] { background: var(--badge); }
.row-actions button[form^="remove-"] { background: var(--danger-dark); }

.setup-buttons { display: flex; gap: 0.6rem; flex-wrap: wrap; }
.setup-buttons a {
    background: var(--badge); color: white; text-decoration: none; padding: 0.5rem 1rem;
    border-radius: 0.375rem; font-size: 0.9rem;
}
.setup-buttons a:hover { background: var(--accent); }

/* Console layout: top row (controls + setup), full-width status, two columns, recent activity in left column */
.console-top-row { display: flex; gap: 1rem; margin-bottom: 1.25rem; align-items: stretch; }
.console-top-row .controls-card { flex: 2; margin-bottom: 0; }

/* Setup card is one big clickable link styled as a card - no separate button inside it */
.setup-card-link {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: var(--card);
    border: none;
    border-top: 4px solid var(--badge);
    border-radius: 0.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
    padding: 1rem;
    text-decoration: none;
    color: inherit;
    text-align: center;
    transition: box-shadow 0.15s, transform 0.15s;
}
.setup-card-link:hover { box-shadow: 0 6px 16px rgba(0, 0, 0, 0.5); transform: translateY(-2px); }
.setup-card-link h2 { margin: 0 0 0.4rem; color: var(--text); font-size: 1.05rem; }
.setup-card-link p { margin: 0; font-size: 0.85rem; color: var(--text-muted); }

.controls-card-header { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.controls-card-header h2 { margin: 0; }
.bid-date-badge { font-size: 0.85rem; color: var(--text-muted); text-align: right; }

.controls-status-row {
    display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap;
    gap: 0.5rem 1.5rem; font-size: 1.15rem; color: var(--text-muted); margin: 0.5rem 0 1rem;
}
.controls-status-right { text-align: right; }
.status-value { font-weight: 400; color: var(--text); }
.status-value.status-in_progress { font-weight: 700; color: var(--success); }
.status-value.status-paused { font-weight: 700; color: var(--danger); }

.status-row { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 1rem; margin-bottom: 1.25rem; align-items: stretch; }
.status-row .console-section { margin-bottom: 0; }
.next-bidders-list { list-style: none; margin: 0; padding: 0; }
.next-bidders-list li { padding: 0.25rem 0; border-bottom: 1px solid var(--border-soft); }
.next-bidders-list li:last-child { border-bottom: none; }

/* Shift Bid console - title bar + Setup across the top, controls sidebar on the left, live
   status / Enter a Bid / Bidder List on the right. Send Message, Manual Override and Clear an
   Assignment open as pop-up <dialog>s from the sidebar. */
.console-layout {
    display: grid;
    grid-template-columns: 250px 1fr 230px;
    grid-template-areas:
        "title   title setup"
        "sidebar main  main";
    gap: 1.25rem;
    align-items: start;
}
.console-title-card {
    grid-area: title;
    align-self: stretch;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: var(--accent-dark);
    border-bottom: 3px solid var(--badge);
    border-radius: 0.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
    padding: 1rem 1.25rem;
    text-align: center;
    color: white;
}
.console-title-card h1 { margin: 0 0 0.35rem; font-size: 1.5rem; }
.console-bid-date { color: var(--text-muted); font-weight: 600; }
.console-setup-card {
    grid-area: setup;
    align-self: stretch;
    background: var(--badge);
    border-top: none;
    color: white;
}
.console-setup-card h2 { color: white; font-size: 1.2rem; }
.console-setup-card p { color: #e3eef7; }
.console-setup-card:hover { background: #2f8fcc; }

.console-sidebar { grid-area: sidebar; display: flex; flex-direction: column; gap: 1.25rem; min-width: 0; }
.console-sidebar .console-section { margin-bottom: 0; }
.sidebar-status { font-size: 1.05rem; }
.sidebar-divider { height: 2px; background: var(--border-soft); margin: 0.9rem -1.25rem; }
.sidebar-label { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-faint); font-weight: 700; }
.sidebar-message-text { margin: 0.3rem 0; font-size: 0.9rem; overflow-wrap: anywhere; }
.sidebar-actions { display: flex; flex-direction: column; gap: 0.6rem; }
.sidebar-actions form { margin: 0; }
.sidebar-gap { height: 0.5rem; }
.sidebar-button {
    display: block; width: 100%;
    border: none; border-radius: 0.375rem; padding: 0.7rem 1rem;
    font: inherit; font-size: 1rem; font-weight: 700; cursor: pointer; color: white;
}
.sidebar-button-popup { background: var(--badge); }
.sidebar-button-popup:hover { background: var(--accent); }
.sidebar-button-start { background: var(--success-dark); }
.sidebar-button-start:hover { background: #1e8449; }
.sidebar-button-pause { background: var(--orange); color: #1a1a1a; }
.sidebar-button-pause:hover { background: #d35400; color: white; }
.sidebar-button-complete { background: #1f4d33; border: 2px solid var(--success-dark); }
.sidebar-button-complete:hover { background: #1a3f2b; }
.sidebar-link-button {
    background: none; border: none; padding: 0.2rem 0; cursor: pointer;
    font: inherit; font-size: 0.85rem; color: var(--text-faint); text-decoration: underline;
}
.sidebar-link-button:hover { color: white; }

.console-main { grid-area: main; display: flex; flex-direction: column; gap: 1.25rem; min-width: 0; }
.console-main .console-section { margin-bottom: 0; }
/* Two cards side by side, stretched to equal height: Current Bidding Status beside Enter a Bid
   (wider, for its long dropdowns), then Next Bidders beside Missed Call In. */
.console-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; align-items: stretch; }
.console-pair-top { grid-template-columns: 1fr 1.5fr; }
.recent-activity-card .log-list { max-height: 16rem; line-height: 1.5; }

/* PTO console - sidebar quick links, and Enter a Bid split into bidder (left) / dates (right) */
.sidebar-links { display: flex; flex-direction: column; gap: 0.5rem; }
.sidebar-links .back-button { text-align: center; }
.pto-enter-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; align-items: start; }
.pto-enter-col { min-width: 0; }

.console-dialog {
    background: var(--modal);
    color: var(--text);
    border: 1px solid var(--border-soft);
    border-top: 4px solid var(--badge);
    border-radius: 0.5rem;
    padding: 1.5rem 1.75rem;
    width: min(620px, calc(100vw - 2rem));
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
}
.console-dialog::backdrop { background: rgba(0, 0, 0, 0.65); }
.console-dialog h2 { margin-top: 0; padding-right: 2rem; }
.dialog-form { flex-direction: column; align-items: stretch; }
.dialog-form button { align-self: flex-start; }

@media (max-width: 900px) {
    .console-layout {
        grid-template-columns: 1fr;
        grid-template-areas: "title" "setup" "sidebar" "main";
    }
    .console-pair, .console-pair-top, .pto-enter-grid { grid-template-columns: 1fr; }
}

/* Fixed-height, vertical-scroll-only lists - sized to roughly N visible rows */
.scrollable-list-3, .scrollable-list-short { overflow-y: auto; overflow-x: hidden; }
.scrollable-list-3 { max-height: 6.5rem; }
.scrollable-list-short { max-height: 9rem; }

.console-columns { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 1.25rem; align-items: start; margin-bottom: 1.25rem; }
.console-column-left { display: flex; flex-direction: column; gap: 1.25rem; min-width: 0; }
.console-column-left .console-section { margin-bottom: 0; }
.console-column-right { display: flex; flex-direction: column; min-width: 0; }
/* Public PTO board: Bid Times carries the R1/R2/Biddable/Days Left columns, so it gets the wider
   side and the booked-dates calendar takes the narrower one. */
/* Bid Times shrinks to fit its columns; the booked-dates calendar gets all the remaining width. */
.pto-board-columns { grid-template-columns: max-content minmax(0, 1fr); }
.pto-board-columns .console-column-left .roster-table { width: auto; }
.pto-board-columns .console-column-left .roster-table td:first-child { white-space: nowrap; }
@media (max-width: 900px) { .pto-board-columns .console-column-left .roster-table { width: 100%; } }
/* Keep both public tables narrow enough that the booked-dates calendar never scrolls sideways */
.pto-board-columns .roster-table th, .pto-board-columns .roster-table td { padding: 0.4rem 0.45rem; }
.pto-board-columns .roster-table th.narrow-col, .pto-board-columns .roster-table td.narrow-col { width: 1%; text-align: center; white-space: nowrap; }
.pto-board-columns .roster-table th.narrow-col { line-height: 1.15; }
.pto-board-columns .nowrap-col { white-space: nowrap; }
.pto-calendar-public th { line-height: 1.15; }
.pto-calendar-public th, .pto-calendar-public td { text-align: center; }
.upcoming-card { display: flex; flex-direction: column; flex: 1; margin-bottom: 0; }
.scrollable-list { overflow-y: auto; flex: 1; min-height: 0; max-height: 70vh; }
.scrollable-list table { margin: 0; }
.scrollable-list thead th { position: sticky; top: 0; background: var(--accent-dark); }
.bidder-table-scroll { max-height: 60vh; border: 1px solid var(--border-soft); border-radius: 0.375rem; }

@media (max-width: 800px) {
    .console-top-row, .console-columns, .status-row { grid-template-columns: 1fr; display: flex; flex-direction: column; }
    .scrollable-list { max-height: 320px; }
}

.two-line-form { flex-direction: column; align-items: stretch; }
.two-line-form .full-line { width: 100%; }
.two-line-form .inline-row { display: flex; gap: 1rem; align-items: flex-end; }
.grow { flex: 1; }

/* Public boards: "← Home" and "Message the Admin" under the logo */
.board-title-spacer { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
.board-logo-buttons { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.board-home-button, .message-admin-button {
    font-size: 0.85rem; font-weight: 700; padding: 0.4rem 0.8rem; border-radius: 0.375rem;
    text-decoration: none; cursor: pointer; line-height: 1.2;
}
.board-home-button { background: var(--border-soft); color: var(--text); border: 1px solid var(--border-soft); }
.board-home-button:hover { background: #555; }
.message-admin-button { background: var(--badge); color: #fff; border: none; }
.message-admin-button:hover { filter: brightness(1.15); }
.message-admin-button[hidden] { display: none; }
.message-admin-modal h2 { font-size: 1.35rem; padding-right: 2rem; }
.message-admin-note { color: #f7dc6f; font-weight: 600; margin: 0 0 1rem; }
.message-admin-field { display: flex; flex-direction: column; gap: 0.3rem; margin-bottom: 0.8rem; font-size: 1rem; }
.message-admin-field input, .message-admin-field textarea { font-size: 1.05rem; padding: 0.6rem 0.7rem; font-family: inherit; }
.message-admin-actions { display: flex; gap: 0.6rem; justify-content: center; align-items: center; margin-top: 1rem; flex-wrap: wrap; }
.message-admin-actions .big-close-button { min-width: 10rem; }

/* Admin consoles: inbox for messages from the boards */
.admin-inbox-button {
    position: fixed; right: 1rem; bottom: 1rem; z-index: 40;
    background: var(--badge); color: #fff; border: none; border-radius: 999px;
    padding: 0.6rem 1.1rem; font-weight: 800; cursor: pointer; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
}
.admin-inbox-off .admin-inbox-button { background: #555; }
.admin-inbox-count { background: var(--danger); color: #fff; border-radius: 999px; padding: 0.05rem 0.5rem; margin-left: 0.3rem; }
.admin-inbox-count[hidden] { display: none; }
.admin-inbox-switch { display: flex; gap: 0.5rem; align-items: center; margin-bottom: 0.5rem; cursor: pointer; }
.admin-inbox-switch input { width: 1.2rem; height: 1.2rem; }
.admin-inbox-list { display: flex; flex-direction: column; gap: 0.6rem; margin-top: 0.75rem; max-height: 55vh; overflow-y: auto; }
.admin-inbox-item { background: var(--card); border-left: 4px solid var(--badge); border-radius: 0.375rem; padding: 0.7rem 0.8rem; }
.admin-inbox-meta { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 0.3rem; }
.admin-inbox-text { white-space: pre-wrap; margin-bottom: 0.5rem; font-size: 1.05rem; }

/* Welcome page (site front door): two big cards + Log in top right. Colors follow
   retirement.activeshiftsoftware.com - navy bar with a blue stripe, ivory logo plate, navy hero
   band, charcoal cards. */
.welcome { min-height: 100vh; display: flex; flex-direction: column; background: #2b2b2b; font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; }
.welcome-bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.7rem 1.5rem; background: #1a2a3a; border-bottom: 3px solid #2980b9; }
.welcome-logo { height: 40px; width: auto; background: #efe8d8; border-radius: 8px; padding: 6px 14px; }
.welcome-account { display: flex; gap: 0.5rem; flex-wrap: wrap; justify-content: flex-end; }
.welcome-login {
    border: 1px solid #f8f9fa; color: #f8f9fa; text-decoration: none; font-weight: 600;
    padding: 0.45rem 1.3rem; border-radius: 0.375rem;
}
.welcome-login:hover { background: #f8f9fa; color: #1a2a3a; }
.welcome-hero { background: #1a3a5c; color: #fff; text-align: center; padding: 2.5rem 1rem; }
.welcome-hero h1 { font-size: 2.6rem; font-weight: 700; margin: 0 0 0.35rem; }
.welcome-hero p { color: #d6dee6; font-size: 1.15rem; margin: 0; }
.welcome-main { flex: 1; display: flex; justify-content: center; padding: 2.5rem 1rem 4rem; }
.welcome-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 380px)); gap: 1.75rem; width: 100%; justify-content: center; align-content: start; }
.welcome-card {
    display: flex; flex-direction: column; align-items: center; gap: 0.75rem; text-align: center;
    background: #3c3f41; border-radius: 0.5rem; padding: 2.5rem 1.75rem;
    text-decoration: none; color: #eaeaea; border-top: 5px solid #2980b9;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35); transition: transform 0.15s, box-shadow 0.15s;
}
.welcome-card-pto { border-top-color: #27ae60; }
.welcome-card:hover, .welcome-card:focus-visible { transform: translateY(-4px); box-shadow: 0 10px 26px rgba(0, 0, 0, 0.5); color: #fff; }
.welcome-card-icon { font-size: 3.2rem; line-height: 1; }
.welcome-card-title { font-size: 1.9rem; font-weight: 700; }
.welcome-card-text { color: #d6d6d6; font-size: 1rem; line-height: 1.45; }
.welcome-card-go { margin-top: 0.5rem; font-weight: 700; color: #3498db; }
.welcome-card-pto .welcome-card-go { color: #2ecc71; }
@media (max-width: 720px) {
    .welcome-cards { grid-template-columns: 1fr; }
    .welcome-hero h1 { font-size: 2rem; }
    .welcome-bar { padding: 0.6rem 1rem; }
}

.setup-hub-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1rem; }
.setup-hub-card {
    display: block; background: var(--card); border: none; border-top: 4px solid var(--badge); border-radius: 0.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
    padding: 1rem; text-decoration: none; color: inherit; transition: box-shadow 0.15s, transform 0.15s;
}
.setup-hub-card:hover { box-shadow: 0 6px 16px rgba(0, 0, 0, 0.5); transform: translateY(-2px); }
.setup-hub-card h3 { margin: 0 0 0.4rem; color: var(--text); font-size: 1rem; }
.setup-hub-card p { margin: 0; font-size: 0.85rem; color: var(--text-muted); }

.setup-steps { margin: 0; padding-left: 1.3rem; }
.setup-steps li { margin-bottom: 0.6rem; line-height: 1.4; }
.setup-steps li:last-child { margin-bottom: 0; }

.roster-table { width: 100%; border-collapse: collapse; }
.roster-table th, .roster-table td { border: 1px solid var(--border-soft); padding: 0.4rem 0.6rem; text-align: left; font-size: 0.9rem; }
.roster-table th { background: var(--accent-dark); color: var(--text); }
.current-row { background: rgba(230, 126, 34, 0.2); }
.pto-days-edit-form { display: flex; gap: 0.3rem; align-items: center; }
.pto-days-edit-form input[type="number"] { width: 3.5rem; min-width: 0; padding: 0.2rem; }
.pto-days-edit-form button { padding: 0.2rem 0.5rem; font-size: 0.8rem; }

.log-list { margin: 0; padding-left: 1.2rem; font-size: 0.85rem; color: var(--text-muted); }

.auth-form {
    max-width: 400px; margin: 2rem auto; background: var(--card); border: none; border-top: 4px solid var(--badge);
    border-radius: 0.5rem; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35); padding: 1.5rem;
}
.auth-form p { margin: 0.5rem 0; }
.auth-form label { color: var(--text-muted); font-weight: 600; font-size: 0.9rem; }
.hint { font-size: 0.85rem; color: var(--text-faint); }
.auth-form button, .console-section a { display: inline-block; }
.auth-form button {
    background: var(--badge); color: white; border: none; padding: 0.55rem 1.2rem; border-radius: 0.375rem; cursor: pointer; margin-top: 0.5rem;
}
.auth-form button:hover { background: var(--accent); }

.empty-state { text-align: center; padding: 4rem 1rem; color: var(--text-muted); }

/* Footer - small corner credit, same as the retirement site's .rd-footer-corner */
.site-footer { display: block; padding: 1rem 0.75rem; color: var(--text-faint); font-size: 0.75rem; }

/* Paused banner - slides down into view from the top when it appears, and back up out of view
   when it's dismissed, instead of an instant show/hide. The wrapper animates open/closed with a
   grid-rows trick (the only way to transition to/from a content-driven height in plain CSS); the
   inner banner rides a transform so the motion actually reads as sliding, not just growing. */
.hidden { display: none !important; }
.paused-banner-wrap {
    position: sticky;
    top: 0;
    z-index: 20;
    display: grid;
    grid-template-rows: 1fr;
    margin-bottom: 0.75rem;
    opacity: 1;
    transition: grid-template-rows 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s ease, margin-bottom 0.4s ease;
}
.paused-banner-wrap.collapsed {
    grid-template-rows: 0fr;
    opacity: 0;
    margin-bottom: 0;
}
.paused-banner {
    overflow: hidden;
    min-height: 0;
    background: repeating-linear-gradient(45deg, #c0392b, #c0392b 20px, #a12922 20px, #a12922 40px);
    color: white;
    text-align: center;
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 0.9rem 1rem;
    border-radius: 0.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.35);
    transform: translateY(0);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.paused-banner-wrap.collapsed .paused-banner {
    transform: translateY(-100%);
    padding-top: 0;
    padding-bottom: 0;
}
.paused-banner-sub {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: none;
    letter-spacing: normal;
    margin-top: 0.25rem;
}

/* Bidder cell flashes briefly at 3 moments, then goes quiet - not a constant blink for the whole
   turn: green (bid time opens, 15s + a tone) -> orange (halfway through, 15s, no sound) -> red
   (last 30s, 30s + a distinct 5-note alarm). A fixed iteration count (1 cycle/sec) makes it stop
   on its own once that many seconds have passed, instead of needing JS to remove the class. */
@keyframes stage-green-anim { 0%, 100% { background-color: transparent; } 50% { background-color: #27ae60; } }
@keyframes stage-orange-anim { 0%, 100% { background-color: transparent; } 50% { background-color: #e67e22; } }
@keyframes stage-red-anim { 0%, 100% { background-color: transparent; } 50% { background-color: #c0392b; } }
.banner-cell.stage-green { animation: stage-green-anim 1s ease-in-out 15; border-radius: 4px; }
.banner-cell.stage-orange { animation: stage-orange-anim 1s ease-in-out 15; border-radius: 4px; }
.banner-cell.stage-red { animation: stage-red-anim 1s ease-in-out 30; border-radius: 4px; }

.enable-sound-button {
    flex-shrink: 0;
    background: var(--success-dark);
    color: white;
    border: none;
    font-weight: 700;
    padding: 0.45rem 1rem;
    border-radius: 0.375rem;
    cursor: pointer;
}
.enable-sound-button:hover { background: #1e8449; }

/* PTO date fields: typed date box + calendar button in front of the real (visually hidden) date
   input - see ptobid/date_entry.js */
.date-entry { position: relative; display: flex; gap: 0.35rem; align-items: stretch; }
.date-entry input.date-entry-text { flex: 1; min-width: 0; width: auto; }
.date-entry-text.date-entry-invalid { border-color: var(--danger); outline-color: var(--danger); }
.date-entry-calendar {
    flex-shrink: 0; background: var(--border-soft); border: 1px solid var(--border-soft);
    border-radius: 0.375rem; padding: 0 0.6rem; cursor: pointer; font-size: 1rem;
}
/* Our own 📅 calendar (the native one couldn't be dismissed and covered the results panel) */
.date-entry-popover {
    position: absolute; top: calc(100% + 4px); right: 0; z-index: 60; width: 16rem;
    background: var(--modal); border: 1px solid var(--border-soft); border-radius: 0.5rem;
    padding: 0.5rem; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}
.date-entry-popover[hidden] { display: none; }
.dep-head { display: flex; align-items: center; justify-content: space-between; font-weight: 700; margin-bottom: 0.35rem; }
.dep-nav { background: none; border: none; color: var(--text); font-size: 1.3rem; cursor: pointer; padding: 0 0.5rem; }
.dep-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; text-align: center; }
.dep-dow { font-size: 0.7rem; color: var(--text-muted); padding: 0.15rem 0; }
.dep-day { padding: 0.3rem 0; border-radius: 0.25rem; font-size: 0.85rem; }
.dep-work { background: var(--border-soft); color: var(--text); border: none; cursor: pointer; font-weight: 700; }
.dep-work:hover { background: var(--badge); color: #fff; }
.dep-selected { background: var(--success-dark); color: #fff; }
.dep-off { color: var(--text-faint); opacity: 0.45; }
/* Kept rendered (not display:none) so form validation still works on it. */
.date-entry input.date-entry-native {
    position: absolute; right: 0; bottom: 0; width: 1px; height: 1px; opacity: 0;
    pointer-events: none; border: 0; padding: 0;
}

/* PTO team sheet: Round 2 "Add Date" popup */
.modal-backdrop[hidden] { display: none; }
/* No inner scroll box: it was clipping the 📅 calendar. The modal grows to fit, and on a short
   screen the backdrop scrolls instead (margin: auto keeps it centred when it does fit). */
#round2-modal { overflow-y: auto; align-items: flex-start; }
.modal.round2-modal { max-width: 760px; max-height: none; overflow: visible; margin: auto; }
.add-date-button { margin-left: 0.4rem; padding: 0.2rem 0.6rem; font-size: 0.8rem; }
.add-date-button:disabled { opacity: 0.4; cursor: not-allowed; }
.round2-dates { display: flex; gap: 1rem; margin: 0.75rem 0; }
.round2-dates label { flex: 1; display: flex; flex-direction: column; gap: 0.25rem; }
.round2-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-bottom: 0.75rem; }
@media (max-width: 520px) { .round2-dates { flex-direction: column; } }

/* PTO public board: "Check If My Dates Are Available" - stands out under Fit to Screen */
.check-my-dates-button {
    background: var(--success-dark); color: #fff; border: 2px solid #fff; font-weight: 800;
    padding: 0.5rem 1rem; border-radius: 0.375rem; cursor: pointer; box-shadow: 0 0 0 3px rgba(46, 204, 113, 0.35);
}
.check-my-dates-button:hover { background: #1e8449; }
.check-dates-ok .check-dates-headline { color: #c2f5d6; }
.check-dates-notice {
    background: #4d3319; border: 2px solid var(--warning); color: #f5b041;
    font-size: 1.15rem; font-weight: 800; line-height: 1.4;
    animation: notice-pulse 1.6s ease-in-out infinite;
}
.check-dates-notice p { margin: 0 0 0.4rem; }
.check-dates-notice p:last-child { margin-bottom: 0; }
@keyframes notice-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(230, 126, 34, 0); border-color: var(--warning); }
    50% { box-shadow: 0 0 14px 3px rgba(230, 126, 34, 0.55); border-color: #f5b041; }
}
@media (prefers-reduced-motion: reduce) { .check-dates-notice { animation: none; } }
/* Shift Bid console "Enter a Bid": bigger Bidder / Position drop-downs (and their option lists) */
#bid-form select { font-size: 1.15rem; padding: 0.55rem 0.7rem; min-height: 2.8rem; }
#bid-form select option { font-size: 1.1rem; }
#bid-form label { font-size: 1.05rem; }
#bid-form .bid-button { font-size: 1.1rem; padding: 0.65rem 1.5rem; }

/* PTO console "Enter a Bid": bigger bidder drop-down, date boxes and round picker - typed into
   quickly while on the phone with the caller. */
.pto-enter-grid select,
.pto-enter-grid .date-entry input.date-entry-text { font-size: 1.15rem; padding: 0.6rem 0.75rem; min-height: 2.8rem; }
.pto-enter-grid .date-entry-calendar { font-size: 1.3rem; padding: 0 0.85rem; }
.pto-enter-grid label { font-size: 1.05rem; }
.pto-enter-grid #bid-roster-entry { width: 100%; text-overflow: ellipsis; }
.pto-enter-grid #pass-round-select { min-height: 2.4rem; padding: 0.35rem 0.6rem; font-size: 1rem; }
.public-name-label { display: flex; flex-direction: column; gap: 0.25rem; margin-bottom: 0.5rem; }
/* Public "Check My Dates" popup: bigger name drop-down and date boxes - used by people who don't
   do this every day, often on a phone. */
.public-check-modal select,
.public-check-modal .date-entry input.date-entry-text { font-size: 1.15rem; padding: 0.65rem 0.75rem; min-height: 2.9rem; }
.public-check-modal .date-entry-calendar { font-size: 1.3rem; padding: 0 0.85rem; }
.public-check-modal label { font-size: 1.05rem; }
.modal-footer-center { display: flex; justify-content: center; margin-top: 1rem; }
.big-close-button {
    min-width: 12rem; padding: 0.8rem 2rem; font-size: 1.15rem; font-weight: 800;
    background: var(--badge); color: #fff; border: none; border-radius: 0.5rem; cursor: pointer;
}
.big-close-button:hover { filter: brightness(1.15); }

/* Rules button + modal */
.rules-button, .fit-screen-button {
    flex-shrink: 0;
    background: var(--orange);
    color: #1a1a1a;
    border: none;
    font-weight: 700;
    padding: 0.45rem 1rem;
    border-radius: 0.375rem;
    cursor: pointer;
}
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
    padding: 1.5rem;
}
.modal {
    background: var(--modal);
    color: var(--text);
    border: 1px solid var(--border-soft);
    border-radius: 0.5rem;
    padding: 1.5rem 1.75rem;
    max-width: 640px;
    width: 100%;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
}
.modal h2 { margin-top: 0; color: var(--text); }
.modal-close {
    position: absolute;
    top: 0.75rem;
    right: 0.9rem;
    background: none;
    border: none;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    color: var(--text-faint);
}
.modal-close:hover { color: white; }
.rule-note { margin-bottom: 1.1rem; }
.rule-note h3 { margin: 0 0 0.3rem; font-size: 1rem; color: var(--info); }
.rule-note p { margin: 0; font-size: 0.9rem; color: var(--text-muted); }

.info-sub { color: var(--text-faint); font-size: 0.8rem; }
.info-empty { color: #8a8d90; }

/* Recent Bids bar (full width) + Progress card, side by side */
.status-strip-row { display: flex; gap: 1rem; margin-bottom: 0.75rem; align-items: stretch; flex-wrap: wrap; }
.recent-bids-bar {
    flex: 3;
    min-width: 260px;
    background: var(--card);
    border-radius: 0.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
    padding: 0.75rem 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text);
}
.recent-bids-label {
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.04em;
    color: var(--text-faint);
    font-weight: 700;
    white-space: nowrap;
}
.progress-card {
    flex: 1;
    min-width: 220px;
    background: var(--card);
    border-radius: 0.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
    padding: 0.75rem 1rem;
}
.progress-label { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-muted); margin-bottom: 0.4rem; }
.progress-bar-track { background: var(--border-soft); border-radius: 999px; height: 0.6rem; overflow: hidden; }
.progress-bar-fill { background: var(--success-dark); height: 100%; border-radius: 999px; transition: width 0.4s ease; }
.progress-text { font-size: 0.8rem; color: var(--text-muted); margin-top: 0.35rem; }

/* Holidays */
.holidays-row { display: flex; gap: 1rem; margin-top: 1rem; flex-wrap: wrap; }
.holiday-card {
    flex: 1;
    min-width: 200px;
    background: var(--accent);
    color: white;
    border-radius: 0.5rem;
    padding: 0.9rem 1.1rem;
    text-align: center;
}
.holiday-card h4 { margin: 0; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.05em; color: #ffd27a; }
.holiday-team { font-weight: 700; font-size: 1.1rem; margin: 0.3rem 0; }
.holiday-list { font-size: 0.95rem; line-height: 1.45; color: #d6dee6; }

/* PTO Bid calendar */
.pto-calendar-scroll { max-height: 70vh; border: 1px solid var(--border-soft); border-radius: 0.375rem; }
.pto-calendar-table td { white-space: nowrap; }
.pto-sold-out { color: var(--danger); font-weight: 700; }
.pto-avail { color: var(--success); font-weight: 700; }

/* PTO Bid console - track/round tabs + check dates */
.track-tabs { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0.5rem 0; }
.track-tab {
    display: inline-block;
    appearance: none;
    font: inherit;
    padding: 0.35rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--row);
    color: var(--text);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}
.track-tab.active { background: var(--badge); color: #fff; border-color: var(--badge); }
.track-tab.disabled { opacity: 0.4; cursor: not-allowed; }
.round-tabs { display: flex; gap: 0.4rem; margin: 0.25rem 0 0.75rem; }
.round-tab { border-radius: 0.375rem; }

/* Public PTO board - team switcher row */
.board-team-tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    background: var(--card);
    padding: 0.75rem 1rem;
}
.board-team-tabs .track-tab { padding: 0.45rem 1rem; font-size: 0.9rem; }

.check-dates-panel {
    margin-top: 0.6rem;
    padding: 0.65rem 1rem;
    border-radius: 0.375rem;
    border: 1px solid var(--border-soft);
    background: var(--row);
    font-size: 0.9rem;
}
.check-dates-panel div { margin: 0.15rem 0; }
.check-dates-ok { background: #1c4d2e; border-color: var(--success-dark); color: #c2f5d6; }
.check-dates-headline { font-size: 1.25rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; color: #fff; }
.check-dates-emphasis { font-size: 1.05rem; font-weight: 700; color: #fff; }
.check-dates-conflict { background: #4d1f1c; border-color: var(--danger-dark); color: #f5c6c2; }

.bid-button:disabled { background: #4a4d50; color: #9a9da0; cursor: not-allowed; }
@keyframes blink-green-anim {
    0%, 100% { box-shadow: 0 0 0 0 rgba(46, 204, 113, 0.6); }
    50% { box-shadow: 0 0 0 7px rgba(46, 204, 113, 0); }
}
.bid-button.blink-green { animation: blink-green-anim 0.7s ease-in-out 3; }

/* PTO Setup - per-track settings/import */
.track-detail { border: 1px solid var(--border-soft); border-radius: 0.375rem; margin-bottom: 0.6rem; padding: 0.5rem 0.9rem; background: var(--row); }
.track-detail summary { cursor: pointer; font-weight: 600; color: var(--text); padding: 0.3rem 0; }
.track-detail-body { display: flex; flex-wrap: wrap; gap: 1.5rem; padding-top: 0.5rem; }
.track-detail-body form { flex: 1; min-width: 260px; }
.track-detail-roster { margin-top: 1rem; padding-top: 0.75rem; border-top: 1px solid var(--border-soft); }
.track-detail-roster h3 { margin: 0 0 0.5rem; font-size: 0.95rem; color: var(--text); }
.pto-booking-chip {
    display: inline-flex; align-items: center; gap: 0.3rem;
    background: var(--row); border-radius: 4px; padding: 0.15rem 0.4rem; margin: 0.1rem 0.2rem 0.1rem 0;
    font-size: 0.85rem;
}
.pto-booking-chip .clear-button { padding: 0.1rem 0.4rem; font-size: 0.75rem; }

/* PTO Console - PTO days stat boxes */
.pto-stat-boxes { display: flex; gap: 0.5rem; margin: 0.5rem 0; }
.pto-stat-boxes[hidden] { display: none; }
.pto-stat-box {
    flex: 1; text-align: center; background: var(--row); border: 1px solid var(--border-soft);
    border-radius: 0.375rem; padding: 0.4rem 0.3rem;
}
.pto-stat-value { font-size: 1.05rem; font-weight: 700; color: var(--text); }
.pto-stat-label { font-size: 0.62rem; color: var(--text-faint); text-transform: uppercase; letter-spacing: 0.03em; }
/* Days Left levels (ptobid days_left.js / pto_levels.py): yellow at 3 or fewer, red at 1 or fewer */
.pto-stat-box.pto-stat-warn { background: #4d4519; border-color: #f1c40f; }
.pto-stat-box.pto-stat-warn .pto-stat-value { color: #f7dc6f; }
.pto-stat-box.pto-stat-danger { background: #4d1f1c; border-color: var(--danger); }
.pto-stat-box.pto-stat-danger .pto-stat-value { color: #f1948a; }
.roster-table td.days-left-cell { font-weight: 700; text-align: center; }
.roster-table td.days-left-warn { background: #f1c40f !important; color: #1a1a1a; }
.roster-table td.days-left-danger { background: #c0392b !important; color: #fff; }

.pass-inline-row { display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; margin: 0.75rem 0; }
.pass-inline-row .hint { margin: 0; flex: 1; min-width: 180px; }
.pass-inline-row select { padding: 0.45rem; border: 1px solid var(--border-soft); border-radius: 0.375rem; }

.pto-bidder-table th { text-align: center; }
.pto-bidder-table th, .pto-bidder-table td { font-size: 0.82rem; padding: 0.32rem 0.4rem; }

/* PTO booking confirmation popup */
.pto-popup-overlay {
    position: fixed; inset: 0; z-index: 1000;
    display: flex; align-items: center; justify-content: center;
    background: rgba(0, 0, 0, 0.65);
    animation: pto-popup-fade-in 0.2s ease-out;
}
.pto-popup-overlay[hidden] { display: none; }
.pto-popup-box {
    background: var(--card); border-top: 4px solid var(--success-dark); border-radius: 0.5rem;
    padding: 2.25rem 2.75rem; width: 90%; max-width: 560px;
    text-align: center; box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
}
.pto-popup-box h2 { margin: 0 0 0.9rem; color: var(--success); font-size: 1.5rem; }
.pto-popup-box p { margin: 0.55rem 0; font-size: 1.15rem; color: var(--text); }
.pto-popup-name { font-size: 1.3rem; font-weight: 700; color: white; }
.pto-popup-dates { font-weight: 700; white-space: nowrap; }
@keyframes pto-popup-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

.pto-chip {
    display: inline-block;
    padding: 0.1rem 0.4rem;
    border-radius: 4px;
    font-size: 0.8rem;
    margin: 0.1rem 0.2rem 0.1rem 0;
    white-space: nowrap;
}
.pto-chip-1 { background: #1c3a4d; color: #b8e2f5; }
.pto-chip-2 { background: #1c4d2e; color: #c2f5d6; }
.pto-chip-3 { background: #4d3319; color: #f8cfa0; }
.pto-chip-4 { background: #3d2550; color: #e2c2f5; }
.pto-chip-5 { background: #4d1f1c; color: #f5c6c2; }
.pto-chip-6 { background: #164540; color: #b2efe5; }

/* PTO print schedule - one column per team, copy/paste into Word */
.print-schedule-table { width: 100%; border-collapse: collapse; margin-top: 1rem; }
.print-schedule-table th, .print-schedule-table td {
    border: 1px solid var(--border); padding: 0.4rem 0.6rem; text-align: left; font-size: 0.9rem;
}
.print-team-header { text-align: center; color: white; }
.print-team-header:nth-of-type(1) { background: var(--team-a); }
.print-team-header:nth-of-type(2) { background: var(--team-b); }
.print-team-header:nth-of-type(3) { background: var(--team-c); }

/* PTO team phone sheet */
.team-sheet-table .phone-input { width: 100%; padding: 0.3rem; border: 1px solid var(--border-soft); border-radius: 0.375rem; }
.team-sheet-table .pick-cell { font-weight: 600; color: var(--text); }

/* Shift Bid results print sheet - one consolidated table, sized to fit a single printed page */
.print-page-actions { display: flex; gap: 0.75rem; margin-bottom: 1rem; }
.print-title { font-size: 1.1rem; margin: 0 0 0.5rem; }
.results-print-table { width: 100%; border-collapse: collapse; }
.results-print-table th, .results-print-table td {
    border: 1px solid var(--border); padding: 0.2rem 0.5rem; text-align: left; font-size: 0.8rem;
}
.results-print-table thead th { text-align: center; font-weight: 700; }
.results-print-station-row th { background: #1e3a6e; color: white; text-align: left; font-size: 0.85rem; }
.results-print-role { white-space: nowrap; }

@media print {
    :root {
        --bg: #ffffff; --card: #ffffff; --row: #f2f5fa; --border: #c9d2e0; --border-soft: #c9d2e0;
        --text: #1a1a1a; --text-muted: #333333; --text-faint: #555555;
    }
    .topnav, .site-footer, .print-page-actions, .back-button { display: none !important; }
    body { background: white; }
    .console-section, .auth-form { box-shadow: none; }
    .console.print-page { max-width: none; margin: 0; padding: 0; }
    .results-print-table { page-break-inside: avoid; }
    @page { size: letter landscape; margin: 0.35in; }
}

/* New-bid setup wizard (Shift Bid + PTO Bid) - one question per step, all committed on Create */
.wizard-launch {
    display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
    background: var(--accent); color: white; border-radius: 0.5rem; padding: 1rem 1.25rem; margin-bottom: 1.25rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}
.wizard-launch h2 { margin: 0 0 0.25rem; font-size: 1.1rem; color: white; }
.wizard-launch p { margin: 0; font-size: 0.85rem; color: #d6dee6; }
.wizard-launch a {
    background: var(--success-dark); color: white; font-weight: 700; text-decoration: none;
    padding: 0.65rem 1.4rem; border-radius: 0.375rem; white-space: nowrap;
}
.wizard-launch a:hover { background: var(--success); }

.wizard { max-width: 760px; margin: 0 auto; }
.wizard-progress { display: flex; gap: 0.35rem; margin-bottom: 1rem; }
.wizard-progress span { flex: 1; height: 6px; border-radius: 3px; background: var(--border-soft); }
.wizard-progress span.done { background: var(--badge); }
.wizard-step-count { font-size: 0.8rem; color: var(--text-faint); margin: 0 0 0.25rem; }
.wizard-step { display: none; }
.wizard-step.active { display: block; }
.wizard-step h2 { font-size: 1.35rem; margin-bottom: 0.5rem; }
.wizard-step h3 { font-size: 0.95rem; color: var(--info); margin: 1.25rem 0 0.5rem; }
.wizard-field { display: flex; flex-direction: column; gap: 0.3rem; font-size: 0.9rem; color: var(--text-muted); font-weight: 600; margin-bottom: 0.9rem; }
.wizard-field input, .wizard-field select, .wizard-field textarea {
    padding: 0.55rem; border: 1px solid var(--border-soft); border-radius: 0.375rem; font-size: 1rem; font-family: inherit;
    font-weight: normal; max-width: 100%; box-sizing: border-box;
}
.wizard-field input.wizard-big { font-size: 1.4rem; max-width: 10rem; }
.wizard-field .field-error { color: var(--danger); font-size: 0.85rem; }
.wizard-row { display: flex; gap: 1rem; flex-wrap: wrap; }
.wizard-row .wizard-field { flex: 1; min-width: 160px; }
.wizard-choices { list-style: none; margin: 0; padding: 0; border: 1px solid var(--border-soft); border-radius: 0.375rem; background: var(--card); }
.wizard-choices li { border-bottom: 1px solid var(--border-soft); }
.wizard-choices li:last-child { border-bottom: none; }
.wizard-choices label { display: flex; gap: 0.6rem; align-items: flex-start; padding: 0.6rem 0.75rem; cursor: pointer; }
.wizard-choices label:hover { background: var(--row); }
.wizard-choices input[type="checkbox"], .wizard-choices input[type="radio"] { margin-top: 0.2rem; }
.wizard-choices small { display: block; color: var(--text-faint); }
.wizard-new-rule { display: grid; grid-template-columns: 1fr 1fr 1fr auto; gap: 0.5rem; margin-bottom: 0.5rem; }
.wizard-new-rule input, .wizard-new-rule select { padding: 0.45rem; border: 1px solid var(--border-soft); border-radius: 0.375rem; min-width: 0; }
.wizard-nav { display: flex; justify-content: space-between; gap: 0.75rem; margin-top: 1.5rem; }
.wizard-nav button, .wizard-yes-no button {
    border: none; padding: 0.7rem 1.6rem; border-radius: 0.375rem; cursor: pointer; font-size: 1rem; font-weight: 700;
}
.wizard-next, .wizard-yes { background: var(--badge); color: white; }
.wizard-back, .wizard-no { background: var(--secondary); color: white; }
.wizard-create { background: var(--success-dark); color: white; }
.wizard-yes-no { display: flex; gap: 1rem; margin-top: 1.25rem; }
.wizard-yes-no button, .wizard-yes-no a {
    min-width: 8rem; font-size: 1.1rem; font-weight: 700; text-align: center; text-decoration: none;
    padding: 0.7rem 1.6rem; border-radius: 0.375rem; box-sizing: border-box;
}
.wizard-review { list-style: none; margin: 0; padding: 0; }
.wizard-review li { padding: 0.5rem 0; border-bottom: 1px solid var(--border-soft); display: flex; gap: 1rem; }
.wizard-review li:last-child { border-bottom: none; }
.wizard-review strong { min-width: 11rem; color: var(--text); }
.wizard-capacity { width: 4.5rem; padding: 0.3rem; border: 1px solid var(--border-soft); border-radius: 0.375rem; margin-left: auto; }
@media (max-width: 600px) {
    .wizard-new-rule { grid-template-columns: 1fr 1fr; }
    .wizard-review li { flex-direction: column; gap: 0.2rem; }
}
