:root {
  color-scheme: light;
  --ink: #1f2927;
  --muted: #66716d;
  --paper: #f6f2e9;
  --paper-deep: #eee7da;
  --line: rgba(42, 61, 56, 0.14);
  --platform: #7e9854;
  --identity: #d29a36;
  --security: #d6795d;
  --cloud: #4c97ac;
  --ai: #d9a515;
  --lane-label: 132px;
  font-family: "Aptos", "Segoe UI", ui-sans-serif, -apple-system, BlinkMacSystemFont, sans-serif;
}

* { box-sizing: border-box; }

html, body { overflow-x: hidden; }

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 8% 4%, rgba(255, 255, 255, 0.96), transparent 34rem),
    linear-gradient(145deg, #faf8f2 0%, var(--paper) 48%, #eee8dc 100%);
  min-height: 100vh;
}

button, input, select { font: inherit; }
button { color: inherit; }

.page-shell {
  width: min(1560px, 100%);
  margin: 0 auto;
  padding: clamp(24px, 4vw, 64px);
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: clamp(18px, 2.5vw, 30px);
  font-family: "Aptos", "Segoe UI", sans-serif;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 12px;
  color: #fffdf8;
  background: linear-gradient(135deg, #59654b, #8fa37b 62%, #c98255);
  font-size: 24px;
  font-weight: 750;
}

.brand strong,
.brand small { display: block; }
.brand strong { font-size: 18px; }
.brand small { margin-top: 2px; color: var(--muted); font-size: 12px; font-weight: 650; }

.career-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  color: #4f5747;
  font-size: 14px;
  font-weight: 650;
}

.career-nav a { color: inherit; text-decoration: none; }
.career-nav .home-link { display: inline-flex; align-items: center; gap: 7px; }

.language-switch {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.language-switch a,
.language-switch span {
  display: grid;
  min-width: 34px;
  min-height: 30px;
  place-items: center;
  border: 1px solid transparent;
  border-radius: 999px;
  color: inherit;
  text-decoration: none;
}

.language-switch a:hover {
  border-color: rgba(89, 101, 75, 0.22);
  background: rgba(255, 253, 248, 0.72);
}

.language-switch [aria-current="page"] {
  border-color: rgba(89, 101, 75, 0.18);
  background: #405f50;
  color: white;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 390px);
  gap: 32px;
  align-items: center;
  margin-bottom: 26px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.stage__intro h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
  letter-spacing: -0.035em;
}

h1 {
  margin: 0;
  max-width: 700px;
  font-size: clamp(2.25rem, 4vw, 3.65rem);
  line-height: 1.06;
  font-weight: 680;
  letter-spacing: -0.025em;
}

.lede {
  margin: 14px 0 0;
  max-width: 620px;
  color: var(--muted);
  font-size: clamp(1rem, 1.35vw, 1.16rem);
  line-height: 1.62;
}

.hero-note {
  display: grid;
  gap: 8px;
  padding: 18px 20px 19px;
  border: 1px solid rgba(89, 101, 75, 0.18);
  border-radius: 10px;
  background: rgba(255, 253, 248, 0.72);
  box-shadow: 0 14px 36px rgba(75, 84, 62, 0.07);
}

