:root {
  --bg: #0B0B0D;
  --bg-2: #111114;
  --panel: #16161A;
  --panel-2: #1D1D22;
  --line: #26262C;
  --line-2: #34343C;
  --text: #ECECEE;
  --muted: #9A9AA3;
  --faint: #6E6E77;
  --rec: #FF3B30;
  --rec-dim: #8E1F1A;
  --team: #3A3A43;
  --ok: #7CD992;

  --f-display: 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --f-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-mono: 'JetBrains Mono', ui-monospace, Consolas, monospace;

  --gutter: clamp(16px, 4vw, 40px);
  --max: 1200px;
  --radius: 6px;
  --header-h: 64px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 400 16px/1.6 var(--f-body);
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; }
p { margin: 0; }
ul { list-style: none; margin: 0; padding: 0; }
:focus-visible { outline: 2px solid var(--rec); outline-offset: 3px; border-radius: 2px; }

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.tc { font: 500 12px/1.4 var(--f-mono); letter-spacing: .04em; color: var(--muted); text-transform: uppercase; }
.src { font-size: 12px; color: var(--faint); margin-top: 10px; }
.link { color: var(--text); text-decoration: none; border-bottom: 1px solid var(--line-2); padding-bottom: 1px; transition: border-color .2s, color .2s; }
.link:hover { border-color: var(--rec); color: #fff; }

.skip { position: absolute; left: -9999px; top: 8px; background: var(--rec); color: #fff; padding: 8px 12px; z-index: 100; border-radius: 4px; }
.skip:focus { left: 8px; }

/* ---------- Header / timeline nav ---------- */
.top { position: sticky; top: 0; z-index: 50; background: rgba(11, 11, 13, .86); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.top__bar { height: var(--header-h); display: flex; align-items: center; gap: 24px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; }
.brand__rec { width: 10px; height: 10px; border-radius: 50%; background: var(--rec); box-shadow: 0 0 0 4px rgba(255, 59, 48, .18); animation: rec 1.6s ease-in-out infinite; }
.brand__name { font: 700 22px/1 var(--f-display); letter-spacing: .02em; text-transform: uppercase; }
@keyframes rec { 50% { opacity: .35; } }

.nav { display: flex; gap: 4px; margin-left: auto; }
.nav a { display: flex; align-items: baseline; gap: 6px; padding: 8px 10px; text-decoration: none; font-size: 14px; color: var(--muted); border-radius: 4px; transition: color .2s, background .2s; white-space: nowrap; }
.nav a:hover { color: var(--text); background: var(--panel); }
.nav a.is-active { color: var(--text); }
.nav a.is-active .nav__tc { color: var(--rec); }
.nav__tc { font: 500 11px var(--f-mono); color: var(--faint); }
.lang { border: 1px solid var(--line-2); background: transparent; padding: 6px 10px; border-radius: 4px; font: 500 12px var(--f-mono); cursor: pointer; min-width: 44px; min-height: 36px; }
.lang:hover { border-color: var(--text); }

.ruler {
  position: relative; height: 10px; border-top: 1px solid var(--line);
  background-image: repeating-linear-gradient(90deg, var(--line-2) 0 1px, transparent 1px 12px), repeating-linear-gradient(90deg, var(--faint) 0 1px, transparent 1px 120px);
  background-size: auto 4px, auto 8px; background-repeat: repeat-x; background-position: 0 0, 0 0;
}
.ruler__head { position: absolute; top: -1px; bottom: -1px; left: 0; width: 2px; background: var(--rec); transform: translateX(0); will-change: transform; }
.ruler__head::before { content: ''; position: absolute; top: 0; left: -4px; border: 5px solid transparent; border-top-color: var(--rec); }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 10px 18px; border: 1px solid var(--line-2); border-radius: var(--radius); text-decoration: none; font-weight: 500; font-size: 15px; transition: border-color .2s, background .2s, transform .15s; cursor: pointer; background: transparent; }
.btn:hover { border-color: var(--text); }
.btn:active { transform: translateY(1px); }
.btn--rec { background: var(--rec); border-color: var(--rec); color: #fff; }
.btn--rec:hover { background: #ff5247; border-color: #ff5247; }

/* ---------- Hero ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(28px, 5vw, 64px); align-items: center; padding-block: clamp(40px, 8vw, 96px) clamp(48px, 7vw, 88px); }
.hero__title { font: 700 clamp(48px, 7.4vw, 96px)/.9 var(--f-display); text-transform: uppercase; letter-spacing: -.01em; margin: 14px 0 20px; text-wrap: balance; }
.hero__title em { font-style: normal; color: var(--rec); }
.hero__lead { color: var(--muted); font-size: clamp(16px, 1.6vw, 18px); max-width: 52ch; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin: 36px 0 0; border-top: 1px solid var(--line); }
.stats div { padding: 14px 12px 0 0; display: flex; flex-direction: column; gap: 4px; }
.stats dd { order: -1; }
.stats div + div { padding-left: 12px; border-left: 1px solid var(--line); }
.stats dt { font-size: 12px; color: var(--muted); line-height: 1.3; }
.stats dd { margin: 0; font: 700 clamp(28px, 3.2vw, 40px)/1 var(--f-display); }

.monitor { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 10px; }
.monitor__top { display: flex; justify-content: space-between; padding: 2px 4px 10px; }
.monitor__top .tc:first-child::before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--rec); margin-right: 8px; vertical-align: 1px; }
.hero__reel figcaption { margin-top: 12px; text-transform: none; }
.hero__reel { margin: 0; }

/* ---------- Player (lite YouTube) ---------- */
.player { position: relative; aspect-ratio: 16 / 9; background: #000; border-radius: 4px; overflow: hidden; }
.player img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease, opacity .3s; }
.player iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.player__btn { position: absolute; inset: 0; display: grid; place-items: center; border: 0; background: linear-gradient(180deg, transparent 55%, rgba(0, 0, 0, .55)); cursor: pointer; padding: 0; }
.player__btn::before { content: ''; width: 68px; height: 68px; border-radius: 50%; background: var(--rec); box-shadow: 0 8px 30px rgba(255, 59, 48, .35); transition: transform .2s; }
.player__btn::after { content: ''; position: absolute; left: 50%; top: 50%; transform: translate(-35%, -50%); border-style: solid; border-width: 11px 0 11px 18px; border-color: transparent transparent transparent #fff; }
.player:hover img { transform: scale(1.02); }
.player:hover .player__btn::before { transform: scale(1.08); }
.player__label { position: absolute; left: 12px; bottom: 10px; right: 12px; font: 500 12px var(--f-mono); color: #fff; text-shadow: 0 1px 4px rgba(0, 0, 0, .8); pointer-events: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- Sections ---------- */
.section { padding-block: clamp(56px, 9vw, 112px); border-top: 1px solid var(--line); }
.section--alt { background: var(--bg-2); }
.sec-head { max-width: 760px; margin-bottom: clamp(24px, 4vw, 40px); }
.sec-head h2 { font: 700 clamp(36px, 5vw, 60px)/.95 var(--f-display); text-transform: uppercase; margin: 10px 0 14px; text-wrap: balance; }
.sec-head__lead { color: var(--muted); max-width: 64ch; }
.mini-h { font: 500 12px/1.4 var(--f-mono); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 22px 0 10px; }

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 8px; margin-bottom: 18px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.tabs::-webkit-scrollbar { display: none; }
.tab { flex-shrink: 0; border: 1px solid var(--line-2); background: transparent; border-radius: var(--radius); padding: 10px 14px; cursor: pointer; text-align: left; min-height: 44px; transition: border-color .2s, background .2s; }
.tab:hover { border-color: var(--muted); }
.tab[aria-selected="true"] { border-color: var(--rec); background: rgba(255, 59, 48, .08); }
.tab b { display: block; font: 700 18px/1.1 var(--f-display); text-transform: uppercase; }
.tab span { font: 400 11px var(--f-mono); color: var(--muted); }

/* ---------- Series ---------- */
.series { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: clamp(20px, 3vw, 36px); align-items: start; }
.series__now { margin-top: 14px; }
.series__ep { font: 600 18px/1.3 var(--f-body); margin-bottom: 4px; }
.series__side { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 18px; }
.series__side .mini-h:first-of-type { margin-top: 18px; }
.series__facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 0; }
.series__facts div { display: flex; flex-direction: column-reverse; }
.series__facts dt { font-size: 11px; color: var(--muted); }
.series__facts dd { margin: 0; font: 700 26px/1 var(--f-display); }

.days { display: grid; grid-template-columns: repeat(auto-fill, minmax(34px, 1fr)); gap: 4px; }
.day { aspect-ratio: 1; min-height: 34px; border: 1px solid var(--line-2); background: var(--panel-2); border-radius: 3px; cursor: pointer; font: 500 11px var(--f-mono); color: var(--muted); padding: 0; position: relative; transition: background .15s, border-color .15s, color .15s; }
.day:hover { border-color: var(--text); color: var(--text); }
.day[aria-pressed="true"] { background: var(--rec); border-color: var(--rec); color: #fff; }
.day.is-verified::after { content: ''; position: absolute; top: 3px; right: 3px; width: 5px; height: 5px; border-radius: 50%; background: var(--ok); }
.days-note { font-size: 12px; color: var(--faint); margin-top: 8px; display: flex; align-items: center; gap: 6px; }
.days-note::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--ok); flex-shrink: 0; }

/* ---------- Contribution lanes ---------- */
.lanes { display: grid; gap: 6px; }
.lane { display: grid; grid-template-columns: minmax(0, 11em) minmax(0, 1fr); gap: 10px; align-items: center; }
.lane__label { font-size: 13px; color: var(--text); line-height: 1.25; }
.lane__label small { display: block; font: 400 11px var(--f-mono); color: var(--faint); }
.lane__track { position: relative; height: 16px; background: var(--panel-2); border-radius: 2px; overflow: hidden; border: 1px solid var(--line); }
.lane__clip { position: absolute; top: 0; bottom: 0; border-radius: 1px; }
.lane__clip--me { background: var(--rec); }
.lane__clip--partial { background: repeating-linear-gradient(135deg, var(--rec) 0 5px, var(--rec-dim) 5px 10px); }
.lane__clip--team { background: var(--team); }
.lane__tick { position: absolute; top: -1px; bottom: -1px; width: 1px; background: var(--text); }
.lane__time { font: 400 11px var(--f-mono); color: var(--faint); display: flex; justify-content: space-between; margin: 2px 0 0 calc(11em + 10px); }

.legend { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 22px; text-transform: none; }
.legend > span { display: inline-flex; align-items: center; gap: 6px; }
.sw { display: inline-block; width: 18px; height: 10px; border-radius: 2px; }
.sw--me { background: var(--rec); }
.sw--partial { background: repeating-linear-gradient(135deg, var(--rec) 0 4px, var(--rec-dim) 4px 8px); }
.sw--team { background: var(--team); }

/* ---------- Filters & grid ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.chip { border: 1px solid var(--line-2); background: transparent; border-radius: 999px; padding: 8px 14px; font-size: 14px; cursor: pointer; min-height: 40px; color: var(--muted); transition: all .2s; }
.chip:hover { color: var(--text); border-color: var(--muted); }
.chip.is-on { color: #fff; background: var(--panel-2); border-color: var(--text); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 18px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; display: flex; flex-direction: column; transition: border-color .2s, transform .2s; }
.card:hover { border-color: var(--line-2); transform: translateY(-2px); }
.card[hidden] { display: none; }
.card__open { all: unset; cursor: pointer; display: flex; flex-direction: column; height: 100%; }
.card__open:focus-visible { outline: 2px solid var(--rec); outline-offset: -2px; }
.card__thumb { position: relative; aspect-ratio: 16 / 9; background: #000; overflow: hidden; }
.card__thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card__thumb img { transform: scale(1.04); }
.card__dur { position: absolute; right: 8px; bottom: 8px; background: rgba(0, 0, 0, .8); font: 500 11px var(--f-mono); padding: 2px 6px; border-radius: 3px; }
.card__views { position: absolute; left: 8px; bottom: 8px; background: rgba(0, 0, 0, .8); font: 500 11px var(--f-mono); padding: 2px 6px; border-radius: 3px; }
.card__lang { position: absolute; left: 8px; top: 8px; background: var(--text); color: var(--bg); font: 600 11px var(--f-mono); padding: 2px 6px; border-radius: 3px; }
.card__body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card__client { font: 500 12px var(--f-mono); color: var(--muted); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; text-transform: uppercase; }
.card__title { font: 600 16px/1.3 var(--f-body); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card__mini { display: flex; gap: 3px; margin-top: auto; padding-top: 4px; }
.card__mini i { height: 6px; flex: 1; border-radius: 1px; }

.badge { display: inline-flex; align-items: center; gap: 5px; font: 500 11px/1 var(--f-mono); padding: 4px 7px; border-radius: 3px; border: 1px solid var(--line-2); color: var(--muted); text-transform: none; white-space: nowrap; }
.badge--ok { color: var(--ok); border-color: rgba(124, 217, 146, .35); }
.badge--ok::before { content: '✓'; }
.badge--role { color: var(--text); }
.badges { display: flex; flex-wrap: wrap; gap: 6px; }

/* ---------- Sheet (dialog) ---------- */
.sheet { width: min(980px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); padding: 0; border: 1px solid var(--line-2); border-radius: 10px; background: var(--panel); color: var(--text); overflow: auto; }
.sheet::backdrop { background: rgba(0, 0, 0, .75); backdrop-filter: blur(4px); }
.sheet[open] { animation: sheetIn .25s ease; }
@keyframes sheetIn { from { opacity: 0; transform: translateY(12px); } }
.sheet__inner { position: relative; }
.sheet .player { border-radius: 0; }
.sheet__close { position: absolute; top: 10px; right: 10px; z-index: 3; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-2); background: rgba(11, 11, 13, .85); cursor: pointer; font-size: 16px; }
.sheet__close:hover { border-color: var(--text); }
.sheet__body { padding: clamp(18px, 3vw, 28px); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; }
.sheet__title { font: 700 clamp(26px, 3vw, 34px)/1 var(--f-display); text-transform: uppercase; margin: 8px 0 12px; }
.sheet__meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font: 400 12px var(--f-mono); color: var(--muted); margin-bottom: 12px; }
.quote { margin: 16px 0 0; padding: 14px 16px; border-left: 2px solid var(--rec); background: var(--panel-2); font-size: 15px; }
.quote cite { display: block; margin-top: 8px; font: 400 11px var(--f-mono); color: var(--faint); font-style: normal; }
.sheet__links { display: flex; flex-wrap: wrap; gap: 10px 16px; margin-top: 16px; font-size: 14px; }
.sheet__note { margin-top: 14px; font-size: 13px; color: var(--muted); }

/* ---------- Motion ---------- */
.motion { display: grid; gap: 18px; }
.motion__feature { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: clamp(18px, 3vw, 32px); background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 14px; align-items: start; }
.motion__feature h3 { font: 700 26px/1 var(--f-display); text-transform: uppercase; margin: 8px 0 10px; }
.motion__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 14px; }
.mg { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 8px; }
.mg__frame { position: relative; aspect-ratio: 16 / 9; border-radius: 4px; overflow: hidden; background:
  radial-gradient(circle at 20% 30%, rgba(255, 59, 48, .25), transparent 40%),
  repeating-linear-gradient(90deg, var(--line) 0 1px, transparent 1px 24px), var(--panel-2); }
.mg__frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.mg__load { position: absolute; inset: 0; display: grid; place-items: center; background: transparent; border: 0; cursor: pointer; font: 500 12px var(--f-mono); color: var(--text); text-transform: uppercase; }
.mg__load span { border: 1px solid var(--line-2); padding: 10px 14px; border-radius: 4px; background: rgba(11, 11, 13, .7); transition: border-color .2s; }
.mg__load:hover span { border-color: var(--rec); }
.mg p { margin: 8px 4px 2px; }
.motion__more { margin-top: 20px; }

/* ---------- Clients ---------- */
.clients { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(20px, 4vw, 48px); align-items: start; }
.clients__list { border-top: 1px solid var(--line); }
.client { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.client__name { font: 700 22px/1.1 var(--f-display); text-transform: uppercase; }
.client__name small { display: block; font: 400 12px var(--f-mono); color: var(--muted); text-transform: none; margin-top: 3px; }
.client__count { font: 500 12px var(--f-mono); color: var(--muted); text-align: right; }
.review { margin: 0; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 24px; position: sticky; top: calc(var(--header-h) + 24px); }
.review blockquote { margin: 12px 0 16px; font: 700 clamp(28px, 3vw, 38px)/1.02 var(--f-display); text-transform: uppercase; }
.review blockquote::before { content: '“'; color: var(--rec); }
.review blockquote::after { content: '”'; color: var(--rec); }
.review figcaption { font-size: 14px; color: var(--muted); }
.review figcaption b { color: var(--text); font-weight: 600; }
.stars { color: var(--rec); letter-spacing: 2px; font-size: 14px; }

/* ---------- Contact ---------- */
.contact { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); }
.contact__title { font: 700 clamp(40px, 6vw, 76px)/.92 var(--f-display); text-transform: uppercase; margin: 10px 0 16px; text-wrap: balance; }
.contact__title em { font-style: normal; color: var(--rec); }
.about p { color: var(--muted); }
.about .mini-h:first-child { margin-top: 0; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags li { border: 1px solid var(--line-2); border-radius: 3px; padding: 4px 8px; font: 400 12px var(--f-mono); color: var(--muted); }

.foot { display: flex; justify-content: space-between; gap: 12px; padding-block: 28px 40px; border-top: 1px solid var(--line); }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero, .series, .clients, .contact, .motion__feature { grid-template-columns: minmax(0, 1fr); }
  .review { position: static; }
  .nav a { padding: 8px 8px; }
  .nav__tc { display: none; }
}
@media (max-width: 720px) {
  :root { --header-h: 104px; }
  .top__bar { flex-wrap: wrap; height: auto; padding-block: 10px 0; gap: 8px 12px; }
  .brand { order: 1; }
  .lang { order: 2; margin-left: auto; }
  .nav { order: 3; width: calc(100% + var(--gutter) * 2); margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter) 6px; overflow-x: auto; scrollbar-width: none; }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { padding: 10px 10px; min-height: 44px; align-items: center; }
  .nav a:first-child { padding-left: 0; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats div:nth-child(3) { padding-left: 0; border-left: 0; }
  .stats div:nth-child(n+3) { border-top: 1px solid var(--line); margin-top: 12px; }
  .sheet__body { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .lane { grid-template-columns: minmax(0, 9em) minmax(0, 1fr); }
  .lane__time { margin-left: calc(9em + 10px); }
  .client { grid-template-columns: minmax(0, 1fr) auto; }
  .client__count { grid-column: 1 / -1; text-align: left; margin-top: -6px; }
  .foot { flex-direction: column; }
  .player__btn::before { width: 56px; height: 56px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}
