/* ==============================
   Planning TDAH - Styles v2
   Refonte visuelle: Inter + JetBrains Mono
   Icons SVG, alignement, polish
   ============================== */

:root {
    --bg: #0d1117;
    --surface: #161b22;
    --surface-alt: #1c2333;
    --text: #e6edf3;
    --text-muted: #7d8590;
    --accent-axia: #4fc3f7;
    --accent-record: #66bb6a;
    --accent-explo: #ffa726;
    --accent-perso: #ef5350;
    --accent-trajet: #ab47bc;
    --accent-attente: #78909c;
    --accent-rituel: #ef5350;
    --now-line: #ff5252;
    --border: rgba(255,255,255,0.08);
    --done: rgba(255,255,255,0.15);
    --radius: 14px;
    --radius-sm: 10px;
    --max-w: 720px;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --mono: 'JetBrains Mono', 'SF Mono', 'Fira Code', monospace;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    padding: 0;
    overflow-x: hidden;
    -webkit-tap-highlight-color: transparent;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.5;
}

/* ===== GLOBAL CONTENT WRAPPER ===== */
#app {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 20px;
}

.content-wrap {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== LOGIN SCREEN ===== */
.login-screen {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
}

.login-screen h1 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
}

.login-screen p {
    color: var(--text-muted);
    margin-bottom: 32px;
}

.pin-input {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
}

.pin-input input {
    width: 52px;
    height: 60px;
    background: var(--surface);
    border: 2px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-size: 24px;
    text-align: center;
    font-family: var(--mono);
    outline: none;
    transition: border-color 0.2s;
}

.pin-input input:focus {
    border-color: var(--accent-axia);
    box-shadow: 0 0 0 3px rgba(79, 195, 247, 0.15);
}

.login-error {
    color: var(--now-line);
    font-size: 14px;
    min-height: 20px;
}

/* ===== HEADER ===== */
.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(13, 17, 23, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    padding: 20px 20px 16px;
    max-width: var(--max-w);
    margin: 0 auto;
}

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

.greeting {
    font-size: 13px;
    color: var(--text-muted);
    letter-spacing: 1.5px;
    text-transform: uppercase;
    font-family: var(--mono);
    font-weight: 400;
}

.date-display {
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -0.5px;
    line-height: 1.3;
}

.week-number {
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 600;
    color: var(--accent-axia);
    background: rgba(79, 195, 247, 0.1);
    padding: 3px 10px;
    border-radius: 20px;
    vertical-align: middle;
    margin-left: 6px;
}

.focus-count {
    display: inline-block;
    background: rgba(79, 195, 247, 0.1);
    color: var(--accent-axia);
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
    margin-top: 6px;
}

.nav-arrows {
    display: flex;
    gap: 6px;
    align-items: center;
}

.nav-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.nav-btn:hover, .nav-btn:active {
    background: var(--surface-alt);
    border-color: rgba(255,255,255,0.15);
}

.today-btn {
    width: auto;
    padding: 0 12px;
    font-size: 11px;
    font-family: var(--mono);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

/* ===== WEATHER STRIP ===== */
.weather-strip {
    display: flex;
    gap: 12px;
    padding: 0 20px 16px;
    overflow-x: auto;
    scrollbar-width: none;
    max-width: var(--max-w);
    margin: 0 auto;
}

.weather-strip::-webkit-scrollbar { display: none; }

.weather-loading {
    font-size: 12px;
    color: var(--text-muted);
    font-family: var(--mono);
    padding: 10px 0;
}

/* Weather V3 cards */
.wc3 {
    flex: 1;
    min-width: 200px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 14px 16px;
    display: flex;
    gap: 12px;
}

.wc3-left { flex: 1; }
.wc3-right { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }

.wc3-city {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.wc3-temp {
    font-size: 28px;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 4px;
}

.wc3-desc {
    font-size: 12px;
    font-weight: 500;
}

.wc3-svg { line-height: 0; }
.w-ico { width: 48px; height: 48px; }
.w-ico-sm { vertical-align: -0.1em; }

.wc3-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 3px;
}

.wc3-meta-item {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
}

.wc3-sun-row {
    display: flex;
    gap: 8px;
    margin-top: 2px;
}

.wc3-sun-item {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 3px;
}

/* Old weather card fallback */
.weather-card {
    flex: 1;
    min-width: 140px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 12px 14px;
}

.weather-city {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.weather-main {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 2px;
}

.weather-icon { font-size: 22px; line-height: 1; }
.weather-temps { font-size: 15px; font-weight: 700; }

.weather-desc {
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.weather-sun {
    display: flex;
    gap: 10px;
    font-size: 11px;
    font-family: var(--mono);
    color: var(--text-muted);
}

/* ===== EPHEMERIDE ===== */
.ephemeride-card {
    max-width: var(--max-w);
    margin: 0 auto 16px;
    padding: 16px 20px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.ephemeride-label {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.ephemeride-date {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 2px;
}

.ephemeride-saint {
    font-size: 13px;
    color: var(--text-muted);
}

.ephemeride-saint strong {
    color: var(--text);
}

.ephemeride-sun {
    display: flex;
    gap: 16px;
    margin-top: 6px;
    font-size: 12px;
    font-family: var(--mono);
    color: var(--text-muted);
}

.ephemeride-sun span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.ephemeride-loading {
    font-size: 12px;
    color: var(--text-muted);
    font-family: var(--mono);
}

/* ===== PROPORTIONAL TIMELINE ===== */
.tl-container {
    position: relative;
    margin: 0 20px 40px 70px;
    max-width: calc(var(--max-w) - 70px);
}

/* Hour markers */
.tl-hour {
    position: absolute;
    left: -50px;
    right: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    pointer-events: none;
    z-index: 1;
}

.tl-hour-label {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--text-muted);
    width: 32px;
    text-align: right;
    flex-shrink: 0;
}

.tl-hour-line {
    flex: 1;
    height: 1px;
    background: var(--border);
}

/* Event positioned absolutely */
.tl-event {
    position: absolute;
    left: 0;
    right: 0;
    z-index: 5;
}

.tl-event .event-card {
    height: 100%;
    overflow: hidden;
}

/* Now indicator */
.tl-now {
    position: absolute;
    left: -50px;
    right: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 20;
    pointer-events: none;
}

.now-dot {
    width: 10px;
    height: 10px;
    min-width: 10px;
    background: var(--now-line);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(255, 82, 82, 0.5);
    animation: pulse 2s infinite;
}

.now-line {
    flex: 1;
    height: 2px;
    background: linear-gradient(90deg, var(--now-line), transparent);
}

.now-time {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--now-line);
    font-weight: 600;
    white-space: nowrap;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.4); }
}

/* ===== COMPACT EVENT ===== */
.event-card.compact {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 6px 16px;
}

.event-card.compact .event-header {
    margin-bottom: 0;
}

.event-title-inline {
    font-size: 13px;
    font-weight: 600;
    margin-left: 4px;
}

/* ===== EVENT CARD ===== */
.event-card {
    flex: 1;
    border-radius: var(--radius);
    padding: 14px 16px;
    position: relative;
    overflow: hidden;
    transition: all 0.2s ease;
    cursor: default;
    border: 1px solid transparent;
}

.event-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
}

