@import url('https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,400;0,500;0,600;0,700;0,800;1,400&family=Noto+Serif+Display:wght@700&display=swap');

:root {
  --serif-display: "Noto Serif Display", "Times New Roman", Times, serif;
  --sans: "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --bg: #090b10;
  --bg-2: #0c0f16;
  --surface: #12151d;
  --surface-2: #191d28;
  --border: #242a38;
  --hairline: rgba(255,255,255,.06);
  --text: #eef1f7;
  --text-dim: #949db0;
  --accent: #5a8dff;
  --accent-soft: rgba(90,141,255,.14);
  --gold: #d6b981;
  --gold-soft: rgba(214,185,129,.12);
  --green: #35d6a0;
  --red: #ff6470;
  --amber: #ffbe63;
  --violet: #b199fc;
  --radius: 14px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.3);
  --shadow-md: 0 10px 30px -12px rgba(0,0,0,.55);
  --shadow-lg: 0 24px 60px -20px rgba(0,0,0,.65);
  font-size: 16px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  background:
    radial-gradient(1200px 640px at 50% -8%, rgba(90,141,255,.08), transparent 55%),
    radial-gradient(900px 500px at 100% 0%, rgba(214,185,129,.05), transparent 50%),
    linear-gradient(180deg, var(--bg-2) 0%, var(--bg) 40%);
  background-color: var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font-family: var(--sans);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
::selection { background: rgba(90,141,255,.28); color: #fff; }
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-thumb { background: #232a38; border: 3px solid transparent; background-clip: padding-box; border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: #2f3747; background-clip: padding-box; }

/* ---------- Header + nav ---------- */
header {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 15px 28px;
  border-bottom: 1px solid var(--hairline);
  position: sticky; top: 0;
  background: linear-gradient(180deg, rgba(12,15,22,.92), rgba(10,12,18,.82));
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  z-index: 50;
  box-shadow: 0 1px 0 rgba(255,255,255,.03), 0 8px 24px -16px rgba(0,0,0,.8);
}
.logo {
  display: flex; align-items: center; gap: 11px; font-weight: 700;
  color: var(--text); text-decoration: none;
}
.logo-dot {
  width: 30px; height: 30px;
  background: url('logo.svg') center / contain no-repeat;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 8px rgba(90,141,255,.35));
}
.logo {
  font-family: var(--serif-display); font-weight: 700;
  text-transform: uppercase; letter-spacing: 1.4px; font-size: 1.12rem;
  background: linear-gradient(180deg, #fff 0%, var(--gold) 140%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}

/* ---------- Typographie : Open Sans partout (lisibilité) ---------- */
.page-title, .news-title, .hero-title, .tr-title, .rs-title,
.opp-title, .big-q, .mkt-name {
  font-family: var(--sans);
}
.page-title { font-weight: 800; }
.brief p { font-size: .97rem; line-height: 1.7; }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(79,140,255,.55); }
  70% { box-shadow: 0 0 0 10px rgba(79,140,255,0); }
  100% { box-shadow: 0 0 0 0 rgba(79,140,255,0); }
}
nav.mainnav { display: flex; gap: 2px; }
nav.mainnav a {
  position: relative;
  color: var(--text-dim); text-decoration: none; font-size: .87rem; font-weight: 500;
  padding: 7px 13px; border-radius: 9px; transition: color .18s, background .18s;
}
nav.mainnav a:hover { color: var(--text); background: rgba(255,255,255,.04); }
nav.mainnav a.active { color: var(--text); background: rgba(255,255,255,.05); font-weight: 600; }
nav.mainnav a.active::after {
  content: ""; position: absolute; left: 13px; right: 13px; bottom: 2px; height: 2px;
  border-radius: 2px; background: linear-gradient(90deg, var(--accent), var(--gold));
}
.search {
  flex: 1; min-width: 140px; max-width: 380px;
  background: rgba(255,255,255,.03); border: 1px solid var(--hairline);
  border-radius: 11px; padding: 10px 15px; color: var(--text);
  font-size: .9rem; outline: none; transition: border-color .18s, box-shadow .18s, background .18s;
}
.search:focus { border-color: rgba(90,141,255,.5); background: rgba(90,141,255,.05); box-shadow: 0 0 0 3px rgba(90,141,255,.12); }
.search::placeholder { color: var(--text-dim); }
.live-badge {
  display: flex; align-items: center; gap: 7px;
  background: rgba(255,100,112,.1); color: var(--red);
  border: 1px solid rgba(255,100,112,.22);
  font-weight: 700; font-size: .72rem; letter-spacing: 1px;
  padding: 6px 13px; border-radius: 999px;
}
.live-badge::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%;
  background: var(--red); animation: blink 1.2s infinite;
}
@keyframes blink { 50% { opacity: .25; } }
.clock { margin-left: auto; color: var(--text-dim); font-variant-numeric: tabular-nums; font-size: .9rem; }

