/* Сабиль: общие стили сайта. Шрифты лежат на самом сайте, сторонних запросов нет. */

@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url(/assets/fonts/manrope-latin-wght-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url(/assets/fonts/manrope-cyrillic-wght-normal.woff2) format('woff2');
  unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;
}
@font-face {
  font-family: 'Reem Kufi';
  font-style: normal;
  font-display: swap;
  font-weight: 400 700;
  src: url(/assets/fonts/reem-kufi-arabic-wght-normal.woff2) format('woff2');
  unicode-range: U+0600-06FF,U+0750-077F,U+0870-088E,U+0890-0891,U+0897-08E1,U+08E3-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FE74,U+FE76-FEFC;
}
@font-face {
  font-family: 'IBM Plex Sans Arabic';
  font-style: normal;
  font-display: swap;
  font-weight: 400;
  src: url(/assets/fonts/ibm-plex-sans-arabic-arabic-400-normal.woff2) format('woff2');
  unicode-range: U+0600-06FF,U+0750-077F,U+0870-088E,U+0890-0891,U+0897-08E1,U+08E3-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FE74,U+FE76-FEFC;
}
@font-face {
  font-family: 'IBM Plex Sans Arabic';
  font-style: normal;
  font-display: swap;
  font-weight: 500;
  src: url(/assets/fonts/ibm-plex-sans-arabic-arabic-500-normal.woff2) format('woff2');
  unicode-range: U+0600-06FF,U+0750-077F,U+0870-088E,U+0890-0891,U+0897-08E1,U+08E3-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FE74,U+FE76-FEFC;
}
@font-face {
  font-family: 'IBM Plex Sans Arabic';
  font-style: normal;
  font-display: swap;
  font-weight: 600;
  src: url(/assets/fonts/ibm-plex-sans-arabic-arabic-600-normal.woff2) format('woff2');
  unicode-range: U+0600-06FF,U+0750-077F,U+0870-088E,U+0890-0891,U+0897-08E1,U+08E3-08FF,U+200C-200E,U+2010-2011,U+204F,U+2E41,U+FB50-FDFF,U+FE70-FE74,U+FE76-FEFC;
}

:root {
  --ground: #F3F5F2;
  --ink: #12211D;
  --muted: #4C5B56;
  --accent: #0E5A4B;
  --accent-dark: #093E34;
  --line: #D5DCD7;
  --card: #FFFFFF;
  --tint: #E1EEE8;
  --dark: #0F2A24;
  --sand: #D9B978;
  --sand-line: #C9A45C;
  --on-dark: #EAF0EC;
  --on-dark-muted: #C5D3CC;
  --font-text: 'Manrope', 'IBM Plex Sans Arabic', 'Segoe UI', system-ui, -apple-system, Arial, sans-serif;
  --font-kufi: 'Reem Kufi', 'IBM Plex Sans Arabic', Tahoma, sans-serif;
  --font-ar: 'IBM Plex Sans Arabic', 'Manrope', 'Segoe UI', Tahoma, 'Geeza Pro', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: 17px;
  line-height: 1.55;
}
html[lang="ar"] body { font-family: var(--font-ar); font-size: 18px; line-height: 1.8; }

h1, h2, h3, p, figure, ol { margin: 0; }
a { color: inherit; }
svg { flex: none; }
:focus-visible { outline: 3px solid var(--sand-line); outline-offset: 3px; border-radius: 6px; }

.kufi { font-family: var(--font-kufi); }
[dir="rtl"] .arrow { transform: scaleX(-1); }

.skip {
  position: absolute; top: -80px; inset-inline-start: 16px; z-index: 10;
  padding: 10px 16px; border-radius: 10px;
  background: var(--dark); color: #FFFFFF; text-decoration: none;
}
.skip:focus { top: 12px; }

.container { max-width: 1120px; margin-inline: auto; padding-inline: 24px; }

