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

  :root {
    --bg:        #0d0f14;
    --surface:   #151820;
    --surface2:  #1c2030;
    --border:    #1e2333;
    --border2:   #252b3b;
    --blue:      #4a9eff;
    --blue-dim:  #2563a8;
    --amber:     #f59e0b;
    --green:     #22c55e;
    --red:       #ef4444;
    --muted:     #6b7694;
    --text:      #c9d1e8;
    --text-dim:  #8892a8;
    --mono:      'JetBrains Mono', monospace;
    --sans:      'Inter', sans-serif;
  }

  html { background: var(--bg); color: var(--text); font-family: var(--sans); font-size: 14px; line-height: 1.5; }
  body { min-height: 100vh; padding: 0 0 60px; }

  /* ── Layout ── */
  .shell { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

  /* ── Header ── */
  header {
    border-bottom: 1px solid var(--border);
    padding: 18px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--surface);
    position: sticky;
    top: 0;
    z-index: 100;
  }
  .logo {
    font-family: var(--mono);
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
    letter-spacing: 0.04em;
  }
  .logo span { color: var(--blue); }
  .header-meta {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
  }

  /* ── Stats bar ── */
  .stats-bar {
    display: flex;
    gap: 0;
    border-bottom: 1px solid var(--border);
    background: var(--surface);
  }
  .stat-item {
    flex: 1;
    padding: 14px 20px;
    border-right: 1px solid var(--border);
    min-width: 0;
  }
  .stat-item:last-child { border-right: none; }
  .stat-label {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 4px;
  }
  .stat-value {
    font-family: var(--mono);
    font-size: 22px;
    font-weight: 600;
    color: var(--text);
  }
  .stat-value.blue { color: var(--blue); }
  .stat-value.green { color: var(--green); }
  .stat-value.amber { color: var(--amber); }

  /* ── Section headers ── */
  .section { margin-top: 32px; }
  .section-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
  }
  .section-title {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted);
  }
  .section-line { flex: 1; height: 1px; background: var(--border); }

  /* ── Next milestone ── */
  .milestone-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-left: 3px solid var(--blue);
    border-radius: 6px;
    padding: 20px 24px;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 16px;
    align-items: start;
  }
  .milestone-label {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--blue);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 6px;
  }
  .milestone-name {
    font-size: 18px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 12px;
  }
  .milestone-bar-wrap { display: flex; align-items: center; gap: 12px; }
  .milestone-bar-bg {
    flex: 1;
    height: 3px;
    background: var(--border2);
    border-radius: 2px;
    overflow: hidden;
  }
  .milestone-bar-fill {
    height: 100%;
    background: var(--blue);
    border-radius: 2px;
    transition: width 0.4s ease;
  }
  .milestone-pct {
    font-family: var(--mono);
    font-size: 12px;
    color: var(--blue);
    white-space: nowrap;
  }
  .milestone-edit-btn {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--muted);
    background: none;
    border: 1px solid var(--border2);
    border-radius: 4px;
    padding: 3px 8px;
    cursor: pointer;
    margin-left: 8px;
    transition: color 0.15s, border-color 0.15s;
  }
  .milestone-edit-btn:hover { color: var(--blue); border-color: var(--blue-dim); }
  .milestone-quote {
    font-size: 12px;
    color: var(--text-dim);
    font-style: italic;
    margin-top: 12px;
    border-top: 1px solid var(--border);
    padding-top: 12px;
  }
  .milestone-quote cite {
    display: block;
    font-style: normal;
    font-family: var(--mono);
    font-size: 10px;
    color: var(--muted);
    margin-top: 4px;
  }
  .milestone-streak {
    text-align: right;
    min-width: 100px;
  }
  .streak-fire { font-size: 22px; line-height: 1; margin-bottom: 4px; }
  .streak-num {
    font-family: var(--mono);
    font-size: 28px;
    font-weight: 600;
    color: var(--amber);
    line-height: 1;
  }
  .streak-label {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
  }
  .streak-best {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--muted);
    margin-top: 6px;
  }

  /* ── Inline progress edit ── */
  .progress-edit-inline {
    display: none;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
  }
  .progress-edit-inline.active { display: flex; }
  .progress-edit-inline input[type=range] {
    flex: 1;
    accent-color: var(--blue);
    cursor: pointer;
  }
  .progress-edit-inline input[type=number] {
    width: 54px;
    background: var(--surface2);
    border: 1px solid var(--border2);
    color: var(--text);
    font-family: var(--mono);
    font-size: 12px;
    padding: 4px 6px;
    border-radius: 4px;
    text-align: center;
  }
  .progress-edit-inline input[type=number]:focus { outline: 1px solid var(--blue); }
  .progress-save-btn {
    font-family: var(--mono);
    font-size: 10px;
    padding: 4px 10px;
    background: var(--blue);
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
  }
  .progress-save-btn:hover { background: var(--blue-dim); }

  /* ── Cert cards ── */
  .cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 12px;
  }
  .cert-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 18px 20px;
    transition: border-color 0.15s;
    position: relative;
  }
  .cert-card:hover { border-color: var(--border2); }
  .cert-card.status-active { border-left: 3px solid var(--blue); }
  .cert-card.status-upcoming { border-left: 3px solid var(--amber); }
  .cert-card.status-planned { border-left: 3px solid var(--muted); }
  .cert-card.status-completed { border-left: 3px solid var(--green); }

  .cert-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; margin-bottom: 12px; }
  .cert-name { font-size: 14px; font-weight: 600; color: var(--text); flex: 1; line-height: 1.3; }
  .cert-issuer { font-family: var(--mono); font-size: 10px; color: var(--muted); margin-top: 3px; }

  .badge {
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 3px 8px;
    border-radius: 99px;
    white-space: nowrap;
    flex-shrink: 0;
  }
  .badge.active   { background: rgba(74,158,255,.15); color: var(--blue); border: 1px solid rgba(74,158,255,.3); }
  .badge.upcoming { background: rgba(245,158,11,.12); color: var(--amber); border: 1px solid rgba(245,158,11,.3); }
  .badge.planned  { background: rgba(107,118,148,.12); color: var(--muted); border: 1px solid rgba(107,118,148,.25); }
  .badge.completed{ background: rgba(34,197,94,.12); color: var(--green); border: 1px solid rgba(34,197,94,.3); }

  .cert-progress-wrap { margin: 10px 0 6px; }
  .cert-progress-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
  }
  .cert-progress-pct {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--blue);
  }
  .cert-progress-hours {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--muted);
  }
  .pbar-bg {
    height: 2px;
    background: var(--border2);
    border-radius: 1px;
    overflow: hidden;
  }
  .pbar-fill {
    height: 100%;
    border-radius: 1px;
    transition: width 0.4s ease;
  }
  .pbar-fill.blue  { background: var(--blue); }
  .pbar-fill.amber { background: var(--amber); }
  .pbar-fill.green { background: var(--green); }
  .pbar-fill.muted { background: var(--muted); }

  .cert-unlock {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 12px;
  }
  .unlock-tag {
    font-family: var(--mono);
    font-size: 9px;
    color: var(--text-dim);
    background: var(--surface2);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 2px 7px;
  }
  .cert-timeline-info {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--muted);
    margin-top: 10px;
  }
  .cert-edit-btn {
    font-family: var(--mono);
    font-size: 9px;
    color: var(--muted);
    background: none;
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 3px 7px;
    cursor: pointer;
    margin-top: 10px;
    transition: color 0.15s, border-color 0.15s;
  }
  .cert-edit-btn:hover { color: var(--blue); border-color: var(--blue-dim); }
  .cert-inline-edit {
    display: none;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
  }
  .cert-inline-edit.active { display: flex; }
  .cert-inline-edit input[type=range] { flex: 1; accent-color: var(--blue); cursor: pointer; }
  .cert-inline-edit input[type=number] {
    width: 50px;
    background: var(--surface2);
    border: 1px solid var(--border2);
    color: var(--text);
    font-family: var(--mono);
    font-size: 11px;
    padding: 3px 5px;
    border-radius: 4px;
    text-align: center;
  }
  .cert-inline-edit input[type=number]:focus { outline: 1px solid var(--blue); }
  .cert-save-btn {
    font-family: var(--mono);
    font-size: 9px;
    padding: 4px 8px;
    background: var(--blue);
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    white-space: nowrap;
  }
  .cert-save-btn:hover { opacity: 0.85; }

  /* ── Timeline ── */
  .timeline {
    position: relative;
    padding-left: 28px;
    display: flex;
    flex-direction: column;
    gap: 0;
  }
  .timeline-axis {
    position: absolute;
    left: 8px;
    top: 12px;
    bottom: 12px;
    width: 1px;
    background: var(--border2);
  }
  .timeline-item {
    position: relative;
    padding: 0 0 24px 24px;
  }
  .timeline-item:last-child { padding-bottom: 0; }
  .timeline-dot {
    position: absolute;
    left: -20px;
    top: 10px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid var(--bg);
  }
  .timeline-dot.blue   { background: var(--blue); }
  .timeline-dot.amber  { background: var(--amber); }
  .timeline-dot.muted  { background: var(--muted); }
  .timeline-dot.green  { background: var(--green); }
  .timeline-dot.today  { background: var(--red); box-shadow: 0 0 0 3px rgba(239,68,68,.2); }

  .timeline-row {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 12px 16px;
  }
  .timeline-date {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--muted);
    white-space: nowrap;
    min-width: 72px;
    padding-top: 2px;
  }
  .timeline-name { font-size: 13px; font-weight: 500; color: var(--text); }
  .timeline-issuer { font-family: var(--mono); font-size: 10px; color: var(--muted); margin-top: 2px; }
  .timeline-today-marker {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 0 18px 0;
  }
  .today-pip {
    position: absolute;
    left: -20px;
    top: 6px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--red);
    box-shadow: 0 0 0 3px rgba(239,68,68,.2);
  }
  .today-label {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--red);
    background: rgba(239,68,68,.1);
    border: 1px solid rgba(239,68,68,.25);
    border-radius: 4px;
    padding: 3px 8px;
  }

  /* ── Session logger ── */
  .logger-layout { display: grid; grid-template-columns: 1fr 340px; gap: 16px; }
  @media (max-width: 768px) { .logger-layout { grid-template-columns: 1fr; } }

  .form-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 20px;
  }
  .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; }
  @media (max-width: 500px) { .form-row { grid-template-columns: 1fr; } }
  .form-group { display: flex; flex-direction: column; gap: 5px; }
  .form-group.full { grid-column: 1 / -1; }
  .form-label {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
  }
  .form-control {
    background: var(--surface2);
    border: 1px solid var(--border2);
    color: var(--text);
    font-family: var(--mono);
    font-size: 12px;
    padding: 8px 10px;
    border-radius: 4px;
    width: 100%;
    appearance: none;
    -webkit-appearance: none;
  }
  .form-control:focus { outline: 1px solid var(--blue); border-color: var(--blue); }
  .form-control option { background: var(--surface2); }
  textarea.form-control { resize: vertical; min-height: 64px; line-height: 1.5; }
  .btn-primary {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    padding: 9px 18px;
    background: var(--blue);
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    letter-spacing: 0.05em;
    transition: opacity 0.15s;
  }
  .btn-primary:hover { opacity: 0.85; }

  /* ── Session log ── */
  .sessions-list { display: flex; flex-direction: column; gap: 6px; max-height: 380px; overflow-y: auto; }
  .sessions-list::-webkit-scrollbar { width: 4px; }
  .sessions-list::-webkit-scrollbar-track { background: transparent; }
  .sessions-list::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 2px; }

  .session-item {
    background: var(--surface2);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 10px 12px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
  }
  .session-left { flex: 1; min-width: 0; }
  .session-cert { font-family: var(--mono); font-size: 11px; color: var(--blue); margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .session-date { font-family: var(--mono); font-size: 10px; color: var(--muted); }
  .session-note { font-size: 11px; color: var(--text-dim); margin-top: 3px; line-height: 1.4; }
  .session-hours { font-family: var(--mono); font-size: 13px; font-weight: 600; color: var(--text); white-space: nowrap; }
  .session-hrs-label { font-size: 9px; color: var(--muted); display: block; text-align: right; }
  .session-delete {
    background: none;
    border: none;
    color: var(--muted);
    cursor: pointer;
    font-size: 14px;
    padding: 0 2px;
    line-height: 1;
    transition: color 0.15s;
  }
  .session-delete:hover { color: var(--red); }
  .empty-state {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
    text-align: center;
    padding: 24px;
    border: 1px dashed var(--border2);
    border-radius: 6px;
  }

  /* ── Hours per cert ── */
  .hours-breakdown { display: flex; flex-direction: column; gap: 8px; }
  .hours-row { display: flex; align-items: center; gap: 10px; }
  .hours-cert-name { flex: 1; font-size: 12px; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .hours-pbar-bg { flex: 2; height: 3px; background: var(--border2); border-radius: 2px; overflow: hidden; }
  .hours-pbar-fill { height: 100%; background: var(--blue); border-radius: 2px; }
  .hours-total { font-family: var(--mono); font-size: 11px; color: var(--text); white-space: nowrap; min-width: 32px; text-align: right; }

  /* ── Responsive ── */
  @media (max-width: 600px) {
    .stats-bar { flex-wrap: wrap; }
    .stat-item { flex: 1 1 50%; border-bottom: 1px solid var(--border); }
    .milestone-card { grid-template-columns: 1fr; }
    .milestone-streak { text-align: left; }
  }
  @media (max-width: 420px) {
    .cert-grid { grid-template-columns: 1fr; }
  }

  /* ── Exam Countdown ── */
  .countdown-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-left: 3px solid var(--blue);
    border-radius: 6px;
    padding: 20px 24px;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 16px;
    align-items: center;
    transition: border-color 0.2s;
  }
  .countdown-card.soon   { border-left-color: var(--amber); }
  .countdown-card.urgent { border-left-color: var(--red); }
  .countdown-card.passed { border-left-color: var(--green); }
  .countdown-label {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--blue);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 6px;
  }
  .countdown-card.soon   .countdown-label { color: var(--amber); }
  .countdown-card.urgent .countdown-label { color: var(--red); }
  .countdown-card.passed .countdown-label { color: var(--green); }
  .countdown-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
  }
  .countdown-target {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
  }
  .countdown-clock { display: flex; gap: 20px; }
  .countdown-unit { text-align: center; min-width: 40px; }
  .countdown-num {
    font-family: var(--mono);
    font-size: 34px;
    font-weight: 600;
    color: var(--text);
    line-height: 1;
    font-variant-numeric: tabular-nums;
  }
  .countdown-card.soon   .countdown-num { color: var(--amber); }
  .countdown-card.urgent .countdown-num { color: var(--red); }
  .countdown-card.passed .countdown-num { color: var(--green); }
  .countdown-unit-label {
    font-family: var(--mono);
    font-size: 9px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-top: 4px;
  }
  .countdown-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
  .countdown-actions-btns { display: flex; gap: 6px; }
  .countdown-edit-row {
    display: none;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
    grid-column: 1 / -1;
    flex-wrap: wrap;
    border-top: 1px solid var(--border);
    padding-top: 12px;
  }
  .countdown-edit-row.active { display: flex; }
  .countdown-quote {
    font-size: 12px;
    color: var(--text-dim);
    font-style: italic;
    margin-top: 12px;
    border-top: 1px solid var(--border);
    padding-top: 12px;
    grid-column: 1 / -1;
  }
  @media (max-width: 600px) {
    .countdown-card { grid-template-columns: 1fr; }
    .countdown-actions { align-items: flex-start; }
    .countdown-clock { gap: 14px; }
  }

  /* ── Job Applications ── */
  .jobs-table-wrap { overflow-x: auto; }
  .jobs-table { width: 100%; border-collapse: collapse; min-width: 1200px; }
  .jobs-table th {
    font-family: var(--mono);
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--muted);
    text-align: left;
    padding: 8px 10px;
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
  }
  .jobs-table td {
    padding: 10px;
    border-bottom: 1px solid var(--border);
    font-size: 12px;
    color: var(--text-dim);
    vertical-align: top;
  }
  .jobs-table tr:hover td { background: var(--surface2); }
  .job-company { font-weight: 600; color: var(--text); white-space: nowrap; }
  .job-title-cell { color: var(--text); white-space: nowrap; }
  .job-desc-cell, .job-notes-cell {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .job-link { color: var(--blue); text-decoration: none; font-family: var(--mono); font-size: 10px; }
  .job-link:hover { text-decoration: underline; }
  .mode-tag {
    font-family: var(--mono);
    font-size: 9px;
    padding: 2px 7px;
    border-radius: 4px;
    border: 1px solid var(--border2);
    color: var(--text-dim);
    white-space: nowrap;
  }
  .job-delete-btn {
    background: none;
    border: none;
    color: var(--muted);
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
  }
  .job-delete-btn:hover { color: var(--red); }
  .badge.applied      { background: rgba(74,158,255,.15); color: var(--blue);  border: 1px solid rgba(74,158,255,.3); }
  .badge.interviewing { background: rgba(245,158,11,.12); color: var(--amber); border: 1px solid rgba(245,158,11,.3); }
  .badge.offer        { background: rgba(34,197,94,.12);  color: var(--green); border: 1px solid rgba(34,197,94,.3); }
  .badge.rejected      { background: rgba(239,68,68,.12); color: var(--red);   border: 1px solid rgba(239,68,68,.3); }

  /* ── Header actions (backup) ── */
  .header-right { display: flex; align-items: center; gap: 12px; }
  .header-actions { display: flex; gap: 6px; }
  .header-actions button {
    font-family: var(--mono);
    font-size: 9px;
    color: var(--muted);
    background: none;
    border: 1px solid var(--border2);
    border-radius: 4px;
    padding: 4px 8px;
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s;
  }
  .header-actions button:hover { color: var(--blue); border-color: var(--blue-dim); }

  /* ── Study heatmap ── */
  .heatmap-wrap { overflow-x: auto; padding-bottom: 4px; }
  .heatmap-wrap::-webkit-scrollbar { height: 4px; }
  .heatmap-wrap::-webkit-scrollbar-track { background: transparent; }
  .heatmap-wrap::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 2px; }
  .heatmap-grid {
    display: grid;
    grid-auto-flow: column;
    grid-template-rows: repeat(7, 12px);
    gap: 3px;
    width: max-content;
  }
  .heatmap-cell {
    width: 12px;
    height: 12px;
    border-radius: 2px;
    background: var(--surface2);
    border: 1px solid var(--border);
  }
  .heatmap-cell.level-1 { background: rgba(74,158,255,.25); border-color: rgba(74,158,255,.35); }
  .heatmap-cell.level-2 { background: rgba(74,158,255,.5);  border-color: rgba(74,158,255,.55); }
  .heatmap-cell.level-3 { background: rgba(74,158,255,.75); border-color: rgba(74,158,255,.8); }
  .heatmap-cell.level-4 { background: var(--blue); border-color: var(--blue); }
  .heatmap-legend {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    font-family: var(--mono);
    font-size: 9px;
    color: var(--muted);
  }
  .heatmap-legend-cells { display: flex; gap: 3px; }

  /* ── Toast ── */
  .toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--surface2);
    border: 1px solid var(--border2);
    border-left: 3px solid var(--green);
    color: var(--text);
    font-family: var(--mono);
    font-size: 11px;
    padding: 10px 16px;
    border-radius: 6px;
    z-index: 999;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.2s, transform 0.2s;
    pointer-events: none;
  }
  .toast.show { opacity: 1; transform: translateY(0); }

  /* ── Horizontal timeline (desktop) ── */
  .htl-wrap {
    overflow-x: auto;
    padding-bottom: 8px;
  }
  .htl-wrap::-webkit-scrollbar { height: 4px; }
  .htl-wrap::-webkit-scrollbar-track { background: transparent; }
  .htl-wrap::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 2px; }
  .htl {
    display: flex;
    align-items: flex-start;
    gap: 0;
    min-width: max-content;
    padding: 20px 0 10px;
    position: relative;
  }
  .htl-axis {
    position: absolute;
    left: 0; right: 0;
    top: 32px;
    height: 1px;
    background: var(--border2);
  }
  .htl-node { display: flex; flex-direction: column; align-items: center; position: relative; padding: 0 32px; }
  .htl-dot-wrap { position: relative; z-index: 1; margin-bottom: 10px; }
  .htl-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid var(--bg);
  }
  .htl-dot.blue   { background: var(--blue); }
  .htl-dot.amber  { background: var(--amber); }
  .htl-dot.muted  { background: var(--muted); }
  .htl-dot.green  { background: var(--green); }
  .htl-today-dot  { background: var(--red); box-shadow: 0 0 0 3px rgba(239,68,68,.2); }
  .htl-label { text-align: center; max-width: 120px; }
  .htl-date { font-family: var(--mono); font-size: 9px; color: var(--muted); margin-bottom: 3px; }
  .htl-name { font-size: 11px; font-weight: 500; color: var(--text); line-height: 1.3; }
  .htl-issuer { font-family: var(--mono); font-size: 9px; color: var(--muted); margin-top: 2px; }
  .htl-today-label {
    font-family: var(--mono);
    font-size: 9px;
    color: var(--red);
    background: rgba(239,68,68,.1);
    border: 1px solid rgba(239,68,68,.25);
    border-radius: 4px;
    padding: 2px 6px;
    white-space: nowrap;
  }

  /* ── Cross-page nav links ── */
  .text-link {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--blue);
    text-decoration: none;
    white-space: nowrap;
  }
  .text-link:hover { text-decoration: underline; }
  .back-link {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--muted);
    text-decoration: none;
  }
  .back-link:hover { color: var(--blue); }

  /* ── Filter bar ── */
  .filter-bar {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
  }
  .filter-bar .form-group { min-width: 180px; }
