/* Abdullahi Osman — Interactive Systems, DevOps & Security World */
:root {
    --bg: #060911;
    --bg-elev: #0c1220;
    --bg-card: rgba(13, 20, 34, 0.88);
    --bg-card-solid: #0d1422;
    --border: rgba(148, 163, 184, 0.16);
    --border-strong: rgba(245, 158, 11, 0.42);
    --text: #f1f5f9;
    --text-muted: #94a3b8;
    --accent: #f59e0b;
    --accent-glow: rgba(245, 158, 11, 0.22);
    --emerald: #10b981;
    --emerald-soft: rgba(16, 185, 129, 0.16);
    --sky: #38bdf8;
    --sky-soft: rgba(56, 189, 248, 0.16);
    --rose: #fb7185;
    --rose-soft: rgba(251, 113, 133, 0.16);
    --nav-bg: rgba(6, 9, 17, 0.86);
    --grid-line: rgba(148, 163, 184, 0.06);
    --term-bg: #070b14;
    --shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
}

html.light {
    --bg: #f3f6fb;
    --bg-elev: #ffffff;
    --bg-card: rgba(255, 255, 255, 0.94);
    --bg-card-solid: #ffffff;
    --border: rgba(15, 23, 42, 0.11);
    --border-strong: rgba(217, 119, 6, 0.45);
    --text: #0f172a;
    --text-muted: #475569;
    --accent: #d97706;
    --accent-glow: rgba(217, 119, 6, 0.14);
    --emerald: #059669;
    --emerald-soft: rgba(5, 150, 105, 0.12);
    --sky: #0284c7;
    --sky-soft: rgba(2, 132, 199, 0.12);
    --rose: #e11d48;
    --rose-soft: rgba(225, 29, 72, 0.12);
    --nav-bg: rgba(243, 246, 251, 0.9);
    --grid-line: rgba(15, 23, 42, 0.055);
    --term-bg: #0b1120;
    --shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

*, *::before, *::after {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    max-width: 100%;
    overflow-x: clip;
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
}

.font-mono {
    font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

.tech-backdrop {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
    background-image:
        linear-gradient(to right, var(--grid-line) 1px, transparent 1px),
        linear-gradient(to bottom, var(--grid-line) 1px, transparent 1px);
    background-size: 40px 40px;
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 18px;
}

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 40;
    background: var(--nav-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
}

.nav-row {
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 0.96rem;
    letter-spacing: -0.02em;
    flex-shrink: 0;
}

.brand-logo {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: block;
    flex-shrink: 0;
}

.nav-links {
    display: none;
    align-items: center;
    gap: 20px;
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--text-muted);
}

.nav-links a:hover {
    color: var(--text);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.theme-btn, .menu-btn {
    height: 36px;
    min-width: 36px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text);
    font-size: 0.76rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.theme-btn:hover, .menu-btn:hover {
    border-color: var(--accent);
}

.menu-btn {
    padding: 0;
    width: 36px;
}

.mobile-menu {
    display: none;
    border-top: 1px solid var(--border);
    padding: 14px 18px 18px;
    background: var(--bg-elev);
}

.mobile-menu.open {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.mobile-menu a {
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: var(--bg-card-solid);
    font-size: 0.8rem;
    font-weight: 600;
    text-align: center;
}

/* Hero + Live Pixel Skyline Canvas */
.hero {
    padding: 36px 0 48px;
    border-bottom: 1px solid var(--border);
}

.hero-stage {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.24);
    background: #070c18;
    box-shadow: var(--shadow);
    margin-bottom: 28px;
}

.skyline-canvas {
    display: block;
    width: 100%;
    height: 220px;
    cursor: crosshair;
    image-rendering: pixelated;
}

.stage-hud {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    pointer-events: none;
}

.hud-chip {
    font-size: 0.68rem;
    font-weight: 700;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(6, 9, 17, 0.78);
    border: 1px solid rgba(56, 189, 248, 0.35);
    color: #e2e8f0;
    backdrop-filter: blur(8px);
}

.hud-chip-live {
    border-color: rgba(16, 185, 129, 0.5);
    color: #34d399;
}

.hud-hint {
    display: none;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
    align-items: start;
}

.hero-copy {
    min-width: 0;
}

.availability-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 999px;
    background: var(--emerald-soft);
    border: 1px solid rgba(16, 185, 129, 0.38);
    color: var(--emerald);
    font-size: 0.74rem;
    font-weight: 700;
    margin-bottom: 14px;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--emerald);
    flex-shrink: 0;
}