/* Шапка */
.site-header {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 8px 32px; padding-block: 20px;
}
.brand { display: inline-flex; align-items: center; gap: 12px; min-height: 44px; text-decoration: none; color: var(--ink); }
.brand-ar { font-family: var(--font-kufi); font-size: 32px; font-weight: 600; line-height: 1; color: var(--accent); }
.brand-name { font-family: var(--font-text); font-size: 18px; font-weight: 700; letter-spacing: 0.01em; }
html[lang="ar"] .brand-name { font-size: 17px; font-weight: 600; letter-spacing: 0.02em; }

.nav { display: flex; flex-wrap: wrap; align-items: center; gap: 0 28px; }
.nav a {
  display: inline-flex; align-items: center; min-height: 44px;
  font-size: 16px; font-weight: 500; text-decoration: none; color: var(--ink);
}
html[lang="ar"] .nav a { font-size: 17px; }
.nav a:hover { color: var(--accent); }

/* Переключатель языков: одна рамка, внутри ссылки на остальные версии */
.langs {
  display: inline-flex; align-items: stretch;
  border: 1px solid #B4C1BA; border-radius: 999px; overflow: hidden;
}
.lang {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 42px; padding: 0 18px;
  text-decoration: none; color: var(--ink);
}
.lang + .lang { border-inline-start: 1px solid #B4C1BA; }
.lang:hover { background: var(--tint); color: var(--accent); }
.lang:focus-visible { outline-offset: -4px; border-radius: 999px; }
.lang[lang="ar"] { font-family: var(--font-kufi); font-size: 17px; font-weight: 500; }
.lang[lang="ru"], .lang[lang="en"] { font-family: var(--font-text); font-size: 15px; font-weight: 600; }

/* Кнопки и ссылки */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 28px; border-radius: 999px;
  font-size: 17px; font-weight: 600; text-decoration: none; text-align: center;
  transition: background-color 0.15s ease;
}
html[lang="ar"] .btn { font-size: 18px; }
.btn-primary { background: var(--accent); color: #FFFFFF; }
.btn-primary:hover { background: var(--accent-dark); }
.btn-sand { background: var(--sand); color: var(--ink); font-weight: 700; }
html[lang="ar"] .btn-sand { font-weight: 600; }
.btn-sand:hover { background: #E6CB93; }

.link-arrow {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px;
  font-weight: 600; color: var(--accent); text-decoration: none;
}
.link-arrow:hover { color: var(--accent-dark); }

/* Первый экран */
.hero {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr));
  gap: 48px 56px; align-items: center; padding-block: 48px 96px;
}
.hero-text { display: flex; flex-direction: column; align-items: flex-start; gap: 24px; }
.eyebrow { font-size: 14px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }
html[lang="ar"] .eyebrow { font-size: 16px; font-weight: 600; letter-spacing: 0; }

h1 {
  font-size: clamp(2.4rem, 4.8vw, 3.75rem); font-weight: 700;
  line-height: 1.08; letter-spacing: -0.02em; text-wrap: balance;
}
html[lang="ar"] h1 {
  font-family: var(--font-kufi); font-size: clamp(2.5rem, 5vw, 4rem);
  line-height: 1.35; letter-spacing: 0;
}
.lead { font-size: 19px; line-height: 1.6; color: var(--muted); max-width: 520px; text-wrap: pretty; }
html[lang="ar"] .lead { font-size: 20px; line-height: 1.85; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; }

.hero-art svg { display: block; width: 100%; height: auto; border-radius: 28px; }
.hero-art figcaption { margin-top: 14px; font-size: 15px; color: var(--muted); }
.hero-art figcaption .kufi { font-size: 17px; color: var(--ink); }

/* Разделы */
.section { padding-bottom: 96px; }
.section-head { display: flex; flex-direction: column; gap: 10px; margin-bottom: 32px; }
html[lang="ar"] .section-head { gap: 6px; }

h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); font-weight: 700; line-height: 1.15; letter-spacing: -0.01em; }
html[lang="ar"] h2 {
  font-family: var(--font-kufi); font-size: clamp(1.9rem, 3.2vw, 2.6rem);
  font-weight: 600; line-height: 1.4; letter-spacing: 0;
}
h2.small { font-size: clamp(1.6rem, 2.6vw, 2.1rem); }
html[lang="ar"] h2.small { font-size: clamp(1.7rem, 2.8vw, 2.2rem); }

