/*====================================
                 BLOG  
======================================*/
/* --- CSS VARIABLES & RESET --- */
:root {
    --bg-dark       : #0a192f;
    --bg-card       : #112240;
    --bg-light      : #233554;
    --text-primary  : #ccd6f6;
    --text-secondary: #8892b0;
    --accent        : #00d4ff;
    /* Cyan */
    --accent-hover  : #00a3cc;
    --white         : #e6f1ff;
    --font-main     : 'Quicksand', sans-serif;
    --font-heading  : 'Playfair Display', serif;
    --transition    : all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1);
    --shadow        : 0 10px 30px -10px rgba(2, 12, 27, 0.7);
}

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

html {
    scroll-behavior: smooth;
}

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

a {
    text-decoration: none;
    color          : inherit;
    transition     : var(--transition);
}

ul {
    list-style: none;
}

h1,
h2,
h3,
h4,
h5 {
    color      : var(--white);
    font-family: var(--font-heading);
}

/* --- UTILITIES --- */
.container {
    max-width: 1200px;
    margin   : 0 auto;
    padding  : 0 20px;
}

.section-padding {
    padding: 50px 0;
}

.text-accent {
    color: var(--accent);
}

.text-secondary {
    color: var(--text-secondary);
}

.code-block {
    background   : rgba(0, 212, 255, 0.1);
    color        : var(--accent);
    padding      : 2px 6px;
    border-radius: 4px;
    font-family  : 'Courier New', monospace;
    font-size    : 0.9em;
}

.btn {
    display      : inline-block;
    padding      : 12px 24px;
    border       : 1px solid var(--accent);
    border-radius: 4px;
    color        : var(--accent);
    font-weight  : 500;
    cursor       : pointer;
    background   : transparent;
    transition   : var(--transition);
}

.btn:hover {
    background: rgba(0, 212, 255, 0.1);
    transform : translateY(-2px);
}

.btn-fill {
    background: var(--accent);
    color     : var(--bg-dark);
}

.btn-fill:hover {
    background: var(--accent-hover);
    color     : var(--white);
}

/* --- NAVIGATION --- */
.navbar {
    position               : fixed;
    top                    : 0;
    width                  : 100%;
    background             : rgba(10, 25, 47, 0.95);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter        : blur(10px);
    z-index                : 1000;
    padding                : 20px 0;
    border-bottom          : 1px solid rgba(255, 255, 255, 0.05);
}

.nav-container {
    display        : flex;
    justify-content: space-between;
    align-items    : center;
}

.logo {
    font-family: var(--font-heading);
    font-size  : 1.5rem;
    font-weight: 700;
    color      : var(--accent);
}

.nav-links {
    display: flex;
    gap    : 30px;
}

.nav-link {
    font-size: 1rem;
    color    : var(--text-primary);
    position : relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent);
}

.nav-link::after {
    content   : '';
    display   : block;
    width     : 0;
    height    : 2px;
    background: var(--accent);
    transition: width 0.3s;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.mobile-toggle {
    display  : none;
    color    : var(--accent);
    font-size: 1.5rem;
    cursor   : pointer;
}

/* --- HERO SECTION --- */
.hero {
    top            : 4em;
    position       : relative;
    height         : 60vh;
    display        : flex;
    align-items    : center;
    justify-content: center;
    text-align     : center;
    overflow       : hidden;
}

#bg-canvas {
    position: absolute;
    top     : 0;
    left    : 0;
    width   : 100%;
    height  : 100%;
    z-index : 0;
    opacity : 0.4;
}

.hero-content {
    position : relative;
    z-index  : 1;
    max-width: 800px;
    animation: fadeIn 1.5s ease-out;
}

.hero h1 {
    font-size    : 3.5rem;
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.2rem;
    color    : var(--text-secondary);
}

/* --- BLOG CARDS --- */
.blog-grid {
    display              : grid;
    grid-template-columns: 2fr 1fr;
    gap                  : 30px;
}

@media (max-width: 768px) {
    .blog-grid {
        grid-template-columns: 1fr;
    }
}

.card {
    background   : var(--bg-card);
    border-radius: 8px;
    padding      : 30px;
    box-shadow   : var(--shadow);
    transition   : var(--transition);
    position     : relative;
    overflow     : hidden;
}

.card::before {
    content   : '';
    position  : absolute;
    top       : 0;
    left      : 0;
    width     : 4px;
    height    : 0;
    background: var(--accent);
    transition: height 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
}

.card:hover::before {
    height: 100%;
}

.meta-info {
    display      : flex;
    gap          : 15px;
    font-size    : 0.85rem;
    color        : var(--text-secondary);
    margin-bottom: 15px;
}

.card-title {
    font-size    : 1.8rem;
    margin-bottom: 20px;
    line-height  : 1.3;
}

.highlight-box {
    background : rgba(0, 212, 255, 0.05);
    border-left: 3px solid var(--accent);
    padding    : 15px;
    margin     : 20px 0;
    font-style : italic;
}

