:root {
  --blue: #0876d8;
  --blue-dark: #03529d;
  --orange: #ff9a16;
  --yellow: #ffc727;
  --ink: #081526;
  --muted: #596579;
  --paper: #ffffff;
  --cream: #fff6d7;
  --soft-blue: #eaf5ff;
  --line: rgba(8, 21, 38, 0.12);
  --shadow: 0 18px 44px rgba(8, 21, 38, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: #fff8df;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.menu-home,
body.simple-page {
  min-height: 100vh;
  min-height: 100svh;
  overflow: hidden;
}

img {
  max-width: 100%;
}

a {
  color: inherit;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px clamp(18px, 4vw, 58px);
  background: rgba(255, 250, 231, 0.92);
  border-bottom: 1px solid rgba(8, 21, 38, 0.08);
  backdrop-filter: blur(16px);
}

.start-screen {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  overflow: hidden;
  isolation: isolate;
}

.start-bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.start-screen::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(255, 189, 38, 0.1), rgba(255, 206, 67, 0.08) 46%, rgba(255, 154, 22, 0.26)),
    linear-gradient(0deg, rgba(8, 21, 38, 0.04), rgba(8, 21, 38, 0));
}

.start-logo {
  position: absolute;
  left: clamp(24px, 4vw, 70px);
  top: clamp(18px, 3vw, 48px);
  z-index: 2;
}

.start-logo img {
  width: clamp(170px, 18vw, 270px);
  height: auto;
  display: block;
}

.start-menu {
  position: absolute;
  right: clamp(30px, 6vw, 88px);
  top: 50%;
  transform: translateY(-50%);
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 270px));
  gap: clamp(16px, 2vw, 28px);
}

.start-menu.four-buttons {
  grid-template-columns: repeat(2, minmax(220px, 300px));
}

