@font-face {
  font-family: 'Plus Jakarta Sans';
  src: url('/assets/fonts/plus-jakarta-sans-400.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  src: url('/assets/fonts/plus-jakarta-sans-700.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
}
/* ================================================================
   Security+ SY0-701 — Feuille de styles commune
   ================================================================ */
:root {
  --bg: #ffffff;
  --text: #1a1a1a;
  --accent: #0C1B33;
  --accent2: #1A6FC4;
  --al: #e8f0fe;
  --al2: #f0f7ff;
  --grey: #f5f5f5;
  --grey2: #eeeeee;
  --bdr: #d0d0d0;
  --sb-width: 270px;
  --sb-bg: #152540;
  --sb-text: #cdd6f4;
  --sb-hover: rgba(255,255,255,.09);
  --sb-active-bg: rgba(255,255,255,.14);
  --sb-active: #35C4B5;
  --top-h: 50px;
  --ok: #2e7d32;
  --warn: #e65100;
  --err: #b71c1c;
  --ok-bg: #c8e6c9;
  --warn-bg: #fff3cd;
  --err-bg: #ffcdd2;
  --remember-bg: #fffde7;
  --remember-bdr: #f9a825;
  --exam-bg: #e8f0fe;
  --exam-bdr: #0C1B33;
}

* { box-sizing: border-box; margin: 0; padding: 0 }
html { scroll-behavior: smooth }
body {
  font-family: 'Plus Jakarta Sans', -apple-system, 'Segoe UI', Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.8;
  font-size: 16px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ---- Top bar ---- */
.topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--top-h);
  background: var(--accent);
  display: flex;
  align-items: center;
  padding: 0 1rem;
  gap: .75rem;
  z-index: 2000;
  box-shadow: 0 2px 8px rgba(0,0,0,.3);
}
.topbar-logo {
  color: #fff;
  font-family: 'Plus Jakarta Sans', Georgia, serif;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}
.topbar-logo span { font-size: .78rem; opacity: .75; font-weight: 400; margin-left: .35rem; }
.topbar-spacer { flex: 1 }
.topbar-links { display: flex; gap: .25rem }
.topbar-links a {
  color: rgba(255,255,255,.8);
  font-size: .78rem;
  padding: .3rem .6rem;
  border-radius: 3px;
  text-decoration: none;
  white-space: nowrap;
}
.topbar-links a:hover { background: rgba(255,255,255,.18); color: #fff }
.sb-toggle {
  background: none;
  border: none;
  color: #fff;
  font-size: 1.3rem;
  cursor: pointer;
  padding: .25rem .5rem;
  border-radius: 4px;
  flex-shrink: 0;
  line-height: 1;
}
.sb-toggle:hover { background: rgba(255,255,255,.15) }

/* ---- Sidebar ---- */
#sidebar {
  position: fixed;
  top: var(--top-h);
  left: 0;
  width: var(--sb-width);
  height: calc(100vh - var(--top-h));
  background: var(--sb-bg);
  overflow-y: auto;
  z-index: 1000;
  transition: transform .28s ease;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,.15) transparent;
}
#sidebar::-webkit-scrollbar { width: 4px }
#sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.15); border-radius: 2px }
#sidebar.hidden { transform: translateX(calc(-1 * var(--sb-width))) }

.sb-section { padding: .4rem 0 }
.sb-ch-header {
  display: flex;
  align-items: center;
  gap: .4rem;
  padding: .45rem 1rem;
  color: rgba(255,255,255,.5);
  font-size: .69rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  cursor: pointer;
  user-select: none;
  transition: color .2s;
}
.sb-ch-header:hover { color: rgba(255,255,255,.8) }
.sb-ch-header .arrow {
  margin-left: auto;
  font-size: .65rem;
  transition: transform .22s;
  color: rgba(255,255,255,.4);
}
.sb-ch-header.open .arrow { transform: rotate(90deg) }
.sb-ch-items { display: none; }
.sb-ch-header.open + .sb-ch-items { display: block }

