/* ================================================
   Rooster Shyfter-stijl — Weekrooster Grid
   Gebaseerd op het visuele ontwerp van Shyfter
   ================================================ */

/* ── Container ──────────────────────────────── */
.sg-wrapper {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,.08), 0 0 0 1px rgba(0,0,0,.06);
}

.sg-grid {
    display: grid;
    grid-template-columns: 220px repeat(7, minmax(150px, 1fr));
    min-width: 1270px;
}

/* ── Header row (day names) ─────────────────── */
.sg-header-row {
    display: contents;
}

.sg-emp-header {
    grid-column: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: #F8FAFC;
    border-bottom: 2px solid #E5E7EB;
    border-right: 1px solid #E5E7EB;
    position: sticky;
    left: 0;
    z-index: 20;
}

.sg-header-title {
    font-size: 12px;
    font-weight: 600;
    color: #6B7280;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.sg-emp-count {
    background: #E5E7EB;
    color: #374151;
    font-size: 11px;
    font-weight: 600;
    padding: 1px 7px;
    border-radius: 999px;
}

.sg-day-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8px 10px;
    background: #F8FAFC;
    border-bottom: 2px solid #E5E7EB;
    border-right: 1px solid #E5E7EB;
    gap: 4px;
    position: relative;
    min-height: 64px;
}

.sg-day-header.sg-today {
    background: #EFF6FF;
    border-bottom-color: #3B82F6;
}

.sg-day-title {
    font-size: 13px;
    font-weight: 700;
    color: #111827;
}

.sg-today .sg-day-title {
    color: #1D4ED8;
}

.sg-day-num {
    font-weight: 400;
    color: #6B7280;
    font-size: 12px;
}

