/* ==========================================================================
   ZAI INFORMATIQUE — shared modern stylesheet
   Modern, responsive, accessible. Pure static (no build step).
   ========================================================================== */

/* ---- Reset / base ------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

:root {
  --brand: #f97316;
  --brand-dark: #ea580c;
  --navy: #0f2738;
  --navy-2: #153b52;
  --ink: #24313c;
  --muted: #5b6b78;
  --bg: #f4f6f8;
  --surface: #ffffff;
  --line: #e5eaee;
  --accent: #0e7f86;
  --shadow-sm: 0 1px 2px rgba(18,40,56,.08), 0 2px 8px rgba(18,40,56,.06);
  --shadow-md: 0 6px 24px rgba(18,40,56,.10);
  --radius: 14px;
  --maxw: 1140px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
      Arial, "Noto Sans", "Liberation Sans", sans-serif;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible, [tabindex]:focus-visible {
  outline: 3px solid rgba(249,115,22,.55); outline-offset: 2px; border-radius: 4px;
}
h1, h2, h3, h4 { line-height: 1.2; color: var(--navy); font-weight: 800; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 1.25rem; }

/* ---- Skip link --------------------------------------------------- */
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--navy); color: #fff; padding: .75rem 1.25rem; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; color: #fff; text-decoration: none; }

