/* ============================================================
   GAOS™ SHARED BASE — Minimal shared foundation only
   Each module imports this + its own module-specific styles
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Space+Grotesk:wght@400;500;600;700&display=swap');

/* CSS Token System */
:root {
  --font-main: 'Outfit', sans-serif;
  --font-mono: 'Space Grotesk', sans-serif;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 24px;
  --transition: 0.3s ease;
}

/* Light base */
body.light {
  --bg: #F8F9FA;
  --surface: #FFFFFF;
  --surface2: #F1F3F5;
  --border: #DEE2E6;
  --text: #212529;
  --text2: #6C757D;
  --text3: #ADB5BD;
}

/* Dark base */
body.dark {
  --bg: #0D1117;
  --surface: #161B22;
  --surface2: #21262D;
  --border: #30363D;
  --text: #E6EDF3;
  --text2: #8B949E;
  --text3: #484F58;
}

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

body {
  font-family: var(--font-main);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  transition: background var(--transition), color var(--transition);
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

/* ── Auth overlay (shared across all modules) ── */
.auth-screen {
  position: fixed; inset: 0;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  z-index: 9999; padding: 20px;
}

.auth-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  width: 100%; max-width: 460px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0,0,0,0.12);
}

.auth-box-header {
  padding: 28px 30px 20px;
  border-bottom: 1px solid var(--border);
}

.auth-box-body { padding: 28px 30px; }

.btn-sso {
  width: 100%;
  padding: 13px;
  border-radius: var(--radius-md);
  border: 2px solid;
  font-family: var(--font-main);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  transition: all var(--transition);
}

.divider {
  display: flex; align-items: center; gap: 14px;
  margin: 18px 0; color: var(--text3); font-size: 0.82rem;
}
.divider::before, .divider::after {
  content: ''; flex: 1; height: 1px; background: var(--border);
}

/* ── Shared form controls ── */
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-weight: 600; font-size: 0.88rem; margin-bottom: 6px; color: var(--text); }
.form-control {
  width: 100%; padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-family: var(--font-main);
  font-size: 0.92rem;
  transition: border-color var(--transition);
}
.form-control:focus { outline: none; border-color: var(--accent); }
.form-select {
  width: 100%; padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-family: var(--font-main);
  font-size: 0.92rem;
  cursor: pointer;
}

/* ── Shared utility classes ── */
.text-xs { font-size: 0.75rem; }
.text-sm { font-size: 0.875rem; }
.text-muted { color: var(--text2) !important; }
.fw-bold { font-weight: 700; }
.fw-semibold { font-weight: 600; }

.badge-pill {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 10px; border-radius: 100px;
  font-size: 0.75rem; font-weight: 600;
}

/* Animations */
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }
@keyframes spin { to { transform: rotate(360deg); } }

.animate-in { animation: fadeIn 0.4s ease forwards; }
.spinning { animation: spin 1s linear infinite; display: inline-block; }

/* ── Global API Highway Logger Drawer ── */
.gaos-data-bus-btn {
  position: fixed; bottom: 20px; right: 20px; z-index: 10000;
  width: 52px; height: 52px; border-radius: 50%;
  background: #111827; border: 2px solid #10B981; color: #10B981;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; cursor: pointer; box-shadow: 0 8px 24px rgba(16, 185, 129, 0.3);
  transition: all 0.3s ease;
}
.gaos-data-bus-btn:hover {
  transform: scale(1.1); background: #10B981; color: #111827;
  box-shadow: 0 12px 30px rgba(16, 185, 129, 0.5);
}
.gaos-data-bus-btn.pulse-active {
  animation: busPulse 0.5s ease;
}
@keyframes busPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.2); box-shadow: 0 0 0 10px rgba(16, 185, 129, 0.4); }
  100% { transform: scale(1); }
}
.gaos-data-bus-drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: 420px;
  background: #0B0F19; border-left: 1px solid #1F2937;
  box-shadow: -10px 0 30px rgba(0,0,0,0.5); z-index: 10001;
  transform: translateX(100%); transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex; flex-direction: column; color: #E5E7EB;
  font-family: var(--font-mono);
}
.gaos-data-bus-drawer.open {
  transform: translateX(0);
}
.gaos-data-bus-header {
  padding: 16px 20px; border-bottom: 1px solid #1F2937;
  display: flex; align-items: center; justify-content: space-between;
  background: #111827;
}
.gaos-data-bus-body {
  flex: 1; overflow-y: auto; padding: 16px 20px;
  display: flex; flex-direction: column; gap: 12px;
}
.gaos-payload-card {
  background: #161B22; border: 1.5px solid #30363D; border-radius: var(--radius-sm);
  padding: 12px 14px; font-size: 0.78rem; position: relative;
  animation: slideInLeft 0.3s ease;
}
@keyframes slideInLeft {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}
.gaos-payload-time {
  font-size: 0.65rem; color: #8B949E; margin-bottom: 6px;
  display: flex; justify-content: space-between;
}
.gaos-payload-pre {
  background: #0D1117; padding: 8px; border-radius: 4px;
  color: #52B788; overflow-x: auto; margin-top: 6px;
  border: 1px solid #21262D; font-family: monospace; font-size: 0.72rem;
}

/* ── Global Unified ID Passport Modal ── */
.passport-modal-overlay {
  position: fixed; inset: 0; z-index: 10002;
  background: rgba(11, 15, 25, 0.75); backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
  padding: 16px;
}
.passport-modal-overlay.show {
  opacity: 1; pointer-events: auto;
}
.passport-modal-card {
  background: #111827; border: 2.5px solid #BCA355; border-radius: var(--radius-lg);
  max-width: 580px; width: 100%; box-shadow: 0 24px 60px rgba(0,0,0,0.6);
  position: relative; overflow: hidden; color: #E5E7EB;
  animation: modalScaleUp 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}
@keyframes modalScaleUp {
  from { transform: scale(0.9) translateY(20px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}
.passport-modal-card::before {
  content: 'GAOS TRUST PASSPORT';
  position: absolute; top: 22px; right: -55px;
  transform: rotate(45deg); background: #BCA355;
  color: #111827; padding: 6px 60px; font-size: 0.65rem;
  font-weight: 800; letter-spacing: 1.5px; z-index: 5;
}
.passport-stamp-seal {
  position: absolute; bottom: 20px; right: 24px;
  width: 90px; height: 90px; border: 4px double #10B981;
  border-radius: 50%; color: #10B981; display: flex;
  flex-direction: column; align-items: center; justify-content: center;
  font-size: 0.7rem; font-weight: 800; text-transform: uppercase;
  transform: rotate(-15deg); opacity: 0.8; z-index: 5;
  background: rgba(17, 24, 39, 0.8);
}
.passport-land-node {
  fill: #30363D; stroke: #8B949E; stroke-width: 1.5px;
  cursor: pointer; transition: all 0.2s ease;
}
.passport-land-node:hover {
  fill: #10B981; stroke: #fff; filter: drop-shadow(0 0 6px #10B981);
}
.passport-land-node.active {
  fill: #BCA355; stroke: #fff;
}