.sg-day-stats {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.sg-day-sched {
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 999px;
}

.sg-day-sched.sg-ok    { background: #D1FAE5; color: #065F46; }
.sg-day-sched.sg-over  { background: #FEE2E2; color: #B91C1C; }
.sg-day-sched.sg-under { background: #DBEAFE; color: #1E40AF; }

.sg-day-persons {
    font-size: 11px;
    color: #6B7280;
    display: flex;
    align-items: center;
    gap: 2px;
}

.sg-add-btn {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: none;
    background: #E5E7EB;
    color: #374151;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s;
    padding: 0;
}

.sg-add-btn:hover {
    background: #3B82F6;
    color: #fff;
}

/* ── Budget rows ────────────────────────────── */
.sg-budget-row {
    display: contents;
}

.sg-budget-row > .sg-emp-col,
.sg-budget-row > .sg-budget-cell {
    border-bottom: 1px solid #E5E7EB;
}

/* Total budget row */
.sg-budget-row.sg-total-budget-row > .sg-emp-col,
.sg-budget-row.sg-total-budget-row > .sg-budget-cell {
    background: #FFFBEB;
}

/* Dept budget rows */
.sg-budget-row.sg-dept-budget-row > .sg-emp-col,
.sg-budget-row.sg-dept-budget-row > .sg-budget-cell {
    background: #FAFAFA;
}

.sg-budget-emp-col {
    padding: 8px 14px;
    border-right: 1px solid #E5E7EB;
    position: sticky;
    left: 0;
    z-index: 10;
    display: flex;
    flex-direction: column;
    gap: 2px;
    background: inherit;
}

.sg-budget-label-main {
    font-size: 11px;
    font-weight: 700;
    color: #92400E;
    text-transform: uppercase;
    letter-spacing: .4px;
}

.sg-budget-label-dept {
    font-size: 11px;
    font-weight: 600;
    color: #374151;
    display: flex;
    align-items: center;
    gap: 5px;
}

.sg-dept-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.sg-budget-week-total {
    font-size: 10px;
    color: #6B7280;
}

.sg-budget-cell {
    padding: 6px 10px;
    border-right: 1px solid #E5E7EB;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
}

.sg-budget-nums {
    display: flex;
    align-items: baseline;
    gap: 3px;
}

.sg-budget-sched {
    font-size: 12px;
    font-weight: 700;
    color: #111827;
}

.sg-budget-slash {
    font-size: 11px;
    color: #9CA3AF;
}

.sg-budget-norm {
    font-size: 11px;
    color: #6B7280;
}

.sg-budget-bar {
    width: 100%;
    height: 4px;
    background: #E5E7EB;
    border-radius: 2px;
    overflow: hidden;
}

.sg-budget-fill {
    height: 100%;
    border-radius: 2px;
    transition: width .3s;
}

.sg-budget-fill.sg-ok    { background: #10B981; }
.sg-budget-fill.sg-over  { background: #EF4444; }
.sg-budget-fill.sg-under { background: #3B82F6; }

.sg-budget-pct {
    font-size: 10px;
    color: #9CA3AF;
}

/* Small dept budget cells (no bar) */
.sg-dept-budget-cell {
    flex-direction: row;
    gap: 3px;
    justify-content: center;
    align-items: center;
    padding: 4px 8px;
    min-height: 30px;
}

/* ── Group separator ────────────────────────── */
.sg-group-sep {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    padding: 0 16px;
    height: 28px;
    background: #EEF2FF;
    border-top: 1px solid #E0E7FF;
    border-bottom: 1px solid #E0E7FF;
}

.sg-group-sep span {
    font-size: 11px;
    font-weight: 700;
    color: #4F46E5;
    text-transform: uppercase;
    letter-spacing: .6px;
}

/* ── Employee rows ──────────────────────────── */
.sg-emp-row {
    display: contents;
}

.sg-emp-row > .sg-emp-info-col,
.sg-emp-row > .sg-day-cell {
    border-bottom: 1px solid #F3F4F6;
}

.sg-emp-row:hover > .sg-emp-info-col,
.sg-emp-row:hover > .sg-day-cell {
    background: #FAFBFF;
}

/* Employee info sidebar */
.sg-emp-info-col {
    padding: 10px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-right: 1px solid #E5E7EB;
    position: sticky;
    left: 0;
    background: #fff;
    z-index: 10;
    min-height: 72px;
}

.sg-emp-row:hover > .sg-emp-info-col {
    background: #FAFBFF;
}

.sg-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
    letter-spacing: -.5px;
}

.sg-emp-details {
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.sg-emp-name {
    font-size: 13px;
    font-weight: 700;
    color: #111827;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sg-emp-lastname {
    font-weight: 400;
    color: #374151;
}

.sg-emp-func {
    font-size: 11px;
    color: #6B7280;
    margin-top: 1px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Weekly hours badge */
.sg-emp-weekly {
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 999px;
    white-space: nowrap;
    flex-shrink: 0;
}

.sg-hours-ok    { background: #D1FAE5; color: #065F46; }
.sg-hours-over  { background: #FEE2E2; color: #B91C1C; }
.sg-hours-under { background: #DBEAFE; color: #1E40AF; }

/* ── Day cells ──────────────────────────────── */
.sg-day-cell {
    padding: 6px 8px;
    border-right: 1px solid #F3F4F6;
    display: flex;
    flex-direction: column;
    gap: 5px;
    min-height: 72px;
    cursor: pointer;
    transition: background .12s, outline .12s, box-shadow .12s;
    vertical-align: top;
    position: relative;
}

.sg-day-cell:hover {
    background: #F8FAFC !important;
}

.sg-today-cell {
    background: #F0F7FF !important;
}

/* ── Drop target — shown while dragging a shift over a cell ── */
.sg-day-cell.sg-drop-target {
    background: rgba(229, 0, 0, 0.05) !important;
    outline: 2px dashed #E50000;
    outline-offset: -3px;
    box-shadow: inset 0 0 0 6px rgba(229, 0, 0, 0.02);
}

.sg-day-cell.sg-drop-target::before {
    content: "+";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #E50000;
    color: #fff;
    font-size: 26px;
    font-weight: 700;
    line-height: 40px;
    text-align: center;
    pointer-events: none;
    z-index: 10;
    box-shadow: 0 3px 12px rgba(229, 0, 0, 0.35);
    animation: sg-drop-pulse 0.75s ease-in-out infinite;
}

@keyframes sg-drop-pulse {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
        box-shadow: 0 3px 12px rgba(229, 0, 0, 0.35);
    }
    50% {
        transform: translate(-50%, -50%) scale(1.12);
        box-shadow: 0 5px 18px rgba(229, 0, 0, 0.5);
    }
}

/* Shift card while being dragged — subtle fade */
.sg-shift-card.dragging,
.shift-card.dragging {
    opacity: 0.45;
    transform: scale(0.97);
    transition: opacity .1s, transform .1s;
}

.sg-empty-cell::after {
    content: '+';
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    min-height: 40px;
    color: #D1D5DB;
    font-size: 20px;
    font-weight: 300;
    border: 2px dashed #E5E7EB;
    border-radius: 8px;
    transition: all .15s;
}

.sg-empty-cell:hover::after {
    border-color: #3B82F6;
    color: #3B82F6;
    background: #EFF6FF;
}

/* ── Shift cards ────────────────────────────── */
.sg-shift-card {
    border-radius: 8px;
    padding: 7px 9px 0 9px;
    background: var(--dept-bg, #F3F4F6);
    border: 1.5px solid var(--dept-border, #D1D5DB);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: box-shadow .15s, transform .1s;
    user-select: none;
}

.sg-shift-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,.12);
    transform: translateY(-1px);
}

.sg-shift-card.sg-selected {
    box-shadow: 0 0 0 2px var(--dept-border, #3B82F6);
    transform: translateY(-1px);
}

/* Published = solid border, concept = dashed border */
.sg-shift-card.sg-published {
    border-style: solid;
}

.sg-shift-card.sg-concept {
    border-style: dashed;
    opacity: .92;
}

/* Shift card header: time + checkbox */
.sg-shift-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 3px;
}

.sg-shift-time {
    font-size: 13px;
    font-weight: 700;
    color: var(--dept-text, #111827);
    letter-spacing: -.2px;
}

.sg-shift-check {
    width: 14px;
    height: 14px;
    cursor: pointer;
    accent-color: var(--dept-border, #3B82F6);
    flex-shrink: 0;
}

/* Duration + break row */
.sg-shift-duration {
    font-size: 11px;
    color: #6B7280;
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 4px;
}

.sg-dur-icon, .sg-brk-icon {
    font-size: 11px;
}

/* Optional task name */
.sg-shift-task {
    font-size: 10px;
    color: #6B7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
}

/* Department bar at bottom of card */
.sg-shift-dept-bar {
    margin: 0 -9px;
    padding: 2px 9px;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: .3px;
    border-radius: 0 0 7px 7px;
    text-align: left;
    margin-top: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Status code cards */
.sg-status-card {
    background: #F9FAFB;
    border: 1.5px solid #D1D5DB;
    padding: 7px 9px;
    border-radius: 8px;
    cursor: pointer;
}

.sg-shift-time-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.sg-status-badge {
    padding: 1px 6px;
    border-radius: 4px;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .3px;
}

.sg-status-name {
    font-size: 11px;
    color: #374151;
    font-weight: 500;
}

.sg-shift-notes {
    font-size: 10px;
    color: #9CA3AF;
    margin-top: 3px;
    font-style: italic;
}

/* ── Empty state ────────────────────────────── */
.sg-empty-state {
    grid-column: 1 / -1;
    padding: 40px;
    text-align: center;
    color: #9CA3AF;
    font-size: 14px;
}

/* ── Responsive ─────────────────────────────── */
@media (max-width: 900px) {
    .sg-grid {
        grid-template-columns: 180px repeat(7, minmax(130px, 1fr));
        min-width: 1100px;
    }

    .sg-emp-info-col {
        padding: 8px 10px;
        gap: 7px;
    }

    .sg-avatar {
        width: 30px;
        height: 30px;
        font-size: 11px;
    }

    .sg-emp-name {
        font-size: 12px;
    }
}

/* ── Print ──────────────────────────────────── */
/* ================================================
   PRINT — Landscape, strip to names + dates + shift times
   ================================================ */
@media print {
    @page { size: A4 landscape; margin: 8mm; }

    /* Hide everything that isn't the rooster grid or planning table */
    body > *:not(.main-content),
    .sidebar, .header, .mobile-nav, .fab,
    .page-header, .page-actions, .tips-banner,
    .rooster-first-tip, .rooster-overflow-menu, .rooster-overflow-wrapper,
    .budget-banner, #conflictWarnings, .toolbar-indicators,
    .sg-add-btn, .sg-shift-check, .sg-budget-bar, .sg-budget-pct,
    .shift-context-menu, .modal {
        display: none !important;
    }

    .main-content { margin-left: 0 !important; padding: 0 !important; }
    .page { display: none !important; }
    .page.active { display: block !important; padding: 0 !important; }
    body { background: #fff !important; color: #000 !important; }

    /* ── Rooster Shyfter grid ── */
    .sg-wrapper {
        box-shadow: none !important;
        border: none !important;
        border-radius: 0 !important;
        overflow: visible !important;
        background: #fff !important;
    }
    .sg-grid {
        min-width: 0 !important;
        width: 100% !important;
        grid-template-columns: 140px repeat(7, 1fr) !important;
    }
    .sg-emp-header, .sg-day-header {
        background: #fff !important;
        color: #000 !important;
        border-bottom: 1.5px solid #000 !important;
        font-size: 11px !important;
        font-weight: 700 !important;
        padding: 6px 4px !important;
    }
    .sg-emp-info-col {
        background: #fff !important;
        padding: 6px 4px !important;
        border-right: 1px solid #ccc !important;
    }
    .sg-emp-name { font-size: 11px !important; font-weight: 600 !important; color: #000 !important; }
    .sg-emp-lastname { font-weight: 400 !important; }
    .sg-emp-func, .sg-emp-weekly, .sg-avatar {
        display: none !important;
    }
    .sg-day-cell {
        padding: 3px !important;
        border-right: 1px solid #e5e5e5 !important;
        background: #fff !important;
        min-height: 0 !important;
    }
    .sg-today-cell { background: #fff !important; }
    .sg-empty-cell::after { display: none !important; }

    /* Shift cards — minimalist: only time + (optional) department indicator */
    .sg-shift-card {
        border: none !important;
        border-left: 3px solid var(--dept-border, #666) !important;
        background: #fff !important;
        box-shadow: none !important;
        transform: none !important;
        padding: 2px 4px !important;
        margin-bottom: 2px !important;
        border-radius: 2px !important;
        page-break-inside: avoid;
    }
    .sg-shift-header {
        padding: 0 !important;
        margin: 0 !important;
    }
    .sg-shift-time {
        font-size: 11px !important;
        font-weight: 600 !important;
        color: #000 !important;
    }
    .sg-shift-duration,
    .sg-shift-task,
    .sg-shift-dept-bar,
    .sg-shift-notes,
    .sg-partial-badge {
        display: none !important;
    }

    /* Status (ziekte/vakantie) shifts — show shortcode only */
    .sg-status-card {
        background: #fff !important;
        border: 1px dashed #666 !important;
    }
    .sg-status-badge {
        background: #fff !important;
        color: #000 !important;
        border: 1px solid #666 !important;
        padding: 1px 4px !important;
        font-size: 10px !important;
    }
    .sg-status-name { font-size: 10px !important; color: #333 !important; }

    /* Budget/stat rows removed from print */
    .sg-budget-row,
    .sg-dept-row,
    .sg-stats-row { display: none !important; }

    /* ── Planning views (week/excel/timeline) ── */
    .planning-table, .planning-table th, .planning-table td {
        border: 1px solid #000 !important;
        background: #fff !important;
        color: #000 !important;
        font-size: 10px !important;
    }
    .planning-table th { font-weight: 700 !important; padding: 4px !important; }
    .planning-table td { padding: 3px 4px !important; }
    .planning-summary, .day-summary-grid,
    #planningBudgetBanner, .timeline-legend { display: none !important; }

    /* Excel view — keep structure but strip colors */
    .excel-view-container table,
    .excel-view-container th,
    .excel-view-container td {
        border: 1px solid #999 !important;
        font-size: 9px !important;
        padding: 2px 3px !important;
    }

    /* Timeline — let bars print in grayscale */
    .timeline-bar { box-shadow: none !important; border: 1px solid #666 !important; }

    /* Cards: remove chrome */
    .card {
        box-shadow: none !important;
        border: none !important;
        border-radius: 0 !important;
        background: #fff !important;
    }
    .card-header { padding: 4px 0 !important; border-bottom: 1.5px solid #000 !important; }
    .card-header h2 { font-size: 14px !important; font-weight: 700 !important; color: #000 !important; }
    .card-content { padding: 4px 0 !important; }
}

/* ================================================
   DARK MODE — Rooster Shyfter grid
   ================================================ */
[data-theme="dark"] .sg-wrapper {
    background: #1F2937 !important;
    box-shadow: 0 1px 4px rgba(0,0,0,.35), 0 0 0 1px rgba(255,255,255,.05) !important;
}
[data-theme="dark"] .sg-grid { background: transparent !important; }
[data-theme="dark"] .sg-emp-header,
[data-theme="dark"] .sg-day-header {
    background: #111827 !important;
    color: #E5E7EB !important;
    border-bottom-color: rgba(255,255,255,.08) !important;
    border-right-color: rgba(255,255,255,.05) !important;
}
[data-theme="dark"] .sg-day-header-date { color: #9CA3AF !important; }
[data-theme="dark"] .sg-emp-info-col {
    background: #1F2937 !important;
    border-right-color: rgba(255,255,255,.08) !important;
    border-bottom-color: rgba(255,255,255,.06) !important;
}
[data-theme="dark"] .sg-emp-name { color: #F9FAFB !important; }
[data-theme="dark"] .sg-emp-lastname { color: rgba(249,250,251,.7) !important; }
[data-theme="dark"] .sg-emp-func { color: #9CA3AF !important; }
[data-theme="dark"] .sg-day-cell {
    background: #1F2937 !important;
    border-right-color: rgba(255,255,255,.05) !important;
    border-bottom-color: rgba(255,255,255,.05) !important;
}
[data-theme="dark"] .sg-day-cell:hover { background: rgba(255,255,255,.03) !important; }
[data-theme="dark"] .sg-today-cell { background: rgba(229,0,0,.08) !important; }
[data-theme="dark"] .sg-empty-cell::after {
    border-color: rgba(255,255,255,.1) !important;
    color: rgba(255,255,255,.2) !important;
}
[data-theme="dark"] .sg-empty-cell:hover::after {
    background: rgba(59,130,246,.12) !important;
    border-color: #3B82F6 !important;
    color: #93C5FD !important;
}
[data-theme="dark"] .sg-shift-card {
    background: #111827 !important;
    color: #F9FAFB !important;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.06) !important;
}
[data-theme="dark"] .sg-shift-time { color: #F9FAFB !important; }
[data-theme="dark"] .sg-shift-duration,
[data-theme="dark"] .sg-shift-task { color: rgba(255,255,255,.75) !important; }
[data-theme="dark"] .sg-shift-card.sg-concept { opacity: 0.85; }
[data-theme="dark"] .sg-status-card { background: rgba(255,255,255,.04) !important; }
[data-theme="dark"] .sg-status-name { color: #E5E7EB !important; }

/* Totals / budget rows in rooster-shyfter grid (if used) */
[data-theme="dark"] .sg-budget-row,
[data-theme="dark"] .sg-dept-row,
[data-theme="dark"] .sg-stats-row {
    background: #111827 !important;
    color: #E5E7EB !important;
    border-color: rgba(255,255,255,.05) !important;
}

/* Drop-target overlay in dark mode */
[data-theme="dark"] .sg-day-cell.sg-drop-target {
    background: rgba(229,0,0,.12) !important;
    outline-color: #FCA5A5 !important;
}

/* Avatar + Weekly hours pill */
[data-theme="dark"] .sg-avatar {
    box-shadow: 0 0 0 2px #1F2937 !important;
    color: #fff !important;
}
[data-theme="dark"] .sg-emp-weekly {
    background: rgba(255,255,255,.06) !important;
    color: #E5E7EB !important;
    border: 1px solid rgba(255,255,255,.08) !important;
}
[data-theme="dark"] .sg-hours-ok {
    background: rgba(16,185,129,.15) !important;
    color: #6EE7B7 !important;
    border-color: rgba(16,185,129,.25) !important;
}
[data-theme="dark"] .sg-hours-over {
    background: rgba(239,68,68,.15) !important;
    color: #FCA5A5 !important;
    border-color: rgba(239,68,68,.25) !important;
}
[data-theme="dark"] .sg-hours-under {
    background: rgba(59,130,246,.15) !important;
    color: #93C5FD !important;
    border-color: rgba(59,130,246,.25) !important;
}

/* Shift card published/concept distinction */
[data-theme="dark"] .sg-shift-card.sg-published {
    box-shadow: inset 3px 0 0 rgba(16,185,129,.7), inset 0 0 0 1px rgba(255,255,255,.06) !important;
}
[data-theme="dark"] .sg-shift-card.sg-concept {
    box-shadow: inset 3px 0 0 rgba(245,158,11,.7), inset 0 0 0 1px rgba(255,255,255,.06) !important;
    opacity: 0.92;
}
[data-theme="dark"] .sg-shift-card.sg-selected {
    box-shadow: inset 0 0 0 2px #93C5FD, 0 4px 12px rgba(59,130,246,.25) !important;
}

/* Shift card accent elements */
[data-theme="dark"] .sg-shift-dept-bar {
    background: rgba(255,255,255,.04) !important;
    color: #D1D5DB !important;
}
[data-theme="dark"] .sg-dur-icon,
[data-theme="dark"] .sg-brk-icon { color: #9CA3AF !important; }
[data-theme="dark"] .sg-shift-check {
    accent-color: #FCA5A5;
}
[data-theme="dark"] .sg-shift-notes {
    color: rgba(255,255,255,.55) !important;
    background: rgba(255,255,255,.03) !important;
    border-color: rgba(255,255,255,.06) !important;
}

/* Status partial-work badge (sickness with hours worked) */
[data-theme="dark"] .sg-partial-badge {
    background: rgba(245,158,11,.15) !important;
    color: #FCD34D !important;
    border-color: rgba(245,158,11,.3) !important;
}

/* Status badge inside status-card */
[data-theme="dark"] .sg-status-badge {
    color: #fff !important;
    box-shadow: 0 0 0 1px rgba(255,255,255,.1) !important;
}

/* Day header today indicator */
[data-theme="dark"] .sg-day-header.sg-today {
    background: linear-gradient(135deg, rgba(229,0,0,.22), rgba(229,0,0,.12)) !important;
    color: #FCA5A5 !important;
}

/* Empty-state in grid */
[data-theme="dark"] .sg-empty-state {
    color: rgba(255,255,255,.45) !important;
}

/* Group-header rows if any */
[data-theme="dark"] .sg-group-header,
[data-theme="dark"] .sg-func-group {
    background: #111827 !important;
    color: #9CA3AF !important;
    border-color: rgba(255,255,255,.08) !important;
}

/* Scrollbar in dark wrapper */
[data-theme="dark"] .sg-wrapper::-webkit-scrollbar { background: #111827; }
[data-theme="dark"] .sg-wrapper::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,.15);
    border-radius: 4px;
}
[data-theme="dark"] .sg-wrapper::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,.25);
}

/* ================================================
   Rooster overflow menu (⋯ dropdown)
   ================================================ */

.rooster-overflow-menu {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 240px;
    background: #fff;
    border: 1px solid #E5E7EB;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12), 0 2px 6px rgba(15, 23, 42, 0.06);
    padding: 6px;
    z-index: 1000;
    animation: rooster-dropdown-in 0.14s ease-out;
}

@keyframes rooster-dropdown-in {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}

.rooster-overflow-menu .ctx-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 9px 12px;
    border: none;
    background: transparent;
    color: #111827;
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    text-align: left;
    cursor: pointer;
    border-radius: 8px;
    transition: background 0.12s ease;
}

.rooster-overflow-menu .ctx-item:hover {
    background: #F3F4F6;
}

.rooster-overflow-menu .ctx-item .material-icons {
    font-size: 18px;
    color: #6B7280;
    flex-shrink: 0;
}

.rooster-overflow-menu .ctx-divider {
    height: 1px;
    background: #F3F4F6;
    margin: 5px 8px;
}

/* Dismissable first-time tip */
.rooster-first-tip kbd {
    display: inline-block;
    padding: 1px 6px;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
    font-size: 11px;
    font-weight: 600;
    color: #374151;
    background: #fff;
    border: 1px solid #E5E7EB;
    border-radius: 4px;
    box-shadow: 0 1px 0 rgba(0,0,0,0.04);
    line-height: 1.2;
}
