:root {
  --bg: #f4f7fb;
  --surface: rgba(255,255,255,.82);
  --surface-solid: #ffffff;
  --text: #111827;
  --muted: #6b7280;
  --line: rgba(17,24,39,.08);
  --accent: #2563eb;
  --accent-soft: rgba(37,99,235,.11);
  --shadow: 0 18px 60px rgba(15,23,42,.10);
}

html[data-theme="dark"] {
  --bg: #0b1020;
  --surface: rgba(17,24,39,.76);
  --surface-solid: #111827;
  --text: #f8fafc;
  --muted: #9ca3af;
  --line: rgba(255,255,255,.09);
  --accent: #60a5fa;
  --accent-soft: rgba(96,165,250,.14);
  --shadow: 0 18px 60px rgba(0,0,0,.28);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--bg);
  transition: background .2s ease, color .2s ease;
  overflow-x: hidden;
}

.bg-orb {
  position: fixed;
  width: 420px;
  height: 420px;
  filter: blur(90px);
  opacity: .18;
  border-radius: 999px;
  pointer-events: none;
  z-index: -1;
}

.orb-one { background: #3b82f6; top: -180px; right: -120px; }
.orb-two { background: #8b5cf6; bottom: -220px; left: -160px; }

.topbar {
  max-width: 1180px;
  margin: 0 auto;
  padding: 28px 24px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand { display: flex; align-items: center; gap: 13px; }

.brand-mark {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #fff;
  font-weight: 800;
  letter-spacing: -.04em;
  background: linear-gradient(135deg, #111827, #2563eb);
  box-shadow: var(--shadow);
}

.brand h1 {
  margin: 0;
  font-size: 1.05rem;
  letter-spacing: -.02em;
}

.brand p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: .82rem;
}

.icon-button {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  border-radius: 13px;
  cursor: pointer;
  font-size: 1.1rem;
  backdrop-filter: blur(14px);
}

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 34px 24px 64px;
}

.hero {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 28px;
  padding: 28px 0 36px;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 12px;
  color: var(--accent);
  font-weight: 800;
  letter-spacing: .12em;
  font-size: .72rem;
}

.hero h2 {
  margin: 0;
  max-width: 740px;
  font-size: clamp(2rem, 5vw, 4.2rem);
  line-height: 1.02;
  letter-spacing: -.055em;
}

.hero p {
  margin: 18px 0 0;
  max-width: 640px;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.7;
}

.status-card {
  min-width: 230px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 18px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.status-card strong, .status-card small { display: block; }
.status-card small { color: var(--muted); margin-top: 4px; }

.status-dot {
  width: 11px;
  height: 11px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 7px rgba(34,197,94,.12);
}

.search-section {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 10px 0 26px;
  flex-wrap: wrap;
}

.search-box {
  min-width: min(100%, 330px);
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: var(--surface);
  backdrop-filter: blur(14px);
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  padding: 14px 0;
  background: transparent;
  color: var(--text);
  font: inherit;
}

.filters { display: flex; gap: 8px; flex-wrap: wrap; }

.filter-button {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  padding: 10px 13px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 650;
}

.filter-button.active {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: transparent;
}

.section-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 16px;
}

.section-heading h3 { margin: 0; font-size: 1.05rem; }
.section-heading span { color: var(--muted); font-size: .9rem; }

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

.app-card {
  display: flex;
  flex-direction: column;
  min-height: 210px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: 0 10px 34px rgba(15,23,42,.06);
  backdrop-filter: blur(16px);
  text-decoration: none;
  color: inherit;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.app-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: rgba(37,99,235,.22);
}

.app-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 1.45rem;
  font-weight: 800;
}

.app-card h4 {
  margin: 20px 0 8px;
  font-size: 1.05rem;
  letter-spacing: -.02em;
}

.app-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  font-size: .9rem;
}

.app-card .meta {
  margin-top: auto;
  padding-top: 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--muted);
  font-size: .8rem;
}

.badge {
  padding: 6px 9px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 750;
}

.empty-state {
  padding: 40px 20px;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: 18px;
}

footer {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px 36px;
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: .8rem;
}

@media (max-width: 850px) {
  .hero { grid-template-columns: 1fr; align-items: start; }
  .status-card { width: fit-content; }
  .apps-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 580px) {
  .topbar { padding-top: 18px; }
  .container { padding-top: 18px; }
  .hero { padding-top: 14px; }
  .apps-grid { grid-template-columns: 1fr; }
  .app-card { min-height: 180px; }
  footer { flex-direction: column; gap: 8px; }
}