.hero-note p { margin: 0; color: #4f5747; line-height: 1.58; font-size: 0.94rem; }
.hero-note__label {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.experience {
  overflow: hidden;
  border: 1px solid rgba(48, 60, 55, 0.14);
  border-radius: 28px;
  background: rgba(255, 253, 247, 0.82);
  box-shadow: 0 28px 80px rgba(61, 55, 39, 0.12);
  backdrop-filter: blur(18px);
}

.controls {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(250, 248, 242, 0.85);
}

.control, .speed-control {
  min-height: 40px;
  border: 1px solid rgba(36, 51, 47, 0.15);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.62);
}

.control {
  padding: 0 16px;
  cursor: pointer;
  font-weight: 680;
  transition: transform 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.control:hover { transform: translateY(-1px); box-shadow: 0 7px 20px rgba(45, 61, 54, 0.1); }
.control--primary { min-width: 130px; color: #fff; border-color: #405f50; background: #405f50; }

.speed-control { display: flex; align-items: center; gap: 7px; padding-left: 14px; font-size: 0.82rem; color: var(--muted); }
.speed-control select { border: 0; background: transparent; padding: 0 12px 0 0; color: var(--ink); font-weight: 700; outline: none; }

.status { display: flex; gap: 10px; align-items: baseline; margin-left: auto; }
.status__year { color: #405f50; font-family: Georgia, serif; font-size: 1.7rem; }
.status__chapter { color: var(--muted); font-size: 0.85rem; }

.stage-scroll { overflow-x: auto; overscroll-behavior-x: contain; }
.stage { position: relative; min-width: 1060px; min-height: 720px; padding: 34px 32px 0; overflow: hidden; }
.stage::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.34;
  background-image: radial-gradient(rgba(65, 71, 55, 0.12) 0.65px, transparent 0.65px);
  background-size: 7px 7px;
  mask-image: linear-gradient(to bottom, #000, transparent 52%);
}

.stage__intro { position: relative; z-index: 3; width: min(680px, 64%); min-height: 104px; }
.stage__kicker { margin: 0 0 7px; color: #6c7a71; font-size: 0.76rem; font-weight: 760; letter-spacing: 0.1em; text-transform: uppercase; }
.stage__intro h2 { margin: 0; font-size: clamp(2rem, 3.7vw, 3.7rem); line-height: 1; }
.stage__intro > p:last-child { margin: 9px 0 0; color: var(--muted); }

.stage__legend {
  position: absolute;
  z-index: 3;
  top: 38px;
  right: 32px;
  display: grid;
  grid-template-columns: repeat(2, auto);
  gap: 8px 16px;
  color: var(--muted);
  font-size: 0.72rem;
}
.stage__legend span { display: flex; align-items: center; gap: 7px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.dot--platform { color: var(--platform); }
.dot--identity { color: var(--identity); }
.dot--security { color: var(--security); }
.dot--cloud { color: var(--cloud); }
.dot--ai { color: var(--ai); }

.timeline { position: relative; z-index: 2; height: 66px; margin-top: 12px; margin-left: var(--lane-label); }
.timeline__track { position: absolute; left: 18px; right: 14px; top: 32px; height: 2px; background: #d6d0c5; }
.timeline__progress { position: absolute; inset: 0 auto 0 0; width: 0; background: #54715f; }
.timeline__playhead { position: absolute; z-index: 2; top: -11px; left: 0; width: 24px; height: 24px; border: 2px solid #58765f; border-radius: 50%; background: #fbf8f1; box-shadow: 0 0 0 6px rgba(92, 126, 99, 0.12); transform: translateX(-50%); }
.timeline__playhead::after { content: ""; position: absolute; top: 24px; left: 10px; width: 1px; height: 486px; background: linear-gradient(#789481 0%, rgba(120, 148, 129, 0.15) 80%, transparent); }
.timeline__playhead span { position: absolute; inset: 6px; border-radius: 50%; background: #58765f; }
.timeline__ticks { position: absolute; inset: 0; }
.tick { position: absolute; top: 10px; transform: translateX(-50%); color: #7b817d; font-size: 0.68rem; }
.tick::before { content: ""; position: absolute; left: 50%; top: -10px; width: 1px; height: 6px; background: #aaa69e; }

.lanes { position: relative; z-index: 1; height: 470px; border-top: 1px solid var(--line); }
.lane { position: absolute; left: 0; right: 0; height: 25%; border-bottom: 1px dashed rgba(60, 74, 68, 0.14); }
.lane--focus { top: 0; }
.lane--active { top: 25%; }
.lane--experience { top: 50%; }
.lane--historic { top: 75%; }
.lane::after { content: ""; position: absolute; left: var(--lane-label); right: 0; top: 0; bottom: 0; background: linear-gradient(90deg, rgba(255,255,255,0.38), transparent 38%); }

.lane__label { position: absolute; z-index: 3; top: 16px; left: 0; width: var(--lane-label); padding-right: 18px; text-transform: uppercase; }
.lane__label strong { display: block; color: #405f50; font-size: 0.75rem; letter-spacing: 0.08em; }
.lane__label span { display: block; margin-top: 4px; color: #8b928e; font-size: 0.62rem; text-transform: none; }

.entities { position: absolute; inset: 0 12px 0 var(--lane-label); z-index: 4; pointer-events: none; }
.entity {
  --entity-color: var(--platform);
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 86px;
  max-width: 186px;
  min-height: 38px;
  padding: 8px 11px;
  border: 1px solid color-mix(in srgb, var(--entity-color), transparent 44%);
  border-radius: 12px;
  color: var(--ink);
  background: color-mix(in srgb, var(--entity-color) 6%, #fffdf8);
  box-shadow: 0 9px 24px rgba(57, 58, 44, 0.09);
  transform: translate(-50%, -50%);
  transform-origin: center;
  pointer-events: auto;
  cursor: pointer;
  will-change: transform, opacity, left, top;
}
.entity[hidden] { display: none; }
.entity:hover, .entity:focus-visible { z-index: 9; outline: none; box-shadow: 0 13px 34px rgba(57, 58, 44, 0.18); }
.entity__mark { flex: 0 0 auto; display: grid; place-items: center; width: 19px; height: 19px; border-radius: 6px; color: #fff; background: var(--entity-color); font-size: 0.66rem; font-weight: 800; }
.entity__label { font-size: 0.69rem; font-weight: 720; line-height: 1.15; }
.entity--group { min-width: 164px; min-height: 48px; padding: 10px 13px; border-width: 1.5px; border-radius: 16px; }
.entity--group .entity__label { font-size: 0.78rem; }
.entity--ribbon { min-width: 220px; max-width: none; height: 28px; min-height: 28px; padding: 4px 12px; border-radius: 999px; box-shadow: none; background: color-mix(in srgb, var(--entity-color) 5%, #fffdf8); }
.entity--ribbon .entity__label { font-size: 0.64rem; }
.entity--ribbon::after { content: ""; position: absolute; right: -9px; width: 17px; height: 17px; border-top: 1px solid var(--entity-color); border-right: 1px solid var(--entity-color); transform: rotate(45deg); background: #fffdf8; }
.entity--platform { --entity-color: var(--platform); }
.entity--identity { --entity-color: var(--identity); }
.entity--security { --entity-color: var(--security); }
.entity--cloud { --entity-color: var(--cloud); }
.entity--ai { --entity-color: var(--ai); }

.connections { position: absolute; inset: 0 12px 0 var(--lane-label); z-index: 2; width: calc(100% - var(--lane-label) - 12px); height: 100%; overflow: visible; pointer-events: none; }
.connection { fill: none; stroke-width: 1.35; stroke-linecap: round; opacity: 0.43; }

.event-toast {
  position: absolute;
  z-index: 8;
  right: 30px;
  bottom: 18px;
  max-width: 340px;
  padding: 10px 14px;
  border: 1px solid rgba(79, 103, 89, 0.15);
  border-radius: 12px;
  color: #4f5c56;
  background: rgba(255, 254, 250, 0.92);
  box-shadow: 0 12px 30px rgba(55, 61, 51, 0.1);
  font-size: 0.72rem;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 240ms ease, transform 240ms ease;
}
.event-toast.is-visible { opacity: 1; transform: translateY(0); }

.scrubber { padding: 18px 28px 12px; border-top: 1px solid var(--line); background: rgba(247, 244, 236, 0.72); }
.scrubber label { display: block; margin-bottom: 8px; color: #66716d; font-size: 0.72rem; font-weight: 760; letter-spacing: 0.09em; text-transform: uppercase; }
.scrubber input { width: 100%; accent-color: #4d6b59; cursor: ew-resize; }
.scrubber__years { display: flex; justify-content: space-between; margin-top: 3px; color: #969b98; font-size: 0.62rem; }
.hint { padding: 12px 28px 20px; color: #777f7b; background: rgba(247, 244, 236, 0.72); font-size: 0.75rem; }
.hint span { margin-right: 7px; color: #415f50; font-weight: 800; text-transform: uppercase; }

.personal-summary {
  width: min(920px, 100%);
  margin: clamp(34px, 5vw, 64px) auto 0;
  padding: 0 clamp(10px, 2vw, 22px);
  text-align: center;
}

.personal-summary h2 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.8rem, 3.2vw, 3rem);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.08;
}

.personal-summary > p:last-child {
  max-width: 780px;
  margin: 16px auto 0;
  color: var(--muted);
  font-size: clamp(0.96rem, 1.3vw, 1.08rem);
  line-height: 1.68;
}

.detail-panel {
  position: fixed;
  z-index: 30;
  right: clamp(16px, 3vw, 46px);
  bottom: clamp(16px, 3vw, 46px);
  width: min(410px, calc(100vw - 32px));
  max-height: min(760px, calc(100vh - 32px));
  overflow-y: auto;
  padding: 26px;
  border: 1px solid rgba(46, 61, 55, 0.15);
  border-radius: 22px;
  background: rgba(255, 253, 247, 0.97);
  box-shadow: 0 26px 90px rgba(45, 48, 39, 0.25);
  opacity: 0;
  pointer-events: none;
  transform: translateY(16px) scale(0.98);
  transition: 220ms ease;
}
.detail-panel.is-open { opacity: 1; pointer-events: auto; transform: none; }
.detail-panel__close { position: absolute; top: 10px; right: 12px; border: 0; background: transparent; font-size: 1.6rem; cursor: pointer; }
.detail-panel__type { margin: 0 0 7px; color: #718076; font-size: 0.7rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; }
.detail-panel h2 { margin: 0 0 12px; font-family: Georgia, serif; font-size: 1.8rem; font-weight: 500; }
.detail-panel > p:not(.detail-panel__type) { color: #59635e; line-height: 1.55; }
.detail-panel__visual { margin: 18px 0 0; overflow: hidden; border: 1px solid rgba(46, 61, 55, 0.12); border-radius: 15px; background: #eee9df; }
.detail-panel__visual[hidden] { display: none; }
.detail-panel__visual img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.detail-panel__visual figcaption { padding: 8px 10px; color: #737c77; font-size: 0.64rem; line-height: 1.35; }
.detail-panel__meta { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 18px; }
.detail-panel__meta span { padding: 6px 9px; border-radius: 999px; color: #55615b; background: #efebe2; font-size: 0.68rem; font-weight: 700; }

@media (max-width: 860px) {
  .page-shell { padding: 18px 12px 34px; }
  .site-header { align-items: flex-start; flex-direction: column; margin-bottom: 30px; }
  .hero { grid-template-columns: 1fr; gap: 20px; }
  .hero-note { display: none; }
  .experience { border-radius: 20px; }
  .controls { flex-wrap: wrap; }
  .status { width: 100%; margin: 2px 0 0; padding-left: 3px; }
  .stage { min-width: 980px; }
  .stage-scroll::after { content: "← horizontal bewegen →"; position: sticky; left: 12px; display: inline-block; margin: 0 0 8px; padding: 5px 9px; border-radius: 999px; color: #6b746f; background: rgba(255,255,255,.9); font-size: .65rem; }
}

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