/* ==========================================================
   Installer styles
   Screens are previewable without JS via :target
   (#welcome, #location, #installing, #done).
   Later, JS can toggle the .is-active class instead.
   ========================================================== */

:root {
  --bg:            #111418;
  --bg-raised:     #181c22;
  --bg-input:      #0d1014;
  --border:        #262c35;
  --border-strong: #343c48;

  --text:          #f2f5f7;
  --text-muted:    #98a2ae;
  --text-faint:    #647080;

  --accent:        #00ae5e;
  --accent-2:      #00c3d0;
  --accent-soft:   #6fe8b0;
  --accent-grad:   linear-gradient(135deg, var(--accent), var(--accent-2));

  --danger:        #ff6b6b;

  --radius:        10px;
  --radius-sm:     6px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;

  --win-w: 720px;
  --win-h: 480px;
  --titlebar-h: 40px;
}

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

html, body {
  margin: 0;
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

::selection {
    /* background: var(--accent); */
    color: var(--surface);
}

img { display: block; }
h1, h2, p, ul { margin: 0; padding: 0; }
ul { list-style: none; }
[hidden] { display: none !important; }

/* ---------- Window frame ---------- */

.window {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-height: 100%;
  max-width: var(--win-w);
  height: var(--win-h);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

/* ---------- Title bar ---------- */

.titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--titlebar-h);
  padding: 0 6px 0 14px;
  -webkit-app-region: drag;
}

.titlebar__brand { display: flex; align-items: center; gap: 8px; }
.titlebar__logo  { width: 16px; height: 16px; object-fit: contain; }
.titlebar__title { font-size: 12px; color: var(--text-muted); letter-spacing: .02em; }

.titlebar__controls { display: flex; gap: 2px; -webkit-app-region: no-drag; }

.titlebar__btn {
  width: 34px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-muted);
  font-size: 13px;
  cursor: pointer;
  transition: background .15s, color .15s;
}
.titlebar__btn:hover        { background: var(--bg-raised); color: var(--text); }
.titlebar__btn--close:hover { background: var(--danger); color: #fff; }

/* ---------- Screens ---------- */

.screens { position: relative; flex: 1; min-height: 0; }

.screen {
  display: none;
  flex-direction: column;
  position: absolute;
  inset: 0;
}

/* Default: show the first screen */
.screens:not(:has(.screen:target, .screen.is-active)) .screen:first-child { display: flex; }
/* No-JS preview: show whichever screen is targeted */
.screen:target,
.screen.is-active { display: flex; }

.screen__body {
  flex: 1;
  min-height: 0;
  padding: 24px 44px 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.screen__body--center {
  align-items: center;
  justify-content: center;
  text-align: center;
}

.screen__title    { font-size: 22px; font-weight: 600; letter-spacing: -.01em; }
.screen__subtitle { color: var(--text-muted); margin-bottom: 14px; }

.screen__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  border-top: 1px solid var(--border);
  background: var(--bg-raised);
}
.footer__note { font-size: 12px; color: var(--text-faint); }
.actions { display: flex; gap: 10px; }

/* ---------- Welcome ---------- */

.hero-logo   { width: 96px; height: 96px; object-fit: contain; margin-bottom: 14px; }
.app-name    { font-size: 30px; font-weight: 700; letter-spacing: -.02em; }
.app-version { font-family: var(--mono); font-size: 12px; color: var(--text-faint); margin-top: 2px; }
.lead        { color: var(--text-muted); max-width: 380px; margin-top: 12px; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 92px;
  height: 36px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font: inherit;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  cursor: pointer;
  transition: filter .15s, background .15s, border-color .15s, transform .05s;
}
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 2px; }

