/* rusadze.com — brutalist line grid. Tokens first, then sections top → bottom. */
:root {
  --ink: #0d0d0d;
  --paper: #fff;
  --mist: #efefef;
  --ac: #2B2BFF;
  --lime: #EAFF00;
  --hdr: 64px;
  --pad: clamp(20px, 3.4vw, 56px);
  --display: 'Roboto Flex', 'Arial Black', Arial, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, Menlo, monospace;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: var(--hdr); }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 18px/1.5 var(--display); font-stretch: 100%;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, p, figure, blockquote { margin: 0; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
:focus-visible { outline: 3px solid var(--ac); outline-offset: 2px; }
::selection { background: var(--ac); color: #fff; }

.mono { font-family: var(--mono); font-style: italic; font-size: 13px; letter-spacing: .02em; line-height: 1.4; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: fixed; left: 8px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 12px 16px; }
.skip:focus { top: 8px; }
.display {
  font-family: var(--display); font-weight: 1000; font-stretch: 151%;
  text-transform: uppercase; line-height: .9; letter-spacing: -.01em;
}
.arr { width: .9em; height: .9em; flex: none; transition: transform .25s ease; }

/* the 1px line system: a grid paints its gaps in ink */
.grid { display: grid; gap: 1px; background: var(--ink); }
.cell { background: var(--paper); min-width: 0; }
.fill, .fill img { display: block; width: 100%; height: 100%; }
.fill img, .cm img, .ev img, .md img { object-fit: cover; }

/* ---------- header ---------- */
.top {
  position: sticky; top: 0; z-index: 40; height: var(--hdr);
  display: grid; grid-template-columns: auto 1fr auto auto var(--hdr); gap: 1px;
  background: var(--ink); border-bottom: 1px solid var(--ink);
}
.top > * { background: var(--paper); display: flex; align-items: center; }
.brand { background: var(--ac); color: #fff; gap: 12px; padding: 0 22px 0 18px; }
.brand .mk {
  display: grid; place-items: center; width: 34px; height: 34px; background: #fff; color: var(--ac);
  font-weight: 1000; font-stretch: 151%; font-size: 14px; letter-spacing: -.02em;
}
.brand .bn { font-weight: 1000; font-stretch: 151%; text-transform: uppercase; font-size: 18px; letter-spacing: .01em; }
.ticker { overflow: hidden; white-space: nowrap; }
.tk, .bd { display: flex; width: max-content; animation: mq 48s linear infinite; }
.tk span, .tk i { font: italic 400 13px var(--mono); padding: 0 18px; }
.tk i { padding: 0; color: var(--ac); font-style: normal; }
.lang, .tcta { padding: 0 22px; font-weight: 800; font-stretch: 130%; text-transform: uppercase; font-size: 14px; letter-spacing: .03em; }
.lang:hover { background: var(--mist); }
.top .tcta { background: var(--ink); color: #fff; }
.top .tcta:hover { background: var(--ac); }
.burger { justify-content: center; flex-direction: column; gap: 7px; }
.burger span { display: block; width: 26px; height: 2px; background: var(--ink); transition: transform .3s ease; }
.burger:hover { background: var(--mist); }
.burger[aria-expanded="true"] { background: var(--ink); }
.burger[aria-expanded="true"] span { background: #fff; }
.burger[aria-expanded="true"] span:first-child { transform: translateY(4.5px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { transform: translateY(-4.5px) rotate(-45deg); }
@keyframes mq { to { transform: translateX(-50%); } }

/* ---------- menu overlay ---------- */
.menu {
  position: fixed; inset: var(--hdr) 0 0; z-index: 39; background: var(--ink); color: #fff;
  display: flex; flex-direction: column; justify-content: space-between; padding: var(--pad);
  overflow-y: auto; opacity: 0; transition: opacity .25s ease;
}
.menu.open { opacity: 1; }
.menu[hidden] { display: none; }
.menu ul { display: grid; gap: 0; }
.menu li a {
  display: flex; align-items: baseline; gap: 18px; padding: 6px 0;
  font-weight: 1000; font-stretch: 151%; text-transform: uppercase; line-height: 1;
  font-size: clamp(30px, 5.2vw, 76px); border-bottom: 1px solid #2a2a2a;
  transition: color .2s ease, padding .25s ease;
}
.menu li a .mono { color: var(--lime); font-size: 13px; }
.menu li a:hover { color: var(--lime); padding-left: 12px; }
.menu-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 32px; color: #bbb; }
.menu-foot a:hover { color: #fff; }

/* ---------- buttons ---------- */
.btns { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  display: inline-flex; align-items: center; gap: 12px; min-height: 56px; padding: 0 26px;
  font-weight: 800; font-stretch: 125%; text-transform: uppercase; font-size: 14px; letter-spacing: .04em;
  border: 1px solid var(--ink); transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.btn:hover .arr, .case-a:hover .arr, .clink:hover .arr { transform: translate(3px, -3px); }
.btn-ac { background: var(--ac); color: #fff; border-color: var(--ac); }
.btn-ac:hover { background: var(--ink); border-color: var(--ink); }
.btn-line:hover { background: var(--ink); color: #fff; }
.btn-lime { background: var(--lime); color: var(--ink); border-color: var(--lime); }
.btn-lime:hover { background: #fff; border-color: #fff; }

/* ---------- hero ---------- */
.hero { grid-template-columns: 7fr 5fr; border-bottom: 1px solid var(--ink); }
.hero-text { display: flex; flex-direction: column; justify-content: space-between; gap: 40px; padding: var(--pad); }
.kicker { color: var(--ac); }
.hero h1 { font-size: clamp(46px, 7.7vw, 140px); }
.hero h1 span { display: block; }
.hero h1 .ac { color: var(--ac); }
.lead { font-size: clamp(19px, 1.6vw, 24px); line-height: 1.4; max-width: 30em; font-stretch: 105%; }
.hero-photo { position: relative; min-height: 420px; background: var(--mist); }
.hero-photo .fill { position: absolute; inset: 0; }
.hero-photo img { object-position: 50% 25%; }
.hero-meta { grid-column: 1 / -1; grid-template-columns: repeat(4, 1fr); }
.meta { padding: 18px var(--pad) 20px; display: grid; gap: 6px; }
.meta .mono { color: #666; }
.meta b { font-weight: 800; font-stretch: 115%; font-size: 17px; }

/* ---------- band ---------- */
.band { background: var(--ac); color: #fff; overflow: hidden; border-bottom: 1px solid var(--ink); padding: 18px 0; }
.bd { animation-duration: 60s; }
.bd span, .bd i {
  font-weight: 1000; font-stretch: 151%; text-transform: uppercase; white-space: nowrap;
  font-size: clamp(26px, 3.6vw, 54px); line-height: 1; padding: 0 .45em;
}
.bd i { font-style: normal; color: var(--lime); }

/* ---------- quote ---------- */
.quote { grid-template-columns: 5fr 7fr; border-bottom: 1px solid var(--ink); }
.q-photo { aspect-ratio: 1; }
.q-text { background: var(--mist); display: flex; flex-direction: column; justify-content: center; gap: 28px; padding: var(--pad); }
.q-text blockquote { font-weight: 700; font-stretch: 112%; font-size: clamp(24px, 2.9vw, 46px); line-height: 1.16; letter-spacing: -.01em; }
.q-text figcaption { color: var(--ac); }

/* ---------- section scaffold ---------- */
.sec { border-bottom: 1px solid var(--ink); }
.head { grid-template-columns: minmax(0, 1fr) minmax(220px, 26%); border-bottom: 1px solid var(--ink); }
.head h2 { padding: calc(var(--pad) * 1.2) var(--pad) calc(var(--pad) * .7); font-size: clamp(36px, 6.4vw, 112px); }
.head .sub { display: flex; align-items: flex-end; padding: var(--pad); color: #555; font-size: 14px; }

/* ---------- about ---------- */
.about { grid-template-columns: 6fr 3fr 3fr; border-bottom: 1px solid var(--ink); }
.about-text { padding: var(--pad); display: grid; gap: 1em; align-content: start; font-size: clamp(17px, 1.3vw, 20px); }
.about-text p:first-child { font-size: 1.25em; line-height: 1.35; font-weight: 600; font-stretch: 108%; }
.about-photo { min-height: 360px; position: relative; }
.about-photo .fill { position: absolute; inset: 0; }
.princ { padding: var(--pad); background: var(--ink); color: #fff; }
.princ h3 { color: var(--lime); margin-bottom: 22px; }
.princ ol { display: grid; gap: 22px; counter-reset: p; }
.princ li { display: grid; gap: 6px; counter-increment: p; }
.princ li b { font-weight: 800; font-stretch: 120%; text-transform: uppercase; font-size: 16px; line-height: 1.2; }
.princ li b::before { content: "0" counter(p) "  "; color: var(--lime); font: italic 400 13px var(--mono); }
.princ li span { color: #c9c9c9; font-size: 15px; line-height: 1.45; }
.stats { grid-template-columns: repeat(3, 1fr); }
.stat { padding: var(--pad); display: grid; gap: 10px; align-content: start; }
.stat:nth-child(odd) { background: var(--mist); }
.stat .num { font-weight: 1000; font-stretch: 151%; color: var(--ac); font-size: clamp(46px, 6vw, 100px); line-height: .9; letter-spacing: -.02em; }
.stat span { font-size: 16px; max-width: 22em; }

/* ---------- skills ---------- */
.skills { grid-template-columns: repeat(3, 1fr); }
.skill { padding: var(--pad); display: flex; flex-direction: column; gap: 14px; min-height: 340px; transition: background .25s ease, color .25s ease; }
.skill .idx { color: var(--ac); }
.skill h3 { font-weight: 1000; font-stretch: 140%; text-transform: uppercase; font-size: clamp(22px, 1.9vw, 30px); line-height: 1; margin-top: 36px; }
.skill .tags { margin-top: auto; padding-top: 8px; }
.skill p { font-size: 16px; color: #333; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags li { border: 1px solid currentColor; padding: 4px 10px; font: italic 400 12px var(--mono); }
.skill:hover { background: var(--ac); color: #fff; }
.skill:hover p, .skill:hover .idx { color: #fff; }

/* ---------- projects ---------- */
.cases { grid-template-columns: repeat(4, 1fr); }
.case-a { display: flex; flex-direction: column; height: 100%; }
.case-media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; border-bottom: 1px solid var(--ink); }
.cm, .cm img { display: block; width: 100%; height: 100%; }
.cm img { transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.case-a:hover .cm img { transform: scale(1.045); }
.cm-logo, .cm-word { display: grid; place-items: center; }
.cm-logo img { width: auto; height: auto; max-width: 58%; max-height: 62%; object-fit: contain; }
.case-a:hover .cm-logo img { transform: scale(1.06); }
.cm-word span { font-weight: 1000; font-stretch: 151%; text-transform: uppercase; font-size: clamp(26px, 2.6vw, 42px); line-height: .9; text-align: center; padding: 0 12px; }
.badge { position: absolute; left: 0; top: 0; background: var(--lime); color: var(--ink); padding: 8px 14px; font: italic 400 12px var(--mono); }
.case-body { padding: 22px 24px 26px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.case-body .mono { color: #666; }
.case-body h3 { font-weight: 1000; font-stretch: 135%; text-transform: uppercase; font-size: 22px; line-height: 1; }
.summ { font-size: 15px; line-height: 1.45; color: #333; }
.metric { font-size: 14px; color: #555; }
.metric b { display: block; color: var(--ac); font-weight: 1000; font-stretch: 151%; font-size: 30px; line-height: 1; }
.more { margin-top: auto; padding-top: 8px; display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-stretch: 125%; text-transform: uppercase; font-size: 13px; letter-spacing: .05em; }
.case-a:hover .more { color: var(--ac); }
.case.wide { grid-column: 1 / -1; }
.case.wide .case-a { display: grid; grid-template-columns: 7fr 5fr; }
.case.wide .case-media { aspect-ratio: 16 / 10; border-bottom: 0; border-right: 1px solid var(--ink); }
.case.wide .case-body { padding: var(--pad); justify-content: center; gap: 16px; }
.case.wide h3 { font-size: clamp(30px, 3.6vw, 58px); }
.case.wide .summ { font-size: clamp(16px, 1.25vw, 19px); }

/* ---------- events ---------- */
.events { grid-template-columns: repeat(6, 1fr); }
.ev-text { grid-column: span 2; padding: var(--pad); display: flex; flex-direction: column; justify-content: space-between; gap: 28px; background: var(--lime); }
.ev-text p { font-size: clamp(17px, 1.3vw, 20px); line-height: 1.45; }
.ev { position: relative; aspect-ratio: 3 / 4; overflow: hidden; }
.ev picture, .ev img { width: 100%; height: 100%; }
.ev figcaption { position: absolute; left: 0; bottom: 0; background: var(--paper); padding: 6px 10px; }

/* ---------- path ---------- */
.path { display: grid; }
.row {
  display: grid; grid-template-columns: 2fr 4fr 6fr; gap: 24px; align-items: baseline;
  padding: 26px var(--pad); border-bottom: 1px solid var(--ink); transition: background .2s ease;
}
.row:last-child { border-bottom: 0; }
.row:hover { background: var(--mist); }
.yr { font-weight: 1000; font-stretch: 151%; color: var(--ac); font-size: clamp(20px, 2vw, 30px); line-height: 1; white-space: nowrap; }
.role { display: grid; gap: 4px; }
.role b { font-weight: 800; font-stretch: 115%; font-size: 19px; line-height: 1.2; }
.role .mono { color: #666; }
.row p { font-size: 16px; color: #333; }

/* ---------- education ---------- */
.edus { grid-template-columns: repeat(4, 1fr); }
.edu { padding: var(--pad); display: flex; flex-direction: column; gap: 10px; }
.edu-logo { height: 96px; display: flex; align-items: center; margin-bottom: 14px; }
.edu-logo img { width: auto; max-width: 78%; max-height: 72px; }
.edu-logo .word { font-weight: 1000; font-stretch: 151%; font-size: 40px; color: var(--ac); line-height: 1; }
.edu h3 { font-weight: 800; font-stretch: 112%; font-size: 18px; line-height: 1.25; }
.edu .mono { color: var(--ac); }
.edu p:last-child { font-size: 15px; color: #444; }

/* ---------- media ---------- */
.media { grid-template-columns: repeat(4, 1fr); }
.md-text { padding: var(--pad); display: flex; flex-direction: column; justify-content: space-between; gap: 28px; }
.md-text p { font-size: clamp(17px, 1.3vw, 20px); }
.md { display: flex; flex-direction: column; }
.md picture { aspect-ratio: 4 / 5; overflow: hidden; display: block; }
.md img { width: 100%; height: 100%; }
.md figcaption { padding: 14px 18px 18px; font-weight: 700; font-stretch: 110%; font-size: 15px; line-height: 1.3; border-top: 1px solid var(--ink); }

/* ---------- R&A ---------- */
.ra { background: var(--ink); color: #fff; }
.ra-g { grid-template-columns: 5fr 7fr; background: #2e2e2e; }
.ra .cell { background: var(--ink); }
.ra-logo { display: grid; place-items: center; padding: calc(var(--pad) * 1.4); }
.ra-logo img { width: min(78%, 420px); }
.ra-text { padding: var(--pad); display: flex; flex-direction: column; gap: 32px; align-items: flex-start; }
.ra-text > p { font-size: clamp(19px, 1.7vw, 26px); line-height: 1.35; font-stretch: 105%; }
.ra-stats { display: grid; grid-template-columns: repeat(3, auto); gap: 18px 40px; }
.ra-stat { display: grid; gap: 4px; }
.ra-stat b { color: var(--lime); font-weight: 1000; font-stretch: 151%; font-size: clamp(30px, 3vw, 48px); line-height: 1; }
.ra-stat span { color: #bdbdbd; font-size: 14px; }

/* ---------- contact ---------- */
.contact { background: var(--ac); color: #fff; }
.ct-g { grid-template-columns: 7fr 5fr; background: var(--ink); }
.contact .cell { background: var(--ac); }
.ct-text { padding: var(--pad); display: flex; flex-direction: column; gap: 26px; }
.ct-text h2 { font-size: clamp(32px, 4.5vw, 80px); }
.ct-text h2 span { display: block; }
.ct-text h2 span + span { color: var(--lime); }
.ct-text .sub { font-size: clamp(17px, 1.4vw, 21px); max-width: 30em; }
.clinks { display: grid; margin-top: 8px; border-top: 1px solid rgba(255, 255, 255, .35); }
.clink {
  display: grid; grid-template-columns: 28px 110px 1fr auto; align-items: center; gap: 14px;
  padding: 16px 0; border-bottom: 1px solid rgba(255, 255, 255, .35); transition: padding .25s ease, color .2s ease;
}
.clink .ic svg { width: 22px; height: 22px; display: block; }
.cl-k { color: rgba(255, 255, 255, .75); }
.cl-v { font-weight: 800; font-stretch: 115%; font-size: clamp(16px, 1.5vw, 22px); overflow-wrap: anywhere; }
.clink:hover { color: var(--lime); padding-left: 10px; }
.ct-photo { position: relative; min-height: 420px; }
.ct-photo .fill { position: absolute; inset: 0; }

/* ---------- footer ---------- */
.foot {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; align-items: center;
  background: var(--ink); color: #cfcfcf; padding: 22px var(--pad); font-size: 14px; border-top: 1px solid #2e2e2e;
}
.foot a:hover { color: #fff; }

/* ---------- reveal on scroll (only when JS is running) ---------- */
/* cells stay opaque (the grid behind them is ink); only their content fades in */
html.js [data-r] > * { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); transition-delay: inherit; }
html.js [data-r].in > * { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 1180px) {
  .cases { grid-template-columns: repeat(2, 1fr); }
  .about { grid-template-columns: 1fr 1fr; }
  .about-text { grid-column: 1 / -1; }
  .events { grid-template-columns: repeat(4, 1fr); }
  .ev-text { grid-column: 1 / -1; }
  .media { grid-template-columns: repeat(3, 1fr); }
  .md-text { grid-column: 1 / -1; }
  .edus { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
  .ticker { visibility: hidden; }
  .hero, .quote, .head, .ct-g, .ra-g, .case.wide .case-a { grid-template-columns: 1fr; }
  .hero-photo { min-height: 0; aspect-ratio: 4 / 5; }
  .hero-meta { grid-template-columns: repeat(2, 1fr); }
  .head .sub { padding-top: 0; border-top: 0; }
  .case.wide .case-media { border-right: 0; border-bottom: 1px solid var(--ink); }
  .skills, .stats { grid-template-columns: repeat(2, 1fr); }
  .row { grid-template-columns: 1fr; gap: 8px; }
  .ra-stats { grid-template-columns: repeat(2, auto); }
  .ct-photo { min-height: 0; aspect-ratio: 4 / 3; }
  .ct-photo img { object-position: 50% 30%; }
}
@media (max-width: 640px) {
  :root { --hdr: 56px; }
  body { font-size: 17px; }
  .top { grid-template-columns: 1fr auto var(--hdr); }
  .ticker, .tcta { display: none !important; }
  .brand { padding: 0 14px; }
  .brand .mk { width: 30px; height: 30px; font-size: 12px; }
  .brand .bn { font-size: 16px; }
  .hero h1 { font-size: clamp(36px, 12.4vw, 64px); }
  .hero-text { gap: 26px; }
  .btn { width: 100%; justify-content: space-between; }
  .meta { padding: 14px 16px; }
  .meta b { font-size: 15px; }
  .q-photo { aspect-ratio: 4 / 3; }
  .about { grid-template-columns: 1fr; }
  .about-photo { min-height: 0; aspect-ratio: 4 / 5; }
  .skills, .stats, .cases, .edus { grid-template-columns: 1fr; }
  .skill { min-height: 0; }
  .skill h3 { margin-top: 12px; }
  .head h2 { font-size: 8.6vw; }
  .ct-text h2 { font-size: 8.2vw; }
  .events { grid-template-columns: repeat(2, 1fr); }
  .media { grid-template-columns: 1fr 1fr; }
  .md figcaption { padding: 10px 12px 12px; font-size: 13px; }
  .md:last-child { grid-column: 1 / -1; }
  .md:last-child picture { aspect-ratio: 4 / 3; }
  .ra-stats { grid-template-columns: 1fr 1fr; }
  .clink { grid-template-columns: 24px 1fr auto; }
  .cl-k { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .tk, .bd { animation: none; }
  html.js [data-r] > * { opacity: 1; transform: none; transition: none; }
  * { transition-duration: 0s !important; }
}
