/* Шрифты лежат на самом сайте (без Google Fonts). Только латиница — главная на английском. */
@font-face {
  font-family: 'Inter Tight';
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-tight-latin-ext-wght-normal.woff2) format('woff2-variations');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}
@font-face {
  font-family: 'Inter Tight';
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-tight-latin-wght-normal.woff2) format('woff2-variations');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-display: swap;
  font-weight: 100 800;
  src: url(/fonts/jetbrains-mono-latin-ext-wght-normal.woff2) format('woff2-variations');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-display: swap;
  font-weight: 100 800;
  src: url(/fonts/jetbrains-mono-latin-wght-normal.woff2) format('woff2-variations');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

:root {
  --fg: #ecebe8; --muted: rgba(236, 235, 232, .38); --silver: #8d8f94; --blue: #2f7bff;
  --mono: 'JetBrains Mono', ui-monospace, monospace; --display: 'Inter Tight', system-ui, sans-serif;
  --mx: 50vw; --my: 45vh; --r: 230px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { background: #000; color: var(--fg); height: 100%; overflow: hidden; -webkit-font-smoothing: antialiased; }
body { font-family: var(--mono); font-weight: 300; font-size: 11px; letter-spacing: .14em; text-transform: lowercase; }
a, button { color: inherit; text-decoration: none; font: inherit; letter-spacing: inherit; text-transform: inherit; background: none; border: 0; cursor: pointer; }
::selection { background: var(--blue); color: #fff; }

/* луч света за курсором — нейтральный, холодно-белый */
.light {
  position: fixed; inset: 0; pointer-events: none;
  background: radial-gradient(circle calc(var(--r) * 1.9) at var(--mx) var(--my), rgba(225, 232, 255, .06), rgba(225, 232, 255, .012) 45%, transparent 70%);
}

/* две одинаковые сцены: тусклая и освещённая; освещённая видна только в круге света */
.scene { position: fixed; inset: 0; display: grid; place-content: center; text-align: center; pointer-events: none; }
.word {
  font-family: var(--display); font-weight: 800; font-size: clamp(3.4rem, 15.5vw, 17rem);
  letter-spacing: -.045em; line-height: .85; text-transform: none;
}
.word.xl { font-size: clamp(9rem, 40vw, 34rem); letter-spacing: -.06em; }
.line { margin-top: 2.2rem; font-size: clamp(10px, 1vw, 13px); letter-spacing: .5em; }
.dim { color: #0b0b0b; }
.dim .line { color: #111; }
.lit {
  color: var(--fg);
  -webkit-mask-image: radial-gradient(circle var(--r) at var(--mx) var(--my), #000 0%, rgba(0, 0, 0, .4) 40%, transparent 78%);
  mask-image: radial-gradient(circle var(--r) at var(--mx) var(--my), #000 0%, rgba(0, 0, 0, .4) 40%, transparent 78%);
}
.lit .word { background: linear-gradient(180deg, #fff 20%, #a9adb5); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lit .line { color: var(--blue); text-shadow: 0 0 14px rgba(47, 123, 255, .45); }

.grain {
  position: fixed; inset: -50%; pointer-events: none; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1s steps(6) infinite;
}
@keyframes grain { 0%,100% { transform: translate(0,0); } 33% { transform: translate(-4%,3%); } 66% { transform: translate(3%,-5%); } }

/* углы */
.corner { position: fixed; z-index: 5; color: var(--muted); }
.tl { top: max(28px, env(safe-area-inset-top)); left: 32px; color: var(--fg); font-weight: 400; letter-spacing: .3em; text-transform: uppercase; }
.tr { top: max(28px, env(safe-area-inset-top)); right: 32px; font-variant-numeric: tabular-nums; text-transform: uppercase; }
.bl { bottom: calc(28px + env(safe-area-inset-bottom)); left: 32px; }
.br { bottom: calc(28px + env(safe-area-inset-bottom)); right: 32px; transition: color .4s, text-shadow .4s; }
.br:hover { color: var(--blue); text-shadow: 0 0 18px rgba(47, 123, 255, .6); }

/* индекс файлов */
.index {
  position: fixed; z-index: 5; left: 50%; bottom: calc(14vh + env(safe-area-inset-bottom)); transform: translateX(-50%);
  display: flex; flex-direction: column; gap: .2rem; width: min(420px, 84vw);
}
.file { display: grid; grid-template-columns: 3.4em 1fr auto 1.4em; gap: 1em; align-items: center; padding: .7em 0; text-align: left; border-top: 1px solid rgba(255, 255, 255, .06); color: var(--muted); transition: color .4s; }
.file:last-child { border-bottom: 1px solid rgba(255, 255, 255, .06); }
.file .name { transition: color .4s, text-shadow .4s; color: var(--fg); text-transform: uppercase; letter-spacing: .3em; }
.file .go { text-align: right; }
/* электрический синий вспыхивает только при наведении */
a.file:hover { color: var(--blue); }
a.file:hover .name { color: var(--blue); text-shadow: 0 0 18px rgba(47, 123, 255, .65); }
.file .redacted { color: #1d1d1d; letter-spacing: 0; }
.locked { cursor: not-allowed; }
.locked.denied .state { color: #ff4d3a; }

/* появление: всё проступает из тьмы */
.corner, .index { opacity: 0; animation: in 2.4s 1s cubic-bezier(.2, .8, .2, 1) forwards; }
.index { animation-delay: 1.6s; }
@keyframes in { to { opacity: 1; } }
.corner.br, .corner.bl { animation-delay: 2s; }

@media (max-width: 700px) {
  :root { --r: 150px; }
  .tl, .bl { left: 20px; } .tr, .br { right: 20px; }
  .bl { display: none; }
  .line { letter-spacing: .3em; padding: 0 1rem; }
  .index { bottom: calc(12vh + env(safe-area-inset-bottom)); }
}
@media (prefers-reduced-motion: reduce) {
  .lit { -webkit-mask-image: none; mask-image: none; }
  .grain { animation: none; }
}