h3 { font-size: 19px; font-weight: 700; line-height: 1.3; }
html[lang="ar"] h3 { font-size: 20px; font-weight: 600; line-height: 1.5; }

.sub { font-size: 18px; color: var(--muted); }
html[lang="ar"] .sub { font-size: 19px; }

.grid-4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); gap: 20px; }

.card {
  display: flex; flex-direction: column; gap: 14px;
  padding: 24px; border: 1px solid var(--line); border-radius: 20px; background: var(--card);
}
html[lang="ar"] .card { gap: 12px; }
.card p { font-size: 16px; color: var(--muted); }
html[lang="ar"] .card p { font-size: 17px; }

.icon {
  display: flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--tint); color: var(--accent);
}

/* Карточки проектов */
.project { padding: 28px; text-decoration: none; color: var(--ink); transition: border-color 0.15s ease; }
.project:hover { border-color: var(--accent); }
.project h3 { font-size: 22px; line-height: 1.25; }
html[lang="ar"] .project h3 { font-size: 23px; line-height: 1.5; }
.project p { font-size: 17px; text-wrap: pretty; }
html[lang="ar"] .project p { font-size: 18px; }

.meta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; }
.tags { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.kind { font-size: 13px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
html[lang="ar"] .kind { font-size: 15px; font-weight: 600; letter-spacing: 0; }

.chip { padding: 4px 12px; border-radius: 999px; font-size: 14px; font-weight: 600; }
html[lang="ar"] .chip { padding: 2px 14px; font-size: 15px; }
.chip-live { background: var(--tint); color: var(--accent); }
.chip-dev { background: #F1ECDD; color: #5A4A1E; }
.chip-team { background: #E6E9E7; color: #3A4743; }
.chip-soon { background: #F1ECDD; color: #5A4A1E; }
.chip-store { background: var(--tint); color: var(--accent); }

.more {
  display: inline-flex; align-items: center; gap: 8px;
  margin-top: auto; padding-top: 6px;
  font-size: 16px; font-weight: 600; color: var(--accent);
}
html[lang="ar"] .more { font-size: 17px; }

/* Светлая полоса: принципы и подробности */
.band { background: #FFFFFF; border-block: 1px solid var(--line); }
.band-inner { padding-block: 80px; }
.band-inner.tight { padding-block: 72px; }
.split { display: flex; flex-wrap: wrap; gap: 40px 56px; }
.split-head { flex: 1 1 260px; display: flex; flex-direction: column; gap: 10px; }
html[lang="ar"] .split-head { gap: 6px; }
.split-body { flex: 2 1 520px; min-width: 0; }

.points { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 36px 40px; }
.point { display: flex; flex-direction: column; gap: 8px; padding-top: 18px; border-top: 2px solid var(--sand-line); }
html[lang="ar"] .point { gap: 6px; padding-top: 16px; }
.point p { font-size: 16px; color: var(--muted); }
html[lang="ar"] .point p { font-size: 17px; }

/* Шаги */
.steps {
  list-style: none; padding: 0;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 32px 0;
}
.step { display: flex; flex-direction: column; gap: 16px; }
html[lang="ar"] .step { gap: 14px; }
.step-top { display: flex; align-items: center; }
.step-num {
  flex: none; display: flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--accent); color: #FFFFFF; font-size: 17px; font-weight: 700; line-height: 1;
}
html[lang="ar"] .step-num { font-size: 19px; font-weight: 600; }
.step-line { flex: 1; height: 2px; background: var(--sand-line); }
.step:last-child .step-line { display: none; }
.step-body { display: flex; flex-direction: column; gap: 6px; padding-inline-end: 28px; }
html[lang="ar"] .step-body { gap: 4px; }
.step-body p { font-size: 16px; color: var(--muted); }
html[lang="ar"] .step-body p { font-size: 17px; }

.section-process { padding-top: 80px; }

/* Тёмный блок связи */
.section-cta { padding-bottom: 56px; }
.section-cta.spaced { padding-top: 72px; }
.cta {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 32px 48px;
  padding: clamp(32px, 6vw, 64px); border-radius: 28px;
  background: var(--dark); color: var(--on-dark);
}
.cta-text { flex: 1 1 380px; display: flex; flex-direction: column; gap: 12px; }
html[lang="ar"] .cta-text { gap: 8px; }
.cta h2 { color: #FFFFFF; }
.cta p { font-size: 18px; color: var(--on-dark-muted); }
html[lang="ar"] .cta p { font-size: 19px; }
.cta-side { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.cta-side p { font-size: 15px; }
html[lang="ar"] .cta-side p { font-size: 16px; }
.cta-side p a { color: var(--on-dark); }

/* Подвал */
.site-footer {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px;
  padding-bottom: 40px; font-size: 15px; color: var(--muted);
}
html[lang="ar"] .site-footer { font-size: 16px; }
.site-footer .domain { font-family: var(--font-text); font-size: 15px; font-weight: 500; }

/* Страница проекта */
.project-hero { display: flex; flex-direction: column; align-items: flex-start; gap: 20px; padding-block: 16px 72px; }
html[lang="ar"] .project-hero { gap: 18px; }
.project-hero h1 { font-size: clamp(2.2rem, 4.2vw, 3.25rem); line-height: 1.1; }
html[lang="ar"] .project-hero h1 { font-size: clamp(2.3rem, 4.4vw, 3.4rem); line-height: 1.4; }
.project-hero .lead { max-width: 720px; }
.back { font-size: 16px; }
html[lang="ar"] .back { font-size: 17px; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px 16px; }
.note {
  max-width: 720px; padding: 16px 20px;
  border: 1px solid var(--line); border-radius: 16px; background: #FFFFFF; font-size: 16px;
}
html[lang="ar"] .note { padding: 14px 20px; font-size: 17px; }
.section-how { padding-bottom: 80px; }
.section-how h2 { margin-bottom: 36px; }
.band h2.small { margin-bottom: 32px; }

/* Страница «не найдено» */
.notfound { display: flex; flex-direction: column; align-items: flex-start; gap: 20px; padding-block: 72px 120px; }

/* Узкие экраны */
@media (max-width: 860px) {
  .nav { order: 3; flex-basis: 100%; gap: 0 22px; }
}
@media (max-width: 640px) {
  .container { padding-inline: 20px; }
  .hero { gap: 32px; padding-block: 24px 64px; }
  .section { padding-bottom: 64px; }
  .section-process { padding-top: 56px; }
  .band-inner, .band-inner.tight { padding-block: 56px; }
  .project { padding: 22px; }
  .project-hero { padding-bottom: 56px; }
  .section-how { padding-bottom: 56px; }
  .section-cta.spaced { padding-top: 56px; }
  .cta { border-radius: 22px; }
  .hero-art svg { border-radius: 22px; }
  .btn-row .btn { flex: 1 1 100%; }
}
@media (max-width: 340px) {
  .brand { gap: 8px; }
  .langs .lang { padding: 0 10px; }
}
@media (max-width: 520px) {
  .site-header { column-gap: 12px; }
  .lang { padding: 0 13px; }
  .step-line { display: none; }
  .steps { gap: 24px 0; }
}

/* Скриншоты на странице проекта */
.section-shots { padding-bottom: 80px; }
.section-shots .section-head { margin-bottom: 28px; }
.shots {
  display: flex; gap: 20px; overflow-x: auto; padding-bottom: 14px;
  scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch;
}
.shot { flex: none; width: min(300px, 72vw); margin: 0; scroll-snap-align: start; }
.shot img {
  display: block; width: 100%; height: auto;
  border: 1px solid var(--line); border-radius: 22px; background: #FFFFFF;
}
/* Широкие снимки: сцены трансляции, а не экран телефона */
.shot.wide { width: min(620px, 86vw); }
.shot.wide img { border-radius: 14px; }

/* Страницы с текстом: конфиденциальность, поддержка */
.doc-hero { padding-bottom: 48px; }
.updated { font-size: 15px; color: var(--muted); }
html[lang="ar"] .updated { font-size: 16px; }
.doc { padding-bottom: 88px; }
.doc-body { display: flex; flex-direction: column; gap: 40px; max-width: 760px; }
.doc-block { display: flex; flex-direction: column; gap: 14px; scroll-margin-top: 24px; }
html[lang="ar"] .doc-block { gap: 10px; }
.doc-block h2 { font-size: clamp(1.35rem, 2.2vw, 1.6rem); line-height: 1.25; letter-spacing: 0; }
html[lang="ar"] .doc-block h2 { font-size: clamp(1.45rem, 2.4vw, 1.7rem); line-height: 1.5; }
.doc-block p, .doc-block li { color: var(--muted); text-wrap: pretty; }
.doc-block ul { margin: 0; padding-inline-start: 22px; display: flex; flex-direction: column; gap: 10px; }
html[lang="ar"] .doc-block ul { gap: 6px; }
.doc-block li::marker { color: var(--sand-line); }
.doc-block a:not(.btn) { color: var(--accent); font-weight: 600; }
.doc-block a:not(.btn):hover { color: var(--accent-dark); }
.doc-contact { color: var(--ink); }

/* Ссылки в подвале */
.footer-links { display: flex; flex-wrap: wrap; gap: 4px 24px; }
.footer-links a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.footer-links a:hover { color: var(--accent); text-decoration: underline; }

/* Цифры по проектам: блок на главной и на странице проекта */
.stats-panel {
  align-self: stretch; display: flex; flex-direction: column; gap: 20px;
  padding: 28px; border: 1px solid var(--line); border-radius: 20px; background: var(--card);
}
.project-hero .stats-panel { margin-top: 12px; }
.stats-title {
  font-size: 14px; font-weight: 700; line-height: 1.4; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--accent);
}
html[lang="ar"] .stats-title {
  font-family: var(--font-ar); font-size: 16px; font-weight: 600; line-height: 1.6; letter-spacing: 0;
}
.stats {
  margin: 0; display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(170px, 100%), 1fr)); gap: 24px 32px;
}
/* В разметке подпись стоит перед числом, на экране число сверху */
.stat { display: flex; flex-direction: column-reverse; justify-content: flex-end; gap: 6px; }
.stat dd {
  margin: 0; font-size: clamp(2.1rem, 3.6vw, 2.75rem); font-weight: 700; line-height: 1.05;
  letter-spacing: -0.02em; font-variant-numeric: tabular-nums;
}
html[lang="ar"] .stat dd { font-weight: 600; line-height: 1.3; letter-spacing: 0; }
/* Когда чисел одно или два, на широком экране блок не растягивается на всю ширину */
@media (min-width: 641px) {
  .stats-panel.few { align-self: flex-start; min-width: 440px; }
  .stats-panel.few .stats { grid-template-columns: repeat(2, minmax(150px, max-content)); gap: 24px 64px; }
}
.stat dt { font-size: 16px; line-height: 1.4; color: var(--muted); }
html[lang="ar"] .stat dt { font-size: 17px; line-height: 1.6; }
.stats-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0 24px; }
.stats-note { font-size: 15px; color: var(--muted); }
html[lang="ar"] .stats-note { font-size: 16px; }

/* Страница «Сотрудничество» и ссылка на неё с главной */
.section-more { margin-top: 20px; }
a.more { min-height: 44px; text-decoration: none; }
a.more:hover { color: var(--accent-dark); }
.hero-contact { font-size: 16px; color: var(--muted); }
html[lang="ar"] .hero-contact { font-size: 17px; }
.hero-contact a { color: var(--accent); font-weight: 600; }
.band .split-head h2.small { margin-bottom: 0; }

@media (max-width: 640px) {
  .section-shots { padding-bottom: 56px; }
  .doc-hero { padding-bottom: 36px; }
  .doc-hero h1 { font-size: min(2.2rem, 8.4vw); overflow-wrap: anywhere; }
  .doc { padding-bottom: 64px; }
  .doc-body { gap: 32px; }
  .stats-panel { padding: 22px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 16px; }
}
