/* Светлая тема брендбука evristy.ru: кремовый фон в клетку 24px, тёмно-синий текст, синий / жёлтый / красный акценты. */
@font-face { font-family: "Severina"; src: url(../fonts/Severina.woff2) format("woff2"); font-display: block; }
:root {
  --bg: #fffdf4; --navy: #042D50; --blue: #3963A8; --yellow: #EDB20E; --red: #AC1414; --green: #2E8B57;
  --muted: #4a6580; --line: #d6deea; --card: #f4f7fb;
  --sans: "Sofia Sans Semi Condensed", "Arial Narrow", sans-serif;
  --head: "Severina", Impact, "Arial Narrow", sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--navy); font-family: var(--sans); color-scheme: light; }
body { overflow: hidden; }
.grid {
  background-color: var(--bg);
  background-image: linear-gradient(rgba(57, 99, 168, .09) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(57, 99, 168, .09) 1px, transparent 1px);
  background-size: 24px 24px;
}

#wrap { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
#stage { position: relative; width: 1920px; height: 1080px; flex: none; overflow: hidden; transform-origin: 50% 50%; }
#stage::before { content: ""; position: absolute; left: 88px; top: 0; bottom: 0; width: 2px; background: var(--red); opacity: .55; z-index: 5; }
body.film #wrap { display: block; }
body.film #stage { transform: none; }
body.film #nav { display: none; }

#nav { position: fixed; left: 50%; bottom: 14px; transform: translateX(-50%); display: flex; gap: 8px; z-index: 10; }
#nav button { font: 700 15px/1 var(--sans); text-transform: uppercase; letter-spacing: .04em; color: var(--navy); background: #fff;
  border: 2px solid var(--blue); border-radius: 8px; padding: 9px 14px; cursor: pointer; }
#nav button[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }

.scene { position: absolute; inset: 0; visibility: hidden; }
.cv { position: absolute; left: 0; top: 0; width: 1920px; height: 1080px; }

