/* Заглушка ikarasev.com: тёмный «кинозал», портрет растворяется в черноте, внизу — таймлайн монтажа */

:root {
  --bg: #050505;
  --text: #f1efe9;
  --muted: #9d9a92;
  --dim: #5f5d58;
  --line: rgba(255, 255, 255, 0.1);
  --accent: #e8483c;
  --clip: #3a3a3a;
  --clip-hi: #6b6b6b;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 Manrope, 'Segoe UI', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  min-height: 100svh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  overflow-x: hidden;
}

a {
  color: inherit;
}

/* ---------- Зерно плёнки и уголки видоискателя ---------- */

.grain {
  position: fixed;
  inset: -50%;
  z-index: 5;
  pointer-events: none;
  opacity: 0.07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 0.9s steps(4) infinite;
}

@keyframes grain {
  0% { transform: translate(0, 0); }
  25% { transform: translate(-3%, 2%); }
  50% { transform: translate(2%, -3%); }
  75% { transform: translate(-2%, -1%); }
  100% { transform: translate(1%, 3%); }
}

.frame {
  position: fixed;
  inset: 18px;
  z-index: 4;
  pointer-events: none;
}

.frame i {
  position: absolute;
  width: 26px;
  height: 26px;
  border: 0 solid rgba(255, 255, 255, 0.35);
}

.frame i:nth-child(1) { top: 0; left: 0; border-width: 1.5px 0 0 1.5px; }
.frame i:nth-child(2) { top: 0; right: 0; border-width: 1.5px 1.5px 0 0; }
.frame i:nth-child(3) { bottom: 0; left: 0; border-width: 0 0 1.5px 1.5px; }
.frame i:nth-child(4) { bottom: 0; right: 0; border-width: 0 1.5px 1.5px 0; }

/* ---------- Верхняя строка: REC и таймкод ---------- */

.bar {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 34px 52px 0;
  font: 500 13px/1 'JetBrains Mono', ui-monospace, monospace;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.rec {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.rec b {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent);
  animation: blink 1.6s ease-in-out infinite;
}

@keyframes blink {
  50% { opacity: 0.15; }
}

.tc {
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.lang {
  margin-left: auto;
  font: inherit;
  color: var(--muted);
  background: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 11px;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}

.lang:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.3);
}

/* ---------- Портрет и текст ---------- */

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  min-height: 0;
}

.photo {
  margin: 0;
  position: absolute;
  inset: 0 0 0 auto;
  width: min(58vw, 900px);
  height: 100%;
  z-index: 0;
}

.photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 40% 22%;
  display: block;
  /* Портрет растворяется в черноте к тексту и к таймлайну */
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 34%), linear-gradient(to bottom, transparent 0%, #000 14%, #000 76%, transparent 100%);
  mask-image: linear-gradient(to right, transparent 0%, #000 34%), linear-gradient(to bottom, transparent 0%, #000 14%, #000 76%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
  filter: contrast(1.04);
  animation: reveal 2.4s ease-out both;
}

@keyframes reveal {
  from { opacity: 0; transform: scale(1.04); }
  to { opacity: 1; transform: none; }
}

.text {
  position: relative;
  z-index: 2;
  padding: 12px 0 12px 52px;
  max-width: 640px;
  animation: rise 1.4s 0.3s ease-out both;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

.slate {
  margin: 0 0 18px;
  font: 500 12px/1 'JetBrains Mono', ui-monospace, monospace;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--dim);
}

h1 {
  margin: 0;
  font: 600 clamp(54px, min(8.6vw, 15vh), 128px)/0.92 Oswald, 'Arial Narrow', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.01em;
}

h1 span {
  display: block;
}

.role {
  margin: 22px 0 0;
  font: 500 clamp(15px, 1.5vw, 19px)/1.3 'JetBrains Mono', ui-monospace, monospace;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text);
}

