/* ==========================================================
   1. COULEURS ET RÉGLAGES GÉNÉRAUX
   Modifie principalement cette partie pour changer la DA.
   ========================================================== */
:root {
  --white: #ffffff;
  --paper: #f8fafb;
  --paper-blue: #eef5f9;
  --line: #dce3e7;
  --ink: #11171b;
  --ink-soft: #3f4b52;
  --muted: #718089;
  --blue-light: #dcecf5;
  --blue-mid: #9fc6dc;
  --blue-strong: #4e7f9b;
  --blue-dark: #27536c;
  --shadow: 0 24px 70px rgba(39, 66, 80, 0.13);
  --radius: 22px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--paper);
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}

body.is-detail-open {
  background: var(--white);
}

[hidden] {
  display: none !important;
}

button,
a {
  font: inherit;
}

button {
  color: inherit;
}

button,
a[href] {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

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

::selection {
  background: var(--blue-light);
  color: var(--ink);
}

:focus-visible {
  outline: 3px solid var(--blue-strong);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--ink);
  color: var(--white);
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

/* ==========================================================
   2. EN-TÊTE
   ========================================================== */
.site-header {
  position: relative;
  z-index: 50;
  min-height: 90px;
  padding: 18px clamp(20px, 4vw, 66px);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(16px);
}

body.is-detail-open .site-header {
  position: sticky;
  top: 0;
}

.brand {
  width: fit-content;
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.brand-name {
  font-size: 1.08rem;
  font-weight: 750;
  letter-spacing: -0.025em;
}

.brand-role {
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.brand:hover .brand-name {
  color: var(--blue-dark);
}

.availability {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--ink-soft);
  font-size: 0.78rem;
}

.availability span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #7aaf9b;
  box-shadow: 0 0 0 5px rgba(122, 175, 155, 0.13);
}

.header-links {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-links a,
.header-links button {
  min-height: 42px;
  padding: 10px 14px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--ink-soft);
  font-size: 0.82rem;
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease, color 180ms ease;
}

.header-links a:hover,
.header-links button:hover {
  border-color: var(--line);
  background: var(--paper-blue);
  color: var(--ink);
}

.header-links .cv-link {
  border-color: var(--line);
  background: var(--white);
}

.header-links .contact-button {
  padding-inline: 20px;
  background: var(--ink);
  color: var(--white);
}

.header-links .contact-button:hover {
  border-color: var(--blue-dark);
  background: var(--blue-dark);
  color: var(--white);
}

/* ==========================================================
   3. ACCUEIL
   ========================================================== */
.home-view {
  min-height: calc(100svh - 90px);
  padding: clamp(24px, 3vw, 46px) clamp(20px, 4vw, 66px) 20px;
  display: grid;
  grid-template-rows: auto minmax(360px, 1fr) auto;
  gap: clamp(18px, 2.2vw, 32px);
  background:
    radial-gradient(circle at 75% 10%, rgba(201, 226, 239, 0.42), transparent 28%),
    var(--paper);
}

.home-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(260px, 0.7fr);
  align-items: end;
  gap: 40px;
}

.eyebrow,
.section-label {
  margin: 0 0 10px;
  color: var(--blue-dark);
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.home-intro h1 {
  margin: 0;
  max-width: 850px;
  font-size: clamp(2rem, 4.3vw, 5rem);
  font-weight: 650;
  letter-spacing: -0.065em;
  line-height: 0.96;
}

.home-intro > p {
  max-width: 500px;
  margin: 0;
  color: var(--ink-soft);
  font-size: clamp(0.95rem, 1.25vw, 1.18rem);
}

.universe-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: 0.92fr 1.16fr 0.92fr;
  gap: clamp(12px, 1.5vw, 22px);
}

.universe-card {
  position: relative;
  min-height: 360px;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(78, 99, 111, 0.26);
  border-radius: var(--radius);
  background: #dce5e9;
  text-align: left;
  cursor: pointer;
  isolation: isolate;
  box-shadow: 0 12px 38px rgba(44, 66, 78, 0.08);
  transition: transform 450ms var(--ease), box-shadow 450ms var(--ease), border-color 250ms ease;
}

