/* =========================================================
   TECHTAN Consulting — CV page (Jérémy Peyraud)
   Builds on css/styles.css (shared design system).
   Only CV-specific components live here.
   ========================================================= */

/* ---------- CV hero / identity ---------- */
.cv-hero {
  position: relative;
  padding-top: calc(var(--nav-h) + clamp(34px, 6vw, 72px));
  padding-bottom: clamp(28px, 4vw, 48px);
  overflow: hidden;
}

.cv-id { display: grid; grid-template-columns: auto 1fr; gap: clamp(20px, 3vw, 36px); align-items: center; }

.cv-avatar {
  width: clamp(86px, 12vw, 128px);
  height: clamp(86px, 12vw, 128px);
  border-radius: 28px;
  display: grid; place-items: center;
  font-family: var(--font-head); font-weight: 700;
  font-size: clamp(32px, 5vw, 50px);
  color: #0a1417;
  background: var(--grad-brand);
  box-shadow: var(--shadow-glow);
}

.cv-id h1 { font-size: clamp(30px, 5.2vw, 58px); letter-spacing: -0.03em; }
.cv-role { color: var(--mint); font-family: var(--font-head); font-weight: 600; font-size: clamp(15px, 2vw, 20px); margin-top: 8px; }
.cv-meta-line { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 12px; color: var(--muted); font-size: 14.5px; }
.cv-meta-line > span { display: inline-flex; align-items: center; gap: 7px; }
.cv-meta-line svg { width: 16px; height: 16px; color: var(--mint); flex: none; }

.cv-lead { color: var(--muted); font-size: clamp(16px, 1.55vw, 19px); line-height: 1.7; max-width: 70ch; margin-top: clamp(22px, 3vw, 30px); }

.cv-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: clamp(22px, 3vw, 28px); }

/* facts strip reuses .trust from styles.css */
.cv-hero .trust { margin-top: clamp(24px, 3.5vw, 34px); }

/* ---------- Section sizing (slightly tighter than home) ---------- */
.cv-section { padding: clamp(44px, 6vw, 88px) 0; }
.cv-section .section-head { margin-bottom: clamp(28px, 4vw, 44px); }
/* The Experience intro is one long sentence; the shared .section-head caps the
   column at 62ch, which orphaned the last word. Widen just this block, and let
   pretty wrapping avoid a lone last word in either language. */
#experience .section-head,
#experience .section-head .lead { max-width: 80ch; }
#experience .section-head .lead { text-wrap: pretty; }

/* ---------- Skills ---------- */
.skill-groups { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.skill-group { display: grid; gap: 14px; align-content: start; }
.skill-group h3 { display: flex; align-items: center; gap: 12px; font-size: 16px; }
.skill-group .gico {
  width: 36px; height: 36px; flex: none;
  border-radius: 11px;
  display: grid; place-items: center;
  background: var(--grad-soft);
  border: 1px solid var(--border);
  color: var(--mint);
}
.skill-group .gico svg { width: 19px; height: 19px; }
.skill-group .chips { display: flex; flex-wrap: wrap; gap: 8px; }
.skill-group .tag { color: var(--muted); background: var(--surface-2); border-color: var(--border); }

/* ---------- Experience timeline ---------- */
.cv-timeline { position: relative; display: grid; gap: 18px; }
.cv-timeline::before {
  content: "";
  position: absolute;
  left: 23px; top: 12px; bottom: 12px;
  width: 2px;
  background: linear-gradient(180deg, var(--mint-deep), rgba(79, 140, 125, 0.12) 92%, transparent);
  opacity: .55;
}

.cv-job { position: relative; padding-left: 64px; }
.cv-job::before {
  content: "";
  position: absolute;
  left: 16px; top: 28px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--grad-brand);
  box-shadow: 0 0 0 4px var(--bg), var(--shadow-glow);
}

.cv-job-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; }
.cv-logo { flex: none; width: 158px; height: 46px; display: grid; place-content: center; place-items: center; padding: 7px 12px; background: #fff; border-radius: 12px; box-shadow: 0 8px 22px -14px rgba(0, 0, 0, 0.7); }
.cv-logo img { height: 32px; width: auto; max-width: 142px; object-fit: contain; display: block; }
.cv-logo img[src*="Daito-Design"] { height: 41px; } /* enlarged: the Daito mark sits small in its canvas */
.cv-logo img[src*="flyingblue"] { height: 34px; } /* nudged up for optical balance */
.cv-logo--ink { background: #000; } /* black chip for white/light logos (e.g. EyeLights) */
.cv-job-headtext { flex: 1 1 200px; min-width: 0; }
.cv-job-title { font-size: clamp(18px, 2.3vw, 22px); }
.cv-company { color: var(--mint); font-family: var(--font-head); font-weight: 600; font-size: 15px; margin-top: 5px; }
.cv-job-when { flex: none; margin-left: auto; color: var(--muted-2); font-family: var(--font-head); font-weight: 600; font-size: 13px; letter-spacing: .01em; text-align: right; }

.cv-bullets { margin: 16px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.cv-bullets li { position: relative; padding-left: 22px; color: var(--muted); font-size: 15px; line-height: 1.6; }
.cv-bullets li::before { content: ""; position: absolute; left: 1px; top: 9px; width: 7px; height: 7px; border-radius: 2px; background: var(--grad-brand); }

.cv-job .chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.cv-job .chips .tag { color: var(--muted); background: var(--surface-2); border-color: var(--border); }

/* Nested roles within one company (e.g. Intel) */
.cv-subrole { margin-top: 20px; padding-top: 18px; border-top: 1px dashed var(--border); }
.cv-subrole-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 16px; }
.cv-subrole-title { font-size: 17px; font-family: var(--font-head); font-weight: 600; }
.cv-tracking { margin: 12px 0 0; color: var(--muted-2); font-size: 13.5px; }

/* ---------- Responsive ---------- */
@media (max-width: 820px) {
  .skill-groups { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .cv-id { grid-template-columns: 1fr; gap: 18px; }
  .cv-job-when { text-align: left; }
}
@media (max-width: 520px) {
  .cv-job { padding-left: 46px; }
  .cv-timeline::before { left: 15px; }
  .cv-job::before { left: 8px; }
}

/* ---------- Print / save-to-PDF (clean light layout) ---------- */
@media print {
  :root { --text: #11272d; --muted: #3a564f; --muted-2: #5c7570; --border: #d9e4e1; }
  html, body { background: #fff !important; color: #11272d !important; }
  body::before, body::after { display: none !important; }
  .nav, .nav-toggle, .lang, .hero-aurora, .cv-actions, .footer-bottom a,
  [data-print], .cv-print-hide { display: none !important; }

  .cv-hero { padding-top: 4px; }
  .cv-section, .section { padding: 12px 0 !important; }
  .section-head { margin-bottom: 10px !important; }

  .card { box-shadow: none !important; background: #fff !important; border-color: #d9e4e1 !important; }
  .card::before { display: none !important; }
  .tag { color: #2c4a44 !important; background: #eef4f2 !important; border-color: #d4e2de !important; }

  .cv-avatar, .gradient-text, .cv-timeline::before, .cv-job::before, .eyebrow::before,
  .cv-bullets li::before, .skill-group .gico, .cv-logo, .cv-logo--ink {
    -webkit-print-color-adjust: exact; print-color-adjust: exact;
  }
  .cv-job::before { box-shadow: 0 0 0 4px #fff; }
  .cv-logo { box-shadow: none !important; }

  a { color: inherit !important; }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
  .cv-job, .skill-group, .cta-band { break-inside: avoid; }
}
