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

:root {
  --bg: #f5f4f0;
  --surface: #ffffff;
  --surface-hover: #f0efe9;
  --border: rgba(0,0,0,0.07);
  --border-strong: rgba(0,0,0,0.12);
  --text-1: #0f0f0d;
  --text-2: #5c5a54;
  --radius: 14px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111110;
    --surface: #1c1c1a;
    --surface-hover: #242422;
    --border: rgba(255,255,255,0.06);
    --border-strong: rgba(255,255,255,0.11);
    --text-1: #f0efe9;
    --text-2: #7a7870;
  }
}

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg);
  color: var(--text-1);
  min-height: 100dvh;
  padding-top: env(safe-area-inset-top, 0);
  padding-bottom: env(safe-area-inset-bottom, 0);
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: 540px;
  margin: 0 auto;
  padding: 40px 20px 64px;
}

.hero {
  border-radius: 18px;
  overflow: hidden;
  margin-bottom: 36px;
}

.hero img {
  width: 100%;
  display: block;
}

.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.item {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  padding: 13px 14px;
  text-decoration: none;
  color: var(--text-1);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: background 0.12s ease, border-color 0.12s ease, transform 0.1s ease;
  -webkit-tap-highlight-color: transparent;
}

.item:active {
  background: var(--surface-hover);
  transform: scale(0.97);
}

@media (hover: hover) {
  .item:hover {
    background: var(--surface-hover);
    border-color: var(--border-strong);
  }
}

.icon {
  font-size: 22px;
  flex-shrink: 0;
  line-height: 1;
}

.name {
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.empty {
  grid-column: 1 / -1;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-2);
  font-size: 13px;
  text-align: center;
}