.sb-item {
  display: block;
  padding: .35rem .9rem .35rem 1.6rem;
  color: var(--sb-text);
  font-size: .82rem;
  text-decoration: none;
  border-left: 2px solid transparent;
  transition: background .15s, border-color .15s;
  line-height: 1.4;
}
.sb-item:hover { background: var(--sb-hover); color: #fff }
.sb-item.active {
  background: var(--sb-active-bg);
  border-left-color: var(--sb-active);
  color: var(--sb-active);
  font-weight: 600;
}
.sb-divider {
  border: none;
  border-top: 1px solid rgba(255,255,255,.07);
  margin: .3rem 1rem;
}
.sb-label {
  padding: .8rem 1rem .3rem;
  font-size: .68rem;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: rgba(255,255,255,.35);
  font-weight: 700;
}

/* ---- Main content ---- */
#main {
  margin-left: var(--sb-width);
  margin-top: var(--top-h);
  padding: 2rem 2.5rem 4rem;
  max-width: 860px;
  transition: margin-left .28s ease;
  flex: 1;
}
#main.sb-hidden { margin-left: 0 }

/* ---- Overlay for mobile ---- */
#sb-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 999;
}

/* ---- Typography ---- */
h1, h2, h3, h4 {
  font-family: 'Plus Jakarta Sans', Georgia, serif;
  color: var(--accent);
  line-height: 1.3;
}
h1 { font-size: 2rem; margin-bottom: .75rem }
h2 {
  font-size: 1.45rem;
  margin: 2.5rem 0 .9rem;
  padding-bottom: .35rem;
  border-bottom: 2px solid var(--accent);
}
h3 { font-size: 1.12rem; margin: 1.75rem 0 .55rem }
h4 { font-size: .97rem; margin: 1.25rem 0 .4rem; color: #00234d }
p { margin-bottom: 1rem }
a { color: var(--accent2) }
a:hover { text-decoration: underline }
ul, ol { margin: 0 0 1rem 1.6rem }
li { margin-bottom: .3rem }
strong { font-weight: 700 }
code {
  font-family: 'Courier New', monospace;
  background: #1e1e2e;
  color: #cdd6f4;
  padding: .1rem .4rem;
  border-radius: 3px;
  font-size: .87rem;
}
pre {
  font-family: 'Courier New', monospace;
  background: #1e1e2e;
  color: #cdd6f4;
  padding: 1rem 1.25rem;
  border-radius: 6px;
  overflow-x: auto;
  font-size: .84rem;
  line-height: 1.65;
  margin: 1rem 0 1.5rem;
}
hr { border: none; border-top: 1px solid var(--bdr); margin: 2.5rem 0 }

/* ---- Breadcrumb ---- */
.breadcrumb {
  font-size: .8rem;
  color: #888;
  margin-bottom: 1.25rem;
  display: flex;
  gap: .35rem;
  align-items: center;
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--accent); text-decoration: none }
.breadcrumb a:hover { text-decoration: underline }
.breadcrumb .sep { color: #bbb }

/* ---- Chapter meta ---- */
.ch-meta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: .82rem;
  color: #666;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--bdr);
}
.ch-meta .domain-tag {
  background: var(--accent);
  color: #fff;
  padding: .2rem .65rem;
  border-radius: 3px;
  font-size: .75rem;
  font-weight: 600;
}

