/* Couleurs et réglages de base */
:root {
  color-scheme: dark;
  --background: #101713;
  --surface: #171f1a;
  --surface-light: #1d2821;
  --text: #eef1e8;
  --muted: #aab4aa;
  --line: #344239;
  --grass: #91c45b;
  --grass-light: #b5da7c;
  --font-mono: "Courier New", monospace;
  --font-body: "Segoe UI", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(ellipse at 78% 8%, #1c3022 0, transparent 32%),
    var(--background);
  color: var(--text);
  font-family: var(--font-body);
}

a {
  color: inherit;
}

.page {
  width: min(1120px, calc(100% - 48px));
  margin-inline: auto;
}

/* En-tête et navigation */
.site-header {
  position: relative;
  display: flex;
  min-height: 76px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid rgb(255 255 255 / 10%);
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-decoration: none;
}

.brand__name {
  color: var(--text);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 2px;
}

.brand__studio {
  color: var(--grass-light);
  font: 10px var(--font-mono);
  letter-spacing: 1.5px;
}

.site-nav {
  display: flex;
  gap: 26px;
}

.site-nav a {
  color: #c6d0c4;
  font-size: 13px;
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--grass-light);
}

.development-status {
  color: var(--grass-light);
  font: 10px var(--font-mono);
  letter-spacing: .5px;
  text-transform: uppercase;
}

.development-status::before {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--grass);
  box-shadow: 0 0 10px rgb(145 196 91 / 55%);
  content: "";
}

.menu-toggle {
  display: none;
}

/* Grande présentation */
.hero {
  display: grid;
  min-height: 560px;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 44px;
  padding-block: 48px;
}

.eyebrow,
.project-card__type {
  color: var(--grass-light);
  font: 600 10px var(--font-mono);
  letter-spacing: 1px;
  text-transform: uppercase;
}

.eyebrow::before {
  display: inline-block;
  width: 18px;
  height: 2px;
  margin-right: 9px;
  background: var(--grass);
  vertical-align: middle;
  content: "";
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 20px;
  font-size: clamp(58px, 7vw, 82px);
  font-weight: 700;
  letter-spacing: -5px;
  line-height: .96;
}

h1 span {
  color: #9fd36a;
}

.intro,
.sculkcore__intro > p:not(.eyebrow) {
  max-width: 500px;
  color: #bac5ba;
  font-size: 15px;
  line-height: 1.75;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: 4px;
  padding: 12px 16px;
  font-size: 12px;
  font-weight: 650;
  text-decoration: none;
  transition: background-color .2s, transform .2s;
}

.button:hover {
  transform: translateY(-2px);
}

.button--primary {
  background: var(--grass);
  color: #132014;
}

.button--primary:hover {
  background: var(--grass-light);
}

.button--secondary {
  border-color: #455447;
  background: var(--surface);
  color: var(--text);
}

.button--secondary:hover {
  border-color: var(--grass);
}

/* Décor Minecraft en blocs */
.world-card {
  position: relative;
  display: grid;
  min-height: 390px;
  place-items: center;
  overflow: hidden;
  border: 1px solid #46594a;
  border-radius: 5px;
  background:
    linear-gradient(
      to bottom,
      #1a2c3a 0%,
      #293b48 53%,
      #516446 53%,
      #34472f 74%,
      #1a261d 74%
    );
  box-shadow: 0 22px 55px rgb(0 0 0 / 25%);
}

