:root {
    --bg: #0d0d0d;
    --bg2: #141414;
    --bg3: #1a1a1a;
    --border: #2a2a2a;
    --border-hover: #444;
    --orange: #ff5500;
    --orange-dim: #c43d00;
    --orange-glow: rgba(255,85,0,0.15);
    --red: #e03030;
    --yellow: #e8a020;
    --green: #3a9e5f;
    --text: #d4d4d4;
    --text-dim: #777;
    --text-bright: #f0f0f0;
    --mono: 'JetBrains Mono', monospace;
    --display: 'Barlow Condensed', sans-serif;
  }

  /* ─── LIGHT THEME ─── */
  body.light {
    --bg: #f8f5f2;
    --bg2: #ffffff;
    --bg3: #f0ece8;
    --border: #ddd;
    --border-hover: #bbb;
    --orange: #e84800;
    --orange-dim: #c43d00;
    --orange-glow: rgba(232,72,0,0.1);
    --red: #cc2222;
    --yellow: #b87800;
    --green: #2e7d4f;
    --text: #2a2a2a;
    --text-dim: #888;
    --text-bright: #0a0a0a;
  }

  body.light #topbar::after {
    background: linear-gradient(90deg, var(--orange) 0%, transparent 60%);
  }

  body.light .doc-content code { background: #f0ece8; border-color: #ddd; color: #2e7d4f; }
  body.light .doc-content pre { background: #f0ece8; border-color: #ddd; color: #333; }
  body.light .doc-content tr:nth-child(even) td { background: rgba(0,0,0,0.02); }
  body.light .alert-box.critical { background: rgba(204,34,34,0.06); color: #aa2222; }
  body.light .alert-box.warn { background: rgba(232,72,0,0.06); color: #c04000; }
  body.light .alert-box.info { background: rgba(60,100,200,0.06); color: #4466aa; }
  body.light .gone-ref { color: var(--red); }
  body.light .comment-line.urgent { color: #cc2222; }
  body.light .comment-line.jerome { color: #c04000; }
  body.light .dot-red { background: #cc2222; box-shadow: 0 0 6px rgba(204,34,34,0.4); }

  /* ─── THEME TOGGLE BUTTON ─── */
  #theme-toggle {
    background: var(--bg3);
    border: 1px solid var(--border);
    border-radius: 4px;
    color: var(--text-dim);
    font-family: var(--mono);
    font-size: 11px;
    padding: 5px 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    letter-spacing: 0.05em;
    transition: all 0.15s;
  }
  #theme-toggle:hover { border-color: var(--orange); color: var(--orange); }

  /* ─── TOP NAV TABS ─── */
  #topnav {
    display: flex;
    align-items: center;
    gap: 2px;
    flex: 1;
    justify-content: center;
  }
  .tnav {
    padding: 6px 16px;
    font-family: var(--display);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-dim);
    cursor: pointer;
    border-radius: 4px;
    border: 1px solid transparent;
    transition: all 0.15s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 6px;
  }
  .tnav:hover { color: var(--text); background: var(--bg3); }
  .tnav.active { color: var(--orange); border-color: rgba(255,85,0,0.3); background: rgba(255,85,0,0.07); }

  /* ─── TOPBAR ACTIONS ─── */
  #topbar-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
  }
  .tb-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 5px 11px;
    background: var(--bg3);
    border: 1px solid var(--border);
    border-radius: 4px;
    color: var(--text-dim);
    font-family: var(--mono);
    font-size: 11px;
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
  }
  .tb-btn:hover { border-color: var(--orange); color: var(--orange); }

  /* ─── PAGE SYSTEM ─── */
  /*
   * position:fixed coupe tout lien avec le flex-layout de body.
   * top:52px = hauteur du topbar.
   * display:none sur l'élément lui-même (pas un parent) = garanti invisible.
   */
  #page-docs,
  #page-vitrine,
  #page-about {
    display: none;
    position: fixed;
    top: 52px;
    left: 0;
    right: 0;
    bottom: 0;
    flex-direction: column;
    overflow: hidden;
    background: var(--bg);
    z-index: 1;
  }
  #page-vitrine,
  #page-about {
    overflow-y: auto;
  }
  #page-docs.active,
  #page-vitrine.active,
  #page-about.active {
    display: flex;
  }
  #topbar {
    position: relative;
    z-index: 10;
  }
  #statsbar { flex-shrink: 0; }

  /* ─── VITRINE PAGE ─── */
  .vt-hero {
    background: linear-gradient(160deg, #0d0d0d 0%, #1a0a00 50%, #0d0d0d 100%);
    border-bottom: 1px solid var(--border);
    padding: 70px 60px 60px;
    position: relative;
    overflow: hidden;
  }
  body.light .vt-hero { background: linear-gradient(160deg, #f8f5f2 0%, #fff3ec 50%, #f8f5f2 100%); }
  .vt-hero::before {
    content: 'KTN';
    position: absolute;
    right: -20px; top: -40px;
    font-family: var(--display);
    font-size: 280px;
    font-weight: 900;
    color: rgba(255,85,0,0.04);
    letter-spacing: -0.02em;
    pointer-events: none;
    user-select: none;
    line-height: 1;
  }
  .vt-hero-eyebrow {
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--orange);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
  }
  .vt-hero-eyebrow::after { content:''; flex: 0 0 40px; height: 1px; background: var(--orange); opacity: 0.5; }
  .vt-hero-title {
    font-family: var(--display);
    font-size: 88px;
    font-weight: 900;
    line-height: 0.9;
    letter-spacing: -0.02em;
    color: var(--text-bright);
    text-transform: uppercase;
    margin-bottom: 8px;
  }
  .vt-hero-title span { color: var(--orange); }
  .vt-hero-sub {
    font-family: var(--display);
    font-size: 20px;
    font-weight: 300;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--text-dim);
    margin-bottom: 32px;
  }
  .vt-hero-tagline {
    font-family: var(--mono);
    font-size: 13px;
    color: var(--text);
    line-height: 1.8;
    max-width: 560px;
    border-left: 3px solid var(--orange);
    padding-left: 16px;
  }
  .vt-hero-tagline em { color: var(--text-dim); font-style: italic; }

  .vt-badges {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 28px;
  }
  .vt-badge {
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: 3px;
    border: 1px solid rgba(255,85,0,0.35);
    background: rgba(255,85,0,0.08);
    color: var(--orange);
  }
  .vt-badge.grey { border-color: var(--border); background: transparent; color: var(--text-dim); }

  /* Sections vitrine */
  .vt-section {
    padding: 48px 60px;
    border-bottom: 1px solid var(--border);
  }
  .vt-section-label {
    font-family: var(--mono);
    font-size: 9px;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--orange);
    margin-bottom: 6px;
  }
  .vt-section-title {
    font-family: var(--display);
    font-size: 42px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: var(--text-bright);
    margin-bottom: 6px;
    line-height: 1;
  }
  .vt-section-sub {
    font-size: 12px;
    color: var(--text-dim);
    margin-bottom: 28px;
    font-style: italic;
  }

  /* Cards */
  .vt-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 12px;
  }
  .vt-card {
    background: var(--bg2);
    border: 1px solid var(--border);
    border-radius: 6px;
    position: relative;
    overflow: hidden;
    transition: border-color 0.15s, transform 0.15s;
    display: flex;
    flex-direction: column;
  }
  .vt-card:hover { border-color: var(--orange); transform: translateY(-2px); }
  .vt-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: var(--orange);
    opacity: 0;
    transition: opacity 0.15s;
    z-index: 2;
  }
  .vt-card:hover::before { opacity: 1; }
  .vt-card-photo {
    width: 100%; height: 190px; flex-shrink: 0;
    overflow: hidden; background: #0d0d0d;
    position: relative;
    display: flex; align-items: center; justify-content: center;
    font-size: 52px;
  }
  .vt-card-photo img {
    width: 100%; height: 100%; object-fit: cover; display: block;
    filter: saturate(0.85) contrast(1.05);
    transition: transform 0.4s, filter 0.3s;
  }
  .vt-card:hover .vt-card-photo img { transform: scale(1.06); filter: saturate(1.1) contrast(1.1); }
  .vt-card-photo-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(13,13,13,0.55) 0%, transparent 55%);
    pointer-events: none;
  }
  body.light .vt-card-photo-overlay { background: linear-gradient(to top, rgba(0,0,0,0.2) 0%, transparent 55%); }
  .vt-card-badge {
    position: absolute; top: 10px; right: 10px; z-index: 3;
    font-size: 9px; padding: 3px 8px; border-radius: 2px;
    text-transform: uppercase; letter-spacing: 0.08em; font-weight: 700;
    backdrop-filter: blur(4px);
  }
  .vt-card-badge.orange { background: rgba(255,85,0,0.88); color:#fff; }
  .vt-card-badge.grey   { background: rgba(0,0,0,0.65); color:#bbb; border:1px solid #333; }
  .vt-card-badge.red    { background: rgba(200,30,30,0.88); color:#fff; }
  .vt-card-badge.yellow { background: rgba(180,120,0,0.88); color:#fff; }
  .vt-card-body { padding: 20px; flex: 1; }
  .vt-card-model {
    font-family: var(--display);
    font-size: 18px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-bright);
    margin-bottom: 2px;
  }
  .vt-card-cc {
    font-size: 10px;
    color: var(--text-dim);
    letter-spacing: 0.1em;
    margin-bottom: 12px;
  }
  .vt-card-price {
    font-family: var(--display);
    font-size: 28px;
    font-weight: 900;
    color: var(--orange);
    line-height: 1;
  }
  .vt-card-price-note {
    font-size: 9px;
    color: var(--red);
    letter-spacing: 0.05em;
    margin-top: 2px;
    font-family: var(--mono);
  }
  .vt-card-stock {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 12px;
    font-size: 10px;
    color: var(--text-dim);
    letter-spacing: 0.06em;
  }

  /* Stats row */
  .vt-stats-row {
    display: flex;
    gap: 1px;
    background: var(--border);
    border: 1px solid var(--border);
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 28px;
  }
  .vt-stat-cell {
    flex: 1;
    background: var(--bg2);
    padding: 16px;
    text-align: center;
  }
  .vt-stat-num {
    font-family: var(--display);
    font-weight: 900;
    font-size: 34px;
    display: block;
    color: var(--orange);
    line-height: 1;
  }
  .vt-stat-label {
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-dim);
    display: block;
    margin-top: 3px;
  }

  /* Alerte vitrine */
  .vt-alert {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    background: rgba(255,85,0,0.06);
    border: 1px solid rgba(255,85,0,0.3);
    border-radius: 6px;
    padding: 14px 18px;
    margin-top: 20px;
    font-size: 12px;
    color: var(--text);
    line-height: 1.7;
  }
  .vt-alert.red { background: rgba(224,48,48,0.06); border-color: rgba(224,48,48,0.3); }
  .vt-alert-icon { font-size: 18px; flex-shrink: 0; }

  /* Services */
  .vt-services {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
  }
  .vt-service {
    background: var(--bg2);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 20px;
    transition: border-color 0.15s;
  }
  .vt-service:hover { border-color: var(--border-hover); }
  .vt-service-icon { font-size: 28px; margin-bottom: 10px; display: block; }
  .vt-service-name {
    font-family: var(--display);
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-bright);
    margin-bottom: 4px;
  }
  .vt-service-desc { font-size: 11px; color: var(--text-dim); line-height: 1.6; }
  .vt-service-caveat { font-size: 10px; color: var(--red); margin-top: 8px; font-style: italic; }

  /* Footer vitrine */
  .vt-footer {
    padding: 32px 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--bg2);
    border-top: 1px solid var(--border);
  }
  .vt-footer-logo {
    font-family: var(--display);
    font-size: 32px;
    font-weight: 900;
    color: var(--orange);
    letter-spacing: 0.05em;
  }
  .vt-footer-copy {
    font-size: 10px;
    color: var(--text-dim);
    text-align: right;
    line-height: 1.8;
    letter-spacing: 0.05em;
  }

  /* ─── GLOBAL SEARCH OVERLAY ─── */
  #global-search-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    z-index: 1000;
    align-items: flex-start;
    justify-content: center;
    padding-top: 80px;
  }
  #global-search-overlay.open { display: flex; }
  body.light #global-search-overlay { background: rgba(0,0,0,0.4); }

  #global-search-box {
    background: var(--bg2);
    border: 1px solid var(--orange);
    border-radius: 6px;
    width: 600px;
    max-width: 90vw;
    box-shadow: 0 20px 60px rgba(0,0,0,0.6);
    overflow: hidden;
  }

  #global-search-input {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border);
    padding: 14px 18px;
    font-family: var(--mono);
    font-size: 14px;
    color: var(--text-bright);
    outline: none;
  }
  #global-search-input::placeholder { color: var(--text-dim); }

  #global-search-results {
    max-height: 380px;
    overflow-y: auto;
    padding: 8px 0;
  }

  .gsr-item {
    padding: 10px 18px;
    cursor: pointer;
    border-bottom: 1px solid var(--border);
    transition: background 0.1s;
  }
  .gsr-item:hover { background: var(--orange-glow); }
  .gsr-item:last-child { border-bottom: none; }

  .gsr-name { font-size: 12px; color: var(--text-bright); font-weight: 500; }
  .gsr-path { font-size: 10px; color: var(--text-dim); margin-top: 1px; }
  .gsr-snippet { font-size: 11px; color: var(--orange); margin-top: 4px; font-style: italic; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .gsr-match { background: rgba(255,85,0,0.25); border-radius: 2px; padding: 0 2px; }

  #global-search-hint {
    padding: 10px 18px;
    font-size: 10px;
    color: var(--text-dim);
    border-top: 1px solid var(--border);
    letter-spacing: 0.08em;
  }

  /* ─── NOTES ZONE ─── */
  #notes-zone {
    flex-shrink: 0;
    border-top: 1px solid var(--border);
    background: var(--bg2);
    display: flex;
    flex-direction: column;
  }

  #notes-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 16px;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    user-select: none;
  }

  #notes-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-dim);
  }

  #notes-header-left .notes-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--orange);
    display: none;
  }
  #notes-header-left .notes-dot.visible { display: block; }

  #notes-toggle-icon {
    font-size: 10px;
    color: var(--text-dim);
    transition: transform 0.2s;
  }
  #notes-zone.expanded #notes-toggle-icon { transform: rotate(180deg); }

  #notes-area-wrap {
    display: none;
    padding: 10px 16px 12px;
    gap: 8px;
    flex-direction: column;
  }
  #notes-zone.expanded #notes-area-wrap { display: flex; }

  #notes-textarea {
    width: 100%;
    min-height: 80px;
    max-height: 180px;
    background: var(--bg3);
    border: 1px solid var(--border);
    border-radius: 3px;
    color: var(--text);
    font-family: var(--mono);
    font-size: 12px;
    padding: 8px 10px;
    resize: vertical;
    outline: none;
    line-height: 1.6;
    transition: border-color 0.15s;
  }
  #notes-textarea:focus { border-color: var(--orange); }
  #notes-textarea::placeholder { color: var(--text-dim); }

  .notes-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: space-between;
  }

  .notes-btn {
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    border-radius: 3px;
    padding: 5px 12px;
    cursor: pointer;
    border: 1px solid;
    transition: all 0.15s;
  }

  .notes-btn.save {
    background: var(--orange);
    border-color: var(--orange);
    color: #fff;
  }
  .notes-btn.save:hover { background: var(--orange-dim); }

  .notes-btn.clear {
    background: transparent;
    border-color: var(--border);
    color: var(--text-dim);
  }
  .notes-btn.clear:hover { border-color: var(--red); color: var(--red); }

  #notes-saved-msg {
    font-size: 10px;
    color: var(--green);
    opacity: 0;
    transition: opacity 0.3s;
    letter-spacing: 0.05em;
  }
  #notes-saved-msg.show { opacity: 1; }

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

  body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--mono);
    font-size: 13px;
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }

  /* ─── TOPBAR ─── */
  #topbar {
    background: var(--bg2);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    height: 52px;
    flex-shrink: 0;
    position: relative;
  }

  #topbar::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--orange) 0%, transparent 60%);
  }

  .logo {
    font-family: var(--display);
    font-weight: 900;
    font-size: 26px;
    letter-spacing: 0.05em;
    color: var(--orange);
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 10px;
  }

  .logo-sub {
    font-family: var(--display);
    font-weight: 300;
    font-size: 13px;
    color: var(--text-dim);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    border-left: 1px solid var(--border);
    padding-left: 12px;
    margin-left: 4px;
  }

  .tagline {
    font-family: var(--display);
    font-size: 11px;
    letter-spacing: 0.2em;
    color: var(--text-dim);
    text-transform: uppercase;
    font-style: italic;
  }

  /* ─── STATS BAR ─── */
  #statsbar {
    background: var(--bg2);
    border-bottom: 1px solid var(--border);
    display: flex;
    gap: 0;
    flex-shrink: 0;
    overflow-x: auto;
  }

  .stat {
    padding: 8px 20px;
    border-right: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    cursor: default;
  }

  .stat-num {
    font-family: var(--display);
    font-weight: 700;
    font-size: 20px;
    line-height: 1;
  }

  .stat-label {
    font-size: 10px;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    line-height: 1.3;
  }

  .s-red { color: var(--red); }
  .s-orange { color: var(--orange); }
  .s-yellow { color: var(--yellow); }
  .s-green { color: var(--green); }
  .s-dim { color: var(--text-dim); }

  /* ─── LAYOUT ─── */
  #main {
    display: flex;
    flex: 1;
    overflow: hidden;
  }

  /* ─── SIDEBAR ─── */
  #sidebar {
    width: 280px;
    flex-shrink: 0;
    background: var(--bg2);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }

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

  #sidebar-header span {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--text-dim);
  }

  #search {
    width: 100%;
    background: var(--bg3);
    border: 1px solid var(--border);
    border-radius: 3px;
    padding: 6px 10px;
    color: var(--text);
    font-family: var(--mono);
    font-size: 12px;
    margin: 10px 12px;
    width: calc(100% - 24px);
    outline: none;
    transition: border-color 0.2s;
  }

  #search:focus { border-color: var(--orange); }
  #search::placeholder { color: var(--text-dim); }

  #file-list {
    overflow-y: auto;
    flex: 1;
    padding: 4px 0;
  }

  #file-list::-webkit-scrollbar { width: 4px; }
  #file-list::-webkit-scrollbar-track { background: transparent; }
  #file-list::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

  .file-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 8px 16px;
    cursor: pointer;
    border-left: 2px solid transparent;
    transition: all 0.15s;
    position: relative;
  }

  .file-item:hover {
    background: var(--bg3);
    border-left-color: var(--border-hover);
  }

  .file-item.active {
    background: var(--orange-glow);
    border-left-color: var(--orange);
  }

  .file-icon {
    font-size: 14px;
    flex-shrink: 0;
    margin-top: 1px;
  }

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

  .file-name {
    font-size: 11.5px;
    color: var(--text-bright);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
  }

  .file-path {
    font-size: 10px;
    color: var(--text-dim);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
    margin-top: 2px;
  }

  .badge {
    font-size: 9px;
    padding: 2px 5px;
    border-radius: 2px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    flex-shrink: 0;
    font-weight: 700;
    margin-top: 2px;
  }

  .badge-red { background: rgba(224,48,48,0.2); color: #e07070; border: 1px solid rgba(224,48,48,0.3); }
  .badge-fire { background: rgba(255,85,0,0.2); color: #ff7040; border: 1px solid rgba(255,85,0,0.3); }
  .badge-orange { background: rgba(232,160,32,0.15); color: #e8b060; border: 1px solid rgba(232,160,32,0.3); }
  .badge-yellow { background: rgba(200,180,30,0.15); color: #cccc60; border: 1px solid rgba(200,180,30,0.3); }
  .badge-info { background: rgba(100,140,200,0.15); color: #88aadd; border: 1px solid rgba(100,140,200,0.3); }

  /* ─── VIEWER ─── */
  #viewer {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--bg);
  }

  #viewer-header {
    background: var(--bg2);
    border-bottom: 1px solid var(--border);
    padding: 10px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    min-height: 44px;
  }

  #viewer-title {
    font-family: var(--display);
    font-weight: 600;
    font-size: 16px;
    color: var(--text-bright);
    letter-spacing: 0.05em;
    flex: 1;
  }

  #viewer-meta {
    font-size: 11px;
    color: var(--text-dim);
  }

  #viewer-body {
    flex: 1;
    overflow-y: auto;
    padding: 28px 36px;
  }

  #viewer-body::-webkit-scrollbar { width: 6px; }
  #viewer-body::-webkit-scrollbar-track { background: transparent; }
  #viewer-body::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

  /* ─── CONTENT STYLES ─── */
  .doc-header {
    border-bottom: 1px solid var(--border);
    padding-bottom: 16px;
    margin-bottom: 24px;
  }

  .doc-title {
    font-family: var(--display);
    font-weight: 900;
    font-size: 32px;
    color: var(--text-bright);
    letter-spacing: 0.02em;
    line-height: 1.1;
    margin-bottom: 8px;
  }

  .doc-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
    align-items: center;
  }

  .meta-chip {
    background: var(--bg3);
    border: 1px solid var(--border);
    border-radius: 3px;
    padding: 3px 8px;
    font-size: 10px;
    color: var(--text-dim);
    letter-spacing: 0.05em;
  }

  .meta-chip.warn {
    border-color: rgba(255,85,0,0.4);
    color: #ff8040;
    background: rgba(255,85,0,0.08);
  }

  .doc-content {
    line-height: 1.7;
    color: var(--text);
  }

  .doc-content h2 {
    font-family: var(--display);
    font-weight: 700;
    font-size: 20px;
    color: var(--orange);
    margin: 28px 0 10px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border);
  }

  .doc-content h3 {
    font-family: var(--display);
    font-size: 16px;
    font-weight: 600;
    color: var(--text-bright);
    margin: 20px 0 8px;
    letter-spacing: 0.05em;
  }

  .doc-content p { margin-bottom: 10px; }

  .doc-content code {
    background: var(--bg3);
    border: 1px solid var(--border);
    border-radius: 3px;
    padding: 0 5px;
    font-family: var(--mono);
    font-size: 12px;
    color: #a8d8a8;
  }

  .doc-content pre {
    background: var(--bg3);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 16px;
    overflow-x: auto;
    margin: 12px 0;
    font-size: 12px;
    line-height: 1.6;
    color: #c8e8c8;
  }

  .doc-content pre::-webkit-scrollbar { height: 4px; }
  .doc-content pre::-webkit-scrollbar-thumb { background: var(--border); }

  .doc-content blockquote {
    border-left: 3px solid var(--orange);
    padding: 8px 16px;
    margin: 12px 0;
    background: var(--orange-glow);
    border-radius: 0 4px 4px 0;
    font-style: italic;
    color: var(--text-bright);
  }

  .doc-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 12px 0;
    font-size: 12px;
  }

  .doc-content th {
    background: var(--bg3);
    padding: 8px 12px;
    text-align: left;
    border: 1px solid var(--border);
    color: var(--text-dim);
    text-transform: uppercase;
    font-size: 10px;
    letter-spacing: 0.1em;
    font-weight: 500;
  }

  .doc-content td {
    padding: 7px 12px;
    border: 1px solid var(--border);
    vertical-align: top;
  }

  .doc-content tr:nth-child(even) td { background: rgba(255,255,255,0.02); }

  .doc-content ul, .doc-content ol {
    padding-left: 20px;
    margin: 8px 0;
  }

  .doc-content li { margin-bottom: 4px; }

  .alert-box {
    border: 1px solid;
    border-radius: 4px;
    padding: 12px 16px;
    margin: 12px 0;
    display: flex;
    gap: 10px;
    align-items: flex-start;
  }

  .alert-box.critical {
    border-color: rgba(224,48,48,0.5);
    background: rgba(224,48,48,0.07);
    color: #e08080;
  }

  .alert-box.warn {
    border-color: rgba(255,85,0,0.4);
    background: rgba(255,85,0,0.07);
    color: #ff8040;
  }

  .alert-box.info {
    border-color: rgba(100,140,200,0.3);
    background: rgba(100,140,200,0.06);
    color: #88aadd;
  }

  .alert-icon { font-size: 16px; flex-shrink: 0; }

  .comment-line {
    display: block;
    padding: 3px 0;
    color: var(--text-dim);
    font-style: italic;
  }

  .comment-line.strike { text-decoration: line-through; opacity: 0.5; }
  .comment-line.urgent { color: #e07070; }
  .comment-line.jerome { color: #ff7040; }

  .gone-ref {
    color: var(--red);
    font-size: 11px;
    font-weight: 500;
  }

  .status-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    margin-right: 5px;
  }

  .dot-green { background: #3a9e5f; }
  .dot-red { background: #e03030; box-shadow: 0 0 6px rgba(224,48,48,0.6); }
  .dot-yellow { background: #e8a020; }
  .dot-grey { background: #555; }

  /* ─── WELCOME SCREEN ─── */
  #welcome {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 20px;
    opacity: 0;
    animation: fadeIn 0.6s 0.3s forwards;
  }

  .welcome-logo {
    font-family: var(--display);
    font-weight: 900;
    font-size: 80px;
    color: var(--orange);
    letter-spacing: -0.02em;
    line-height: 1;
    text-shadow: 0 0 80px rgba(255,85,0,0.3);
  }

  .welcome-sub {
    font-family: var(--display);
    font-size: 16px;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--text-dim);
  }

  .welcome-hint {
    font-size: 12px;
    color: var(--text-dim);
    margin-top: 20px;
    text-align: center;
    line-height: 1.8;
  }

  .welcome-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--border);
    border: 1px solid var(--border);
    border-radius: 4px;
    overflow: hidden;
    margin-top: 10px;
    width: 500px;
  }

  .ws-cell {
    background: var(--bg2);
    padding: 14px;
    text-align: center;
  }

  .ws-num {
    font-family: var(--display);
    font-weight: 700;
    font-size: 28px;
    display: block;
  }

  .ws-label {
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-dim);
    display: block;
    margin-top: 2px;
  }

  /* ─── ANIMATIONS ─── */
  @keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
  }

  @keyframes slideIn {
    from { opacity: 0; transform: translateX(-8px); }
    to { opacity: 1; transform: translateX(0); }
  }

  .doc-content { animation: slideIn 0.2s ease forwards; }

  /* ─── SCROLLBAR GLOBAL ─── */
  ::-webkit-scrollbar { width: 6px; height: 6px; }
  ::-webkit-scrollbar-track { background: transparent; }
  ::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

  /* ─── ÉNONCÉ PINNED ─── */
  #enonce-pin {
    margin: 8px 12px 4px;
    padding: 9px 12px;
    border-radius: 4px;
    border: 1px solid rgba(100,140,200,0.35);
    background: rgba(100,140,200,0.07);
    cursor: pointer;
    transition: all 0.15s;
    display: flex;
    align-items: flex-start;
    gap: 8px;
  }
  #enonce-pin:hover { border-color: rgba(100,140,200,0.6); background: rgba(100,140,200,0.12); }
  #enonce-pin.active { border-color: rgba(100,140,200,0.7); background: rgba(100,140,200,0.15); }
  #enonce-pin-icon { font-size: 14px; flex-shrink: 0; margin-top: 1px; }
  #enonce-pin-info { flex: 1; min-width: 0; }
  #enonce-pin-name {
    font-size: 11.5px;
    color: #88aadd;
    font-weight: 600;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  #enonce-pin-sub {
    font-size: 10px;
    color: var(--text-dim);
    display: block;
    margin-top: 2px;
  }
  #enonce-pin-badge {
    font-size: 9px;
    padding: 2px 5px;
    border-radius: 2px;
    background: rgba(100,140,200,0.15);
    color: #88aadd;
    border: 1px solid rgba(100,140,200,0.3);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 700;
    flex-shrink: 0;
    margin-top: 2px;
  }
  #enonce-divider {
    margin: 6px 12px 2px;
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--text-dim);
    opacity: 0.6;
  }

  /* ─── FILTER TABS ─── */
  #filter-tabs {
    display: flex;
    gap: 0;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
  }

  .ftab {
    padding: 5px 12px;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-dim);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.15s;
    white-space: nowrap;
  }

  .ftab:hover { color: var(--text); }
  .ftab.active { color: var(--orange); border-bottom-color: var(--orange); }

  .hidden { display: none !important; }

