/* =========================================================================
   Marketing pages (home + pricing) — palette + page-specific components
   Base = ECRU (light); MIDNIGHT for dark. Theme is driven by the
   data-theme="light|dark" attribute on <html> (shared site-wide with the docs
   page). Only the marketing pages load this file, so its token vocabulary and
   component classes never clash with the docs page.
   ========================================================================= */

/* ============================== Palette =========================== */
:root {
  /* Brand purple (kit LOGO_PNG_SVG, nuancier): --ac fills buttons and borders,
     --ac-text colours text and links (lighter kit shade on dark backgrounds). */
  /* Fonts (AUD-236): Symfony's system font stack for text and titles,
     JetBrains Mono for code, terminal and uppercase labels. */
  --font-sans: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans', 'Liberation Sans', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --ac:#4F46E5; --ac-rgb:79,70,229; --ac-text:#4F46E5; --on-ac:#FFFFFF;
  --bg-page:#F4F0E6; --bg-deep:#ECE6D6; --bg-grad2:#F4F0E6;
  --surface:#FFFFFF; --surface-card:#FFFFFF; --surface-hi:#FFFFFF; --surface-hi2:#FFFFFF; --ctx-bg:#F7F3E9;
  --nav-bg:rgba(244,240,230,0.82);
  --bd-12:rgba(42,37,28,0.16); --bd-10:rgba(42,37,28,0.12); --bd-09:rgba(42,37,28,0.11); --bd-08:rgba(42,37,28,0.10); --bd-07:rgba(42,37,28,0.09); --bd-06:rgba(42,37,28,0.08); --bd-05:rgba(42,37,28,0.07); --bd-04:rgba(42,37,28,0.055); --bd-03:rgba(42,37,28,0.04); --bd-02:rgba(42,37,28,0.03);
  --tx-1:#211E16; --tx-2:#211E16; --tx-3:#2A2620; --tx-4:#3A352B; --tx-5:#4A4434; --tx-6:#4A4434; --tx-7:#6E6757; --tx-8:#837B6A; --tx-9:#9A917D;
  --amber:#B45309; --amber-bg:rgba(180,83,9,0.14); --red:#DC2626; --red-bg:rgba(220,38,38,0.10); --red-line:rgba(220,38,38,0.5); --green:#059669; --green-bg:rgba(5,150,105,0.10);
  --focus:#4F46E5;
  --glow-a:0.22; --play:running; --lift:-3px;
}

:root[data-theme="dark"] {
  --ac-text:#9590EF;
  --bg-page:#08090C; --bg-deep:#0A0B0F; --bg-grad2:#0C0E13;
  --surface:#0E1014; --surface-card:#0C0E12; --surface-hi:#101218; --surface-hi2:#14161D; --ctx-bg:#08090C;
  --nav-bg:rgba(8,9,12,0.72);
  --bd-12:rgba(255,255,255,0.12); --bd-10:rgba(255,255,255,0.1); --bd-09:rgba(255,255,255,0.09); --bd-08:rgba(255,255,255,0.08); --bd-07:rgba(255,255,255,0.07); --bd-06:rgba(255,255,255,0.06); --bd-05:rgba(255,255,255,0.05); --bd-04:rgba(255,255,255,0.04); --bd-03:rgba(255,255,255,0.03); --bd-02:rgba(255,255,255,0.02);
  --tx-1:#F7F8FA; --tx-2:#F2F3F5; --tx-3:#E8EAED; --tx-4:#DDE0E5; --tx-5:#C9CDD4; --tx-6:#B9BEC7; --tx-7:#9AA0AB; --tx-8:#8A9099; --tx-9:#6B7280;
  --amber:#FBBF24; --amber-bg:rgba(251,191,36,0.14); --red:#F87171; --red-bg:rgba(248,113,113,0.1); --red-line:rgba(248,113,113,0.55); --green:#34D399; --green-bg:rgba(52,211,153,0.1);
}
/* CALM ambiance: dial down glow + motion + hover lift */
.amb-calm { --glow-a:0.05; --play:paused; --lift:0px; }

/* ============================ Element base ======================== */
body { background: var(--bg-page); color: var(--tx-3); font-family: var(--font-sans); transition: background 0.35s ease; }
/* Titles as on symfony.com: weight 600, tighter letter-spacing on h1/h2. */
h1, h2, h3 { font-family: var(--font-sans); font-weight: 600; }
h1, h2 { letter-spacing: -0.02em; }
a { color: inherit; }
::selection { background: rgba(var(--ac-rgb),0.35); color: #fff; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--bd-12); border-radius: 8px; }
::-webkit-scrollbar-track { background: transparent; }

/* ============================ Animations ========================== */
@keyframes acpulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }
@keyframes acfloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }

