/* The Convenience Suite — styled after the VanOS Forest theme:
   near-black base with an emerald glow, frosted glass cards with hairline borders,
   amber / teal highlights, white "selected" pills. */
:root {
  --bg: #060907;
  --surface: rgba(255, 255, 255, 0.045);
  --surface-2: rgba(255, 255, 255, 0.06);
  --border: rgba(255, 255, 255, 0.09);
  --hairline: rgba(255, 255, 255, 0.07);
  --text: #f3f6f1;
  --text-2: #a7b0a6;
  --text-3: #8c968b;
  --accent: #4ade80;
  --amber: #f2b33d;
  --teal: #5ec4c4;
  --copper: #e0915a;
  --pill: #f3f6f1;
  --pill-text: #0b0f0c;
  --radius: 24px;
  --blur: blur(22px) saturate(140%);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", Inter, "Segoe UI", Roboto, sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--text);
  background-color: var(--bg);
  background:
    radial-gradient(60% 40% at 100% 100%, rgba(94, 196, 196, 0.09), transparent 70%) fixed,
    radial-gradient(50% 35% at 0% 60%, rgba(242, 179, 61, 0.05), transparent 70%) fixed,
    radial-gradient(120% 70% at 50% -12%, #22472c 0%, #12241a 38%, #070b08 72%, #050706 100%) fixed;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

svg { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

code {
  font-family: ui-monospace, "SF Mono", Consolas, monospace;
  font-size: 0.86em;
  padding: 1px 6px;
  border-radius: 6px;
  background: var(--surface-2);
  border: 1px solid var(--hairline);
  overflow-wrap: anywhere;
}

/* --- Top bar ------------------------------------------------------------ */
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px max(16px, calc((100vw - 1120px) / 2));
  background: rgba(6, 9, 7, 0.55);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 650;
  font-size: 16px;
  text-decoration: none;
  white-space: nowrap;
}

/* --- Pills (VanOS mode chips) ------------------------------------------- */
.pills { display: flex; flex-wrap: wrap; gap: 8px; }

.pill {
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-2);
  text-decoration: none;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.pill:hover { color: var(--text); background: rgba(255, 255, 255, 0.1); }
.pill.is-on { background: var(--pill); color: var(--pill-text); border-color: var(--pill); font-weight: 600; }
.pill:focus-visible, .btn:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* --- Layout ------------------------------------------------------------- */
main { max-width: 1120px; margin: 0 auto; padding: 0 16px; }

.eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-2);
}

.dot {
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c, var(--accent));
  box-shadow: 0 0 10px var(--c, var(--accent));
}

h1, h2, h3 { margin: 0; letter-spacing: -0.02em; line-height: 1.15; }
h1 { font-size: clamp(34px, 6vw, 58px); font-weight: 700; }
h2 { font-size: clamp(24px, 3.4vw, 30px); font-weight: 700; }
h3 { font-size: 20px; font-weight: 650; }

/* --- Hero --------------------------------------------------------------- */
.hero { padding: 72px 0 40px; }
.lede { max-width: 620px; margin: 18px 0 0; font-size: 17px; color: var(--text-2); }

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 36px;
}

.stat {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--surface);
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
}
.stat b { display: block; font-size: 20px; font-weight: 700; }
.stat small { display: block; font-size: 12px; color: var(--text-3); }
.stat-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  font-size: 20px;
  color: var(--c);
  background: color-mix(in srgb, var(--c) 14%, transparent);
}

/* --- Glass card --------------------------------------------------------- */
.card {
  position: relative;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background-color: var(--surface);
  /* the VanOS soft round light just past the top-right corner */
  background-image: radial-gradient(55% 70% at 96% -8%, color-mix(in srgb, var(--app-accent, var(--accent)) 17%, transparent) 0%, transparent 72%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 20px 40px -24px rgba(0, 0, 0, 0.8);
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
}

/* --- Apps --------------------------------------------------------------- */
.apps-section { padding: 32px 0; scroll-margin-top: 72px; }

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 20px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}