.world-card::before {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 43%;
  background:
    linear-gradient(135deg, transparent 0 19%, #52633c 19% 38%, transparent 38%),
    linear-gradient(45deg, #273b2a 0 24%, transparent 24%),
    linear-gradient(160deg, transparent 0 35%, #273927 35% 68%, transparent 68%);
  content: "";
  opacity: .85;
}

.world-card::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 25%;
  border-top: 6px solid #719342;
  background: repeating-linear-gradient(0deg, #403728 0 15px, #55452f 15px 30px);
  content: "";
}

.world-card__label,
.world-card__footer {
  position: absolute;
  z-index: 2;
  font: 10px var(--font-mono);
  text-shadow: 0 1px 5px #101510;
}

.world-card__label {
  top: 16px;
  left: 16px;
}

.world-card__footer {
  right: 15px;
  bottom: 14px;
  left: 15px;
  display: flex;
  justify-content: space-between;
}

.world-card__status {
  color: var(--grass-light);
}

.grass-block {
  position: relative;
  z-index: 1;
  width: 112px;
  height: 112px;
  transform: translateY(13px);
  border: 6px solid #29402d;
  background: #5d9140;
  box-shadow:
    inset 10px 8px #93ba55,
    inset -12px -11px #3d6837,
    8px 13px 28px rgb(16 23 18 / 65%);
  image-rendering: pixelated;
}

.grass-block::before {
  position: absolute;
  top: -28px;
  left: -6px;
  width: 100%;
  height: 22px;
  border: 6px solid #29402c;
  background: #99c55b;
  box-shadow: inset 10px 4px #b0d96b;
  content: "";
}

.grass-block::after {
  position: absolute;
  top: -6px;
  right: -28px;
  width: 22px;
  height: 100%;
  border: 6px solid #263d2d;
  background: #426f37;
  content: "";
}

/* Résumé des projets */
.project-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-block: 1px solid var(--line);
  padding-block: 20px;
}

.project-stats > div {
  display: flex;
  flex-direction: column;
  gap: 6px;
  border-left: 1px solid var(--line);
  padding-left: 18px;
}

.project-stats > div:first-child {
  border-left: 0;
  padding-left: 0;
}

.project-stats strong {
  font-size: 16px;
}

.project-stats span {
  color: #a8c986;
  font: 9px var(--font-mono);
  letter-spacing: 1px;
}

/* Sections et cartes de projets */
.content-section {
  padding-block: 76px;
}

.content-section--compact {
  padding-top: 0;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 32px;
  margin-top: 12px;
}

.section-heading h2,
.sculkcore h2,
.closing-card h2 {
  margin-bottom: 0;
  font-size: 34px;
  letter-spacing: -1.4px;
}

.section-heading > p {
  max-width: 440px;
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 28px;
}

.project-card {
  position: relative;
  min-height: 215px;
  border: 1px solid #35443a;
  border-radius: 5px;
  padding: 22px;
  background: linear-gradient(150deg, #1b241e, #151d18);
  box-shadow: 0 10px 25px rgb(0 0 0 / 12%);
  transition: border-color .2s, transform .2s;
}

.project-card:hover {
  transform: translateY(-3px);
  border-color: #71984e;
}

.project-card::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--grass) 0 28%, #5c743f 28% 36%, transparent 36%);
  content: "";
}

.project-card h3 {
  margin: 22px 0 9px;
  font-size: 19px;
}

.project-card p {
  margin-bottom: 24px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.project-card__category {
  color: var(--grass-light);
  font: 9px var(--font-mono);
  letter-spacing: .5px;
  text-decoration: none;
}

/* SculkCore et ses commandes */
.sculkcore {
  display: grid;
  grid-template-columns: .8fr 1.2fr;
  align-items: start;
  gap: 36px;
}

.sculkcore h2 {
  margin: 12px 0 18px;
}

.sculkcore__intro > p:not(.eyebrow) {
  margin-bottom: 14px;
}

.command-window {
  border: 1px solid #3d4b40;
  border-radius: 5px;
  padding: 20px;
  background: #141b17;
  box-shadow: 0 12px 28px rgb(0 0 0 / 12%);
}

.command-window__title {
  margin-bottom: 16px;
  color: var(--muted);
  font: 9px var(--font-mono);
  letter-spacing: 1px;
}

.command-window pre {
  overflow-x: auto;
  margin: 0;
  color: #dce4d5;
  font: 12px/1.8 var(--font-mono);
  white-space: pre-wrap;
}

.command {
  color: var(--grass-light);
}

.command-comment {
  color: #839184;
}

.command-window__note {
  margin: 18px 0 0;
  border-top: 1px solid var(--line);
  padding-top: 14px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

/* Bas de page */
.closing-card {
  border: 1px solid #485744;
  border-radius: 5px;
  padding: 30px;
  background: linear-gradient(110deg, #1b2a1e, #19201a);
  box-shadow: inset 3px 0 var(--grass);
}

.closing-card h2 {
  margin: 12px 0 8px;
}

.closing-card > p:last-child {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 14px;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 44px;
  border-top: 1px solid var(--line);
  padding-block: 22px;
  color: var(--muted);
  font: 10px/1.8 var(--font-mono);
  letter-spacing: .3px;
}

/* Adaptation pour tablettes */
@media (max-width: 800px) {
  .page {
    width: min(100% - 36px, 620px);
  }

  .hero {
    min-height: 0;
    grid-template-columns: 1fr;
    gap: 32px;
    padding-block: 64px 48px;
  }

  .world-card {
    min-height: 330px;
  }

  .section-heading {
    display: block;
  }

  .section-heading > p {
    margin-top: 14px;
  }

  .project-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .project-card {
    min-height: 185px;
  }

  .sculkcore {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

/* Adaptation pour téléphones */
@media (max-width: 600px) {
  .project-grid {
    grid-template-columns: 1fr;
  }

  .page {
    width: calc(100% - 32px);
  }

  .site-header {
    min-height: 68px;
    flex-wrap: wrap;
    gap: 12px;
  }

  .menu-toggle {
    display: block;
    border: 1px solid #455447;
    border-radius: 4px;
    padding: 9px 12px;
    background: var(--surface);
    color: var(--text);
    font: 11px var(--font-mono);
    text-transform: uppercase;
  }

  .site-nav {
    position: absolute;
    z-index: 5;
    top: calc(100% + 8px);
    right: 0;
    left: 0;
    display: none;
    flex-direction: column;
    gap: 0;
    border: 1px solid #455447;
    border-radius: 4px;
    padding: 8px 14px;
    background: var(--surface-light);
    box-shadow: 0 12px 25px rgb(0 0 0 / 45%);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding-block: 12px;
  }

  .development-status {
    display: none;
  }

  .hero {
    padding-top: 52px;
  }

  h1 {
    font-size: clamp(52px, 15vw, 68px);
  }

  .world-card {
    min-height: 280px;
  }

  .project-stats {
    grid-template-columns: 1fr 1fr;
    gap: 18px 12px;
  }

  .project-stats > div:nth-child(3) {
    border-left: 0;
    padding-left: 0;
  }

  .content-section {
    padding-block: 60px;
  }

  .content-section--compact {
    padding-top: 0;
  }

  .section-heading h2,
  .sculkcore h2,
  .closing-card h2 {
    font-size: 29px;
  }

  .site-footer {
    flex-direction: column;
    gap: 4px;
  }
}