:root {
  --bg: #0b1320;
  --bg-card: #121b2b;
  --border: #22304a;
  --gold: #eab308;
  --text: #e7ecf5;
  --text-dim: #93a1b8;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  background: radial-gradient(circle at top, #14203a, var(--bg) 60%);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.brand-title {
  text-align: center;
  margin-bottom: 32px;
}
.brand-title h1 {
  font-size: 2.2rem;
  margin: 0;
  letter-spacing: 0.02em;
}
.brand-title h1 span { color: var(--gold); }
.brand-title p { color: var(--text-dim); margin: 6px 0 0; }

/* Login */
#login-view { width: 100%; max-width: 380px; }
.login-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
}
.login-card label { display: block; font-size: 0.85rem; color: var(--text-dim); margin: 14px 0 6px; }
.login-card input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #0e1626;
  color: var(--text);
  font-size: 0.95rem;
}
.login-card button[type="submit"] {
  width: 100%;
  margin-top: 20px;
  padding: 11px;
  border: none;
  border-radius: 8px;
  background: var(--gold);
  color: #1a1300;
  font-weight: 600;
  cursor: pointer;
}
.login-card button[type="submit"]:hover { filter: brightness(1.08); }
#google-button { margin-top: 16px; display: flex; justify-content: center; }
.error-text { color: #f87171; font-size: 0.85rem; margin-top: 12px; }

/* Portal */
#portal-view { width: 100%; max-width: 960px; }
.portal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}
.portal-header button {
  background: none;
  border: 1px solid var(--border);
  color: var(--text-dim);
  border-radius: 8px;
  padding: 8px 14px;
  cursor: pointer;
}
.portal-header button:hover { color: var(--text); border-color: var(--gold); }

.tiles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}
.tile {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
  cursor: pointer;
  transition: transform 0.15s, border-color 0.15s;
}
.tile:hover { transform: translateY(-2px); border-color: var(--gold); }
.tile-disabled { opacity: 0.6; }
.tile h3 { margin: 12px 0 4px; font-size: 1.05rem; }
.tile p { margin: 0; color: var(--text-dim); font-size: 0.85rem; line-height: 1.4; }
.tile-badge {
  position: absolute; top: 12px; right: 12px;
  background: var(--gold); color: #1a1300;
  font-size: 0.65rem; font-weight: 700;
  padding: 2px 8px; border-radius: 999px;
}
.tile-soon {
  display: inline-block; margin-top: 10px;
  font-size: 0.7rem; color: var(--text-dim);
  border: 1px solid var(--border); border-radius: 999px;
  padding: 2px 8px;
}
.tile-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: rgba(234, 179, 8, 0.12);
  display: flex; align-items: center; justify-content: center;
  color: var(--gold);
  font-size: 1.3rem;
}
.tile-icon::before { content: '★'; }

#tile-status {
  margin-top: 18px;
  padding: 10px 14px;
  border-radius: 8px;
  background: #1c2740;
  color: var(--text-dim);
  font-size: 0.85rem;
}

[hidden] { display: none !important; }
