/* ROOT VARIABLES & RESET */
:root {
    --bg-dark: #0f1115;
    --bg-card: #161b22;
    --bg-card-hover: #1c2128;
    --text-main: #e6edf3;
    --text-muted: #8b949e;
    --accent-adb: #58a6ff;
    --accent-app: #3fb950;
    --border-color: #30363d;
    --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

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

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
}

/* BACKGROUND ACCENTS */
.page-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: -1;
    background:
        radial-gradient(circle at 15% 50%, rgba(88, 166, 255, 0.08) 0%, transparent 25%),
        radial-gradient(circle at 85% 30%, rgba(63, 185, 80, 0.08) 0%, transparent 25%);
}

.docs-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* NAVIGATION HEADER */
.page-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.back-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: none;
    border: none;
    color: var(--text-muted);
    font-family: var(--font-sans);
    font-weight: 500;
    cursor: pointer;
    transition: color 0.2s;
}

.back-btn:hover {
    color: var(--text-main);
}

.nav-breadcrumbs {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.crumb-current {
    color: var(--accent-adb);
    font-weight: 600;
}

.crumb-sep {
    margin: 0 0.5rem;
    opacity: 0.5;
}

/* HERO SECTION */
.hero-section {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 4rem;
    margin-bottom: 5rem;
    align-items: center;
}


.hero-content h1 {
    font-size: 4rem;
    line-height: 1.1;
    font-weight: 800;
    margin-bottom: 1.5rem;
    background: linear-gradient(to right, #ffffff, #a5b4fc);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-desc {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 600px;
    margin-bottom: 2rem;
}

.tech-stack-pills {
    display: flex;
    gap: 0.75rem;
}

.pill {
    padding: 0.35rem 0.85rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.03);
}

/* HERO VISUAL DIAGRAM */
.connection-diagram {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 2rem;
    gap: 1rem;
    position: relative;
}

.node {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    z-index: 2;
}

.node .icon {
    font-size: 2.5rem;
    background: var(--bg-card);
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.node .label {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 600;
}

.lines {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: relative;
}

.line {
    height: 2px;
    background: var(--border-color);
    position: relative;
    width: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.2rem;
    margin-top: 0.2rem;
}

.line span {
    position: absolute;
    background: var(--bg-dark);
    padding: 0 5px;
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: 700;
    font-family: var(--font-mono);

}

.line.adb-line {
    background: linear-gradient(90deg, transparent, var(--accent-adb), transparent);
}

.line.app-line {
    background: linear-gradient(90deg, transparent, var(--accent-app), transparent);
}

/* PROTOCOLS GRID */
.protocols-grid {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 2rem;
}

.protocol-track {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

/* Track Header Styling */
.track-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.track-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.adb-track .track-icon {
    color: var(--accent-adb);
    background: rgba(88, 166, 255, 0.1);
}

.app-track .track-icon {
    color: var(--accent-app);
    background: rgba(63, 185, 80, 0.1);
}

.track-info h2 {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
}

.track-info p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Cards */
.features-list {
    display: grid;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.feature-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid transparent;
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    gap: 1.25rem;
    transition: all 0.2s ease;
}

.feature-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-color);
}

.card-icon {
    font-size: 1.5rem;
}

.card-content h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: var(--text-main);
}

.card-content p {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.specs-list {
    list-style: none;
    font-size: 0.8rem;
    color: var(--text-muted);
    display: flex;
    gap: 1rem;
}

.specs-list li::before {
    content: "•";
    color: var(--accent-adb);
    margin-right: 0.5rem;
}

/* Tags */
.tag-row {
    display: flex;
    gap: 0.5rem;
}

.tag {
    font-size: 0.75rem;
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    font-weight: 500;
}

/* DEV TERMINAL */
.dev-terminal-wrapper {
    background: #0d1117;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    font-family: var(--font-mono);
    overflow: hidden;
    margin-top: 2rem;
}

.terminal-header {
    background: rgba(255, 255, 255, 0.03);
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #238636;
    box-shadow: 0 0 8px rgba(35, 134, 54, 0.4);
}

.term-title {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.terminal-body {
    padding: 1.25rem;
}

.comment {
    color: #6a737d;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
}

.code-line {
    background: rgba(88, 166, 255, 0.1);
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 1.5rem;
    display: flex;
    gap: 0.75rem;
    font-size: 0.95rem;
}

.cmd {
    color: var(--accent-adb);
}

.arg {
    color: #d2a8ff;
}

.assumption-box {
    font-size: 0.8rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.02);
    padding: 0.75rem;
    border-radius: 6px;
}

.assumption-box ul {
    margin-top: 0.5rem;
    margin-left: 1.5rem;
    line-height: 1.5;
}

/* WIDGETS */
.info-widget {
    margin-top: 2rem;
    background: linear-gradient(135deg, rgba(63, 185, 80, 0.1), transparent);
    border: 1px solid rgba(63, 185, 80, 0.2);
    padding: 1.5rem;
    border-radius: 12px;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.widget-icon {
    font-size: 1.5rem;
}

/* RESPONSIVE */
@media (max-width: 900px) {
    .protocols-grid {
        grid-template-columns: 1fr;
    }

    .hero-section {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-content {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .hero-visual {
        display: none;
    }
}