/* ============================ Components ========================== */
/* Nav links */
.lnk { color: var(--tx-7); text-decoration: none; font-size: 14px; transition: color .2s; }
.lnk:hover { color: var(--tx-3); }
/* Section eyebrow label above each heading */
.eyebrow { font-family: var(--font-mono); text-transform: uppercase; font-size: 12px; letter-spacing: 0.16em; color: var(--ac-text); }
/* Section heading */
.h-section { font-weight: 600; font-size: 42px; letter-spacing: -0.02em; color: var(--tx-1); margin: 14px 0 0; }
/* Surface card / container driven by design tokens */
.panel { background: var(--surface); border: 1px solid var(--bd-07); border-radius: 14px; }
/* Narrow viewports: stack the inline grids, hide the nav links, shrink the headings */
.code-tabs { overflow-x: auto; }
@media (max-width: 780px) {
  .grid-stack { grid-template-columns: 1fr !important; }
  .nav-links .lnk { display: none; }
  .hero-title { font-size: 40px !important; }
  .h-section { font-size: 32px; }
}

/* ===================== Buttons (shared marketing CTAs) ============= */
/* Primary = accent fill; outline = bordered/secondary. Used on the home
   CTA and the pricing cards. */
.btn-primary {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--ac); color: var(--on-ac);
  font-weight: 600; font-size: 14px; padding: 12px 20px;
  border: 1px solid var(--ac); border-radius: 10px; cursor: pointer;
  transition: transform .15s ease, filter .2s ease;
}
.btn-primary:hover { filter: brightness(1.05); transform: translateY(var(--lift, -3px)); }
.btn-outline {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--bd-05); color: var(--tx-3);
  font-weight: 500; font-size: 14px; padding: 12px 20px;
  border: 1px solid var(--bd-10); border-radius: 10px; cursor: pointer;
  transition: transform .15s ease, border-color .2s ease;
}
.btn-outline:hover { border-color: rgba(var(--ac-rgb),0.4); transform: translateY(var(--lift, -3px)); }

/* ============================ Pricing page ======================== */
/* Pricing tier card. --featured variant is visually emphasised (accent
   border + soft glow) to steer conversion toward the commercial license. */
.price-card {
  display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--bd-07);
  border-radius: 16px; padding: 32px 30px;
}
.price-card--featured {
  border-color: rgba(var(--ac-rgb),0.55);
  box-shadow: 0 0 0 1px rgba(var(--ac-rgb),0.25), 0 18px 50px -28px rgba(var(--ac-rgb),0.6);
}
.price-badge {
  align-self: flex-start;
  font-family: var(--font-mono); text-transform: uppercase;
  font-size: 11px; letter-spacing: 0.12em;
  color: var(--ac-text); background: rgba(var(--ac-rgb),0.13);
  border: 1px solid rgba(var(--ac-rgb),0.3);
  padding: 5px 11px; border-radius: 999px; margin-bottom: 18px;
}
.price-tag { font-family: var(--font-sans); font-weight: 700; font-size: 40px; letter-spacing: -0.02em; color: var(--tx-1); }
.price-tag small { font-family: var(--font-sans); font-weight: 400; font-size: 15px; color: var(--tx-7); }
.price-features { list-style: none; margin: 22px 0 28px; padding: 0; display: flex; flex-direction: column; gap: 13px; }
.price-features li { position: relative; padding-left: 26px; font-size: 14.5px; line-height: 1.5; color: var(--tx-6); }
.price-features li::before {
  content: ""; position: absolute; left: 0; top: 3px;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--green-bg);
  /* check mark */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23059669' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 8.5l3 3 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: center;
}
[data-theme="dark"] .price-features li::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%2334D399' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 8.5l3 3 6-6'/%3E%3C/svg%3E");
}
.price-card .btn-primary,
.price-card .btn-outline { margin-top: auto; justify-content: center; }

/* FAQ */
.faq-item { border-top: 1px solid var(--bd-07); padding: 24px 0; }
.faq-item:last-child { border-bottom: 1px solid var(--bd-07); }
.faq-item h3 { font-size: 17px; color: var(--tx-2); margin-bottom: 10px; }
.faq-item p { font-size: 14.5px; line-height: 1.65; color: var(--tx-7); }
.faq-item p code { font-family: var(--font-mono); font-size: 13px; color: var(--tx-3); background: var(--bd-05); padding: 1px 6px; border-radius: 5px; white-space: nowrap; }
.faq-item p a { color: var(--ac-text); text-decoration: underline; text-underline-offset: 2px; }


