/* ──────────────────────────────────────────────────────────────────────── */
/*  files-tech.com — Design system inspiré GitHub Dark                       */
/* ──────────────────────────────────────────────────────────────────────── */

:root {
  --bg:        #0d1117;
  --surface:   #161b22;
  --surface-2: #21262d;
  --border:    #30363d;
  --text:      #e6edf3;
  --text-sec:  #8b949e;
  --accent:    #58a6ff;
  --accent-bg: #1f6feb;
  --accent-bg-hover: #388bfd;
  --red:       #f85149;
  --red-app:   #c62828;
  --green:     #3fb950;
  --gold:      #f9a825;
  --shadow:    0 1px 3px rgba(0,0,0,.3), 0 0 0 1px rgba(255,255,255,.04);

  --maxw:      1180px;
  --radius:    12px;
  --radius-sm: 8px;

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

  --link-hover: #79b8ff;
  --btn-secondary-hover: #2d333b;
  --btn-support-hover: #273343;
  --selection-text: #ffffff;
  --hero-glow-primary: rgba(31, 111, 235, 0.12);
  --hero-glow-secondary: rgba(198, 40, 40, 0.06);
  --alert-success-bg: #1f3a1f;
  --alert-success-border: #2ea043;
  --alert-success-text: #56d364;
  --alert-error-bg: #3a1f1f;
  --alert-error-border: #f85149;
  --alert-error-text: #ff7b72;
  --privacy-banner-bg: rgba(13, 17, 23, 0.82);
  --privacy-banner-text: #f0f0f0;
  --privacy-banner-shadow: 0 1px 5px rgba(46, 54, 65, 0.9);
  --privacy-banner-link: #56a0f4;
  --privacy-banner-link-hover: #76b3f9;
  --privacy-banner-button-bg: #333e4c;
  --privacy-banner-button-bg-hover: #2c3541;
  --privacy-banner-close-bg-hover: #2d3743;
}

/* Reuse the same semantic aliases across the site templates. */
:root {
  --text-primary: var(--text);
  --text-secondary: var(--text-sec);
}

:root[data-theme="light"] {
  --bg:        #eef3f8;
  --surface:   #f4f8fc;
  --surface-2: #e9f0f7;
  --border:    #c7d2df;
  --text:      #1f2328;
  --text-sec:  #4f5d6b;
  --accent:    #4d78a8;
  --accent-bg: #5f84ad;
  --accent-bg-hover: #55789f;
  --red:       #b86c68;
  --red-app:   #b86c68;
  --green:     #5f8b69;
  --gold:      #9d8360;
  --shadow:    0 8px 24px rgba(31, 35, 40, .08), 0 1px 3px rgba(31, 35, 40, .06), 0 0 0 1px rgba(199, 210, 223, .55);

  --link-hover: #426b96;
  --btn-secondary-hover: #e2e9f2;
  --btn-support-hover: #55789f;
  --selection-text: #ffffff;
  --hero-glow-primary: rgba(95, 132, 173, 0.10);
  --hero-glow-secondary: rgba(184, 108, 104, 0.05);
  --alert-success-bg: #e6f0e8;
  --alert-success-border: #9eb8a4;
  --alert-success-text: #44614a;
  --alert-error-bg: #f8ece9;
  --alert-error-border: #d1a7a2;
  --alert-error-text: #8d5c58;
  --privacy-banner-bg: rgba(244, 248, 252, 0.96);
  --privacy-banner-text: #1f2328;
  --privacy-banner-shadow: 0 10px 30px rgba(31, 35, 40, 0.12);
  --privacy-banner-link: #567ca5;
  --privacy-banner-link-hover: #476b92;
  --privacy-banner-button-bg: #e7edf4;
  --privacy-banner-button-bg-hover: #dbe4ee;
  --privacy-banner-close-bg-hover: #dbe4ee;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; display: block; }

a {
  color: var(--accent);
  text-decoration: none;
  transition: color .15s;
}
a:hover { color: var(--link-hover); text-decoration: underline; }

::selection { background: var(--accent-bg); color: var(--selection-text); }

/* ── Layout ─────────────────────────────────────────────────────────────── */

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

main { min-height: 60vh; }

/* ── Header ─────────────────────────────────────────────────────────────── */

header.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(8px);
}

