/* Tycoon Empire - main.css */
:root {
  --bg: #0f1115;
  --card: #171a21;
  --accent: #3b82f6;
  --text: #e5e7eb;
  --muted: #9ca3af;
  --success: #10b981;
  --danger: #ef4444;
  --warning: #f59e0b;
}
* { box-sizing: border-box; margin:0; padding:0; font-family: Inter, system-ui, sans-serif; }
body { background: var(--bg); color: var(--text); min-height: 100vh; }
.view { display: none; min-height: 100vh; }
.view.active { display: block; }
.auth-card { max-width: 360px; margin: 10vh auto; background: var(--card); padding: 2rem; border-radius: 16px; box-shadow: 0 10px 30px rgba(0,0,0,.4); }
.auth-card h1 { text-align:center; margin-bottom:1.5rem; color: var(--accent); }
.tabs { display:flex; gap:.5rem; margin-bottom:1rem; }
.tab { flex:1; padding:.6rem; background:#1f2937; border:none; color:var(--muted); border-radius:8px; cursor:pointer; }
.tab.active { background:var(--accent); color:white; }
.auth-form { display:flex; flex-direction:column; gap:.8rem; }
.auth-form.hidden { display:none; }
input, button, select { padding:.7rem .9rem; border-radius:10px; border:1px solid #2a3240; background:#0f141b; color:var(--text); }
button { background:var(--accent); border:none; cursor:pointer; font-weight:600; transition:.2s; }
button:hover { opacity:.9; }
button:disabled { opacity:.5; cursor:not-allowed; }

.header { display:flex; justify-content:space-between; align-items:center; padding:.8rem 1rem; background:var(--card); border-bottom:1px solid #222; position:sticky; top:0; z-index:10; }
.brand { font-weight:800; font-size:1.2rem; color:var(--accent); }
.header-actions { display:flex; gap:.6rem; align-items:center; }
.notif-bell { position:relative; cursor:pointer; padding:.4rem .6rem; background:#1f2937; border-radius:8px; }
.badge { position:absolute; top:-6px; right:-6px; background:var(--danger); color:white; font-size:.7rem; padding:2px 6px; border-radius:10px; min-width:18px; text-align:center; }
.badge.hidden { display:none; }

.stats-bar { display:flex; gap:1.5rem; padding:.7rem 1rem; background:#11151c; border-bottom:1px solid #1f2937; flex-wrap:wrap; }
.nav { display:flex; gap:.5rem; padding:.6rem; background:var(--card); overflow-x:auto; }
.nav-btn { background:#1f2937; white-space:nowrap; }
.nav-btn.active { background:var(--accent); }

#main-content { padding:1rem; max-width:1200px; margin:0 auto; }
.grid { display:grid; gap:1rem; grid-template-columns:repeat(auto-fit, minmax(280px,1fr)); }
.card { background:var(--card); border:1px solid #222831; border-radius:14px; padding:1rem; }
.card h3 { margin-bottom:.6rem; color:var(--accent); }
.list { display:flex; flex-direction:column; gap:.5rem; }
.list-item { display:flex; justify-content:space-between; align-items:center; padding:.6rem; background:#0f141b; border-radius:10px; }
.actions { display:flex; gap:.5rem; flex-wrap:wrap; margin-top:.8rem; }

#toast-container { position:fixed; bottom:1rem; right:1rem; display:flex; flex-direction:column; gap:.5rem; z-index:1000; }
.toast { background:#1f2937; padding:.8rem 1rem; border-radius:10px; border-left:4px solid var(--accent); min-width:260px; box-shadow:0 4px 12px rgba(0,0,0,.3); animation:slideIn .3s; }
.toast.success { border-color:var(--success); }
.toast.error { border-color:var(--danger); }
@keyframes slideIn { from { transform:translateX(100%); opacity:0 } to { transform:translateX(0); opacity:1 } }

.modal { position:fixed; inset:0; background:rgba(0,0,0,.7); display:flex; align-items:center; justify-content:center; z-index:900; }
.modal.hidden { display:none; }
.modal-content { background:var(--card); padding:1.5rem; border-radius:14px; width:90%; max-width:420px; }
.modal-actions { display:flex; justify-content:flex-end; gap:.5rem; margin-top:1rem; }

.notif-panel { position:fixed; top:56px; right:1rem; width:340px; max-height:70vh; overflow:auto; background:var(--card); border:1px solid #222; border-radius:12px; z-index:800; padding:.5rem; }
.notif-panel.hidden { display:none; }
.notif-item { padding:.7rem; border-bottom:1px solid #222; cursor:pointer; }
.notif-item.unread { background:#1a2230; }
.notif-item small { color:var(--muted); }

.chat-box { height:400px; overflow:auto; background:#0f141b; padding:.8rem; border-radius:10px; margin-bottom:.5rem; }
.msg { margin-bottom:.6rem; }
.msg.me { text-align:right; }
.msg-bubble { display:inline-block; padding:.5rem .8rem; background:#1f2937; border-radius:10px; max-width:70%; }
.msg.me .msg-bubble { background:var(--accent); }

@media (max-width:768px) {
  .stats-bar { gap:.8rem; font-size:.9rem; }
  .grid { grid-template-columns:1fr; }
}
