/* ==================== Reset & Base Styles ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Color Palette */
    --bg-primary: #0a0e27;
    --bg-secondary: #151932;
    --bg-card: #1e2139;
    --bg-hover: #252947;

    --sidebar-bg: #0d1117;
    --sidebar-hover: #161b22;

    --text-primary: #ffffff;
    --text-secondary: #8b92a7;
    --text-muted: #5e6c84;

    --accent-primary: #6366f1;
    --accent-hover: #4f46e5;
    --accent-secondary: #10b981;
    --accent-warning: #f59e0b;
    --accent-danger: #ef4444;

    --border-color: #2d3250;
    --border-hover: #3d4464;

    /* Eisenhower Colors */
    --urgent-important: #ef4444;
    --not-urgent-important: #6366f1;
    --urgent-not-important: #f59e0b;
    --not-urgent-not-important: #64748b;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    overflow-x: hidden;
}

/* ==================== App Layout ==================== */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* ==================== Sidebar ==================== */
.sidebar {
    width: 200px;
    background: var(--sidebar-bg);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    z-index: 100;
    transition: width 0.3s ease;
}

/* Collapsed sidebar state */
.sidebar.collapsed {
    width: 60px;
}

.sidebar.collapsed .logo-text,
.sidebar.collapsed .nav-text,
.sidebar.collapsed .google-calendar-section,
.sidebar.collapsed .sidebar-footer {
    display: none;
}

.sidebar.collapsed .sidebar-header {
    padding: 20px 10px;
    justify-content: center;
}

.sidebar.collapsed .logo {
    justify-content: center;
}

.sidebar.collapsed .nav-item {
    justify-content: center;
    padding: 14px;
}

.sidebar.collapsed .nav-icon {
    font-size: 20px;
}

.sidebar.collapsed .sidebar-collapse-btn {
    position: absolute;
    right: -12px;
    top: 50%;
    transform: translateY(-50%) rotate(180deg);
}

.sidebar-collapse-btn {
    display: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 12px;
    font-weight: bold;
    transition: all 0.2s ease;
    position: absolute;
    right: 10px;
}

.sidebar-collapse-btn:hover {
    background: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

/* Show collapse button on desktop */
@media (min-width: 769px) {
    .sidebar-collapse-btn {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .main-content {
        transition: margin-left 0.3s ease;
    }

    .sidebar.collapsed + .main-content,
    body:has(.sidebar.collapsed) .main-content {
        margin-left: 60px;
    }
}

.sidebar-header {
    padding: 20px 16px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Mobile Menu Toggle - Fixed position outside sidebar */
.mobile-menu-toggle {
    display: none;
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 200;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 12px;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.mobile-menu-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text-primary);
    transition: all 0.3s ease;
    border-radius: 2px;
}

.mobile-menu-toggle:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
}

.mobile-menu-toggle:hover span {
    background: var(--accent-primary);
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Sidebar Overlay for Mobile */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 90;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

/* Sidebar Close Button */
.sidebar-close {
    display: none;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 24px;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.sidebar-close:hover {
    background: var(--bg-hover);
    color: var(--accent-primary);
}

.sidebar.collapsed {
    width: 60px;
}

.sidebar.collapsed .logo-text,
.sidebar.collapsed .nav-text,
.sidebar.collapsed .sidebar-btn span:last-child {
    display: none;
}

.sidebar.collapsed + .main-content {
    margin-left: 60px;
}

.logo-icon {
    font-size: 24px;
}

.logo-text {
    font-size: 18px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar-nav {
    flex: 1;
    padding: 12px 8px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow-y: auto;
    min-height: 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: 500;
    text-align: left;
}

.nav-item:hover {
    background: var(--sidebar-hover);
    color: var(--text-primary);
}

.nav-item.active {
    background: var(--accent-primary);
    color: white;
}

.nav-icon {
    font-size: 18px;
}

.sidebar-footer {
    padding: 12px 8px;
    border-top: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sidebar-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 13px;
    font-weight: 500;
}

.sidebar-btn:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
}

/* ==================== Main Content ==================== */
.main-content {
    margin-left: 200px;
    margin-right: 280px;
    flex: 1;
    background: var(--bg-primary);
    min-height: 100vh;
    padding: 24px;
    transition: margin 0.3s ease;
}

/* ==================== Page Header ==================== */
.page-header {
    margin-bottom: 24px;
}

.page-header h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 4px;
}

.page-description {
    color: var(--text-secondary);
    font-size: 14px;
}

/* ==================== Workflow Hint ==================== */
.workflow-hint {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(16, 185, 129, 0.1));
    border: 1px solid var(--border-color);
    border-radius: 10px;
    margin-bottom: 24px;
    font-size: 14px;
    color: var(--text-secondary);
    flex-wrap: wrap;
}

.hint-step {
    width: 24px;
    height: 24px;
    background: var(--accent-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}

.hint-arrow {
    color: var(--accent-primary);
    font-weight: bold;
}

/* ==================== Week Header ==================== */
.week-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 24px;
}

.week-info {
    text-align: center;
    flex: 1;
}

.week-info h2 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 2px;
}

.week-range {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0;
}

/* ==================== Timer Widget ==================== */
.timer-widget {
    position: fixed;
    top: 50%;
    right: 32px;
    transform: translateY(-50%);
    background: var(--bg-card);
    border: 2px solid var(--accent-primary);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    z-index: 200;
    width: 260px;
}

.timer-widget.hidden {
    display: none;
}

.timer-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 50%;
    color: var(--text-secondary);
    font-size: 20px;
    transition: all 0.2s ease;
}

.timer-close:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.timer-task-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    text-align: center;
    margin-bottom: 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.stopwatch-container {
    position: relative;
    width: 180px;
    height: 180px;
    margin: 0 auto 20px;
}

.stopwatch-svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.stopwatch-bg {
    fill: none;
    stroke: var(--bg-secondary);
    stroke-width: 8;
}

.stopwatch-progress {
    fill: none;
    stroke: var(--accent-primary);
    stroke-width: 8;
    stroke-linecap: round;
    stroke-dasharray: 565.48;
    stroke-dashoffset: 565.48;
    transition: stroke-dashoffset 1s linear;
}

.timer-display {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 32px;
    font-weight: 700;
    color: var(--accent-primary);
    font-family: 'Courier New', monospace;
}

.timer-controls {
    display: flex;
    gap: 10px;
}

.timer-controls button {
    flex: 1;
    padding: 10px;
    font-size: 13px;
}

/* ==================== Week Days Container ==================== */
.week-days-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.day-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px 20px;
    transition: all 0.2s ease;
}

.day-card.today {
    border-color: var(--accent-primary);
    background: linear-gradient(135deg, var(--bg-card), rgba(99, 102, 241, 0.1));
}

.day-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.day-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.day-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
}

.day-date {
    font-size: 13px;
    color: var(--text-secondary);
}

.holiday-badge {
    font-size: 12px;
    padding: 4px 10px;
    background: rgba(245, 158, 11, 0.2);
    color: var(--accent-warning);
    border-radius: 12px;
    border: 1px solid var(--accent-warning);
}

.day-task-count {
    font-size: 12px;
    color: var(--text-muted);
    background: var(--bg-secondary);
    padding: 4px 10px;
    border-radius: 10px;
}

.day-tasks-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.day-task-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: var(--bg-secondary);
    border-radius: 8px;
    border-left: 3px solid var(--accent-primary);
    transition: all 0.2s ease;
}

.day-task-item:hover {
    background: var(--bg-hover);
}

.day-task-item.completed {
    opacity: 0.5;
}

.day-task-item.completed .task-text {
    text-decoration: line-through;
}

.day-empty {
    text-align: center;
    padding: 24px;
    color: var(--text-muted);
    font-size: 13px;
}

/* ==================== Floating Add Button ==================== */
.floating-add-btn {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-hover));
    border: none;
    border-radius: 50%;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: all 0.3s ease;
    z-index: 100;
}

.floating-add-btn:hover {
    width: 140px;
    border-radius: 28px;
    box-shadow: 0 6px 28px rgba(99, 102, 241, 0.6);
}

.floating-add-btn .plus-icon {
    font-size: 28px;
    color: white;
    font-weight: 300;
}

