/* site-kit — обвязка публичных страниц RobX (шапка, футер, карточки,
 * кнопки) в дизайне главной robx.online.
 *
 * Нужен, чтобы IoT-портал (`iot/`, отдельный хост) не расходился с
 * главной: раньше у него была своя бирюзовая шапка на W3.CSS и свой
 * футер, и любая правка дизайна главной обходила его стороной.
 *
 * Значения скопированы 1:1 из `main/index.php` — это одна и та же
 * система, а не «похожая». Правим здесь и там одновременно.
 *
 * Подключение с чужого хоста:
 *   <link rel="stylesheet" href="https://robx.online/shared/site-kit/site-kit.css?v=ГГГГММДД">
 *   <link rel="stylesheet" href="https://robx.online/static/fonts/logo-font.css">
 */

:root {
  --bg: #f5f9ff;
  --bg-2: #eef4fd;
  --ink: oklch(0.18 0.02 250);
  --ink-2: oklch(0.42 0.02 250);
  --ink-3: oklch(0.58 0.015 250);
  --line: oklch(0.92 0.012 250);
  --brand: #2563eb;
  --brand-2: #3b82f6;
  --warm: #f97316;
  --violet: #7c3aed;
  --mint: #10b981;
  --danger: #e0294a;
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --maxw: 1180px;
  /* Шапка тянется во всю страницу с отступом 8px от краёв; полотно
     страницы живёт по той же ширине, иначе футер уже меню. */
  --rx-edge: 8px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  font-family: "Montserrat", Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  overflow-x: hidden;
}
button { font-family: inherit; cursor: pointer; border: 0; background: transparent; color: inherit; }
a { color: inherit; text-decoration: none; }

.rx-page { position: relative; min-height: 100vh; isolation: isolate; }

/* ── Шапка ─────────────────────────────────────────────────── */
.rx-nav {
  position: sticky;
  top: 8px;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 8px auto 0;
  padding: 8px 24px;
  max-width: none;
  width: calc(100% - 16px);
  background: #fff;
  border: 1px solid rgba(15,23,42,0.08);
  border-radius: 999px;
  box-shadow: 0 4px 14px -6px rgba(30,60,130,0.12);
}
.rx-logo { padding: 0 4px; }
.rx-logo-mark {
  font-family: 'Montserrat Logo', 'Montserrat', Arial, sans-serif;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.rx-nav-pill { display: flex; align-items: center; gap: 2px; }
.rx-nav-link {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 0 14px; height: 38px; border-radius: 999px;
  font-size: 14px; font-weight: 500; color: var(--ink-2);
  transition: background 0.16s, color 0.16s;
}
.rx-nav-link:hover { background: rgba(15,23,42,0.05); color: var(--ink); }
.rx-nav-link-active { background: rgba(37,99,235,0.1); color: var(--brand); font-weight: 600; }
.rx-nav-right { display: flex; align-items: center; gap: 10px; }
.rx-spacer { flex: 1 1 auto; }

/* ── Кнопки ────────────────────────────────────────────────── */
.rx-cta-primary {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 22px; border-radius: 999px;
  font-size: 14px; font-weight: 600; color: #fff;
  background: #2563eb;
  box-shadow: 0 8px 20px -8px rgba(37, 99, 235, 0.5);
  transition: transform 0.15s, background 0.15s, box-shadow 0.15s;
}
.rx-cta-primary:hover { background: #1d4ed8; transform: translateY(-1px); }
.rx-cta-glass {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 22px; border-radius: 999px;
  font-size: 14px; font-weight: 600; color: var(--ink);
  background: #fff; border: 1px solid rgba(15,23,42,0.1);
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
}
.rx-cta-glass:hover { background: #f5f9ff; border-color: rgba(37,99,235,0.4); transform: translateY(-1px); }

/* ── Полотно и карточки ────────────────────────────────────── */
/* Полотно чуть уже шапки — как в кабинете (lk/panel.php). Отступ ровно в
   радиус «пилюли» (высота шапки 64px → радиус 32px), поэтому карточки
   начинаются там, где у шапки заканчивается скругление. */
.rx-section {
  width: calc(100% - var(--rx-edge) * 2);
  margin: 0 auto;
  padding: 60px 32px;
}
.rx-section-head { text-align: center; margin-bottom: 36px; }
.rx-h1 {
  font-size: clamp(34px, 5vw, 56px); line-height: 1.05;
  letter-spacing: -0.03em; font-weight: 700; margin: 0 0 18px;
}
.rx-h2 {
  font-size: clamp(30px, 3.6vw, 44px); line-height: 1.1;
  letter-spacing: -0.025em; font-weight: 700; margin: 0 0 8px;
}
.rx-eyebrow { color: var(--ink-3); font-size: 16px; margin: 0; }
.rx-glass-card {
  position: relative;
  background: #fff;
  border: 1px solid rgba(15,23,42,0.08);
  border-radius: var(--radius-lg);
  box-shadow: 0 14px 30px -14px rgba(20,30,60,0.18);
}

/* ── Футер ─────────────────────────────────────────────────── */
.rx-footer {
  margin-top: 60px;
  padding: 50px 32px 30px;
  width: calc(100% - var(--rx-edge) * 2);
  margin-left: auto;
  margin-right: auto;
}
.rx-footer-inner {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 40px;
  padding: 32px 36px;
  background: #fff;
  border: 1px solid rgba(15,23,42,0.08);
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 22px -14px rgba(30,60,130,0.12);
}
.rx-footer-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.rx-footer-text { color: var(--ink-3); font-size: 14px; max-width: 280px; }
.rx-footer-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; min-width: 0; }
.rx-footer-h { font-size: 13px; font-weight: 600; color: var(--ink); margin-bottom: 12px; }
.rx-footer-cols a { display: block; font-size: 13.5px; color: var(--ink-3); padding: 4px 0; overflow-wrap: anywhere; }
.rx-footer-cols a:hover { color: var(--ink); }
/* Копирайт — внутри карточки, под левым (брендовым) блоком. */
.rx-footer-bottom {
  color: var(--ink-3); font-size: 13px; margin-top: 18px;
  padding-top: 16px; border-top: 1px solid rgba(0, 0, 0, 0.06);
}

/* ── Адаптив ───────────────────────────────────────────────── */
@media (max-width: 1000px) {
  .rx-footer-inner { grid-template-columns: 1fr; }
  .rx-nav-pill { display: none; }
}
@media (max-width: 600px) {
  .rx-section { padding: 36px 16px; }
  .rx-footer { padding: 34px 16px 20px; }
  .rx-footer-inner { padding: 22px 18px; gap: 24px; }
  .rx-footer-cols { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .rx-footer-text { font-size: 13.5px; }
  .rx-nav { padding: 8px 14px; }
}
@media (max-width: 400px) {
  .rx-footer-cols { grid-template-columns: 1fr; }
}