/* ---- Badges ---- */
.br, .bo {
  display: inline-flex;
  align-items: center;
  font-size: .71rem;
  padding: .15rem .55rem;
  border-radius: 12px;
  font-weight: 600;
  white-space: nowrap;
  vertical-align: middle;
  margin-left: .4rem;
}
.br { background: #fdecea; color: #b71c1c; border: 1px solid #e57373 }
.bo { background: #e3f2fd; color: #0d47a1; border: 1px solid #90caf9 }

/* ---- Tables ---- */
table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
  font-size: .91rem;
}
th {
  background: var(--accent);
  color: #fff;
  padding: .55rem .8rem;
  text-align: left;
  font-family: 'Plus Jakarta Sans', Georgia, serif;
  font-size: .87rem;
}
td { padding: .45rem .8rem; border-bottom: 1px solid var(--bdr) }
tr:nth-child(even) td { background: var(--grey) }
.table-wrap { overflow-x: auto; margin-bottom: 1.5rem }
.table-wrap table { margin-bottom: 0 }

/* ---- Special boxes ---- */
.remember-box {
  background: var(--remember-bg);
  border: 1px solid var(--remember-bdr);
  border-left: 4px solid var(--remember-bdr);
  border-radius: 0 6px 6px 0;
  padding: 1rem 1.2rem;
  margin: 1.5rem 0;
}
.remember-box .rb-title {
  color: #795548;
  font-weight: 700;
  font-family: 'Plus Jakarta Sans', Georgia, serif;
  font-size: .93rem;
  margin-bottom: .4rem;
  display: flex;
  align-items: center;
  gap: .4rem;
}

.exam-tip {
  background: var(--exam-bg);
  border-left: 4px solid var(--exam-bdr);
  border-radius: 0 6px 6px 0;
  padding: 1rem 1.2rem;
  margin: 1.75rem 0;
}
.exam-tip .et-title {
  color: var(--accent);
  font-weight: 700;
  font-family: 'Plus Jakarta Sans', Georgia, serif;
  font-size: .93rem;
  margin-bottom: .35rem;
  display: flex;
  align-items: center;
  gap: .4rem;
}

.scenario-box {
  background: #f3e5f5;
  border-left: 4px solid #7b1fa2;
  border-radius: 0 6px 6px 0;
  padding: 1rem 1.2rem;
  margin: 1.5rem 0;
}
.scenario-box .sc-title {
  color: #4a148c;
  font-weight: 700;
  font-family: 'Plus Jakarta Sans', Georgia, serif;
  font-size: .9rem;
  margin-bottom: .35rem;
}

.summary-box {
  background: #f8fafb;
  border: 1px solid var(--bdr);
  border-radius: 6px;
  padding: 1rem 1.25rem;
  margin: 2rem 0;
}
.summary-box h4 {
  margin-top: 0;
  font-size: .92rem;
  color: var(--accent);
  margin-bottom: .5rem;
  border-bottom: 1px solid var(--bdr);
  padding-bottom: .3rem;
}
.summary-box ul { margin-bottom: 0 }

.warning-box {
  background: #fff3e0;
  border-left: 4px solid #e65100;
  border-radius: 0 6px 6px 0;
  padding: .9rem 1.1rem;
  margin: 1.25rem 0;
}

/* ---- Progress bar ---- */
.prog-wrap { margin: 0 0 2rem }
.prog-bar {
  background: #e0e0e0;
  border-radius: 6px;
  height: 8px;
  overflow: hidden;
  margin: .35rem 0;
}
.prog-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 6px;
  transition: width .4s;
  width: 0%;
}
.prog-txt { font-size: .78rem; color: #777 }
.chk-lbl {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .83rem;
  color: #555;
  cursor: pointer;
  margin: .75rem 0 1.25rem;
}
.chk-lbl input { accent-color: var(--accent); width: .95rem; height: .95rem }

/* ---- Quiz ---- */
.quiz {
  background: #fafafa;
  border: 1px solid var(--bdr);
  border-radius: 8px;
  padding: 1.25rem;
  margin: 2.5rem 0;
}
.quiz > .quiz-title {
  margin-top: 0;
  font-size: 1.05rem;
  color: var(--accent);
  border-bottom: 1px solid var(--bdr);
  padding-bottom: .5rem;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: .5rem;
}
.qblock {
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid #eee;
}
.qblock:last-of-type { border-bottom: none; margin-bottom: 0; padding-bottom: 0 }
.qblock .q-text { font-weight: 600; margin-bottom: .55rem; font-size: .95rem }
.qblock label {
  display: flex;
  align-items: flex-start;
  gap: .5rem;
  cursor: pointer;
  margin-bottom: .3rem;
  font-weight: 400;
  font-size: .92rem;
  line-height: 1.5;
}
.qblock label input[type=radio] { margin-top: .22rem; flex-shrink: 0; accent-color: var(--accent) }
.quiz-btn {
  background: var(--accent);
  color: #fff;
  border: none;
  padding: .55rem 1.5rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: .93rem;
  margin-top: .75rem;
}
.quiz-btn:hover { background: #002244 }
.quiz-result {
  display: none;
  margin-top: .85rem;
  font-weight: 700;
  font-size: .95rem;
  padding: .65rem .9rem;
  border-radius: 4px;
}
.qblock.correct .q-text::before { content: '✓ '; color: #2e7d32 }
.qblock.incorrect .q-text::before { content: '✗ '; color: #c62828 }
.correct-label { background: #c8e6c9 !important; border-radius: 3px }
.expl {
  display: none;
  font-size: .84rem;
  color: #333;
  font-style: italic;
  background: #f0f4ff;
  border-left: 3px solid var(--accent2);
  padding: .5rem .7rem;
  border-radius: 0 4px 4px 0;
  margin-top: .5rem;
  line-height: 1.6;
}

/* ---- To top button ---- */
.to-top {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 1rem;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(0,0,0,.28);
  z-index: 998;
  opacity: 0;
  transition: opacity .3s;
  line-height: 40px;
  text-align: center;
}
.to-top.visible { opacity: 1 }

/* ---- See also ---- */
.see-also {
  font-size: .84rem;
  color: #555;
  padding: .65rem .9rem;
  background: var(--grey);
  border-radius: 4px;
  margin: 1.5rem 0;
}
.see-also a { color: var(--accent) }

/* ---- Two-col grid ---- */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1.25rem;
}
@media (max-width: 600px) { .two-col { grid-template-columns: 1fr } }

/* ---- Pill list ---- */
.pill-list { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 1rem }
.pill {
  background: var(--al);
  color: var(--accent);
  border: 1px solid #b3c8f0;
  padding: .2rem .65rem;
  border-radius: 20px;
  font-size: .82rem;
  font-weight: 600;
}

/* ---- Objective tag ---- */
.obj-tag {
  display: inline-block;
  background: #e8f5e9;
  color: #1b5e20;
  border: 1px solid #a5d6a7;
  font-size: .72rem;
  font-weight: 600;
  padding: .1rem .5rem;
  border-radius: 3px;
  margin-bottom: 1rem;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 800px) {
  :root { --sb-width: 260px }
  #main { margin-left: 0; padding: 1.25rem 1rem 3rem }
  #sidebar { transform: translateX(calc(-1 * var(--sb-width))); }
  #sidebar.open { transform: translateX(0) }
  #sb-overlay.visible { display: block }
  .topbar-links { display: none }
}

@media (min-width: 801px) {
  .sb-toggle { display: none }
}

/* ============================================================
   Print
   ============================================================ */
@media print {
  #sidebar, .topbar, .to-top, .quiz-btn, .chk-lbl,
  .prog-wrap, #sb-overlay { display: none !important }
  #main { margin-left: 0 !important; padding: .5rem }
  .quiz { border: 1px solid #ccc }
  a { color: #003366 }
}


/* ---- Marque ObjectifCyber (topbar) ---- */
.topbar-home {
  display: flex; align-items: center; gap: .45rem;
  color: #fff; text-decoration: none; font-weight: 700; font-size: .95rem;
  flex-shrink: 0;
}
.topbar-home svg { width: 26px; height: 26px; display: block; }
.topbar-home span { color: #35C4B5; }
.topbar-sep { color: rgba(255,255,255,.35); margin: 0 .15rem; }

/* ---- Pied de page ObjectifCyber ---- */
.sp-footer {
  margin-left: var(--sb-width);
  padding: 1.5rem 2rem;
  background: var(--sb-bg);
  color: rgba(255,255,255,.75);
  font-size: .82rem;
  display: flex; flex-wrap: wrap; gap: .5rem 1.5rem;
  align-items: center; justify-content: space-between;
}
.sp-footer a { color: #35C4B5; text-decoration: none; }
.sp-footer a:hover { text-decoration: underline; }
.sp-footer .sp-footer-links { display: flex; flex-wrap: wrap; gap: 1.25rem; }
@media (max-width: 800px) { .sp-footer { margin-left: 0; } }
