:root {
  --bg: #162835;
  --header: #0f212e;
  --footer: #071d2a;
  --surface: #213743;
  --surface-2: #213743;
  --text: #ffffff;
  --muted: #b1bad3;
  --accent: #1475e1;
  --accent-hover: #1a86f5;
  --green: #1fbd5a;
  --red: #ed4163;
  --line: #2f4553;
  --radius: 16px;
  --max: 1120px;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--muted);
  background: var(--bg);
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--accent); }
a:hover { color: var(--accent-hover); }

h1, h2, h3 { color: var(--text); line-height: 1.3; margin: 0 0 .6em; font-weight: 600; }
h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); }
h2::after {
  content: "";
  display: block;
  width: 88px;
  height: 2px;
  margin-top: 8px;
  background: var(--accent);
}
h3 { font-size: clamp(1.05rem, 2.4vw, 1.25rem); }
p { margin: 0 0 1em; }

.wrap {
  width: min(100% - 32px, var(--max));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--header);
  border-bottom: 1px solid #9aa7bd;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  flex-wrap: wrap;
}
/* Header logo: its own class, so the provider tile style .brand does not apply to it */
.site-logo { display: block; flex-shrink: 0; }
.site-logo img { height: 36px; width: auto; }
.menu ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.menu-item {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 8px;
  color: var(--text);
  font-size: .95rem;
  cursor: pointer;
  text-decoration: none;
}
a.menu-item:hover { color: var(--text); background: var(--surface); }

main { padding: 24px 0 56px; }

main > * + * { margin-top: 48px; }