:root[data-theme="light"] header.site-header {
  background: rgba(244, 248, 252, 0.92);
  box-shadow: 0 1px 0 rgba(199, 210, 223, 0.35);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  gap: 24px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
  color: var(--text);
  text-decoration: none;
}
.logo:hover { text-decoration: none; color: var(--accent); }
.logo-mark { width: 28px; height: 28px; border-radius: 6px; }
.logo-text { font-family: var(--mono); letter-spacing: -0.02em; }

.nav-links {
  display: flex;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  color: var(--text-sec);
  padding: 8px 14px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
}
.nav-links a:hover {
  color: var(--text);
  background: var(--surface-2);
  text-decoration: none;
}
.nav-links a.active { color: var(--text); }

:root[data-theme="light"] .nav-links a.active {
  background: #dde7f0;
  border: 1px solid #cad5e0;
}

.nav-theme-divider {
  position: relative;
  margin-right: 8px;
  padding-right: 8px;
}

.nav-theme-divider::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 0;
  width: 1px;
  height: 20px;
  background: var(--border);
  transform: translateY(-50%);
}

.nav-theme-toggle-item {
  display: flex;
  align-items: center;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  color: var(--text);
  padding: 6px 10px;
  border-radius: 6px;
  cursor: pointer;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-sec);
  cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
  flex: 0 0 auto;
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
  background: var(--surface-2);
  color: var(--text);
  border-color: var(--border);
  outline: none;
}

.theme-toggle-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.theme-toggle-icon svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.theme-toggle-icon-sun {
  display: none;
}

:root[data-theme="light"] .theme-toggle-icon-sun {
  display: inline-flex;
}

:root[data-theme="light"] .theme-toggle-icon-moon {
  display: none;
}

/* ── Hero ───────────────────────────────────────────────────────────────── */

.hero {
  padding: 80px 0 64px;
  text-align: center;
  background:
    radial-gradient(ellipse 60% 80% at 50% 0%, var(--hero-glow-primary), transparent),
    radial-gradient(ellipse 60% 80% at 80% 50%, var(--hero-glow-secondary), transparent);
}

