/* Nonogram Studio — black, white, pixels. The work brings the colour. */

/* Armenian letters only (Helvetica has none): Montserrat arm, SIL Open Font Licence, cut down to the
   Armenian alphabet (~9 KB a weight). The unicode-range keeps it off English pages entirely. Bold text uses
   the ExtraBold cut so Armenian headlines weigh the same as the English ones. */
@font-face {
  font-family: "Nono Armenian";
  src: url("../assets/fonts/montserrat-arm-regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
  unicode-range: U+0530-058F, U+2024, U+FB13-FB17;
}
@font-face {
  font-family: "Nono Armenian";
  src: url("../assets/fonts/montserrat-arm-semibold.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
  unicode-range: U+0530-058F, U+2024, U+FB13-FB17;
}
@font-face {
  font-family: "Nono Armenian";
  src: url("../assets/fonts/montserrat-arm-extrabold.woff2") format("woff2");
  font-weight: 700 900;
  font-display: swap;
  unicode-range: U+0530-058F, U+2024, U+FB13-FB17;
}
:root {
  --bg: #000;
  --fg: #fff;
  --muted: #9a9a9a;
  --line: #2a2a2a;
  --card: #0d0d0d;
  --pad: clamp(16px, 4vw, 56px);
  --max: 1440px;
  --font: "Nono Armenian", "Helvetica Neue", "Neue Haas Grotesk Display Pro", Helvetica, Arial, sans-serif;
  --radius: 999px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; overflow-x: clip; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 400 18px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 700; letter-spacing: -0.04em; line-height: 0.92; text-transform: uppercase; }
p { margin: 0; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 3px; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: var(--fg); color: var(--bg); padding: 8px 12px; }

.eyebrow { font-size: 14px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 20px; }

/* Buttons: pill shape, as on the portfolio */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 26px; border-radius: var(--radius);
  background: var(--fg); color: var(--bg); border: 1.5px solid var(--fg);
  font-size: 17px; font-weight: 600; text-decoration: none; cursor: pointer;
  transition: background .2s, color .2s;
}
.btn:hover { background: var(--bg); color: var(--fg); }
.btn--ghost { background: transparent; color: var(--fg); }
.btn--ghost:hover { background: var(--fg); color: var(--bg); }
.btn--small { padding: 8px 18px; font-size: 15px; }

/* Header */
.top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px var(--pad);
  background: rgba(0, 0, 0, .82); backdrop-filter: blur(10px);
}
.top__logo img { height: 34px; width: auto; }
.top__nav { display: flex; align-items: center; gap: 28px; font-size: 16px; }
.top__nav a:not(.btn) { text-decoration: none; color: var(--muted); }
.top__nav a:not(.btn):hover, .top__nav a[aria-current="page"] { color: var(--fg); }
/* Language dropdown (js/lang.js remembers the choice and closes it) */
.lang { position: relative; }
.lang summary {
  list-style: none; cursor: pointer; user-select: none; display: flex; align-items: center; gap: 6px;
  color: var(--muted); font-size: 15px; letter-spacing: .04em;
}
.lang summary::-webkit-details-marker { display: none; }
.lang summary::after {
  content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: translateY(-2px) rotate(45deg); transition: transform .2s;
}
.lang summary:hover, .lang[open] summary { color: var(--fg); }
.lang[open] summary::after { transform: translateY(1px) rotate(225deg); }
.lang__menu {
  position: absolute; right: -12px; top: calc(100% + 14px); z-index: 30; min-width: 170px;
  display: grid; gap: 2px; padding: 6px; background: var(--bg); border: 1px solid var(--line); border-radius: 18px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .6);
}
.top__nav .lang__menu a {
  display: flex; align-items: center; gap: 12px; padding: 9px 14px; border-radius: var(--radius);
  color: var(--muted); text-decoration: none; white-space: nowrap; font-size: 15px;
}
.lang__menu b { width: 22px; font-weight: 600; font-size: 12px; letter-spacing: .06em; color: inherit; }
.top__nav .lang__menu a:hover { background: #161616; color: var(--fg); }
.top__nav .lang__menu a[aria-current] { background: var(--fg); color: #000; }

/* Hero */
.hero {
  max-width: var(--max); margin: 0 auto;
  min-height: min(calc(100vh - 64px), 920px);
  display: grid; grid-template-columns: 1.3fr 1fr; align-items: center; gap: clamp(32px, 6vw, 96px);
  padding: clamp(40px, 8vh, 96px) var(--pad);
}
.hero__title { font-size: clamp(44px, 6.2vw, 108px); }
.hero__title span { display: block; }
.hero__title span:nth-child(2) { padding-left: 0.6em; }
.hero__lead { margin-top: 32px; max-width: 34em; font-size: clamp(18px, 1.5vw, 21px); color: #d6d6d6; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }

/* Nonogram game */
.game { margin: 0; justify-self: center; width: min(100%, 480px); position: relative; }
.game__bar { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; font-size: 14px; }
.game__count { color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.game__time { font-variant-numeric: tabular-nums; margin-right: auto; }
.game__lb { position: relative; }
.game__lbbtn { border: 1.5px solid var(--line); background: none; border-radius: var(--radius); padding: 6px 14px; cursor: pointer; font-size: 14px; }
.game__lbbtn:hover, .game__lbbtn[aria-expanded="true"] { border-color: var(--fg); }
.lb {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 10; width: min(320px, 86vw);
  background: #0b0b0b; border: 1px solid var(--line); padding: 16px; box-shadow: 0 20px 60px rgba(0,0,0,.6);
}
.lb__title { font-weight: 700; text-transform: uppercase; letter-spacing: -.01em; font-size: 18px; margin-bottom: 10px; }
.lb__list { list-style: none; margin: 0; padding: 0; font-size: 15px; }
.lb__list li { display: grid; grid-template-columns: 26px 1fr auto auto; gap: 10px; padding: 7px 0; border-top: 1px solid var(--line); }
.lb__list li.lb__empty { display: block; color: var(--muted); }
.lb__list .lb__me { color: #000; background: var(--fg); padding-left: 6px; padding-right: 6px; margin: 0 -6px; }
.lb__rank { color: var(--muted); }
.lb__me .lb__rank { color: #000; }
.lb__name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb__score, .lb__time { font-variant-numeric: tabular-nums; }
.lb__note { color: var(--muted); font-size: 13px; margin-top: 10px; }
.lb__foot { display: flex; justify-content: space-between; gap: 10px; margin-top: 12px; font-size: 13px; color: var(--muted); }
.lb__link { background: none; border: 0; padding: 0; color: var(--fg); text-decoration: underline; cursor: pointer; font-size: 13px; }

.puzzle__board {
  display: grid;
  grid-template-columns: auto repeat(var(--n), 1fr);
  gap: 3px;
  user-select: none; -webkit-user-select: none;
  touch-action: none;
}
.puzzle__clue { font-size: 11px; color: #cfcfcf; display: flex; font-variant-numeric: tabular-nums; transition: color .2s; }
.puzzle__clue.done { color: #4a4a4a; }
.puzzle__clue--col { flex-direction: column; justify-content: flex-end; align-items: center; line-height: 1.15; padding-bottom: 4px; }
.puzzle__clue--row { justify-content: flex-end; align-items: center; gap: 5px; padding-right: 6px; }
.puzzle__cell { aspect-ratio: 1; cursor: pointer; background: #151515; position: relative; transition: background .2s, transform .15s; }
.puzzle__cell:hover { background: #2c2c2c; }
.puzzle__cell.on { background: var(--fg); }
.puzzle__cell.x::before, .puzzle__cell.x::after {
  content: ""; position: absolute; left: 22%; right: 22%; top: 50%; height: 1.5px; background: #6a6a6a;
}
.puzzle__cell.x::before { transform: rotate(45deg); }
.puzzle__cell.x::after { transform: rotate(-45deg); }
.puzzle__cell.pop { transform: scale(.84); }
.game.is-solved .puzzle__cell:not(.on) { background: #0a0a0a; }
.game.is-solved .puzzle__cell { cursor: default; }

.game__tools { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 14px; }
.seg { display: inline-flex; border: 1.5px solid var(--line); border-radius: var(--radius); padding: 3px; }
.seg button { border: 0; background: none; border-radius: var(--radius); padding: 6px 14px; cursor: pointer; font-size: 14px; color: var(--muted); }
.seg button[aria-pressed="true"] { background: var(--fg); color: #000; }
.game__skip { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 14px; text-decoration: underline; }
.game__skip:hover { color: var(--fg); }
.game__solved { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 14px; }
.game__solved p { font-size: 15px; color: #d6d6d6; }
.game__solved .btn { white-space: nowrap; flex-shrink: 0; }
.game__solved b { color: var(--fg); text-transform: uppercase; }
.game__player { margin-top: 14px; padding: 14px; border: 1px solid var(--line); display: grid; gap: 8px; font-size: 15px; }
.game__player-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.game__player input { flex: 1; min-width: 140px; background: #111; border: 1px solid var(--line); color: var(--fg); padding: 8px 12px; border-radius: var(--radius); font: inherit; }
.game__player input:focus { outline: none; border-color: var(--fg); }
.game__error { color: #ff8a8a; min-height: 1em; }
.puzzle__hint { margin-top: 12px; font-size: 13px; color: var(--muted); min-height: 1.5em; }

/* Sections */
.section { max-width: var(--max); margin: 0 auto; padding: clamp(64px, 11vw, 150px) var(--pad) 0; }
.section__head { display: grid; grid-template-columns: 1fr 1fr; gap: 24px 48px; align-items: end; margin-bottom: clamp(32px, 5vw, 64px); }
.section__head h2, .section__head h1, .ninetails h2, .contact__title { font-size: clamp(40px, 6.4vw, 104px); }
.section__head h2::after, .section__head h1::after {
  /* the pixel O from the logo */
  content: ""; display: inline-block; width: .32em; height: .32em; margin-left: .2em; vertical-align: .1em;
  background: url("../assets/brand/o-white.svg") center / contain no-repeat;
}
.section__head p { color: #cfcfcf; font-size: clamp(18px, 1.6vw, 22px); max-width: 30em; }

/* Services */
.services { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; column-gap: 48px; counter-reset: s; }
.services li { counter-increment: s; display: grid; grid-template-columns: 56px 1fr; gap: 4px 12px; padding: 22px 0; border-top: 1px solid var(--line); }
.services li::before { content: counter(s, decimal-leading-zero); color: var(--muted); font-size: 14px; padding-top: 6px; grid-row: span 2; }
.services h3 { font-size: clamp(22px, 2.2vw, 30px); letter-spacing: -0.02em; }
.services p { color: var(--muted); font-size: 16px; }

/* Work */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.chip {
  border: 1.5px solid var(--line); background: transparent; border-radius: var(--radius);
  padding: 8px 16px; font-size: 15px; cursor: pointer; color: #cfcfcf;
}
.chip:hover { border-color: var(--fg); }
.chip[aria-pressed="true"] { background: var(--fg); color: var(--bg); border-color: var(--fg); }

/* Masonry: every preview shows the whole image at its own shape.
   js/site.js sets each card's row span from its height (rows are 4px). */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 4px; column-gap: clamp(12px, 1.6vw, 24px); align-items: start; }
.card { position: relative; display: block; cursor: pointer; text-align: left; background: none; border: 0; padding: 0 0 clamp(24px, 3vw, 40px); color: inherit; text-decoration: none; }
.card[hidden] { display: none; }
.card__img { overflow: hidden; background: var(--card); }
.card__img img { width: 100%; height: auto; transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.card:hover .card__img img { transform: scale(1.03); }
.card__meta { padding: 14px 2px 0; }
.card__title { font-size: clamp(20px, 2vw, 28px); text-transform: uppercase; font-weight: 700; letter-spacing: -0.03em; line-height: 1; }
.card__summary { color: #cfcfcf; font-size: 16px; margin-top: 6px; }
.card__tags { color: var(--muted); font-size: 13px; margin-top: 6px; letter-spacing: .02em; }
.more { display: flex; justify-content: center; margin-top: 40px; }
.empty { grid-column: 1 / -1; color: var(--muted); padding: 40px 0; }

/* 9Tails */
.ninetails { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(32px, 6vw, 96px); align-items: center; }
.ninetails__img { width: 100%; height: auto; }
.ninetails h2 { font-size: clamp(36px, 4.6vw, 76px); margin-bottom: 28px; }
.ninetails p:not(.eyebrow) { color: #cfcfcf; font-size: clamp(18px, 1.5vw, 21px); margin-bottom: 32px; max-width: 32em; }

/* About */
.about .section__head { grid-template-columns: 1fr; }
.about__cols { display: grid; grid-template-columns: 1.2fr 1fr; gap: 48px; align-items: start; }
.about__big { font-size: clamp(24px, 2.6vw, 38px); line-height: 1.2; letter-spacing: -0.02em; }
.about__cols p:last-child { color: #cfcfcf; }

/* Partners */
.partners { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.partners li { display: flex; align-items: center; justify-content: center; height: clamp(96px, 11vw, 160px); padding: 0 12%; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.partners img { max-width: 100%; max-height: 52%; width: auto; height: auto; object-fit: contain; filter: grayscale(1) brightness(1.6); opacity: .75; transition: filter .3s, opacity .3s; }
.partners li:hover img { filter: none; opacity: 1; }

/* Events */
.events { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border-top: 1px solid var(--line); }
.events li { padding: 24px 24px 24px 0; border-bottom: 1px solid var(--line); }
.events li + li { padding-left: 24px; border-left: 1px solid var(--line); }
.events b { display: block; font-size: clamp(40px, 5vw, 80px); letter-spacing: -0.05em; line-height: 1; }
.events span { color: var(--muted); font-size: 16px; }

/* Contact */
.contact { padding-bottom: clamp(64px, 10vw, 140px); }
.contact__title { max-width: 14em; }
.contact__lead { margin-top: 28px; font-size: clamp(18px, 1.6vw, 22px); color: #cfcfcf; max-width: 32em; }
.contact__buttons { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 40px; }
.contact__details { display: flex; flex-wrap: wrap; gap: 12px 40px; margin-top: 40px; font-size: clamp(18px, 2vw, 26px); }
.contact__details a { text-decoration: none; border-bottom: 1px solid var(--line); }
.contact__details a:hover { border-color: var(--fg); }
.contact__details span { color: var(--muted); }

/* Footer */
.foot {
  max-width: var(--max); margin: 0 auto; padding: 40px var(--pad) 48px;
  border-top: 1px solid var(--line);
  display: grid; grid-template-columns: auto 1fr auto; gap: 20px 40px; align-items: center;
  color: var(--muted); font-size: 15px;
}
.foot img { height: 40px; width: auto; }
.foot__social { list-style: none; margin: 0; padding: 0; display: flex; gap: 22px; }
.foot__social a { text-decoration: none; color: var(--fg); }
.foot__social a:hover { text-decoration: underline; }
.foot__rights { grid-column: 1 / -1; }
.foot__nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.foot__nav a { color: var(--muted); text-decoration: none; }
.foot__nav a:hover { color: var(--fg); }

/* Multi-page site: the first section of a page sits closer to the header */
.section--first { padding-top: clamp(40px, 7vw, 96px); }

/* Homepage: short services list, each a link to /services/#… */
.services-short { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; column-gap: 48px; counter-reset: s; }
.services-short li { counter-increment: s; border-top: 1px solid var(--line); }
.services-short a {
  display: flex; align-items: baseline; gap: 16px; padding: 18px 0; text-decoration: none;
  font-size: clamp(22px, 2.4vw, 34px); font-weight: 700; text-transform: uppercase; letter-spacing: -0.03em; line-height: 1;
}
.services-short a::before { content: counter(s, decimal-leading-zero); color: var(--muted); font-size: 14px; font-weight: 400; letter-spacing: 0; }
.services-short a::after { content: "→"; margin-left: auto; color: var(--muted); transition: transform .2s, color .2s; }
.services-short a:hover::after { color: var(--fg); transform: translateX(4px); }

/* /services/: each service with three examples */
.services-full { list-style: none; margin: 0; padding: 0; }
.service {
  display: grid; grid-template-columns: 56px 1fr 1.3fr; gap: 16px 32px; align-items: start;
  padding: clamp(28px, 4vw, 48px) 0; border-top: 1px solid var(--line); scroll-margin-top: 90px;
}
.service__n { color: var(--muted); font-size: 14px; padding-top: 8px; }
.service__text h2 { font-size: clamp(26px, 3vw, 44px); margin-bottom: 14px; }
.service__text p { color: #cfcfcf; max-width: 24em; }
.service__work { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.service__work a { text-decoration: none; color: var(--muted); font-size: 13px; }
.service__work img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; margin-bottom: 6px; background: var(--card); transition: opacity .2s; }
.service__work a:hover { color: var(--fg); }
.service__work a:hover img { opacity: .8; }

/* Podcast: teaser on the homepage and the coming-soon page. The bars are a pixel equaliser. */
.podcast-teaser { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(32px, 6vw, 96px); align-items: center; }
.podcast-teaser h2 { font-size: clamp(36px, 4.6vw, 76px); margin-bottom: 24px; }
.podcast-teaser p:not(.eyebrow) { color: #cfcfcf; font-size: clamp(18px, 1.5vw, 21px); margin-bottom: 32px; max-width: 30em; }
.podcast { display: grid; grid-template-columns: 1.2fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: center; min-height: 60vh; }
.podcast h1 { font-size: clamp(44px, 7vw, 120px); margin-bottom: 28px; }
.podcast__lead { font-size: clamp(20px, 2vw, 28px); line-height: 1.3; margin-bottom: 24px; max-width: 26em; }
.podcast__text > p:not(.eyebrow):not(.podcast__lead) { color: #cfcfcf; }
.podcast__follow { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.podcast__art, .podcast-teaser__art { display: flex; justify-content: center; }
.podcast__art .pix { width: min(100%, 440px); }
.podcast-teaser__art .pix { width: min(100%, 360px); }

/* A picture drawn as a nonogram (js/pix.js fills it in) */
.pix {
  display: grid; grid-template-columns: auto repeat(var(--cols), minmax(0, 1fr)); gap: calc(32px / var(--cols)); align-items: end; min-width: 0;
  padding: 0; border: 0; background: none; color: var(--muted); font: 10px/1.1 var(--font); cursor: pointer;
}
.pix--fixed { grid-template-columns: calc(var(--clue-w) + 6px) repeat(var(--cols), minmax(0, 1fr)); font-size: 9px; }
.pix--fixed .pix__clue--col { min-height: calc(var(--clue-lines) * 10px + 3px); }
/* row clues never make a row taller than its squares; numbers never make a column wider */
.pix__clue--row { height: 0; line-height: 0; align-self: center; display: flex; align-items: center; justify-content: flex-end; }
.pix__clue--col { min-width: 0; }
.pix i { aspect-ratio: 1; background: #151515; transition: background .25s; transition-delay: 0s; }
.pix.is-solved i[data-on] { background: var(--fg); transition-delay: var(--d); }
.pix:hover i:not([data-on]) { background: #1c1c1c; }
.pix__clue--col { display: flex; flex-direction: column; align-items: center; padding-bottom: 3px; }
.pix__clue--col b { font-weight: 400; }
.pix__clue--row { text-align: right; padding-right: 5px; white-space: nowrap; align-self: center; }
.pix.is-solved .pix__clue { color: #4a4a4a; transition: color .3s .8s; }

/* About */
.about__text p + p { margin-top: 1em; }
.about__text { color: #cfcfcf; }
.stats { grid-template-columns: repeat(5, 1fr); margin-top: clamp(40px, 6vw, 80px); }
.how { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.how li { border-top: 1px solid var(--line); padding-top: 20px; }
.how__n { color: var(--muted); font-size: 14px; }
.how h3 { font-size: clamp(24px, 2.4vw, 34px); margin: 14px 0 12px; }
.how p { color: #cfcfcf; }
.people__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.person { min-width: 0; }
.person .pix { width: 100%; margin-bottom: 16px; }
/* text on the picture's own columns: it starts exactly where the squares start */
.person__text { display: grid; grid-template-columns: calc(var(--clue-w) + 6px) repeat(var(--cols), minmax(0, 1fr)); column-gap: calc(32px / var(--cols)); font-size: 9px; }
.person__text > * { grid-column: 2 / -1; }
.person__name { font-weight: 700; text-transform: uppercase; letter-spacing: -0.02em; font-size: 20px; line-height: 1.1; }
.person__role { color: var(--muted); font-size: 15px; margin-top: 4px; }
.cheat { margin-top: 32px; padding: 16px 20px; background: var(--fg); color: #000; font-weight: 700; display: inline-flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; box-shadow: 6px 6px 0 #00ea9e; }
.cheat .btn { background: #000; color: #fff; border-color: #000; }
.facts { list-style: none; margin: 0; padding: 0; counter-reset: f; }
.facts li { counter-increment: f; display: grid; grid-template-columns: 56px 1fr; padding: 20px 0; border-top: 1px solid var(--line); font-size: clamp(20px, 2vw, 28px); line-height: 1.25; }
.facts li::before { content: counter(f, decimal-leading-zero); color: var(--muted); font-size: 14px; padding-top: 6px; }

/* Project modal */
.modal {
  width: min(1100px, calc(100vw - 24px)); max-height: calc(100vh - 24px);
  padding: 0; border: 1px solid var(--line); background: #070707; color: var(--fg);
}
.modal::backdrop { background: rgba(0, 0, 0, .85); }
.modal__close {
  position: sticky; top: 12px; float: right; margin: 12px 12px 0 0; z-index: 2;
  border: 1.5px solid var(--fg); background: var(--bg); border-radius: var(--radius);
  padding: 8px 16px; cursor: pointer; font-size: 15px;
}
.modal__body { --pad: clamp(20px, 4vw, 48px); padding: var(--pad); }
.modal__body h2 { font-size: clamp(36px, 5vw, 72px); margin: 8px 0 20px; }
.modal__video { aspect-ratio: 16 / 9; background: #000; margin-bottom: 32px; }
.modal__video iframe { display: block; width: 100%; height: 100%; border: 0; }
.modal__info { display: grid; grid-template-columns: 1.6fr 1fr; gap: 24px 48px; margin-bottom: 32px; }
.modal__info p { color: #d6d6d6; }
.modal__facts { font-size: 15px; color: var(--muted); display: grid; gap: 8px; align-content: start; }
.modal__facts b { color: var(--fg); font-weight: 600; }
.modal__links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.modal__images { display: grid; gap: 12px; }

/* Behance case, block by block (pictures sit edge to edge, as on Behance) */
.case { margin-bottom: calc(-1 * var(--pad)); }
.case img, .case video { display: block; width: 100%; height: auto; margin: 0 auto; }
.case--full { margin-inline: calc(-1 * var(--pad)); }
.case .modal__video { margin: 32px 0; }
.case__row { display: flex; }
.case__row > div { min-width: 0; }
.case__text { max-width: 760px; margin: 0 auto; padding: 56px 0; color: #d6d6d6; }
.case__text h3, .case__text h2 { font-size: clamp(26px, 3.4vw, 44px); line-height: 1.05; margin: 0 0 12px; color: var(--fg); text-transform: uppercase; }
.case__text p { margin: 0 0 1em; }
.case__text p:last-child { margin-bottom: 0; }
.case__text .sub { color: var(--muted); text-transform: uppercase; letter-spacing: .08em; font-size: 14px; margin-bottom: 2em; }
.case__text a { color: var(--fg); }

/* Standalone project pages and 404 (written by tools/prerender.mjs) */
.page { max-width: 1100px; margin: 0 auto; }
.page__title { font-size: clamp(36px, 5vw, 72px); margin: 8px 0 20px; }
.page__cta, .page__more, .page__404 { padding: clamp(48px, 8vw, 96px) var(--pad) 0; }
.page__cta h2, .page__more h2 { font-size: clamp(28px, 3.6vw, 48px); margin-bottom: 16px; }
.page__cta p { color: #cfcfcf; max-width: 36em; margin-bottom: 24px; }
.page__more .grid { grid-auto-rows: auto; margin-bottom: 24px; }
.page__404 { min-height: 50vh; }
.page__404 p:not(.eyebrow) { color: #cfcfcf; margin-bottom: 24px; }

.video-facade__play { position: relative; display: block; width: 100%; height: 100%; padding: 0; border: 0; background: #000; cursor: pointer; }
.video-facade__play img { width: 100%; height: 100%; object-fit: cover; }
.video-facade__icon {
  position: absolute; left: 50%; top: 50%; width: 76px; height: 76px; margin: -38px 0 0 -38px; border-radius: 50%;
  background: var(--fg); transition: transform .2s;
}
.video-facade__icon::after {
  content: ""; position: absolute; left: 31px; top: 24px; border-style: solid; border-width: 14px 0 14px 22px;
  border-color: transparent transparent transparent #000;
}
.video-facade__play:hover .video-facade__icon { transform: scale(1.08); }

/* Logo easter egg (js/egg.js): the site takes client feedback literally */
.top__logo { touch-action: manipulation; }  /* quick taps on phones don't zoom */
.top__logo img { transition: height .35s cubic-bezier(.3, 1.6, .5, 1), filter .3s; }
.egg-1 .top__logo img { height: clamp(70px, 14vw, 120px); }
.egg-2 .top__logo img { filter: drop-shadow(0 0 6px #fff) drop-shadow(4px 6px 0 #ff2bd6) drop-shadow(-4px -3px 0 #00ea9e); animation: egg-pop .6s ease-in-out infinite alternate; }
/* Comic Sans has no Armenian letters: in Armenian the "client" gets Hovhannes Tumanyan's handwriting instead.
   "Tumanian's Handwriting" © Ruben Tarumian, free for personal and commercial use (fonter.am); Armenian letters only. */
@font-face {
  font-family: "Nono Silly";
  src: url("../assets/fonts/tumanian-handwriting.woff2") format("woff2");
  font-display: swap;
  unicode-range: U+0530-058F, U+2024, U+FB13-FB17;
}
.egg-3 body, .egg-3 .btn, .egg-3 h1, .egg-3 h2, .egg-3 h3 { font-family: "Nono Silly", "Comic Sans MS", "Comic Neue", "Chalkboard SE", "Comic Sans", cursive !important; letter-spacing: 0 !important; }
.egg-4 h1, .egg-4 h2, .egg-4 .card__title {
  background: linear-gradient(90deg, #ff2b2b, #ffb800, #00ea9e, #2b8cff, #b42bff, #ff2b2b) 0 0 / 200% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent; animation: egg-rainbow 2s linear infinite;
}
.egg-4 .btn:not(.egg .btn) { background: linear-gradient(90deg, #ff2bd6, #ffb800, #00ea9e); color: #000; border-color: transparent; }
.egg-4 .top__logo img { animation: egg-pop .6s ease-in-out infinite alternate, egg-spin 3s linear infinite; }
@keyframes egg-pop { to { transform: scale(1.08) rotate(-3deg); } }
@keyframes egg-spin { to { rotate: 360deg; } }
@keyframes egg-rainbow { to { background-position: -200% 0; } }
.egg {
  position: fixed; left: 50%; bottom: 24px; z-index: 60; width: min(440px, calc(100vw - 32px)); transform: translateX(-50%);
  background: var(--fg); color: #000; padding: 18px 20px; border-radius: 4px; box-shadow: 6px 6px 0 #00ea9e;
  font-family: inherit;
}
.egg--in { animation: egg-in .35s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes egg-in { from { transform: translateX(-50%) translateY(16px) scale(.92); opacity: 0; } }
.egg__quote { font-size: 20px; font-weight: 700; line-height: 1.2; letter-spacing: -0.01em; }
.egg__by { margin-top: 6px; font-size: 13px; color: #555; }
.egg .btn { margin-top: 12px; background: #000; color: #fff; border-color: #000; }

/* Brief builder in the contact block (js/brief.js) */
.brief { margin-top: 40px; max-width: 980px; border-top: 1px solid var(--line); padding-top: 28px; }
.brief__title { font-size: clamp(22px, 2.4vw, 32px); margin-bottom: 18px; }
.brief__row { margin-bottom: 18px; }
.brief__q { color: var(--muted); font-size: 15px; margin-bottom: 10px; }
.brief__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.brief__like { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 18px; padding: 6px 8px 6px 14px; border-radius: var(--radius); background: #00ea9e; color: #000; font-weight: 600; font-size: 15px; }
.brief__react { min-height: 1.5em; font-weight: 700; margin: 6px 0 12px; }
.brief__msg { display: block; width: 100%; resize: vertical; background: #111; border: 1px solid var(--line); padding: 14px 16px; font: 16px/1.5 var(--font); color: var(--fg); margin-bottom: 10px; }
.brief__msg:focus { outline: none; border-color: var(--fg); }
.brief__msg::placeholder { color: #666; }
.brief__x { border: 0; background: #000; color: #00ea9e; width: 24px; height: 24px; border-radius: 50%; font-size: 16px; line-height: 1; cursor: pointer; }
.brief__regen { border: 0; background: none; padding: 0; margin-bottom: 18px; color: var(--muted); text-decoration: underline; cursor: pointer; font-size: 14px; }
.brief__regen + .brief__q, .brief__msg + .brief__regen[hidden] + .brief__q { margin-top: 8px; }
.contact .brief + .contact__buttons { margin-top: 0; }

/* Everything leads to the brief */
.service__cta { display: inline-block; margin-top: 14px; color: var(--fg); font-weight: 600; text-decoration: none; border-bottom: 1px solid var(--line); }
.service__cta:hover { border-color: var(--fg); }
.game__cta { display: block; margin-top: 10px; font-size: 14px; color: var(--fg); }

/* Partners: the last square is for you */
.partners__you a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; width: 100%; height: 100%; text-decoration: none; color: var(--muted); transition: background .2s, color .2s; }
.partners__you b { font-size: clamp(26px, 3vw, 44px); letter-spacing: -0.04em; color: var(--fg); text-transform: uppercase; }
.partners__you span { font-size: 14px; }
.partners__you a:hover { background: var(--fg); color: #000; }
.partners__you a:hover b { color: #000; }
.partners li.partners__you { padding: 0; }

/* Things to play with (js/fun.js) */
.fun-toast { bottom: 96px; }
.foot__line--rules { cursor: pointer; }
.foot__line--rules:hover { color: var(--fg); }
.foot__line a { color: var(--fg); text-decoration: none; }
.foot__secrets { grid-column: 1 / -1; justify-self: start; border: 1px solid var(--line); background: none; color: #00ea9e; border-radius: var(--radius); padding: 6px 14px; font-size: 13px; cursor: pointer; }
.section__head h1, .section__head h2 { cursor: default; }
.o-spin::after { animation: o-spin .7s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes o-spin { to { transform: rotate(360deg) scale(1.2); } }
.fun-pop body { animation: fun-pop .9s cubic-bezier(.3, 1.8, .5, 1); }
@keyframes fun-pop { 30% { transform: scale(1.03); filter: saturate(3) contrast(1.4); } 60% { transform: scale(.99); } }
.fun-rain { position: fixed; inset: 0; pointer-events: none; z-index: 70; overflow: hidden; }
.fun-rain i { position: absolute; top: -20px; width: 12px; height: 12px; background: var(--fg); animation: fun-fall linear forwards; }
@keyframes fun-fall { to { transform: translateY(110vh) rotate(180deg); } }

/* Cookie notice for Google Analytics (js/analytics.js) */
.consent {
  position: fixed; right: 16px; bottom: 16px; z-index: 50; max-width: 340px;
  background: #111; border: 1px solid var(--line); padding: 16px; font-size: 14px; color: #cfcfcf;
}
.consent__buttons { display: flex; gap: 10px; margin-top: 12px; }
@media (max-width: 560px) { .consent { left: 16px; max-width: none; } }

/* Custom cursor (js/cursor.js): only switched on for a mouse */
.has-cursor, .has-cursor * { cursor: none !important; }
.has-cursor :is(input:not([type="checkbox"]):not([type="radio"]), textarea, [contenteditable="true"]) { cursor: text !important; }
.cursor {
  position: fixed; left: 0; top: 0; z-index: 9999; pointer-events: none;
  width: 22px; height: 22px; display: grid; place-items: center;
  background: url("../assets/brand/o-white.svg") center / contain no-repeat;
  mix-blend-mode: difference; /* the white O turns dark over light pictures */
  transition: width .2s, height .2s, border-radius .2s, background-color .2s, opacity .2s;
}
.cursor[data-state="o"].is-down { width: 16px; height: 16px; }
.cursor[data-state="view"], .cursor[data-state="media"] {
  width: 84px; height: 84px; border-radius: 50%; background: var(--fg); mix-blend-mode: normal;
}
.cursor__label { color: #000; font-size: 14px; font-weight: 600; }
.cursor[data-state="invert"] { width: 30px; height: 30px; background: var(--fg); }
.cursor[data-state="invert"].is-down { width: 22px; height: 22px; }
.cursor[data-state="cell"] { background: rgba(255, 255, 255, .14); outline: 2px solid var(--fg); outline-offset: -2px; transition: none; }
.cursor[data-state="hidden"], .cursor.is-away { opacity: 0; }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: 0; }
  .game { width: 100%; max-width: 480px; justify-self: start; }
  .section__head, .about__cols, .ninetails, .modal__info { grid-template-columns: 1fr; }
  .services { grid-template-columns: 1fr; }
  .grid { grid-template-columns: 1fr 1fr; }
  .partners { grid-template-columns: repeat(3, 1fr); }
  .events { grid-template-columns: 1fr 1fr; }
  .events li:nth-child(3) { padding-left: 0; border-left: 0; }
  .foot { grid-template-columns: 1fr; }
  .services-short { grid-template-columns: 1fr; }
  .service { grid-template-columns: 40px 1fr; }
  .service__work { grid-column: 2; }
  .podcast-teaser, .podcast { grid-template-columns: 1fr; }
  .podcast { min-height: 0; }
  .stats { grid-template-columns: repeat(3, 1fr); }
  .stats li:nth-child(4) { padding-left: 0; border-left: 0; }
  .how, .people__list { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .service__work { grid-column: 1 / -1; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stats li:nth-child(odd) { padding-left: 0; border-left: 0; }
  .stats li:nth-child(even) { padding-left: 24px; border-left: 1px solid var(--line); }
  .how { grid-template-columns: 1fr; }
  .facts li { grid-template-columns: 36px 1fr; }
  .grid { grid-template-columns: 1fr; }
  .partners { grid-template-columns: repeat(2, 1fr); }
  .hero__title span:nth-child(2) { padding-left: 0; }
  .case__row { flex-direction: column; }
  .case__row > div { flex: none !important; }
  .case__text { padding: 40px 0; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}

/* Close buttons on projects (after .modal__close so these win) */
.page__close { text-decoration: none; color: var(--fg); top: 76px; }
@media (max-width: 900px) {
  /* the pop-up fills the phone screen, so nothing hangs over its edge; Close stays in its top-right corner */
  .modal { width: 100vw; max-width: none; height: 100dvh; max-height: none; margin: 0; border: 0; }
  .modal__close { position: fixed; top: 12px; right: 12px; margin: 0; float: none; z-index: 30; box-shadow: 0 0 0 4px rgba(0, 0, 0, .6); }
  /* project pages: under the header on the right, clear of the browser's bottom bar */
  .page__close { position: fixed; top: 80px; bottom: auto; right: 12px; z-index: 18; box-shadow: 0 0 0 4px rgba(0, 0, 0, .6); }
}

/* ---------- Phones and small tablets (js/mobile.js adds the ☰ button, the menu and the More buttons) ---------- */
.menu-btn, .mnav, .more-btn { display: none; }
@media (max-width: 900px) {
  /* one line in every language: logo · language · Contact · ☰ */
  .top { flex-wrap: nowrap; }
  .top__nav { width: auto; flex-wrap: nowrap; gap: 14px; }
  .top__nav > a:not(.btn) { display: none; }
  .top__nav .btn { margin-left: 0; white-space: nowrap; }
  .menu-btn {
    display: grid; align-content: center; gap: 5px; width: 40px; height: 40px; padding: 0 9px;
    border: 1px solid var(--line); border-radius: 50%; background: none; cursor: pointer;
  }
  .menu-btn i { display: block; height: 2px; background: var(--fg); transition: transform .25s, opacity .2s; }
  .menu-open .menu-btn i:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .menu-open .menu-btn i:nth-child(2) { opacity: 0; }
  .menu-open .menu-btn i:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .mnav:not([hidden]) {
    display: flex; flex-direction: column; justify-content: space-between; position: fixed; inset: 0; z-index: 19;
    padding: 110px var(--pad) 40px; background: var(--bg); overflow-y: auto;
  }
  .menu-open { overflow: hidden; }
  .mnav__links { display: grid; gap: 6px; }
  .mnav__links a {
    font-size: clamp(26px, 8vw, 52px); font-weight: 700; text-transform: uppercase; letter-spacing: -0.04em; line-height: 1.05; overflow-wrap: anywhere;
    text-decoration: none; color: var(--fg); padding: 6px 0; border-bottom: 1px solid var(--line);
  }
  .mnav__links a::after {
    content: ""; display: inline-block; width: .28em; height: .28em; margin-left: .2em; vertical-align: .1em;
    background: url("../assets/brand/o-white.svg") center / contain no-repeat;
  }
  .mnav__links a:not([aria-current])::after { display: none; }
  .mnav__langs { display: flex; gap: 10px; margin-top: 40px; }
  .mnav__langs a { display: flex; gap: 10px; align-items: center; padding: 10px 18px; border: 1px solid var(--line); border-radius: var(--radius); color: var(--muted); text-decoration: none; }
  .mnav__langs a[aria-current] { background: var(--fg); color: #000; border-color: var(--fg); }
  .mnav__langs b { font-size: 12px; letter-spacing: .06em; }
}
@media (max-width: 560px) {
  .top__nav { gap: 10px; }
  .lang__menu { right: -60px; }

  /* less text: pictures and titles carry the cards and sections */
  .card__summary, .card__tags { display: none; }
  .section__head p { display: none; }
  .section__head { margin-bottom: 28px; }
  .service__text p { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

  /* How we work: swipe through four cards */
  .how { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--pad); gap: 14px; margin: 0 calc(-1 * var(--pad)); padding: 0 var(--pad) 8px; scrollbar-width: none; }
  .how::-webkit-scrollbar { display: none; }
  .how li { flex: 0 0 78%; scroll-snap-align: start; }

  /* three facts, the rest behind "More"; long case texts behind "Read more" */
  .facts:not(.is-open) li:nth-child(n+4) { display: none; }
  .more-btn {
    display: inline-block; margin-top: 16px; padding: 8px 16px; border: 1px solid var(--line); border-radius: var(--radius);
    background: none; color: var(--fg); font: 600 14px var(--font); cursor: pointer;
  }
  .case__text.is-folded p:not(:first-of-type), .case__text.is-folded h2 ~ p:not(:nth-of-type(-n+2)) { display: none; }
  .case__text .more-btn { margin-top: 4px; }

  /* brief: one swipeable row per question; the message box opens after the first pick */
  .brief__chips { flex-wrap: nowrap; overflow-x: auto; scroll-padding-inline: var(--pad); margin: 0 calc(-1 * var(--pad)); padding: 0 var(--pad) 4px; scrollbar-width: none; }
  .brief__chips::-webkit-scrollbar { display: none; }
  .brief__chips .chip { flex: none; }
  .brief:not(.is-open) .brief__msg, .brief:not(.is-open) .brief__regen { display: none; }
  .brief:not(.is-open) label.brief__q { display: inline-block; color: var(--fg); text-decoration: underline; cursor: pointer; }
}

/* ---------- Phones, round 2 ---------- */
@media (max-width: 560px) {
  /* long Armenian words: big titles scale with the screen so a single word always fits */
  :lang(hy) .contact__title, :lang(hy) .section__head h1, :lang(hy) .section__head h2,
  :lang(hy) .podcast h1, :lang(hy) .podcast-teaser h2, :lang(hy) .ninetails h2 { font-size: min(8.4vw, 40px); }
  h1, h2 { overflow-wrap: break-word; }

  /* team: two per row, just the pictures (clue numbers are too small to read here) */
  .people__list { grid-template-columns: 1fr 1fr; gap: 28px 16px; }
  .person .pix--fixed, .person__text { grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); }
  .person .pix__clue, .person .pix__corner { display: none; }
  .person__text > * { grid-column: 1 / -1; }
  .person__name { font-size: 15px; }
  .person__role { font-size: 13px; }
  .person .pix { margin-bottom: 10px; }

  /* sideways rows: a fade at the edge says "there's more"; it goes once you reach the end (js/mobile.js) */
  .swipe { -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 56px), transparent);
           mask-image: linear-gradient(to right, #000 calc(100% - 56px), transparent); }
  .swipe.at-end { -webkit-mask-image: none; mask-image: none; }
}

/* Our video player (js/video.js): a see-through layer over the embed, and a slim control bar */
.vplayer { position: relative; overflow: hidden; background: #000; }
.vplayer iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.vplayer__hit { position: absolute; inset: 0 0 52px; z-index: 1; border: 0; padding: 0; background: transparent; cursor: pointer; }
.vplayer:not(.is-playing) .vplayer__hit::after {
  content: ""; position: absolute; left: 50%; top: calc(50% + 26px); width: 76px; height: 76px; margin: -38px 0 0 -38px; border-radius: 50%;
  background: var(--fg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E") 55% 50% / 30px no-repeat;
}
.has-cursor .vplayer:not(.is-playing) .vplayer__hit::after { display: none; }   /* the cursor says "Play" instead */
.vplayer__bar {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; height: 52px; display: flex; align-items: center; gap: 14px;
  padding: 0 16px; background: linear-gradient(transparent, rgba(0, 0, 0, .85)); color: var(--fg); font-size: 13px;
  transition: opacity .25s;
}
.vplayer.is-playing:not(:hover):not(:focus-within) .vplayer__bar { opacity: 0; }
.vplayer__btn { flex: none; width: 34px; height: 34px; border: 0; border-radius: 50%; background: transparent center / 20px no-repeat; cursor: pointer; }
.vplayer__btn:hover { background-color: rgba(255, 255, 255, .14); }
.vplayer__play { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E"); }
.vplayer.is-playing .vplayer__play { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M6 5h4v14H6zM14 5h4v14h-4z'/%3E%3C/svg%3E"); }
.vplayer__mute { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M4 9v6h4l5 5V4L8 9zm12.5 3a4.5 4.5 0 0 0-2.5-4v8a4.5 4.5 0 0 0 2.5-4z'/%3E%3C/svg%3E"); }
.vplayer.is-muted .vplayer__mute { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M4 9v6h4l5 5V4L8 9zm12.6 3 2.7-2.7-1.4-1.4-2.7 2.7-2.7-2.7-1.4 1.4 2.7 2.7-2.7 2.7 1.4 1.4 2.7-2.7 2.7 2.7 1.4-1.4z'/%3E%3C/svg%3E"); }
.vplayer__full { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M4 4h6v2H6v4H4zm10 0h6v6h-2V6h-4zM4 14h2v4h4v2H4zm14 0h2v6h-6v-2h4z'/%3E%3C/svg%3E"); }
.vplayer__time { flex: none; font-variant-numeric: tabular-nums; color: #cfcfcf; }
.vplayer__track { flex: 1; min-width: 0; height: 4px; appearance: none; -webkit-appearance: none; background: rgba(255, 255, 255, .25); border-radius: 2px; cursor: pointer; accent-color: #00ea9e; }
.vplayer__track::-webkit-slider-thumb { -webkit-appearance: none; width: 12px; height: 12px; border-radius: 50%; background: #00ea9e; }
.vplayer__track::-moz-range-thumb { width: 12px; height: 12px; border: 0; border-radius: 50%; background: #00ea9e; }
.vplayer:not(.has-time) .vplayer__track, .vplayer:not(.has-time) .vplayer__time { visibility: hidden; }
.vplayer:fullscreen { width: 100vw; height: 100vh; aspect-ratio: auto !important; }
@media (max-width: 560px) { .vplayer__time { display: none; } .vplayer__bar { gap: 8px; padding: 0 8px; } }

/* Project buttons: "Behance" on its own on phones, both buttons the same size */
.lbl-short { display: none; }
@media (max-width: 560px) {
  .lbl-long { display: none; }
  .lbl-short { display: inline; }
  .modal__links { display: flex; flex-wrap: nowrap; gap: 10px; }
  .modal__links .btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 18px; font-size: 15px; white-space: nowrap; }
}

/* ---------- Phone top bar: fixed, slides away when scrolling down, back when scrolling up (js/mobile.js) ---------- */
@media (max-width: 900px) {
  .top {
    position: fixed; top: 0; left: 0; right: 0; width: 100%; z-index: 20;
    min-height: calc(60px + env(safe-area-inset-top)); padding: env(safe-area-inset-top) var(--pad) 0;
    background: rgba(0, 0, 0, .9); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
    transform: translateY(0); transition: transform 250ms ease; will-change: transform;
  }
  .top.is-hidden { transform: translateY(-100%); }
  body { padding-top: calc(60px + env(safe-area-inset-top)); }
  html { scroll-padding-top: calc(72px + env(safe-area-inset-top)); }
  .mnav:not([hidden]) { padding-top: calc(96px + env(safe-area-inset-top)); }
  /* every tap target at least 44px */
  .top__logo { display: flex; align-items: center; min-height: 44px; }
  .top__nav .btn { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; }
  .lang summary { min-height: 44px; min-width: 44px; padding: 0 4px; justify-content: center; }
  .menu-btn { width: 44px; height: 44px; padding: 0 11px; }
  .page__close { top: calc(72px + env(safe-area-inset-top)); }
}
@media (max-width: 900px) and (prefers-reduced-motion: reduce) { .top { transition: none; } }