.event-card:active {
    transform: scale(0.98);
}

.event-card.done {
    opacity: 0.4;
}

.event-card.done .event-title {
    text-decoration: line-through;
}

/* Category styles */
.cat-axia { background: linear-gradient(rgba(79, 195, 247, 0.12), rgba(79, 195, 247, 0.08)), var(--surface); border-color: rgba(79, 195, 247, 0.12); }
.cat-axia::before { background: var(--accent-axia); }
.cat-axia .event-tag { color: var(--accent-axia); background: rgba(79, 195, 247, 0.15); }

.cat-record { background: linear-gradient(rgba(102, 187, 106, 0.12), rgba(102, 187, 106, 0.08)), var(--surface); border-color: rgba(102, 187, 106, 0.12); }
.cat-record::before { background: var(--accent-record); }
.cat-record .event-tag { color: var(--accent-record); background: rgba(102, 187, 106, 0.15); }

.cat-explo { background: linear-gradient(rgba(255, 167, 38, 0.12), rgba(255, 167, 38, 0.08)), var(--surface); border-color: rgba(255, 167, 38, 0.12); }
.cat-explo::before { background: var(--accent-explo); }
.cat-explo .event-tag { color: var(--accent-explo); background: rgba(255, 167, 38, 0.15); }

.cat-perso { background: linear-gradient(rgba(239, 83, 80, 0.12), rgba(239, 83, 80, 0.08)), var(--surface); border-color: rgba(239, 83, 80, 0.12); }
.cat-perso::before { background: var(--accent-perso); }
.cat-perso .event-tag { color: var(--accent-perso); background: rgba(239, 83, 80, 0.15); }

.cat-trajet { background: linear-gradient(rgba(171, 71, 188, 0.12), rgba(171, 71, 188, 0.08)), var(--surface); border-color: rgba(171, 71, 188, 0.12); }
.cat-trajet::before { background: var(--accent-trajet); }
.cat-trajet .event-tag { color: var(--accent-trajet); background: rgba(171, 71, 188, 0.15); }

.cat-attente { background: linear-gradient(rgba(120, 144, 156, 0.12), rgba(120, 144, 156, 0.08)), var(--surface); border-color: rgba(120, 144, 156, 0.12); }
.cat-attente::before { background: var(--accent-attente); }
.cat-attente .event-tag { color: var(--accent-attente); background: rgba(120, 144, 156, 0.15); }

.cat-rituel { background: linear-gradient(rgba(239, 83, 80, 0.12), rgba(239, 83, 80, 0.08)), var(--surface); border-color: rgba(239, 83, 80, 0.12); }
.cat-rituel::before { background: var(--accent-rituel); }
.cat-rituel .event-tag { color: var(--accent-rituel); background: rgba(239, 83, 80, 0.15); }

.event-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.event-tag {
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.event-time-range {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--text-muted);
}

.event-title {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.3;
}

.event-location {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* ===== TASKS INSIDE EVENT ===== */
.embedded-tasks {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--border);
}

.task-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 0;
    cursor: pointer;
    transition: opacity 0.2s;
}

.task-item:active {
    opacity: 0.6;
}

.task-check {
    width: 20px;
    height: 20px;
    min-width: 20px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    font-size: 11px;
    color: transparent;
}

.task-item.checked .task-check {
    background: var(--accent-record);
    border-color: var(--accent-record);
    color: #fff;
    box-shadow: 0 0 8px rgba(102, 187, 106, 0.3);
}

.task-item.checked .task-text {
    text-decoration: line-through;
    color: var(--text-muted);
}

.task-text {
    font-size: 14px;
    line-height: 1.3;
}

.task-priority-high {
    border-left: 2px solid var(--now-line);
    padding-left: 8px;
}

.task-priority-medium {
    border-left: 2px solid var(--accent-explo);
    padding-left: 8px;
}

.task-actions {
    display: flex;
    gap: 4px;
    margin-left: auto;
    opacity: 0;
    transition: opacity 0.15s;
}

.task-item:hover .task-actions {
    opacity: 1;
}

/* ===== ADDRESS PILLS ===== */
.address-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.address-pill {
    padding: 5px 12px;
    border-radius: 20px;
    border: 1px solid var(--border);
    background: rgba(79, 195, 247, 0.06);
    color: var(--accent-axia);
    font-size: 12px;
    font-family: var(--font);
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
}

.address-pill:hover, .address-pill:active {
    background: rgba(79, 195, 247, 0.15);
    border-color: rgba(79, 195, 247, 0.3);
}

/* ===== FREE SLOT ===== */
.free-slot {
    flex: 1;
    border-radius: var(--radius);
    padding: 12px 16px;
    background: rgba(255,255,255,0.02);
    border: 1px dashed rgba(255,255,255,0.1);
    color: var(--text-muted);
    font-size: 13px;
    font-style: italic;
}