/* Hero */
.hero {
  display: grid;
  gap: 24px;
  align-items: center;
}
.hero-title { margin-bottom: .5em; }
.lead { font-size: 1rem; color: var(--muted); }
.hero-img {
  border-radius: 12px;
  width: 100%;
  object-fit: cover;
}
.hero-text > * + * { margin-top: 20px; }
.bonus-card {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  padding: 16px 18px;
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  font-weight: 500;
  text-decoration: none;
  font-size: 1.05rem;
  cursor: default;
}
.bonus-card::before {
  content: "";
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  background: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231475e1' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='8' width='18' height='4' rx='1'/%3E%3Cpath d='M12 8v13M19 12v9H5v-9'/%3E%3Cpath d='M7.5 8a2.5 2.5 0 0 1 0-5C11 3 12 8 12 8s1-5 4.5-5a2.5 2.5 0 0 1 0 5'/%3E%3C/svg%3E");
}
.bonus-label { color: var(--text); }
.hero-buttons {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 20px;
}
.hero-buttons .btn { margin-top: 0; }
/* Secondary hero button: same blue as the rest of the buttons */
.btn-alt,
.btn-alt:hover { background: var(--accent); color: #fff; }
.btn-alt:hover { background: var(--accent-hover); }

/* Quick links */
.quick-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  display: inline-block;
  padding: 8px 16px;
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  font-size: .95rem;
}
.chip:hover { background: var(--accent); color: #fff; }

/* Prose and text blocks */
.prose { color: var(--muted); }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li { margin-bottom: .35em; }
.prose table,
table {
  display: block;
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  border-collapse: separate;
  border-spacing: 0;
  margin: 1em 0;
  font-size: .95rem;
}
th, td {
  padding: 12px 16px;
  border: 0;
  border-bottom: 6px solid var(--bg);
  background-clip: padding-box;
  text-align: left;
  vertical-align: middle;
}
td { background: var(--surface); color: var(--muted); font-weight: 500; }
td:first-child { border-radius: 8px 0 0 8px; }
td:last-child { border-radius: 0 8px 8px 0; }
th { background: var(--accent); color: #fff; font-weight: 700; }
th:first-child { border-radius: 8px 0 0 8px; }
th:last-child { border-radius: 0 8px 8px 0; }

.text-block,
.review,
.howto,
.cards-section,
.faq,
.providers,
.games {
  background: transparent;
  border: 0;
  padding: 0;
}
.blk-section > * + * { margin-top: 28px; }
.text-block h3 { margin-top: 24px; }
.text-block .text-block,
.text-block .blk-section { margin-top: 16px; }
.text-block > .btn, .review > .btn { margin-top: 12px; }

/* Pros and cons */
.pros-cons {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  margin-top: 1em;
}
.pros-cons ul {
  list-style: none;
  margin: 0;
  padding: 16px 18px;
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  font-size: .95rem;
}
.pros-cons ul::before {
  display: block;
  margin-bottom: 14px;
  padding: 10px;
  border: 1px solid var(--green);
  border-radius: 12px;
  text-align: center;
  font-size: 1rem;
  color: var(--text);
}
.pros::before { content: "POUR"; }
.cons::before { content: "CONS"; border-color: var(--red) !important; }
.pros-cons li {
  position: relative;
  padding-left: 28px;
  margin-bottom: .6em;
}
.pros li::before,
.cons li::before {
  position: absolute;
  left: 0;
  font-weight: 700;
}
.pros li::before { content: "✓"; color: var(--green); }
.cons li::before { content: "✕"; color: var(--red); }

/* Steps */
.steps {
  list-style: none;
  counter-reset: step;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 16px;
}
.step {
  counter-increment: step;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, .85);
}
.step::before {
  content: "Étape " counter(step);
  align-self: flex-start;
  padding: 8px 16px;
  border-radius: 6px;
  background: #ffeb99;
  color: #665200;
  font-size: .875rem;
  font-weight: 600;
  line-height: 1.3;
}
/* Order inside a step: badge, title, text, button, then picture */
.step-body { display: contents; }
.step h3 { margin: 0; }
.step .prose { margin: 0; }
.step .btn { margin-top: 0; }
.step-img { order: 99; border-radius: 8px; width: 100%; }

/* Buttons */
.btn {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 12px 24px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 500;
  text-align: center;
  text-decoration: none;
}
.btn:hover { background: var(--accent-hover); color: #fff; }
@media (min-width: 600px) {
  .btn { display: inline-block; width: auto; }
  .hero-buttons { flex-direction: row; flex-wrap: wrap; }
}

/* Lobby cards */
.card-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
  margin-top: 1.5em;
}
.card {
  display: grid;
  grid-template-columns: 82px 1fr;
  align-items: center;
  gap: 12px 16px;
  background: var(--surface);
  border-radius: var(--radius);
  padding: 16px;
}
.card-img {
  grid-column: 1;
  width: 82px;
  height: 58px;
  border-radius: 10px;
  object-fit: cover;
}
.card h3 { grid-column: 2; margin: 0; font-size: 1.05rem; }
.card .prose { grid-column: 1 / -1; font-size: .95rem; }
.card .prose ul { list-style: none; padding: 0; }
.card .prose li {
  position: relative;
  min-height: 24px;
  padding-left: 32px;
  margin-bottom: .8em;
  color: var(--muted);
}
.card .prose li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 1px;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
}
@media (min-width: 700px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); align-items: start; }
}
@media (min-width: 1000px) {
  .card-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Providers: horizontal scroll row */
.brand-grid {
  list-style: none;
  margin: 1.2em 0 0;
  padding: 0 0 12px;
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
}
.brand {
  flex: 0 0 150px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 20px 14px;
  border-radius: 12px;
  background: var(--surface);
  text-align: center;
  color: var(--text);
  font-weight: 600;
  scroll-snap-align: start;
}
.brand img {
  height: 40px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
}

/* Placeholders for dynamic modules */
.placeholder {
  margin-top: 1em;
  padding: 24px;
  border: 2px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  text-align: center;
}
.img-missing {
  display: grid;
  place-items: center;
  min-height: 180px;
  border: 2px dashed var(--line);
  border-radius: 10px;
  color: var(--muted);
}

/* FAQ */
.faq-item {
  border-top: 1px solid var(--line);
  padding: 16px 0;
}
.faq-item:last-of-type { border-bottom: 1px solid var(--line); }
.faq-item summary {
  cursor: pointer;
  color: var(--text);
  font-weight: 600;
  font-size: 1.02rem;
  list-style: none;
  padding-right: 8px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  float: right;
  margin-left: 12px;
  color: var(--accent);
  font-size: 1.4rem;
  line-height: 1;
}
.faq-item[open] summary::after { content: "–"; }
.faq-a { margin-top: 12px; color: var(--muted); }

/* Wide screens */
@media (min-width: 900px) {
  .hero { grid-template-columns: 1.1fr .9fr; gap: 40px; }
}

/* Header: row of links and buttons */
.btn-blue {
  display: inline-block;
  padding: 9px 18px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 500;
  font-size: .95rem;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
}
.btn-blue:hover { background: var(--accent-hover); color: #fff; }
.drawer {
  display: flex;
  flex: 1;
  align-items: center;
  gap: 16px;
}
.header-actions {
  display: flex;
  flex-shrink: 0;
  gap: 10px;
  flex-wrap: wrap;
}
.menu-toggle { display: none; }
.drawer-head { display: none; }
.drawer-overlay { display: none; }

/* Mobile: menu opens as a side drawer */
@media (max-width: 899px) {
  .menu-toggle {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    order: 2;
    margin-left: 0;
    padding: 10px;
    background: transparent;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
  }
  .menu-toggle span {
    display: block;
    height: 2px;
    border-radius: 2px;
    background: var(--text);
  }
  .header-inner { gap: 8px; }
  .site-logo img { height: 30px; }
  .header-actions {
    order: 1;
    flex-wrap: nowrap;
    gap: 6px;
    margin-left: auto;
  }
  .header-actions .btn-blue {
    padding: 8px 8px;
    font-size: .75rem;
  }
  .drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    width: min(86vw, 340px);
    height: 100vh;
    height: 100dvh;
    flex: none;
    flex-direction: column;
    align-items: stretch;
    gap: 20px;
    padding: 16px 20px 28px;
    overflow-y: auto;
    background: var(--header);
    border-left: 1px solid var(--line);
    box-shadow: -12px 0 32px rgba(0, 0, 0, .4);
    transform: translateX(100%);
    visibility: hidden;
    transition: transform .25s ease, visibility .25s;
  }
  .drawer.is-open {
    transform: none;
    visibility: visible;
  }
  .drawer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  .drawer-title { font-weight: 700; font-size: 1.1rem; color: var(--text); }
  .drawer-close {
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 8px;
    background: var(--surface);
    color: var(--text);
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
  }
  .menu ul {
    flex-direction: column;
    gap: 4px;
  }
  .menu-item {
    display: block;
    padding: 12px 14px;
    border-radius: 8px;
    font-size: 1.02rem;
  }
  .drawer-overlay.is-open {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 20;
    background: rgba(5, 8, 14, .65);
  }
  body.menu-open { overflow: hidden; }
}

/* Game Center: popular games, horizontal row */
.game-grid {
  list-style: none;
  margin: 1.2em 0 0;
  padding: 0 0 12px;
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
}
.game-card {
  flex: 0 0 150px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  scroll-snap-align: start;
}
.game-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 12px;
  background: var(--surface);
}
.game-card h3 { font-size: .9rem; font-weight: 600; margin: 0; }
.game-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-top: auto;
}
.btn-demo,
.btn-play {
  padding: 7px 8px;
  border-radius: 8px;
  font-size: .85rem;
  font-weight: 500;
  text-align: center;
  text-decoration: none;
}
.btn-demo {
  background: transparent;
  border: 1px solid var(--accent);
  color: #fff;
}
.btn-demo:hover { background: var(--surface); color: #fff; }
.btn-play,
.btn-play:hover { background: var(--accent); color: #fff; border: 1px solid var(--accent); }
.btn-play:hover { background: var(--accent-hover); }
@media (min-width: 900px) {
  .game-grid {
    display: grid;
    overflow: visible;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 16px;
  }
  .game-card { flex: none; }
  .brand-grid { flex-wrap: wrap; overflow: visible; }
}

/* Footer */
.site-footer {
  margin-top: 56px;
  padding: 36px 0 28px;
  background: var(--footer);
  color: #c9d3e6;
  font-size: .95rem;
}
.footer-top {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: start;
}
.footer-brand img { height: 44px; width: auto; }
.age-badge { margin: 16px 0 12px; }
.payment-icons {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 260px;
}
.payment-icons li { display: flex; align-items: center; }
.payment-icons svg { display: block; height: 30px; width: auto; }
.footer-col h3 {
  margin: 0 0 12px;
  font-size: 1.1rem;
  font-weight: 500;
  color: #fff;
}
.footer-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.footer-col a {
  color: #a9bbd6;
  text-decoration: none;
}
.footer-col a:hover { color: #fff; }
.footer-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 180px;
}
.footer-actions .btn-blue { text-align: center; }
.footer-providers {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 22px 30px;
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid #2a3a50;
}
.footer-providers img {
  height: 26px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
}
.footer-bottom { margin-top: 22px; }
.footer-bottom p { margin: 0 0 4px; color: #fff; }

@media (min-width: 600px) {
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (min-width: 900px) {
  .footer-top { grid-template-columns: 1.2fr 1fr 1fr auto; }
  .footer-brand { grid-column: auto; }
}

/* Back to top */
.to-top {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 15;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  width: 48px;
  height: 48px;
  padding: 0;
  border-radius: 8px;
  border: 0;
  background: var(--surface);
  color: #fff;
  box-shadow: 0 6px 20px rgba(0, 0, 0, .35);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity .25s ease, transform .25s ease, visibility .25s, background .2s;
}
.to-top svg { width: 18px; height: 18px; }
.to-top::after { content: "TOP"; font-size: 10px; font-weight: 500; line-height: 1; }
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--accent); }
.to-top:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