.hero h1 {
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.1;
  margin: 0 0 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.hero p.lead {
  font-size: clamp(16px, 2vw, 20px);
  color: var(--text-sec);
  max-width: 720px;
  margin: 0 auto 32px;
}

.hero.hero-compact {
  padding: 48px 0 24px;
}

.hero.hero-medium {
  padding: 64px 0 32px;
}

.hero.hero-error {
  padding: 96px 0;
  text-align: center;
}

.hero-title-medium {
  font-size: clamp(28px, 4vw, 42px);
}

.hero-title-error {
  margin: 0;
  font-size: clamp(48px, 8vw, 96px);
}

.hero-cta {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Pastille de version à côté du h1 dans le hero des pages app */
.hero-version {
  display: inline-block;
  vertical-align: middle;
  margin-left: 10px;
  padding: 3px 10px;
  font-size: 0.5em;
  font-weight: 500;
  color: var(--muted);
  background: rgba(139, 148, 158, .12);
  border: 1px solid rgba(139, 148, 158, .3);
  border-radius: 999px;
  letter-spacing: 0.3px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  position: relative;
  top: -3px;
}

/* ── Buttons ────────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  transition: background .15s, transform .15s;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: inherit;
}
.btn-primary {
  background: var(--accent-bg);
  color: #fff;
  border-color: rgba(255,255,255,.1);
}
.btn-primary:hover {
  background: var(--accent-bg-hover);
  color: #fff;
  text-decoration: none;
}
.btn-secondary {
  background: var(--surface-2);
  color: var(--text);
  border-color: var(--border);
}
.btn-secondary:hover {
  background: var(--btn-secondary-hover);
  text-decoration: none;
  color: var(--text);
}

/* ── Sections ───────────────────────────────────────────────────────────── */

section {
  padding: 64px 0;
}

section h2 {
  font-size: clamp(24px, 3vw, 32px);
  margin: 0 0 12px;
  letter-spacing: -0.02em;
}
section p.section-lead {
  color: var(--text-sec);
  font-size: 17px;
  margin: 0 0 40px;
}

/* Content helpers used by legal, contact, and marketing pages. */
.section-surface {
  background: var(--surface);
}

.container-narrow {
  max-width: 820px;
}

.container-form {
  max-width: 720px;
}

.text-center {
  text-align: center;
}

.section-lead-centered {
  margin: 0 auto 32px;
}

.inline-link-copy {
  color: var(--text-secondary);
}

.inline-note {
  color: var(--text-secondary);
  font-size: 14px;
}

.visually-hidden-honeypot {
  position: absolute;
  left: -9999px;
}

.panel-box {
  margin-bottom: 24px;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.panel-box > :first-child {
  margin-top: 0;
}

.section-heading-gap {
  margin-top: 24px;
}

/* ── Apps grid ──────────────────────────────────────────────────────────── */

.apps-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(3, 1fr);
}
@media (max-width: 980px) {
  .apps-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 600px) {
  .apps-grid {
    grid-template-columns: 1fr;
  }
}

.app-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  transition: border-color .15s, transform .15s, box-shadow .15s;
  display: flex;
  flex-direction: column;
}

/* Placeholder invisible : occupe une cellule de la grille 3×2 pour
   garder l'alignement quand on a 5 apps réelles, sans afficher de
   "trou" visuel. Sera remplacé par une 6e carte réelle plus tard. */
.app-card-placeholder {
  visibility: hidden;
  pointer-events: none;
  border: none;
  background: transparent;
  box-shadow: none;
}
@media (max-width: 980px) {
  /* En 2 colonnes, 5 cards = 2+2+1, le placeholder n'a plus de sens et
     dérange visuellement → on le retire. */
  .app-card-placeholder { display: none; }
}

/* Notice d'emploi (notes-tech.php) — étapes numérotées plus respirantes
   que des <ol> bruts. */
ol.numbered-steps {
  padding-left: 24px;
  margin: 16px 0;
}
ol.numbered-steps > li {
  margin-bottom: 12px;
  line-height: 1.55;
}
.muted {
  color: var(--muted, #888);
  font-size: 0.92em;
  margin-top: 12px;
}

:root[data-theme="light"] .app-card,
:root[data-theme="light"] .panel-box,
:root[data-theme="light"] form.contact-form,
:root[data-theme="light"] .screenshot,
:root[data-theme="light"] table.simple th {
  box-shadow: var(--shadow);
}

:root[data-theme="light"] .app-card,
:root[data-theme="light"] .panel-box,
:root[data-theme="light"] form.contact-form,
:root[data-theme="light"] .screenshot,
:root[data-theme="light"] table.simple th,
:root[data-theme="light"] footer.site-footer,
:root[data-theme="light"] header.site-header {
  background-color: var(--surface);
}
.app-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(88, 166, 255, .1);
  text-decoration: none;
}
.app-card-icon {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  margin-bottom: 16px;
  flex: 0 0 auto;
}
.app-card h3 {
  margin: 0 0 8px;
  font-size: 20px;
  color: var(--text);
}
.app-card p {
  color: var(--text-sec);
  margin: 0 0 16px;
  font-size: 14px;
  flex-grow: 1;
}
.app-card .meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: auto;
}
.tag {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text-sec);
  border: 1px solid var(--border);
  font-weight: 500;
}
.tag.green  { color: var(--green); border-color: rgba(63, 185, 80, .3); }
.tag.red    { color: var(--red); border-color: rgba(248, 81, 73, .3); }
.tag.gold   { color: var(--gold); border-color: rgba(249, 168, 37, .3); }
.tag.blue   { color: var(--accent); border-color: rgba(88, 166, 255, .3); }
.tag.version{ color: var(--muted); border-color: rgba(139, 148, 158, .3); font-variant-numeric: tabular-nums; letter-spacing: 0.3px; }

:root[data-theme="light"] .tag {
  background: #e3ebf3;
  color: var(--text-sec);
  border-color: #ced9e4;
}

