/* ============================================================
   AppStorrent satellite — dark + cyan theme
   palette: cyan #00d9ff · cyan-dark #00b8e6 · ink #0d0d0d
   surface: #1a1a1a · panel: #222 · border: #333
   ============================================================ */
:root {
  --cyan: #00d9ff;
  --cyan-dark: #00b8e6;
  --cyan-soft: rgba(0, 217, 255, .12);
  --ink: #0d0d0d;
  --bg: #141414;
  --bg-alt: #1a1a1a;
  --panel: #1f1f1f;
  --panel-2: #262626;
  --border: #2c2c2c;
  --border-strong: #3a3a3a;
  --text: #e8e8e8;
  --text-soft: #b8b8b8;
  --muted: #a8a8a8;
  --warn: #ffb84d;
  --good: #4cd97a;
  --grad: linear-gradient(135deg, #00d9ff 0%, #00b8e6 60%, #0098cc 100%);
  --shadow-card: 0 14px 32px -18px rgba(0, 0, 0, .8);
  --shadow-glow: 0 0 30px -8px rgba(0, 217, 255, .35);
  --rad: 14px;
  --sans: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, sans-serif;
  --display: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Inter", sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; background: var(--ink); }
section[id], h2[id] { scroll-margin-top: 80px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1 !important; transform: none !important; }
}
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px; line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  background-image:
    radial-gradient(900px 500px at 88% -10%, rgba(0, 217, 255, .08), transparent 60%),
    radial-gradient(700px 400px at -10% 30%, rgba(0, 152, 204, .06), transparent 65%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--cyan); text-decoration: none; transition: color .15s; }