/* ─── PAGE : ABOUT ─── */
.about-content {
  max-width: 960px;
  margin: 0 auto;
  padding: 40px 32px 60px;
}

.about-header {
  text-align: center;
  margin-bottom: 52px;
  padding-bottom: 36px;
  border-bottom: 1px solid var(--border);
}

.about-ktn-logo {
  font-family: var(--display);
  font-weight: 900;
  font-size: 100px;
  color: var(--orange);
  letter-spacing: -0.02em;
  line-height: 1;
  text-shadow: 0 0 80px rgba(255,85,0,0.25);
}

.about-corp-name {
  font-family: var(--display);
  font-weight: 300;
  font-size: 16px;
  letter-spacing: 0.5em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-top: 8px;
}

.about-tagline-big {
  font-family: var(--display);
  font-size: 14px;
  letter-spacing: 0.18em;
  color: var(--text-dim);
  margin-top: 16px;
  font-style: italic;
}

.about-meta-chips {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 24px;
}

.about-chip {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 4px 14px;
  font-size: 11px;
  color: var(--text-dim);
  letter-spacing: 0.04em;
}

.about-section {
  margin-bottom: 48px;
}

.about-section-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: 22px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--orange);
  margin-bottom: 18px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.about-text {
  font-size: 13px;
  line-height: 1.85;
  color: var(--text);
  margin-bottom: 14px;
}

