/*
 * jyotisoft.com — one stylesheet, no build step, no dependencies.
 *
 * The palette is the SAME brand palette as the web app
 * (app/packages/ui/src/tokens/brand-jyotisoft.css): a cool sheet, deep slate
 * and a teal accent, so the site and the app read as one product. The values
 * are duplicated here rather than imported because this is plain static HTML
 * served by Caddy, with no bundler to resolve a package — the app's palette is
 * the source of truth, and the copy is these ten lines.
 */
:root {
  --paper: #eaf0f6;
  --paper-bright: #ffffff;
  --card: #d9e4ee;
  --slate: #0e1c30;
  --slate-deep: #0a1524;
  --ink: #10203a;
  --ink-muted: #4b5d70;
  --accent: #10574e;
  --accent-bright: #3fb3a0;
  --line: rgba(16, 32, 58, .14);
  --radius: 16px;
  color-scheme: light;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.65 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.wrap { width: min(1080px, 100% - 2.5rem); margin-inline: auto; }

a { color: var(--accent); }

/* ── header ─────────────────────────────────────────────────────── */
.site-head {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(234, 240, 246, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-head .wrap {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  padding: .75rem 0;
}
.brand {
  display: inline-flex;
  align-items: center;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -.01em;
  text-decoration: none;
  color: var(--ink);
  margin-right: auto;
}
.brand b { color: var(--accent); font-weight: 700; }
/* Знак РЯДОМ с текстовым знаком, а не вместо него: текст держит две фирменные
   краски, тянется под ширину экрана и остаётся тем, что читает поисковик и
   скринридер. Поэтому у картинки alt="" — имя продукта уже произнесено
   соседним текстом, и второй раз его объявлять незачем. */
/* Отступ у КАРТИНКИ, а не gap у .brand: gap встаёт между всеми детьми флекса,
   включая <b> внутри слова, и разрывает «JyotiSoft» на «Jyoti Soft». Поймано
   рендером — в разметке этого не видно. */
/* Знак тёмно-синий: на тёмной теме его контраст к --paper 1.1 — он исчезает.
   Поэтому <picture> подменяет файл на logo-dark.png; picture — flex-элемент,
   размеры и отступ остаются на самой картинке. */
.brand picture { display: flex; flex: none; }
.brand-mark { width: 1.9rem; height: 1.9rem; flex: none; margin-right: .5rem; }
.nav { display: flex; gap: 1rem; font-size: .95rem; flex-wrap: wrap; }
.nav a { color: var(--ink-muted); text-decoration: none; }
.nav a:hover { color: var(--accent); }
.lang { font-size: .85rem; color: var(--ink-muted); letter-spacing: .04em; }
.lang a { text-decoration: none; }
.lang [aria-current] { color: var(--ink); font-weight: 600; }

/* ── buttons ────────────────────────────────────────────────────── */
.button {
  display: inline-block;
  padding: .7rem 1.2rem;
  border-radius: 999px;
  border: 1px solid var(--accent);
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  line-height: 1.2;
}
.button:hover { background: rgba(63, 179, 160, .12); }
.button-solid {
  background: var(--slate);
  border-color: var(--slate);
  color: #eaf6f3;
}
.button-solid:hover { background: var(--slate-deep); }

/* ── sections ───────────────────────────────────────────────────── */
section { padding: 3.5rem 0; }
.hero { padding: 4.5rem 0 3rem; }
.eyebrow {
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: .72rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: .75rem;
}
h1 {
  font-size: clamp(2rem, 5vw, 3.1rem);
  line-height: 1.12;
  letter-spacing: -.02em;
  margin: 0 0 1rem;
}
h2 {
  font-size: clamp(1.5rem, 3.2vw, 2.1rem);
  line-height: 1.2;
  letter-spacing: -.015em;
  margin: 0 0 1.5rem;
}
h3 { font-size: 1.05rem; margin: 0 0 .5rem; }
.lead { font-size: 1.15rem; color: var(--ink-muted); max-width: 46rem; margin: 0 0 1.75rem; }
.actions { display: flex; gap: .75rem; flex-wrap: wrap; }
.note { font-size: .9rem; color: var(--ink-muted); margin-top: 1rem; }

.cards { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card {
  background: linear-gradient(145deg, var(--paper-bright), var(--card));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4rem;
}
.card p { margin: 0 0 .75rem; color: var(--ink-muted); }
.card .card-link { font-weight: 600; text-decoration: none; }
.card-index {
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: .5rem;
}

.panel {
  background: var(--slate);
  color: #eaf6f3;
  border-radius: var(--radius);
  padding: 2rem;
}
.panel h2, .panel h3 { color: #f5fbfa; }
.panel p { color: #c3d3dd; }
.panel a:not(.button) { color: var(--accent-bright); }
/* Inside the dark panel the page inks invert: --ink is the ink FOR THE SHEET
   and disappears here (the step titles read as slate-on-slate), and the solid
   button loses its own edge because its background is the panel's. */
.panel ol.steps li { color: #c3d3dd; }
.panel ol.steps li b { color: #f5fbfa; }
.panel .button-solid {
  background: var(--accent-bright);
  border-color: var(--accent-bright);
  color: #08201d;
}

ol.steps { counter-reset: s; list-style: none; padding: 0; display: grid; gap: 1rem; }
ol.steps li { padding-left: 2.6rem; position: relative; color: var(--ink-muted); }
ol.steps li b { color: var(--ink); display: block; }
ol.steps li::before {
  counter-increment: s;
  content: counter(s);
  position: absolute;
  left: 0;
  top: 0;
  width: 1.9rem;
  height: 1.9rem;
  border-radius: 50%;
  background: var(--accent);
  color: #eaf6f3;
  font-weight: 700;
  font-size: .85rem;
  display: grid;
  place-items: center;
}

ul.checks { list-style: none; padding: 0; display: grid; gap: .6rem; }
ul.checks li { padding-left: 1.6rem; position: relative; }
ul.checks li::before { content: "◆"; position: absolute; left: 0; color: var(--accent); }

details {
  border-top: 1px solid var(--line);
  padding: .9rem 0;
}
details summary { cursor: pointer; font-weight: 600; }
details p { color: var(--ink-muted); margin: .6rem 0 0; }

/* ── footer ─────────────────────────────────────────────────────── */
.site-foot {
  border-top: 1px solid var(--line);
  padding: 2rem 0 3rem;
  font-size: .9rem;
  color: var(--ink-muted);
}
.site-foot .cols { display: flex; gap: 2rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.site-foot a { text-decoration: none; }
.site-foot .cols div { display: grid; gap: .35rem; }

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0a1524;
    --paper-bright: #17304f;
    --card: #0e1c30;
    --ink: #e8f4f2;
    --ink-muted: #9db3c4;
    --accent: #56c8b5;
    --line: rgba(232, 244, 242, .16);
    color-scheme: dark;
  }
  .site-head { background: rgba(10, 21, 36, .92); }
  /* The solid button is slate — on a navy sheet that is a button-shaped hole.
     On dark it becomes the accent, which is what it means: the primary CTA. */
  .button-solid { background: var(--accent); border-color: var(--accent); color: #08201d; }
  .button-solid:hover { background: var(--accent-bright); }
  .brand { color: var(--ink); }
  .card { background: linear-gradient(145deg, #17304f, #0e1c30); }
  .panel { background: #0e1c30; }
}