.universe-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 850ms var(--ease), filter 450ms ease;
}

.universe-card--datacenter img {
  object-position: center 48%;
}

.universe-card--development img {
  object-position: center 55%;
}

.card-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(238, 246, 250, 0.12) 0%, rgba(12, 24, 31, 0.08) 42%, rgba(12, 25, 32, 0.91) 100%),
    linear-gradient(90deg, rgba(170, 205, 224, 0.12), transparent 55%);
}

.universe-card--support .card-overlay {
  background:
    linear-gradient(180deg, rgba(223, 240, 250, 0.08) 0%, rgba(12, 35, 48, 0.08) 38%, rgba(12, 34, 47, 0.92) 100%),
    linear-gradient(90deg, rgba(126, 189, 224, 0.18), transparent 60%);
}

.card-number,
.priority-label,
.card-copy,
.card-action {
  position: absolute;
  z-index: 2;
  color: var(--white);
}

.priority-label {
  top: 18px;
  right: 18px;
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 999px;
  background: rgba(27, 68, 90, 0.38);
  backdrop-filter: blur(10px);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.card-copy {
  right: 24px;
  bottom: 58px;
  left: 24px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.card-copy small {
  margin-bottom: 8px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.68rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.card-copy strong {
  max-width: 96%;
  font-size: clamp(1.5rem, 2.5vw, 3rem);
  font-weight: 600;
  letter-spacing: -0.055em;
  line-height: 0.98;
}

.card-copy > span {
  max-width: 440px;
  margin-top: 12px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.86rem;
}

.card-action {
  right: 24px;
  bottom: 22px;
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.universe-card:hover,
.universe-card:focus-visible {
  z-index: 2;
  border-color: rgba(73, 130, 162, 0.7);
  box-shadow: var(--shadow);
  transform: translateY(-8px);
}

.universe-card:hover img,
.universe-card:focus-visible img {
  transform: scale(1.045);
  filter: saturate(1.04) contrast(1.02);
}

.home-footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  color: var(--muted);
  font-size: 0.72rem;
}

/* ==========================================================
   4. NAVIGATION DES PAGES DÉTAILLÉES
   ========================================================== */
.detail-view {
  min-height: 100svh;
  background: var(--white);
}

.detail-navigation {
  position: sticky;
  z-index: 40;
  top: 90px;
  min-height: 64px;
  padding: 10px clamp(20px, 4vw, 66px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(16px);
}

.detail-navigation nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.detail-navigation button {
  min-height: 40px;
  padding: 8px 13px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 0.76rem;
  cursor: pointer;
}

.detail-navigation button span {
  margin-right: 7px;
  font-size: 0.65rem;
}

.detail-navigation nav button:hover,
.detail-navigation nav button.is-active {
  border-color: var(--line);
  background: var(--paper-blue);
  color: var(--ink);
}

.detail-navigation .back-home {
  border-color: var(--line);
  color: var(--ink);
}

.detail-navigation .back-home:hover {
  border-color: var(--blue-mid);
  background: var(--blue-light);
}

/* ==========================================================
   5. GRANDE IMAGE DE CHAQUE UNIVERS
   ========================================================== */
.detail-hero {
  position: relative;
  min-height: calc(100svh - 154px);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  isolation: isolate;
  background: #dbe5ea;
}

.detail-hero > img,
.hero-shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.detail-hero > img {
  z-index: -2;
  object-fit: cover;
}

.detail-hero--datacenter > img {
  object-position: center 42%;
}

.detail-hero--development > img {
  object-position: center 58%;
}

.hero-shade {
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(7, 19, 25, 0.76) 0%, rgba(9, 28, 39, 0.26) 54%, rgba(9, 26, 35, 0.18) 100%),
    linear-gradient(0deg, rgba(7, 18, 24, 0.6), transparent 50%);
}

.detail-hero--support .hero-shade {
  background:
    linear-gradient(90deg, rgba(13, 40, 55, 0.8) 0%, rgba(23, 67, 90, 0.25) 58%, rgba(14, 39, 52, 0.12) 100%),
    linear-gradient(0deg, rgba(8, 25, 34, 0.58), transparent 50%);
}

.hero-copy {
  width: min(920px, 78vw);
  padding: clamp(44px, 6vw, 96px) clamp(20px, 6vw, 100px);
  color: var(--white);
}

.hero-copy > span,
.hero-copy > p:first-of-type {
  display: inline-block;
  margin: 0 16px 14px 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero-copy h2 {
  margin: 0;
  font-size: clamp(3.5rem, 9vw, 9rem);
  font-weight: 570;
  letter-spacing: -0.075em;
  line-height: 0.86;
}

.hero-description {
  max-width: 630px;
  margin: 26px 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(1rem, 1.5vw, 1.3rem);
}

.scroll-indicator {
  position: absolute;
  right: clamp(20px, 5vw, 80px);
  bottom: 38px;
  padding: 11px 15px;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 999px;
  background: rgba(9, 27, 37, 0.25);
  color: var(--white);
  font-size: 0.75rem;
  backdrop-filter: blur(8px);
}

.scroll-indicator:hover {
  background: rgba(9, 27, 37, 0.55);
}

/* ==========================================================
   6. CONTENU ÉDITORIAL
   ========================================================== */
.editorial {
  background: var(--white);
}

.editorial h3,
.contact-band h3 {
  margin: 0;
  font-size: clamp(2rem, 4.2vw, 4.8rem);
  font-weight: 590;
  letter-spacing: -0.06em;
  line-height: 1;
}

.editorial h4 {
  margin: 0;
  font-size: 1.12rem;
}

.editorial p {
  color: var(--ink-soft);
}

.lead {
  font-size: clamp(1.05rem, 1.45vw, 1.3rem);
  line-height: 1.55;
}

.intro-section,
.content-section,
.experience-card,
.compact-card,
.three-columns {
  padding: clamp(58px, 8vw, 120px) clamp(20px, 7vw, 120px);
}

.intro-section {
  display: grid;
  grid-template-columns: minmax(240px, 0.7fr) minmax(0, 1.3fr);
  align-items: center;
  gap: clamp(40px, 8vw, 130px);
}

.portrait {
  margin: 0;
}

.portrait img {
  width: 100%;
  max-height: 500px;
  border-radius: var(--radius);
  object-fit: cover;
  object-position: center 24%;
  box-shadow: var(--shadow);
}

.portrait figcaption {
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.75rem;
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
  align-items: end;
  gap: clamp(32px, 7vw, 110px);
}

.section-heading > p {
  margin: 0;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-block: 1px solid #c6dce8;
  background: var(--paper-blue);
}

.metrics > div {
  min-height: 170px;
  padding: 30px;
  display: flex;
  flex-direction: column;
  border-right: 1px solid #c6dce8;
}

.metrics > div:last-child {
  border-right: 0;
}

.metrics strong {
  font-size: clamp(1.6rem, 3vw, 3rem);
  letter-spacing: -0.055em;
}

.metrics span {
  margin-top: 6px;
  color: var(--blue-dark);
  font-size: 0.78rem;
}

.metrics--datacenter {
  background: #f1f5f7;
}

.skill-list {
  margin-top: clamp(40px, 6vw, 80px);
  border-top: 1px solid var(--line);
}

.skill-list article {
  min-height: 112px;
  padding: 24px 0;
  display: grid;
  grid-template-columns: 70px minmax(200px, 0.65fr) minmax(280px, 1.35fr);
  align-items: center;
  gap: 24px;
  border-bottom: 1px solid var(--line);
}

.skill-list article > span {
  color: var(--blue-strong);
  font-size: 0.72rem;
  font-weight: 750;
}

.skill-list p {
  margin: 0;
}

.experience-card {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: clamp(40px, 8vw, 130px);
  background: var(--ink);
  color: var(--white);
}

.experience-card p,
.experience-card .section-label {
  color: rgba(255, 255, 255, 0.72);
}

.experience-card ul {
  margin: 24px 0 0;
  padding-left: 20px;
  color: rgba(255, 255, 255, 0.86);
}

.experience-card li + li {
  margin-top: 8px;
}

.compact-card {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  align-items: end;
  gap: clamp(40px, 8vw, 130px);
  background: #f2f6f8;
}

.compact-card p {
  margin-bottom: 0;
}

.three-columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
}

.three-columns article {
  padding: clamp(26px, 4vw, 56px);
  background: var(--paper);
}

.technology-list {
  padding: 22px clamp(20px, 7vw, 120px);
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  border-block: 1px solid var(--line);
  background: var(--paper-blue);
  justify-content: center;
}

.technology-list span {
  padding: 10px 14px;
  border: 1px solid #c8dce7;
  border-radius: 999px;
  background: var(--white);
  color: var(--blue-dark);
  font-size: 0.78rem;
  font-weight: 650;
}

.project-grid {
  margin-top: clamp(42px, 6vw, 80px);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.project-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.project-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
}

.project-card > div {
  padding: 24px;
}

.project-card p {
  min-height: 72px;
}

.project-card > div > span {
  display: block;
  color: var(--muted);
  font-size: 0.72rem;
}

.project-card a {
  width: fit-content;
  margin-top: 22px;
  display: block;
  color: var(--blue-dark);
  font-size: 0.82rem;
  font-weight: 750;
}

.project-card a:hover {
  text-decoration: underline;
}

/* ==========================================================
   7. CONTACT ET PIED DE PAGE
   ========================================================== */
.contact-band {
  padding: clamp(60px, 8vw, 120px) clamp(20px, 7vw, 120px);
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  align-items: end;
  gap: clamp(40px, 8vw, 120px);
  background: var(--blue-light);
}

.contact-band p {
  color: var(--blue-dark);
}

.contact-band button {
  margin-top: 18px;
  padding: 13px 20px;
  border: 0;
  border-radius: 999px;
  background: var(--ink);
  color: var(--white);
  cursor: pointer;
}

.contact-band button:hover {
  background: var(--blue-dark);
}

.site-footer {
  padding: 22px clamp(20px, 4vw, 66px);
  display: flex;
  justify-content: space-between;
  gap: 24px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.72rem;
}

.contact-dialog {
  width: min(650px, calc(100% - 32px));
  padding: clamp(24px, 4vw, 42px);
  border: 1px solid #bfd5e1;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  box-shadow: 0 40px 100px rgba(8, 28, 39, 0.3);
}

.contact-dialog::backdrop {
  background: rgba(12, 23, 29, 0.6);
  backdrop-filter: blur(6px);
}

.dialog-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
}

.dialog-heading h2 {
  margin: 0;
  font-size: clamp(2.3rem, 6vw, 4.2rem);
  letter-spacing: -0.06em;
  line-height: 0.95;
}

.dialog-close {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  font-size: 1.6rem;
  cursor: pointer;
}

.dialog-close:hover {
  background: var(--blue-light);
}

.email-box {
  margin: 28px 0;
  padding: 18px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px 18px;
  border: 1px solid #c5dce8;
  border-radius: 16px;
  background: var(--paper-blue);
}

.email-box span {
  color: var(--muted);
  font-size: 0.7rem;
  text-transform: uppercase;
}

.email-box strong {
  overflow-wrap: anywhere;
}

.email-box button {
  grid-row: 1 / 3;
  grid-column: 2;
  padding: 9px 13px;
  border: 1px solid var(--blue-mid);
  border-radius: 999px;
  background: var(--white);
  color: var(--blue-dark);
  cursor: pointer;
}

.email-box button:hover {
  background: var(--blue-light);
}

.dialog-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.dialog-links a {
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 0.82rem;
}

.dialog-links a:hover {
  border-color: var(--blue-mid);
  background: var(--paper-blue);
}

.toast {
  position: fixed;
  z-index: 1000;
  right: 20px;
  bottom: 20px;
  margin: 0;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--ink);
  color: var(--white);
  box-shadow: var(--shadow);
  font-size: 0.82rem;
}

/* ==========================================================
   8. TABLETTES ET TÉLÉPHONES
   ========================================================== */
@media (max-width: 1050px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .availability {
    display: none;
  }

  .universe-grid {
    grid-template-columns: 1fr 1.08fr 1fr;
  }

  .card-copy strong {
    font-size: clamp(1.35rem, 3vw, 2.2rem);
  }

  .project-grid {
    grid-template-columns: 1fr 1fr;
  }

  .project-card:last-child {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .project-card:last-child img {
    height: 100%;
    border-right: 1px solid var(--line);
    border-bottom: 0;
  }
}

@media (max-width: 780px) {
  .site-header {
    min-height: auto;
    padding: 14px 18px;
  }

  .brand-role,
  .header-links > a:first-child {
    display: none;
  }

  .header-links a,
  .header-links button {
    min-height: 38px;
    padding: 8px 11px;
    font-size: 0.75rem;
  }

  .header-links .cv-link {
    display: none;
  }

  .home-view {
    min-height: auto;
    padding: 30px 18px 20px;
    display: block;
  }

  .home-intro {
    display: block;
  }

  .home-intro h1 {
    font-size: clamp(2.5rem, 13vw, 4.4rem);
  }

  .home-intro > p {
    margin-top: 20px;
  }

  .universe-grid {
    margin-top: 30px;
    grid-template-columns: 1fr;
  }

  .universe-card {
    min-height: 390px;
  }

  .universe-card--support {
    order: -1;
  }

  .card-copy strong {
    font-size: 2.5rem;
  }

  .home-footer {
    margin-top: 22px;
    flex-direction: column;
    gap: 5px;
  }

  .detail-navigation {
    top: 67px;
    padding: 9px 14px;
    overflow-x: auto;
  }

  .detail-navigation nav {
    min-width: max-content;
  }

  .detail-navigation nav button span {
    display: none;
  }

  .detail-navigation .back-home {
    min-width: max-content;
  }

  .detail-hero {
    min-height: calc(100svh - 126px);
  }

  .hero-copy {
    width: 100%;
    padding: 50px 20px 90px;
  }

  .hero-copy h2 {
    font-size: clamp(3.2rem, 16vw, 6rem);
  }

  .scroll-indicator {
    right: 20px;
    bottom: 24px;
  }

  .intro-section,
  .section-heading,
  .experience-card,
  .compact-card,
  .contact-band {
    grid-template-columns: 1fr;
  }

  .intro-section,
  .content-section,
  .experience-card,
  .compact-card,
  .three-columns,
  .contact-band {
    padding: 58px 20px;
  }

  .portrait {
    max-width: 420px;
  }

  .metrics {
    grid-template-columns: 1fr 1fr;
  }

  .metrics > div:nth-child(2) {
    border-right: 0;
  }

  .metrics > div:nth-child(-n + 2) {
    border-bottom: 1px solid #c6dce8;
  }

  .skill-list article {
    grid-template-columns: 46px 1fr;
    gap: 8px 16px;
  }

  .skill-list article p {
    grid-column: 2;
  }

  .three-columns,
  .project-grid {
    grid-template-columns: 1fr;
  }

  .project-card:last-child {
    grid-column: auto;
    display: block;
  }

  .project-card:last-child img {
    height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .site-footer {
    flex-direction: column;
    gap: 4px;
  }
}

@media (max-width: 520px) {
  .brand-name {
    font-size: 0.94rem;
  }

  .header-links .contact-button {
    padding-inline: 14px;
  }

  .universe-card {
    min-height: 350px;
  }

  .priority-label {
    max-width: 128px;
    text-align: center;
  }

  .detail-navigation nav button {
    padding-inline: 10px;
  }

  .detail-navigation .back-home {
    font-size: 0;
  }

  .detail-navigation .back-home span {
    margin: 0;
    font-size: 1.1rem;
  }

  .metrics {
    grid-template-columns: 1fr;
  }

  .metrics > div {
    min-height: 130px;
    border-right: 0;
    border-bottom: 1px solid #c6dce8;
  }

  .metrics > div:last-child {
    border-bottom: 0;
  }

  .email-box,
  .dialog-links {
    grid-template-columns: 1fr;
  }

  .email-box button {
    grid-row: auto;
    grid-column: auto;
    margin-top: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