/* ===== SECTION DIVIDER ===== */
.section-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 28px 20px 14px;
    max-width: var(--max-w);
}

.section-divider span {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 6px;
}

.section-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border);
}

/* ===== WAITING LIST ===== */
.waiting-list {
    padding: 0 20px 40px;
    max-width: var(--max-w);
    margin: 0 auto;
}

.waiting-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 6px;
    border-left: 3px solid var(--accent-attente);
}

.waiting-who {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--accent-attente);
    background: rgba(120, 144, 156, 0.12);
    padding: 3px 10px;
    border-radius: 8px;
    white-space: nowrap;
}

.waiting-text {
    font-size: 14px;
}

/* ===== FAB ===== */
.fab {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 52px;
    height: 52px;
    border-radius: 16px;
    background: var(--accent-axia);
    color: #fff;
    border: none;
    font-size: 26px;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(79, 195, 247, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    z-index: 200;
}

.fab:hover, .fab:active {
    transform: scale(1.08);
    box-shadow: 0 6px 24px rgba(79, 195, 247, 0.5);
}

/* ===== MODAL ===== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 300;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s;
}

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

.modal {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px 20px 0 0;
    width: 100%;
    max-width: 500px;
    max-height: 85vh;
    overflow-y: auto;
    padding: 24px 20px 40px;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}

.modal-overlay.active .modal {
    transform: translateY(0);
}

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

.modal-title {
    font-size: 18px;
    font-weight: 700;
}

.modal-close {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.modal-close:hover {
    background: rgba(255,255,255,0.1);
}

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

.form-label {
    display: block;
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
    font-family: var(--mono);
    font-weight: 600;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: 15px;
    font-family: var(--font);
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    border-color: var(--accent-axia);
    box-shadow: 0 0 0 3px rgba(79, 195, 247, 0.1);
}

.form-textarea {
    resize: vertical;
    min-height: 80px;
    line-height: 1.5;
}

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%237d8590' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.form-row {
    display: flex;
    gap: 12px;
}

.form-row .form-group {
    flex: 1;
}

.form-btn {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font);
}

.form-btn-primary {
    background: var(--accent-axia);
    color: #fff;
}

.form-btn-primary:hover, .form-btn-primary:active {
    opacity: 0.9;
    transform: scale(0.98);
}

.form-btn-danger {
    background: rgba(239, 83, 80, 0.12);
    color: var(--accent-perso);
    margin-top: 8px;
}

/* ===== ADD BUTTONS ===== */
.add-inline-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 0;
    color: var(--text-muted);
    font-size: 13px;
    cursor: pointer;
    border: none;
    background: none;
    font-family: var(--font);
    transition: color 0.15s;
}

.add-inline-btn:hover {
    color: var(--text);
}

/* ===== EMPTY STATE ===== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-state-icon {
    font-size: 40px;
    margin-bottom: 12px;
    opacity: 0.5;
}

.empty-state-text {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
}

.empty-state-sub {
    font-size: 13px;
}

/* ===== DELETE ACTIONS ===== */
.event-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 4px;
    opacity: 0;
    transition: opacity 0.15s;
}

.event-card:hover .event-actions {
    opacity: 1;
}

.event-action-btn {
    width: 26px;
    height: 26px;
    border-radius: 8px;
    background: rgba(255,255,255,0.08);
    border: none;
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.event-action-btn:hover {
    background: rgba(255,255,255,0.15);
    color: var(--text);
}

/* ===== TRACKER SECTIONS ===== */
.tracker-section {
    padding: 0 20px 16px;
    max-width: var(--max-w);
    margin: 0 auto;
}

.tracker-empty {
    font-size: 13px;
    color: var(--text-muted);
    font-style: italic;
    padding: 8px 0;
}

.tracker-group-label {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    padding: 10px 0 4px;
    letter-spacing: 0.3px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.tracker-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 6px;
    cursor: pointer;
    transition: all 0.15s;
}

.tracker-item:active {
    transform: scale(0.98);
    opacity: 0.8;
}

.tracker-item.checked {
    opacity: 0.5;
}

.tracker-item.checked .tracker-name {
    text-decoration: line-through;
    color: var(--text-muted);
}

.tracker-icon {
    font-size: 18px;
    line-height: 1;
}

.tracker-name {
    font-size: 14px;
    font-weight: 500;
}

.tracker-dosage {
    font-size: 11px;
    color: var(--text-muted);
    font-family: var(--mono);
    font-weight: 600;
    margin-left: auto;
}

/* ===== MOOD ENTRIES ===== */
.mood-entry {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 6px;
    border-left: 3px solid var(--text-muted);
    cursor: pointer;
    transition: all 0.15s;
}

.mood-entry:active {
    transform: scale(0.98);
    opacity: 0.8;
}

.mood-time {
    font-family: var(--mono);
    font-size: 13px;
    font-weight: 600;
    color: var(--accent-axia);
    white-space: nowrap;
    min-width: 40px;
}

.mood-emojis {
    font-size: 18px;
    line-height: 1;
    display: flex;
    gap: 4px;
    align-items: center;
}

.mood-note {
    font-size: 13px;
    color: var(--text-muted);
    font-style: italic;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mood-delete {
    margin-left: auto;
    opacity: 0;
    transition: opacity 0.15s;
}

.mood-entry:hover .mood-delete {
    opacity: 1;
}

/* ===== EMOJI SELECTOR ===== */
.emoji-selector {
    display: flex;
    gap: 8px;
    justify-content: center;
    padding: 8px 0;
}

.emoji-btn {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    border: 2px solid var(--border);
    background: var(--bg);
    font-size: 22px;
    cursor: pointer;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.emoji-btn:hover {
    border-color: rgba(79, 195, 247, 0.3);
    background: rgba(79, 195, 247, 0.06);
}

.emoji-btn.selected {
    border-color: var(--accent-axia);
    background: rgba(79, 195, 247, 0.15);
    transform: scale(1.08);
    box-shadow: 0 0 12px rgba(79, 195, 247, 0.25);
}

/* ===== MONTHLY RECAP ===== */
.recap-container {
    padding: 20px;
    max-width: var(--max-w);
    margin: 0 auto;
}

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

.recap-title {
    font-size: 20px;
    font-weight: 700;
    text-transform: capitalize;
}

.recap-nav {
    display: flex;
    gap: 8px;
    align-items: center;
}

.recap-back-btn {
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    font-size: 13px;
    cursor: pointer;
    font-family: var(--font);
    transition: all 0.15s;
}

.recap-back-btn:hover {
    background: var(--surface-alt);
}

.recap-calendar {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 16px;
}

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

.recap-day-label {
    text-align: center;
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    padding: 4px 0;
}

.recap-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
}

.recap-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 13px;
    font-family: var(--mono);
    cursor: pointer;
    transition: all 0.15s;
    position: relative;
}

.recap-day:hover {
    background: rgba(255,255,255,0.05);
}

.recap-day.empty { pointer-events: none; }
.recap-day.today { border: 2px solid var(--accent-axia); }

.recap-day.has-data::after {
    content: '';
    position: absolute;
    bottom: 2px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.recap-day.mood-1 { background: rgba(239, 83, 80, 0.2); color: var(--accent-perso); }
.recap-day.mood-2 { background: rgba(255, 167, 38, 0.2); color: var(--accent-explo); }
.recap-day.mood-3 { background: rgba(136, 146, 164, 0.15); }
.recap-day.mood-4 { background: rgba(79, 195, 247, 0.2); color: var(--accent-axia); }
.recap-day.mood-5 { background: rgba(102, 187, 106, 0.2); color: var(--accent-record); }

/* Stat cards */
.recap-stats {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.recap-stat-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
}

.recap-stat-title {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
}

.recap-stat-value {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 4px;
}

.recap-stat-sub {
    font-size: 13px;
    color: var(--text-muted);
}

.recap-progress-bar {
    height: 6px;
    background: rgba(255,255,255,0.06);
    border-radius: 3px;
    margin-top: 10px;
    overflow: hidden;
}

.recap-progress-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.5s ease;
}

.recap-habit-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
}