:root[data-theme="light"] .tag.green { border-color: rgba(26, 127, 55, .22); }
:root[data-theme="light"] .tag.red { border-color: rgba(207, 34, 46, .2); }
:root[data-theme="light"] .tag.gold { border-color: rgba(154, 103, 0, .22); }
:root[data-theme="light"] .tag.blue { border-color: rgba(9, 105, 218, .22); }

/* ── Features ────────────────────────────────────────────────────────────── */

.features {
  display: grid;
  gap: 24px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.feature {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.feature-icon {
  width: 36px;
  height: 36px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 18px;
}
.feature h4 {
  margin: 0;
  font-size: 16px;
  color: var(--text);
}
.feature p {
  margin: 0;
  color: var(--text-sec);
  font-size: 14px;
}

/* ── App detail page ──────────────────────────────────────────────────── */

.app-hero {
  padding: 48px 0;
  border-bottom: 1px solid var(--border);
}
.app-hero-title {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.app-hero .icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  flex: 0 0 auto;
}
.app-hero h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.1;
}
.app-hero .tagline {
  color: var(--text-sec);
  margin: 0;
  font-size: 16px;
}

.app-hero .hero-cta {
  justify-content: flex-start;
  margin-top: 16px;
}

/* App icon color variants for detail pages and card fallbacks. */
.icon-bg-pdf {
  background: var(--red-app);
}

.icon-bg-read {
  background: var(--accent-bg);
}

.icon-bg-pass {
  background: var(--gold);
}

.screenshots {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin: 32px 0;
}
.screenshot {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 9 / 19;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-sec);
  font-size: 13px;
  text-align: center;
  padding: 20px;
}
.screenshot img { width: 100%; height: 100%; object-fit: cover; }

.screenshots-note {
  color: var(--text-sec);
  font-size: 13px;
  text-align: center;
}

/* ── Code blocks ──────────────────────────────────────────────────────── */

code, pre {
  font-family: var(--mono);
  background: var(--surface-2);
  border-radius: 6px;
  border: 1px solid var(--border);
}
code {
  padding: 2px 6px;
  font-size: .9em;
}
pre {
  padding: 16px;
  overflow-x: auto;
  font-size: 13px;
  line-height: 1.5;
  margin: 16px 0;
}
pre code {
  background: none;
  border: 0;
  padding: 0;
}

/* ── Tables ────────────────────────────────────────────────────────────── */

table.simple {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 14px;
}
table.simple th, table.simple td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
table.simple th {
  color: var(--text-sec);
  font-weight: 600;
  background: var(--surface);
}
table.simple tr:hover { background: var(--surface); }

/* ── Form ──────────────────────────────────────────────────────────────── */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

.contact-info h3 {
  margin-top: 0;
}
.contact-info p { color: var(--text-sec); font-size: 15px; }
.contact-info ul {
  list-style: none;
  padding: 0;
}
.contact-info li {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 8px 0;
}

form.contact-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
}

.form-row { margin-bottom: 16px; }
.form-row label {
  display: block;
  font-size: 13px;
  color: var(--text-sec);
  margin-bottom: 6px;
  font-weight: 500;
}

.field {
  width: 100%;
  padding: 10px 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
  font-size: 15px;
  font-family: inherit;
  transition: border-color .15s, box-shadow .15s;
}

:root[data-theme="light"] .field {
  background: #f1f6fb;
}
.field:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(88, 166, 255, .15);
}
textarea.field { resize: vertical; min-height: 140px; }

.form-row .checkbox-radio {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 13px;
  color: var(--text-sec);
}
.form-row .checkbox-radio input { margin-top: 4px; flex-shrink: 0; }

.msg {
  margin-top: 12px;
  padding: 10px 14px;
  border-radius: 6px;
  font-size: 14px;
  display: none;
}
.msg.success {
  background: rgba(63, 185, 80, .1);
  color: var(--green);
  border: 1px solid rgba(63, 185, 80, .3);
  display: block;
}
.msg.error {
  background: rgba(248, 81, 73, .1);
  color: var(--red);
  border: 1px solid rgba(248, 81, 73, .3);
  display: block;
}