/* ============================ Site footer ========================= */
/* Shared by the home and pricing pages (templates/partials/_site_footer.html.twig). */
.site-footer { border-top: 1px solid var(--bd-07); background: var(--bg-page); }
.site-footer__top { display: flex; justify-content: space-between; gap: 48px; padding-block: 56px 40px; }
.site-footer__brand { max-width: 380px; }
.site-footer__logo { height: 26px; }
.site-footer__brand p { margin: 16px 0 0; font-size: 14.5px; line-height: 1.6; color: var(--tx-7); }
.site-footer__cols { display: flex; gap: 64px; }
.site-footer__col h2 { font-family: var(--font-mono); font-weight: 500; font-size: 11.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--tx-7); margin: 0 0 14px; }
.site-footer__col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.site-footer__col a { font-size: 14.5px; color: var(--tx-3); text-decoration: none; transition: color .2s; }
.site-footer__col a:hover { color: var(--ac-text); }
.site-footer__bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding-block: 22px 32px; border-top: 1px solid var(--bd-07); font-family: var(--font-mono); font-size: 12px; color: var(--tx-7); }
@media (max-width: 780px) {
  .site-footer__top { flex-direction: column; gap: 32px; }
  .site-footer__cols { gap: 48px; }
}

/* ============================ Home page =========================== */
/* Sections of the home page (AUD-232). */
.home-lead { font-size: 16.5px; line-height: 1.65; color: var(--tx-7); max-width: 640px; margin: 16px 0 0; }
.home-lead strong { color: var(--tx-3); font-weight: 600; }
.home-band { background: var(--bg-deep); border-block: 1px solid var(--bd-06); }
/* "What is" section: text left, architecture diagram right (AUD-260) */
.bundle-grid { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1.15fr); gap: 56px; align-items: center; }
.bundle-figure { margin: 0; }
.bundle-figure img { display: block; width: 100%; height: auto; border-radius: 14px; border: 1px solid var(--bd-10); box-shadow: 0 24px 60px rgba(0,0,0,0.18); }
/* Centered section header: title, text and buttons (AUD-244) */
.home-center { text-align: center; }
.home-center .home-lead { margin-inline: auto; }

/* Picto in a light-purple rounded square (Figma "AuditLog" mock-up) */
.icon-tile { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 48px; height: 48px; border-radius: 8px; background: rgba(var(--ac-rgb),0.10); color: var(--ac-text); }
.icon-tile--sm { width: 36px; height: 36px; border-radius: 6px; }
[data-theme="dark"] .icon-tile { background: rgba(var(--ac-rgb),0.20); }
.icon-tile .icon { display: block; }

/* Operational history timeline */
.timeline { list-style: none; margin: 0; padding: 0 0 0 26px; position: relative; display: flex; flex-direction: column; gap: 14px; }
.timeline::before { content: ""; position: absolute; left: 7px; top: 8px; bottom: 8px; width: 1px; background: var(--bd-12); }
.timeline__item { position: relative; background: var(--surface); border: 1px solid var(--bd-07); border-radius: 12px; padding: 16px 18px; }
.timeline__item::before { content: ""; position: absolute; left: -23px; top: 29px; width: 9px; height: 9px; border-radius: 50%; background: var(--ac); box-shadow: 0 0 0 3px var(--bg-page); }
.timeline__head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.timeline__head .timeline__title { flex: 1; }
.timeline__title { font-family: var(--font-mono); font-weight: 600; font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--tx-2); }
.timeline__source { font-family: var(--font-mono); font-size: 11.5px; color: var(--ac-text); }
.timeline__item p { margin: 0; font-size: 14px; line-height: 1.55; color: var(--tx-7); }

.why-card { transition: transform .2s, border-color .2s; }
.why-card:hover { border-color: rgba(var(--ac-rgb),0.4) !important; transform: translateY(var(--lift, -3px)); }