/* ─── ABOUT STATS (réutilise .aws-*) ─── */
.about-workshop-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
}

.aws-cell {
  background: var(--bg2);
  padding: 16px;
  text-align: center;
}

.aws-num {
  font-family: var(--display);
  font-weight: 700;
  font-size: 28px;
  display: block;
  line-height: 1.1;
}

.aws-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  display: block;
  margin-top: 4px;
  line-height: 1.5;
}

/* ─── ABOUT TEAM ─── */
.about-team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
}

.about-team-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 16px;
  transition: border-color 0.15s;
}

.about-team-card:hover { border-color: var(--border-hover); }

.about-team-avatar {
  font-size: 28px;
  margin-bottom: 8px;
}

.about-team-name {
  font-family: var(--display);
  font-weight: 700;
  font-size: 15px;
  color: var(--text-bright);
  letter-spacing: 0.04em;
  margin-bottom: 2px;
}

.about-team-role {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--orange);
  margin-bottom: 8px;
}

.about-team-note {
  font-size: 11px;
  color: var(--text-dim);
  line-height: 1.6;
}

/* ─── ABOUT VALUES ─── */
.about-values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.about-value-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 16px 18px;
}

.about-value-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: 14px;
  color: var(--text-bright);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 6px;
}

.about-value-text {
  font-size: 11px;
  color: var(--text-dim);
  line-height: 1.65;
  margin-bottom: 6px;
}