/* ---------- Ticker ---------- */
.ticker-wrap {
  overflow: hidden; border-bottom: 1px solid var(--hairline);
  background: linear-gradient(180deg, rgba(255,255,255,.025), rgba(255,255,255,0));
  white-space: nowrap;
}
.ticker { display: inline-block; padding: 9px 0; animation: scroll 45s linear infinite; }
.ticker span { margin: 0 22px; font-size: .85rem; color: var(--text-dim); }
.ticker b { color: var(--text); font-weight: 600; }
.up { color: var(--green) !important; }
.down { color: var(--red) !important; }
@keyframes scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Filtres / chips ---------- */
.filters { display: flex; gap: 8px; padding: 16px 24px 0; flex-wrap: wrap; }
.chip {
  padding: 7px 16px; border-radius: 999px; font-size: .84rem;
  background: rgba(255,255,255,.03); border: 1px solid var(--hairline);
  color: var(--text-dim); cursor: pointer; transition: all .18s;
}
.chip:hover { border-color: rgba(90,141,255,.4); color: var(--text); background: rgba(90,141,255,.06); }
.chip.active {
  background: linear-gradient(135deg, var(--accent), #4678e6);
  border-color: transparent; color: #fff; font-weight: 600;
  box-shadow: 0 6px 16px -6px rgba(90,141,255,.6);
}

/* ---------- Layout ---------- */
.grid {
  display: grid; grid-template-columns: 1.6fr 1fr;
  gap: 18px; padding: 18px 24px 40px; align-items: start;
}
@media (max-width: 980px) { .grid { grid-template-columns: 1fr; } }
.page { padding: 18px 24px 40px; display: flex; flex-direction: column; gap: 18px; }
.page-title { font-size: 1.35rem; font-weight: 700; line-height: 1.35; }
.page-sub { color: var(--text-dim); font-size: .9rem; margin-top: 5px; }
.col { display: flex; flex-direction: column; gap: 18px; }
.cards-2 { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }

.card {
  position: relative;
  background:
    linear-gradient(180deg, rgba(255,255,255,.025), rgba(255,255,255,0) 45%),
    var(--surface);
  border: 1px solid var(--hairline);
  border-radius: var(--radius); padding: 18px;
}
.card::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.14), transparent);
  border-radius: var(--radius) var(--radius) 0 0;
}
.card h2 {
  font-size: .76rem; text-transform: uppercase; letter-spacing: 1.4px;
  color: var(--text-dim); margin-bottom: 14px; display: flex; align-items: center; gap: 8px;
}
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.section-head h2 { margin-bottom: 0; }
.section-head a { color: var(--accent); font-size: .8rem; text-decoration: none; }

/* ---------- Synthèse IA ---------- */
.brief { border-left: 3px solid transparent; border-image: linear-gradient(180deg, var(--accent), var(--gold)) 1; }
.brief p { color: var(--text); font-size: .95rem; line-height: 1.65; }
.brief .meta { margin-top: 12px; font-size: .78rem; color: var(--text-dim); }

