﻿/* ===== Base Reset ===== */
*,
*::before,
*::after {
    box-sizing: border-box;
}
* {
    font-family: 'BNazanin', 'VazirMatn','BLotus', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    margin: 0;
    background: #f5f7fa;
    color: #333;
    line-height: 1.8;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ===== Container ===== */
.container {
    /*max-width: 1320px;*/
    margin: 0 auto;
    padding: 0 16px;
}

/* ===== Main Content Grid ===== */
.main-content {
    padding: 40px 0;
}

.content-grid {
    display: grid;
    grid-template-columns: 280px 1fr 280px;
    gap: 24px;
}

.category-list {
    padding-right: 50px !important;
}
/* ===== Sidebars ===== */
.sidebar {
    position: relative;
}

.sidebar-widget {
    background: #cde1ff;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,.05);
}

    .sidebar-widget h3 {
        font-size: 16px;
        margin-bottom: 12px;
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .sidebar-widget .sidebar-widget {
        background: lavender;
    }

/* ===== Footer ===== */
.site-footer {
    background: #1e293b;
    color: #cbd5e1;
    padding: 60px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
}

.footer-col h4 {
    margin-bottom: 16px;
    color: #fff;
}

.footer-links li {
    margin-bottom: 8px;
}

.footer-links a:hover {
    color: #38bdf8;
}

.footer-bottom {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,.1);
    display: flex;
    justify-content: space-between;
    font-size: 14px;
}

/* ================= Theme Switch ================= */
.theme-switch {
    display: flex;
    align-items: center;
}

    .theme-switch input {
        display: none;
    }

    .theme-switch label {
        width: 52px;
        height: 28px;
        background: #e5e7eb;
        border-radius: 50px;
        position: relative;
        cursor: pointer;
        transition: background .3s ease;
    }

    .theme-switch .toggle-ball {
        width: 22px;
        height: 22px;
        background: white;
        border-radius: 50%;
        position: absolute;
        top: 3px;
        left: 3px;
        transition: transform .3s ease;
    }

    .theme-switch i {
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        font-size: 12px;
        color: #475569;
    }

    .theme-switch .fa-moon {
        left: 8px;
    }

    .theme-switch .fa-sun {
        right: 8px;
    }

/* ===== Dark State ===== */
body.dark .theme-switch label {
    background: #334155;
}

body.dark .theme-switch .toggle-ball {
    transform: translateX(24px);
}

body.dark .theme-switch i {
    color: #e5e7eb;
}