.about-value-note {
  font-size: 10px;
  color: var(--red);
  font-style: italic;
  border-top: 1px solid var(--border);
  padding-top: 6px;
  margin-top: 4px;
  line-height: 1.5;
}

/* ─── ABOUT TIMELINE ─── */
.about-timeline {
  position: relative;
  padding-left: 28px;
}

.about-timeline::before {
  content: '';
  position: absolute;
  left: 7px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--border);
}

.about-tl-item {
  position: relative;
  padding: 0 0 24px 20px;
}

.about-tl-item::before {
  content: '';
  position: absolute;
  left: -5px;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border);
  border: 2px solid var(--bg);
}

.about-tl-item.red::before {
  background: var(--red);
  box-shadow: 0 0 6px rgba(224,48,48,0.5);
}

.about-tl-year {
  font-family: var(--display);
  font-weight: 700;
  font-size: 16px;
  color: var(--orange);
  letter-spacing: 0.06em;
  margin-bottom: 4px;
}

.about-tl-item.red .about-tl-year { color: var(--red); }

.about-tl-text {
  font-size: 12px;
  color: var(--text);
  line-height: 1.7;
  margin-bottom: 4px;
}

.about-tl-sub {
  font-size: 11px;
  color: var(--text-dim);
  font-style: italic;
  line-height: 1.5;
}
