/* Play Hub — portal + login styles. Kid-friendly, big tap targets. */
:root {
  --brand: #2C3A43;
  --brand-2: #517485;
  --accent: #E84E0F;
  --gold: #FFD700;
  --green: #2E9E4F;
  --card: #ffffff;
  --ink: #1e2b33;
  --radius: 18px;
  --shadow: 0 6px 18px rgba(44, 58, 67, 0.14);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; margin: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--ink);
  min-height: 100%;
}
.grad-bg {
  background: linear-gradient(160deg, #dbe9f0 0%, #eaf2f6 45%, #f4e9dd 100%);
}
a { color: inherit; text-decoration: none; }

/* ---------- shared buttons ---------- */
.btn {
  min-height: 54px; padding: 12px 20px; border: none; border-radius: 14px;
  background: var(--brand-2); color: #fff; font: inherit; font-weight: 700; font-size: 16px;
  cursor: pointer; box-shadow: var(--shadow); display: inline-flex; align-items: center;
  justify-content: center; gap: 8px;
}
.btn:active { transform: scale(0.98); }
.btn-block { width: 100%; }
.btn-small { min-height: 42px; padding: 8px 14px; font-size: 14px; }
.btn-ghost { background: transparent; color: var(--brand-2); box-shadow: none; border: 1px solid var(--brand-2); }
.btn-outline { background: #fff; color: var(--brand); border: 1px solid var(--brand-2); }

/* ---------- login ---------- */
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 16px; }
.login-card {
  width: 100%; max-width: 380px; background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 28px 24px; text-align: center;
}
.login-mascot { font-size: 72px; line-height: 1; animation: bob 2.4s ease-in-out infinite; }
.login-title { font-size: 30px; font-weight: 800; color: var(--brand); margin: 8px 0 2px; }
.login-sub { color: var(--brand-2); margin: 0 0 20px; }
.field { display: block; text-align: left; margin: 12px 0; }
.field span { display: block; font-weight: 700; color: var(--brand); font-size: 14px; margin-bottom: 6px; }
.field input {
  width: 100%; min-height: 52px; padding: 12px 14px; font-size: 17px; border: 2px solid var(--brand-2);
  border-radius: 12px; margin: 0; background: #fff;
}
.login-error { color: var(--accent); font-weight: 700; margin: 10px 0; }
.login-hint { color: var(--brand-2); opacity: .7; font-size: 13px; margin-top: 14px; }

/* ---------- portal ---------- */
.portal-topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 14px 18px; background: rgba(255,255,255,.7); backdrop-filter: blur(6px);
  border-bottom: 1px solid #dde6ec; position: sticky; top: 0; z-index: 10;
}
.portal-brand { font-weight: 800; font-size: 20px; color: var(--brand); }
.portal-user { display: flex; align-items: center; gap: 12px; }
.who { font-weight: 700; color: var(--brand-2); }
.portal-main { max-width: 900px; margin: 0 auto; padding: 24px 18px 40px; }
.portal-hello { font-size: clamp(28px, 6vw, 40px); font-weight: 800; color: var(--brand); margin: 10px 0 4px; }
.portal-sub { color: var(--brand-2); margin: 0 0 22px; font-size: 17px; }

.game-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.game-card {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 26px 16px; text-align: center; min-height: 150px;
  transition: transform .12s ease; border-bottom: 4px solid var(--brand-2);
}
.game-card:active { transform: scale(0.97); }
.game-emoji { font-size: 56px; line-height: 1; }
.game-title { font-weight: 800; font-size: 19px; color: var(--brand); }
.game-desc { font-size: 13px; color: var(--brand-2); opacity: .85; }
.game-card--soon { border-bottom-color: #cbd6dd; opacity: .7; }

.admin-panel {
  margin-top: 28px; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 20px; border-top: 4px solid var(--gold);
}
.admin-panel h2 { margin: 0 0 14px; color: var(--brand); }
.admin-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.admin-note { color: var(--brand-2); opacity: .8; margin-top: 14px; font-size: 13px; }

@keyframes bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

@media (min-width: 600px) {
  .game-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; }
}
