/* ===== TODAY PAGE — SEQUENTIAL TIMER ===== */

/* Day Life Progress Bar */
.timer-daylife-section {
    padding: 0.5rem 1rem;
    margin-bottom: 0.75rem;
}

.timer-daylife-bar-container {
    background: var(--bg-tertiary);
    border-radius: 6px;
    height: 8px;
    overflow: hidden;
    margin-bottom: 4px;
}

.timer-daylife-fill {
    height: 100%;
    border-radius: 6px;
    background: var(--success-color);
    transition: width 0.5s ease, background 0.3s ease;
}

.timer-daylife-fill.warning {
    background: var(--warning-color);
}

.timer-daylife-fill.over {
    background: var(--danger-color);
    animation: timerPulse 1.5s infinite;
}

.timer-daylife-text {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-align: center;
}

/* Controls Bar */
.timer-controls {
    display: flex;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.timer-controls .btn {
    padding: 0.5rem 1rem;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: transform 0.1s ease, opacity 0.15s ease;
}

.timer-controls .btn:active {
    transform: scale(0.95);
}

.timer-controls .btn-start {
    background: var(--success-color);
    color: white;
}

.timer-controls .btn-pause {
    background: var(--warning-color);
    color: #333;
}

.timer-controls .btn-stop {
    background: var(--danger-color);
    color: white;
}

.timer-controls .btn-add {
    background: var(--accent-color);
    color: white;
}

.timer-controls .btn-save-timeline {
    background: var(--primary-color, #6c63ff);
    color: white;
}

.timer-controls .btn-load-timeline {
    background: var(--accent-color);
    color: white;
}

.timer-controls .btn-settings {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

/* Timer Queue */
.timer-queue-container {
    padding: 0 0.75rem 1rem;
}

/* Timer Queue Item — Memorigi primer-card style */
.timer-queue-item {
    display: flex;
    flex-direction: column;
    background: var(--bg-secondary);
    border-radius: 12px;
    border-left: 4px solid var(--timer-type-color, #f97316);
    margin-bottom: 0.5rem;
    padding: 0;
    cursor: default;
    transition: transform 0.15s ease, opacity 0.3s ease, box-shadow 0.15s ease;
    overflow: hidden;
}

.timer-queue-item.active {
    box-shadow: 0 0 0 1px var(--timer-type-color, #f97316), 0 4px 12px rgba(0,0,0,0.2);
    transform: scale(1.01);
}

.timer-queue-item.paused {
    opacity: 0.7;
}

.timer-queue-item.completed {
    opacity: 0.4;
}

.timer-queue-item.timer-dragging {
    opacity: 0.6;
    transform: scale(1.03);
    z-index: 100;
    box-shadow: 0 8px 24px rgba(0,0,0,0.2);
}

.timer-queue-item.timer-non-draggable .timer-drag-handle {
    opacity: 0.2;
    cursor: not-allowed;
}

.timer-queue-item.timer-archiving {
    animation: timerSlideOut 0.8s ease-out forwards;
}

.timer-queue-item.timer-auto-archive::after {
    content: attr(data-archive-countdown);
    position: absolute;
    top: 6px;
    right: 6px;
    background: rgba(0,0,0,0.5);
    color: white;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
}

/* Timer Item Row — flex layout */
.timer-item-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0.875rem;
    position: relative;
}

/* Drag Handle */
.timer-drag-handle {
    color: var(--text-muted);
    font-size: 14px;
    letter-spacing: -3px;
    cursor: grab;
    user-select: none;
    touch-action: none;
    flex-shrink: 0;
    opacity: 0.5;
}

.timer-drag-handle:active {
    cursor: grabbing;
}

/* Item Body */
.timer-item-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.timer-item-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
    white-space: normal;
    word-break: break-word;
    line-height: 1.3;
}

/* Tags row */
.timer-item-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    align-items: center;
}

.timer-event-type-tag {
    text-transform: uppercase;
    font-size: 0.6rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.5px;
}

.timer-duration-tag {
    font-size: 0.65rem;
    color: var(--text-secondary);
}

.timer-link-tag {
    background: rgba(139, 92, 246, 0.15);
    color: #8b5cf6;
}

/* Countdown display */
.timer-item-countdown {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.5px;
}

.timer-queue-item.active .timer-item-countdown {
    color: var(--timer-type-color, #f97316);
}

/* Delete Button */
.timer-delete-btn {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: none;
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    line-height: 1;
    z-index: 2;
    transition: all 0.15s ease;
}

.timer-delete-btn:hover {
    background: var(--danger-color);
    color: white;
}

/* Progress bar */
.timer-item-progress {
    height: 3px;
    background: var(--bg-tertiary);
    overflow: hidden;
}

.timer-item-progress-bar {
    height: 100%;
    border-radius: 0;
    transition: width 1s linear;
}

/* Action Buttons on Items */
.timer-complete-early-btn,
.timer-resume-btn {
    margin: 0 0.875rem 0.75rem;
    padding: 0.5rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    text-align: center;
}

.timer-complete-early-btn {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.timer-resume-btn {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
}

/* Empty State */
.timer-empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-secondary);
}

.timer-empty-icon {
    font-size: 3rem;
    margin-bottom: 0.75rem;
    opacity: 0.5;
}

.timer-empty-state h2,
.timer-empty-state h3 {
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

/* ===== MODALS ===== */

.timer-redistribution-modal,
.timer-notification-modal,
.timer-add-modal,
.timer-settings-modal,
.timer-archive-modal,
.timer-templates-modal,
.timer-timelines-modal,
.timer-task-picker-modal,
.timer-quick-add-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200000;
    padding: 1rem;
    backdrop-filter: blur(4px);
}

.timer-redistribution-content,
.timer-notification-content,
.timer-add-content,
.timer-settings-content,
.timer-archive-content,
.timer-templates-content,
.timer-task-picker-content {
    background: var(--bg-secondary);
    border-radius: 16px;
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    color: var(--text-primary);
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.timer-archive-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
}

.timer-archive-header h2 {
    margin: 0;
    font-size: 1.1rem;
}

.timer-modal-close {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.timer-archive-body {
    padding: 0.75rem 1rem;
    max-height: 60vh;
    overflow-y: auto;
}

.timer-archive-day h3 {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin: 1rem 0 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.timer-archive-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.75rem;
    background: var(--bg-tertiary);
    border-radius: 8px;
    margin-bottom: 0.375rem;
    font-size: 0.85rem;
}

.timer-archive-name {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.timer-archive-type {
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 2px 6px;
    border-radius: 4px;
    flex-shrink: 0;
}

.timer-archive-duration {
    font-size: 0.75rem;
    color: var(--text-secondary);
    flex-shrink: 0;
}

/* Event type colors */
.timer-type-focus { background: rgba(255,107,107,0.2); color: #e74c3c; }
.timer-type-critical { background: rgba(231,76,60,0.2); color: #c0392b; }
.timer-type-refresher { background: rgba(78,205,196,0.2); color: #2ecc71; }
.timer-type-leisure { background: rgba(149,225,211,0.2); color: #1abc9c; }
.timer-type-off-duty { background: rgba(168,216,234,0.2); color: #3498db; }

/* Add Event Modal */
.timer-add-form {
    padding: 1rem 1.25rem;
}

.timer-add-group {
    margin-bottom: 1rem;
}

.timer-add-group label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.timer-add-group select,
.timer-add-group input[type="text"],
.timer-add-group input[type="number"] {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 0.9rem;
    box-sizing: border-box;
}

.timer-add-duration {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 0.5rem;
}

.timer-add-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: var(--bg-tertiary);
    border-radius: 8px;
}

.timer-add-link span {
    flex: 1;
    font-size: 0.85rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.timer-add-actions {
    display: flex;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border-top: 1px solid var(--border-color);
    flex-wrap: wrap;
}

.timer-add-actions .btn {
    flex: 1;
    min-width: 100px;
}

/* Redistribution Modal */
.timer-redistribution-content h2 {
    text-align: center;
    padding: 1rem 1rem 0;
}

.timer-redistribution-time {
    font-size: 1.5rem;
    font-weight: 700;
    text-align: center;
    padding: 0.5rem 1rem;
    color: var(--accent-color);
}

.timer-redistribution-options {
    padding: 0 1.25rem;
}

.timer-redistribution-section h3 {
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.timer-redistribution-select {
    width: 100%;
    padding: 0.6rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-primary);
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    box-sizing: border-box;
}

.timer-redistribution-actions {
    display: flex;
    gap: 0.5rem;
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--border-color);
}

.timer-redistribution-actions .btn {
    flex: 1;
}

/* Notification Modal */
.timer-notification-content {
    text-align: center;
    padding: 2rem;
}

.timer-notification-content h2 {
    margin-bottom: 0.5rem;
}

.timer-notification-countdown {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 1rem 0;
}

/* Settings Modal */
.timer-settings-body {
    padding: 0.5rem 0;
}

.timer-settings-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.875rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
}

.timer-settings-row small {
    color: var(--text-secondary);
    font-size: 0.75rem;
}

.timer-settings-daylife {
    padding: 0.75rem 1.25rem;
    background: var(--bg-tertiary);
}

.timer-daylife-range {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.timer-daylife-range input {
    padding: 0.4rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 0.9rem;
}

/* Toggle */
.timer-toggle {
    width: 48px;
    height: 28px;
    border-radius: 14px;
    background: var(--border-color);
    position: relative;
    cursor: pointer;
    transition: background 0.3s ease;
    flex-shrink: 0;
}

.timer-toggle.active {
    background: var(--success-color);
}

.timer-toggle-handle {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: white;
    position: absolute;
    top: 3px;
    left: 3px;
    transition: transform 0.3s ease;
}

.timer-toggle.active .timer-toggle-handle {
    transform: translateX(20px);
}

/* ===== Task Picker — Memorigi Style ===== */

/* Header */
.tp-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
}

.tp-header-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.2rem;
}

.tp-title {
    font-size: 1rem;
    font-weight: 700;
}

.tp-subtitle {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

/* Search */
.tp-search-wrap {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

.tp-search {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 0.85rem;
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.15s ease;
}

.tp-search:focus {
    border-color: var(--accent-color);
}

/* List */
.timer-task-picker-list {
    max-height: 55vh;
    overflow-y: auto;
    padding: 0.5rem 0.75rem 0.75rem;
}

/* Group */
.tp-group {
    margin-bottom: 0.75rem;
}

.tp-group-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.5rem;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tp-group-icon {
    font-size: 0.85rem;
}

.tp-group-name {
    flex: 1;
}

.tp-group-count {
    background: var(--bg-tertiary);
    padding: 1px 6px;
    border-radius: 10px;
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--text-secondary);
}

.tp-chevron {
    font-size: 0.6rem;
    color: var(--text-muted);
    transition: transform 0.2s ease;
}

.tp-group-header {
    cursor: pointer;
    user-select: none;
}

.tp-group-header:active {
    opacity: 0.7;
}

.tp-group-tasks {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

/* Task Item — primer-card style */
.tp-task-item,
.tp-subtask-item {
    cursor: pointer;
}

.tp-task-card,
.tp-subtask-card {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.75rem;
    background: var(--bg-secondary);
    border-radius: 10px;
    border-left: 4px solid transparent;
    transition: background 0.1s ease, transform 0.1s ease;
}

.tp-task-card:hover,
.tp-subtask-card:hover {
    background: var(--bg-tertiary);
}

.tp-task-card:active,
.tp-subtask-card:active {
    transform: scale(0.98);
}

/* Letter badge */
.tp-letter-badge {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 800;
    flex-shrink: 0;
    color: white;
}

.tp-letter-badge.letter-A { background: #e74c3c; }
.tp-letter-badge.letter-B { background: #f39c12; }
.tp-letter-badge.letter-C { background: #3498db; }
.tp-letter-badge.letter-D { background: var(--text-muted); }
.tp-letter-badge.letter-Starter { background: #f59e0b; }

/* Task name */
.tp-task-name {
    flex: 1;
    min-width: 0;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
    word-break: break-word;
}

/* Tags */
.tp-tag {
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 2px 6px;
    border-radius: 4px;
    flex-shrink: 0;
}

.tp-tag-starter { background: rgba(245,158,11,0.2); color: #f59e0b; }
.tp-tag-repeat { background: rgba(16,185,129,0.2); color: #10b981; }
.tp-tag-subtask { background: rgba(99,102,241,0.15); color: #6366f1; }

/* Subtask indent */
.tp-subtask-card {
    margin-left: 1.5rem;
    border-left: 3px solid var(--border-color);
}

.tp-subtask-indent {
    color: var(--text-muted);
    font-size: 0.8rem;
    flex-shrink: 0;
}

/* Focus Mode */
.timer-focus-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.92);
    z-index: 300000;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.timer-focus-overlay.active {
    display: flex;
}

.timer-focus-container {
    text-align: center;
    color: white;
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    z-index: 300001;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    cursor: default;
}

.timer-focus-container.active {
    display: flex;
}

.timer-focus-name {
    font-size: 1.5rem;
    font-weight: 600;
    opacity: 0.8;
}

.timer-focus-display {
    font-size: 5rem;
    font-weight: 900;
    letter-spacing: 2px;
}

.timer-focus-progress-container {
    width: 300px;
    height: 6px;
    background: rgba(255,255,255,0.2);
    border-radius: 3px;
    overflow: hidden;
}

.timer-focus-progress-bar {
    height: 100%;
    background: white;
    border-radius: 3px;
    transition: width 1s linear;
}

.timer-focus-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
}

.timer-focus-actions .btn {
    padding: 0.6rem 1.5rem;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
}

/* Template Dropdown in Add Event Modal */
.timer-template-dropdown {
    border-top: 1px solid var(--border-color);
    max-height: 200px;
    overflow-y: auto;
}

.timer-template-dropdown-header {
    padding: 0.5rem 1.25rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-secondary);
    letter-spacing: 0.5px;
}

.timer-template-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.25rem;
    cursor: pointer;
    transition: background 0.1s ease;
    font-size: 0.85rem;
}

.timer-template-dropdown-item:hover {
    background: var(--bg-tertiary);
}

.timer-template-dropdown-name {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.timer-template-dropdown-dur {
    font-size: 0.75rem;
    color: var(--text-secondary);
    flex-shrink: 0;
}

/* Info button style */
.btn-info {
    background: var(--primary-color, #6c63ff);
    color: white;
    border: none;
}

/* Success button */
.btn-success,
.btn-sm.btn-success {
    background: var(--success-color);
    color: white;
    border: none;
}

/* Save/Load Timeline modals */
.timer-save-timeline-modal,
.timer-load-timeline-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200000;
    padding: 1rem;
    backdrop-filter: blur(4px);
}

/* Timeline item in load modal */
.timer-timeline-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem;
    background: var(--bg-tertiary);
    border-radius: 10px;
    margin-bottom: 0.5rem;
}

.timer-timeline-item-info {
    flex: 1;
    min-width: 0;
}

.timer-timeline-item-name {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 2px;
}

.timer-timeline-item-meta {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.timer-timeline-item-events {
    display: flex;
    flex-wrap: wrap;
    gap: 3px;
}

.timer-timeline-item-actions {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex-shrink: 0;
}

.timer-timeline-item-actions .btn-sm {
    padding: 4px 10px;
    font-size: 0.7rem;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-weight: 600;
}

/* Animations */
@keyframes timerSlideOut {
    0% { transform: translateX(0); opacity: 1; max-height: 200px; }
    60% { transform: translateX(40px); opacity: 0.3; }
    100% { transform: translateX(100%); opacity: 0; max-height: 0; padding: 0; margin: 0; }
}

@keyframes timerPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

/* Mobile */
@media (max-width: 768px) {
    .timer-item-countdown {
        font-size: 1.2rem;
    }

    .timer-controls {
        padding: 0.5rem 0.75rem;
    }

    .timer-controls .btn {
        padding: 0.4rem 0.75rem;
        font-size: 0.75rem;
    }

    .timer-focus-display {
        font-size: 3.5rem;
    }

    .timer-focus-progress-container {
        width: 250px;
    }

    .timer-add-content,
    .timer-settings-content,
    .timer-archive-content,
    .timer-templates-content,
    .timer-task-picker-content {
        max-width: 100%;
        border-radius: 12px;
    }
}

/* ============================================================================
   Timer feature toggle — Timer mode ↔ Simple Today mode
   Settings > Today Page > Enable Timer Feature
   When OFF, body gets .timer-disabled class: hide timer UI, show simple UI.
   When ON, reverse. Also swaps action-modal labels between "Add to Timeline"
   and "Send to Today".
   ============================================================================ */

/* Default: timer mode — simple-mode-only elements are hidden */
.today-simple-mode-only {
    display: none !important;
}
.today-timer-mode-only {
    display: block;
}

/* Timer disabled: hide timer UI, show simple UI */
body.timer-disabled .today-timer-mode-only {
    display: none !important;
}
body.timer-disabled .today-simple-mode-only {
    display: block !important;
}

/* Action-modal dual labels */
.simple-mode-label {
    display: none;
}
body.timer-disabled .timer-mode-label {
    display: none;
}
body.timer-disabled .simple-mode-label {
    display: inline;
}

/* ---- Simple Today layout ---- */
.today-simple-container {
    display: none; /* controlled by .today-simple-mode-only above */
    padding: 0 0 1rem 0;
}
body.timer-disabled .today-simple-container {
    display: block;
}

.today-simple-list {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding-top: 0.5rem;
}

/* Today simple-mode card — matches the Focus primer-card vocabulary
   (colored left border, pill tag row, subtask progress bar) but with a
   dedicated [Complete] [Back] footer instead of the ⋯ menu. Title wraps
   freely — no ellipsis — same as Focus. */
.today-simple-card {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.85rem;
    padding: 0.85rem 1rem;
    cursor: pointer;
    position: relative;
}

.today-simple-card .drag-handle {
    color: var(--text-muted);
    font-size: 1rem;
    cursor: grab;
    user-select: none;
    align-self: flex-start;
    margin-bottom: -0.25rem;
}

.today-simple-card .primer-card-check {
    align-self: center;
    flex-shrink: 0;
}

.today-simple-card .primer-card-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.today-simple-card .primer-card-title {
    font-weight: 600;
    font-size: 0.98rem;
    color: var(--text-primary);
    line-height: 1.35;
    /* Wrap freely — no ellipsis */
    word-break: break-word;
    overflow-wrap: anywhere;
}

.today-simple-card .primer-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    align-items: center;
}

.today-simple-card .today-simple-context {
    font-size: 0.72rem;
    color: var(--text-muted);
    line-height: 1.3;
    word-break: break-word;
}
/* Parent/group source label sits ABOVE the title — a touch of spacing. */
.today-simple-card .today-simple-parent {
    margin-bottom: 2px;
}

/* Small ghost ↩ button (remove from Highlight) — replaces the old full-width
   footer now that completion is the Focus-style circle on the left. */
.today-simple-back {
    flex-shrink: 0;
    align-self: center;
    margin-left: auto;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary, rgba(255, 255, 255, 0.06));
    color: var(--text-secondary, #a8a8c0);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, transform 0.08s ease-out;
}
.today-simple-back:hover { background: var(--bg-secondary); color: var(--text-primary); }
.today-simple-back:active { transform: scale(0.92); }

/* Footer action row — full-width, right-aligned, sits below the card body */
.today-simple-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
    margin-top: 0.25rem;
    padding-top: 0.5rem;
    border-top: 1px solid var(--border-color, rgba(255, 255, 255, 0.06));
}

.primer-tag-complete {
    background: var(--success-color, #22c55e);
    color: #fff;
    border: none;
    padding: 0.5rem 0.9rem;
    border-radius: 9px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: filter 0.15s, transform 0.08s ease-out;
    min-height: 36px;
}
.primer-tag-complete:hover {
    filter: brightness(1.1);
}
.primer-tag-complete:active {
    transform: scale(0.96);
}

.primer-tag-sendback {
    background: var(--bg-tertiary, #333);
    color: var(--text-primary, #eee);
    border: 1px solid var(--border-color, #444);
    padding: 0.5rem 0.9rem;
    border-radius: 9px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: filter 0.15s, transform 0.08s ease-out;
    min-height: 36px;
}
.primer-tag-sendback:hover {
    filter: brightness(1.2);
}
.primer-tag-sendback:active {
    transform: scale(0.96);
}

.today-simple-bulk-bar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.75rem;
    margin: 0.5rem 0;
    background: var(--bg-secondary);
    border-radius: 10px;
    border: 1px solid var(--border-color, #333);
}

.today-simple-bulk-count {
    flex: 1;
    font-weight: 600;
    color: var(--primary-color, #3b82f6);
    font-size: 0.9rem;
}

.today-simple-card.draggable-card {
    cursor: grab;
}
.today-simple-card.draggable-card:active {
    cursor: grabbing;
}

/* Mobile: wider tap targets on the Complete / Back buttons */
@media (max-width: 640px) {
    .today-simple-card {
        padding: 0.8rem 0.85rem;
    }
    .today-simple-actions .primer-tag-complete,
    .today-simple-actions .primer-tag-sendback {
        flex: 1;
        text-align: center;
        min-height: 40px;
        font-size: 0.88rem;
    }
}

/* ─────────────────────────────────────────────────────────────────────
   2026-05-29 — Highlight page polish. Scoped to body.timer-disabled
   (simple mode) so it never touches the timer view. Gold/star theme to
   match the 🌟 Highlight identity + the gold counter chip.
   ───────────────────────────────────────────────────────────────────── */

/* Header: gold-gradient title + a touch more breathing room */
body.timer-disabled #todayPage .header h1 {
    background: linear-gradient(120deg, #fbbf24, var(--primary-color, #6c63ff));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 0.01em;
}
body.timer-disabled #todayPage .header h1 .icon,
body.timer-disabled #todayPage .header h1 .icon-emoji {
    -webkit-text-fill-color: initial;   /* keep the 🌟 emoji colored */
}
body.timer-disabled #todayPage .page-subtitle.today-simple-mode-only {
    color: var(--text-secondary, #a8a8c0);
}

/* Card: soft gold-tinted gradient, rounded, lift on hover */
body.timer-disabled .today-simple-card {
    background: linear-gradient(135deg, rgba(251,191,36,0.055), var(--bg-secondary) 60%) !important;
    border: 1px solid rgba(251,191,36,0.16) !important;
    border-radius: 14px !important;
    box-shadow: 0 2px 12px rgba(0,0,0,0.28);
    transition: transform 0.16s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
body.timer-disabled .today-simple-card:hover {
    transform: translateY(-2px);
    border-color: rgba(251,191,36,0.38) !important;
    box-shadow: 0 8px 22px rgba(251,191,36,0.12);
}
/* Title a touch larger/bolder so each highlight reads as "important" */
body.timer-disabled .today-simple-card .primer-card-title {
    font-size: 1.02rem;
    font-weight: 700;
}

/* Complete button — richer green gradient + glow */
body.timer-disabled .primer-tag-complete {
    background: linear-gradient(135deg, #22c55e, #16a34a) !important;
    box-shadow: 0 3px 10px rgba(34,197,94,0.28);
    border-radius: 10px !important;
}
body.timer-disabled .primer-tag-complete:hover {
    box-shadow: 0 5px 16px rgba(34,197,94,0.42);
    filter: brightness(1.05);
}
/* Back button — quiet ghost style so Complete is clearly the primary action */
body.timer-disabled .primer-tag-sendback {
    background: transparent !important;
    border: 1px solid var(--border-color, #2a2a2a) !important;
    color: var(--text-secondary, #a8a8c0) !important;
    border-radius: 10px !important;
}
body.timer-disabled .primer-tag-sendback:hover {
    background: var(--bg-tertiary, #242424) !important;
    color: var(--text-primary, #fff) !important;
}

/* Counter chip — a little more presence on the Highlight header */
body.timer-disabled #highlightCounterChip {
    box-shadow: 0 2px 8px rgba(251,191,36,0.30);
}

/* Empty state — warmer, on-theme */
body.timer-disabled .timer-empty-state .timer-empty-icon {
    filter: drop-shadow(0 0 14px rgba(251,191,36,0.45));
}