.floating-add-btn .btn-text {
    font-size: 14px;
    font-weight: 600;
    color: white;
    opacity: 0;
    max-width: 0;
    overflow: hidden;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.floating-add-btn:hover .btn-text {
    opacity: 1;
    max-width: 80px;
    margin-left: 6px;
}

/* ==================== Modal ==================== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.2s ease;
}

.modal.hidden {
    display: none;
}

.modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    width: 90%;
    max-width: 480px;
    box-shadow: 0 16px 64px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 18px;
    font-weight: 700;
    margin: 0;
}

.modal-close {
    width: 32px;
    height: 32px;
    background: transparent;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 22px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.modal-body {
    padding: 24px;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.form-input,
.form-select {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    transition: all 0.2s ease;
}

.form-input:focus,
.form-select:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: var(--bg-primary);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* ==================== Tab Content ==================== */
.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-content.active {
    display: block;
}

/* ==================== Buttons ==================== */
.btn {
    padding: 10px 18px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-primary {
    background: var(--accent-primary);
    color: white;
}

.btn-primary:hover {
    background: var(--accent-hover);
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-hover);
}

.btn-danger {
    background: var(--accent-danger);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
}

.btn-nav {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    padding: 8px 14px;
}

.btn-nav:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
}

.btn-add {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: var(--accent-secondary);
    color: white;
    font-size: 18px;
    padding: 0;
    justify-content: center;
}

.btn-add:hover {
    background: #059669;
}

/* ==================== Inputs ==================== */
input[type="text"],
input[type="date"],
input[type="number"],
textarea,
select {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 10px 14px;
    color: var(--text-primary);
    font-size: 13px;
    transition: all 0.2s ease;
}

input::placeholder,
textarea::placeholder {
    color: var(--text-muted);
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: var(--bg-card);
}

/* ==================== Tasks & Common Elements ==================== */
.task-checkbox {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: var(--accent-primary);
}

.task-text {
    flex: 1;
    font-size: 14px;
    color: var(--text-primary);
}

.task-duration {
    font-size: 11px;
    color: var(--text-secondary);
    background: rgba(99, 102, 241, 0.2);
    padding: 4px 8px;
    border-radius: 6px;
}

.task-scheduled {
    font-size: 11px;
    color: var(--accent-secondary);
    background: rgba(16, 185, 129, 0.2);
    padding: 4px 8px;
    border-radius: 6px;
}

.task-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.task-meta {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.task-start-btn {
    padding: 6px 12px;
    background: var(--accent-primary);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s ease;
}

.task-start-btn:hover {
    background: var(--accent-hover);
}

.task-delete-btn {
    padding: 4px 10px;
    background: transparent;
    color: var(--text-muted);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 18px;
    transition: all 0.2s ease;
}

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

.delete-btn {
    background: transparent;
    color: var(--text-muted);
    border: none;
    padding: 4px 10px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.2s ease;
}

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

/* ==================== Planner Header ==================== */
.planner-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 24px;
    padding: 16px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
}

.month-display {
    display: flex;
    gap: 8px;
}

.month-select,
.year-select {
    padding: 8px 12px;
    font-size: 14px;
    font-weight: 600;
}

/* ==================== Calendar ==================== */
.calendar {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
}

.calendar-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
    margin-bottom: 12px;
}

.calendar-day-name {
    text-align: center;
    font-weight: 600;
    color: var(--text-secondary);
    padding: 8px;
    font-size: 12px;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    grid-auto-rows: minmax(80px, auto);
    gap: 6px;
    align-items: start;
}

.calendar-day {
    min-height: 80px;
    padding: 8px;
    background: var(--bg-secondary);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    font-size: 13px;
    height: auto;
}

.calendar-day:hover {
    background: var(--bg-hover);
    transform: scale(1.02);
}

.calendar-day.today {
    background: var(--accent-primary);
    color: white;
}

.calendar-day.other-month {
    opacity: 0.3;
}

.calendar-day-number {
    font-weight: 600;
    margin-bottom: 4px;
}

.calendar-day-tasks {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    overflow: visible;
}

.calendar-task {
    font-size: 10px;
    background: var(--bg-primary);
    padding: 3px 6px;
    border-radius: 4px;
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
    border-left: 2px solid var(--accent-primary);
    line-height: 1.3;
}

.calendar-task.completed {
    opacity: 0.5;
    text-decoration: line-through;
}

.calendar-task-more {
    font-size: 10px;
    color: var(--text-muted);
    font-style: italic;
}

/* ==================== Monthly Sections ==================== */
.monthly-sections {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.monthly-goals,
.lessons-section {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
}

.monthly-goals h3,
.lessons-section h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
}

.goal-input-group {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.goal-input {
    flex: 1;
}

.goal-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 300px;
    overflow-y: auto;
}

.goal-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--bg-secondary);
    border-radius: 8px;
    border-left: 3px solid var(--accent-secondary);
}

.goal-item.completed {
    opacity: 0.5;
}

.goal-item.completed .task-text {
    text-decoration: line-through;
}

.empty-list {
    text-align: center;
    color: var(--text-muted);
    padding: 20px;
    font-size: 13px;
}

.lessons-textarea {
    width: 100%;
    min-height: 150px;
    resize: vertical;
    font-family: inherit;
    margin-bottom: 12px;
}

/* ==================== Eisenhower Matrix ==================== */
.eisenhower-matrix {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.matrix-quadrant {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px;
    min-height: 320px;
}

.quadrant-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.quadrant-header h3 {
    font-size: 14px;
    font-weight: 600;
}

.quadrant-action {
    font-size: 11px;
    padding: 4px 10px;
    border-radius: 12px;
    font-weight: 600;
}

.urgent-important {
    border-left: 4px solid var(--urgent-important);
}
.urgent-important .quadrant-action {
    background: rgba(239, 68, 68, 0.2);
    color: var(--urgent-important);
}

.not-urgent-important {
    border-left: 4px solid var(--not-urgent-important);
}
.not-urgent-important .quadrant-action {
    background: rgba(99, 102, 241, 0.2);
    color: var(--not-urgent-important);
}

.urgent-not-important {
    border-left: 4px solid var(--urgent-not-important);
}
.urgent-not-important .quadrant-action {
    background: rgba(245, 158, 11, 0.2);
    color: var(--urgent-not-important);
}

.not-urgent-not-important {
    border-left: 4px solid var(--not-urgent-not-important);
}
.not-urgent-not-important .quadrant-action {
    background: rgba(100, 116, 139, 0.2);
    color: var(--not-urgent-not-important);
}

.matrix-task-input-group {
    display: flex;
    gap: 6px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.matrix-input {
    flex: 2;
    min-width: 100px;
}

.matrix-duration {
    width: 60px;
}

.matrix-schedule {
    width: 120px;
}

.matrix-task-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 280px;
    overflow-y: auto;
}

.matrix-task-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    background: var(--bg-secondary);
    border-radius: 8px;
    transition: all 0.2s ease;
}

.matrix-task-item:hover {
    background: var(--bg-hover);
}

.matrix-task-item.completed {
    opacity: 0.5;
}

.matrix-task-item.completed .task-text {
    text-decoration: line-through;
}

.empty-quadrant {
    text-align: center;
    color: var(--text-muted);
    padding: 30px 10px;
    font-size: 12px;
}

/* ==================== Matrix Stats ==================== */
.matrix-stats {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
}

.matrix-stats h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
}

.stat-card {
    background: var(--bg-secondary);
    padding: 16px;
    border-radius: 10px;
    border-left: 4px solid var(--accent-primary);
}

.stat-card.total {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(16, 185, 129, 0.1));
}

.stat-label {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
}