.recap-habit-row:last-child { border-bottom: none; }

.recap-habit-name { flex: 1; font-size: 14px; }

.recap-habit-days {
    font-family: var(--mono);
    font-size: 13px;
    font-weight: 600;
    color: var(--accent-axia);
}

.recap-habit-streak {
    font-size: 12px;
    color: var(--accent-explo);
}

/* ===== TRAFFIC ===== */
.traffic-section {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 20px;
}

.traffic-toggle-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    padding: 10px 0;
}
.traffic-toggle-icon {
    color: var(--text-muted);
    font-size: 12px;
    transition: transform 0.2s;
}
.traffic-body {
    overflow: hidden;
    transition: max-height 0.3s ease, opacity 0.3s ease;
    max-height: 2000px;
    opacity: 1;
}
.traffic-body.collapsed {
    max-height: 0;
    opacity: 0;
    padding: 0;
    margin: 0;
}

.traffic-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.traffic-route {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--accent-record);
}

.traffic-route.traffic-ralenti { border-left-color: var(--accent-explo); }
.traffic-route.traffic-charge { border-left-color: var(--accent-perso); }

.traffic-route.traffic-error {
    border-left-color: var(--text-muted);
    opacity: 0.6;
}

.traffic-icon {
    font-size: 18px;
    flex-shrink: 0;
    color: var(--text-muted);
    display: flex;
    align-items: center;
}

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

.traffic-name {
    font-size: 14px;
    font-weight: 600;
}

.traffic-detail {
    font-size: 11px;
    color: var(--text-muted);
    font-family: var(--mono);
}

.traffic-time {
    text-align: right;
    flex-shrink: 0;
}

.traffic-minutes {
    font-family: var(--mono);
    font-size: 18px;
    font-weight: 700;
}

.traffic-fluide .traffic-minutes { color: var(--accent-record); }
.traffic-ralenti .traffic-minutes { color: var(--accent-explo); }
.traffic-charge .traffic-minutes { color: var(--accent-perso); }

.traffic-status {
    font-size: 11px;
    font-family: var(--mono);
    color: var(--text-muted);
}

.traffic-fluide .traffic-status { color: var(--accent-record); }
.traffic-ralenti .traffic-status { color: var(--accent-explo); }
.traffic-charge .traffic-status { color: var(--accent-perso); }

.tracker-manage-btn {
    display: block;
    width: 100%;
    padding: 8px;
    margin-top: 8px;
    background: none;
    border: 1px dashed var(--border);
    border-radius: 8px;
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font);
}

.tracker-manage-btn:active {
    background: rgba(255,255,255,0.03);
}

/* ===== OVERDUE TASKS ===== */
.overdue-section {
    border-left: 3px solid var(--accent-perso);
    margin: 0 20px 16px;
    padding: 12px 0 12px 12px;
    background: rgba(239, 83, 80, 0.04);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    max-width: var(--max-w);
}

.overdue-date-label {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--accent-explo);
    padding: 6px 0 2px;
    letter-spacing: 0.3px;
}

.overdue-task {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    background: var(--surface);
    border-radius: 8px;
    margin-bottom: 4px;
}

.overdue-task.priority-high {
    border-left: 2px solid var(--accent-perso);
}

.overdue-task.priority-low {
    opacity: 0.7;
}