.app {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 22px;
  transition: border-color 0.2s, transform 0.2s;
}
.app:hover { border-color: color-mix(in srgb, var(--app-accent, var(--accent)) 35%, var(--border)); transform: translateY(-2px); }
.app[hidden] { display: none; }

.app-head { display: flex; align-items: center; gap: 14px; }
.app-icon {
  flex: none;
  width: 56px;
  height: 56px;
  border-radius: 14px;
  box-shadow: 0 8px 24px -10px color-mix(in srgb, var(--app-accent, var(--accent)) 60%, transparent);
}
.app-icon.placeholder {
  display: grid;
  place-items: center;
  font-size: 24px;
  color: var(--text-3);
  border: 1px dashed rgba(255, 255, 255, 0.2);
  box-shadow: none;
}

.tag {
  display: inline-block;
  margin-bottom: 4px;
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-2);
}
.tag.dashed { border-style: dashed; }

.version { margin: 2px 0 0; font-size: 12px; color: var(--text-3); }

.desc { margin: 0; font-size: 14.5px; color: var(--text-2); }
.desc em { color: var(--text); font-style: normal; font-weight: 600; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.chips li {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  font-size: 12.5px;
  font-weight: 500;
}
.chips .dot { --c: var(--app-accent); width: 7px; height: 7px; }

.actions { display: flex; align-items: center; gap: 12px; margin-top: auto; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 999px;
  background: var(--pill);
  color: var(--pill-text);
  font-size: 14px;
  font-weight: 650;
  text-decoration: none;
  transition: box-shadow 0.2s, transform 0.2s;
}
.btn svg { font-size: 17px; stroke-width: 2.2; }
.btn:hover { box-shadow: 0 0 0 4px color-mix(in srgb, var(--app-accent, var(--accent)) 30%, transparent); }
.btn:active { transform: scale(0.97); }

.size { font-size: 12px; color: var(--text-3); }

details {
  border-top: 1px solid var(--hairline);
  padding-top: 12px;
}
summary {
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: 6px;
}
summary::-webkit-details-marker { display: none; }
summary::before {
  content: "";
  width: 6px;
  height: 6px;
  border-right: 1.8px solid currentColor;
  border-bottom: 1.8px solid currentColor;
  transform: rotate(-45deg);
  transition: transform 0.2s;
}
details[open] summary::before { transform: rotate(45deg); }
summary:hover { color: var(--text); }
details ol { margin: 12px 0 0; padding-left: 20px; font-size: 13.5px; color: var(--text-2); }
details li + li { margin-top: 6px; }
details b { color: var(--text); }

.soon { border-style: dashed; background-image: none; }
.soon:hover { transform: none; border-color: var(--border); }

/* --- About -------------------------------------------------------------- */
.about {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 32px;
  align-items: center;
  margin: 24px 0 48px;
  padding: 32px;
  --app-accent: var(--amber);
  scroll-margin-top: 80px;
}
.about p:not(.eyebrow) { color: var(--text-2); margin: 12px 0 0; }

.promises { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.promises li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--surface-2);
}
.promises .dot { margin-top: 6px; }
.promises b { display: block; font-size: 14px; }
.promises small { color: var(--text-3); font-size: 12.5px; }

/* --- Footer ------------------------------------------------------------- */
.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  max-width: 1120px;
  margin: 0 auto;
  padding: 24px 16px 40px;
  border-top: 1px solid var(--hairline);
  font-size: 12.5px;
  color: var(--text-3);
}

/* --- Small screens ------------------------------------------------------ */
@media (max-width: 820px) {
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about { grid-template-columns: 1fr; padding: 24px; }
}
@media (max-width: 480px) {
  .hero { padding-top: 44px; }
  .hero h1 br { display: none; }
  .brand span { font-size: 14px; }
  .topbar .pills { gap: 6px; }
  .grid { grid-template-columns: 1fr; }
  .app { padding: 18px; }
  .stat { padding: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