/* ---------- News cards ---------- */
.news-item {
  display: flex; gap: 14px; padding: 14px 0;
  border-bottom: 1px solid var(--border); cursor: pointer;
}
.news-item:last-child { border-bottom: none; }
.news-item:hover .news-title { color: var(--accent); }
.impact {
  flex-shrink: 0; width: 42px; height: 42px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center; font-size: 1.2rem;
}
.impact.high { background: rgba(255,92,105,.14); }
.impact.med  { background: rgba(255,180,84,.14); }
.impact.low  { background: rgba(46,204,143,.12); }
.news-body { flex: 1; min-width: 0; }
.news-title { font-weight: 600; font-size: .97rem; line-height: 1.4; transition: color .15s; }
.news-summary { color: var(--text-dim); font-size: .85rem; line-height: 1.5; margin-top: 4px; }
.news-meta { display: flex; gap: 10px; align-items: center; margin-top: 8px; flex-wrap: wrap; }
.tag { font-size: .7rem; padding: 3px 9px; border-radius: 6px; font-weight: 600; letter-spacing: .3px; }
.tag.eco    { background: rgba(79,140,255,.15); color: var(--accent); }
.tag.geo    { background: rgba(167,139,250,.15); color: var(--violet); }
.tag.marche { background: rgba(46,204,143,.15); color: var(--green); }
.tag.energie{ background: rgba(255,180,84,.15); color: var(--amber); }
.tag.tech   { background: rgba(255,92,105,.15); color: var(--red); }
.tag.int    { background: rgba(79,140,255,.15);  color: var(--accent); }
.tag.pol    { background: rgba(167,139,250,.15); color: var(--violet); }
.tag.soc    { background: rgba(139,149,167,.18); color: var(--text-dim); }
.tag.sci    { background: rgba(79,216,255,.14);  color: #4fd8ff; }
.tag.climat { background: rgba(255,180,84,.15);  color: var(--amber); }
.tag.culture{ background: rgba(255,92,105,.15);  color: var(--red); }
.tag.sport  { background: rgba(46,204,143,.15);  color: var(--green); }
.src { font-size: .74rem; color: var(--text-dim); }
.src b { color: var(--text); font-weight: 600; }
.time { font-size: .74rem; color: var(--text-dim); margin-left: auto; font-variant-numeric: tabular-nums; }

/* ---------- Marchés ---------- */
.market-row {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 0; border-bottom: 1px solid var(--border); font-size: .88rem;
}
.market-row:last-child { border-bottom: none; }
.market-name { width: 92px; font-weight: 600; }
.spark { flex: 1; height: 26px; }
.market-val { font-variant-numeric: tabular-nums; width: 82px; text-align: right; }
.market-chg { font-variant-numeric: tabular-nums; width: 64px; text-align: right; font-weight: 600; font-size: .8rem; }

/* ---------- Régions ---------- */
.region { display: flex; align-items: center; gap: 12px; padding: 8px 0; font-size: .86rem; }
.region .name { width: 130px; display: flex; gap: 8px; align-items: center; }
.bar { flex: 1; height: 8px; border-radius: 4px; background: var(--surface-2); overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 4px; }
.region .count { width: 34px; text-align: right; color: var(--text-dim); font-size: .78rem; }

/* ---------- Connecteurs ---------- */
.connector {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 0; font-size: .86rem; border-bottom: 1px solid var(--border);
}
.connector:last-child { border-bottom: none; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); flex-shrink: 0; }
.dot.sync { background: var(--amber); animation: blink 1s infinite; }
.dot.off { background: var(--text-dim); }
.connector .n { flex: 1; font-weight: 500; }
.connector .stat { color: var(--text-dim); font-size: .76rem; font-variant-numeric: tabular-nums; }
.add-src {
  margin-top: 12px; width: 100%; padding: 9px; border-radius: 10px;
  border: 1px dashed var(--border); background: none; color: var(--text-dim);
  cursor: pointer; font-size: .84rem; transition: all .15s;
}
.add-src:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- Flux live ---------- */
.feed-item {
  display: flex; gap: 12px; padding: 10px 0;
  border-bottom: 1px solid var(--border);
  font-size: .86rem; animation: slideIn .4s ease;
}
.feed-item:last-child { border-bottom: none; }
@keyframes slideIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
.feed-time { color: var(--text-dim); font-variant-numeric: tabular-nums; font-size: .76rem; width: 46px; flex-shrink: 0; padding-top: 2px; }
.feed-txt b { font-weight: 600; }
.feed-src { color: var(--text-dim); font-size: .75rem; margin-top: 2px; }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; }
.stat .v { font-size: 1.35rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat .l { color: var(--text-dim); font-size: .78rem; margin-top: 4px; }

/* ---------- Timeline ---------- */
.tl { position: relative; padding-left: 20px; }
.tl::before { content: ""; position: absolute; left: 5px; top: 6px; bottom: 6px; width: 2px; background: var(--border); }
.tl-item { position: relative; padding: 8px 0 8px 12px; }
.tl-item::before {
  content: ""; position: absolute; left: -19px; top: 14px; width: 8px; height: 8px;
  border-radius: 50%; background: var(--surface-2); border: 2px solid var(--accent);
}
.tl-time { font-size: .75rem; color: var(--text-dim); font-variant-numeric: tabular-nums; }
.tl-txt { font-size: .9rem; margin-top: 2px; line-height: 1.5; }

/* ---------- Tables ---------- */
table.tbl { width: 100%; border-collapse: collapse; font-size: .86rem; }
.tbl th {
  text-align: left; color: var(--text-dim); font-size: .72rem; text-transform: uppercase;
  letter-spacing: .8px; padding: 8px 10px; border-bottom: 1px solid var(--border); font-weight: 600;
}
.tbl td { padding: 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.tbl tr:last-child td { border-bottom: none; }

/* ---------- Tonalité ---------- */
.tone { font-size: .72rem; padding: 3px 9px; border-radius: 6px; font-weight: 600; white-space: nowrap; }
.tone.pos { background: rgba(46,204,143,.15); color: var(--green); }
.tone.neg { background: rgba(255,92,105,.15); color: var(--red); }
.tone.neu { background: rgba(139,149,167,.18); color: var(--text-dim); }

/* ---------- Switch ---------- */
.switch { position: relative; width: 38px; height: 22px; flex-shrink: 0; cursor: pointer; display: inline-block; }
.switch input { display: none; }
.switch i {
  position: absolute; inset: 0; border-radius: 999px;
  background: var(--surface-2); border: 1px solid var(--border); transition: .2s; display: block;
}
.switch i::after {
  content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px;
  border-radius: 50%; background: var(--text-dim); transition: .2s;
}
.switch input:checked + i { background: var(--accent); border-color: var(--accent); }
.switch input:checked + i::after { left: 18px; background: #fff; }

/* ---------- Boutons / divers ---------- */
.btn {
  padding: 10px 18px; border-radius: 11px; border: 1px solid var(--hairline);
  background: rgba(255,255,255,.04); color: var(--text); cursor: pointer; font-size: .86rem;
  font-weight: 600; transition: all .18s;
}
.btn.primary {
  background: linear-gradient(135deg, var(--accent), #4678e6); border-color: transparent; color: #fff;
  box-shadow: 0 8px 20px -8px rgba(90,141,255,.6);
}
.btn:hover { transform: translateY(-1px); filter: brightness(1.08); }
.crumb { font-size: .84rem; color: var(--text-dim); }
.crumb a { color: var(--accent); text-decoration: none; }

/* ---------- Événements ---------- */
.event { display: flex; gap: 12px; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--border); font-size: .87rem; }
.event:last-child { border-bottom: none; }
.event .when { width: 96px; font-variant-numeric: tabular-nums; color: var(--text-dim); font-size: .78rem; flex-shrink: 0; }
.event .imp { margin-left: auto; }

/* ---------- Bouton "En savoir +" ---------- */
.know-more {
  display: inline-flex; align-items: center; gap: 5px;
  font-family: var(--sans); font-size: .72rem; font-weight: 600;
  color: var(--accent); background: rgba(79,140,255,.1);
  border: 1px solid rgba(79,140,255,.25); border-radius: 999px;
  padding: 3px 10px; cursor: pointer; white-space: nowrap;
  transition: all .15s;
}
.know-more::before { content: "✨"; font-size: .8em; }
.know-more:hover { background: rgba(79,140,255,.2); border-color: var(--accent); }

/* ---------- Modal synthèse ---------- */
.dt-modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(8,10,14,.72); backdrop-filter: blur(5px);
  display: flex; align-items: center; justify-content: center; padding: 20px;
  animation: dtFade .15s ease;
}
.dt-modal-overlay[hidden] { display: none; }
@keyframes dtFade { from { opacity: 0; } to { opacity: 1; } }
.dt-modal {
  position: relative;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 16px; padding: 26px 28px; width: 100%; max-width: 540px;
  max-height: 85vh; overflow-y: auto;
  box-shadow: 0 24px 70px rgba(0,0,0,.55);
  animation: dtRise .2s ease;
}
@keyframes dtRise { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }
.dt-modal-close {
  position: absolute; top: 16px; right: 16px;
  width: 30px; height: 30px; border-radius: 8px;
  background: var(--surface-2); border: 1px solid var(--border);
  color: var(--text-dim); cursor: pointer; font-size: .85rem;
}
.dt-modal-close:hover { color: var(--text); border-color: var(--accent); }
.dt-modal-eyebrow {
  font-size: .72rem; font-weight: 700; letter-spacing: .8px; text-transform: uppercase;
  color: var(--accent); margin-bottom: 8px;
}
.dt-modal-title {
  font-family: var(--sans); font-size: 1.2rem; font-weight: 800; line-height: 1.35;
  margin-bottom: 14px; padding-right: 30px;
}
.dt-modal-body { font-size: .94rem; line-height: 1.65; color: var(--text); }
/* La zone de résumé défile seule si elle est longue */
.dt-modal-body .synth-scroll {
  max-height: 38vh; overflow-y: auto;
  margin: 6px -8px 0; padding: 2px 8px;
}
.dt-modal-body .synth-scroll::-webkit-scrollbar { width: 6px; }
.dt-modal-body .synth-scroll::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
.dt-modal-body p { margin-bottom: 10px; }
.dt-modal-body ul { margin: 6px 0 12px; padding-left: 20px; }
.dt-modal-body li { margin-bottom: 5px; line-height: 1.55; }
.dt-modal-body .synth-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 14px; }
.dt-modal-body .synth-kv {
  background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px;
  padding: 6px 11px; font-size: .82rem;
}
.dt-modal-body .synth-kv b { font-variant-numeric: tabular-nums; }
.dt-modal-foot {
  margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border);
  display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
  font-size: .78rem; color: var(--text-dim);
}
.dt-modal-foot a { color: var(--accent); text-decoration: none; font-weight: 600; }
.dt-modal-foot .ai-note { font-style: italic; }