.stat-detail {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* ==================== Notes ==================== */
.notes-controls {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.note-title-input {
    flex: 1;
}

.notes-container {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 16px;
    min-height: 500px;
}

.notes-sidebar {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 12px;
    overflow-y: auto;
}

.note-item {
    padding: 12px;
    background: var(--bg-secondary);
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.note-item:hover {
    background: var(--bg-hover);
}

.note-item.active {
    background: var(--accent-primary);
    color: white;
}

.note-item-title {
    font-weight: 600;
    font-size: 13px;
    margin-bottom: 4px;
}

.note-item-date {
    font-size: 11px;
    opacity: 0.7;
}

.empty-notes {
    text-align: center;
    color: var(--text-muted);
    padding: 30px 10px;
    font-size: 13px;
}

.notes-editor {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
}

.note-editor-area {
    background: var(--bg-secondary);
    padding: 20px;
    border-radius: 10px;
    min-height: 400px;
}

.note-editor-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 6px;
}

.note-editor-date {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.note-editor-content {
    width: 100%;
    min-height: 300px;
    font-size: 14px;
    line-height: 1.6;
}

.note-actions {
    margin-top: 16px;
    display: flex;
    gap: 10px;
}

.empty-state {
    text-align: center;
    color: var(--text-muted);
    padding: 100px 20px;
    font-size: 14px;
}

/* ==================== Scrollbar ==================== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--border-hover);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-primary);
}

/* ==================== Responsive ==================== */
@media (max-width: 1200px) {
    .eisenhower-matrix {
        grid-template-columns: 1fr;
    }

    .monthly-sections {
        grid-template-columns: 1fr;
    }

    .notes-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    /* Show mobile menu toggle */
    .mobile-menu-toggle {
        display: flex;
    }

    .sidebar-overlay {
        display: block;
    }

    .sidebar-close {
        display: block;
    }

    /* Sidebar slides in from left on mobile */
    .sidebar {
        width: 260px;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

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

    .sidebar.open .logo-text,
    .sidebar.open .nav-text,
    .sidebar.open .sidebar-btn span:last-child {
        display: inline;
    }

    .main-content {
        margin-left: 0;
        padding: 16px;
        padding-top: 70px;
    }

    .logo-text,
    .nav-text {
        display: inline;
    }

    .sidebar-footer {
        padding: 8px 12px;
    }

    .week-header {
        flex-wrap: wrap;
        gap: 10px;
    }

    .workflow-hint {
        font-size: 12px;
        gap: 8px;
    }

    .calendar-day {
        min-height: 60px;
        padding: 4px;
        font-size: 11px;
    }
}

@media (max-width: 480px) {
    .main-content {
        padding: 12px;
    }

    .planner-header {
        flex-direction: column;
        gap: 12px;
    }

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

    .floating-add-btn {
        bottom: 20px;
        right: 20px;
        width: 52px;
        height: 52px;
    }
}

/* ===== GOOGLE CALENDAR INTEGRATION ===== */

.google-calendar-section {
    padding: 16px;
    border-top: 1px solid var(--border-color);
    margin-top: auto;
}

.google-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    margin-bottom: 12px;
    padding: 8px 12px;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.05);
}

.google-status.connected {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
}

.google-status.disconnected {
    background: rgba(108, 117, 125, 0.1);
    color: #6c757d;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
}

.google-btn {
    background: #4285f4;
    color: white;
}

.google-btn:hover {
    background: #3367d6;
}

.google-sync-btn {
    background: #34a853;
    color: white;
    margin-top: 8px;
}

.google-sync-btn:hover {
    background: #2d8f47;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: #333;
    color: white;
    padding: 14px 28px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    z-index: 10000;
    font-size: 14px;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.toast.hidden {
    opacity: 0;
    transform: translateX(-50%) translateY(20px);
    pointer-events: none;
}

.toast.success {
    background: #28a745;
}

.toast.error {
    background: #dc3545;
}

/* Google Settings Modal Styles */
.google-setup-info {
    background: #f8f9fa;
    padding: 16px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.google-setup-info h4 {
    margin: 0 0 12px 0;
    font-size: 14px;
    color: var(--text-dark);
}

.setup-steps {
    margin: 0;
    padding-left: 20px;
    font-size: 13px;
    line-height: 1.8;
    color: var(--text-muted);
}

.setup-steps a {
    color: #4285f4;
    text-decoration: none;
}

.setup-steps a:hover {
    text-decoration: underline;
}

.sync-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 14px;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* ===== DAY/WEEK POPUP MODAL ===== */

.day-week-modal-content {
    max-width: 95vw;
    width: 1200px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.day-week-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.day-week-tabs {
    display: flex;
    gap: 4px;
    background: var(--bg-secondary);
    padding: 4px;
    border-radius: 8px;
}

.view-tab {
    padding: 10px 20px;
    background: transparent;
    border: none;
    border-radius: 6px;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.view-tab:hover {
    color: var(--text-primary);
}

.view-tab.active {
    background: var(--accent-primary);
    color: white;
}

.day-week-title h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
}

.day-week-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.day-week-body {
    flex: 1;
    overflow: auto;
    padding: 0;
}

.day-week-footer {
    display: flex;
    justify-content: space-between;
}

/* ===== DAY VIEW (GANTT CHART) ===== */

.day-view-container {
    padding: 20px;
}

.gantt-header {
    margin-bottom: 10px;
}

.gantt-time-labels {
    display: flex;
    gap: 0;
    margin-left: 0;
}

.gantt-time-label {
    width: 60px;
    font-size: 11px;
    color: var(--text-muted);
    text-align: center;
    flex-shrink: 0;
}

.gantt-chart {
    position: relative;
    min-height: 200px;
    background: var(--bg-secondary);
    border-radius: 8px;
    padding: 10px 0;
    overflow-x: auto;
    margin-bottom: 20px;
}

.gantt-empty {
    padding: 40px;
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
}

.gantt-bar {
    position: absolute;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    min-width: 60px;
}

.gantt-bar:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.gantt-bar.completed {
    opacity: 0.5;
}

.gantt-bar-text {
    color: white;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.gantt-bar-duration {
    color: rgba(255, 255, 255, 0.8);
    font-size: 11px;
    margin-left: 8px;
    flex-shrink: 0;
}

.day-task-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.day-task-item-detail {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--bg-secondary);
    border-radius: 10px;
    transition: all 0.2s ease;
}

.day-task-item-detail:hover {
    background: var(--bg-hover);
}

.day-task-item-detail.completed {
    opacity: 0.5;
}

.day-task-item-detail.completed .task-name {
    text-decoration: line-through;
}

.task-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.task-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

.task-meta-row {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.task-time {
    font-size: 12px;
    color: var(--text-secondary);
}

.task-duration-badge {
    font-size: 11px;
    padding: 2px 8px;
    background: rgba(99, 102, 241, 0.2);
    color: var(--accent-primary);
    border-radius: 10px;
}

.quadrant-badge {
    font-size: 10px;
    padding: 2px 8px;
    color: white;
    border-radius: 10px;
    font-weight: 500;
}

.task-actions {
    display: flex;
    gap: 6px;
}

/* ===== WEEK VIEW (GOOGLE CALENDAR STYLE) ===== */

.week-view-container {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.week-view-container.hidden {
    display: none;
}

.week-navigation {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
}

.week-range-label {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.week-calendar-grid {
    display: flex;
    flex: 1;
    overflow: auto;
}

.week-time-column {
    width: 60px;
    flex-shrink: 0;
    border-right: 1px solid var(--border-color);
    padding-top: 50px;
}

.week-time-slot {
    height: 50px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    font-size: 11px;
    color: var(--text-muted);
    padding-top: 4px;
}

.week-days-columns {
    display: flex;
    flex: 1;
}

.week-day-column {
    flex: 1;
    min-width: 120px;
    border-right: 1px solid var(--border-color);
    cursor: pointer;
}

.week-day-column:last-child {
    border-right: none;
}

.week-day-column.today .week-day-header {
    background: var(--accent-primary);
    color: white;
}

.week-day-header {
    height: 50px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 10;
    padding: 0 8px;
}

.week-day-name {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.week-day-date {
    font-size: 16px;
    font-weight: 700;
}

.open-matrix-day-btn {
    position: absolute;
    right: 4px;
    top: 4px;
    width: 24px;
    height: 24px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.week-day-header {
    position: relative;
}

.week-day-header:hover .open-matrix-day-btn {
    opacity: 1;
}

.week-day-tasks-grid {
    position: relative;
    min-height: 850px; /* 17 hours * 50px */
}

.week-time-slot-bg {
    height: 50px;
    border-bottom: 1px solid var(--border-color);
}

.week-time-slot-bg:nth-child(odd) {
    background: var(--bg-secondary);
}

.week-task-block {
    position: absolute;
    left: 4px;
    right: 4px;
    border-radius: 6px;
    padding: 4px 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 5;
}

.week-task-block:hover {
    transform: scale(1.02);
    z-index: 10;
}

.week-task-block.completed {
    opacity: 0.5;
}

.week-task-text {
    display: block;
    color: white;
    font-size: 11px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.week-task-duration {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    font-size: 10px;
}

/* ===== OVERDUE TASK STYLES ===== */

.matrix-task-item.overdue {
    border-left: 3px solid var(--accent-danger);
    background: rgba(239, 68, 68, 0.1);
}

.task-scheduled.overdue {
    background: rgba(239, 68, 68, 0.2);
    color: var(--accent-danger);
}

/* ===== RESPONSIVE ADJUSTMENTS ===== */

@media (max-width: 900px) {
    .day-week-modal-content {
        width: 98vw;
    }

    .week-day-column {
        min-width: 80px;
    }

    .day-week-header {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ===== ENHANCED COUNTDOWN TIMER ===== */

.timer-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    animation: fadeIn 0.3s ease;
    padding: 20px;
    box-sizing: border-box;
}

.timer-modal.hidden {
    display: none;
}

.timer-modal.fullscreen {
    background: var(--bg-primary);
    padding: 0;
}

.timer-modal.fullscreen .timer-modal-content {
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    border-radius: 0;
    border: none;
}

.timer-modal-content {
    background: linear-gradient(145deg, var(--bg-card), var(--bg-secondary));
    border: 1px solid var(--border-color);
    border-radius: 20px;
    width: 100%;
    max-width: 420px;
    max-height: 90vh;
    padding: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: scaleIn 0.3s ease;
    transition: all 0.3s ease;
    overflow-y: auto;
    box-sizing: border-box;
}

.timer-modal-content.overtime {
    background: linear-gradient(145deg, rgba(239, 68, 68, 0.2), var(--bg-secondary));
    border-color: var(--accent-danger);
}

@keyframes scaleIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.timer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.timer-fullscreen-btn,
.timer-close-btn {
    width: 40px;
    height: 40px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.timer-fullscreen-btn:hover,
.timer-close-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
    border-color: var(--accent-primary);
}

.timer-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.timer-task-info {
    text-align: center;
}

.timer-task-icon {
    font-size: 48px;
    display: block;
    margin-bottom: 12px;
    animation: sandClock 2s ease-in-out infinite;
}

@keyframes sandClock {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(10deg); }
    75% { transform: rotate(-10deg); }
}

.timer-task-name {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    max-width: 400px;
    word-wrap: break-word;
}

/* Timer Progress Bar Design */
.timer-progress-container {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
}

.timer-time-display {
    text-align: center;
    margin-bottom: 24px;
}

.countdown-time {
    font-size: 64px;
    font-weight: 700;
    color: var(--accent-primary);
    font-family: 'Courier New', monospace;
    display: block;
    transition: color 0.3s ease;
    line-height: 1;
}

.countdown-time.negative {
    color: var(--accent-danger);
}

.countdown-label {
    font-size: 14px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 8px;
    display: block;
}

.timer-modal-content.overtime .countdown-label {
    color: var(--accent-danger);
}

.timer-progress-bar {
    width: 100%;
    height: 24px;
    background: var(--bg-secondary);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    position: relative;
}

.timer-progress-fill {
    height: 100%;
    width: 100%;
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
    border-radius: 12px;
    transition: width 1s linear;
    position: relative;
}

.timer-progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.15) 50%,
        transparent 100%
    );
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.timer-modal-content.overtime .timer-progress-fill {
    background: linear-gradient(90deg, var(--accent-danger), #f97316);
    animation: pulse-bar 1s ease-in-out infinite;
}

@keyframes pulse-bar {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.timer-progress-markers {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    padding: 0 4px;
}

.timer-progress-markers span {
    font-size: 11px;
    color: var(--text-muted);
}

.timer-controls {
    display: flex;
    gap: 16px;
    justify-content: center;
}

.timer-control-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 2px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 24px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.timer-control-btn:hover {
    transform: scale(1.1);
    border-color: var(--accent-primary);
}

.timer-control-btn.play-pause {
    width: 80px;
    height: 80px;
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
    font-size: 28px;
}

.timer-control-btn.play-pause:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
}

.timer-control-btn.restart {
    font-size: 28px;
}

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

.timer-control-btn.stop:hover {
    background: #dc2626;
    border-color: #dc2626;
}

.play-icon.hidden,
.pause-icon.hidden {
    display: none;
}

.motivation-container {
    text-align: center;
    max-width: 400px;
    padding: 20px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 12px;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.motivation-quote {
    font-size: 16px;
    font-style: italic;
    color: var(--text-primary);
    margin: 0 0 8px 0;
    line-height: 1.5;
    transition: opacity 0.3s ease;
}

.motivation-author {
    font-size: 13px;
    color: var(--text-secondary);
    transition: opacity 0.3s ease;
}

/* Timer icon button on tasks */
.timer-icon-btn {
    width: 32px;
    height: 32px;
    background: rgba(99, 102, 241, 0.2);
    border: none;
    border-radius: 8px;
    color: var(--accent-primary);
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.timer-icon-btn:hover {
    background: var(--accent-primary);
    color: white;
    transform: scale(1.1);
}

/* Matrix task item layout with timer */
.matrix-task-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.matrix-task-item .task-content {
    flex: 1;
    min-width: 0;
}

.matrix-task-item .task-actions {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-shrink: 0;
}

.matrix-task-item .timer-icon-btn {
    width: 28px;
    height: 28px;
    font-size: 14px;
}

.matrix-task-item .delete-btn {
    flex-shrink: 0;
}

/* Fullscreen timer adjustments - NO SCROLL */
.timer-modal.fullscreen .timer-modal-content {
    display: flex;
    flex-direction: column;
    padding: 20px 40px;
    overflow: hidden;
}

.timer-modal.fullscreen .timer-header {
    margin-bottom: 10px;
    flex-shrink: 0;
}

.timer-modal.fullscreen .timer-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    align-items: center;
    gap: 0;
    max-height: calc(100vh - 60px);
    overflow: hidden;
}

.timer-modal.fullscreen .timer-task-info {
    flex-shrink: 0;
}

.timer-modal.fullscreen .timer-task-icon {
    font-size: clamp(32px, 5vh, 64px);
    margin-bottom: 8px;
}

.timer-modal.fullscreen .timer-task-name {
    font-size: clamp(20px, 4vh, 36px);
}

.timer-modal.fullscreen .timer-progress-container {
    max-width: 700px;
    width: 90%;
    flex-shrink: 0;
}

.timer-modal.fullscreen .timer-time-display {
    margin-bottom: 16px;
}

.timer-modal.fullscreen .countdown-time {
    font-size: clamp(48px, 10vh, 120px);
}

.timer-modal.fullscreen .countdown-label {
    font-size: clamp(12px, 2vh, 18px);
}

.timer-modal.fullscreen .timer-progress-bar {
    height: clamp(20px, 3vh, 40px);
    border-radius: 20px;
}

.timer-modal.fullscreen .timer-progress-fill {
    border-radius: 20px;
}

.timer-modal.fullscreen .timer-progress-markers {
    margin-top: 6px;
}

.timer-modal.fullscreen .timer-controls-new {
    flex-shrink: 0;
    gap: 20px;
}

.timer-modal.fullscreen .motivation-container {
    max-width: 700px;
    padding: 16px 24px;
    flex-shrink: 0;
}

.timer-modal.fullscreen .motivation-quote {
    font-size: clamp(14px, 2.5vh, 22px);
    margin-bottom: 8px;
}

.timer-modal.fullscreen .motivation-author {
    font-size: clamp(11px, 1.5vh, 16px);
}

@media (max-width: 600px) {
    .timer-modal-content {
        padding: 20px;
    }

    .timer-progress-container {
        max-width: 100%;
    }

    .countdown-time {
        font-size: 42px;
    }

    .timer-progress-bar {
        height: 18px;
    }

    .timer-task-name {
        font-size: 18px;
    }

    .timer-control-btn {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }

    .timer-control-btn.play-pause {
        width: 70px;
        height: 70px;
        font-size: 24px;
    }
}

/* ==================== Settings Page ==================== */
.settings-container {
    max-width: 800px;
    margin: 0 auto;
}

.settings-section {
    margin-bottom: 32px;
}

.settings-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.settings-icon {
    font-size: 20px;
}

.settings-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
}

.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-color);
    gap: 20px;
}

.setting-item:last-child {
    border-bottom: none;
}

.setting-item.danger {
    background: rgba(239, 68, 68, 0.05);
    margin: 0 -20px;
    padding: 16px 20px;
    border-radius: 0 0 12px 12px;
    border-bottom: none;
}

.setting-info {
    flex: 1;
}

.setting-info label {
    display: block;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.setting-description {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0;
}

.setting-control {
    flex-shrink: 0;
}

.settings-input {
    width: 100%;
    max-width: 400px;
    padding: 10px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    transition: border-color 0.2s ease;
}

.settings-input:focus {
    outline: none;
    border-color: var(--accent-primary);
}

.settings-input::placeholder {
    color: var(--text-muted);
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 26px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 26px;
    transition: all 0.3s ease;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 2px;
    bottom: 2px;
    background: var(--text-secondary);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.toggle-switch input:checked + .toggle-slider {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(22px);
    background: white;
}

/* Settings Status */
.settings-status {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
}

.settings-status.disconnected {
    background: rgba(239, 68, 68, 0.1);
    color: var(--accent-danger);
}

.settings-status.connected {
    background: rgba(16, 185, 129, 0.1);
    color: var(--accent-secondary);
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
}

/* Settings Actions */
.setting-actions {
    display: flex;
    gap: 12px;
    padding-top: 16px;
    margin-top: 8px;
    border-top: 1px solid var(--border-color);
    flex-wrap: wrap;
}

/* Settings Help */
.settings-help {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.settings-help details {
    cursor: pointer;
}

.settings-help summary {
    color: var(--accent-primary);
    font-weight: 500;
    font-size: 14px;
    padding: 8px 0;
}

.settings-help summary:hover {
    text-decoration: underline;
}

.settings-help ol {
    margin: 12px 0 0 20px;
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.8;
}

.settings-help a {
    color: var(--accent-primary);
}

/* Settings responsive */
@media (max-width: 600px) {
    .setting-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .setting-control {
        width: 100%;
    }

    .settings-input {
        max-width: 100%;
    }

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

    .setting-actions .btn {
        width: 100%;
    }
}

/* Calendar Selection Styles */
.calendar-selection-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 300px;
    overflow-y: auto;
    padding: 4px;
}

.calendar-list-empty,
.calendar-list-loading {
    color: var(--text-muted);
    font-size: 14px;
    padding: 12px;
    text-align: center;
}

.calendar-select-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.calendar-select-item:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
}

.calendar-select-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--accent-primary);
    cursor: pointer;
}

.calendar-color-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--cal-color, #6366f1);
    flex-shrink: 0;
}

.calendar-name {
    flex: 1;
    font-size: 14px;
    color: var(--text-primary);
}

/* ==================== Right Schedule Sidebar ==================== */
.schedule-sidebar {
    width: 280px;
    background: var(--bg-card);
    border-left: 1px solid var(--border-color);
    position: fixed;
    right: 0;
    top: 0;
    height: 100vh;
    z-index: 80;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease;
}

.schedule-sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.schedule-toggle-btn {
    display: none;
    position: absolute;
    left: -48px;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-right: none;
    border-radius: 12px 0 0 12px;
    font-size: 20px;
    cursor: pointer;
    box-shadow: -4px 0 12px rgba(0, 0, 0, 0.2);
}

/* Mini Clock */
.mini-clock-section {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: var(--bg-secondary);
    border-radius: 12px;
}

.mini-time-display {
    display: flex;
    flex-direction: column;
}

.mini-digital-time {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.mini-date {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* Current Activity Mini */
.current-activity-mini {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px 16px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(16, 185, 129, 0.15));
    border-radius: 10px;
    border-left: 3px solid var(--accent-primary);
}

.activity-now-label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.activity-now-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

/* Vertical Timeline */
.vertical-timeline {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 300px;
    background: var(--bg-secondary);
    border-radius: 12px;
    overflow: hidden;
}

.timeline-header-bar {
    padding: 10px 14px;
    background: var(--bg-hover);
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.vertical-timeline-scroll {
    flex: 1;
    overflow-y: auto;
    position: relative;
}

.v-timeline-hour {
    display: flex;
    min-height: 60px;
    border-bottom: 1px solid var(--border-color);
    position: relative;
}

.v-timeline-hour.current-hour {
    background: rgba(99, 102, 241, 0.1);
}

.v-hour-label {
    width: 45px;
    padding: 8px 6px;
    font-size: 11px;
    color: var(--text-muted);
    text-align: right;
    flex-shrink: 0;
    border-right: 1px solid var(--border-color);
}

.v-hour-content {
    flex: 1;
    padding: 4px 8px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: relative;
}

.v-timeline-block {
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    color: white;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.v-timeline-block:hover {
    filter: brightness(1.1);
    transform: translateX(2px);
}

.v-timeline-block .block-emoji {
    font-size: 14px;
}

.v-timeline-block .block-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.v-now-line {
    position: absolute;
    left: 45px;
    right: 0;
    height: 2px;
    background: var(--accent-danger);
    z-index: 10;
}

.v-now-line::before {
    content: '';
    position: absolute;
    left: -4px;
    top: -3px;
    width: 8px;
    height: 8px;
    background: var(--accent-danger);
    border-radius: 50%;
}

/* Sidebar Routines List */
.sidebar-routines {
    background: var(--bg-secondary);
    border-radius: 12px;
    overflow: hidden;
}

.sidebar-routines-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    background: var(--bg-hover);
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
}

.btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 16px;
    padding: 4px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.btn-icon:hover {
    background: var(--bg-primary);
}

.sidebar-routines-list {
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 200px;
    overflow-y: auto;
}

.sidebar-routine-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--bg-primary);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.sidebar-routine-item:hover {
    background: var(--bg-hover);
}

.routine-emoji {
    font-size: 18px;
}

.routine-info-mini {
    flex: 1;
    min-width: 0;
}

.routine-name-mini {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.routine-time-mini {
    font-size: 11px;
    color: var(--text-muted);
}

/* ==================== Home Welcome Page ==================== */
.home-welcome {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.welcome-header {
    text-align: center;
    margin-bottom: 32px;
}

.welcome-header h1 {
    font-size: clamp(28px, 5vw, 40px);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.welcome-date {
    font-size: 16px;
    color: var(--text-secondary);
}

.quick-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 32px;
}

.stat-card-home {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
}

.stat-icon {
    font-size: 32px;
}

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.stat-label {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 4px;
}

.upcoming-section {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
}

.upcoming-section h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.upcoming-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.upcoming-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--bg-secondary);
    border-radius: 10px;
    border-left: 3px solid var(--accent-primary);
}

.upcoming-time {
    font-size: 13px;
    font-weight: 600;
    color: var(--accent-primary);
    min-width: 50px;
}

.upcoming-name {
    flex: 1;
    font-size: 14px;
    color: var(--text-primary);
}

.upcoming-type {
    font-size: 11px;
    padding: 4px 10px;
    background: var(--bg-hover);
    border-radius: 12px;
    color: var(--text-muted);
}

.upcoming-empty {
    text-align: center;
    padding: 24px;
    color: var(--text-muted);
}

.quick-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    position: relative;
    z-index: 10;
}

.quick-action-btn {
    flex: 1;
    min-width: 140px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 500;
    pointer-events: auto;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.quick-action-btn:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
    transform: translateY(-2px);
}

.quick-action-btn span:first-child {
    font-size: 28px;
}

/* ==================== Emoji Picker ==================== */
.emoji-picker-mini {
    position: relative;
}

.emoji-selected {
    width: 100%;
    height: 44px;
    font-size: 24px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.emoji-selected:hover {
    border-color: var(--accent-primary);
}

.emoji-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    width: 200px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 8px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 4px;
    z-index: 100;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.emoji-dropdown.hidden {
    display: none;
}

.emoji-dropdown button {
    width: 40px;
    height: 40px;
    font-size: 20px;
    background: var(--bg-secondary);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.emoji-dropdown button:hover {
    background: var(--accent-primary);
    transform: scale(1.1);
}

/* ==================== Routines Management Panel ==================== */
.routines-modal-panel {
    position: fixed;
    top: 0;
    right: 280px;
    width: 350px;
    max-width: calc(100vw - 280px);
    height: 100vh;
    background: var(--bg-card);
    border-left: 1px solid var(--border-color);
    z-index: 500;
    transform: translateX(0);
    transition: transform 0.3s ease;
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.3);
}

.routines-modal-panel.hidden {
    transform: translateX(calc(100% + 280px));
    pointer-events: none;
}

.routines-panel-content {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.routines-panel-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
}

.routines-panel-header h3 {
    flex: 1;
    font-size: 18px;
    font-weight: 600;
    margin: 0;
}

.close-panel-btn {
    width: 36px;
    height: 36px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.close-panel-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.routines-list-full {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Routines Panel */
.routines-panel {
    flex: 1;
    max-width: 400px;
    min-width: 300px;
}

.routines-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.routines-header h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
}

.routines-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
}

.routine-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.routine-item:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
    transform: translateX(4px);
}

.routine-color {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    flex-shrink: 0;
}

.routine-info {
    flex: 1;
}

.routine-name {
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.routine-time {
    font-size: 12px;
    color: var(--text-secondary);
}

.routine-duration-badge {
    background: var(--bg-secondary);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    color: var(--text-secondary);
}

.routine-legend {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.routine-legend-title {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

/* Color picker grid */
.color-picker-grid {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.color-option {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 3px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.color-option:hover {
    transform: scale(1.15);
}

.color-option.selected {
    border-color: white;
    box-shadow: 0 0 0 2px var(--accent-primary);
}

/* Days picker */
.days-picker {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.day-option {
    width: 44px;
    height: 36px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.day-option:hover {
    border-color: var(--accent-primary);
}

.day-option.selected {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
}

/* ==================== Redesigned Timer Buttons ==================== */
.timer-controls-new {
    display: flex;
    gap: 16px;
    justify-content: center;
    align-items: center;
}

.timer-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px 24px;
    border-radius: 16px;
    border: 2px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 90px;
}

.timer-btn svg {
    width: 28px;
    height: 28px;
}

.timer-btn span {
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.timer-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.timer-btn-primary {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-hover));
    border-color: var(--accent-primary);
    color: white;
    min-width: 120px;
    padding: 20px 32px;
}

.timer-btn-primary svg {
    width: 36px;
    height: 36px;
}

.timer-btn-primary:hover {
    background: linear-gradient(135deg, var(--accent-hover), #4338ca);
}

.timer-btn-restart {
    background: var(--bg-card);
}

.timer-btn-restart:hover {
    border-color: var(--accent-secondary);
    color: var(--accent-secondary);
}

.timer-btn-stop {
    background: rgba(239, 68, 68, 0.1);
    border-color: var(--accent-danger);
    color: var(--accent-danger);
}

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

.timer-btn .btn-label {
    font-size: 13px;
}

.timer-btn .play-label.hidden,
.timer-btn .pause-label.hidden {
    display: none;
}

/* Hide old timer controls */
.timer-controls {
    display: none;
}

/* Fullscreen timer button adjustments */
.timer-modal.fullscreen .timer-btn {
    padding: 24px 36px;
    min-width: 120px;
}

.timer-modal.fullscreen .timer-btn svg {
    width: 40px;
    height: 40px;
}

.timer-modal.fullscreen .timer-btn-primary {
    min-width: 160px;
    padding: 28px 48px;
}

.timer-modal.fullscreen .timer-btn-primary svg {
    width: 52px;
    height: 52px;
}

/* ==================== Comprehensive Mobile Responsive ==================== */
@media (max-width: 1200px) {
    .main-content {
        margin-right: 260px;
    }

    .schedule-sidebar {
        width: 260px;
    }

    .routines-modal-panel {
        right: 260px;
    }

    .routines-modal-panel.hidden {
        transform: translateX(calc(100% + 260px));
    }
}

@media (max-width: 1024px) {
    /* Hide right sidebar on tablet, show toggle button */
    .schedule-sidebar {
        transform: translateX(100%);
        pointer-events: none;
    }

    .schedule-sidebar.open {
        transform: translateX(0);
        pointer-events: auto;
    }

    /* Toggle button should always be clickable */
    .schedule-toggle-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        pointer-events: auto;
    }

    .main-content {
        margin-right: 0;
    }

    .routines-modal-panel {
        right: 0;
        width: 100%;
        max-width: 380px;
    }

    .routines-modal-panel.hidden {
        transform: translateX(100%);
        pointer-events: none;
    }
}

@media (max-width: 768px) {
    /* Mobile layout */
    .main-content {
        margin-left: 0;
        margin-right: 0;
        padding: 16px;
        padding-bottom: 80px;
    }

    .sidebar {
        transform: translateX(-100%);
        pointer-events: none;
    }

    .sidebar.open {
        transform: translateX(0);
        pointer-events: auto;
    }

    .mobile-menu-toggle {
        display: flex;
        pointer-events: auto;
    }

    /* Home page mobile */
    .home-welcome {
        padding: 10px;
    }

    .welcome-header h1 {
        font-size: 24px;
    }

    .quick-stats {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .stat-card-home {
        padding: 16px;
    }

    .stat-number {
        font-size: 24px;
    }

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

    .quick-action-btn {
        flex-direction: row;
        justify-content: center;
        padding: 16px;
    }

    .quick-action-btn span:first-child {
        font-size: 24px;
    }

    /* Schedule sidebar mobile */
    .schedule-sidebar {
        width: 100%;
        max-width: 320px;
    }

    .schedule-toggle-btn {
        left: -52px;
    }

    /* Eisenhower matrix mobile */
    .eisenhower-matrix {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .matrix-quadrant {
        padding: 16px;
    }

    .workflow-hint {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }

    .hint-arrow {
        transform: rotate(90deg);
    }

    /* Calendar mobile */
    .planner-header {
        flex-wrap: wrap;
        gap: 10px;
    }

    .calendar {
        font-size: 12px;
    }

    .calendar-day {
        min-height: 60px;
        padding: 4px;
    }

    .month-display {
        flex-wrap: wrap;
        gap: 8px;
    }

    /* Timer mobile */
    .timer-modal-content {
        padding: 20px;
    }

    .timer-btn {
        padding: 12px 16px;
        min-width: 70px;
    }

    .timer-btn svg {
        width: 24px;
        height: 24px;
    }

    .timer-btn-primary {
        min-width: 100px;
        padding: 16px 24px;
    }

    /* Notes mobile */
    .notes-container {
        flex-direction: column;
    }

    .notes-sidebar {
        max-height: 200px;
        width: 100%;
    }

    /* Settings mobile */
    .settings-container {
        padding: 0;
    }

    .setting-item {
        flex-direction: column;
        gap: 12px;
    }

    .setting-control {
        width: 100%;
    }

    .settings-input {
        width: 100%;
    }

    /* Floating button mobile */
    .floating-add-btn {
        bottom: 20px;
        right: 20px;
        width: 56px;
        height: 56px;
    }

    .floating-add-btn .btn-text {
        display: none;
    }
}

@media (max-width: 480px) {
    .main-content {
        padding: 12px;
    }

    .page-header h2 {
        font-size: 20px;
    }

    .page-description {
        font-size: 13px;
    }

    .modal-content {
        width: 95%;
        max-width: none;
        padding: 16px;
    }

    .form-row {
        flex-direction: column;
    }

    .btn {
        padding: 10px 16px;
        font-size: 13px;
    }

    /* Stats on very small screens */
    .stat-card-home {
        padding: 12px;
        gap: 12px;
    }

    .stat-icon {
        font-size: 24px;
    }

    .stat-number {
        font-size: 20px;
    }

    /* Vertical timeline mobile */
    .v-hour-label {
        width: 35px;
        font-size: 10px;
    }

    .v-timeline-block {
        font-size: 11px;
        padding: 4px 6px;
    }
}

/* ==================== AI Settings Styles ==================== */
.settings-select {
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--card-bg);
    color: var(--text-primary);
    font-size: 14px;
    min-width: 200px;
    cursor: pointer;
}

.settings-select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.setting-control {
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-icon {
    padding: 8px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
}

.btn-icon:hover {
    background: var(--bg-tertiary);
}

.api-help-content {
    padding: 12px;
    background: var(--bg-secondary);
    border-radius: 8px;
    margin-top: 8px;
}

.api-help-content h4 {
    margin: 0 0 8px 0;
    font-size: 14px;
    color: var(--accent-primary);
}

.api-help-content ol {
    margin: 0 0 16px 0;
    padding-left: 20px;
}

.api-help-content li {
    margin: 4px 0;
    font-size: 13px;
}

.ai-features-preview {
    margin-top: 16px;
    padding: 16px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(139, 92, 246, 0.1) 100%);
    border-radius: 12px;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.ai-features-preview h4 {
    margin: 0 0 12px 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.ai-feature-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.ai-feature-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-secondary);
}

.feature-icon {
    font-size: 16px;
}

/* AI Bid Prediction Styles */
.bid-prediction-card {
    background: linear-gradient(135deg, var(--card-bg) 0%, rgba(99, 102, 241, 0.05) 100%);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    margin-top: 16px;
}

.prediction-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.prediction-score {
    display: flex;
    align-items: center;
    gap: 12px;
}

.score-circle {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 700;
    color: white;
}

.score-circle.high { background: linear-gradient(135deg, #10b981, #059669); }
.score-circle.medium { background: linear-gradient(135deg, #f59e0b, #d97706); }
.score-circle.low { background: linear-gradient(135deg, #ef4444, #dc2626); }

.score-label {
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.prediction-factors {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 16px;
}

.factor-group {
    padding: 12px;
    border-radius: 8px;
    background: var(--bg-secondary);
}

.factor-group h5 {
    margin: 0 0 8px 0;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.factor-group.positive h5 { color: #10b981; }
.factor-group.negative h5 { color: #ef4444; }
.factor-group.neutral h5 { color: #6b7280; }

.factor-group ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.factor-group li {
    font-size: 12px;
    padding: 4px 0;
    color: var(--text-secondary);
}

.prediction-recommendations {
    margin-top: 16px;
    padding: 12px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 8px;
    border-left: 3px solid var(--accent-primary);
}

.prediction-recommendations h5 {
    margin: 0 0 8px 0;
    font-size: 13px;
    color: var(--accent-primary);
}

.prediction-recommendations ul {
    margin: 0;
    padding-left: 16px;
}

.prediction-recommendations li {
    font-size: 12px;
    color: var(--text-secondary);
    margin: 4px 0;
}

/* AI Loading State */
.ai-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 24px;
    color: var(--text-secondary);
}

.ai-loading-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--border-color);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Smart Schedule Preview */
.smart-schedule-preview {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px;
    margin-top: 16px;
}

.schedule-day {
    margin-bottom: 16px;
}

.schedule-day-header {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-color);
}

.schedule-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px;
    border-radius: 6px;
    margin: 4px 0;
    font-size: 13px;
}

.schedule-item.task { background: rgba(99, 102, 241, 0.1); }
.schedule-item.routine { background: rgba(16, 185, 129, 0.1); }
.schedule-item.break { background: rgba(107, 114, 128, 0.1); }

.schedule-time {
    font-weight: 500;
    min-width: 100px;
    color: var(--text-secondary);
}

/* Smart Schedule Modal */
.smart-schedule-modal {
    max-width: 700px;
    max-height: 85vh;
    overflow-y: auto;
}

.smart-schedule-intro {
    text-align: center;
    padding: 20px;
}

.smart-schedule-intro p {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.schedule-options {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: center;
    margin-bottom: 24px;
}

.option-group {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.option-group label {
    color: var(--text-secondary);
}

.option-group select,
.option-group input[type="time"] {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 14px;
}

.schedule-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}

.schedule-header h4 {
    margin: 0;
    font-size: 16px;
}

.utilization-badge {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.schedule-task-name {
    flex: 1;
    font-weight: 500;
}

.priority-indicator {
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    text-transform: uppercase;
}

.priority-indicator.high { background: #ef4444; color: white; }
.priority-indicator.medium { background: #f59e0b; color: white; }
.priority-indicator.low { background: #6b7280; color: white; }

.schedule-suggestions,
.schedule-conflicts {
    margin-top: 16px;
    padding: 12px;
    border-radius: 8px;
}

.schedule-suggestions {
    background: rgba(99, 102, 241, 0.1);
    border-left: 3px solid var(--accent-primary);
}

.schedule-conflicts {
    background: rgba(239, 68, 68, 0.1);
    border-left: 3px solid #ef4444;
}

.schedule-suggestions h5,
.schedule-conflicts h5 {
    margin: 0 0 8px 0;
    font-size: 13px;
}

.schedule-suggestions ul,
.schedule-conflicts ul {
    margin: 0;
    padding-left: 16px;
}

.schedule-suggestions li,
.schedule-conflicts li {
    font-size: 12px;
    color: var(--text-secondary);
    margin: 4px 0;
}

.schedule-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.error-message {
    text-align: center;
    padding: 24px;
    color: #ef4444;
}

.error-message button {
    margin-top: 12px;
}

/* AI Button style */
.quick-action-btn.ai-btn {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.2) 100%);
    border-color: rgba(99, 102, 241, 0.3);
}

.quick-action-btn.ai-btn:hover {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.3) 0%, rgba(139, 92, 246, 0.3) 100%);
    border-color: var(--accent-primary);
}

/* Week view routine blocks */
.week-routine-block {
    z-index: 1;
}

.week-task-block {
    z-index: 2;
}

/* ==================== Bid Chat Sidebar ==================== */
.bid-chat-sidebar {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-top: 20px;
    overflow: hidden;
}

.bid-chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-color);
}

.bid-chat-header h4 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
}

.bid-chat-toggle {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: var(--text-secondary);
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
}

.bid-chat-toggle:hover {
    background: var(--bg-primary);
}

.bid-chat-body {
    display: flex;
    flex-direction: column;
    height: 350px;
    transition: height 0.3s ease;
}

.bid-chat-body.collapsed {
    height: 0;
    overflow: hidden;
}

.bid-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.chat-welcome {
    color: var(--text-secondary);
    font-size: 13px;
}

.chat-welcome p {
    margin: 0 0 12px 0;
}

.suggested-questions {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.suggested-questions li {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.suggested-questions li:hover {
    background: var(--accent-primary);
    color: white;
    border-color: var(--accent-primary);
}

.chat-message {
    display: flex;
    max-width: 85%;
}

.chat-message.user {
    align-self: flex-end;
}

.chat-message.assistant {
    align-self: flex-start;
}

.chat-message-content {
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 13px;
    line-height: 1.5;
    white-space: pre-wrap;
}

.chat-message.user .chat-message-content {
    background: var(--accent-primary);
    color: white;
    border-bottom-right-radius: 4px;
}

.chat-message.assistant .chat-message-content {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border-bottom-left-radius: 4px;
}

.chat-message.thinking .chat-message-content {
    color: var(--text-muted);
    font-style: italic;
}

.thinking-dots {
    animation: pulse 1.5s infinite;
}

.bid-chat-input {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    border-top: 1px solid var(--border-color);
    background: var(--bg-tertiary);
}

.bid-chat-input input {
    flex: 1;
    padding: 10px 14px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 13px;
}

.bid-chat-input input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.bid-chat-input button {
    padding: 10px 16px;
    font-size: 13px;
}

/* ==================== Lead Time Settings ==================== */
.lead-time-settings {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-top: 20px;
    overflow: hidden;
}

.lead-time-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: var(--bg-tertiary);
    cursor: pointer;
}

.lead-time-header h4 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
}

.lead-time-toggle {
    background: none;
    border: none;
    font-size: 12px;
    cursor: pointer;
    color: var(--text-secondary);
}

.lead-time-body {
    padding: 16px;
    transition: all 0.3s ease;
}

.lead-time-body.collapsed {
    display: none;
}

.lead-time-desc {
    margin: 0 0 16px 0;
    font-size: 12px;
    color: var(--text-secondary);
}

.lead-time-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}

.lead-time-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}

.lead-time-item label {
    flex: 1;
    color: var(--text-secondary);
}

.lead-time-item input {
    width: 50px;
    padding: 6px 8px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--bg-primary);
    color: var(--text-primary);
    text-align: center;
    font-size: 13px;
}

/* ==================== ICS Reminder Settings ==================== */
.ics-reminder-settings {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-top: 20px;
    overflow: hidden;
}

.ics-reminder-header {
    padding: 12px 16px;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-color);
}

.ics-reminder-header h4 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
}

.ics-reminder-body {
    padding: 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.ics-reminder-body label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    cursor: pointer;
}

.ics-reminder-body input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--accent-primary);
}

/* ==================== RSVP Button ==================== */
.bid-action-btn.rsvp-btn {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
}

.bid-action-btn.rsvp-btn:hover {
    background: rgba(59, 130, 246, 0.2);
    border-color: #3b82f6;
}

/* ==================== Bid Tracker Layout Adjustments ==================== */
.bid-tracker-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

@media (min-width: 1200px) {
    .bid-tracker-container {
        grid-template-columns: 1fr 350px;
    }

    .bid-chat-sidebar {
        grid-column: 2;
        grid-row: 1 / 4;
        margin-top: 0;
        height: fit-content;
        position: sticky;
        top: 20px;
    }

    .bid-input-section,
    .bids-list-section,
    .bid-deadlines-section,
    .lead-time-settings,
    .ics-reminder-settings {
        grid-column: 1;
    }
}

/* Responsive AI styles */
@media (max-width: 768px) {
    .ai-feature-list {
        grid-template-columns: 1fr;
    }

    .prediction-factors {
        grid-template-columns: 1fr;
    }

    .smart-schedule-modal {
        max-width: 95%;
    }

    .schedule-options {
        flex-direction: column;
        align-items: stretch;
    }

    .option-group {
        justify-content: space-between;
    }

    .lead-time-grid {
        grid-template-columns: 1fr;
    }

    .bid-chat-body {
        height: 280px;
    }
}

/* ==================== UI Improvements ==================== */

/* --- Daily Progress Card --- */
.daily-progress-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px 24px;
    margin-bottom: 24px;
}

.progress-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.progress-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.progress-fraction {
    font-size: 14px;
    color: var(--text-secondary);
}

.daily-progress-bar {
    width: 100%;
    height: 8px;
    background: var(--bg-secondary);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 16px;
}

.daily-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
    border-radius: 4px;
    transition: width 0.4s ease;
}

/* Stat Chips (compact version of stat cards) */
.quick-stats {
    display: flex;
    gap: 12px;
}

.stat-chip {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 8px;
    background: var(--bg-secondary);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.stat-chip .stat-number {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
}

.stat-chip .stat-label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.stat-chip.completed .stat-number { color: var(--accent-secondary); }
.stat-chip.urgent .stat-number { color: var(--accent-danger); }

/* --- Empty state hint --- */
.empty-state-hint {
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.6;
    padding: 12px 0;
}

.empty-state-hint strong {
    color: var(--text-secondary);
}

/* --- Primary Quick Action Button --- */
.quick-action-btn.primary-action {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-hover));
    color: white;
    border-color: var(--accent-primary);
    font-weight: 600;
}

.quick-action-btn.primary-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.3);
}

/* --- Unified Task Input (Eisenhower) --- */
.unified-task-input {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 20px;
}

.unified-input-row {
    display: flex;
    gap: 10px;
    margin-bottom: 12px;
}

.unified-input-row .matrix-input {
    flex: 1;
}

.unified-input-row .matrix-duration {
    width: 80px;
}

.unified-input-row .matrix-schedule {
    width: 160px;
}

.unified-quadrant-row {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.quadrant-pick {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-secondary);
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.quadrant-pick:hover {
    border-color: var(--border-hover);
    color: var(--text-primary);
}

.quadrant-pick.active {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.15);
    color: var(--text-primary);
}

.qp-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}

/* --- Calendar Details/Collapsible Sections --- */
.monthly-details {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    margin-bottom: 12px;
    overflow: hidden;
}

.monthly-details-summary {
    padding: 14px 20px;
    cursor: pointer;
    font-weight: 600;
    font-size: 15px;
    color: var(--text-primary);
    list-style: none;
    display: flex;
    align-items: center;
    gap: 8px;
    user-select: none;
}

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

.monthly-details-summary::before {
    content: '\25B6';
    font-size: 10px;
    color: var(--text-muted);
    transition: transform 0.2s ease;
}

.monthly-details[open] > .monthly-details-summary::before {
    transform: rotate(90deg);
}

.monthly-details .monthly-goals,
.monthly-details .lessons-section {
    padding: 0 20px 16px;
}

/* Today button style */
.btn-today {
    padding: 8px 16px;
    background: transparent;
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    border-radius: 8px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-today:hover {
    background: var(--accent-primary);
    color: white;
}

/* --- Settings Collapsible Sections --- */
.settings-section-details {
    margin-bottom: 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
}

.settings-section-details > .settings-section-title {
    cursor: pointer;
    padding: 16px 20px;
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    list-style: none;
    display: flex;
    align-items: center;
    gap: 8px;
    user-select: none;
}

.settings-section-details > .settings-section-title::-webkit-details-marker {
    display: none;
}

.settings-section-details > .settings-section-title::before {
    content: '\25B6';
    font-size: 10px;
    color: var(--text-muted);
    transition: transform 0.2s ease;
}

.settings-section-details[open] > .settings-section-title::before {
    transform: rotate(90deg);
}

.settings-section-details .settings-card {
    margin: 0 12px 12px;
}

/* --- Notes Empty State --- */
.empty-state-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    text-align: center;
}

.empty-state-icon {
    font-size: 48px;
    color: var(--text-muted);
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state-card .empty-state {
    color: var(--text-secondary);
    font-size: 16px;
    margin-bottom: 8px;
}

.empty-state-card .empty-state-hint {
    max-width: 300px;
}

/* --- Utility classes --- */
.hidden {
    display: none !important;
}

.flex-2 { flex: 2; }
.flex-1 { flex: 1; }
.flex-icon { flex: 0 0 80px; }

/* --- Duplicate Warning Banner --- */
.bid-duplicate-warning {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    margin-bottom: 12px;
    background: rgba(245, 158, 11, 0.12);
    border: 1px solid rgba(245, 158, 11, 0.4);
    border-radius: 8px;
    color: var(--accent-warning);
    font-size: 13px;
    animation: slideDown 0.2s ease;
}

.bid-duplicate-warning.hidden {
    display: none;
}

.warning-icon {
    font-size: 18px;
    flex-shrink: 0;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- Addendum Section (Edit Modal) --- */
.addendum-section {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.addendum-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.addendum-header label {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-primary);
}

.addendum-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.empty-addendum {
    color: var(--text-muted);
    font-size: 13px;
    font-style: italic;
}

.addendum-item {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 10px 14px;
}

.addendum-item-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
}

.addendum-item-header strong {
    font-size: 13px;
    color: var(--accent-primary);
}

.addendum-date {
    font-size: 11px;
    color: var(--text-muted);
    margin-left: auto;
}

.btn-remove-addendum {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 16px;
    padding: 0 4px;
    line-height: 1;
}

.btn-remove-addendum:hover {
    color: var(--accent-danger);
}

.addendum-item-body {
    display: flex;
    flex-direction: column;
    gap: 3px;
    font-size: 13px;
    color: var(--text-secondary);
}

.addendum-new-date {
    color: var(--accent-secondary);
    font-weight: 500;
    font-size: 12px;
}

/* --- Responsive adjustments for unified input --- */
@media (max-width: 768px) {
    .unified-input-row {
        flex-direction: column;
    }

    .unified-input-row .matrix-duration,
    .unified-input-row .matrix-schedule {
        width: 100%;
    }

    .unified-quadrant-row {
        flex-wrap: wrap;
    }

    .quadrant-pick {
        font-size: 12px;
        padding: 5px 10px;
    }

    .quick-stats {
        gap: 8px;
    }

    .stat-chip .stat-number {
        font-size: 18px;
    }
}
