/* ===================================================================
   Forge Atelier Numérique — company site (Projects + About)
   Per docs/Forge - Build Spec.html (v1). Plain, classic, one brand red.
   =================================================================== */

:root {
  --red: #EA1D25;
  --red-hover: #c8161d;
  --ink: #16181d;
  --body: #3f454d;
  --mute: #5b626b;
  --label: #828a94;
  --faint: #949aa3;
  --surface: #f4f5f7;
  --card: #ffffff;
  --line: #e6e8ec;
  --divider: #d8dce2;
  --placeholder: #eef0f3;
  --stripe: #e2e5ea;
}

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

body {
  font-family: "IBM Plex Sans", system-ui, sans-serif;
  color: var(--body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--ink); color: #fff; }

a { color: inherit; text-decoration: none; }
h1, h2, h3 {
  font-family: "Space Grotesk", sans-serif;
  color: var(--ink);
  margin: 0;
}

/* ── Shared bits ──────────────────────────────────────── */
.eyebrow {
  font-family: "IBM Plex Mono", monospace;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--label);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
}
.brand .logo { flex: none; display: block; }
.brand .wordmark {
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}

/* Nav links + language toggle (used in both screens) */
.nav-links { display: flex; gap: 26px; }
.nav-links a {
  font-size: 0.98rem;
  color: var(--mute);
  transition: color 0.18s ease;
}
.nav-links a:hover,
.nav-links a.active { color: var(--ink); }

.toggle {
  display: inline-flex;
  gap: 2px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 3px;
}
.toggle button {
  font-family: "IBM Plex Mono", monospace;
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.06em;
  border: 0;
  background: transparent;
  color: rgba(22, 24, 29, 0.5);
  cursor: pointer;
  padding: 5px 11px;
  border-radius: 7px;
  transition: background 0.18s ease, color 0.18s ease;
}
.toggle button:hover { color: rgba(22, 24, 29, 0.85); }
.toggle button.active { background: var(--ink); color: var(--surface); }

/* ===================================================================
   Projects screen — red brand panel (44%) + light content panel
   =================================================================== */
.projects { display: flex; min-height: 100vh; }

/* Red brand panel */
.panel-red {
  flex: 0 0 44%;
  background: var(--red);
  color: #fff;
  padding: 48px 56px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.panel-red .brand .logo { width: 40px; height: 40px; }
.panel-red .brand .wordmark { color: #fff; }

.hero { max-width: 560px; }
.hero .eyebrow { color: rgba(255, 255, 255, 0.72); }
.hero h1 {
  margin: 18px 0 0;
  color: #fff;
  font-weight: 700;
  font-size: clamp(2.6rem, 4vw, 4.4rem);
  line-height: 1.02;
  letter-spacing: -0.025em;
}
.hero .sub {
  max-width: 450px;
  margin: 22px 0 0;
  font-size: 1.05rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.78);
}
.hero .contact {
  display: inline-block;
  margin-top: 26px;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.85);
  border-bottom: 1px solid rgba(255, 255, 255, 0.4);
  text-underline-offset: 4px;
  padding-bottom: 2px;
  transition: color 0.18s ease, border-color 0.18s ease;
}
.hero .contact:hover { color: #fff; border-color: #fff; }

/* Content panel */
.panel-content {
  flex: 1;
  background: var(--card);
  padding: 40px 56px;
  display: flex;
  flex-direction: column;
}
.topnav {
  display: flex;
  align-items: center;
  gap: 28px;
}
.topnav .toggle { margin-left: auto; }

.work {
  width: 100%;
  max-width: 520px;
  margin: auto 0;
  padding: 48px 0;
}
.section-label {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 14px;
}
.section-label .hr {
  flex: 1;
  height: 1px;
  background: var(--divider);
}
.work h2 {
  margin: 0 0 26px;
  font-weight: 600;
  font-size: clamp(1.5rem, 2.2vw, 2rem);
  line-height: 1.12;
  letter-spacing: -0.02em;
}

/* Project card */
.card {
  background: var(--card);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 20px 50px -20px rgba(0, 0, 0, 0.18);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.26);
}
.card-media {
  position: relative;
  height: 200px;
  background-color: var(--placeholder);
  background-image: repeating-linear-gradient(
    135deg,
    var(--stripe) 0 1px,
    transparent 1px 12px
  );
}
.card-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  font-family: "IBM Plex Mono", monospace;
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  background: var(--ink);
  color: #fff;
  padding: 6px 11px;
  border-radius: 999px;
}
.card-body { padding: 24px 26px 26px; }
.card-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
}
.card-name {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 600;
  font-size: 1.5rem;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.card-tags {
  font-family: "IBM Plex Mono", monospace;
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--label);
  text-align: right;
  white-space: nowrap;
}
.card-desc {
  margin: 12px 0 0;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--body);
}
.card-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 18px;
  color: var(--red);
  font-weight: 500;
  transition: gap 0.18s ease;
}
.card-link:hover { gap: 12px; }
.card-link .arrow { transition: transform 0.18s ease; }

/* ===================================================================
   About screen — single column, light surface, no red panel
   =================================================================== */
.about {
  min-height: 100vh;
  background: var(--surface);
  display: flex;
  flex-direction: column;
}
.about-header {
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 40px 56px;
}
.about-header .brand .logo { width: 30px; height: 30px; }
.about-header .brand .wordmark { color: var(--ink); }
.about-header .nav-links { margin-left: auto; }

.about-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 60px 56px;
}
.about-wrap {
  width: 100%;
  max-width: 680px;
  margin: 0 auto;
}
.about-wrap .eyebrow {
  display: block;
  margin-bottom: 18px;
}
.about-wrap h1 {
  font-weight: 700;
  font-size: clamp(2.2rem, 3.4vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.025em;
  max-width: 14ch;
}
.about-wrap p {
  max-width: 56ch;
  margin: 24px 0 0;
  font-size: 1.15rem;
  line-height: 1.7;
  color: var(--body);
}

/* ===================================================================
   Responsive — stack the Projects screen below ~860px
   =================================================================== */
@media (max-width: 860px) {
  .projects { flex-direction: column; }
  .panel-red {
    flex: none;
    min-height: auto;
    padding: 32px 24px 40px;
  }
  .hero { max-width: none; }
  .hero .sub { max-width: none; }

  .panel-content { padding: 26px 24px 48px; }
  .work {
    max-width: none;
    margin: 30px 0 0;
    padding: 0;
  }

  .about-header {
    padding: 26px 24px;
    gap: 16px;
    flex-wrap: wrap;
  }
  .about-main { padding: 44px 24px; }
}

@media (max-width: 520px) {
  /* long French words overflow the 2.6rem clamp floor on narrow phones */
  .hero h1 { font-size: clamp(2rem, 8.5vw, 2.6rem); }
  .topnav { gap: 16px; flex-wrap: wrap; }
  .nav-links { gap: 20px; }
  .about-header .nav-links { margin-left: 0; }
}
