:root {
  --bg: #0f1115;
  --card: #1a1d24;
  --text: #f4f5f7;
  --muted: #9aa0ab;
  --accent: #4f7cff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 48px 16px;
}

header {
  text-align: center;
  margin-bottom: 40px;
}

header h1 {
  font-size: 2rem;
  margin: 0 0 8px;
}

header p {
  color: var(--muted);
  margin: 0;
}

#app-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  width: 100%;
  max-width: 960px;
}

.app-card {
  background: var(--card);
  border: 1px solid #2a2e37;
  border-radius: 16px;
  padding: 24px;
  text-align: left;
  color: var(--text);
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.app-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
}

.app-card h2 {
  margin: 0 0 8px;
  font-size: 1.15rem;
}

.app-card p {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 0.9rem;
}

.app-cta {
  color: var(--accent);
  font-weight: 600;
  font-size: 0.9rem;
}

.offline-banner {
  margin-top: 16px;
  padding: 8px 16px;
  background: #3a2e12;
  color: #f4c969;
  border-radius: 8px;
  font-size: 0.85rem;
  display: inline-block;
}

.detail-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 10;
}

.detail-card {
  position: relative;
  background: var(--card);
  border: 1px solid #2a2e37;
  border-radius: 16px;
  padding: 32px 28px;
  max-width: 440px;
  width: 100%;
  color: var(--text);
}

.detail-close {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.detail-close:hover {
  color: var(--text);
}

.detail-card h2 {
  margin: 0 0 8px;
  font-size: 1.3rem;
}

.detail-card p {
  color: var(--muted);
  margin: 0 0 16px;
}

.detail-card ul {
  margin: 0 0 24px;
  padding-left: 20px;
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.6;
}

.app-cta-button {
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
}

.app-cta-button:hover {
  opacity: 0.9;
}