.sidebar-card {
    position: sticky;
    top     : 100px;
}

.sidebar-list {
    margin-top: 15px;
}

.list-item {
    margin-bottom : 10px;
    color         : var(--text-secondary);
    border-bottom : 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 10px;
}

/* --- ARCHIVE SECTION --- */
.archive-item {
    background    : var(--bg-card);
    border-radius : 8px;
    padding       : 25px;
    margin-bottom : 20px;
    display       : flex;
    flex-direction: column;
    gap           : 10px;
    border        : 1px solid transparent;
    transition    : var(--transition);
}

.archive-item:hover {
    border-color: var(--accent);
}

.hidden-content {
    display    : none;
    margin-top : 15px;
    padding-top: 15px;
    border-top : 1px solid rgba(255, 255, 255, 0.1);
    animation  : slideDown 0.5s ease;
}

.archive-item.expanded .hidden-content {
    display: block;
}

.read-more-btn {
    color     : var(--accent);
    cursor    : pointer;
    font-size : 0.9rem;
    margin-top: 5px;
    align-self: flex-start;
}

.read-more-btn:hover {
    text-decoration: underline;
}

/* --- INSIGHTS GRID --- */
.insights-grid {
    display              : grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap                  : 20px;
    margin-top           : 30px;
}

.insight-card {
    background   : var(--bg-light);
    padding      : 20px;
    border-radius: 8px;
}

.insight-card h5 {
    color        : var(--white);
    margin-bottom: 15px;
    font-family  : var(--font-heading);
    font-size    : 1.2rem;
}

.insight-card li {
    color          : var(--text-secondary);
    margin-bottom  : 8px;
    font-size      : 0.95rem;
    display        : flex;
    justify-content: space-between;
}

.insight-card code {
    opacity: 0.8;
}

/* --- CONTACT FORM --- */
.form-group {
    margin-bottom: 20px;
}

.form-control {
    width        : 100%;
    padding      : 15px;
    background   : var(--bg-card);
    border       : 1px solid var(--bg-light);
    border-radius: 4px;
    color        : var(--text-primary);
    font-family  : var(--font-main);
    transition   : var(--transition);
}

.form-control:focus {
    outline     : none;
    border-color: var(--accent);
}

/* --- FOOTER --- */
footer {
    background: var(--bg-card);
    padding   : 40px 0;
    text-align: center;
    color     : var(--text-secondary);
}

.social-links {
    margin-bottom: 20px;
}

.social-links a {
    font-size: 1.5rem;
    margin   : 0 15px;
    color    : var(--text-secondary);
}

.social-links a:hover {
    color: var(--accent);
}

/* --- ANIMATIONS --- */
@keyframes fadeIn {
    from {
        opacity  : 0;
        transform: translateY(20px);
    }

    to {
        opacity  : 1;
        transform: translateY(0);
    }
}

@keyframes slideDown {
    from {
        opacity  : 0;
        transform: translateY(-10px);
    }

    to {
        opacity  : 1;
        transform: translateY(0);
    }
}

.reveal {
    opacity   : 0;
    transform : translateY(30px);
    transition: all 0.8s ease-out;
}

.reveal.active {
    opacity  : 1;
    transform: translateY(0);
}

/* --- TOAST NOTIFICATION --- */
.toast {
    position     : fixed;
    bottom       : 30px;
    right        : 30px;
    background   : var(--bg-card);
    border-left  : 4px solid var(--accent);
    padding      : 15px 25px;
    border-radius: 4px;
    box-shadow   : var(--shadow);
    transform    : translateX(150%);
    transition   : transform 0.3s ease;
    z-index      : 2000;
    display      : flex;
    align-items  : center;
    gap          : 10px;
}

.toast.show {
    transform: translateX(0);
}

/* --- MOBILE RESPONSIVENESS --- */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }

    .nav-links {
        position      : absolute;
        top           : 70px;
        right         : 0;
        width         : 100%;
        background    : var(--bg-card);
        flex-direction: column;
        padding       : 20px;
        gap           : 20px;
        transform     : translateX(100%);
        transition    : transform 0.3s ease;
    }

    .nav-links.nav-active {
        transform: translateX(0);
    }

    .mobile-toggle {
        display: block;
    }
}

/* --- UTILITIES FOR REPLACED INLINE STYLES --- */
.bg-overlay {
    background: rgba(255, 255, 255, 0.02);
}

.heading-spacing {
    margin-top: 25px;
    color     : var(--white);
}

.mt-spacing {
    margin-top: 10px;
    margin-bottom: 30px;
}

.mb-5 {
    margin-bottom: 30px;
}

.mb-small {
    margin-bottom: 30px;
}

.img-flex-row {
    display   : flex;
    gap       : 10px;
    margin-top: 10px;
}

.img-half {
    width        : 50%;
    border-radius: 4px;
}

.img-full {
    width        : 100%;
    border-radius: 4px;
    margin-top   : 10px;
}

.container-limit {
    max-width: 600px;
}