.overdue-check {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid var(--accent-record);
    background: none;
    color: var(--accent-record);
    font-size: 14px;
    cursor: pointer;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.overdue-check:active {
    background: var(--accent-record);
    color: white;
}

.overdue-task-info {
    flex: 1;
    min-width: 0;
}

.overdue-task-title {
    font-size: 13px;
    font-weight: 500;
}

.overdue-event-label {
    font-size: 10px;
    color: var(--text-muted);
    background: rgba(255,255,255,0.05);
    padding: 1px 6px;
    border-radius: 4px;
    display: inline-block;
    margin-top: 2px;
}

.overdue-report-btn {
    padding: 4px 10px;
    background: rgba(79, 195, 247, 0.1);
    border: 1px solid rgba(79, 195, 247, 0.2);
    border-radius: 6px;
    color: var(--accent-axia);
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    flex-shrink: 0;
    transition: all 0.15s;
    font-family: var(--font);
}

.overdue-report-btn:active {
    background: rgba(79, 195, 247, 0.2);
}

/* ===== DAILY NOTE ===== */
.daily-note-section {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 20px;
}

.daily-note-textarea,
.daily-note-input {
    width: 100%;
    min-height: 80px;
    padding: 12px 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: 14px;
    font-family: var(--font);
    line-height: 1.5;
    outline: none;
    resize: vertical;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.daily-note-textarea:focus,
.daily-note-input:focus {
    border-color: var(--accent-axia);
    box-shadow: 0 0 0 3px rgba(79, 195, 247, 0.1);
}

.daily-note-textarea::placeholder,
.daily-note-input::placeholder {
    color: var(--text-muted);
    font-style: italic;
}

.daily-note-charcount {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 4px;
}

/* ===== WEEKLY VIEW ===== */
.week-container {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 20px;
}

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

.week-title {
    font-size: 18px;
    font-weight: 700;
    font-family: var(--mono);
    color: var(--accent-axia);
}

.week-nav {
    display: flex;
    gap: 6px;
    align-items: center;
}

.week-days {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-bottom: 40px;
}

.week-day-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 14px 16px;
    cursor: pointer;
    transition: border-color 0.15s, transform 0.15s;
}

.week-day-card:hover {
    border-color: rgba(255,255,255,0.15);
    transform: translateY(-1px);
}

.week-day-card.is-today {
    border-color: var(--accent-axia);
    border-width: 2px;
}

.week-day-card.is-past {
    opacity: 0.6;
}

.week-day-header {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.week-day-name {
    font-size: 15px;
    font-weight: 700;
    min-width: 75px;
}

.week-day-date {
    font-size: 13px;
    color: var(--text-muted);
    font-family: var(--mono);
}

.week-day-saint {
    font-size: 12px;
    color: var(--accent-explo);
    margin-left: auto;
    font-style: italic;
}

.week-day-weather {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.week-weather-city {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-family: var(--mono);
    color: var(--text-muted);
    background: rgba(255,255,255,0.03);
    padding: 4px 8px;
    border-radius: 6px;
    flex: 1;
    min-width: 0;
}

.week-weather-icon {
    flex-shrink: 0;
}

.week-weather-icon .w-ico {
    width: 18px;
    height: 18px;
}

.week-weather-temp {
    font-weight: 600;
    color: var(--text);
}

.week-weather-name {
    flex-shrink: 0;
}

.week-sun {
    font-size: 10px;
    color: var(--text-muted);
    margin-left: auto;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 4px;
}

.week-sun .w-ico {
    width: 12px;
    height: 12px;
}

.week-day-birthdays {
    margin-bottom: 8px;
}

.week-birthday {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
    padding: 3px 8px;
    border-radius: 12px;
    margin-right: 6px;
    font-weight: 600;
}

.week-day-events {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.week-event {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
}

.week-event-time {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--text-muted);
    min-width: 85px;
    flex-shrink: 0;
}

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

.week-event-title {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.week-no-events {
    font-size: 12px;
    color: var(--text-muted);
    font-style: italic;
}

.week-loading {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
    font-family: var(--mono);
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* ===== BIRTHDAY BANNER ===== */
.birthday-banner {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(239, 68, 68, 0.06));
    border: 1px solid rgba(245, 158, 11, 0.2);
    border-radius: var(--radius);
    padding: 14px 16px;
    margin: 12px 20px;
    max-width: var(--max-w);
}

.birthday-header {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    color: #f59e0b;
    margin-bottom: 10px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.birthday-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: var(--radius-sm);
    margin-bottom: 6px;
}

.birthday-icon {
    font-size: 20px;
    display: flex;
    align-items: center;
}

.birthday-name {
    flex: 1;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
}

.birthday-age {
    font-size: 13px;
    font-family: var(--mono);
    font-weight: 600;
    color: #f59e0b;
    white-space: nowrap;
}

/* ===== SYMPTOM CARDS ===== */
.symptom-cards-section {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 20px;
}

.symptom-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
    padding: 12px 0;
}

.symptom-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    border-left: 3px solid var(--card-color, #666);
    padding: 14px;
    transition: transform 0.15s;
}

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

.symptom-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.symptom-card-icon {
    font-size: 16px;
    display: flex;
    align-items: center;
    color: var(--card-color, var(--text-muted));
}

.symptom-card-title {
    font-size: 12px;
    font-weight: 700;
    color: var(--text);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: var(--mono);
}

.symptom-card-badge {
    margin-left: auto;
    background: var(--card-color, #666);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    font-family: var(--mono);
    min-width: 20px;
    height: 20px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 6px;
}

.symptom-card-items { display: flex; flex-direction: column; gap: 2px; }

.symptom-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.15s;
    font-size: 13px;
    color: var(--text-muted);
}

.symptom-item:hover { background: rgba(255,255,255,0.04); }

.symptom-item::before {
    content: '';
    width: 16px;
    height: 16px;
    border-radius: 4px;
    border: 2px solid rgba(255,255,255,0.15);
    flex-shrink: 0;
    transition: all 0.15s;
}

.symptom-item.checked {
    color: var(--text);
}

.symptom-item.checked::before {
    background: var(--card-color, #4fc3f7);
    border-color: var(--card-color, #4fc3f7);
}

.symptom-item-text { flex: 1; }

/* ===== CAPTURE INBOX ===== */
.capture-divider {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.capture-header-link {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px;
    transition: color 0.15s;
}

.capture-header-link:hover {
    color: var(--accent-axia);
}

.capture-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 10px;
    background: var(--accent-perso);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    font-family: var(--mono);
    margin-left: 4px;
}

.capture-nav-btn {
    position: relative;
}

.capture-header-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 8px;
    background: var(--accent-perso);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    font-family: var(--mono);
    display: flex;
    align-items: center;
    justify-content: center;
}

.capture-quick-add {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 12px;
    margin-bottom: 10px;
}

.capture-input {
    width: 100%;
    padding: 10px 14px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: 14px;
    font-family: var(--font);
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    margin-bottom: 8px;
}

.capture-input:focus {
    border-color: var(--accent-axia);
    box-shadow: 0 0 0 3px rgba(79, 195, 247, 0.1);
}

.capture-input::placeholder {
    color: var(--text-muted);
    font-style: italic;
}

.capture-context-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.capture-pill {
    padding: 4px 10px;
    border-radius: 16px;
    border: 1px solid var(--border);
    background: none;
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font);
    white-space: nowrap;
}

.capture-pill:hover {
    border-color: var(--pill-color, var(--text-muted));
    color: var(--text);
}

.capture-pill.selected {
    background: var(--pill-color, var(--accent-axia));
    border-color: var(--pill-color, var(--accent-axia));
    color: #fff;
}

.capture-add-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 10px;
    border-radius: var(--radius-sm);
    border: none;
    background: var(--accent-axia);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font);
}

.capture-add-btn:hover {
    opacity: 0.9;
}

.capture-add-btn:active {
    transform: scale(0.98);
}

.capture-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 6px;
    transition: all 0.15s;
}