.role::before {
  content: '';
  display: inline-block;
  width: 34px;
  height: 2px;
  margin: 0 14px 0.3em 0;
  vertical-align: middle;
  background: var(--accent);
}

.lead {
  margin: clamp(14px, 2.4vh, 22px) 0 0;
  max-width: 470px;
  color: var(--muted);
  font-size: 17px;
}

.links {
  margin-top: clamp(18px, 3.4vh, 34px);
  display: grid;
  gap: 10px;
  max-width: 420px;
}

.link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 11px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.025);
  backdrop-filter: blur(6px);
  transition: border-color 0.2s, background 0.2s, transform 0.2s;
}

.link:hover {
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.06);
  transform: translateX(3px);
}

.link.primary {
  border-color: rgba(232, 72, 60, 0.55);
}

.link.primary:hover {
  border-color: var(--accent);
}

.link > svg,
.link > img {
  flex: none;
  color: var(--text);
  border-radius: 5px;
}

.link span {
  display: grid;
  line-height: 1.35;
}

.link b {
  font-weight: 700;
  font-size: 15px;
}

.link small {
  color: var(--muted);
  font-size: 13px;
}

/* ---------- Таймлайн монтажа ---------- */

.timeline {
  position: relative;
  z-index: 3;
  padding: 0 52px 28px;
}

.tl-head {
  display: flex;
  justify-content: space-between;
  font: 500 11.5px/1 'JetBrains Mono', ui-monospace, monospace;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim);
  margin-bottom: 10px;
}

.tl-status {
  color: var(--accent);
}

.tracks {
  position: relative;
  display: grid;
  gap: 5px;
  padding-top: 4px;
}

.track {
  display: grid;
  grid-template-columns: 30px 1fr;
  align-items: center;
  gap: 8px;
}

.track em {
  font: 500 10.5px/1 'JetBrains Mono', ui-monospace, monospace;
  font-style: normal;
  color: var(--dim);
}

.lane {
  position: relative;
  height: 16px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.03);
}

.lane i {
  position: absolute;
  top: 0;
  bottom: 0;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--clip-hi), var(--clip));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.audio .lane i {
  background: repeating-linear-gradient(90deg, rgba(232, 72, 60, 0.55) 0 2px, rgba(232, 72, 60, 0.25) 2px 4px);
}

.playhead {
  position: absolute;
  top: -6px;
  bottom: -4px;
  left: 38px;
  width: 1.5px;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent);
  animation: play 22s linear infinite;
}

.playhead::before {
  content: '';
  position: absolute;
  top: 0;
  left: -5px;
  border: 6px solid transparent;
  border-top-color: var(--accent);
  border-bottom: 0;
}

@keyframes play {
  from { left: 38px; }
  to { left: 100%; }
}

.copy {
  margin: 12px 0 0;
  font-size: 12.5px;
  color: var(--dim);
}

@media (prefers-reduced-motion: reduce) {
  .grain,
  .rec b,
  .playhead,
  .photo img,
  .text {
    animation: none;
  }
}

/* ---------- Телефон и узкие экраны ---------- */

@media (max-width: 820px) {
  .bar {
    padding: 26px 24px 0;
  }
  .hero {
    grid-template-columns: 1fr;
    align-items: end;
  }
  .photo {
    position: relative;
    inset: auto;
    width: 100%;
    height: 62svh;
    grid-row: 1;
    margin-top: -60px;
  }
  .photo img {
    object-position: 45% 18%;
    -webkit-mask-image: linear-gradient(to top, transparent 0%, #000 40%);
    mask-image: linear-gradient(to top, transparent 0%, #000 40%);
  }
  .text {
    grid-row: 2;
    margin-top: -22svh;
    padding: 0 24px 32px;
  }
  .lead {
    font-size: 16px;
  }
  .links {
    max-width: none;
  }
  .timeline {
    padding: 0 24px 26px;
  }
  .frame {
    inset: 10px;
  }
}
