@import url('https://fonts.googleapis.com/css2?family=Bungee&family=Manrope:wght@400;500;700;800&family=Playfair+Display:wght@600;700;800&display=swap');

:root {
  --paper: #f8f2e7;
  --ink: #17120f;
  --ink-soft: #5f554e;
  --card: #fffaf2;
  --line: #d8cdbf;
  --accent: #9a3223;
  --accent-dark: #6f2116;
  --hero: #efe1d2;
  --hero-mid: #e6c5ad;
  --hero-secondary: #d8ad97;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  font-family: 'Manrope', sans-serif;
  color: var(--ink);
  line-height: 1.7;
  background:
    radial-gradient(circle at 14% -8%, #efe2d2 0%, transparent 42%),
    radial-gradient(circle at 90% 0, #f2dfcf 0%, transparent 44%),
    var(--paper);
}

a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
}

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

p {
  margin-bottom: 0.8rem;
}

.social-icons {
  position: fixed;
  right: 12px;
  top: 108px;
  z-index: 60;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.social-icons a {
  display: block;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  background: #fff;
  border: 2px solid var(--ink);
  box-shadow: 4px 4px 0 var(--ink);
  transition: transform 0.2s ease;
}

.social-icons a:hover {
  transform: translate(-2px, -2px);
}

.social-icons img {
  width: 100%;
  height: 100%;
  padding: 8px;
  border-radius: 999px;
}

.header-scroll {
  width: min(1120px, 92vw);
  margin: 1.2rem auto 0;
  border: 4px solid var(--accent-dark);
  box-shadow: 10px 10px 0 rgba(111, 33, 22, 0.75);
  background: linear-gradient(120deg, var(--hero) 0%, var(--hero-mid) 54%, var(--hero-secondary) 100%);
  padding: clamp(0.9rem, 2.4vw, 1.6rem);
  display: grid;
  grid-template-columns: 120px 1fr;
  align-items: center;
  gap: 1rem;
}

.header-scroll img {
  width: 116px;
  height: 116px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--accent-dark);
  background: #fff;
}

.header-scroll h1 {
  font-family: 'Playfair Display', serif;
  font-weight: 800;
  font-size: clamp(1.9rem, 5.2vw, 3.8rem);
  line-height: 1.05;
  color: var(--accent-dark);
  text-shadow: 1px 1px 0 rgba(255, 250, 242, 0.55);
  text-wrap: balance;
}

header {
  width: min(1120px, 92vw);
  margin: 1.2rem auto 0;
  position: sticky;
  top: 0;
  z-index: 50;
}

.menu-principal {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 250, 242, 0.95);
  backdrop-filter: blur(7px);
  box-shadow: 0 10px 28px -22px rgba(22, 16, 11, 0.9);
}

.menu-principal > li {
  position: relative;
  flex: 1;
  min-width: 170px;
  text-align: center;
  border-right: 1px solid var(--line);
}

.menu-principal > li:last-child {
  border-right: 0;
}

.menu-principal > li > a {
  display: block;
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  padding: 0.78rem 0.6rem;
}

.menu-principal > li > a:hover {
  background: rgba(154, 50, 35, 0.1);
}

.sous-menu {
  display: none;
  list-style: none;
  position: absolute;
  left: 50%;
  top: calc(100% + 0.35rem);
  transform: translateX(-50%);
  min-width: 220px;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  background: #fffaf0;
  box-shadow: 0 18px 34px -24px rgba(22, 16, 11, 0.95);
}

.menu-principal li:hover .sous-menu {
  display: block;
}

.sous-menu a {
  display: block;
  color: var(--ink);
  font-weight: 700;
  padding: 0.6rem 0.75rem;
}

.sous-menu a:hover {
  background: rgba(154, 50, 35, 0.08);
}

body > nav:not(.menu-principal) {
  width: min(1120px, 92vw);
  margin: 1rem auto 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  padding: 1rem 1.1rem;
}

body > nav:not(.menu-principal) h2 {
  margin-bottom: 0.5rem;
}

body > nav:not(.menu-principal) ul {
  padding-left: 1.2rem;
}

main {
  width: min(1120px, 92vw);
  margin: 1rem auto 0;
  padding-bottom: 1.2rem;
}

.content-wrapper {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 1rem;
  align-items: start;
}

article,
aside,
main > section,
main > .detail-container,
main > h2,
main > p,
main > ul {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--card);
}

article,
aside,
main > section,
main > .detail-container {
  padding: 1.05rem;
  box-shadow: 0 14px 30px -26px rgba(22, 16, 11, 0.95);
}

section {
  display: grid;
  gap: 1rem;
}

.parcours-highlights {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin: 0.9rem 0 1.15rem;
  list-style: none;
  border-top: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  background: #fffaf2;
}

.parcours-highlights li {
  position: relative;
  display: grid;
  gap: 0.2rem;
  min-height: 118px;
  padding: 0.95rem 1rem 1rem;
  border-right: 1px solid var(--line);
}

.parcours-highlights li:last-child {
  border-right: 0;
}

.highlight-number {
  font-family: 'Bungee', sans-serif;
  font-size: 0.78rem;
  line-height: 1;
  color: var(--accent);
  letter-spacing: 0.04em;
}