.capture-item.processed {
    opacity: 0.5;
}

.capture-item.processed .capture-item-text {
    text-decoration: line-through;
    color: var(--text-muted);
}

.capture-ctx-dot {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
    opacity: 0.8;
}

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

.capture-item-text {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    word-break: break-word;
}

.capture-item-time {
    display: block;
    font-size: 11px;
    color: var(--text-muted);
    font-family: var(--mono);
    margin-top: 2px;
}

.capture-item-actions {
    display: flex;
    gap: 4px;
    flex-shrink: 0;
    opacity: 0;
    transition: opacity 0.15s;
}

.capture-item:hover .capture-item-actions {
    opacity: 1;
}

.capture-action-btn {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    transition: all 0.15s;
}

.capture-done-btn {
    background: rgba(102, 187, 106, 0.1);
    color: var(--accent-record);
}

.capture-done-btn:hover {
    background: rgba(102, 187, 106, 0.25);
}

.capture-del-btn {
    background: rgba(239, 83, 80, 0.08);
    color: var(--accent-perso);
}

.capture-del-btn:hover {
    background: rgba(239, 83, 80, 0.2);
}

.capture-empty {
    text-align: center;
    padding: 16px;
    color: var(--text-muted);
    font-size: 13px;
    font-style: italic;
}

/* Inbox full view */
.inbox-container {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 20px;
}

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

.inbox-title {
    font-size: 18px;
    font-weight: 700;
    font-family: var(--mono);
    color: var(--accent-axia);
    display: flex;
    align-items: center;
    gap: 8px;
}

.inbox-count {
    font-size: 13px;
    color: var(--text-muted);
    font-family: var(--mono);
}

.inbox-quick-add {
    margin-bottom: 16px;
}

.inbox-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.inbox-filter {
    padding: 6px 12px;
    border-radius: 16px;
    border: 1px solid var(--border);
    background: none;
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font);
    white-space: nowrap;
}

.inbox-filter:hover {
    border-color: rgba(255,255,255,0.2);
    color: var(--text);
}

.inbox-filter.active {
    background: var(--pill-color, var(--accent-axia));
    border-color: var(--pill-color, var(--accent-axia));
    color: #fff;
}

.inbox-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    padding-bottom: 40px;
}

/* ===== TODO PAGE ===== */
.todo-page {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 20px 40px;
}

.todo-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 0;
    margin-bottom: 8px;
}

.todo-header h2 {
    font-size: 20px;
    font-weight: 700;
    font-family: var(--mono);
    color: var(--accent-axia);
    flex: 1;
    margin: 0;
}

.todo-back-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 13px;
    font-family: var(--font);
    cursor: pointer;
    padding: 6px 10px;
    border-radius: var(--radius-sm);
    transition: all 0.15s;
}

.todo-back-btn:hover {
    color: var(--text);
    background: rgba(255,255,255,0.05);
}

.todo-manage-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 6px;
    border-radius: var(--radius-sm);
    transition: color 0.15s;
    display: flex;
    align-items: center;
}

.todo-manage-btn:hover {
    color: var(--accent-axia);
}

.todo-filters {
    margin-bottom: 16px;
}

.todo-theme-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.todo-filter-btn {
    padding: 6px 14px;
    border-radius: 16px;
    border: 1px solid var(--border);
    background: none;
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font);
    white-space: nowrap;
}

.todo-filter-btn:hover {
    border-color: var(--btn-color, rgba(255,255,255,0.2));
    color: var(--text);
}

.todo-filter-btn.active {
    background: var(--btn-color, var(--accent-axia));
    border-color: var(--btn-color, var(--accent-axia));
    color: #fff;
}

.todo-domain-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.todo-domain-chip {
    padding: 4px 10px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: none;
    color: var(--text-muted);
    font-size: 11px;
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font);
    white-space: nowrap;
}

.todo-domain-chip:hover {
    border-color: var(--chip-color, rgba(255,255,255,0.2));
    color: var(--text);
}

.todo-domain-chip.active {
    background: var(--chip-color, var(--accent-axia));
    border-color: var(--chip-color, var(--accent-axia));
    color: #fff;
}

.todo-pilote-select {
    padding: 6px 12px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: 12px;
    font-family: var(--font);
    outline: none;
    cursor: pointer;
    margin-bottom: 8px;
}

.todo-add-bar {
    margin-bottom: 16px;
}

.todo-add-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    border: 1px dashed var(--border);
    background: none;
    color: var(--accent-axia);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font);
}

.todo-add-btn:hover {
    border-color: var(--accent-axia);
    background: rgba(79, 195, 247, 0.06);
}

.todo-items-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.todo-date-group {
    margin-bottom: 16px;
}