.btn--primary { background: var(--accent-grad); color: #04130c; font-weight: 600; }
.btn--primary:hover { filter: brightness(1.08); }

.btn--ghost { background: transparent; border-color: var(--border-strong); }
.btn--ghost:hover { background: var(--bg-raised); border-color: var(--text-faint); }

.btn--text { background: transparent; color: var(--text-muted); min-width: 0; padding: 0 8px; }
.btn--text:hover { color: var(--text); }

.btn[disabled], .btn.is-disabled { opacity: .45; pointer-events: none; }

/* ---------- Form field ---------- */

.field { display: flex; flex-direction: column; gap: 6px; }
.field__label { font-size: 12px; color: var(--text-muted); }
.field__row   { display: flex; gap: 8px; }
.field__hint  { font-size: 12px; color: var(--text-faint); }

.input {
  flex: 1;
  min-width: 0;
  height: 36px;
  padding: 0 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--mono);
  font-size: 12px;
  user-select: text;
  transition: border-color .15s, box-shadow .15s;
}
.input:focus {
  outline: none;
  border-color: var(--accent-2);
  box-shadow: 0 0 0 3px rgba(0, 195, 208, .15);
}

/* ---------- Checkboxes ---------- */

.options { display: flex; flex-direction: column; gap: 10px; margin-top: 18px; }

.check {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}
.check--center { margin-top: 18px; }
.check input { position: absolute; opacity: 0; pointer-events: none; }

.check__box {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border-strong);
  border-radius: 5px;
  background: var(--bg-input);
  transition: background .15s, border-color .15s;
}
.check__box::after {
  content: "";
  width: 9px;
  height: 5px;
  border-left: 2px solid #04130c;
  border-bottom: 2px solid #04130c;
  transform: rotate(-45deg) translate(1px, -1px);
  opacity: 0;
}
.check input:checked + .check__box { background: var(--accent-grad); border-color: transparent; }
.check input:checked + .check__box::after { opacity: 1; }
.check input:focus-visible + .check__box { outline: 2px solid var(--accent-2); outline-offset: 2px; }
.check__text { color: var(--text); }

/* ---------- Messages ---------- */

.message { margin-top: 14px; font-size: 13px; }
.message--error { color: var(--danger); }

/* ---------- Progress ---------- */

.progress {
  width: 100%;
  max-width: 460px;
  height: 8px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 999px;
  overflow: hidden;
}
.progress__bar {
  --value: 42%;               /* JS will set this later */
  width: var(--value);
  height: 100%;
  background: var(--accent-grad);
  border-radius: inherit;
  transition: width .2s ease;
}
.progress__meta {
  display: flex;
  justify-content: space-between;
  width: 100%;
  max-width: 460px;
  margin-top: 8px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text-faint);
}
.progress__meta span:first-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-right: 16px;
}

/* ---------- Done ---------- */

.done-mark {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  margin-bottom: 14px;
  border-radius: 50%;
  background: var(--accent-grad);
  color: #04130c;
  font-size: 30px;
  font-weight: 700;
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}

/* an empty description (the <auto> had no value) takes no space */
.lead:empty { display: none; }