.alert-box {
  margin-bottom: 24px;
  padding: 16px;
  border: 1px solid transparent;
  border-radius: var(--radius);
}

.alert-box.alert-success {
  background: var(--alert-success-bg);
  border-color: var(--alert-success-border);
  color: var(--alert-success-text);
}

.alert-box.alert-error {
  background: var(--alert-error-bg);
  border-color: var(--alert-error-border);
  color: var(--alert-error-text);
}

/* ===============================
======= Banniere info Cookie ===*/
.privacy-info-banner {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 9999;
  display: flex;
  justify-content: center;
}

.privacy-info-banner__inner {
  width: 100%;
  max-width: 920px;
  background: var(--privacy-banner-bg);
  color: var(--privacy-banner-text);
  border: 1px solid var(--border);
  border-radius: 7px;
  box-shadow: var(--privacy-banner-shadow);
  backdrop-filter: blur(6px);
}

.privacy-info-banner__content {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.2rem;
}

.privacy-info-banner__text {
  flex: 1 1 auto;
}

.privacy-info-banner__text strong {
  display: inline-block;
  margin-bottom: 0.35rem;
  font-size: 1.200rem;
  color: var(--privacy-banner-link);
  letter-spacing: 0.02em;
}

.privacy-info-banner__text p {
  margin: 0.35rem 0 0;
  font-size: 0.850rem;
  color: var(--text-sec);
  line-height: 1.4;
}

:root[data-theme="light"] .privacy-info-banner__inner {
  box-shadow: 0 18px 45px rgba(31, 35, 40, 0.14);
}

.privacy-info-banner__text a {
  color: var(--privacy-banner-link);
  text-decoration: none;
  text-underline-offset: 2px;
}

.privacy-info-banner__text a:hover,
.privacy-info-banner__text a:focus {
  text-decoration: underline;
  color: var(--privacy-banner-link-hover);
}

.privacy-info-banner__actions {
  flex: 0 0 auto;
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
}

.privacy-info-banner__form {
  margin: 0;
}

.privacy-info-banner__btn,
.privacy-info-banner__close {
  appearance: none;
  border: 0;
  cursor: pointer;
  font: inherit;
}

.privacy-info-banner__btn {
  background: var(--privacy-banner-button-bg);
  color: var(--text);
  padding: 0.65rem 1rem;
  border-radius: 999px;
  line-height: 1;
  white-space: nowrap;
}

.privacy-info-banner__btn:hover,
.privacy-info-banner__btn:focus {
  color: var(--text);
  background: var(--privacy-banner-button-bg-hover);
}

.privacy-info-banner__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.2rem;
  height: 2.2rem;
  padding: 0;
  border-radius: 999px;
  background: var(--privacy-banner-button-bg);
  color: var(--text);
  border: 1px solid var(--border);
  font-size: 1.2rem;
  line-height: 1;
  font-weight: 600;
  text-align: center;
}

.privacy-info-banner__close-icon {
  display: block;
  line-height: 1;
  transform: translateY(-1px);
}

.privacy-info-banner__close:hover,
.privacy-info-banner__close:focus {
  background: var(--privacy-banner-close-bg-hover);
  color: var(--text);
}

@media (max-width: 720px) {
  .privacy-info-banner {
    left: 0.6rem;
    right: 0.6rem;
    bottom: 0.6rem;
  }

  .privacy-info-banner__content {
    flex-direction: column;
    align-items: stretch;
    padding: 0.95rem 1rem;
  }

  .privacy-info-banner__actions {
    justify-content: space-between;
    align-items: center;
  }

  .privacy-info-banner__btn {
    width: 100%;
  }
}

/* ── Footer ────────────────────────────────────────────────────────────── */

footer.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 48px 0 32px;
  margin-top: 64px;
}

.footer-brand {
  margin-bottom: 12px;
}

.footer-copy {
  margin: 8px 0 0;
  color: var(--text-sec);
  font-size: 14px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 32px;
}