/* Video section: always dark, whatever the theme */
.home-dark { background: #0C0E12; color: #E8EAED; --ac-text: #9590EF; }
.home-dark .h-section { color: #F7F8FA; }
.home-dark .home-lead { color: #9AA0AB; }
.video-thumb { position: relative; aspect-ratio: 16 / 9; border-radius: 16px; border: 1px solid rgba(255,255,255,0.09); background: #14161D; overflow: hidden; }
.video-thumb__video { display: block; width: 100%; height: 100%; object-fit: cover; }
.video-thumb__overlay { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; border: 0; padding: 0; background: rgba(10,11,16,0.12); cursor: pointer; transition: background .2s; }
.video-thumb__overlay:hover { background: rgba(10,11,16,0.22); }
.video-thumb__overlay:focus-visible { outline: 3px solid var(--ac); outline-offset: -3px; border-radius: 16px; }
.video-thumb__overlay[hidden] { display: none; }
.video-thumb__play { width: 76px; height: 76px; border-radius: 50%; background: var(--ac); color: var(--on-ac); display: flex; align-items: center; justify-content: center; padding-left: 4px; box-shadow: 0 0 40px rgba(var(--ac-rgb),0.45); transition: transform .2s; }
.video-thumb__overlay:hover .video-thumb__play { transform: scale(1.06); }

/* Pricing plans (3 columns) */
.plans-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; margin-top: 40px; align-items: stretch; }
.price-tag--text { font-size: 30px; line-height: 1.35; }
.plan-name { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--tx-7); }

/* FAQ accordion (native <details>) */
.home-faq { background: var(--surface); border: 1px solid var(--bd-07); border-radius: 12px; padding: 18px 22px; }
.home-faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; font-family: var(--font-sans); font-weight: 600; font-size: 16.5px; color: var(--tx-2); }
.home-faq summary::-webkit-details-marker { display: none; }
.home-faq summary::after { content: "→"; color: var(--ac-text); transition: transform .2s; }
.home-faq[open] summary::after { transform: rotate(90deg); }
.home-faq p { margin: 12px 0 0; font-size: 14.5px; line-height: 1.65; color: var(--tx-7); }

/* Final call to action: dark block, whatever the theme */
.final-cta { --ac-text: #9590EF; background: #0C0E12; border: 1px solid rgba(255,255,255,0.09); border-radius: 20px; padding: 72px 32px; text-align: center; }
.final-cta h2 { font-weight: 600; font-size: 44px; letter-spacing: -0.02em; line-height: 1.1; color: #F7F8FA; max-width: 760px; margin: 0 auto 18px; }
.final-cta p { font-size: 16px; line-height: 1.6; color: #9AA0AB; max-width: 600px; margin: 0 auto 28px; }

@media (max-width: 780px) {
  .plans-grid { grid-template-columns: 1fr; }
  /* Keep the nav (EN/FR, theme, Get started) inside a phone screen */
  .nav-links { gap: 10px !important; }
  .nav-cta { padding: 7px 12px !important; font-size: 13px; white-space: nowrap; }
  .final-cta h2 { font-size: 32px; }
  .final-cta { padding: 48px 22px; }
}
/* Header logo: full lockup, square icon only on narrow phones */
.nav-brand-icon { display: none; }
@media (max-width: 440px) {
  .nav-brand { display: none; }
  .nav-brand-icon { display: block; }
}

/* ============================ Terms page ========================== */
/* Terms of Service page (AUD-237 skeleton, AUD-238 text) */
.terms-page { max-width: 820px; padding-block: 88px 72px; }
.terms-content { margin-top: 16px; font-size: 15.5px; line-height: 1.7; color: var(--tx-5); }
.terms-content h2 { font-size: 22px; font-weight: 600; letter-spacing: -0.01em; color: var(--tx-1); margin: 0 0 14px; }
.terms-content h3 { font-size: 16.5px; font-weight: 600; color: var(--tx-2); margin: 24px 0 10px; }
.terms-content p { margin: 0 0 14px; }
.terms-content ul { margin: 0 0 14px; padding-left: 22px; }
.terms-content li { margin-bottom: 6px; }
.terms-content strong { color: var(--tx-2); font-weight: 600; }
.terms-content a { color: var(--ac-text); overflow-wrap: anywhere; }
.terms-meta { color: var(--tx-7); }
.terms-notice { background: rgba(var(--ac-rgb),0.08); border: 1px solid rgba(var(--ac-rgb),0.25); border-radius: 10px; padding: 12px 16px; }
.terms-block, .terms-article, .terms-contact, .terms-toc { margin-top: 40px; scroll-margin-top: 80px; }
.terms-toc { background: var(--surface); border: 1px solid var(--bd-07); border-radius: 12px; padding: 20px 24px; }
.terms-toc h2 { font-size: 17px; }
.terms-toc ol { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 32px; }
.terms-toc li { break-inside: avoid; font-size: 14px; }
.terms-toc a { text-decoration: none; }
.terms-toc a:hover { text-decoration: underline; }
/* Tables scroll horizontally on small screens instead of overflowing */
.terms-table-wrap { overflow-x: auto; margin: 0 0 14px; border: 1px solid var(--bd-07); border-radius: 10px; }
.terms-table { width: 100%; border-collapse: collapse; font-size: 14.5px; min-width: 520px; }
.terms-table th, .terms-table td { text-align: left; vertical-align: top; padding: 10px 14px; border-bottom: 1px solid var(--bd-07); }
.terms-table tbody tr:last-child > * { border-bottom: none; }
.terms-table th { color: var(--tx-2); font-weight: 600; }
.terms-table thead th { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; }
.terms-table--kv th { width: 30%; background: var(--bd-02); }
.terms-note { font-size: 14px; color: var(--tx-7); }
.terms-article h2, .terms-contact h2 { border-top: 1px solid var(--bd-07); padding-top: 28px; }
@media (max-width: 640px) { .terms-toc ol { columns: 1; } .terms-table--kv { min-width: 0; } }
