/* ======= RESET ======= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* ======= BODY ======= */
body {
    background: linear-gradient(-45deg, #0d1b2a, #1b2838, #0a3d62, #1a1a2e);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    color: #e0e0e0;
    padding: 20px 40px 40px;
    min-height: 100vh;
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.icon-color {
    -webkit-text-fill-color: initial !important;
    background-clip: initial !important;
    -webkit-background-clip: initial !important;
}

/* ======= BACK BUTTON ======= */
.back-btn {
    display: inline-block;
    padding: 12px 24px;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    color: #00d4ff;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    margin-bottom: 20px;
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(-5px);
    box-shadow: 0 4px 15px rgba(0, 212, 255, 0.3);
}

.back-btn-bottom {
    display: block;
    margin: 40px auto 0;
    width: fit-content;
}

/* ======= HEADER ======= */
header {
    text-align: center;
    margin-bottom: 30px;
    animation: fadeInDown 0.8s ease-out;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

h1 {
    font-size: 2.8rem;
    font-weight: 700;
    background: linear-gradient(135deg, #00d4ff 0%, #0099cc 50%, #00f5a0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 12px;
    letter-spacing: -0.5px;
}

.header-sub {
    font-size: 1rem;
    color: #8fa8c0;
    font-weight: 300;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ======= NAV TOC ======= */
nav.toc {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 212, 255, 0.2);
    border-radius: 14px;
    padding: 16px 24px;
    margin-bottom: 35px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

nav.toc ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    list-style: none;
    gap: 10px 24px;
}

nav.toc ul li a {
    color: #00d4ff;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.92rem;
    transition: color 0.2s;
}

nav.toc ul li a:hover {
    color: #00f5a0;
    text-decoration: underline;
}

/* ======= MAIN ======= */
main {
    max-width: 960px;
    margin: 0 auto;
    animation: fadeInUp 0.8s ease-out 0.2s backwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ======= SECTIONS ======= */
section {
    background: rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-left: 4px solid #00d4ff;
    border-radius: 16px;
    padding: 32px 36px;
    margin-bottom: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

h2 {
    font-size: 1.7rem;
    font-weight: 700;
    color: #00d4ff;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(0, 212, 255, 0.25);
}

h3 {
    font-size: 1.15rem;
    font-weight: 600;
    color: #7fdbff;
    margin: 24px 0 10px;
}

p {
    font-size: 1rem;
    line-height: 1.8;
    color: #c5d5e8;
}

ul {
    margin: 10px 0 10px 20px;
    color: #c5d5e8;
    line-height: 1.9;
}

/* ======= VLAN TAGS ======= */
.vlan-list {
    list-style: none;
    margin: 16px 0 0 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.vlan-tag {
    display: inline-block;
    padding: 4px 14px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.85rem;
    margin-right: 10px;
}

.vlan-proxmox {
    background: rgba(52, 152, 219, 0.25);
    border: 1px solid rgba(52, 152, 219, 0.5);
    color: #7fc7f5;
}

.vlan-ia {
    background: rgba(155, 89, 182, 0.25);
    border: 1px solid rgba(155, 89, 182, 0.5);
    color: #c9a0f0;
}

.vlan-nas {
    background: rgba(46, 204, 113, 0.25);
    border: 1px solid rgba(46, 204, 113, 0.5);
    color: #7ef5a8;
}

.vlan-talos {
    background: rgba(230, 126, 34, 0.25);
    border: 1px solid rgba(230, 126, 34, 0.5);
    color: #f5b97e;
}

.vlan-mgmt {
    background: rgba(127, 140, 141, 0.25);
    border: 1px solid rgba(127, 140, 141, 0.5);
    color: #b8c5c6;
}

.vlan-wan {
    background: rgba(231, 76, 60, 0.25);
    border: 1px solid rgba(231, 76, 60, 0.5);
    color: #f5a09a;
}

/* ======= INFO BOX ======= */
.info-box {
    background: rgba(0, 212, 255, 0.07);
    border: 1px solid rgba(0, 212, 255, 0.25);
    border-radius: 10px;
    padding: 14px 18px;
    margin: 16px 0;
    color: #a8d8ea;
    font-size: 0.95rem;
    line-height: 1.7;
}

/* ======= CODE / PRE ======= */
pre {
    background: #0b1622;
    border: 1px solid rgba(0, 212, 255, 0.2);
    border-left: 3px solid #00d4ff;
    color: #a8f0e8;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.88rem;
    padding: 16px 20px;
    border-radius: 8px;
    margin: 14px 0;
    overflow-x: auto;
    line-height: 1.6;
}

code {
    font-family: 'Courier New', Courier, monospace;
}

/* ======= FIGURES ======= */
.figure-block {
    margin: 20px 0;
    text-align: center;
}

.figure-block img {
    max-width: 100%;
    border-radius: 10px;
    border: 1px solid rgba(0, 212, 255, 0.2);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.figure-block img:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 30px rgba(0, 212, 255, 0.25);
}

.figure-block figcaption,
.figure-row figcaption {
    display: block;
    font-size: 0.85rem;
    color: #7a9ab5;
    margin-top: 8px;
    font-style: italic;
}

.figure-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 20px 0;
}

.figure-row .figure-block {
    margin: 0;
}

/* ======= FOOTER ======= */
footer {
    text-align: center;
    padding: 24px;
    margin-top: 40px;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    font-size: 0.88rem;
    color: #6a8a9f;
}

/* ======= RESPONSIVE ======= */
@media (max-width: 768px) {
    body {
        padding: 15px 18px 30px;
    }

    h1 {
        font-size: 2rem;
    }

    section {
        padding: 22px 18px;
    }

    .figure-row {
        grid-template-columns: 1fr;
    }

    nav.toc ul {
        flex-direction: column;
        align-items: center;
    }
}