/* ---- Top bar ------------------------------------------------------ */
.topbar { background: var(--navy); color: #dbe6ee; font-size: .92rem; }
.topbar .container { display: flex; flex-wrap: wrap; gap: 1rem 2rem; align-items: center; justify-content: space-between; padding-top: .55rem; padding-bottom: .55rem; }
.topbar a { color: #fff; }
.topbar a:hover { color: #ffd9b3; text-decoration: none; }
.topbar .tb-item { display: inline-flex; align-items: center; gap: .45rem; }
.topbar .tb-item svg { width: 16px; height: 16px; flex: none; }

/* ---- Header / nav ------------------------------------------------- */
.site-header { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; box-shadow: var(--shadow-sm); }
.nav-wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-top: .7rem; padding-bottom: .7rem; }
.brand { display: flex; align-items: center; gap: .9rem; }
.brand img { width: 190px; height: auto; }
.brand .brand-mini { display: none; font-weight: 800; color: var(--navy); font-size: 1.05rem; }

.nav-toggle {
  display: none; background: var(--brand); color: #fff; border: 0; border-radius: 8px;
  padding: .55rem .9rem; font-size: 1.3rem; line-height: 1; cursor: pointer;
}
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .25rem; align-items: center; }
.main-nav a { display: block; padding: .55rem .8rem; border-radius: 8px; color: var(--navy); font-weight: 600; font-size: .98rem; }
.main-nav a:hover { background: #fff1e6; color: var(--brand-dark); text-decoration: none; }
.main-nav a[aria-current="page"] { background: var(--brand); color: #fff; }

/* ---- Hero --------------------------------------------------------- */
.hero { background: linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 60%, #1b4b63 100%); color: #eaf2f7; padding: 4.25rem 0; }
.hero .container { display: grid; grid-template-columns: 1.4fr 1fr; gap: 2.5rem; align-items: center; }
.hero h1 { color: #fff; font-size: clamp(1.9rem, 4vw, 2.8rem); margin: 0 0 .9rem; }
.hero p.lead { font-size: 1.15rem; color: #d5e3ec; margin: 0 0 1.5rem; }
.hero .eyebrow { display: inline-block; background: rgba(249,115,22,.18); color: #ffd9b3; border: 1px solid rgba(249,115,22,.5); padding: .25rem .7rem; border-radius: 999px; font-size: .82rem; font-weight: 700; letter-spacing: .04em; margin-bottom: 1rem; }
.hero .hero-feat { margin-top: 1.6rem; display: grid; grid-template-columns: repeat(3, 1fr); gap: .9rem; }
.hero .hf { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); border-radius: 12px; padding: .9rem; }
.hero .hf b { display: block; color: #fff; font-size: 1.25rem; }
.hero .hf span { font-size: .85rem; color: #cfe0ea; }
.hero-media { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-md); }
.hero-media img { width: 100%; object-fit: cover; }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: .5rem; background: var(--brand); color: #fff; font-weight: 700; padding: .82rem 1.5rem; border-radius: 10px; border: 0; cursor: pointer; font-size: 1rem; transition: transform .12s, background .12s; }
.btn:hover { background: var(--brand-dark); color: #fff; text-decoration: none; transform: translateY(-1px); }
.btn.secondary { background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.35); }
.btn.secondary:hover { background: rgba(255,255,255,.2); }
.btn.navy { background: var(--navy); }
.btn.navy:hover { background: var(--navy-2); }
.btn-sm { padding: .5rem 1rem; font-size: .9rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; }

/* ---- Sections ------------------------------------------------------ */
.section { padding: 4rem 0; }
.section.alt { background: var(--surface); }
.section-title { text-align: center; max-width: 760px; margin: 0 auto 2.5rem; }
.section-title .kicker { color: var(--brand-dark); font-weight: 800; text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; }
.section-title h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin: .35rem 0 .7rem; }
.section-title p { color: var(--muted); margin: 0; }

/* ---- Cards / grids ------------------------------------------------ */
.grid { display: grid; gap: 1.5rem; }
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; box-shadow: var(--shadow-sm); }
.card h3 { margin: .8rem 0 .5rem; font-size: 1.2rem; }
.card p { color: var(--muted); margin: 0 0 .4rem; }
.card .ico { width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center; background: var(--brand); color: #fff; }
.card .ico svg { width: 28px; height: 28px; }
.card.hover:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); transition: .18s; }

/* Feature list with check icons */
.check { list-style: none; margin: 0 0 1rem; padding: 0; }
.check li { position: relative; padding: .35rem 0 .35rem 1.9rem; }
.check li::before {
  content: ""; position: absolute; left: 0; top: .62rem; width: 1.15rem; height: 1.15rem;
  background: var(--brand); -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z"/></svg>') center/contain no-repeat;
  mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z"/></svg>') center/contain no-repeat;
}

/* ---- Breadcrumb ---------------------------------------------------- */
.breadcrumb { padding: 1.1rem 0 .2rem; font-size: .9rem; color: var(--muted); }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: .4rem; margin: 0; padding: 0; }
.breadcrumb li + li::before { content: "/"; margin-right: .4rem; color: #aab6c0; }
.breadcrumb a { color: var(--muted); }
.breadcrumb [aria-current="page"] { color: var(--ink); font-weight: 600; }

/* Page hero (inner pages) */
.page-hero { background: linear-gradient(135deg, var(--navy), var(--navy-2)); color: #fff; padding: 2.5rem 0 2.2rem; }
.page-hero h1 { color: #fff; font-size: clamp(1.7rem, 3.4vw, 2.4rem); margin: 0 0 .4rem; }
.page-hero p { margin: 0; color: #d5e3ec; max-width: 720px; }

/* ---- Content layout (with sidebar) --------------------------------- */
.content-grid { display: grid; grid-template-columns: 1fr 320px; gap: 2rem; align-items: start; }
.content-main { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 2rem; box-shadow: var(--shadow-sm); }
.content-main h2 { font-size: 1.55rem; margin: 1.8rem 0 .8rem; }
.content-main h2:first-child { margin-top: 0; }
.content-main h3 { font-size: 1.2rem; margin: 1.3rem 0 .5rem; }
.content-main p, .content-main ul, .content-main ol { color: var(--ink); }
.sidebar { position: sticky; top: 90px; display: flex; flex-direction: column; gap: 1.25rem; }
.sidebar .card { padding: 1.3rem; }
.sidebar h3 { margin-top: 0; font-size: 1.1rem; }
.sidebar ul { list-style: none; margin: 0; padding: 0; }
.sidebar ul li { border-bottom: 1px dashed var(--line); }
.sidebar ul a { display: block; padding: .5rem 0; color: var(--ink); font-weight: 600; }
.sidebar ul a:hover { color: var(--brand-dark); }
.sidebar .cta { background: linear-gradient(135deg, var(--brand), var(--brand-dark)); color: #fff; }
.sidebar .cta h3 { color: #fff; }
.sidebar .cta a { color: #fff; text-decoration: underline; }
.sidebar .cta p { color: #ffe9d8; }

/* ---- Tables --------------------------------------------------------- */
.table-wrap { overflow-x: auto; margin: 1rem 0; }
table.data { width: 100%; border-collapse: collapse; font-size: .98rem; background: var(--surface); }
table.data th, table.data td { border: 1px solid var(--line); padding: .7rem .8rem; text-align: left; vertical-align: top; }
table.data thead th { background: var(--navy); color: #fff; font-weight: 700; }
table.data tbody tr:nth-child(even) td { background: #f8fafb; }

/* ---- FAQ ------------------------------------------------------------ */
details.faq-item { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; margin-bottom: .9rem; overflow: hidden; }
details.faq-item summary { cursor: pointer; padding: 1.1rem 1.25rem; font-weight: 700; color: var(--navy); list-style: none; position: relative; }
details.faq-item summary::-webkit-details-marker { display: none; }
details.faq-item summary::after { content: "+"; position: absolute; right: 1.25rem; color: var(--brand-dark); font-size: 1.4rem; font-weight: 800; }
details.faq-item[open] summary::after { content: "–"; }
details.faq-item .faq-body { padding: 0 1.25rem 1.1rem; color: var(--muted); }
details.faq-item .faq-body a { color: var(--accent); }
details.faq-item[open] { box-shadow: var(--shadow-sm); }

/* ---- CTA banner ------------------------------------------------------ */
.cta-banner { background: linear-gradient(120deg, var(--brand), var(--brand-dark)); color: #fff; border-radius: var(--radius); padding: 2.5rem 2rem; display: flex; flex-wrap: wrap; gap: 1.5rem; align-items: center; justify-content: space-between; box-shadow: var(--shadow-md); }
.cta-banner h2 { color: #fff; margin: 0 0 .3rem; }
.cta-banner p { margin: 0; color: #ffe9d8; max-width: 620px; }
.cta-banner .btn { background: var(--navy); }
.cta-banner .btn:hover { background: var(--navy-2); }

/* ---- Contact list ------------------------------------------------------ */
.contact-list { list-style: none; margin: 0; padding: 0; }
.contact-list li { display: flex; gap: .8rem; align-items: flex-start; padding: .7rem 0; border-bottom: 1px dashed var(--line); }
.contact-list li:last-child { border-bottom: 0; }
.contact-list .ci { flex: none; width: 40px; height: 40px; border-radius: 10px; background: #fff1e6; color: var(--brand-dark); display: grid; place-items: center; }
.contact-list .ci svg { width: 22px; height: 22px; }
.contact-list b { display: block; color: var(--navy); }
.contact-list span { color: var(--muted); }

/* ---- Footer -------------------------------------------------------------- */
.site-footer { background: var(--navy); color: #cddbe5; margin-top: 2rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.3fr; gap: 2rem; padding: 3rem 0 2rem; }
.site-footer h4 { color: #fff; font-size: 1.05rem; margin: 0 0 1rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer ul li { margin-bottom: .55rem; }
.site-footer a { color: #cddbe5; }
.site-footer a:hover { color: #fff; text-decoration: none; }
.site-footer .about { font-size: .95rem; color: #9fb3c2; }
.site-footer .brand { margin-bottom: 1rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding: 1.2rem 0; font-size: .88rem; color: #9fb3c2; text-align: center; }
.footer-bottom a { color: #ffd9b3; }
.contact-mini li { display: flex; gap: .55rem; align-items: flex-start; }
.contact-mini svg { width: 18px; height: 18px; flex: none; margin-top: .2rem; color: var(--brand); }

/* ---- Misc ------------------------------------------------------------------ */
.media-figure { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.fig-cap { font-size: .85rem; color: var(--muted); text-align: center; padding: .5rem; }
.tag { display: inline-block; background: #e8f5f3; color: var(--accent); font-size: .8rem; font-weight: 700; padding: .2rem .6rem; border-radius: 999px; }
.notice { background: #fff7ed; border-left: 4px solid var(--brand); border-radius: 6px; padding: 1rem 1.2rem; margin: 1.2rem 0; }
.notice p { margin: 0; }
.prose { max-width: 100%; }
.small { font-size: .9rem; color: var(--muted); }

/* ---- Responsive ------------------------------------------------------------ */
@media (max-width: 900px) {
  .grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .grid.cols-3 { grid-template-columns: repeat(2, 1fr); }
  .content-grid { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .hero .container { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 680px) {
  .grid.cols-2, .grid.cols-3, .grid.cols-4 { grid-template-columns: 1fr; }
  .hero { padding: 3rem 0; }
  .hero .hero-feat { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .nav-toggle { display: block; }
  .main-nav { position: absolute; left: 0; right: 0; top: 100%; background: var(--surface); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-md); display: none; }
  .main-nav.open { display: block; }
  .main-nav ul { flex-direction: column; align-items: stretch; padding: .5rem 1rem 1rem; }
  .main-nav a { padding: .75rem .5rem; }
}