:root {
            --bg: #111418;
            --surface: rgb(24, 28, 34);
            --surface-2: #1e242c;
            --border: #2b323c;
            --text: #f2f5f7;
            --muted: #98a2ae;
            --accent: #00ae5e;
            --cyan: #00c3d0;
            --gradient: linear-gradient(120deg, var(--accent), var(--cyan));
            --radius: 12px;
            --max-width: 1120px;
        }

        * {
            box-sizing: border-box;
        }

        html {
            scroll-behavior: smooth;
            scroll-padding-top: 85px;
        }

        body {
            margin: 0;
            background: var(--bg);
            color: var(--text);
            font-family: Inter, system-ui, -apple-system, sans-serif;
            line-height: 1.65;
        }

        a {
            color: inherit;
            text-decoration: none;
        }
        button {
            font: inherit;
        }

        .container {
            width: min(var(--max-width), calc(100% - 40px));
            margin: auto;
        }

        .navbar {
            position: sticky;
            top: 0;
            z-index: 10;
            background: rgba(17, 20, 24, .9);
            backdrop-filter: blur(16px);
            border-bottom: 1px solid var(--border);
        }

        .nav-inner {
            height: 70px;
            display: flex;
            align-items: center;
            justify-content: space-between;
        }

        .brand {
            display: flex;
            align-items: center;
            gap: 10px;
            font-weight: 700;
            font-size: 18px;
        }

        .brand img {
            height: 50px;
            object-fit: contain;
        }

        .nav-links {
            display: flex;
            align-items: center;
            gap: 28px;
            color: var(--muted);
            font-size: 14px;
        }

        .nav-links a:hover {
            color: var(--text);
        }

        .nav-actions {
            display: flex;
            align-items: center;
            gap: 10px;
        }

        .menu-toggle {
            display: none;
            background: transparent;
            border: 1px solid var(--border);
            color: var(--text);
            border-radius: 8px;
            padding: 7px 11px;
            cursor: pointer;
        }

        .button {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            min-height: 42px;
            padding: 0 18px;
            border-radius: 8px;
            border: 1px solid var(--border);
            font-size: 14px;
            font-weight: 600;
            transition: .2s ease;
            cursor: pointer;
        }

        .button-primary {
            color: #04130c;
            background: var(--gradient);
            border-color: transparent;
        }

        .button-primary:hover {
            filter: brightness(1.1);
            transform: translateY(-2px);
        }

        .button-secondary {
            background: var(--surface);
        }

        .button-secondary:hover {
            border-color: var(--accent);
        }

        .hero {
            padding: 110px 0 100px;
            text-align: center;
            position: relative;
            overflow: hidden;
        }

        .hero::before {
            content: "";
            position: absolute;
            width: 500px;
            height: 200px;
            background: var(--accent); 
            opacity: .09;
            filter: blur(120px);
            top: 0;
            left: 50%;
            transform: translateX(-50%);
            pointer-events: none;
        }

        .eyebrow {
            display: inline-flex;
            padding: 6px 12px;
            border: 1px solid #22543d;
            background: #10251b;
            color: #6fe8b0;
            border-radius: 100px;
            font-size: 12px;
            font-weight: 600;
            letter-spacing: .04em;
        }

        .hero h1 {
            font-size: clamp(42px, 7vw, 76px);
            line-height: 1.08;
            letter-spacing: -.055em;
            margin: 24px auto 18px;
            max-width: 850px;
        }

        .gradient-text {
            background: var(--gradient);
            background-clip: text;
            -webkit-background-clip: text;
            color: rgba(24, 28, 34, 95%);

            text-shadow:
                -1px -1px 1px rgb(255 255 255 / 45%),
                0 0 12px rgb(0 195 208 / 42%),
                -1px -1px 15px rgba(0, 174, 94, 25%);
        }

        .hero p {
            max-width: 650px;
            margin: auto;
            color: var(--muted);
            font-size: 17px;
        }

        .hero-actions {
            display: flex;
            justify-content: center;
            gap: 12px;
            margin-top: 30px;
            flex-wrap: wrap;
        }

        .hero-logo {
            width: 100px;
            height: 100px;
            object-fit: contain;
            margin-bottom: 22px;
        }

        .hero-note {
            margin-top: 20px !important;
            font-size: 12px !important;
            color: var(--muted);
        }

        .section {
            padding: 85px 0;
        }

        .section-header {
            max-width: 650px;
            margin-bottom: 42px;
        }

        .section-header h2 {
            font-size: clamp(30px, 4vw, 42px);
            line-height: 1.2;
            letter-spacing: -.035em;
            margin: 12px 0;
        }

        .section-header p {
            color: var(--muted);
        }

        .features {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 16px;
        }

        .feature {
            padding: 25px;
            background: var(--surface);
            border: 1px solid var(--border);
            border-radius: var(--radius);
            transition: border-color .2s, transform .2s;
        }

        .feature:hover {
            border-color: var(--accent);
            transform: translateY(-3px);
        }

        .feature-icon {
            width: 42px;
            height: 42px;
            display: grid;
            place-items: center;
            background: var(--surface-2);
            border-radius: 10px;
            font-size: 20px;
            margin-bottom: 18px;
        }
        h3 .feature-icon {
            background: none;
            color: var(--surface-3);
        }

        .button-icon svg {
            background-color: none;
            color: var(--text);
            width: 24px;
        }
        .button-icon {
            padding: 8px;
        }

        .feature h3 {
            font-size: 17px;
            margin: 0 0 8px;
        }

        .feature p {
            font-size: 14px;
            color: var(--muted);
            margin: 0;
        }

        .platforms {
            background: var(--surface);
            border-top: 1px solid var(--border);
            border-bottom: 1px solid var(--border);
        }

        .platform-grid {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 18px;
        }

        .platform {
            padding: 30px;
            border: 1px solid var(--border);
            border-radius: var(--radius);
            background: var(--bg);
        }

        .platform h3 {
            font-size: 22px;
            margin: 0 0 8px;
        }

        .platform p {
            color: var(--muted);
            font-size: 14px;
        }

        .workflow {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 20px;
            counter-reset: steps;
        }

        .step {
            counter-increment: steps;
            padding: 25px;
            border-left: 2px solid var(--accent-2);
            background: var(--surface);
            border-radius: 10px;
        }

        .step::before {
            content: "0" counter(steps);
            display: block;
            color: var(--accent);
            font-family: monospace;
            font-size: 13px;
            margin-bottom: 16px;
        }

        .step h3 {
            margin: 0 0 8px;
        }

        .step p {
            color: var(--muted);
            font-size: 14px;
        }

        .code-card {
            background: #0b0e11;
            border: 1px solid var(--border);
            border-radius: var(--radius);
            overflow: hidden;
            max-width: 700px;
        }

        .code-header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 12px 16px;
            background: var(--surface);
            border-bottom: 1px solid var(--border);
            color: var(--muted);
            font-size: 12px;
        }

        .code-card pre {
            margin: 0;
            padding: 22px;
            overflow-x: auto;
            color: #a6e8c3;
            font: 13px/1.8 "JetBrains Mono", monospace;
        }

        .copy-button {
            border: 1px solid var(--border);
            color: var(--text);
            background: var(--surface-2);
            border-radius: 5px;
            padding: 5px 10px;
            cursor: pointer;
            font-size: 12px;
        }

        .copy-button:hover {
            border-color: var(--accent);
        }

        .cta {
            padding: 55px 30px;
            text-align: center;
            border: 1px solid var(--border);
            border-radius: 18px;
            background: radial-gradient(ellipse at top, #153326, var(--surface));
        }

        .cta h2 {
            font-size: 34px;
            margin: 0 0 12px;
        }

        .cta p {
            color: var(--muted);
            margin-bottom: 25px;
        }

        footer {
            margin-top: 90px;
            padding: 30px 0;
            border-top: 1px solid var(--border);
            color: var(--muted);
            font-size: 13px;
        }

        .footer-inner {
            display: flex;
            justify-content: space-between;
            gap: 20px;
            flex-wrap: wrap;
        }

        .footer-links {
            display: flex;
            gap: 20px;
        }

        .footer-links a:hover {
            color: var(--text);
        }

        @media (max-width: 800px) {
            .features {
                grid-template-columns: repeat(2, 1fr);
            }

            .workflow {
                grid-template-columns: 1fr;
            }

            .nav-links {
                display: none;
                position: absolute;
                top: 70px;
                left: 0;
                right: 0;
                padding: 20px;
                background: var(--surface);
                border-bottom: 1px solid var(--border);
                flex-direction: column;
                align-items: stretch;
                gap: 18px;
            }

            .nav-links.is-open {
                display: flex;
            }

            .menu-toggle {
                display: block;
            }

            .nav-actions .button {
                display: none;
            }
        }

        @media (max-width: 550px) {
            .features,
            .platform-grid {
                grid-template-columns: 1fr;
            }

            .hero {
                padding: 75px 0;
            }

            .hero p {
                font-size: 15px;
            }

            .section {
                padding: 60px 0;
            }

            .footer-inner {
                flex-direction: column;
            }
        }

        @media (prefers-reduced-motion: reduce) {
            *, *::before, *::after {
                scroll-behavior: auto !important;
                transition: none !important;
            }
        }