.role-kicker {
    font-size: 0.76rem;
    font-weight: 700;
    color: var(--sky);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.hero h1 {
    font-size: clamp(1.9rem, 4.4vw, 3rem);
    line-height: 1.09;
    letter-spacing: -0.03em;
    margin: 0 0 14px;
}

.gradient-text {
    background: linear-gradient(95deg, #f59e0b 0%, #34d399 52%, #38bdf8 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-lead {
    font-size: 0.96rem;
    color: var(--text-muted);
    margin: 0 0 22px;
    max-width: 580px;
}

.hero-cta {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    margin-bottom: 18px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 18px;
    border-radius: 12px;
    font-size: 0.84rem;
    font-weight: 700;
    border: 1px solid transparent;
    cursor: pointer;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, #f59e0b, #ea580c);
    color: #060911;
    box-shadow: 0 10px 26px var(--accent-glow);
}

.btn-secondary {
    background: var(--bg-card);
    border-color: var(--border);
    color: var(--text);
}

.btn-secondary:hover {
    border-color: var(--accent);
}

.btn-sm {
    padding: 9px 14px;
    font-size: 0.78rem;
    border-radius: 10px;
}

.quick-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 0.76rem;
    color: var(--text-muted);
}

.quick-meta strong {
    color: var(--text);
}

/* Interactive Terminal */
.terminal-card {
    background: var(--term-bg);
    color: #e2e8f0;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow);
    min-width: 0;
}

.term-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.04);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.term-dots {
    display: flex;
    align-items: center;
    gap: 6px;
}

