﻿/* ===== StateWeb overlays ====================================
   dc.css (Datacenter design system) provides :root vars, dark
   theme, dashboard classes. This file holds the StateWeb-specific
   shell: bottom nav, tile menu, layer-themed topbar, login.
   ============================================================ */

/* ----- Bottom nav (Home / Analysis / Voter / Booth) ----- */
.bottombar { position: fixed; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-around; align-items: center; padding: 6px 4px; background: linear-gradient(180deg, rgba(13,17,23,0.95), rgba(13,17,23,1)); border-top: 1px solid rgba(255,255,255,.06); z-index: 40; }
.bottombar a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 10px; font-family: var(--mono, monospace); font-size: 11px; color: #94a3b8; text-decoration: none; border-radius: 8px; min-width: 64px; }
.bottombar a .bb-ico { font-size: 18px; line-height: 1 }
.bottombar a .bb-lbl { font-weight: 600; letter-spacing: .04em }
.bottombar a.active { background: linear-gradient(135deg, #ef4444, #f97316); color: #fff; }
.bottombar a:hover { color: #e2e8f0 }
.main { padding-bottom: 64px }

/* ----- Tile menu grid ----- */
.tile-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; padding: 8px 0 }
.tile { background: var(--bg2, #0e1117); border: 1px solid var(--border, rgba(255,255,255,.06)); border-radius: 12px; padding: 18px 12px; text-align: center; text-decoration: none; color: var(--text, #e2e8f0); transition: all .15s; display: block }
.tile:hover { border-color: rgba(34,227,195,.35); transform: translateY(-1px); box-shadow: 0 6px 18px rgba(0,0,0,.4) }
.tile img { width: 56px; height: 56px; object-fit: contain; display: block; margin: 0 auto 6px }
.tile h5 { margin: 4px 0 0; font-size: 13px; font-weight: 700; font-family: var(--mono, monospace) }
.tile.pdag-tile .pdag-letter { font-family: var(--mono, monospace); font-size: 44px; font-weight: 900; line-height: 1; display: block; margin-bottom: 6px }
.tile.pdag-p .pdag-letter { color: #f59e0b }
.tile.pdag-d .pdag-letter { color: #3b82f6 }
.tile.pdag-a .pdag-letter { color: #22c55e }
.tile.pdag-g .pdag-letter { color: #a855f7 }

/* ----- Topbar (Datacenter state yellow brand) ----- */
.topbar { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; color: #fff; background: linear-gradient(135deg, #0d1117 0%, #161b22 100%); border-bottom: 1px solid rgba(255,255,255,.06); box-shadow: 0 2px 12px rgba(0,0,0,.35); position: sticky; top: 0; z-index: 50 }
.topbar .brand { font-family: var(--mono, monospace); font-weight: 800; font-size: 22px; letter-spacing: .06em; text-transform: uppercase; color: #fde047; text-shadow: 0 0 16px rgba(253,224,71,.35) }
.topbar a, .topbar span { color: #fff }
.topbar a { text-decoration: none }
.topbar .logout-btn { display: inline-block; padding: 7px 16px; background: rgba(255,255,255,.06); color: #fff; border: 1px solid rgba(255,255,255,.18); border-radius: 8px; font-size: 13px; font-weight: 600; text-decoration: none; transition: all .15s; cursor: pointer }
.topbar .logout-btn:hover { background: rgba(239,68,68,.85); border-color: rgba(239,68,68,.95); transform: translateY(-1px) }
@media (max-width: 480px) { .topbar { padding: 10px 12px } .topbar .brand { font-size: 16px; letter-spacing: .04em } .topbar .logout-btn { padding: 5px 12px; font-size: 12px } }

/* ----- Login page ----- */
.login-body { background: linear-gradient(135deg, #1a1100 0%, #2a1f00 50%, #0d1117 100%) fixed; min-height: 100vh; color: #fff }
.login-body .main { padding: 24px 18px; max-width: 460px; margin: 0 auto; padding-top: 5vh }
.login-body img { box-shadow: 0 10px 30px rgba(0,0,0,.45), 0 0 0 1px rgba(255,255,255,.06); display: block; width: 100%; max-width: 480px; margin: 0 auto 18px; border-radius: 12px }
.login-body .card { background: rgba(22,27,34,.85); backdrop-filter: blur(10px); border: 1px solid rgba(255,255,255,.08); border-radius: 16px; padding: 28px 24px; box-shadow: 0 20px 50px rgba(0,0,0,.4); color: #fff }
.login-body .card h2 { font-family: var(--mono, monospace); font-size: 32px; font-weight: 800; margin: 0 0 6px; letter-spacing: .04em; text-transform: uppercase; background: linear-gradient(90deg, #fde047, #f59e0b); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent }
.login-body .card .subtitle { font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: #94a3b8; margin-bottom: 24px; font-weight: 600 }
.login-body .form-row { margin-bottom: 16px }
.login-body .form-row label { display: block; font-weight: 600; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: #94a3b8; margin-bottom: 6px }
.login-body .form-row input[type="text"], .login-body .form-row input[type="password"] { width: 100%; box-sizing: border-box; padding: 12px 14px; background: rgba(13,17,23,.6); border: 1px solid rgba(255,255,255,.12); border-radius: 10px; color: #fff; font-size: 15px; font-family: inherit; transition: all .15s }
.login-body .form-row input[type="text"]:focus, .login-body .form-row input[type="password"]:focus { outline: none; border-color: #fde047; box-shadow: 0 0 0 3px rgba(253,224,71,.18); background: rgba(13,17,23,.85) }
.login-body .btn { display: block; width: auto; min-width: 180px; max-width: 280px; margin: 4px auto 0; padding: 13px 32px; background: linear-gradient(135deg, #fde047, #f59e0b); color: #0d1117; border: none; border-radius: 10px; font-weight: 800; font-size: 15px; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; text-align: center; cursor: pointer; transition: all .15s; box-shadow: 0 6px 20px rgba(253,224,71,.28) }
.login-body .btn:hover { transform: translateY(-1px); box-shadow: 0 10px 28px rgba(253,224,71,.45) }
.login-body .err { display: block; margin-top: 14px; padding: 10px 14px; background: rgba(239,68,68,.12); border: 1px solid rgba(239,68,68,.3); border-radius: 8px; color: #fca5a5; font-size: 13px }
@media (max-width: 480px) { .login-body .card h2 { font-size: 26px } .login-body .main { padding-top: 2vh } }