.todo-date-label {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: lowercase;
    font-family: var(--mono);
    padding: 6px 0;
    margin-bottom: 6px;
    border-bottom: 1px solid var(--border);
}

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

.todo-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 4px;
    transition: all 0.15s;
    border-left: 3px solid transparent;
}

.todo-item:hover {
    border-color: rgba(255,255,255,0.12);
    border-left-color: var(--accent-axia);
}

.todo-priority-high { border-left-color: var(--accent-perso); }
.todo-priority-medium { border-left-color: var(--accent-explo); }
.todo-priority-low { border-left-color: var(--accent-attente); }

.todo-item-done {
    opacity: 0.5;
}

.todo-item-done .todo-item-title {
    text-decoration: line-through;
    color: var(--text-muted);
}

.todo-checkbox {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    cursor: pointer;
}

.todo-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    appearance: none;
    -webkit-appearance: none;
    background: var(--bg);
    border: 2px solid rgba(255,255,255,0.15);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.15s;
}

.todo-checkbox input[type="checkbox"]:checked {
    background: var(--accent-record);
    border-color: var(--accent-record);
}

.todo-checkbox input[type="checkbox"]:checked::after {
    content: '✓';
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    width: 100%;
    height: 100%;
}

.todo-item-content {
    flex: 1;
    min-width: 0;
    cursor: pointer;
}

.todo-item-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    margin-bottom: 2px;
}

.todo-item-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
}

.todo-domain-badge {
    display: inline-block;
    padding: 1px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 600;
    color: #fff;
}

.todo-pilote-badge {
    font-size: 11px;
    color: var(--text-muted);
    font-family: var(--mono);
}

.todo-item-date {
    font-size: 11px;
    color: var(--text-muted);
    font-family: var(--mono);
}

.todo-item-delete {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 14px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 6px;
    opacity: 0;
    transition: all 0.15s;
    flex-shrink: 0;
}

.todo-item:hover .todo-item-delete {
    opacity: 1;
}

.todo-item-delete:hover {
    color: var(--accent-perso);
    background: rgba(239, 83, 80, 0.1);
}

/* Todo block in daily view */
.todo-block-section {
    max-width: var(--max-w);
    margin: 0 auto;
    padding: 0 20px;
}

.todo-block-header {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: var(--mono);
    padding: 8px 0;
    cursor: pointer;
    transition: color 0.15s;
}

.todo-block-header:hover {
    color: var(--accent-axia);
}

.todo-block-count {
    margin-left: auto;
    font-size: 11px;
    color: var(--accent-axia);
    font-weight: 600;
}

.todo-block-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 4px;
    font-size: 13px;
    transition: all 0.15s;
}

.todo-block-item:hover {
    border-color: rgba(255,255,255,0.12);
}

.todo-block-item.todo-item-done {
    opacity: 0.5;
}

.todo-block-item.todo-item-done .todo-block-title {
    text-decoration: line-through;
    color: var(--text-muted);
}

.todo-checkbox-sm {
    position: relative;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    cursor: pointer;
}

.todo-checkbox-sm input[type="checkbox"] {
    width: 14px;
    height: 14px;
    appearance: none;
    -webkit-appearance: none;
    background: var(--bg);
    border: 2px solid rgba(255,255,255,0.15);
    border-radius: 3px;
    cursor: pointer;
    transition: all 0.15s;
}

.todo-checkbox-sm input[type="checkbox"]:checked {
    background: var(--accent-record);
    border-color: var(--accent-record);
}

.todo-block-title {
    flex: 1;
    color: var(--text);
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.todo-block-domain {
    font-size: 11px;
    font-weight: 600;
    flex-shrink: 0;
}

.todo-block-more {
    font-size: 12px;
    color: var(--text-muted);
    padding: 4px 10px;
    font-style: italic;
}

.todo-block-add {
    font-size: 12px;
    color: var(--accent-axia);
    padding: 4px 10px;
    cursor: pointer;
    transition: color 0.15s;
}

.todo-block-add:hover {
    color: #fff;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 420px) {
    .header {
        padding: 14px 14px 12px;
    }
    .date-display {
        font-size: 22px;
    }
    .event-title {
        font-size: 14px;
    }
    .fab {
        bottom: 20px;
        right: 20px;
        width: 48px;
        height: 48px;
        font-size: 24px;
    }
    .event-actions {
        opacity: 1;
    }
    .mood-delete {
        opacity: 1;
    }
    .task-actions {
        opacity: 1;
    }
    .capture-item-actions {
        opacity: 1;
    }
    .todo-item-delete {
        opacity: 1;
    }
    .symptom-cards-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (min-width: 768px) {
    .header {
        max-width: var(--max-w);
        margin: 0 auto;
    }
    .tl-container {
        max-width: calc(var(--max-w) - 70px);
        margin-left: auto;
        margin-right: auto;
        margin-left: 70px;
    }
    .section-divider {
        max-width: var(--max-w);
        margin-left: auto;
        margin-right: auto;
        padding: 0 20px;
    }
    .waiting-list {
        max-width: var(--max-w);
        margin: 0 auto;
    }
    .tracker-section {
        max-width: var(--max-w);
        margin-left: auto;
        margin-right: auto;
    }
    .birthday-banner {
        max-width: var(--max-w);
        margin-left: auto;
        margin-right: auto;
    }
    .overdue-section {
        max-width: var(--max-w);
        margin-left: auto;
        margin-right: auto;
    }
    .todo-block-section {
        max-width: var(--max-w);
        margin-left: auto;
        margin-right: auto;
    }
}

/* ===== SMOOTH SELECTION ===== */
::selection {
    background: rgba(79, 195, 247, 0.25);
    color: var(--text);
}

/* ===== SCROLLBAR STYLING ===== */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,0.2);
}