.dot { width: 10px; height: 10px; border-radius: 999px; }
.dot-red { background: #ef4444; }
.dot-amber { background: #f59e0b; }
.dot-green { background: #10b981; }

.term-title {
    font-size: 0.72rem;
    color: #94a3b8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.term-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    padding: 10px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.term-tab {
    padding: 6px 8px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: transparent;
    color: #94a3b8;
    font-size: 0.72rem;
    font-weight: 700;
    cursor: pointer;
}

.term-tab.active, .term-tab:hover {
    background: rgba(16, 185, 129, 0.16);
    border-color: rgba(16, 185, 129, 0.5);
    color: #34d399;
}

.term-body {
    padding: 14px 16px;
    min-height: 220px;
    font-size: 0.76rem;
    line-height: 1.68;
    overflow-x: auto;
}

.term-line { margin: 0 0 6px; word-break: break-word; }
.t-prompt { color: #10b981; font-weight: 700; }
.t-cmd { color: #f8fafc; font-weight: 600; }
.t-muted { color: #94a3b8; }
.t-amber { color: #fbbf24; }
.t-sky { color: #38bdf8; }
.t-ok { color: #34d399; font-weight: 700; }
.t-rose { color: #fb7185; font-weight: 700; }

.cursor-blink {
    display: inline-block;
    width: 8px;
    height: 14px;
    vertical-align: -2px;
    background: #10b981;
    margin-left: 4px;
}

/* Sections */
.section {
    padding: 52px 0;
    border-bottom: 1px solid var(--border);
    scroll-margin-top: 72px;
}

.section-eyebrow {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 8px;
}

.section-title {
    font-size: clamp(1.45rem, 3.2vw, 2.1rem);
    letter-spacing: -0.025em;
    margin: 0 0 10px;
}

.section-sub {
    color: var(--text-muted);
    font-size: 0.94rem;
    max-width: 680px;
    margin: 0 0 26px;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 20px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
    min-width: 0;
}

/* Interactive Solar System Project Explorer */
.solar-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    align-items: stretch;
}

.solar-stage {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    background: #070b15;
    border: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
}

.orbit-canvas {
    display: block;
    width: 100%;
    height: 320px;
    cursor: pointer;
}

.planet-bar {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.03);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.planet-btn {
    padding: 8px 6px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.03);
    color: #cbd5e1;
    font-size: 0.72rem;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
}

.planet-btn.active {
    background: rgba(245, 158, 11, 0.18);
    border-color: #f59e0b;
    color: #fbbf24;
}

.inspector-card {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.arch-preview {
    border-radius: 12px;
    padding: 12px;
    background: var(--term-bg);
    border: 1px solid rgba(148, 163, 184, 0.2);
    color: #e2e8f0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.arch-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.68rem;
    color: #94a3b8;
}

.arch-flow {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    font-size: 0.68rem;
    font-weight: 700;
}

.arch-box {
    flex: 1;
    text-align: center;
    padding: 7px 6px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.arch-arrow {
    color: #f59e0b;
    font-weight: 800;
}

.project-list {
    margin: 0;
    padding-left: 18px;
    color: var(--text-muted);
    font-size: 0.86rem;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag {
    font-size: 0.72rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--bg-elev);
    border: 1px solid var(--border);
    color: var(--text);
}

.project-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: auto;
}

.project-actions.single {
    grid-template-columns: 1fr;
}

/* Playable DevOps / AppSec Boss Fight Arena */
.arena-shell {
    background: #070c17;
    color: #f1f5f9;
    border: 1px solid rgba(251, 113, 133, 0.35);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.arena-header {
    padding: 14px 18px;
    background: rgba(251, 113, 133, 0.08);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.arena-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 18px;
}

.boss-canvas-wrap {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.22);
    background: #050811;
}

.boss-canvas {
    display: block;
    width: 100%;
    height: 230px;
    image-rendering: pixelated;
}

.hp-bars {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 14px;
}

.hp-box {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 10px 12px;
}

.hp-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.72rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.hp-track {
    height: 9px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.1);
    overflow: hidden;
}

.hp-fill {
    height: 100%;
    border-radius: 999px;
    width: 100%;
}

.hp-prod { background: linear-gradient(90deg, #10b981, #34d399); }
.hp-boss { background: linear-gradient(90deg, #e11d48, #fb7185); }

.move-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 12px;
}

.move-btn {
    padding: 11px 10px;
    border-radius: 12px;
    border: 1px solid rgba(148, 163, 184, 0.24);
    background: rgba(255, 255, 255, 0.04);
    color: #f8fafc;
    text-align: left;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.move-btn:hover:not(:disabled) {
    border-color: #f59e0b;
    background: rgba(245, 158, 11, 0.12);
}

.move-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.move-name {
    font-size: 0.78rem;
    font-weight: 800;
}

.move-desc {
    font-size: 0.68rem;
    color: #94a3b8;
}

.battle-log {
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 10px 12px;
    min-height: 76px;
    font-size: 0.74rem;
    line-height: 1.55;
    color: #cbd5e1;
}

.battle-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 10px;
    flex-wrap: wrap;
}

/* Pipeline & Capabilities */
.pipeline-track {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.pipe-node {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 16px;
}

.pipe-node.active-step {
    border-color: var(--emerald);
    box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.25), 0 12px 26px rgba(16, 185, 129, 0.12);
}

.pipe-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}

.pipe-step { font-size: 0.7rem; font-weight: 800; color: var(--emerald); }
.pipe-status {
    font-size: 0.66rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 999px;
    background: var(--emerald-soft);
    color: var(--emerald);
}

.pipe-node h3, .card h3 { margin: 0 0 6px; font-size: 1rem; }
.pipe-node p, .card p { margin: 0; font-size: 0.84rem; color: var(--text-muted); }

.two-col-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

.pillar-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.badge-amber { background: var(--accent-glow); color: var(--accent); }
.badge-emerald { background: var(--emerald-soft); color: var(--emerald); }
.badge-sky { background: var(--sky-soft); color: var(--sky); }

/* CTA & Footer */
.cta-banner {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.14), rgba(16, 185, 129, 0.13));
    border: 1px solid var(--border-strong);
    border-radius: 24px;
    padding: 26px 22px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.cta-banner h2 {
    margin: 0 0 8px;
    font-size: clamp(1.35rem, 3vw, 1.85rem);
}

.cta-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.site-footer {
    padding: 32px 0 44px;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.footer-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    text-align: center;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
}

.footer-links a { font-weight: 600; color: var(--text); }
.footer-links a:hover { color: var(--accent); }

/* Reduced-Motion Safe Keyframes */
@keyframes pulseRing {
    0%, 100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.55); }
    60% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
}

@keyframes blinkCursor {
    0%, 49% { opacity: 1; }
    50%, 100% { opacity: 0; }
}

@media (prefers-reduced-motion: no-preference) {
    html { scroll-behavior: smooth; }
    .pulse-dot { animation: pulseRing 2.2s ease-out infinite; }
    .cursor-blink { animation: blinkCursor 1s steps(1) infinite; }
    .hp-fill { transition: width 0.35s ease; }
    .card, .btn, .theme-btn, .pipe-node, .move-btn, .planet-btn {
        transition: transform 0.2s ease, border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
    }
    .move-btn:hover:not(:disabled) { transform: translateY(-2px); }
}

@media (min-width: 640px) {
    .hero-cta, .cta-actions { display: flex; flex-wrap: wrap; }
    .skyline-canvas { height: 260px; }
    .hud-hint { display: inline-flex; }
    .two-col-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pipeline-track { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 960px) {
    .nav-links { display: flex; }
    .menu-btn, .mobile-menu.open { display: none; }
    .hero-grid { grid-template-columns: 1.1fr 0.9fr; gap: 32px; }
    .solar-layout { grid-template-columns: 1.05fr 0.95fr; }
    .arena-grid { grid-template-columns: 1fr 1.05fr; align-items: center; }
    .pipeline-track { grid-template-columns: repeat(5, minmax(0, 1fr)); }
    .cta-banner {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 32px 34px;
    }
    .footer-row { flex-direction: row; text-align: left; }
}
