/* Vatani Tech website. One stylesheet for every page: deep night colours,
   points of light, teal accents. */
:root {
  --bg: #04060c;
  --bg-2: #080c18;
  --card: #0b1020;
  --line: rgba(120, 140, 200, .16);
  --line-2: rgba(140, 160, 220, .28);
  --text: #f3f5fb;
  --muted: #95a0bd;
  --dim: #5f6a8c;
  --navy: #1e2a5a;
  /* The accent colour, as three numbers so that it can be made see-through.
     An app's page sets its own (see ACCENT in build.py). */
  --acc: 44,196,184;
  --acc2: 127,240,228;
  --teal: rgb(var(--acc));
  --teal-2: rgb(var(--acc2));
  --radius: 22px;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --serif: "Instrument Serif", "Iowan Old Style", Georgia, serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
[id] { scroll-margin-top: 96px; }
body {
  --teal: rgb(var(--acc)); --teal-2: rgb(var(--acc2));   /* again here: an app's page sets --acc on the body */
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.65 var(--sans); -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* Soft coloured light behind everything, and a whisper of film grain. */
body::before {
  content: ""; position: fixed; inset: -20%; z-index: -2; pointer-events: none;
  background:
    radial-gradient(40% 36% at 78% 18%, rgba(var(--acc),.13), transparent 70%),
    radial-gradient(46% 40% at 12% 8%, rgba(46,64,150,.34), transparent 70%),
    radial-gradient(50% 40% at 50% 100%, rgba(30,42,90,.4), transparent 70%);
  animation: drift 26s ease-in-out infinite alternate;
}
body::after {
  content: ""; position: fixed; inset: 0; z-index: 60; pointer-events: none; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E");
}
@keyframes drift { to { transform: translate3d(3%, 4%, 0) scale(1.08); } }
a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 28px; }
h1, h2, h3, h4 { letter-spacing: -.03em; margin: 0; }
em.s { font-family: var(--serif); font-style: italic; font-weight: 400; letter-spacing: -.015em;
  background: linear-gradient(100deg, #fff 0%, var(--teal-2) 45%, var(--teal) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent; padding-right: .06em; }
.grey { color: #6c7697; }

.label { font: 500 12px/1.4 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--teal); }
.label .n { color: var(--dim); }
.pill { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px 8px 12px; border-radius: 999px;
  border: 1px solid var(--line-2); background: rgba(12,18,36,.6); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  font: 500 11.5px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: #c6cee4; }
.pill i { width: 7px; height: 7px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 0 rgba(var(--acc),.7); animation: beat 2.2s infinite; }
@keyframes beat { 70% { box-shadow: 0 0 0 9px rgba(var(--acc),0); } 100% { box-shadow: 0 0 0 0 rgba(var(--acc),0); } }

/* Header */
.site-header { position: sticky; top: 0; z-index: 40; background: rgba(4,6,12,.62);
  backdrop-filter: saturate(150%) blur(14px); -webkit-backdrop-filter: saturate(150%) blur(14px);
  border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 24px; height: 70px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-size: 19px; letter-spacing: -.01em; }
.brand:hover { text-decoration: none; }
.brand svg { width: 34px; height: 28px; }
.brand b { font-weight: 600; }
.brand span { color: #2cc4b8; font-weight: 400; }   /* the studio's own teal, on every page */
.nav { margin-left: auto; display: flex; align-items: center; gap: 28px; }
.nav a { color: var(--muted); font: 500 12px/1 var(--mono); letter-spacing: .13em; text-transform: uppercase; transition: color .2s; }
.nav a:hover { color: var(--text); text-decoration: none; }
.btn { position: relative; display: inline-flex; align-items: center; gap: 10px; padding: 14px 22px; border-radius: 999px;
  font: 500 12px/1 var(--mono); letter-spacing: .13em; text-transform: uppercase;
  border: 1px solid var(--line-2); color: var(--text); background: rgba(12,18,36,.5);
  transition: border-color .25s, background .25s, transform .25s, box-shadow .25s; }
.btn:hover { border-color: var(--teal); text-decoration: none; transform: translateY(-1px); }
.btn.solid { background: linear-gradient(120deg, var(--teal-2), var(--teal)); border-color: transparent; color: #03131a;
  box-shadow: 0 10px 40px -10px rgba(var(--acc),.7); }
.btn.solid:hover { box-shadow: 0 14px 50px -8px rgba(var(--acc),.9); }
.btn .arr { display: inline-block; transition: transform .25s; }
.btn:hover .arr { transform: translateX(4px); }
.btn[aria-disabled="true"] { color: var(--muted); cursor: default; }
.btn[aria-disabled="true"]:hover { border-color: var(--line-2); transform: none; }
.nav .btn { padding: 11px 17px; color: var(--text); }

/* Language menu in the header (English, Azerbaijani, Russian) */
.lang { position: relative; }
.lang summary { display: inline-flex; align-items: center; gap: 7px; padding: 10px 13px 10px 11px; border-radius: 999px; cursor: pointer; list-style: none; user-select: none;
  font: 500 12px/1 var(--mono); letter-spacing: .13em; color: var(--text); border: 1px solid var(--line-2); background: rgba(12,18,36,.5); transition: border-color .25s; }
.lang summary::-webkit-details-marker { display: none; }
.lang summary:hover, .lang[open] summary { border-color: var(--teal); }
.lang summary svg { width: 15px; height: 15px; color: var(--teal); }
.lang-menu { position: absolute; right: 0; top: calc(100% + 10px); min-width: 196px; padding: 6px; display: grid; gap: 2px; border-radius: 16px;
  border: 1px solid var(--line-2); background: #0a0f1e; box-shadow: 0 24px 60px -12px rgba(0,0,0,.85); animation: rise .25s cubic-bezier(.2,.7,.2,1); }
.lang-menu a { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 11px 12px; border-radius: 11px; color: var(--muted); font-size: 14.5px; line-height: 1; }
.lang-menu a:hover { color: var(--text); background: rgba(var(--acc),.1); text-decoration: none; }
.lang-menu a[aria-current] { color: var(--text); }
.lang-menu a[aria-current]::after { content: "✓"; color: var(--teal); }

/* Azerbaijani and Russian pages. The italic accent font (Instrument Serif)
   has no Cyrillic letters and no "ə", so these pages use Playfair Display;
   it runs wider, so it is set a little smaller. Russian words are longer,
   so its big headings are a touch smaller too. */
html[lang="az"], html[lang="ru"] { --serif: "Playfair Display", "Iowan Old Style", Georgia, serif; }
html[lang="az"] em.s, html[lang="ru"] em.s { letter-spacing: -.02em; }
html[lang="az"] .hero h1 em.s, html[lang="ru"] .hero h1 em.s,
html[lang="az"] .block-head h2 em.s, html[lang="ru"] .block-head h2 em.s { font-size: .94em; }
html[lang="ru"] .block-head h2 { font-size: clamp(32px, 4.5vw, 58px); }

/* Appear on scroll (only when scripts run) */
.js .rv { opacity: 0; transform: translateY(26px); transition: opacity .9s cubic-bezier(.2,.7,.2,1), transform .9s cubic-bezier(.2,.7,.2,1); transition-delay: var(--d, 0s); }
.js .rv.in { opacity: 1; transform: none; }

/* Hero */
.hero { position: relative; min-height: min(100svh, 940px); display: flex; align-items: center; overflow: hidden; }
.sculpt { position: absolute; top: 0; bottom: 0; right: -7%; width: 64%; }
.sculpt::before { content: ""; position: absolute; inset: 8%; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(var(--acc),.16), rgba(40,60,150,.14) 55%, transparent 75%); }
.sculpt canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.sculpt-cap { position: absolute; left: 0; right: 0; bottom: 9%; text-align: center; opacity: 0; transform: translateY(6px);
  transition: opacity .5s, transform .5s; font: 500 11.5px/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.sculpt-cap.on { opacity: 1; transform: none; }
.sculpt-cap b { color: var(--teal); font-weight: 500; margin-right: 8px; }
.hero .wrap { position: relative; z-index: 2; width: 100%; padding-top: 40px; padding-bottom: 70px; }
.hero-copy { max-width: 640px; }
.hero h1 { font-size: clamp(54px, 8.6vw, 124px); line-height: .94; font-weight: 700; letter-spacing: -.05em; margin: 26px 0 0; }
.hero h1 em.s { font-size: 1.06em; letter-spacing: -.03em; }
.hero p.lead { max-width: 520px; color: var(--muted); font-size: 18.5px; margin: 30px 0 38px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.scroll-hint { position: absolute; left: 28px; bottom: 26px; z-index: 2; font: 500 11px/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--dim); display: flex; align-items: center; gap: 12px; }
.scroll-hint::before { content: ""; width: 1px; height: 34px; background: linear-gradient(var(--teal), transparent); animation: drop 2.2s ease-in-out infinite; transform-origin: top; }
@keyframes drop { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }

/* Numbers strip */
.stats { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: rgba(8,12,24,.5); }
.stats .wrap { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: 34px 26px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; padding-left: 0; }
.stat b { display: block; font-size: clamp(38px, 4.6vw, 62px); font-weight: 700; letter-spacing: -.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.stat b small { font-size: .45em; color: var(--teal); font-weight: 500; margin-left: 4px; letter-spacing: 0; }
.stat > span { display: block; margin-top: 10px; color: var(--muted); font: 500 11.5px/1.5 var(--mono); letter-spacing: .12em; text-transform: uppercase; }

/* Moving band of words */
.band { overflow: hidden; padding: 34px 0; border-bottom: 1px solid var(--line); -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.band-track { display: flex; width: max-content; animation: slide 42s linear infinite; }
.band span { font-size: clamp(34px, 5vw, 64px); font-weight: 700; letter-spacing: -.035em; white-space: nowrap; padding-right: .9em;
  color: transparent; -webkit-text-stroke: 1px rgba(150,170,230,.42); }
.band span i { font-style: normal; color: var(--teal); -webkit-text-stroke: 0; margin-left: .9em; font-size: .5em; vertical-align: middle; }
.band span.f { color: var(--text); -webkit-text-stroke: 0; }
@keyframes slide { to { transform: translateX(-50%); } }

/* Sections */
section.block { padding: 130px 0; position: relative; }
.block-head { display: grid; grid-template-columns: 1.5fr 1fr; gap: 40px; align-items: end; margin-bottom: 52px; }
.block-head h2 { font-size: clamp(36px, 5.2vw, 68px); line-height: 1; font-weight: 700; letter-spacing: -.045em; margin-top: 20px; }
.block-head h2 em.s { font-size: 1.08em; }
.block-head p { color: var(--muted); margin: 0; font-size: 17px; }

/* Cards that light up under the pointer */
.glow { position: relative; isolation: isolate; }
.glow::before { content: ""; position: absolute; inset: 0; border-radius: inherit; z-index: -1; opacity: 0; transition: opacity .4s;
  background: radial-gradient(380px circle at var(--mx, 50%) var(--my, 50%), rgba(var(--acc),.16), transparent 60%); }
.glow::after { content: ""; position: absolute; inset: -1px; border-radius: inherit; z-index: -1; opacity: 0; transition: opacity .4s; padding: 1px;
  background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 50%), rgba(var(--acc2),.75), transparent 60%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; }
.glow:hover::before, .glow:hover::after { opacity: 1; }

/* Showcase: the list of every app, and one panel per app. On wide screens
   the list is a column on the left that stays in view while the panel
   scrolls (when the window is tall enough for all of it: site.js then adds
   "stick"); up to 1099px it is a grid of all the apps above the panel.
   Never a row that scrolls sideways: every app is always in sight. Each
   app in the list wears its own colour (--acc on the button). */
.showcase { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 44px; align-items: start; }
.tabs { display: flex; flex-direction: column; gap: 3px; border-left: 1px solid var(--line); }
.tabs.stick { position: sticky; top: 96px; }
.tab { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 52px; padding: 9px 14px 9px 16px; margin-left: -1px;
  background: none; border: 0; border-left: 2px solid transparent; border-radius: 0 14px 14px 0; cursor: pointer; text-align: left;
  color: var(--muted); font: 500 13.5px/1.2 var(--mono); letter-spacing: .03em; -webkit-tap-highlight-color: transparent;
  transition: color .2s, background-color .2s, border-color .2s; }
.tab .n { flex: none; min-width: 20px; font-size: 11.5px; letter-spacing: .06em; }
.tab img { flex: none; width: 32px; height: 32px; border-radius: 9px; opacity: .6; filter: saturate(.55); transition: opacity .2s, filter .2s, box-shadow .2s; }
.tab .nm { min-width: 0; }
.tab:hover { color: var(--text); background-color: rgba(var(--acc), .06); }
.tab:hover img { opacity: .9; filter: none; }
.tab[aria-selected="true"] { color: var(--text); border-left-color: rgb(var(--acc)); background-color: rgba(var(--acc), .12); }
.tab[aria-selected="true"] .n { color: rgb(var(--acc)); }
.tab[aria-selected="true"] img { opacity: 1; filter: none; box-shadow: 0 6px 22px -6px rgba(var(--acc), .85); }
.tab:focus-visible { outline: 2px solid rgb(var(--acc)); outline-offset: 2px; }
.panels { min-width: 0; }
/* Closed panels are hidden only when the scripts run: at first by the page's
   "js-one" class, which stays until every script has had its turn (however
   slow the connection), then by the list's own "on", once site.js has set
   it up. Without them every app's panel is shown, one after another, and
   the list and the pager, which would do nothing, are not. */
.js-one .panel.off, .showcase.on .panel.off { display: none; }
html:not(.js-one) .showcase:not(.on) { grid-template-columns: minmax(0, 1fr); }
html:not(.js-one) .showcase:not(.on) .tabs, html:not(.js-one) .showcase:not(.on) .pager { display: none; }
.panel { animation: rise .3s cubic-bezier(.2,.7,.2,1); --teal: rgb(var(--acc)); --teal-2: rgb(var(--acc2)); }   /* each app's tab in its own colour */
@keyframes rise { from { opacity: .35; transform: translateY(10px); } }
.js .panel.now .rv { transition: none; }   /* an app just opened shows all of itself at once */
.app-line { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-bottom: 26px; }
.app-line img { width: 68px; height: 68px; border-radius: 17px; box-shadow: 0 16px 50px -12px var(--glow, rgba(63,81,181,.9)); }
.app-lead { color: var(--muted); font-size: 17px; max-width: 720px; margin: 0 0 26px; }
.app-line h3 { font-size: clamp(30px, 4vw, 46px); font-weight: 700; line-height: 1.05; }
.app-line .sub { color: var(--muted); margin-top: 2px; }
.app-line .chips { margin-left: auto; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { font: 500 11px/1 var(--mono); letter-spacing: .09em; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line-2); border-radius: 999px; padding: 9px 12px; background: rgba(10,14,28,.5); }
.chip.on { color: var(--teal); border-color: rgba(var(--acc),.5); }
.showcase-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 26px; color: var(--dim); font: 500 12px/1 var(--mono); letter-spacing: .08em; }
.pager { display: flex; align-items: center; gap: 14px; white-space: nowrap; }
.pager button { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-2); background: none; color: var(--text); cursor: pointer; font-size: 16px; transition: border-color .2s, background .2s; }
.pager button:hover { border-color: var(--teal); background: rgba(var(--acc),.08); }

/* Bento grid of living tiles */
.bento { display: grid; grid-template-columns: repeat(12, 1fr); gap: 16px; }
.tile { grid-column: span 4; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  background: linear-gradient(180deg, rgba(20,28,54,.62), rgba(9,13,26,.72)); padding: 26px; display: flex; flex-direction: column; min-height: 330px; }
.tile.w5 { grid-column: span 5; } .tile.w6 { grid-column: span 6; } .tile.w7 { grid-column: span 7; } .tile.w8 { grid-column: span 8; } .tile.w12 { grid-column: span 12; }
/* One column as wide as the tile: a drawing wider than that stays centred. */
.tile .viz { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr); place-items: center; min-height: 170px; margin-bottom: 22px; position: relative; }
.tile .cap { font: 500 11px/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--teal); margin-bottom: 10px; }
.tile h4 { font-size: 21px; letter-spacing: -.02em; line-height: 1.2; }
.tile p { color: var(--muted); margin: 8px 0 0; font-size: 14.5px; line-height: 1.55; }
.tile *, .tile *::before, .tile *::after { animation-play-state: paused; }
.tile.live *, .tile.live *::before, .tile.live *::after { animation-play-state: running; }
/* On the home page an app's tiles go two to a row, and a wide one (w7, w8)
   takes the whole row: beside the list of apps a panel is at most about
   850px wide, too narrow for three. (Phones: one to a row, see below.) */
.panels .tile, .panels .tile.w5, .panels .tile.w6 { grid-column: span 6; }
.panels .tile.w7, .panels .tile.w8 { grid-column: span 12; }

/* Tile: world map */
.vmap { width: 100%; }
.vmap svg { width: 100%; height: auto; display: block; overflow: visible; }
.vmap .dots { stroke: rgba(170,188,245,.42); stroke-width: 2.3; stroke-linecap: round; fill: none; }
.vmap .core { fill: var(--teal-2); }
.vmap .ring { fill: none; stroke: var(--teal); stroke-width: 1.2; transform-box: fill-box; transform-origin: center; animation: ping 2.8s ease-out infinite; animation-delay: var(--d, 0s); }
@keyframes ping { 0% { transform: scale(1); opacity: .9; } 100% { transform: scale(6.5); opacity: 0; } }
.vmap .tag { position: absolute; left: 4%; bottom: 2%; }

/* Tile: converter */
.conv { width: 100%; max-width: 340px; display: grid; gap: 10px; }
.conv .row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 16px 18px; border-radius: 16px; border: 1px solid var(--line); background: rgba(6,9,18,.6); }
.conv .row.out { border-color: rgba(var(--acc),.45); background: linear-gradient(120deg, rgba(var(--acc),.14), rgba(6,9,18,.5)); }
.conv .num { font: 500 clamp(26px, 3vw, 34px)/1 var(--mono); font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.conv .out .num { color: var(--teal-2); }
.conv .unit { font: 500 13px/1 var(--mono); color: var(--muted); letter-spacing: .08em; }
.conv .swap { justify-self: center; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line-2); display: grid; place-items: center; color: var(--teal); margin: -4px 0; background: var(--bg-2); animation: spin 5.2s ease-in-out infinite; }
@keyframes spin { 0%, 40% { transform: rotate(0); } 50%, 90% { transform: rotate(180deg); } 100% { transform: rotate(360deg); } }

/* Tile: flashcard */
.flash { width: min(100%, 300px); height: 172px; perspective: 1000px; position: relative; }
.flash::before, .flash::after { content: ""; position: absolute; inset: 0; border-radius: 18px; border: 1px solid var(--line); background: rgba(14,20,40,.7); }
.flash::before { transform: translateY(16px) scale(.9); opacity: .45; }
.flash::after { transform: translateY(8px) scale(.95); opacity: .7; }
.flash-in { position: absolute; inset: 0; z-index: 1; transform-style: preserve-3d; transition: transform .9s cubic-bezier(.3,.8,.2,1); }
.flash.flip .flash-in { transform: rotateY(180deg); }
.face { position: absolute; inset: 0; border-radius: 18px; padding: 22px; display: flex; flex-direction: column; justify-content: center; backface-visibility: hidden; -webkit-backface-visibility: hidden;
  border: 1px solid var(--line-2); background: linear-gradient(150deg, #18224a, #0b1022); }
.face.back { transform: rotateY(180deg); background: linear-gradient(150deg, color-mix(in srgb, rgb(var(--acc)) 26%, #0a1424), #0a1424); border-color: rgba(var(--acc),.5); }
.face small { font: 500 10.5px/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--teal); margin-bottom: 12px; }
.face b { font-size: 24px; letter-spacing: -.025em; line-height: 1.15; }
.face span { font-size: 15px; line-height: 1.5; color: #d5dcf0; }

/* Tile: quiz */
.quiz { width: 100%; max-width: 330px; display: grid; gap: 8px; }
.quiz .q { font-size: 15.5px; font-weight: 600; margin-bottom: 6px; display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.quiz .ringbox { flex: 0 0 auto; width: 44px; height: 44px; position: relative; display: grid; place-items: center; font: 500 10px/1 var(--mono); color: var(--muted); }
.quiz .ringbox svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.quiz .ringbox circle { fill: none; stroke-width: 3; }
.quiz .ringbox .tr { stroke: rgba(140,160,220,.2); }
.quiz .ringbox .pr { stroke: var(--teal); stroke-linecap: round; stroke-dasharray: 113; stroke-dashoffset: 34; animation: ring 7s ease-in-out infinite; }
@keyframes ring { 0%, 38% { stroke-dashoffset: 34; } 50%, 92% { stroke-dashoffset: 22.6; } 100% { stroke-dashoffset: 34; } }
.opt { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-radius: 12px; border: 1px solid var(--line); background: rgba(6,9,18,.55); font-size: 14px; color: #cfd6ea; }
.opt i { width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid var(--line-2); flex: 0 0 auto; display: grid; place-items: center; font-style: normal; font-size: 10px; color: transparent; }
.opt.ok { animation: pick 7s ease-in-out infinite; }
.opt.ok i { animation: tick 7s ease-in-out infinite; }
@keyframes pick { 0%, 36% { border-color: var(--line); background: rgba(6,9,18,.55); } 44%, 92% { border-color: rgba(var(--acc),.65); background: rgba(var(--acc),.14); color: #fff; } 100% { border-color: var(--line); } }
@keyframes tick { 0%, 36% { background: transparent; color: transparent; border-color: var(--line-2); } 44%, 92% { background: var(--teal); color: #03131a; border-color: var(--teal); } 100% { background: transparent; color: transparent; } }
.streak { display: inline-flex; align-items: center; gap: 8px; margin-top: 8px; font: 500 11px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: #ffc38a; }
.streak svg { width: 14px; height: 14px; }

/* Tile: languages */
.langs7 { text-align: center; width: 100%; }
.langword { font-size: clamp(32px, 3.5vw, 50px); white-space: nowrap; font-weight: 700; letter-spacing: -.04em; line-height: 1.15; min-height: 1.2em; transition: opacity .35s, filter .35s, transform .35s;
  background: linear-gradient(100deg, #fff, var(--teal-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.langword.out { opacity: 0; filter: blur(8px); transform: translateY(8px); }
.langs7 .chips { justify-content: center; margin-top: 18px; gap: 6px; }
.langs7 .chip { padding: 8px 9px; transition: color .3s, border-color .3s, background .3s; }
.langs7 .chip.on { background: rgba(var(--acc),.14); }

/* Tile: market chart */
.chart { width: 100%; }
.chart svg { width: 100%; height: auto; display: block; overflow: visible; }
.chart .grid { stroke: rgba(140,160,220,.14); stroke-dasharray: 3 6; }
.chart .l1, .chart .l2 { fill: none; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 1; }
.chart .l1 { stroke: var(--teal); stroke-width: 2.4; }
.chart .l2 { stroke: rgba(200,212,255,.45); stroke-width: 1.6; }
.chart .area { opacity: 0; }
.tile.seen .chart .l1 { animation: draw 2.6s cubic-bezier(.4,0,.2,1) forwards; }
.tile.seen .chart .l2 { animation: draw 2.6s .3s cubic-bezier(.4,0,.2,1) forwards; }
.tile.seen .chart .area { animation: fade 1.2s 1.6s forwards; }
.tile.seen .chart .end { animation: fade .4s 2.4s forwards; }
.chart .end { opacity: 0; }
.chart .end .ring { fill: none; stroke: var(--teal); transform-box: fill-box; transform-origin: center; animation: ping 2.4s ease-out infinite; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fade { to { opacity: 1; } }
.chart .chips { margin-top: 14px; }

/* Tile: interview */
.talk { width: 100%; max-width: 420px; display: grid; gap: 10px; }
.talk .ask { justify-self: start; max-width: 88%; padding: 13px 16px; border-radius: 16px 16px 16px 4px; background: #172044; border: 1px solid var(--line-2); font-size: 14.5px; }
.talk .ans { justify-self: end; width: 86%; padding: 14px 16px; border-radius: 16px 16px 4px 16px; border: 1px solid rgba(var(--acc),.4); background: rgba(var(--acc),.09); }
.talk .ans small { font: 500 10.5px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--teal); display: block; margin-bottom: 10px; }
.talk .ln { height: 7px; border-radius: 4px; background: linear-gradient(90deg, rgba(200,215,255,.5), rgba(200,215,255,.18)); margin-top: 7px; transform-origin: left; animation: type 6s ease-in-out infinite; }
.talk .ln:nth-child(3) { width: 82%; animation-delay: .25s; } .talk .ln:nth-child(4) { width: 60%; animation-delay: .5s; }
@keyframes type { 0%, 8% { transform: scaleX(0); } 30%, 90% { transform: scaleX(1); } 100% { transform: scaleX(0); } }

/* Tile: offline */
.offline { position: relative; width: 190px; height: 190px; display: grid; place-items: center; }
.offline span { position: absolute; inset: 0; border-radius: 50%; border: 1px solid rgba(var(--acc),.5); animation: wave 3.6s ease-out infinite; }
.offline span:nth-child(2) { animation-delay: 1.2s; } .offline span:nth-child(3) { animation-delay: 2.4s; }
@keyframes wave { 0% { transform: scale(.32); opacity: .9; } 100% { transform: scale(1); opacity: 0; } }
.offline .core { width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(140deg, color-mix(in srgb, rgb(var(--acc)) 28%, #0b1428), #0b1428); border: 1px solid rgba(var(--acc),.6); box-shadow: 0 0 60px -6px rgba(var(--acc),.6); }
.offline .core svg { width: 34px; height: 34px; }

/* Tile: ruler (Geo-Rulers) */
.rulerviz, .angle { width: 100%; max-width: 470px; }
.rulerviz svg, .angle svg, .scan svg { width: 100%; height: auto; display: block; overflow: visible; }
.rulerviz .rock, .scan .rock { fill: rgba(150,170,230,.1); stroke: rgba(200,212,255,.6); stroke-width: 1.4; stroke-linejoin: round; }
.rulerviz .facet, .scan .facet { fill: none; stroke: rgba(200,212,255,.28); stroke-width: 1; }
.rulerviz .body { fill: rgba(var(--acc),.1); stroke: rgba(var(--acc),.55); }
.rulerviz .tick { stroke: rgba(var(--acc2),.75); stroke-width: 1; }
.rulerviz text, .angle text { font: 500 11px/1 var(--mono); fill: var(--muted); }
.rulerviz .guide { stroke: var(--teal-2); stroke-width: 1.4; stroke-dasharray: 3 4; }
.rulerviz .g1 { animation: g1 7s cubic-bezier(.3,.7,.2,1) infinite; }
.rulerviz .g2 { animation: g2 7s cubic-bezier(.3,.7,.2,1) infinite; }
@keyframes g1 { 0%, 8% { transform: translateX(96px); opacity: 0; } 14% { opacity: 1; } 36%, 90% { transform: none; opacity: 1; } 100% { transform: none; opacity: 0; } }
@keyframes g2 { 0%, 8% { transform: translateX(-96px); opacity: 0; } 14% { opacity: 1; } 36%, 90% { transform: none; opacity: 1; } 100% { transform: none; opacity: 0; } }
.rulerviz .read { animation: readout 7s ease infinite; }
.rulerviz .read line { stroke: var(--teal); stroke-width: 1.4; }
.rulerviz .read text { fill: var(--teal-2); font-size: 17px; }
@keyframes readout { 0%, 34% { opacity: 0; } 42%, 90% { opacity: 1; } 100% { opacity: 0; } }

/* Tile: protractor (Geo-Rulers) */
.angle { max-width: 330px; }
.angle .arc { fill: rgba(var(--acc),.07); stroke: rgba(var(--acc),.55); stroke-width: 1.4; }
.angle .tick { stroke: rgba(var(--acc2),.7); stroke-width: 1; }
.angle .base { stroke: rgba(200,212,255,.5); stroke-width: 1.4; }
.angle .needle { transform-box: view-box; transform-origin: 150px 160px; animation: dip 7s cubic-bezier(.4,0,.2,1) infinite; }
.angle .needle line { stroke: var(--teal-2); stroke-width: 2.4; stroke-linecap: round; }
.angle .needle circle { fill: var(--teal-2); }
.angle .hub { fill: var(--bg-2); stroke: var(--teal); stroke-width: 1.6; }
@keyframes dip { 0%, 10% { transform: rotate(0); } 40%, 88% { transform: rotate(-35deg); } 100% { transform: rotate(0); } }
.angle .deg { fill: var(--teal-2); font-size: 22px; animation: readout 7s ease infinite; }

/* Tile: camera scanner (Geo-Rulers) */
.scan { width: 100%; max-width: 470px; display: grid; grid-template-columns: 150px 1fr; gap: 26px; align-items: center; }
.scan .finder { position: relative; aspect-ratio: 1; border-radius: 18px; background: rgba(6,9,18,.6); display: grid; place-items: center; padding: 22px; overflow: hidden;
  background-image: linear-gradient(var(--teal), var(--teal)), linear-gradient(var(--teal), var(--teal)), linear-gradient(var(--teal), var(--teal)), linear-gradient(var(--teal), var(--teal)), linear-gradient(var(--teal), var(--teal)), linear-gradient(var(--teal), var(--teal)), linear-gradient(var(--teal), var(--teal)), linear-gradient(var(--teal), var(--teal));
  background-repeat: no-repeat; background-size: 22px 2px, 2px 22px, 22px 2px, 2px 22px, 22px 2px, 2px 22px, 22px 2px, 2px 22px;
  background-position: 10px 10px, 10px 10px, calc(100% - 10px) 10px, calc(100% - 10px) 10px, 10px calc(100% - 10px), 10px calc(100% - 10px), calc(100% - 10px) calc(100% - 10px), calc(100% - 10px) calc(100% - 10px); }
.scan .beam { position: absolute; left: 12px; right: 12px; top: 0; height: 34px; background: linear-gradient(180deg, transparent, rgba(var(--acc),.3)); border-bottom: 2px solid var(--teal-2); animation: beam 3.4s ease-in-out infinite alternate; }
@keyframes beam { from { transform: translateY(-20px); } to { transform: translateY(124px); } }
.scan .guess { display: grid; gap: 12px; }
.scan .row { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; font-size: 14.5px; color: #cfd6ea; }
.scan .row b { font: 500 12px/1.6 var(--mono); color: var(--muted); }
.scan .row i { grid-column: 1 / -1; height: 6px; border-radius: 3px; background: rgba(140,160,220,.16); overflow: hidden; }
.scan .row i::after { content: ""; display: block; height: 100%; width: var(--w); border-radius: 3px; background: rgba(200,212,255,.5); transform-origin: left; animation: fill 6.8s cubic-bezier(.3,.7,.2,1) infinite; animation-delay: var(--d, 0s); }
[dir="rtl"] .scan .row i::after { transform-origin: right; }
.scan .row:first-child { color: #fff; font-weight: 600; }
.scan .row:first-child b { color: var(--teal-2); }
.scan .row:first-child i::after { background: linear-gradient(90deg, var(--teal), var(--teal-2)); }
@keyframes fill { 0%, 22% { transform: scaleX(0); } 46%, 92% { transform: scaleX(1); } 100% { transform: scaleX(0); } }

/* Tile: two apps that belong together */
.pair { display: flex; align-items: center; justify-content: center; gap: 0; }
.pair img { width: 84px; height: 84px; border-radius: 20px; box-shadow: 0 20px 60px -14px var(--glow, rgba(var(--acc),.9)); }
.pair .link { width: 84px; height: 2px; position: relative; background: repeating-linear-gradient(90deg, rgba(var(--acc2),.55) 0 6px, transparent 6px 12px); }
.pair .link::after { content: ""; position: absolute; top: -4px; left: 0; width: 10px; height: 10px; border-radius: 50%; background: var(--teal-2); box-shadow: 0 0 16px var(--teal); animation: hop 2.8s ease-in-out infinite alternate; }
@keyframes hop { to { transform: translateX(74px); } }
.tile h4 a { color: inherit; }
/* A smaller picture in narrower tiles: on phones, and two tiles to a row up to 720px */
@media (max-width: 720px) { .scan { grid-template-columns: 120px 1fr; gap: 18px; } @keyframes beam { from { transform: translateY(-20px); } to { transform: translateY(94px); } } }

/* Tile: a verse with its translation (Quran Guardians) */
.verse { width: 100%; max-width: 460px; text-align: center; }
.verse .ref { font: 500 11px/1 var(--mono); letter-spacing: .16em; color: var(--teal); }
.verse .ar, .hide span { font-family: "Amiri Quran", "Amiri", "Geeza Pro", "Noto Naskh Arabic", "Traditional Arabic", serif; color: #fff; }
.verse .ar { font-size: clamp(26px, 3.2vw, 38px); line-height: 2; direction: rtl; margin: 6px 0 4px; }
.verse .tr { display: grid; gap: 7px; justify-items: center; margin-bottom: 18px; }
.verse .tr i { height: 7px; width: 74%; border-radius: 4px; background: linear-gradient(90deg, rgba(200,215,255,.18), rgba(200,215,255,.5), rgba(200,215,255,.18)); transform-origin: center; animation: type 7s ease-in-out infinite; }
.verse .tr i + i { width: 48%; animation-delay: .3s; }
.verse .chips { justify-content: center; gap: 6px; }
.verse .chip { padding: 8px 9px; }
.verse .src { display: inline-block; margin-top: 14px; font-size: 11.5px; color: var(--dim); }

/* Tile: words hidden for memorising (Quran Guardians) */
.hidebox { display: grid; gap: 20px; justify-items: center; width: 100%; }
.hide { direction: rtl; display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.hide span { font-size: 25px; line-height: 1.9; padding: 2px 14px; border-radius: 12px; border: 1px solid var(--line-2); background: rgba(6,9,18,.55); }
.hide span + span { border-color: rgba(var(--acc),.4); }
.hide b { font-weight: 400; display: inline-block; animation: veil 9s ease-in-out infinite; animation-delay: var(--d, 0s); }
@keyframes veil { 0%, 16% { opacity: 1; filter: none; } 26%, 68% { opacity: 0; filter: blur(7px); } 80%, 100% { opacity: 1; filter: none; } }
.hidebox .chips { justify-content: center; gap: 6px; }
.hidebox .chip { padding: 8px 10px; }

/* Tile: the days of review (Quran Guardians) */
.sched { width: 100%; max-width: 470px; }
.sched svg, .ship svg, .prop svg { width: 100%; height: auto; display: block; overflow: visible; }
.sched .rail { stroke: rgba(140,160,220,.25); stroke-width: 2; }
.sched .go { stroke: var(--teal); stroke-width: 2; stroke-dasharray: 1; stroke-dashoffset: 1; animation: go 9s ease-in-out infinite; }
@keyframes go { 0%, 4% { stroke-dashoffset: 1; } 62%, 90% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: 1; } }
.sched circle { fill: var(--bg-2); stroke: var(--line-2); stroke-width: 1.6; animation: lit 9s ease-in-out infinite; animation-delay: var(--d, 0s); }
@keyframes lit { 0%, 3% { fill: var(--bg-2); stroke: var(--line-2); } 9%, 80% { fill: var(--teal); stroke: var(--teal-2); } 96%, 100% { fill: var(--bg-2); stroke: var(--line-2); } }
.sched text { font: 500 13px/1 var(--mono); fill: var(--text); }
.sched text.u { fill: var(--muted); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; }

/* Tile: a ship on the waves (MarineGram) */
.ship { width: 100%; max-width: 480px; }
.ship .boat { animation: bob 5s ease-in-out infinite alternate; transform-box: fill-box; transform-origin: center; }
@keyframes bob { from { transform: translateY(-2px) rotate(-1deg); } to { transform: translateY(3px) rotate(1deg); } }
.ship .hullp { fill: rgba(var(--acc),.16); stroke: var(--teal-2); stroke-width: 1.5; stroke-linejoin: round; }
.ship .box { fill: rgba(200,212,255,.1); stroke: rgba(200,212,255,.55); stroke-width: 1; }
.ship .box.a { fill: rgba(var(--acc),.3); stroke: rgba(var(--acc2),.8); }
.ship .sea { fill: none; stroke: rgba(var(--acc2),.7); stroke-width: 1.6; stroke-linecap: round; animation: sea 4s linear infinite; }
.ship .sea.b { stroke: rgba(var(--acc),.5); animation-duration: 6.5s; animation-direction: reverse; }
@keyframes sea { to { transform: translateX(-80px); } }
.ship .chips { margin-top: 12px; }

/* Tile: a propeller (MarineGram) */
.prop { width: 100%; max-width: 230px; }
.prop .ring { fill: none; stroke: rgba(var(--acc),.4); stroke-dasharray: 3 7; }
.prop .ring.o { stroke: rgba(150,170,230,.25); }
.prop .blades { transform-box: view-box; transform-origin: 100px 100px; animation: turn 7s linear infinite; }
.prop .blades path { fill: rgba(var(--acc),.16); stroke: var(--teal-2); stroke-width: 1.5; stroke-linejoin: round; }
.prop .hub { fill: var(--bg-2); stroke: var(--teal); stroke-width: 2; }

/* Tile: a ship's frame, turning (MarineGram) */
.hull3 { width: 260px; height: 170px; perspective: 800px; }
.hull3 div { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; animation: yaw 16s linear infinite; }
@keyframes yaw { from { transform: rotateX(-16deg) rotateY(0); } to { transform: rotateX(-16deg) rotateY(360deg); } }
.hull3 i { position: absolute; left: 50%; top: 42%; width: var(--w); height: var(--h); margin-left: calc(var(--w) / -2); margin-top: -20px;
  border: 1.5px solid rgba(var(--acc2),.75); border-top-color: rgba(var(--acc),.45); border-radius: 0 0 50% 50% / 0 0 100% 100%; transform: translateZ(var(--z)); }
.hull3 b { position: absolute; left: 50%; width: 252px; margin-left: -126px; height: 0; border-top: 1.5px solid rgba(var(--acc),.7); transform: rotateY(90deg); }
.hull3 b.keel { top: calc(42% + 32px); } .hull3 b.deck { top: calc(42% - 20px); border-top-style: dashed; }
/* Drawn at four fifths in a narrow tile (two to a row from just over 640px,
   where the phone layout ends, to 720px; or a small phone); the margins make
   the room it takes as small as the drawing. A zoomed window can be 640.9px
   wide, hence 640.02px rather than 641px. */
@media (min-width: 640.02px) and (max-width: 720px), (max-width: 359px) { .hull3 { transform: scale(.8); margin: 0 -26px; } }

/* "Next app" panel */
.soon { border: 1px solid var(--line); border-radius: 26px; padding: 90px 30px; text-align: center;
  background: radial-gradient(60% 80% at 50% 0%, rgba(var(--acc),.12), transparent 70%), linear-gradient(180deg, rgba(20,28,54,.6), rgba(9,13,26,.7)); }
.orbit { width: 170px; height: 170px; margin: 0 auto 34px; position: relative; display: grid; place-items: center; }
.orbit svg { width: 84px; }
.orbit img { width: 96px; height: 96px; border-radius: 23px; position: relative; z-index: 1; box-shadow: 0 24px 70px -14px var(--glow, rgba(63,81,181,.95)); }
.orbit::before, .orbit::after { content: ""; position: absolute; border-radius: 50%; border: 1px dashed rgba(var(--acc2),.4); }
.orbit::before { inset: 0; animation: turn 22s linear infinite; }
.orbit::after { inset: 20px; border-color: rgba(150,170,230,.3); animation: turn 16s linear infinite reverse; }
@keyframes turn { to { transform: rotate(360deg); } }
.soon h3 { font-size: clamp(28px, 4vw, 46px); font-weight: 700; letter-spacing: -.035em; margin-top: 14px; }
.soon p { color: var(--muted); max-width: 520px; margin: 14px auto 0; }

/* Principles */
.grid4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.card { border: 1px solid var(--line); border-radius: var(--radius); padding: 30px 26px; background: linear-gradient(180deg, rgba(20,28,54,.55), rgba(9,13,26,.7)); }
.card .ico { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 26px; color: var(--teal-2);
  background: linear-gradient(140deg, rgba(var(--acc),.2), rgba(30,42,90,.35)); border: 1px solid rgba(var(--acc),.35); }
.card .ico svg { width: 24px; height: 24px; }
.card .label { margin-bottom: 16px; display: block; }
.card h3 { font-size: 21px; margin-bottom: 8px; letter-spacing: -.02em; }
.card p { color: var(--muted); margin: 0; font-size: 15px; }

/* Contact */
.contact-card { position: relative; border-radius: 34px; padding: clamp(50px, 8vw, 110px) 28px; text-align: center; overflow: hidden; border: 1px solid var(--line-2);
  background: radial-gradient(70% 120% at 50% 120%, rgba(var(--acc),.28), transparent 60%), radial-gradient(60% 90% at 10% 0%, rgba(46,64,150,.5), transparent 60%), #070b17; }
.contact-card h2 { font-size: clamp(36px, 6vw, 80px); font-weight: 700; letter-spacing: -.045em; line-height: 1; margin: 22px 0 18px; }
.contact-card p { color: var(--muted); margin: 0 auto 36px; max-width: 520px; font-size: 17px; }
.mail { display: inline-flex; align-items: center; gap: 14px; font-size: clamp(19px, 3vw, 30px); color: var(--text); letter-spacing: -.015em; padding-bottom: 6px; border-bottom: 1px solid var(--line-2); transition: border-color .25s, color .25s; }
.mail:hover { text-decoration: none; border-color: var(--teal); color: var(--teal-2); }

/* Small message at the bottom of the screen (e.g. "address copied") */
.toast { position: fixed; left: 50%; bottom: 28px; z-index: 80; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  max-width: calc(100vw - 32px); padding: 14px 20px; border-radius: 999px; font-size: 14.5px; color: #03131a; text-align: center;
  background: linear-gradient(120deg, var(--teal-2), var(--teal)); box-shadow: 0 16px 50px -10px rgba(var(--acc),.7);
  transition: opacity .3s, transform .3s; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* Footer */
.site-footer { margin-top: 40px; border-top: 1px solid var(--line); color: var(--dim); font-size: 14px; overflow: hidden; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 20px 40px; align-items: center; padding-top: 40px; padding-bottom: 30px; }
.site-footer nav { display: flex; gap: 22px; flex-wrap: wrap; margin-left: auto; }
.site-footer a { color: var(--muted); }
.site-footer .foot-langs { margin-left: 0; flex-basis: 100%; padding-top: 18px; border-top: 1px solid var(--line); }
.site-footer .foot-langs a[aria-current] { color: var(--text); }
.wordmark { font-size: clamp(70px, 17.5vw, 270px); font-weight: 700; letter-spacing: -.06em; line-height: .8; text-align: center; white-space: nowrap; user-select: none; margin-bottom: -.12em;
  background: linear-gradient(180deg, rgba(120,140,210,.3), rgba(120,140,210,0) 85%); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* App page */
.app-hero { position: relative; overflow: hidden; min-height: min(92svh, 860px); display: flex; align-items: center; }
.app-hero .wrap { position: relative; z-index: 2; width: 100%; padding-top: 40px; padding-bottom: 60px; }
.app-hero .top { display: flex; align-items: center; gap: 24px; margin: 26px 0 28px; }
.app-hero img.app-icon { width: 96px; height: 96px; border-radius: 23px; box-shadow: 0 24px 70px -14px var(--glow, rgba(63,81,181,.95)); }
/* An app's slogan under its name (Geo-Rulers) */
.app-hero .slogan { font-size: clamp(26px, 3.2vw, 40px); line-height: 1.1; color: var(--teal-2); margin: -10px 0 22px; }
.app-hero h1 { font-size: clamp(50px, 8vw, 112px); font-weight: 700; line-height: .95; letter-spacing: -.05em; }
.app-hero p.lead { color: var(--muted); font-size: 19px; max-width: 560px; margin: 0 0 34px; }
.store-note { color: var(--dim); font: 500 11.5px/1.5 var(--mono); letter-spacing: .1em; text-transform: uppercase; margin-top: 18px; }

/* The real screens, fanned out */
.fan { position: relative; height: 560px; perspective: 1600px; margin-top: 10px; }
.fan .phone { position: absolute; left: 50%; top: 20px; width: 236px; margin-left: -118px; transition: transform .7s cubic-bezier(.2,.7,.2,1);
  transform: translateX(calc(var(--i) * 150px)) translateZ(calc(var(--a) * -90px)) rotateY(calc(var(--i) * -9deg)) translateY(calc(var(--a) * 14px)); z-index: calc(10 - var(--a)); }
.fan:hover .phone { transform: translateX(calc(var(--i) * 205px)) translateZ(calc(var(--a) * -40px)) rotateY(calc(var(--i) * -4deg)); }
.phone { aspect-ratio: 1320 / 2868; border-radius: 34px; padding: 7px; background: linear-gradient(160deg, #2a3358, #10152a); border: 1px solid #38436e; box-shadow: 0 40px 90px -20px rgba(0,0,0,.8), 0 0 60px -20px rgba(var(--acc),.35); }
.phone img { width: 100%; height: 100%; object-fit: cover; border-radius: 27px; }

/* Long text pages (privacy, terms) */
.doc { max-width: 800px; margin: 0 auto; padding: 80px 28px 110px; }
.doc .langs { display: flex; flex-wrap: wrap; gap: 8px; margin: 26px 0 8px; }
.doc .langs a { font: 500 14px/1 var(--sans); color: var(--muted); border: 1px solid var(--line-2); border-radius: 999px; padding: 10px 14px; background: rgba(10,14,28,.5); transition: color .2s, border-color .2s; }
.doc .langs a:hover { color: var(--text); border-color: var(--teal); text-decoration: none; }
.doc .langs a[aria-current] { color: var(--teal); border-color: rgba(var(--acc),.5); }
.doc section { border-top: 1px solid var(--line); margin-top: 52px; padding-top: 36px; }
.doc h1 { font-size: clamp(32px, 4.8vw, 48px); line-height: 1.08; font-weight: 700; margin: 14px 0 10px; letter-spacing: -.035em; }
.doc section h1 { font-size: 32px; margin-top: 0; }
.doc h2 { font-size: 20px; margin: 36px 0 8px; letter-spacing: -.015em; }
.doc p, .doc li { color: #c9d0e3; }
.doc .meta { color: var(--dim); font-size: 14px; }
.doc ul { padding-inline-start: 22px; }
.doc strong { color: var(--text); }

/* Up to 1099px the list of apps is a grid above the panel: beside it, the
   panel would be too narrow for its tiles. (The apps' numbers show only in
   the column.) */
@media (max-width: 1099px) {
  .showcase { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .tabs, .tabs.stick { position: static; display: grid; grid-template-columns: repeat(auto-fill, minmax(176px, 1fr)); gap: 8px; border-left: 0; }
  .tab { margin-left: 0; border: 1px solid var(--line); border-radius: 14px; padding: 9px 12px; background-color: rgba(10,14,28,.5); }
  .tab .n { display: none; }
  .tab[aria-selected="true"] { border-color: rgba(var(--acc), .65); background-color: rgba(var(--acc), .14); }
}
/* Tablets and phones */
@media (max-width: 980px) {
  .block-head { grid-template-columns: 1fr; gap: 16px; }
  .tile, .tile.w5, .tile.w6, .tile.w7, .tile.w8 { grid-column: span 6; }
  .tile.w8, .tile.w7 { grid-column: span 12; }
  .grid4 { grid-template-columns: 1fr 1fr; }
  .stats .wrap { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: 0; padding-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .app-line .chips { margin-left: 0; width: 100%; }
}
@media (max-width: 860px) {
  .hero, .app-hero { align-items: flex-start; min-height: 0; }
  .sculpt { left: 0; right: 0; width: 100%; top: 0; bottom: auto; height: 46svh; min-height: 300px; }
  .hero .wrap { padding-top: calc(46svh + 22px); padding-bottom: 60px; }
  .app-hero .wrap { padding-top: calc(46svh - 10px); padding-bottom: 60px; }
  .sculpt-cap { bottom: 0; }
  .scroll-hint { display: none; }
  .fan { height: auto; perspective: none; display: flex; gap: 14px; overflow-x: auto; padding: 10px 4px 30px; scroll-snap-type: x mandatory; }
  .fan .phone, .fan:hover .phone { position: static; margin: 0; transform: none; flex: 0 0 200px; scroll-snap-align: center; }
}
@media (max-width: 640px) {
  .wrap { padding: 0 18px; }
  .nav a:not(.btn) { display: none; }
  /* Room for the logo, the Contact button and the language menu on a phone */
  .site-header .wrap { gap: 10px; }
  .site-header .brand { font-size: 17px; gap: 8px; }
  .site-header .brand svg { width: 29px; height: 24px; }
  .nav .btn { padding: 10px 13px; }
  .lang summary { padding: 9px 10px 9px 9px; gap: 6px; }
  section.block { padding: 84px 0; }
  .tile, .tile.w5, .tile.w6, .tile.w7, .tile.w8 { grid-column: span 12; min-height: 0; }
  .panels .tile, .panels .tile.w5, .panels .tile.w6 { grid-column: span 12; }
  .grid4, .grid3 { grid-template-columns: 1fr; }
  .site-footer nav { margin-left: 0; }
  .showcase-foot > span { display: none; }
  .showcase-foot { justify-content: flex-end; }
  /* Two apps to a row; a long name wraps in its own box (never wider). */
  .tabs, .tabs.stick { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tab { min-width: 0; gap: 9px; padding: 8px 10px; min-height: 54px; font-size: 12.5px; letter-spacing: .01em; }
  .tab .nm { overflow-wrap: anywhere; }
  .tab img { width: 30px; height: 30px; border-radius: 8px; }
  .stat { padding: 26px 16px; }
  .stat:nth-child(odd) { padding-left: 0; }
  .app-hero .top { gap: 16px; }
  .app-hero img.app-icon { width: 68px; height: 68px; border-radius: 17px; }
}
@media (max-width: 359px) {
  .site-header .brand span { display: none; }   /* very narrow phones: "Vatani" only */
  /* A smaller icon leaves room for the longest one-word name, "MarineGram". */
  .tab { gap: 8px; padding: 8px 9px; }
  .tab img { width: 26px; height: 26px; border-radius: 7px; }
  /* Two numbers to a row: a little less room beside them and between the
     letters under them, so that the longest word there ("TƏTBİQLƏRİMİZDƏ")
     still fits in one piece. A word that never could (with a larger text
     size, say) breaks rather than widening the page. */
  .stat { padding-left: 12px; padding-right: 12px; }
  .stat > span { letter-spacing: .06em; overflow-wrap: anywhere; }
}
/* Under 320px: one app and one number to a row (two would break names and
   labels inside a word), the scanner's picture above its results, a long
   word in a card's title (the Russian "конфиденциальность") broken rather
   than widening the page, and the header and the email address a little
   tighter, so that they fit. */
@media (max-width: 319px) {
  .tabs, .tabs.stick { grid-template-columns: minmax(0, 1fr); }
  .stats .wrap { grid-template-columns: minmax(0, 1fr); }
  .stat, .stat:nth-child(odd) { padding: 22px 0; border-left: 0; }
  .stat + .stat { border-top: 1px solid var(--line); }
  .stat > span { letter-spacing: .12em; }
  .scan { grid-template-columns: minmax(0, 1fr); }
  .scan .finder { width: 120px; justify-self: center; }
  .card h3 { overflow-wrap: anywhere; hyphens: auto; }
  .site-header .wrap { gap: 6px; }
  .mail { font-size: 16px; gap: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .chart .l1, .chart .l2 { stroke-dashoffset: 0; } .chart .area, .chart .end { opacity: 1; }
}

/* The domino games: a chain being laid piece by piece, and four players taking turns. */
.domino { width: 100%; max-width: 340px; }
.domino svg, .dtable svg { width: 100%; height: auto; display: block; overflow: visible; }
.domino .pc { animation: lay 9s cubic-bezier(.2,.7,.2,1) infinite backwards; animation-delay: var(--d, 0s); }
.domino rect { fill: color-mix(in srgb, rgb(var(--acc)) 10%, #0b1428); stroke: rgba(var(--acc),.75); stroke-width: 1.5; }
.domino line { stroke: rgba(var(--acc),.45); stroke-width: 1.4; stroke-linecap: round; }
.domino circle { fill: var(--teal-2); }
@keyframes lay { 0% { opacity: 0; transform: translateY(-26px) rotate(-8deg); } 7%, 78% { opacity: 1; transform: none; } 86%, 100% { opacity: 0; transform: translateY(14px); } }
.dtable { width: 100%; max-width: 300px; }
.dtable .top { fill: color-mix(in srgb, rgb(var(--acc)) 14%, #0b1428); stroke: rgba(var(--acc),.55); stroke-width: 1.5; }
.dtable .bone { fill: rgba(var(--acc2),.16); stroke: rgba(var(--acc2),.8); stroke-width: 1.2; }
.dtable .bg { fill: var(--bg-2); stroke: var(--line-2); stroke-width: 1.5; }
.dtable .me { fill: rgba(200,212,245,.55); }
.dtable .ring { fill: none; stroke: var(--teal); stroke-width: 2; opacity: 0; animation: myturn 6s ease-in-out infinite; animation-delay: var(--d, 0s); filter: drop-shadow(0 0 8px var(--teal)); }
@keyframes myturn { 0%, 2% { opacity: 0; } 6%, 22% { opacity: 1; } 27%, 100% { opacity: 0; } }

/* The certificate page (/certificate/). */
.cert [hidden] { display: none; }
.cert-wait { color: var(--muted); margin-top: 40px; }
.cert-valid { display: inline-flex; gap: 10px; align-items: center; font: 500 14px/1.4 var(--sans); color: var(--teal-2); border: 1px solid rgba(var(--acc),.45); border-radius: 999px; padding: 9px 16px; margin: 6px 0 0; }
.cert-card { margin: 30px 0 10px; padding: 8px 26px; border: 1px solid var(--line-2); border-radius: var(--radius); background: linear-gradient(160deg, rgba(var(--acc),.10), rgba(10,14,28,.6) 55%); }
.cert-row { display: grid; grid-template-columns: 190px 1fr; gap: 6px 20px; padding: 16px 0; border-top: 1px solid var(--line); }
.cert-row:first-child { border-top: 0; }
.cert-row dt { font: 500 12px/1.6 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.cert-row dd { margin: 0; color: var(--text); overflow-wrap: anywhere; }
.cert-who dd { font-size: clamp(24px, 4vw, 34px); font-weight: 700; letter-spacing: -.02em; line-height: 1.15; }
.cert-row .c-id { font: 500 14px/1.6 var(--mono); }
@media (max-width: 600px) { .cert-row { grid-template-columns: 1fr; } .cert-card { padding: 4px 18px; } }