.parcours-highlights strong {
  display: block;
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.25;
}

.parcours-highlights li > span:last-child {
  color: var(--ink-soft);
  font-size: 0.92rem;
  line-height: 1.35;
}

h2,
.detail-container h1 {
  font-family: 'Playfair Display', serif;
  line-height: 1.12;
  margin-bottom: 0.6rem;
  color: var(--ink);
}

h2 {
  font-size: clamp(1.4rem, 2.9vw, 2rem);
}

aside strong {
  display: block;
  margin-bottom: 0.75rem;
  font-family: 'Playfair Display', serif;
  font-size: 1.25rem;
}

aside nav ul {
  list-style: none;
}

aside nav li {
  border-bottom: 1px dashed var(--line);
  padding: 0.45rem 0;
}

aside nav li:last-child {
  border-bottom: 0;
}

.external-links-grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin-top: 0.2rem;
}

.external-links-grid li {
  display: flex;
  padding: 0;
  border-bottom: 0;
}

.external-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  width: 100%;
  min-height: 96px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fffdf9;
  color: var(--ink);
  font-weight: 800;
  box-shadow: none;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.external-tile:hover {
  border-color: var(--accent);
  background: #fbf3ea;
}

.external-tile img {
  width: 30px;
  height: 30px;
  object-fit: contain;
}

.external-tile span {
  font-size: 0.9rem;
  line-height: 1;
}

.tile-discord {
  grid-column: auto;
  min-height: 96px;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.8rem;
}

.parcours-table {
  overflow-x: auto;
}

caption {
  margin-bottom: 0.45rem;
}

th,
td {
  border: 1px solid var(--line);
  padding: 0.55rem;
  vertical-align: top;
  text-align: left;
}

th {
  background: #f2e6d9;
}

td img {
  max-width: 100%;
  height: auto;
  border-radius: 10px;
}

.galerie {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
}

.galerie figure {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  padding: 0.65rem;
}

.galerie img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 8px;
}

.galerie figcaption {
  margin-top: 0.45rem;
  text-align: center;
  font-weight: 700;
}

.video-container {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.video-item {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  padding: 0.65rem;
}

.video-wrapper video {
  width: 100%;
  border-radius: 10px;
}

.video-title {
  margin-top: 0.45rem;
  font-weight: 700;
}

form {
  display: grid;
  gap: 0.6rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  padding: 1rem;
}

label,
legend {
  font-weight: 700;
}

input,
select,
textarea,
button {
  font: inherit;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #cfbfaf;
  border-radius: 10px;
  background: #fffefb;
  padding: 0.55rem 0.6rem;
}

fieldset {
  border: 1px solid #cfbfaf;
  border-radius: 10px;
  padding: 0.65rem;
}

fieldset label {
  margin-right: 0.8rem;
}

button {
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 0.5rem 0.92rem;
  background: var(--hero);
  font-weight: 800;
  cursor: pointer;
}

button[type='reset'] {
  background: #f3dfd6;
}

button:hover {
  transform: translateY(-1px);
}

.detail-container {
  width: min(780px, 94vw);
  margin: 1.2rem auto;
  text-align: center;
}

.detail-container h1 {
  font-family: 'Bungee', sans-serif;
  font-size: clamp(2rem, 5vw, 3.2rem);
}

.detail-container figure {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  padding: 0.65rem;
  margin: 0.8rem 0;
}

.detail-container img {
  width: 100%;
  max-height: 62vh;
  object-fit: contain;
  border-radius: 8px;
}

.detail-description {
  color: var(--ink-soft);
}

.back-link a {
  display: inline-block;
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 0.42rem 0.88rem;
  background: var(--hero);
  color: var(--ink);
}

footer {
  width: min(1120px, 92vw);
  margin: 0 auto 1.5rem;
  border-top: 1px solid var(--line);
  padding-top: 0.95rem;
  text-align: center;
}

footer h2 {
  margin-bottom: 0.35rem;
}

footer p {
  color: #4c433e;
  text-align: center;
}

body > h2,
body > p,
body > ul,
body > a {
  width: min(820px, 92vw);
  margin-left: auto;
  margin-right: auto;
}

body > h2 {
  margin-top: 1.4rem;
  margin-bottom: 0.8rem;
}

body > p,
body > ul {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  padding: 0.8rem;
  margin-bottom: 0.7rem;
}

body > a {
  display: block;
  margin-bottom: 1.4rem;
}

@media (max-width: 980px) {
  .header-scroll {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .content-wrapper {
    grid-template-columns: 1fr;
  }

  .video-container,
  .galerie {
    grid-template-columns: 1fr;
  }

  .parcours-highlights {
    grid-template-columns: 1fr;
  }

  .parcours-highlights li {
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .parcours-highlights li:last-child {
    border-bottom: 0;
  }

  .menu-principal {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .menu-principal > li {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
}

@media (max-width: 640px) {
  .social-icons {
    top: auto;
    right: 50%;
    bottom: 0.8rem;
    transform: translateX(50%);
    flex-direction: row;
    background: rgba(248, 242, 231, 0.95);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 0.25rem;
  }

  .menu-principal {
    grid-template-columns: 1fr;
  }

  .header-scroll h1 {
    font-size: 2rem;
  }
}
