/* ===================================================================
   CARTFIT.AI · achievements.css
   section 04 — achievements
   load order matters — see index.html
   =================================================================== */

/* =================================================================
   04 / ACHIEVEMENTS
   ================================================================= */
.ac-meta {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 40px;
}
.ac-title-block { margin-bottom: 16px; }
.ac-title {
  font-family: var(--font-display);
  font-weight: 100;
  font-size: clamp(72px, 12vw, 160px);
  line-height: 0.88; letter-spacing: -0.01em;
  color: var(--fg-0); display: block;
}
.ac-subtitle {
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: 0.28em;
  color: var(--fg-3); margin-top: 18px; display: block;
}
.ac-counters {
  display: grid; grid-template-columns: repeat(3, 1fr);
  margin: 48px 0; border-top: 1px solid var(--line-1);
}
.ac-counter {
  padding: 36px 0 28px; 
  position: relative; cursor: default;
}
.ac-counter__line {
  position: absolute; top: 0; left: 0;
  height: 1px; background: var(--accent);
  width: 32px;
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.ac-counter:hover .ac-counter__line { width: 100%; }
.ac-counter__n {
  font-family: var(--font-display); font-weight: 100;
  font-size: clamp(60px, 8vw, 100px); line-height: 1; letter-spacing: -0.02em;
  color: var(--fg-0); display: flex; align-items: flex-end; gap: 8px;
  padding-right: 20px;
}
.ac-counter__unit {
  font-family: var(--font-mono);
  font-size: 0.18em; font-weight: 400;
  color: var(--fg-3); letter-spacing: 0.22em;
  padding-bottom: 0.4em;
  transition: color 0.3s;
}
.ac-counter:hover .ac-counter__unit { color: var(--accent); }
.ac-counter__label {
  font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.22em;
  color: var(--fg-3); margin-top: 8px; padding-right: 20px;
}
.ac-rows { border-top: 1px solid var(--line-1); }
.ac-row {
  display: grid; grid-template-columns: 180px 1fr;
  align-items: start; border-bottom: 1px solid #0D0D0D; padding: 22px 0;
}
.ac-row__cat {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.2em;
  color: #A6A6A6; padding-top: 3px;
  display: flex; align-items: center; gap: 10px;
  transition: color 0.3s;
}
.ac-row__dot {
  width: 4px; height: 4px; background: var(--fg-3); flex-shrink: 0;
  transition: background 0.3s, box-shadow 0.3s;
}
.ac-row__entries { display: flex; flex-direction: column; }
.ac-row__entry {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 24px; padding: 9px 0; border-bottom: 1px solid #080808;
}
.ac-row__entry:last-child { border-bottom: none; }
.ac-row__name {
  font-family: var(--font-jp); font-weight: 300;
  font-size: 13.5px; letter-spacing: 0.04em;
  color: var(--fg-1); line-height: 1.5; transition: color 0.3s;
}
.ac-row__win {
  font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.18em;
  color: var(--accent); white-space: nowrap; flex-shrink: 0;
}
.ac-row__ongoing {
  font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.18em;
  color: var(--accent); white-space: nowrap; flex-shrink: 0;
  display: flex; align-items: center; gap: 8px;
}
.ac-row__date {
  font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.16em;
  color: var(--fg-3); white-space: nowrap; flex-shrink: 0;
}
.dot-live {
  width: 4px; height: 4px; background: var(--accent);
  border-radius: 50%; flex-shrink: 0;
  animation: blink 2.4s ease-in-out infinite;
}
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0.15} }

/* hover linkage — counter ↔ matching row (and row hover itself) */
#achievements:has(.ac-counter[data-target="wins"]:hover) .ac-row[data-row="wins"] .ac-row__cat,
#achievements:has(.ac-counter[data-target="adopted"]:hover) .ac-row[data-row="adopted"] .ac-row__cat,
#achievements:has(.ac-counter[data-target="pilots"]:hover) .ac-row[data-row="pilots"] .ac-row__cat,
.ac-row:hover .ac-row__cat { color: var(--accent); }

#achievements:has(.ac-counter[data-target="wins"]:hover) .ac-row[data-row="wins"] .ac-row__dot,
#achievements:has(.ac-counter[data-target="adopted"]:hover) .ac-row[data-row="adopted"] .ac-row__dot,
#achievements:has(.ac-counter[data-target="pilots"]:hover) .ac-row[data-row="pilots"] .ac-row__dot,
.ac-row:hover .ac-row__dot { background: var(--accent); box-shadow: 0 0 0 3px rgba(200,255,0,0.15); }

#achievements:has(.ac-counter[data-target="wins"]:hover) .ac-row[data-row="wins"] .ac-row__name,
#achievements:has(.ac-counter[data-target="adopted"]:hover) .ac-row[data-row="adopted"] .ac-row__name,
#achievements:has(.ac-counter[data-target="pilots"]:hover) .ac-row[data-row="pilots"] .ac-row__name,
.ac-row:hover .ac-row__name { color: var(--fg-0); }

/* reverse linkage — row hover lights matching counter line */
#achievements:has(.ac-row[data-row="wins"]:hover) .ac-counter[data-target="wins"] .ac-counter__line,
#achievements:has(.ac-row[data-row="adopted"]:hover) .ac-counter[data-target="adopted"] .ac-counter__line,
#achievements:has(.ac-row[data-row="pilots"]:hover) .ac-counter[data-target="pilots"] .ac-counter__line { width: 100%; }

.ac-foot {
  margin-top: 40px; padding-top: 18px;
  border-top: 1px solid var(--line-1);
  display: flex; justify-content: space-between;
}

/* ── mobile (≤768) ───────────────────────────────────────────── */
@media (max-width: 768px) {
  .ac-title { font-size: clamp(48px, 14vw, 80px); }
  .ac-subtitle { font-size: 8px; letter-spacing: 0.14em; }
  .ac-counters {
    grid-template-columns: 1fr;
    border-top: none;
  }
  .ac-counter {
    border-top: 1px solid var(--line-1);
    padding: 20px 0;
  }
  .ac-counter__n { font-size: clamp(48px, 14vw, 72px); }
  .ac-row { grid-template-columns: 1fr; gap: 8px; }
  .ac-row__cat { font-size: 9px; margin-bottom: 4px; }
  .ac-row__entry {
    flex-direction: column;
    gap: 4px;
    align-items: flex-start;
  }
  .ac-row__name { font-size: 12px; }
}