/* ===== TRAJET LIVE BADGE ===== */
.trajet-live-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-muted);
    padding: 6px 10px;
    margin: 6px 0;
    border-radius: 6px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
}
.trajet-live-badge strong {
    color: var(--text);
    font-family: 'JetBrains Mono', monospace;
}
.trajet-live-fluide {
    border-color: rgba(102,187,106,0.3);
    background: rgba(102,187,106,0.08);
}
.trajet-live-fluide .trajet-live-status {
    color: #66bb6a;
    font-weight: 600;
}
.trajet-live-ralenti {
    border-color: rgba(255,167,38,0.3);
    background: rgba(255,167,38,0.08);
}
.trajet-live-ralenti .trajet-live-status {
    color: #ffa726;
    font-weight: 600;
}
.trajet-live-charge {
    border-color: rgba(239,83,80,0.3);
    background: rgba(239,83,80,0.08);
}
.trajet-live-charge .trajet-live-status {
    color: #ef5350;
    font-weight: 600;
}

/* ===== TRAJET AUTO (Event Form) ===== */
.trajet-section {
    margin-top: 12px;
    padding: 14px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    border-radius: 10px;
    animation: dpSlideDown 0.2s ease;
}
.trajet-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--accent-axia);
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}
.trajet-header-icon {
    display: flex;
    align-items: center;
}
.trajet-status {
    font-size: 12px;
    color: var(--text-muted);
    padding: 8px 10px;
    background: rgba(79,195,247,0.08);
    border-radius: 6px;
    margin-top: 8px;
    text-align: center;
}

/* ===== DAY TEMPLATES ===== */
.dt-buttons {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}
.dt-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}
.dt-btn:hover {
    background: rgba(79,195,247,0.1);
    border-color: var(--accent-axia);
    color: var(--text);
    transform: translateY(-1px);
}
.dt-btn:active {
    transform: translateY(0);
}
.dt-icon {
    font-size: 14px;
}
.dt-label {
    white-space: nowrap;
}

/* ===== DATE PICKER (Mini Calendar) ===== */
.dp-calendar {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 14px;
    margin-top: 8px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
    max-width: 320px;
    animation: dpSlideDown 0.2s ease;
}
@keyframes dpSlideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}
.dp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}
.dp-month-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    padding: 4px 12px;
    border-radius: 6px;
    transition: background 0.2s;
}
.dp-month-label:hover {
    background: rgba(255,255,255,0.05);
}
.dp-nav {
    background: none;
    border: 1px solid var(--border);
    color: var(--text-muted);
    border-radius: 6px;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}
.dp-nav:hover {
    color: var(--accent-axia);
    border-color: var(--accent-axia);
}
.dp-days-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
    margin-bottom: 4px;
}
.dp-day-label {
    text-align: center;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    padding: 4px 0;
}
.dp-day-label.dp-weekend {
    color: rgba(255,255,255,0.2);
}
.dp-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
}
.dp-day {
    background: none;
    border: 1px solid transparent;
    color: var(--text);
    font-size: 13px;
    font-weight: 500;
    padding: 6px 0;
    border-radius: 6px;
    cursor: pointer;
    text-align: center;
    transition: all 0.15s;
    font-family: 'JetBrains Mono', monospace;
}
.dp-day:hover {
    background: rgba(79,195,247,0.15);
    border-color: var(--accent-axia);
}
.dp-day.dp-other {
    color: var(--text-muted);
    opacity: 0.4;
}
.dp-day.dp-weekend {
    color: rgba(255,255,255,0.4);
}
.dp-day.dp-today {
    background: rgba(79,195,247,0.15);
    color: var(--accent-axia);
    font-weight: 700;
    border-color: var(--accent-axia);
}
.dp-day.dp-selected {
    background: var(--accent-axia);
    color: var(--bg);
    font-weight: 700;
}
.dp-day.dp-selected.dp-today {
    background: var(--accent-axia);
    color: var(--bg);
}
.date-display svg {
    opacity: 0.4;
    margin-left: 4px;
    transition: opacity 0.2s;
}
.date-display:hover svg {
    opacity: 1;
    color: var(--accent-axia);
}

/* ===== EMAIL SYNC (Outlook) ===== */
.es-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 14px;
    border-bottom: 1px solid var(--border);
}
.es-last-sync {
    font-size: 11px;
    color: var(--text-muted);
}
.es-sync-btn {
    background: none;
    border: 1px solid var(--border);
    color: var(--text-muted);
    border-radius: 6px;
    padding: 4px 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    transition: all 0.2s;
}
.es-sync-btn:hover {
    color: var(--accent-axia);
    border-color: var(--accent-axia);
}
.es-group {
    padding: 8px 14px;
}
.es-group + .es-group {
    border-top: 1px solid var(--border);
}
.es-group-title {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.es-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 8px;
    border: 1px solid var(--border);
    margin-bottom: 6px;
    background: rgba(255,255,255,0.02);
    transition: all 0.2s;
}
.es-item:hover {
    background: rgba(255,255,255,0.05);
}
.es-item.es-imported {
    opacity: 0.4;
    border-color: var(--accent-record);
}
.es-item-info {
    flex: 1;
    min-width: 0;
}
.es-item-time {
    font-size: 11px;
    color: var(--accent-axia);
    font-weight: 600;
    font-family: 'JetBrains Mono', monospace;
}
.es-item-title {
    font-size: 13px;
    font-weight: 500;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.es-item-meta {
    font-size: 11px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.es-item-type {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--accent-axia);
    letter-spacing: 0.5px;
}
.es-item-actions {
    display: flex;
    gap: 4px;
    flex-shrink: 0;
}
.es-import-btn {
    background: none;
    border: 1px solid var(--border);
    color: var(--text-muted);
    border-radius: 6px;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}
.es-import-btn:hover {
    color: var(--accent-axia);
    border-color: var(--accent-axia);
    background: rgba(79,195,247,0.1);
}
.es-priority-high {
    border-left: 3px solid var(--accent-perso);
}
.es-priority-medium {
    border-left: 3px solid var(--accent-explo);
}
.es-priority-low {
    border-left: 3px solid var(--text-muted);
}
.sync-spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid var(--text-muted);
    border-top-color: var(--accent-axia);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    vertical-align: middle;
    margin-right: 6px;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
