:root {
  /* Fonds */
  --bg-primary: #0e0f11;
  --bg-secondary: #16181c;
  --bg-card: #1e2128;

  /* Bordures */
  --border-color: #2e333d;

  /* Textes */
  --text-primary: #e8eaf0;
  --text-secondary: #8a9ab0;

  /* Accents */
  --accent-gold: #c9a84c;
  --accent-purple: #7b68ee;
  --accent-green: #4caf7d;
  --accent-red: #e05c4b;

  /* Typographie */
  --font-heading: "Barlow", sans-serif;
  --font-body: "Inter", sans-serif;
  --font-mono: "JetBrains Mono", monospace;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-body);
}
nav {
  background-color: var(--bg-secondary);
  padding: 1rem;
}
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-primary);
}

code, pre, kbd, samp {
  font-family: var(--font-mono);
}
.corner-box {
  position: relative;
  padding: 14px 18px;
}

.corner-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 12px;
  height: 12px;
  border-top: 1.5px solid #c9a84c;
  border-left: 1.5px solid #c9a84c;
}

.corner-box::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 12px;
  height: 12px;
  border-top: 1.5px solid #c9a84c;
  border-right: 1.5px solid #c9a84c;
}

/* Élément enfant obligatoire pour les coins bas
   <div class="corner-box"><div class="corner-box-inner"></div>...</div> */
.corner-box-inner::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 12px;
  height: 12px;
  border-bottom: 1.5px solid #c9a84c;
  border-left: 1.5px solid #c9a84c;
}

.corner-box-inner::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 12px;
  height: 12px;
  border-bottom: 1.5px solid #c9a84c;
  border-right: 1.5px solid #c9a84c;
}

.text-secondary {
  color: var(--text-secondary);
}

.accent-gold {
  color: var(--accent-gold);
}

.accent-purple {
  color: var(--accent-purple);
}

.accent-green {
  color: var(--accent-green);
}

.accent-red {
  color: var(--accent-red);
}
/* Classes de clip-path pour les cartes */
.clip-lg {
  clip-path: polygon(0 0, calc(100% - 16px) 0, 100% 16px, 100% 100%, 0 100%);
}

.clip-md {
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 0 100%);
}

.clip-sm {
clip-path: polygon(20px 0, 100% 0, 100% 100%, 0 100%);
}
.clip-double {
  clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 14px 100%, 0 calc(100% - 14px));
}