a:hover, a:focus-visible { color: var(--cyan-dark); }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; }
h1, h2, h3, h4 {
  line-height: 1.15; letter-spacing: -.02em; margin: 0 0 .6em;
  font-weight: 800; color: #f5f5f5; font-family: var(--display);
}
h1 { font-size: clamp(2.25rem, 5.5vw, 3.75rem); letter-spacing: -.035em; }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); margin-top: 0; }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; color: var(--text-soft); }
strong { color: #fff; font-weight: 700; }
code { font-family: var(--mono); background: var(--panel-2); padding: .15rem .4rem; border-radius: 4px; font-size: .9em; color: var(--cyan); }
hr { border: 0; border-top: 1px solid var(--border); margin: 2rem 0; }
.skip { position: absolute; left: -9999px; top: 0; background: var(--cyan); color: var(--ink); padding: .75rem 1rem; z-index: 1000; font-weight: 700; border-radius: 0 0 8px 0; }
.skip:focus { left: 0; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 1.5rem; }
.wrap-narrow { max-width: 880px; margin: 0 auto; padding: 0 1.5rem; }
.sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* NAV — appstorrent.org style with emoji nav items */
.nav { position: sticky; top: 0; z-index: 50; background: var(--bg-alt); border-bottom: 1px solid #2a2a2a; transition: border-color .2s, background .2s; }
.nav.scrolled { background: rgba(26, 26, 26, .96); backdrop-filter: saturate(180%) blur(14px); -webkit-backdrop-filter: saturate(180%) blur(14px); }
.nav-inner { display: flex; align-items: center; gap: 1.5rem; height: 60px; max-width: 1280px; margin: 0 auto; padding: 0 1.5rem; }
.brand { display: flex; align-items: center; gap: .6rem; font-weight: 700; font-size: 1.05rem; color: #fff; letter-spacing: -.005em; flex-shrink: 0; }
.brand:hover { color: #fff; }
.brand img { width: 32px; height: 32px; border-radius: 6px; }
.brand .b { color: var(--cyan); }
.nav-links { display: none; gap: .25rem; flex: 1; }
@media (min-width: 880px) { .nav-links { display: flex; } }
.nav-item { display: inline-flex; align-items: center; gap: .4rem; color: #ccc; font-size: .92rem; font-weight: 500; padding: .55rem .85rem; border-radius: 6px; transition: background .15s, color .15s; }
.nav-item:hover, .nav-item:focus-visible { color: var(--cyan); background: #2a2a2a; }
.nav-item .emoji { font-size: 1.05rem; line-height: 1; }
.nav-right { display: flex; align-items: center; gap: .75rem; margin-left: auto; }
.lang-pick { display: inline-flex; align-items: center; gap: .35rem; background: #2a2a2a; border: 1px solid #333; color: #ccc; padding: .45rem .75rem; border-radius: 6px; font-size: .85rem; font-weight: 500; cursor: pointer; transition: border-color .15s, color .15s; }
.lang-pick:hover { border-color: var(--cyan); color: var(--cyan); }
.lang-pick::after { content: "▾"; font-size: .7rem; opacity: .7; }

/* HERO — appstorrent-style with search bar */
.hero { position: relative; padding: 3.5rem 0 2.5rem; text-align: center; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(700px 300px at 50% 0%, rgba(0, 217, 255, .08), transparent 70%); }
.hero .wrap { position: relative; }
.hero-title { color: #fff; font-size: clamp(1.9rem, 4vw, 2.75rem); margin: 0 0 .65rem; letter-spacing: -.025em; }
.hero-title .b { color: var(--cyan); }
.hero-sub { color: var(--text-soft); font-size: 1.05rem; max-width: 640px; margin: 0 auto 2rem; }
.search-bar { display: flex; max-width: 620px; margin: 0 auto; background: var(--panel); border: 1px solid #333; border-radius: 10px; padding: .25rem; transition: border-color .15s; }
.search-bar:focus-within { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(0, 217, 255, .15); }
.search-bar input { flex: 1; background: none; border: 0; color: #fff; font: inherit; padding: .8rem 1rem; outline: none; min-width: 0; }
.search-bar input::placeholder { color: #777; }
.search-bar button { background: var(--cyan); color: var(--ink); font-weight: 700; padding: 0 1.3rem; border-radius: 8px; font-size: .92rem; transition: filter .15s; }
.search-bar button:hover { filter: brightness(1.1); }
.btn { display: inline-flex; align-items: center; gap: .55rem; padding: .85rem 1.4rem; border-radius: 8px; font-weight: 700; font-size: .95rem; transition: transform .15s, box-shadow .2s, background .2s, filter .15s, color .2s, border-color .2s; white-space: nowrap; min-height: 44px; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--cyan); color: var(--ink); box-shadow: 0 8px 20px -6px rgba(0, 217, 255, .4); }
.btn-primary:hover { color: var(--ink); filter: brightness(1.1); }
.btn-ghost { background: var(--panel); color: var(--text); border: 1px solid #333; }
.btn-ghost:hover { color: var(--cyan); border-color: var(--cyan); }

/* CATEGORY SECTION — appstorrent.org style */
.cat-section { padding: 2.5rem 0 1rem; }
.cat-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; padding-bottom: .85rem; border-bottom: 1px solid #2a2a2a; }
.cat-head h2 { color: #fff; font-size: 1.5rem; margin: 0; display: inline-flex; align-items: center; gap: .55rem; }
.cat-head h2 .emoji { font-size: 1.35rem; }
.see-all { color: var(--cyan); font-weight: 600; font-size: .9rem; display: inline-flex; align-items: center; gap: .35rem; transition: gap .15s; }
.see-all:hover { color: var(--cyan); gap: .55rem; }
.see-all::after { content: "→"; }

.card-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1rem; }
@media (max-width: 1080px) { .card-grid { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 880px) { .card-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 620px) { .card-grid { grid-template-columns: repeat(2, 1fr); } }

.soft-item { background: var(--panel); border: 1px solid #2a2a2a; border-radius: 10px; padding: 1rem; text-align: left; color: inherit; display: flex; flex-direction: column; gap: .55rem; transition: transform .2s, border-color .2s, background .2s; position: relative; cursor: default; }
.soft-item:hover { transform: translateY(-3px); border-color: var(--cyan); background: var(--panel-2); }
.os-grid .ver { cursor: default; }
.soft-item .icon-wrap { display: flex; justify-content: center; padding: .35rem 0 .5rem; }
.soft-item .icon-wrap img { width: 64px; height: 64px; border-radius: 14px; }
.soft-item .title { color: #fff; font-weight: 600; font-size: .92rem; line-height: 1.25; min-height: 2.4em; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-align: center; }
.soft-item .meta { display: flex; justify-content: space-between; align-items: center; gap: .35rem; font-size: .75rem; color: var(--muted); border-top: 1px solid #262626; padding-top: .55rem; }
.soft-item .meta .v { color: #ccc; font-weight: 600; }
.soft-item .meta .sz { color: var(--muted); }
.soft-item .badge-tag { position: absolute; top: .55rem; right: .55rem; font-size: .65rem; font-weight: 800; letter-spacing: .05em; padding: .2rem .45rem; border-radius: 4px; text-transform: uppercase; }
.soft-item .badge-tag.new { background: var(--cyan); color: var(--ink); }
.soft-item .badge-tag.upd { background: rgba(255, 184, 77, .18); color: var(--warn); border: 1px solid rgba(255, 184, 77, .35); }

/* OS Versions grid (re-using ver class) */
.os-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 1rem; }
@media (max-width: 720px) { .os-grid { grid-template-columns: repeat(3, 1fr); } }
.ver { display: flex; flex-direction: column; align-items: center; gap: .55rem; padding: 1.1rem .5rem; background: var(--panel); border: 1px solid #2a2a2a; border-radius: 10px; transition: transform .2s, border-color .2s, background .2s; }
.ver:hover { transform: translateY(-3px); border-color: var(--cyan); background: var(--panel-2); }
.ver img { width: 56px; height: 56px; border-radius: 12px; }
.ver span { font-size: .82rem; font-weight: 600; color: #ccc; }
.ver:hover span { color: var(--cyan); }

/* BAND */
.band { padding: 5rem 0; }
.band.dark { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.band.darker { background: var(--ink); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
@media (max-width: 700px) { .band { padding: 3.5rem 0; } }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 3rem; }
.section-head .eyebrow { display: inline-block; background: var(--cyan-soft); color: var(--cyan); font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: .35rem .85rem; border-radius: 999px; margin-bottom: 1rem; }
.section-head h2 { margin-bottom: .65rem; color: #fff; }
.section-head p { color: var(--text-soft); font-size: 1.1rem; line-height: 1.55; max-width: 580px; margin: 0 auto; }
.section-head.left { text-align: left; max-width: none; }

/* STATS */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; max-width: 980px; margin: 0 auto; }
@media (max-width: 760px) { .stats { grid-template-columns: repeat(2, 1fr); } }
.stat { background: var(--panel); border: 1px solid var(--border); border-radius: var(--rad); padding: 1.5rem 1.25rem; text-align: center; transition: transform .25s, border-color .25s, box-shadow .25s; }
.stat:hover { transform: translateY(-3px); border-color: var(--cyan); box-shadow: var(--shadow-glow); }
.stat .n { font-family: var(--display); font-size: clamp(1.8rem, 4vw, 2.4rem); font-weight: 800; color: var(--cyan); line-height: 1; margin-bottom: .35rem; letter-spacing: -.02em; font-variant-numeric: tabular-nums; min-height: 1em; }
.stat .l { font-size: .85rem; color: var(--muted); font-weight: 500; }

/* FEATURE GRID */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
@media (max-width: 920px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid-3 { grid-template-columns: 1fr; } }
.card { background: var(--panel); border: 1px solid var(--border); border-radius: var(--rad); padding: 1.75rem; transition: transform .25s, border-color .25s, box-shadow .25s; }
.card:hover { transform: translateY(-4px); border-color: var(--border-strong); box-shadow: var(--shadow-card); }
.card .ic { width: 44px; height: 44px; border-radius: 10px; background: var(--cyan-soft); color: var(--cyan); display: grid; place-items: center; margin-bottom: 1rem; }
.card h3 { margin: 0 0 .5rem; color: #fff; font-size: 1.1rem; }
.card p { margin: 0; color: var(--text-soft); font-size: .95rem; line-height: 1.55; }

/* SPLIT — Mac/Windows blocks */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; } }
.split-card { background: var(--panel); border: 1px solid var(--border); border-radius: var(--rad); padding: 1.75rem; }
.split-card .head { display: flex; align-items: center; gap: .75rem; margin-bottom: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--border); }
.split-card .badge { display: inline-flex; align-items: center; gap: .4rem; padding: .3rem .7rem; border-radius: 999px; font-size: .75rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.split-card .badge.mac { background: var(--cyan-soft); color: var(--cyan); }
.split-card .badge.win { background: rgba(255, 184, 77, .12); color: var(--warn); }
.split-card h3 { margin: 0; color: #fff; font-size: 1.05rem; }
.split-card p { margin: 0 0 .9em; font-size: .95rem; color: var(--text-soft); line-height: 1.6; }
.split-card p:last-child { margin-bottom: 0; }

/* ARTICLE */
.article { max-width: 820px; margin: 0 auto; }
.article > .lead { font-size: 1.15rem; color: var(--text); line-height: 1.65; margin: 0 0 2.5rem; padding-left: 1.25rem; border-left: 3px solid var(--cyan); }
.article h2 { margin: 2.5rem 0 1rem; color: #fff; font-size: 1.55rem; }
.article h2:first-of-type { margin-top: 0; }
.article p { color: var(--text-soft); margin: 0 0 1.1em; }
.article ul { color: var(--text-soft); padding-left: 1.4rem; margin: 0 0 1.25em; }
.article ul li { margin-bottom: .4em; }
.article ul li::marker { color: var(--cyan); }

/* COMPAT TABLE */
.compat-wrap { background: var(--panel); border: 1px solid var(--border); border-radius: var(--rad); padding: 1.25rem; overflow-x: auto; }
.compat { width: 100%; border-collapse: collapse; font-size: .94rem; }
.compat th, .compat td { text-align: left; padding: .85rem 1rem; border-bottom: 1px solid var(--border); }
.compat th { color: var(--muted); font-weight: 600; font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; }
.compat td { color: var(--text); }
.compat tr:last-child td { border-bottom: 0; }
.compat .ok { color: var(--good); font-weight: 700; }
.compat .no { color: var(--warn); font-weight: 700; }

/* FAQ */
.faq-list { display: flex; flex-direction: column; gap: .65rem; max-width: 820px; margin: 0 auto; }
.faq-item { background: var(--panel); border: 1px solid var(--border); border-radius: 12px; padding: 0; overflow: hidden; transition: border-color .25s; }
.faq-item[open] { border-color: var(--border-strong); }
.faq-item summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.1rem 1.4rem; cursor: pointer; list-style: none; font-weight: 600; color: #fff; font-size: 1rem; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; flex-shrink: 0; width: 28px; height: 28px; border-radius: 50%; background: var(--cyan-soft); color: var(--cyan); display: inline-flex; align-items: center; justify-content: center; font-family: var(--mono); font-weight: 400; font-size: 1.4rem; line-height: 1; padding-bottom: 2px; transition: transform .25s, background .25s; }
.faq-item[open] summary::after { transform: rotate(45deg); background: var(--cyan); color: var(--ink); }
.faq-item .faq-body { padding: 0 1.4rem 1.25rem; color: var(--text-soft); font-size: .96rem; line-height: 1.6; }

/* CTA BAND */
.cta-band { padding: 4.5rem 0; text-align: center; background: linear-gradient(135deg, #0f1f24 0%, #0a1518 100%); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); position: relative; overflow: hidden; }
.cta-band::before { content: ""; position: absolute; inset: 0; background: radial-gradient(500px 250px at 50% 0%, rgba(0, 217, 255, .14), transparent 70%); pointer-events: none; }
.cta-band .wrap { position: relative; }
.cta-band h2 { color: #fff; margin-bottom: .65rem; }
.cta-band p { color: var(--text-soft); max-width: 540px; margin: 0 auto 1.75rem; }

/* AUTHOR CARD */
.author-card { display: flex; align-items: center; gap: 1.25rem; background: var(--panel); border: 1px solid var(--border); border-radius: 14px; padding: 1.25rem 1.5rem; max-width: 820px; margin: 2.5rem auto 0; }
.author-card img { width: 72px; height: 72px; border-radius: 50%; border: 2px solid var(--cyan-soft); flex-shrink: 0; }
.author-card .who { font-weight: 700; color: #fff; margin: 0 0 .15rem; font-size: 1rem; }
.author-card .role { font-size: .85rem; color: var(--muted); margin: 0 0 .25rem; }
.author-card .more { font-size: .85rem; color: var(--cyan); font-weight: 600; }
@media (max-width: 560px) { .author-card { flex-direction: column; text-align: center; } }

/* FOOTER — minimal (iMazing/LM Studio style) */
footer { background: var(--ink); color: var(--muted); padding: 2.5rem 0 2rem; border-top: 1px solid var(--border); }
.foot-inner { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .65rem; }
.foot-inner .brand { font-size: 1rem; }
.foot-inner .brand img { width: 32px; height: 32px; }
.foot-inner .tagline { color: var(--text-soft); font-size: .9rem; line-height: 1.55; max-width: 540px; margin: 0; }
.foot-inner .copy { color: var(--muted); font-size: .82rem; margin: 0; }
.link-btn { background: none; color: var(--text-soft); font-weight: 500; padding: 0; border: 0; cursor: pointer; text-decoration: underline; text-decoration-color: rgba(168, 168, 168, .35); text-underline-offset: 3px; font: inherit; transition: color .15s; }
.link-btn:hover, .link-btn:focus-visible { color: var(--cyan); text-decoration-color: var(--cyan); }

/* REVEAL */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; will-change: opacity, transform; }
.reveal.in { opacity: 1; transform: none; }

/* COOKIE BANNER */
.cookie { position: fixed; left: 1rem; right: 1rem; bottom: 1rem; background: var(--panel-2); border: 1px solid var(--border-strong); color: var(--text); padding: 1rem 1.25rem; border-radius: 14px; box-shadow: 0 18px 40px -10px rgba(0, 0, 0, .6); z-index: 200; display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; justify-content: space-between; max-width: 720px; margin: 0 auto; transition: opacity .25s, transform .25s; }
.cookie.hidden { opacity: 0; transform: translateY(20px); pointer-events: none; }
.cookie p { margin: 0; font-size: .9rem; color: var(--text-soft); flex: 1; min-width: 220px; }
.cookie a { color: var(--cyan); }
.cookie button { background: var(--cyan); color: var(--ink); border-radius: 8px; padding: .55rem 1.2rem; font-weight: 700; font-size: .88rem; }
.cookie button:hover { background: var(--cyan-dark); }