.start-menu a {
  min-height: clamp(124px, 15vh, 172px);
  display: grid;
  place-items: center;
  align-content: center;
  padding: 16px;
  border-radius: 28px;
  color: #3028ff;
  background:
    radial-gradient(circle at 34% 22%, rgba(255, 255, 255, 0.56), transparent 36%),
    linear-gradient(145deg, #fff970, #ffd91f 68%, #ffbc13);
  border: 1px solid rgba(123, 93, 0, 0.16);
  box-shadow:
    -12px -12px 0 rgba(20, 20, 8, 0.72),
    12px 12px 0 rgba(177, 132, 0, 0.82),
    0 20px 34px rgba(8, 21, 38, 0.22);
  text-align: center;
  text-decoration: none;
  transition: transform 150ms ease, filter 150ms ease, box-shadow 150ms ease;
}

.start-menu a:hover,
.start-menu a:focus-visible {
  transform: translateY(-5px);
  filter: saturate(1.05) brightness(1.03);
  box-shadow:
    -10px -10px 0 rgba(20, 20, 8, 0.68),
    10px 10px 0 rgba(177, 132, 0, 0.78),
    0 24px 40px rgba(8, 21, 38, 0.28);
}

.start-menu span,
.start-menu strong {
  display: block;
  max-width: 230px;
  font-size: clamp(25px, 2.2vw, 38px);
  font-weight: 950;
  line-height: 1.08;
}

.start-menu strong:first-child {
  font-size: clamp(28px, 2.6vw, 42px);
}

.locked-screen {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 40px;
  padding: clamp(24px, 6vw, 86px);
  background: url("assets/fond-robotyp-jaune-orange-sans-image.png"), linear-gradient(135deg, #ffe66f, #ff9a16);
  background-size: cover;
  background-position: center;
}

.page-mascot {
  max-height: 560px;
  justify-self: center;
  object-fit: contain;
  filter: drop-shadow(0 22px 34px rgba(8, 21, 38, 0.16));
}

.login-panel {
  width: min(520px, 100%);
  display: grid;
  gap: 14px;
  justify-self: start;
}

.login-panel label {
  color: #123d89;
  font-weight: 950;
}

.login-panel input {
  min-height: 50px;
  border: 0;
  border-radius: 0;
  background: white;
  padding: 0 14px;
  font: inherit;
}

.login-panel button,
.login-button {
  justify-self: center;
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 26px;
  border: 1px solid rgba(123, 93, 0, 0.16);
  border-radius: 8px;
  color: #3028ff;
  background: linear-gradient(145deg, #fff970, #ffd91f 68%, #ffbc13);
  box-shadow: 5px 5px 0 rgba(177, 132, 0, 0.82);
  text-decoration: none;
  font-weight: 950;
  cursor: pointer;
}

.back-link.floating {
  position: absolute;
  left: clamp(20px, 3vw, 46px);
  top: clamp(20px, 3vw, 46px);
  z-index: 4;
  margin: 0;
  min-height: 40px;
  min-width: 120px;
  justify-content: center;
  border-radius: 8px;
  color: #3028ff;
  background: linear-gradient(145deg, #fff970, #ffd91f 68%, #ffbc13);
  box-shadow: 4px 4px 0 rgba(177, 132, 0, 0.82);
}

.hero-buttons {
  display: grid;
  grid-template-columns: repeat(2, minmax(150px, 230px));
  gap: 14px;
  margin-top: 28px;
}

.hero-buttons.parent-buttons {
  grid-template-columns: minmax(150px, 230px);
}

.panel-button {
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border: 1px solid rgba(123, 93, 0, 0.16);
  border-radius: 8px;
  color: #3028ff;
  background:
    radial-gradient(circle at 34% 20%, rgba(255, 255, 255, 0.54), transparent 38%),
    linear-gradient(145deg, #fff970, #ffd91f 68%, #ffbc13);
  box-shadow: 5px 5px 0 rgba(177, 132, 0, 0.82);
  text-align: center;
  text-decoration: none;
  font-size: 18px;
  font-weight: 950;
  transition: transform 150ms ease, filter 150ms ease;
}

.panel-button:hover,
.panel-button:focus-visible {
  transform: translateY(-3px);
  filter: brightness(1.04);
}

.logo-link img {
  display: block;
  width: 190px;
  height: 58px;
  object-fit: contain;
  object-position: left center;
}

nav {
  display: flex;
  align-items: center;
  gap: clamp(8px, 1.8vw, 22px);
  flex-wrap: wrap;
}

nav a {
  padding: 9px 10px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 900;
}

nav a.active,
nav a:hover {
  color: var(--blue-dark);
  background: rgba(8, 118, 216, 0.08);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 20px;
  font-size: clamp(44px, 6.2vw, 84px);
  line-height: 0.96;
}

h2 {
  margin-bottom: 16px;
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.02;
}

h3 {
  margin-bottom: 8px;
  font-size: 24px;
  line-height: 1.08;
}

p {
  color: var(--muted);
  line-height: 1.55;
}

.eyebrow {
  margin-bottom: 10px;
  color: var(--blue);
  font-size: 14px;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

.home-hero {
  position: relative;
  min-height: calc(100vh - 86px);
  display: grid;
  align-items: center;
  overflow: hidden;
  padding: 76px clamp(18px, 5vw, 72px);
}

.home-hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.home-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(255, 199, 39, 0.98), rgba(255, 190, 43, 0.76) 42%, rgba(255, 154, 22, 0.12) 72%),
    linear-gradient(0deg, rgba(8, 21, 38, 0.12), rgba(8, 21, 38, 0));
}

.home-hero-copy {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.home-hero-copy > p:not(.eyebrow),
.page-hero p,
.course-copy p {
  max-width: 680px;
  font-size: clamp(19px, 2.1vw, 25px);
}

.page-section {
  padding: 70px clamp(18px, 5vw, 72px);
}

.menu-stage {
  background: white;
}

.section-title.center {
  max-width: 820px;
  margin: 0 auto 28px;
  text-align: center;
}

.icon-menu {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: clamp(12px, 2vw, 22px);
}

.icon-link {
  display: grid;
  justify-items: center;
  align-content: start;
  min-height: 270px;
  padding: 20px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: linear-gradient(180deg, #ffffff, #fff7dd);
  text-align: center;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.icon-link:hover,
.icon-link:focus-visible {
  transform: translateY(-5px);
  border-color: rgba(8, 118, 216, 0.42);
  background: linear-gradient(180deg, #ffffff, #eaf5ff);
}

.icon-disc {
  width: 124px;
  height: 124px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 24%, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.24) 42%, rgba(255, 154, 22, 0.22)),
    linear-gradient(145deg, #fff6d7, #ffc727);
  border: 1px solid rgba(8, 21, 38, 0.12);
}

.icon-disc img {
  width: 108px;
  height: 108px;
  object-fit: contain;
  filter: drop-shadow(0 12px 18px rgba(8, 21, 38, 0.12));
}

.icon-link strong {
  display: block;
  max-width: 220px;
  font-size: 21px;
  line-height: 1.08;
}

.icon-link small {
  display: block;
  max-width: 220px;
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.35;
}

.split,
.page-hero,
.course-page {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 430px);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
}

.split {
  background: white;
}

.split p {
  max-width: 720px;
  font-size: 19px;
}

.guide-card,
.callout {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 18px;
  align-items: center;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft-blue);
  box-shadow: var(--shadow);
}

.guide-card img,
.callout img {
  width: 150px;
  height: 150px;
  object-fit: contain;
}

.guide-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 24px;
}

.guide-card span {
  color: var(--muted);
  line-height: 1.45;
}

.quick-access {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  background: var(--cream);
}

.quick-access.two-access {
  grid-template-columns: repeat(2, 1fr);
}

.access-card,
.level-card,
.steps-grid article,
.program-grid article,
.two-columns article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.access-card {
  min-height: 320px;
  display: grid;
  align-content: end;
  padding: 24px;
  overflow: hidden;
  text-decoration: none;
  box-shadow: var(--shadow);
}

.access-card img {
  height: 180px;
  justify-self: center;
  object-fit: contain;
  transition: transform 180ms ease;
}

.access-card:hover img,
.level-card:hover img {
  transform: translateY(-6px);
}

.access-card span,
.level-card span {
  color: var(--blue);
  font-size: 13px;
  font-weight: 950;
  text-transform: uppercase;
}

.access-card strong {
  display: block;
  margin-top: 8px;
  font-size: 25px;
  line-height: 1.08;
}

.page-hero,
.course-page {
  padding: 70px clamp(18px, 5vw, 72px);
  background:
    radial-gradient(circle at 78% 18%, rgba(255, 255, 255, 0.78), transparent 24%),
    linear-gradient(135deg, #ffe66f, #ffbd35 52%, #ff9417);
}

.parent-hero img,
.training-hero img,
.course-page img {
  max-height: 460px;
  object-fit: contain;
  justify-self: center;
  filter: drop-shadow(0 18px 30px rgba(8, 21, 38, 0.16));
}

.two-columns,
.program-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  background: white;
}

.program-grid {
  grid-template-columns: repeat(3, 1fr);
}

.two-columns article,
.program-grid article {
  padding: 28px;
}

.parent-steps {
  background: #fff8df;
}

.section-title {
  max-width: 760px;
  margin-bottom: 26px;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.steps-grid article {
  padding: 24px;
}

.steps-grid span {
  display: inline-grid;
  width: 42px;
  height: 42px;
  place-items: center;
  margin-bottom: 18px;
  border-radius: 8px;
  color: white;
  background: var(--blue);
  font-weight: 950;
}

.callout {
  grid-template-columns: 180px 1fr;
  margin: 0 clamp(18px, 5vw, 72px) 70px;
  padding: 30px;
  background: #091727;
  color: white;
}

.component-library {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  padding: 70px clamp(18px, 5vw, 72px);
  background: white;
}

.component-library article {
  min-height: 380px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffaf0;
  text-align: center;
  box-shadow: var(--shadow);
}

.component-library img {
  width: 100%;
  height: 220px;
  object-fit: contain;
}

.component-library h2 {
  margin: 8px 0;
  font-size: 28px;
}

.callout p {
  max-width: 860px;
  color: rgba(255, 255, 255, 0.78);
}

.level-chooser {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  padding: 70px clamp(18px, 5vw, 72px);
  background: white;
}

.level-card {
  display: grid;
  grid-template-rows: 250px auto auto auto;
  min-height: 560px;
  padding: 24px;
  text-decoration: none;
  box-shadow: var(--shadow);
}

.level-card img {
  width: 100%;
  height: 250px;
  object-fit: contain;
  transition: transform 180ms ease;
}

.level-card h2 {
  margin: 10px 0 12px;
  font-size: clamp(28px, 3vw, 42px);
}

.level-card.intro {
  background: linear-gradient(180deg, #ffffff, #eaf5ff);
}

.level-card.base {
  background: linear-gradient(180deg, #ffffff, #fff1c0);
}

.level-card.advanced {
  background: linear-gradient(180deg, #ffffff, #ffe1cb);
}

.mini-home-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  background: white;
}

.mini-home-grid a {
  min-height: 360px;
  display: grid;
  align-content: end;
  justify-items: start;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: linear-gradient(180deg, #ffffff, #fff7dd);
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 160ms ease, border-color 160ms ease;
}

.mini-home-grid a:hover,
.mini-home-grid a:focus-visible {
  transform: translateY(-5px);
  border-color: rgba(8, 118, 216, 0.42);
}

.mini-home-grid img {
  width: 100%;
  height: 210px;
  object-fit: contain;
  justify-self: center;
  margin-bottom: 18px;
}

.mini-home-grid strong {
  display: block;
  margin-bottom: 8px;
  font-size: 28px;
  line-height: 1.05;
}

.mini-home-grid span {
  color: var(--muted);
  line-height: 1.4;
}

.course-copy {
  max-width: 760px;
}

.back-link {
  display: inline-flex;
  margin-bottom: 24px;
  color: var(--blue-dark);
  text-decoration: none;
  font-weight: 950;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 28px clamp(18px, 5vw, 72px);
  color: var(--muted);
  background: white;
  font-weight: 800;
}

.site-footer img {
  width: 170px;
  height: 50px;
  object-fit: contain;
  object-position: left center;
}

@media (max-width: 980px) {
  .topbar,
  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .home-hero {
    min-height: 760px;
  }

  .home-hero::after {
    background: linear-gradient(180deg, rgba(255, 199, 39, 0.96), rgba(255, 169, 30, 0.42));
  }

  .split,
  .page-hero,
  .course-page,
  .quick-access,
  .icon-menu,
  .level-chooser,
  .mini-home-grid,
  .two-columns,
  .program-grid,
  .steps-grid,
  .component-library {
    grid-template-columns: 1fr 1fr;
  }

  .page-hero,
  .course-page {
    grid-template-columns: 1fr;
  }

  .level-card {
    min-height: auto;
  }

  .start-menu {
    right: 24px;
    grid-template-columns: repeat(2, minmax(150px, 1fr));
    width: min(560px, calc(100vw - 48px));
  }

  .start-menu a {
    min-height: 116px;
  }

  .locked-screen {
    grid-template-columns: 1fr;
  }

  .login-panel {
    justify-self: center;
  }
}

@media (max-width: 660px) {
  .logo-link img {
    width: 160px;
  }

  nav a {
    padding-left: 6px;
    padding-right: 6px;
    font-size: 14px;
  }

  h1 {
    font-size: 42px;
  }

  .split,
  .quick-access,
  .quick-access.two-access,
  .icon-menu,
  .level-chooser,
  .mini-home-grid,
  .two-columns,
  .program-grid,
  .steps-grid,
  .component-library,
  .guide-card,
  .callout {
    grid-template-columns: 1fr;
  }

  .parent-hero img,
  .training-hero img,
  .course-page img {
    max-height: 320px;
  }

  .level-card {
    grid-template-rows: auto;
  }

  .level-card img {
    height: 210px;
  }

  .callout {
    margin-left: 18px;
    margin-right: 18px;
  }

  body.menu-home,
  body.simple-page {
    overflow: auto;
  }

  .start-screen {
    min-height: auto;
    padding: 110px 18px 38px;
  }

  .start-bg {
    object-position: 32% center;
  }

  .start-logo {
    left: 18px;
    top: 16px;
  }

  .start-menu {
    position: relative;
    inset: auto;
    width: 100%;
    grid-template-columns: 1fr;
    transform: none;
  }

  .start-menu a {
    min-height: 102px;
    border-radius: 18px;
    box-shadow:
      -7px -7px 0 rgba(20, 20, 8, 0.66),
      7px 7px 0 rgba(177, 132, 0, 0.8),
      0 16px 28px rgba(8, 21, 38, 0.18);
  }

  .start-menu span,
  .start-menu strong,
  .start-menu strong:first-child {
    font-size: 26px;
  }

  .page-mascot {
    max-height: 320px;
  }

  .hero-buttons,
  .hero-buttons.parent-buttons {
    grid-template-columns: 1fr;
  }
}

.start-menu.four-buttons {
  grid-template-columns: repeat(2, minmax(320px, 430px));
}

.start-menu .designed-home-button {
  min-height: clamp(128px, 16vh, 182px);
  grid-template-columns: 108px 1fr;
  justify-items: start;
  gap: 22px;
  padding: 22px 28px;
  border: 6px solid #0c49bf;
  border-radius: 28px;
  color: #113bb2;
  background: linear-gradient(180deg, #ffffff, #fffdf7);
  box-shadow:
    0 13px 0 #e5a700,
    0 18px 0 rgba(8, 21, 38, 0.52),
    0 24px 34px rgba(8, 21, 38, 0.22);
}

.home-icon {
  width: 88px;
  height: 88px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffd23a;
  background: linear-gradient(145deg, #145ad4, #042f9f);
  font-size: 40px;
  font-weight: 950;
  box-shadow: inset 0 6px 12px rgba(255, 255, 255, 0.2);
}

.start-menu .designed-home-button strong {
  max-width: none;
  color: #113bb2;
  font-size: clamp(30px, 2.7vw, 48px);
  line-height: 1.03;
  text-align: left;
}

.login-role {
  margin: 0 0 6px;
  color: #123d89;
  font-size: 24px;
  font-weight: 950;
}

.login-panel input {
  border-radius: 8px;
  box-shadow: inset 0 0 0 2px rgba(8, 21, 38, 0.08);
}

.login-message {
  min-height: 24px;
  margin: 0;
  color: #9a1c1c;
  font-weight: 850;
}

.panel-button {
  cursor: pointer;
}

.account-board {
  display: grid;
  gap: 18px;
  background: white;
}

.account-summary {
  display: grid;
  gap: 8px;
  max-width: 820px;
}

.account-summary strong {
  font-size: 28px;
}

.course-unlock-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.course-tile {
  display: grid;
  gap: 12px;
  align-content: start;
  min-height: 250px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffaf0;
  box-shadow: var(--shadow);
}

.course-tile.locked {
  opacity: 0.72;
}

.course-status {
  display: inline-flex;
  justify-self: start;
  min-height: 34px;
  align-items: center;
  padding: 0 12px;
  border-radius: 999px;
  color: white;
  background: #123d89;
  font-size: 13px;
  font-weight: 950;
}

.course-status.locked {
  background: #8b2a2a;
}

.course-tile h2 {
  margin: 0;
  font-size: 28px;
}

.course-tile p {
  margin: 0;
}

.course-tile a,
.course-tile button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: start;
  padding: 0 16px;
  border: 0;
  border-radius: 8px;
  color: white;
  background: var(--blue-dark);
  text-decoration: none;
  font: inherit;
  font-weight: 950;
  cursor: pointer;
}

.course-tile button.lock-action {
  background: #8b2a2a;
}

@media (max-width: 980px) {
  .start-menu.four-buttons {
    width: min(820px, calc(100vw - 48px));
  }

  .start-menu .designed-home-button {
    grid-template-columns: 82px 1fr;
    gap: 14px;
    padding: 18px;
  }

  .home-icon {
    width: 68px;
    height: 68px;
    font-size: 31px;
  }

  .course-unlock-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 660px) {
  .start-menu.four-buttons {
    grid-template-columns: 1fr;
  }

  .start-menu .designed-home-button {
    grid-template-columns: 66px 1fr;
    border-width: 4px;
  }

  .home-icon {
    width: 54px;
    height: 54px;
    font-size: 24px;
  }

  .start-menu .designed-home-button strong {
    font-size: 25px;
  }
}