.footer-grid h5 {
  margin: 0 0 12px;
  font-size: 13px;
  color: var(--text-sec);
  text-transform: uppercase;
  letter-spacing: .05em;
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { padding: 4px 0; }
.footer-grid a {
  color: var(--text-sec);
  font-size: 14px;
}
.footer-grid a:hover { color: var(--text); }

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  color: var(--text-sec);
  font-size: 13px;
}

/* ── Responsive ────────────────────────────────────────────────────────── */

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 12px;
    gap: 0;
  }
  .nav-links.open { display: flex; }
  .nav-toggle { display: block; }
  .nav-theme-divider {
    margin-right: 0;
    padding-right: 0;
  }
  .nav-theme-divider::after {
    display: none;
  }
  .nav-theme-toggle-item {
    padding-top: 8px;
    margin-top: 8px;
    border-top: 1px solid var(--border);
  }
  .theme-toggle { order: 2; }
  .nav-toggle { order: 3; }
  .contact-grid { grid-template-columns: 1fr; gap: 24px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .app-hero { text-align: center; }
  .app-hero-title { justify-content: center; }
  .app-hero .hero-cta { justify-content: center; }
}

/* ── Contact form ─────────────────────────────────────────────────────── */
.contact-form .form-row { margin-bottom: 18px; }
.contact-form label { display: block; margin-bottom: 6px; font-weight: 600; color: var(--text-primary); font-size: 14px; }
.contact-form .field {
  width: 100%; box-sizing: border-box;
  background: var(--surface-2); color: var(--text-primary);
  border: 1px solid var(--border); border-radius: 6px;
  padding: 10px 12px; font-size: 14px; font-family: inherit;
}
.contact-form .field:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(88,166,255,.25); }
.contact-form textarea.field { resize: vertical; min-height: 140px; }
.contact-form .checkbox-inline { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 13px; color: var(--text-secondary); cursor: pointer; }
.contact-form .checkbox-inline input {
  width: auto;
  min-width: 16px;
  margin: 3px 0 0;
  padding: 0;
  flex: 0 0 auto;
}
.contact-form .checkbox-inline span {
  min-width: 0;
  flex: 1 1 auto;
}
.contact-form .checkbox-inline a { color: var(--accent); }

/* ====== Page Soutenir / don.php ====== */
.don-amounts { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.don-amounts .don-preset { padding: 8px 18px; font-size: 14px; }

/* Note "Soutenir" en bas des pages d'apps — encadrée mais sobre */
.support-note {
  margin: 2.5rem 0 1rem;
  padding: 1.25rem 1.5rem;
}
.support-note .container {
  border: 1px solid var(--border);
  background: var(--surface-2, rgba(255,255,255,0.02));
  border-radius: 10px;
  padding: 1.25rem 1.5rem;
  text-align: center;
}
.support-note p {
  margin: 0;
  font-size: 15px;
  color: var(--text-primary);
  line-height: 1.6;
}
.support-note a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.support-note a:hover { text-decoration-thickness: 2px; }

/* Bouton tertiaire "Soutenir" — discret, à côté de Code source */
.btn-support {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
}
.btn-support:hover {
  background: var(--btn-support-hover);
  color: #fff;
}

/* Tableau comparatif (utilisé sur ai-tech.php) */
.cmp-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0 0.5rem;
  font-size: 0.95rem;
  background: var(--surface, #161b22);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}
.cmp-table thead {
  background: var(--accent-soft, rgba(88, 166, 255, 0.12));
}
.cmp-table th,
.cmp-table td {
  padding: 0.7rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border, rgba(127, 127, 127, 0.18));
  vertical-align: top;
}
.cmp-table th {
  font-weight: 700;
  color: var(--accent);
}
.cmp-table tbody tr:last-child td {
  border-bottom: none;
}
.cmp-table tbody tr:hover {
  background: rgba(127, 127, 127, 0.05);
}
.cmp-table td:first-child {
  font-weight: 600;
}
@media (max-width: 640px) {
  .cmp-table {
    font-size: 0.85rem;
  }
  .cmp-table th,
  .cmp-table td {
    padding: 0.55rem 0.6rem;
  }
}