/* ---------- Onglet "Suivi" mis en évidence ---------- */
nav.mainnav a.nav-suivi {
  color: var(--accent);
  background: rgba(79,140,255,.1);
  border: 1px solid rgba(79,140,255,.32);
  font-weight: 700;
  display: inline-flex; align-items: center; gap: 5px;
}
nav.mainnav a.nav-suivi::before { content: "★"; font-size: .95em; }
nav.mainnav a.nav-suivi:hover { background: rgba(79,140,255,.2); color: var(--accent); }
nav.mainnav a.nav-suivi.active {
  background: var(--accent); color: #fff; border-color: var(--accent);
}
nav.mainnav a.nav-suivi.active::before { color: #fff; }
.nav-suivi-count {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 999px; font-size: .68rem; font-weight: 800;
  background: var(--accent); color: #fff; font-variant-numeric: tabular-nums;
}
nav.mainnav a.nav-suivi.active .nav-suivi-count { background: rgba(255,255,255,.25); }

/* ---------- Sélecteur de langue FR / EN ---------- */
.lang-toggle {
  display: inline-flex; gap: 2px; padding: 2px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 8px;
}
.lang-toggle button {
  border: none; background: none; color: var(--text-dim);
  font-family: var(--sans); font-size: .74rem; font-weight: 700;
  padding: 4px 9px; border-radius: 6px; cursor: pointer; transition: all .15s;
}
.lang-toggle button:hover { color: var(--text); }
.lang-toggle button.active { background: var(--accent); color: #fff; }

/* ---------- Menu déroulant de filtre par média ---------- */
.feed-src-select {
  background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px;
  color: var(--text); font-family: var(--sans); font-size: .8rem;
  padding: 5px 9px; outline: none; cursor: pointer; max-width: 190px;
}
.feed-src-select:hover, .feed-src-select:focus { border-color: var(--accent); }

/* ---------- Carte Briefing de début de journée ---------- */
.briefing-card {
  background:
    radial-gradient(600px 240px at 0% 0%, rgba(90,141,255,.14), transparent 60%),
    radial-gradient(500px 220px at 100% 120%, rgba(214,185,129,.1), transparent 60%),
    var(--surface);
  border: 1px solid rgba(90,141,255,.22);
  box-shadow: var(--shadow-lg);
}
.briefing-card::before {
  background: linear-gradient(90deg, transparent, var(--accent), var(--gold), transparent);
  opacity: .85;
}
.briefing-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.briefing-head h2 {
  font-size: 1.1rem; font-weight: 800; text-transform: none; letter-spacing: 0;
  color: var(--text); margin-bottom: 0;
}
.briefing-date { color: var(--text-dim); font-size: .84rem; text-transform: capitalize; }
.briefing-intro { color: var(--text); font-size: .95rem; line-height: 1.6; margin-bottom: 12px; }
.briefing-points { margin: 0 0 4px; }
.briefing-pt {
  display: flex; gap: 10px; align-items: flex-start; padding: 6px 0;
  font-size: .92rem; line-height: 1.5; cursor: pointer;
}
.briefing-pt:hover .bp-txt { color: var(--accent); }
.briefing-pt .bp-dot { color: var(--accent); font-weight: 800; flex-shrink: 0; }
.briefing-pt .bp-src { color: var(--text-dim); font-size: .82rem; }
.briefing-line { font-size: .9rem; line-height: 1.6; margin-top: 8px; color: var(--text); }
.briefing-line b { font-weight: 700; }

/* ---------- Analyse technique ---------- */
.ta-verdict {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 14px 16px; border-radius: 12px; margin-bottom: 16px; border: 1px solid var(--border);
}
.ta-verdict.pos { background: rgba(46,204,143,.10); border-color: rgba(46,204,143,.35); }
.ta-verdict.neg { background: rgba(255,92,105,.10); border-color: rgba(255,92,105,.35); }
.ta-verdict.neu { background: rgba(255,180,84,.10); border-color: rgba(255,180,84,.35); }
.ta-verdict-label { font-size: .72rem; text-transform: uppercase; letter-spacing: 1px; color: var(--text-dim); font-weight: 700; }
.ta-verdict-main { font-size: 1.05rem; font-weight: 800; margin-top: 3px; }
.ta-score { font-size: 1.7rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.ta-score span { font-size: .9rem; color: var(--text-dim); font-weight: 600; }
.ta-verdict.pos .ta-score { color: var(--green); }
.ta-verdict.neg .ta-score { color: var(--red); }
.ta-verdict.neu .ta-score { color: var(--amber); }
.ta-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.ta-panel { background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px; padding: 13px 15px; }
.ta-panel-t { font-size: .8rem; font-weight: 700; margin-bottom: 8px; }
.ta-line { display: flex; justify-content: space-between; gap: 10px; padding: 5px 0; font-size: .85rem; border-bottom: 1px solid var(--border); }
.ta-line:last-child { border-bottom: none; }
.ta-line span { color: var(--text-dim); }
.ta-line b { font-variant-numeric: tabular-nums; text-align: right; }
.ta-rsi { margin: 6px 0; }
.ta-rsi-bar { position: relative; height: 8px; border-radius: 4px;
  background: linear-gradient(90deg, rgba(46,204,143,.5) 0%, rgba(46,204,143,.5) 30%, var(--surface) 30%, var(--surface) 70%, rgba(255,92,105,.5) 70%); }
.ta-rsi-bar i { position: absolute; top: -3px; width: 3px; height: 14px; background: var(--text); border-radius: 2px; transform: translateX(-50%); }
.ta-rsi-scale { display: flex; justify-content: space-between; font-size: .66rem; color: var(--text-dim); margin-top: 3px; }
.ta-signals { margin-top: 16px; }
.ta-badge { font-size: .7rem; font-weight: 700; padding: 3px 9px; border-radius: 6px; }
.ta-badge.pos { background: rgba(46,204,143,.15); color: var(--green); }
.ta-badge.neg { background: rgba(255,92,105,.15); color: var(--red); }
.ta-badge.neu { background: rgba(139,149,167,.18); color: var(--text-dim); }
.ta-disclaimer {
  margin-top: 14px; padding: 11px 14px; border-radius: 10px; font-size: .8rem; line-height: 1.55;
  background: rgba(255,180,84,.07); border: 1px solid rgba(255,180,84,.28); color: var(--text-dim);
}
.ta-disclaimer b { color: var(--text); }

/* ---------- Sélecteurs d'indicateurs (graphique) ---------- */
.ind-toggles { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 10px; }
.ind-chip {
  font-family: var(--sans); font-size: .74rem; font-weight: 600;
  padding: 4px 11px; border-radius: 999px; cursor: pointer;
  background: var(--surface-2); border: 1px solid var(--border); color: var(--text-dim);
  transition: all .15s; display: inline-flex; align-items: center; gap: 5px;
}
.ind-chip::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; opacity: .35; }
.ind-chip.on { color: var(--text); border-color: var(--accent); background: rgba(79,140,255,.08); }
.ind-chip.on::before { opacity: 1; }
.ind-chip[data-ind="ma20"].on { --dot: #ffb454; }
.ind-chip.on::before { background: var(--dot, var(--accent)); opacity: 1; }
.ind-chip[data-ind="ma20"] { --dot: #ffb454; }
.ind-chip[data-ind="ma50"] { --dot: #4f8cff; }
.ind-chip[data-ind="ma200"] { --dot: #a78bfa; }
.ind-chip[data-ind="bollinger"] { --dot: #8b95a7; }
.ind-chip[data-ind="rsi"] { --dot: #4fd8ff; }
.ind-chip[data-ind="macd"] { --dot: #4f8cff; }

/* Pastilles des indicateurs additionnels + labels de groupe */
.ind-chip[data-ind="ema20"] { --dot: #2ecc8f; }
.ind-chip[data-ind="ema50"] { --dot: #ff5c69; }
.ind-chip[data-ind="ichimoku"] { --dot: #a78bfa; }
.ind-chip[data-ind="psar"] { --dot: #8b95a7; }
.ind-chip[data-ind="sr"] { --dot: #ffb454; }
.ind-chip[data-ind="stoch"] { --dot: #4fd8ff; }
.ind-chip[data-ind="williams"] { --dot: #a78bfa; }
.ind-chip[data-ind="cci"] { --dot: #2ecc8f; }
.ind-chip[data-ind="adx"] { --dot: #e8ecf3; }
.ind-chip[data-ind="atr"] { --dot: #ffb454; }
.ind-chip[data-ind="roc"] { --dot: #4f8cff; }
.ind-group-label {
  font-size: .68rem; text-transform: uppercase; letter-spacing: .8px; font-weight: 700;
  color: var(--text-dim); align-self: center; margin: 0 2px 0 4px;
}
.ind-group-label:not(:first-child) { margin-left: 10px; }

/* ---------- Lecture des indicateurs sélectionnés ---------- */
.ind-analysis { margin-top: 14px; border-top: 1px solid var(--border); padding-top: 14px; }
.ind-analysis-title { font-size: .8rem; font-weight: 700; margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.ind-read {
  display: flex; align-items: flex-start; gap: 12px; padding: 9px 0;
  border-bottom: 1px solid var(--border); font-size: .86rem;
}
.ind-read:last-child { border-bottom: none; }
.ind-read .irn { font-weight: 700; width: 130px; flex-shrink: 0; }
.ind-read .irn small { display: block; font-weight: 600; color: var(--text-dim); font-variant-numeric: tabular-nums; }
.ind-read .irt { flex: 1; color: var(--text-dim); line-height: 1.45; }
.ind-read .irb { flex-shrink: 0; font-size: .68rem; font-weight: 700; padding: 3px 9px; border-radius: 6px; }
.ind-read .irb.pos { background: rgba(46,204,143,.15); color: var(--green); }
.ind-read .irb.neg { background: rgba(255,92,105,.15); color: var(--red); }
.ind-read .irb.neu { background: rgba(139,149,167,.18); color: var(--text-dim); }
.ind-synth {
  margin-top: 12px; padding: 11px 14px; border-radius: 10px; font-size: .88rem; line-height: 1.5; font-weight: 600;
}
.ind-synth.pos { background: rgba(46,204,143,.1); border: 1px solid rgba(46,204,143,.3); }
.ind-synth.neg { background: rgba(255,92,105,.1); border: 1px solid rgba(255,92,105,.3); }
.ind-synth.neu { background: rgba(255,180,84,.1); border: 1px solid rgba(255,180,84,.3); }
.ind-empty { color: var(--text-dim); font-size: .85rem; padding: 4px 0; }

/* ============================================================
   Mode application + lisibilité
   ============================================================ */
body { line-height: 1.5; -webkit-text-size-adjust: 100%; }

/* ---------- Barre d'onglets (mobile) ---------- */
.app-tabbar { display: none; }
.app-more[hidden] { display: none; }

@media (max-width: 760px) {
  :root { font-size: 16.5px; }
  nav.mainnav { display: none; }           /* remplacée par la barre du bas */
  header { gap: 10px; padding: 10px 14px; }
  .clock { display: none; }
  .search { min-width: 0; max-width: none; }
  .ticker span { margin: 0 16px; }
  .page { padding: 14px 15px 40px; }
  .grid { padding: 14px 15px 40px; gap: 14px; }
  .card { padding: 16px; }
  .page-title { font-size: 1.5rem; }
  .filters { padding: 14px 15px 0; }
  body { padding-bottom: 64px; }            /* place pour la barre */

  .app-tabbar {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
    background: rgba(18,22,30,.96); backdrop-filter: blur(14px);
    border-top: 1px solid var(--border);
    padding-bottom: env(safe-area-inset-bottom, 0);
  }
  .app-tabbar a, .app-tabbar button {
    flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px;
    padding: 9px 0 8px; background: none; border: none; cursor: pointer;
    color: var(--text-dim); font-family: var(--sans); font-size: .64rem; font-weight: 700;
    text-decoration: none; letter-spacing: .2px;
  }
  .app-tabbar .ic { font-size: 1.2rem; line-height: 1; }
  .app-tabbar a.on { color: var(--accent); }
}

/* ---------- Feuille "Plus" ---------- */
.app-more { position: fixed; inset: 0; z-index: 100; }
.app-more-bg { position: absolute; inset: 0; background: rgba(8,10,14,.6); backdrop-filter: blur(3px); }
.app-more-sheet {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: var(--surface); border: 1px solid var(--border);
  border-top-left-radius: 20px; border-top-right-radius: 20px;
  padding: 10px 18px calc(22px + env(safe-area-inset-bottom, 0));
  animation: sheetUp .22s ease;
}
@keyframes sheetUp { from { transform: translateY(100%); } to { transform: none; } }
.app-more-grip { width: 42px; height: 4px; border-radius: 2px; background: var(--border); margin: 4px auto 14px; }
.app-more-title { font-weight: 800; font-size: 1rem; margin-bottom: 14px; }
.app-more-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.app-more-grid a {
  display: flex; flex-direction: column; align-items: center; gap: 6px; text-decoration: none;
  color: var(--text); font-size: .72rem; font-weight: 700; text-align: center; line-height: 1.2;
  padding: 14px 4px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--border);
}
.app-more-grid a .ic { font-size: 1.5rem; }
.app-more-grid a.on { border-color: var(--accent); color: var(--accent); background: rgba(79,140,255,.08); }

/* ---------- Plans d'investissement par horizon ---------- */
.plan-intro { color: var(--text-dim); font-size: .9rem; line-height: 1.6; margin: 4px 0 14px; max-width: 900px; }
.plan-intro b { color: var(--text); }
.plans-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; }
.plan-card { display: flex; flex-direction: column; gap: 12px; }
.plan-head { display: flex; align-items: flex-start; gap: 12px; }
.plan-ic { width: 42px; height: 42px; border-radius: 11px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 1.3rem; background: var(--surface-2); }
.plan-h { flex: 1; }
.plan-h .t { font-weight: 800; font-size: 1.05rem; }
.plan-h .s { color: var(--text-dim); font-size: .78rem; margin-top: 1px; }
.plan-risk { font-size: .68rem; font-weight: 700; padding: 3px 9px; border-radius: 6px; white-space: nowrap; }
.plan-risk.r1 { background: rgba(46,204,143,.15); color: var(--green); }
.plan-risk.r2 { background: rgba(255,180,84,.15); color: var(--amber); }
.plan-risk.r3 { background: rgba(255,92,105,.15); color: var(--red); }
.plan-obj { font-size: .88rem; line-height: 1.5; color: var(--text); }
.plan-alloc-bar { display: flex; height: 14px; border-radius: 7px; overflow: hidden; }
.plan-alloc-bar i { height: 100%; }
.plan-legend { display: flex; flex-direction: column; gap: 5px; }
.plan-leg { display: flex; align-items: center; gap: 8px; font-size: .82rem; }
.plan-leg .dot { width: 10px; height: 10px; border-radius: 3px; flex-shrink: 0; }
.plan-leg .pct { margin-left: auto; font-weight: 700; font-variant-numeric: tabular-nums; }
.plan-sec-t { font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--text-dim); margin: 4px 0 2px; }
.plan-strat { margin: 0; padding-left: 18px; }
.plan-strat li { font-size: .84rem; line-height: 1.5; color: var(--text-dim); margin-bottom: 4px; }
.plan-strat li b { color: var(--text); }
.plan-ex { display: flex; flex-wrap: wrap; gap: 6px; }
.plan-ex a, .plan-ex span { font-size: .74rem; padding: 4px 9px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-dim); text-decoration: none; }
.plan-ex a:hover { border-color: var(--accent); color: var(--accent); }
.plan-rule { display: flex; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--border); font-size: .87rem; line-height: 1.5; }
.plan-rule:last-child { border-bottom: none; }
.plan-rule .ri { font-size: 1.1rem; flex-shrink: 0; }
.plan-rule b { color: var(--text); }

/* Liste de sous-jacents dans les plans */
.plan-picks { margin-top: 2px; }
.plan-pick { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--border); font-size: .84rem; text-decoration: none; color: var(--text); }
.plan-pick:last-child { border-bottom: none; }
.plan-pick:hover .pp-n { color: var(--accent); }
.plan-pick .pp-n { flex: 1; font-weight: 600; min-width: 0; }
.plan-pick .pp-p { font-variant-numeric: tabular-nums; color: var(--text-dim); font-size: .8rem; }
.plan-pick .pp-c { font-variant-numeric: tabular-nums; font-weight: 700; width: 62px; text-align: right; }
.plan-rationale { margin-top: 9px; font-size: .78rem; line-height: 1.5; color: var(--text-dim); }

/* ============================================================
   Raffinement UX / lisibilité — moins d'encombrement visuel
   ============================================================ */

/* Largeur de lecture confortable : le contenu ne s'étale plus
   d'un bord à l'autre sur grand écran → moins "noyé". */
.grid, .page, .filters, .disclaimer, .breaking { max-width: 1340px; margin-inline: auto; }

/* Plus d'air entre les blocs pour aider l'œil à regrouper */
.grid { gap: 22px; padding-top: 22px; }
.col { gap: 20px; }
.page { gap: 20px; }
.filters { gap: 9px; }

/* Cartes : respiration + légère élévation pour bien séparer les zones */
.card { padding: 22px 24px; border-radius: 18px; box-shadow: var(--shadow-md); }
.card h2 { margin-bottom: 16px; }

/* Hiérarchie typographique plus nette */
body { line-height: 1.55; }
.page-title { font-size: 1.6rem; letter-spacing: -.2px; }
.page-sub { font-size: .92rem; margin-top: 7px; max-width: 780px; }

/* Bandeau défilant plus discret (c'est du contexte, pas le message principal) */
.ticker span { font-size: .8rem; }
.ticker-wrap { opacity: .9; }

/* Liens de section discrets jusqu'au survol */
.section-head a { opacity: .82; transition: opacity .15s; }
.section-head a:hover { opacity: 1; }

/* Retour visuel homogène sur les cartes cliquables */
.mkt-card, .sel-card, .plan-card { transition: box-shadow .15s, border-color .15s, transform .15s; }
.mkt-card:hover, .sel-card:hover { box-shadow: 0 6px 18px rgba(0,0,0,.28); transform: translateY(-1px); }

/* Confort de lecture & accessibilité */
html { scroll-behavior: smooth; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px;
}

/* Un peu plus d'espace sous les rangées de filtres et de stats */
.stats { gap: 14px; }

/* ---------- Analyse Pro ---------- */
.pro-valbar { display: flex; align-items: center; gap: 8px; margin: 4px 0 12px; font-size: .68rem; color: var(--text-dim); }
.pro-valbar .track { position: relative; flex: 1; height: 8px; border-radius: 4px;
  background: linear-gradient(90deg, rgba(255,92,105,.6), rgba(255,180,84,.5) 50%, rgba(46,204,143,.6)); }
.pro-valbar .track i { position: absolute; top: -3px; width: 3px; height: 14px; background: var(--text); border-radius: 2px; transform: translateX(-50%); box-shadow: 0 0 0 2px var(--surface-2); }
.pro-grade { width: 46px; height: 46px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; font-weight: 800; flex-shrink: 0; }
.pro-grade.pos { background: rgba(46,204,143,.15); color: var(--green); }
.pro-grade.neu { background: rgba(255,180,84,.15); color: var(--amber); }
.pro-grade.neg { background: rgba(255,92,105,.15); color: var(--red); }
.pro-hbar { display: flex; align-items: center; gap: 8px; padding: 4px 0; font-size: .8rem; }
.pro-hbar .l { width: 120px; color: var(--text-dim); flex-shrink: 0; }
.pro-hbar .bar { flex: 1; height: 6px; border-radius: 3px; background: var(--surface); overflow: hidden; }
.pro-hbar .bar i { display: block; height: 100%; border-radius: 3px; }
.pro-hbar .v { width: 26px; text-align: right; font-variant-numeric: tabular-nums; font-weight: 700; font-size: .78rem; }
.pro-tip { font-size: .84rem; line-height: 1.5; padding: 4px 0; }
.pro-tip.pos { color: var(--text); } .pro-tip.pos::first-letter { color: var(--green); }
.pro-tip.neg { color: var(--text); }
.pro-tip.pos { color: var(--green); } .pro-tip.neg { color: var(--red); }
.pro-pat { display: flex; gap: 10px; align-items: flex-start; padding: 7px 0; border-bottom: 1px solid var(--border); font-size: .84rem; }
.pro-pat:last-child { border-bottom: none; }
.pro-pat .d { width: 9px; height: 9px; border-radius: 50%; margin-top: 5px; flex-shrink: 0; }
.pro-pat .d.pos { background: var(--green); } .pro-pat .d.neu { background: var(--text-dim); } .pro-pat .d.neg { background: var(--red); }
.pro-pat .ds { color: var(--text-dim); font-size: .8rem; line-height: 1.45; margin-top: 2px; }

/* ============================================================
   FINITION « HAUT DE GAMME » — couche luxe (ajoutée en dernier)
   ============================================================ */

/* Vignette cinématographique : encadre le contenu, assombrit les marges.
   z-index: -1 → visible dans les gouttières, jamais par-dessus le texte. */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(140% 100% at 50% -10%, transparent 55%, rgba(0,0,0,.45) 100%),
    radial-gradient(100% 60% at 50% 110%, rgba(0,0,0,.35), transparent 60%);
}
/* Grain matte très subtil : texture « imprimé » premium, posée au-dessus du fond
   mais sous le contenu (contenu opaque des cartes le masque). */
body::after {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  opacity: .5; mix-blend-mode: soft-light;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
  background-size: 140px 140px;
}

/* --- Titres de page : plus de présence, filet or signature --- */
.page-title {
  font-size: 1.75rem; font-weight: 800; letter-spacing: -.4px; line-height: 1.25;
  padding-bottom: 12px; position: relative;
}
.page-title::after {
  content: ""; position: absolute; left: 0; bottom: 0; width: 54px; height: 3px;
  border-radius: 3px; background: linear-gradient(90deg, var(--gold), var(--accent));
}

/* --- Eyebrows de carte : liseré or discret pour signer les sections --- */
.card > h2:first-child { position: relative; padding-left: 14px; }
.card > h2:first-child::before {
  content: ""; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 3px; height: 13px; border-radius: 2px;
  background: linear-gradient(180deg, var(--gold), var(--accent));
}
/* Le héros « Briefing » garde son titre libre (pas d'eyebrow), on retire le liseré */
.briefing-card .briefing-head h2 { padding-left: 0; }
.briefing-card .briefing-head h2::before { display: none; }

/* --- Héros : titre plus grand et plus net --- */
.briefing-head h2 { font-size: 1.28rem; letter-spacing: -.3px; }
.briefing-intro { font-size: 1rem; }

/* --- Liens de section : glissent vers l'or au survol --- */
.section-head a {
  display: inline-flex; align-items: center; gap: 4px; font-weight: 600;
  transition: color .18s, gap .18s, opacity .18s;
}
.section-head a:hover { color: var(--gold); gap: 8px; }

/* --- Cartes d'actualité : séparateurs plus fins, survol plus riche --- */
.news-item { border-bottom: 1px solid var(--hairline); padding: 16px 0; transition: transform .18s; }
.news-item:hover { transform: translateX(2px); }
.news-title { font-size: 1rem; letter-spacing: -.1px; }
.impact { border: 1px solid var(--hairline); }

/* --- Rangées de marché & listes : filets en hairline homogènes --- */
.market-row, .region, .connector, .feed-item, .event,
.tbl td, .tbl th, .plan-rule, .plan-pick, .pro-pat, .ta-line, .ind-read {
  border-color: var(--hairline);
}

/* --- Pastille « En savoir + » : finition dorée au survol --- */
.know-more:hover {
  background: var(--gold-soft); border-color: rgba(214,185,129,.5); color: var(--gold);
}

/* --- Micro-interaction homogène sur toutes les cartes --- */
.card { transition: border-color .2s, box-shadow .2s, transform .2s; }
.grid .card:hover, .cards-2 .card:hover, .plans-grid .card:hover {
  border-color: rgba(255,255,255,.1);
  box-shadow: var(--shadow-lg);
}
.briefing-card:hover { transform: none; }

/* --- Barre d'onglets mobile : accent or sur l'actif --- */
@media (max-width: 760px) {
  .app-tabbar a.on { color: var(--gold); }
  .page-title { font-size: 1.65rem; }
}