/* Левая колонка: заголовок, мысль, счётчик */
.txt { position: absolute; left: 140px; top: 140px; width: 560px; z-index: 3; }
.txt h1 { font: 400 76px/1.02 var(--head); text-transform: uppercase; letter-spacing: .01em; margin: 0; color: var(--navy); }
.txt h1::after { content: ""; display: block; width: 76px; height: 6px; background: var(--red); margin-top: 26px; }
.txt .lead { font: 600 34px/1.22 var(--sans); margin: 30px 0 0; }
.count { margin-top: 50px; }
.count b { display: block; font: 400 124px/1 var(--head); color: var(--blue); letter-spacing: .01em; white-space: nowrap; }
.count b i { font: 800 118px/1 var(--sans); font-style: normal; }
.count span { display: block; font: 600 32px/1.2 var(--sans); margin-top: 10px; }
.txt .note { font: 500 27px/1.32 var(--sans); color: var(--muted); margin: 44px 0 0; padding-left: 20px; border-left: 5px solid var(--yellow); }
.txt .list { list-style: none; margin: 40px 0 0; padding: 0; }
.txt .list li { position: relative; font: 600 29px/1.25 var(--sans); padding-left: 40px; margin-bottom: 20px; }
.txt .list li::before { content: ""; position: absolute; left: 0; top: 9px; width: 18px; height: 18px; border-radius: 50%; border: 4px solid var(--blue); background: #fff; }

/* Сервисы сверху */
.svc { position: absolute; width: 180px; transform: translate(-50%, -50%); text-align: center; z-index: 3; }
.svc-c { position: relative; width: 100px; height: 100px; margin: 0 auto; border-radius: 50%; background: #fff; border: 4px solid var(--blue);
  color: var(--blue); display: flex; align-items: center; justify-content: center; }
.svc-c svg { width: 54px; height: 54px; }
.svc-n { display: block; font: 700 27px/1 var(--sans); margin-top: 12px; }
.badge { position: absolute; right: -10px; top: -10px; width: 44px; height: 44px; border-radius: 50%; color: #fff; display: flex;
  align-items: center; justify-content: center; transform: scale(0); border: 3px solid #fff; }
.badge svg { width: 26px; height: 26px; }
.badge.red { background: var(--red); }
.badge.green { background: var(--green); }

/* Сервер */
.server { position: absolute; transform: translate(-50%, -50%); width: 260px; text-align: center; color: var(--blue); z-index: 3; }
.server svg { width: 132px; height: 165px; display: block; margin: 0 auto; filter: drop-shadow(0 10px 18px rgba(4, 45, 80, .14)); }
.server .addr { display: inline-block; margin-top: 12px; font: 700 26px/1 var(--sans); padding: 10px 18px; border-radius: 999px;
  background: #fff; border: 3px solid currentColor; white-space: nowrap; }
.server.sm svg { width: 100px; height: 125px; }
.server.sm .addr { font-size: 22px; padding: 8px 14px; margin-top: 10px; }

/* Плашки */
.plate { position: absolute; transform: translate(-50%, -50%); display: flex; align-items: center; gap: 18px; padding: 16px 32px 16px 16px;
  border-radius: 18px; color: #fff; font: 800 34px/1.1 var(--sans); white-space: nowrap; z-index: 4; box-shadow: 0 16px 34px rgba(4, 45, 80, .22); opacity: 0; }
.plate .pi { width: 58px; height: 58px; border-radius: 50%; background: #fff; display: flex; align-items: center; justify-content: center; flex: none; }
.plate .pi svg { width: 34px; height: 34px; }
.plate.red { background: var(--red); }
.plate.red .pi { color: var(--red); }
.plate.green { background: var(--green); }
.plate.green .pi { color: var(--green); }

/* Свои: аватары тройки */
.mate { position: absolute; width: 84px; height: 84px; transform: translate(-50%, -50%); border-radius: 50%; background: #fff;
  border: 4px solid var(--blue); color: var(--blue); display: flex; align-items: center; justify-content: center; z-index: 3;
  box-shadow: 0 8px 16px rgba(4, 45, 80, .12); }
.mate svg { width: 52px; height: 52px; }
.mate.y { border-color: var(--yellow); color: #b98a06; }
.mate.n { border-color: var(--navy); color: var(--navy); }
.mate.sm { width: 64px; height: 64px; border-width: 3px; }
.mate.sm svg { width: 40px; height: 40px; }
.cap4 { position: absolute; transform: translateX(-50%); font: 700 27px/1 var(--sans); white-space: nowrap; z-index: 3; }
.tag4 { position: absolute; transform: translate(-50%, -50%); display: flex; align-items: center; gap: 8px; font: 700 24px/1 var(--sans);
  color: var(--navy); background: #fff; border: 2px solid var(--yellow); border-radius: 999px; padding: 8px 16px 8px 10px; white-space: nowrap; z-index: 3; }
.tag4 svg { width: 26px; height: 26px; color: var(--blue); }

/* Окно приложения и телефон */
.win { position: absolute; left: 700px; top: 280px; width: 820px; height: 520px; background: #fff; border: 2px solid var(--line);
  border-radius: 20px; box-shadow: 0 30px 70px rgba(4, 45, 80, .16); overflow: hidden; z-index: 3; }
.win-bar { height: 50px; display: flex; align-items: center; gap: 9px; padding: 0 20px; border-bottom: 1px solid var(--line); background: #fbfcfe; position: relative; }
.win-bar i { width: 14px; height: 14px; border-radius: 50%; background: #d3dbe6; }
.win-bar span { position: absolute; left: 0; right: 0; text-align: center; font: 700 20px/1 var(--sans); color: var(--muted); }
.phone { position: absolute; left: 1572px; top: 212px; width: 316px; height: 656px; border-radius: 54px; background: var(--navy); padding: 12px;
  box-shadow: 0 30px 60px rgba(4, 45, 80, .22); z-index: 3; }
.phone .scr { position: relative; width: 292px; height: 632px; border-radius: 43px; overflow: hidden; background: var(--bg); }
.phone .scr .app { transform: scale(.7487); transform-origin: 0 0; }
.isl { position: absolute; left: 50%; top: 9px; width: 86px; height: 25px; margin-left: -43px; border-radius: 20px; background: #0a1520; z-index: 2; }

.app { font-family: var(--sans); color: var(--navy); }
.app .sb { display: flex; align-items: center; justify-content: space-between; padding: 0 30px 0 34px; height: 54px; font: 700 18px/1 var(--sans); }
.app .sb svg { width: 70px; height: 13px; }
.app-top { display: flex; align-items: center; justify-content: space-between; padding: 6px 22px 0; }
.app-top b { font: 800 26px/1 var(--sans); }
.app-top svg { width: 28px; height: 28px; color: var(--muted); }
.ring-wrap { text-align: center; }
.ring { display: block; margin: 0 auto; }
.ring .bg { fill: none; stroke: #e4eaf3; stroke-width: 12; }
.ring .fg { fill: none; stroke: var(--blue); stroke-width: 12; stroke-linecap: round; transform: rotate(-90deg); transform-origin: 100px 100px; }
.ring .core { fill: #fff; stroke: none; }
.ring .pw { fill: none; stroke: var(--blue); stroke-width: 9; stroke-linecap: round; }
.app.on .ring .fg, .app.on .ring .pw { stroke: var(--green); }
.app.on .ring .core { fill: #eef7f1; }
.st-t { display: block; font: 800 34px/1 var(--sans); color: var(--muted); margin-top: 18px; }
.app.on .st-t { color: var(--green); }
.st-s { display: block; font: 500 21px/1.2 var(--sans); color: var(--muted); margin-top: 8px; }
.rows { display: flex; flex-direction: column; gap: 12px; }
.row { display: flex; align-items: center; gap: 14px; background: var(--card); border-radius: 14px; padding: 13px 16px; min-height: 76px; }
.row > i { width: 44px; height: 44px; border-radius: 12px; background: #fff; color: var(--blue); display: flex; align-items: center; justify-content: center; flex: none; }
.row > i svg { width: 26px; height: 26px; }
.row > div { flex: 1; min-width: 0; }
.row small { display: block; font: 500 18px/1.15 var(--sans); color: var(--muted); }
.row b { display: block; font: 700 23px/1.2 var(--sans); margin-top: 3px; }
.row .hid { display: inline-flex; align-items: center; gap: 6px; background: var(--navy); color: #fff; border-radius: 8px; padding: 3px 12px 3px 9px; font-size: 20px; }
.row .hid svg { width: 16px; height: 16px; }
.chev { font: 700 30px/1 var(--sans); color: var(--muted); }
.tgl { width: 52px; height: 30px; border-radius: 15px; background: var(--green); position: relative; flex: none; }
.tgl::after { content: ""; position: absolute; right: 3px; top: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; }

.app.desk { display: grid; grid-template-columns: 300px 1fr; gap: 34px; padding: 40px 40px 0; align-items: start; }
.app.desk .sb, .app.desk .app-top { display: none; }
.app.desk .ring { width: 270px; height: 270px; margin-top: 18px; }
.app.mob { width: 390px; height: 844px; position: relative; background: var(--bg); }
.app.mob .app-top { padding-top: 4px; }
.app.mob .ring-wrap { padding-top: 26px; }
.app.mob .ring { width: 204px; height: 204px; }
.app.mob .st-t { margin-top: 14px; }
.app.mob .rows { padding: 28px 18px 0; gap: 10px; }
.app.mob .row { min-height: 74px; padding: 12px 14px; }
.app.mob .row small { font-size: 17px; }
.app.mob .home { position: absolute; left: 50%; bottom: 9px; width: 134px; height: 5px; margin-left: -67px; border-radius: 3px; background: var(--navy); }
.app.desk .home { display: none; }

/* Режим «только телефон» для кадра 780×1688 */
body.phonemode #wrap, body.phonemode #nav { display: none; }
#phoneonly { position: absolute; left: 0; top: 0; width: 390px; height: 844px; overflow: hidden; }

/* 27.10 (Шор): на странице кейса схема — часть страницы, а не видео в рамке: прозрачный фон (просвечивает клетка самой страницы),
   без своей красной линии полей; на узком экране кнопки сцен прячутся, схема занимает всю высоту. */
body.embed, html:has(body.embed) { background: transparent; }
body.embed .grid { background: transparent; }
body.embed #stage::before { display: none; }
body.embed #nav { bottom: 4px; gap: 6px; }
body.embed #nav button { font-size: clamp(10px, 1.45vw, 13px); padding: .5em .8em; white-space: nowrap; background: rgba(255,253,244,.92); border-width: 1.5px; }
body.embed #nav button[aria-pressed="true"] { background: var(--navy); color: #fff; }
@media (max-width: 640px) { body.embed #nav { display: none; } }