.clip-up{
clip-path: polygon(14px 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 0 100%, 0 14px);}
/* Plus subtil */
.badge-glass-sm {
  background: rgba(138, 154, 176, 0.05);
  border: 0.5px solid rgba(138, 154, 176, 1);
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.etiquette {
background: rgba(32, 96, 160, 0.15);
border: 0.5px solid rgba(80, 160, 220, 0.35);
backdrop-filter: blur(8px);
}
/* Plus visible */
.badge-glass-lg {
  background: rgba(207, 221, 239, 0.15);
  border: 0.5px solid rgba(0, 78, 186, 0.3);
  box-shadow:
    0 6px 16px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.seg-box { border-top: 1.5px solid #c9a84c; border-bottom: 1.5px solid #c9a84c; }
.seg-box::before { top:-1.5px; left:0; width:30%; height:1.5px; background:#0e0f11; }
.seg-box::after { bottom:-1.5px; right:0; width:30%; height:1.5px; background:#0e0f11; }

/* ════════════════════════════════════════════
   SECTION PROJETS — split layout HUD
   ════════════════════════════════════════════ */

.clip-card {
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px));
}
.clip-panel {
  clip-path: polygon(0 0, calc(100% - 20px) 0, 100% 20px, 100% 100%, 20px 100%, 0 calc(100% - 20px));
}
.clip-btn {
  clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 8px 100%, 0 calc(100% - 8px));
}
.clip-thumb {
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 0 100%);
}
.clip-diagonal-left {
  clip-path: polygon(16px 0, 100% 0, 100% 100%, 0 100%);
}

/* Bordures interrompues façon HUD */
.hud-border {
  position: relative;
}
.hud-border::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1.5px;
  background: linear-gradient(to right, #c9a84c 0%, #c9a84c 25%, transparent 25%, transparent 75%, #c9a84c 75%, #c9a84c 100%);
  pointer-events: none;
}
.hud-border::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1.5px;
  background: linear-gradient(to right, #c9a84c 0%, #c9a84c 25%, transparent 25%, transparent 75%, #c9a84c 75%, #c9a84c 100%);
  pointer-events: none;
}
.hud-border-violet::before,
.hud-border-violet::after {
  background: linear-gradient(to right, #7b68ee 0%, #7b68ee 25%, transparent 25%, transparent 75%, #7b68ee 75%, #7b68ee 100%);
}
.hud-border-teal::before,
.hud-border-teal::after {
  background: linear-gradient(to right, #4db89e 0%, #4db89e 25%, transparent 25%, transparent 75%, #4db89e 75%, #4db89e 100%);
}

/* Carte projet — liste/carrousel vertical */
.project-card {
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}
.project-card:hover {
  background: #1e2128;
  transform: translateX(3px);
}
.project-card.active {
  background: #1e2128;
  border-left: 2px solid #c9a84c;
}
.project-card.active-violet {
  border-left-color: #7b68ee;
}
.project-card.active-teal {
  border-left-color: #4db89e;
}

#carousel-track {
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

#detail-panel {
  transition: opacity 0.25s ease, transform 0.25s ease;
}
#detail-panel.switching {
  opacity: 0;
  transform: translateX(8px);
}

.img-placeholder {
  background: repeating-linear-gradient(45deg, #1e2128 0px, #1e2128 10px, #16181c 10px, #16181c 20px);
}

#detail-thumb {
  background-size: cover;
  background-position: center;
}

.carousel-wrap::-webkit-scrollbar { display: none; }
.carousel-wrap { -ms-overflow-style: none; scrollbar-width: none; }

.key-point {
  position: relative;
  padding-left: 14px;
}
.key-point::before {
  content: '';
  position: absolute;
  left: 0; top: 50%;
  transform: translateY(-50%);
  width: 4px; height: 4px;
  background: #c9a84c;
  clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
}

@media (prefers-reduced-motion: reduce) {
  #carousel-track, #detail-panel { transition: none; }
  .project-card { transition: none; }
}

/* ════════════════════════════════════════════
   SECTION STACK & OUTILS — animations
   (.stack-cat / .stack-seg sont des hooks JS,
   le style visuel reste en Tailwind dans le HTML)
   ════════════════════════════════════════════ */

.stack-cat {
  position: relative;
  overflow: hidden;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.stack-cat.in-view {
  opacity: 1;
  transform: translateY(0);
}
.stack-cat:nth-child(1) { transition-delay: 0s; }
.stack-cat:nth-child(2) { transition-delay: 0.1s; }
.stack-cat:nth-child(3) { transition-delay: 0.2s; }
.stack-cat:nth-child(4) { transition-delay: 0.3s; }

/* Scan line au survol */
.stack-cat::after {
  content: '';
  position: absolute;
  left: 0; right: 0;
  top: -2px;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(201, 168, 76, 0.4) 20%, rgba(201, 168, 76, 0.6) 50%, rgba(201, 168, 76, 0.4) 80%, transparent);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.stack-cat:hover::after {
  opacity: 1;
  animation: stack-scanline 1.2s linear;
}
@keyframes stack-scanline {
  from { top: -2px; opacity: 1; }
  to   { top: 100%; opacity: 0; }
}

.stack-seg {
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}
.stack-seg.filled {
  transform: scaleX(1);
}

@media (prefers-reduced-motion: reduce) {
  .stack-cat {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .stack-cat::after { display: none; }
  .stack-seg {
    transform: scaleX(1);
    transition: none;
  }
}

/* ════════════════════════════════════════════
   SECTION CONTACT — point de statut animé
   ════════════════════════════════════════════ */

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-green);
  flex-shrink: 0;
  animation: pulse-dot 2.5s ease-in-out infinite;
}
@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(76, 175, 125, 0.4); }
  50%      { box-shadow: 0 0 0 5px rgba(76, 175, 125, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .status-dot { animation: none; }
}
.status-dot2 {
  width: 7px;
  height: px;
  border-radius: 100%;
  background: var(--accent-green);
  flex-shrink: 0;
  animation: pulse-dot2 2.5s ease-in-out infinite;
}
@keyframes pulse-dot2 {
  0%, 100% { box-shadow: 0 0 0 0 rgba(76, 175, 125, 0.7); }
  50%      { box-shadow: 0 0 0 5px rgba(76, 175, 125, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .status-dot2 { animation: none; }
}
