/* ========================================
   JUNO UNIVERSE - GLOBAL STYLES (PURIFIED)
   This version is based on your original design, with critical fixes.
   ======================================== */

/* --- Base & Body --- */
body {
    background: #0a0a0a;
    color: #a0a0a0;
    font-family: 'Segoe UI', 'Roboto', sans-serif; /* A more standard font for body text */
}

.juno-body {
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(196, 30, 58, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(74, 158, 255, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(255, 165, 0, 0.05) 0%, transparent 50%);
}

/* --- Terminal Header --- */
.terminal-header {
    background: #1a1a1a;
    border-bottom: 1px solid #404040;
}

.terminal-bar {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    gap: 20px;
    max-width: 1400px;
    margin: 0 auto;
}

.terminal-controls { display: flex; gap: 8px; }
.control-btn { width: 12px; height: 12px; border-radius: 50%; }
.control-btn.close { background: #ff5f57; }
.control-btn.minimize { background: #ffbd2e; }
.control-btn.maximize { background: #28ca42; }

.terminal-title { flex: 1; text-align: center; font-family: 'Share Tech Mono', monospace; color: #808080; letter-spacing: 0.1em; }
.terminal-status { display: flex; align-items: center; gap: 8px; }
.status-text { font-size: 0.8rem; color: #00ff00; text-transform: uppercase; }
.status-ping { width: 8px; height: 8px; background: #00ff00; border-radius: 50%; animation: ping 2s infinite; }

@keyframes ping {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(0, 255, 0, 0.7); }
    50% { opacity: 0.5; box-shadow: 0 0 0 10px rgba(0, 255, 0, 0); }
}

/* --- Main Navigation (Globally Sticky) --- */
.main-nav {
    background: #1a1a1a;
    border-bottom: 2px solid #c41e3a;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container { max-width: 1400px; margin: 0 auto; display: flex; align-items: center; }
.nav-home { padding: 15px 20px; background: #c41e3a; color: white; text-decoration: none; display: flex; align-items: center; gap: 10px; transition: background 0.3s; }
.nav-home:hover { background: #e02040; }
.nav-separator { color: #404040; padding: 0 20px; }
.nav-links { display: flex; flex: 1; }
.nav-links a { padding: 15px 25px; color: #a0a0a0; text-decoration: none; text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.9rem; transition: all 0.3s; position: relative; }
.nav-links a::after { content: ''; position: absolute; bottom: 0; left: 0; width: 0; height: 2px; background: #c41e3a; transition: width 0.3s; }
.nav-links a:hover, .nav-links a.active { color: #ffffff; }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }

/* --- Homepage: Hero Section --- */
.hero-section { padding: 60px 40px; background: linear-gradient(180deg, rgba(196, 30, 58, 0.05) 0%, transparent 100%); }
.hero-grid { max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: auto 1fr; gap: 60px; align-items: center; }

/* ASCII Art Fix */
.ascii-art {
    color: #c41e3a;
    font-family: 'Courier New', Courier, monospace; /* CRITICAL FIX: Monospaced font */
    font-size: 0.8rem;
    line-height: 1;
    text-shadow: 0 0 20px rgba(196, 30, 58, 0.5);
}

.universe-title { font-family: 'Orbitron', sans-serif; font-size: 3rem; font-weight: 900; margin-bottom: 10px; letter-spacing: 0.1em; color: #ffffff; }
.universe-tagline { color: #808080; font-size: 1.2rem; margin-bottom: 30px; }
.universe-stats { display: flex; gap: 30px; }
.stat-item { display: flex; gap: 10px; }
.stat-key { color: #606060; }
.stat-val { color: #ffffff; font-weight: bold; }
.stat-val.active { color: #00ff00; }

/* --- Homepage: Dashboard & Systems Sections --- */
.dashboard, .systems-overview, .updates-terminal {
    padding: 40px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Scoped Section Title for Homepage */
.dashboard .section-title, .systems-overview .section-title, .updates-terminal .section-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5rem;
    color: #ffffff;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.title-marker { color: #c41e3a; animation: blink 2s infinite; }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0.3; } }

.dashboard-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(500px, 1fr)); gap: 30px; }
.city-card { background: #1a1a1a; border: 1px solid #404040; position: relative; overflow: hidden; }
.city-card::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 2px; background: linear-gradient(90deg, transparent, #c41e3a, transparent); animation: scan 3s linear infinite; }
@keyframes scan { 0% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }
.city-card[data-city="port-sterling"] { border-left: 3px solid #4a9eff; }
.city-card[data-city="redemption"] { border-left: 3px solid #ffa500; }
.card-header { display: flex; align-items: center; gap: 15px; padding: 20px; background: #2d2d2d; border-bottom: 1px solid #404040; }
.city-icon { font-size: 1.5rem; color: #c41e3a; }
.card-header h3 { flex: 1; margin: 0; font-family: 'Orbitron', sans-serif; font-size: 1.3rem; letter-spacing: 0.1em; color: #ffffff; }
.city-state { font-size: 0.8rem; color: #808080; background: #1a1a1a; padding: 3px 10px; border: 1px solid #404040; }
.card-body { padding: 20px; }
.city-desc { color: #a0a0a0; margin-bottom: 20px; line-height: 1.6; }
.city-stats { display: flex; gap: 15px; padding: 10px 0; margin-bottom: 20px; font-size: 0.9rem; color: #808080; }
.card-actions { display: flex; gap: 10px; }
.action-btn { flex: 1; padding: 10px 15px; background: #2d2d2d; border: 1px solid #404040; color: #a0a0a0; text-decoration: none; text-align: center; text-transform: uppercase; font-size: 0.8rem; letter-spacing: 0.1em; transition: all 0.3s; }
.action-btn:hover { background: #404040; color: #ffffff; transform: translateY(-2px); }
.action-btn.primary { background: rgba(196, 30, 58, 0.2); border-color: #c41e3a; color: #ffffff; }
.action-btn.primary:hover { background: #c41e3a; }

.systems-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; }
.system-node { background: #1a1a1a; border: 1px solid #404040; padding: 25px; text-align: center; transition: all 0.3s; position: relative; overflow: hidden; }
.system-node:hover { border-color: #c41e3a; transform: translateY(-3px); }
.node-icon { font-size: 2rem; margin-bottom: 15px; color: #ffffff; }
.system-node h4 { font-family: 'Orbitron', sans-serif; font-size: 0.9rem; margin-bottom: 10px; color: #ffffff; }
.system-node p { font-size: 0.85rem; color: #808080; margin-bottom: 15px; line-height: 1.4; }
.node-link { color: #c41e3a; text-decoration: none; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.1em; }

.terminal-window { background: #0a0a0a; border: 1px solid #404040; padding: 20px; font-family: 'Share Tech Mono', monospace; min-height: 200px; }
.log-entry { margin-bottom: 10px; display: flex; gap: 15px; }
.timestamp { color: #606060; font-size: 0.9rem; }
.log-text { color: #00ff00; font-size: 0.9rem; }
.terminal-cursor { display: inline-block; animation: cursor-blink 1s infinite; color: #00ff00; }
@keyframes cursor-blink { 0%, 50% { opacity: 1; } 51%, 100% { opacity: 0; } }

/* --- Footer --- */
.juno-footer { background: #1a1a1a; border-top: 1px solid #404040; margin-top: 80px; }
.footer-content { max-width: 1400px; margin: 0 auto; padding: 30px 40px; display: flex; justify-content: space-between; align-items: center; }
.footer-stats { display: flex; gap: 20px; color: #606060; font-size: 0.85rem; }
.footer-nav a { color: #c41e3a; text-decoration: none; font-size: 0.9rem; }

/* ========================================
   GLOBAL PAGE HEADER STYLES
   Used on all overview pages (World, Orgs, etc.)
   ======================================== */

.page-header {
    text-align: center;
    margin-bottom: 60px;
}

.page-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 3rem;
    color: #ffffff;
    display: flex; /* Ensures icon and text align nicely if an icon is used */
    align-items: center;
    justify-content: center; /* This is the key to centering the title */
    gap: 20px;
    margin: 0 0 10px 0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.page-subtitle {
    color: #808080;
    font-size: 1.1rem;
    letter-spacing: 0.1em;
    margin-top: 0;
}