
/* ============================================
   CSS Variables (Root Colors)
   ============================================ */
:root {
    /* Primary Colors */
    --primary-color: #6729db;
    --primary-dark: #5326a6;
    --primary-light: #a78bfa;
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    
    /* Light Theme Colors */
    --bg-body-light: #f7f4f4;
    --bg-color: #ffffff;
    --bg-light: #ffffff;
    --bg-secondary: #f8f9fa;
    --text-color: #333333;
    --text-secondary: #6c757d;
    --border-color: #e9ecef;
    
    /* Dark Theme Colors */
    --bg-body-dark: #2d2d2d;
    --bg-dark: #2d2d2d;
    --bg-secondary-dark: #2d2d2d;
    --text-dark: #ffffff;
    --text-secondary-dark: #b0b0b0;
    --border-dark: #404040;
    
    /* Navbar Colors */
    --navbar-bg: var(--primary-color);
    --navbar-text: #ffffff;
    --navbar-scrolled-bg: var(--primary-dark);
    
    /* Button Colors */
    --btn-primary-bg: #ffffff;
    --btn-primary-text: var(--primary-color);
    --btn-primary-hover-bg: rgba(255, 255, 255, 0.9);
    --btn-primary-hover-text: var(--primary-dark);
    
    /* Text Colors */
    --text-white: #ffffff;
    --text-black: #000000;
    --text-gray-dark: #333333;
    --text-gray-medium: #6c757d;
    --text-gray-light: #f5f5f5;
    
    /* Background Colors */
    --bg-white: #ffffff;
    --bg-black: #000000;
    --bg-gray-light: #f5f5f5;
    --bg-gray-medium: #f8f9fa;
    --bg-overlay-dark: rgba(0, 0, 0, 0.6);
    --bg-overlay-light: rgba(255, 255, 255, 0.1);
    --bg-overlay-medium: rgba(255, 255, 255, 0.2);
    --bg-overlay-dark-modal: rgba(0, 0, 0, 0.95);
    --bg-overlay-navbar: rgba(255, 255, 255, 0.1);
    --bg-overlay-hover: rgba(255, 255, 255, 0.3);
    --bg-overlay-scroll: rgba(33, 37, 41, 0.95);
    
    /* Border Colors */
    --border-white-light: rgba(255, 255, 255, 0.1);
    --border-white-medium: rgba(255, 255, 255, 0.6);
    --border-white-dark: rgba(255, 255, 255, 0.85);
    
    /* Gradient Colors */
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-white-light: linear-gradient(135deg, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0.15) 100%);
    --gradient-white-medium: linear-gradient(135deg, rgba(255, 255, 255, 0.4) 0%, rgba(255, 255, 255, 0.25) 100%);
    --gradient-stats: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
    
    /* Stats Overlay Colors */
    --stats-bg: #ffffff;
    --stats-text: #333333;
    --stats-border: #f0f0f0;
    
    /* Portfolio Colors */
    --portfolio-card-bg: #ffffff;
    --portfolio-image-bg: #f5f5f5;
    --portfolio-overlay-bg: var(--bg-overlay-dark);
    --portfolio-tag-bg: var(--primary-light);
    --portfolio-tag-bg-dark: #6729db;
    --portfolio-tag-text: var(--text-white);
    
    /* Icon Colors */
    --icon-color: #667eea;
    
    /* Shadow Colors (for box-shadow) */
    --shadow-light: rgba(0, 0, 0, 0.1);
    --shadow-medium: rgba(0, 0, 0, 0.15);
    --shadow-dark: rgba(0, 0, 0, 0.2);
    --shadow-darker: rgba(0, 0, 0, 0.3);
    --shadow-white-light: rgba(255, 255, 255, 0.3);
    --shadow-primary: rgba(103, 41, 219, 0.4);
    --shadow-primary-dark: rgba(103, 41, 219, 0.6);
    
    /* Animation Delays */
    --animate-delay-1s: 1s;
    --animate-delay-2s: 2s;
    --animate-delay-3s: 3s;
    --animate-delay-4s: 4s;
    
    /* Container Sizes */
    --container-max-width: 1600px;
    
    /* Comments Colors */
    --comment-bg: var(--bg-color);
    --comment-border: var(--border-color);
    --comment-text: var(--text-color);
    --comment-secondary-text: var(--text-secondary);
    --comment-pending-bg: rgba(255, 193, 7, 0.1);
}

body.dark-theme {
    --comment-bg: var(--bg-secondary-dark);
    --comment-border: var(--border-dark);
    --comment-text: var(--text-dark);
    --comment-secondary-text: var(--text-secondary-dark);
    --comment-pending-bg: rgba(255, 193, 7, 0.15);
}

/* ============================================
   Base Styles
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Custom Container Size */
.container {
    max-width: var(--container-max-width);
    margin-left: auto;
    margin-right: auto;
    padding-left: 15px;
    padding-right: 15px;
}

@media (min-width: 576px) {
    .container {
        max-width: var(--container-max-width);
    }
}

@media (min-width: 768px) {
    .container {
        max-width: var(--container-max-width);
    }
}

@media (min-width: 992px) {
    .container {
        max-width: var(--container-max-width);
    }
}

@media (min-width: 1200px) {
    .container {
        max-width: var(--container-max-width);
    }
}

@media (min-width: 1400px) {
    .container {
        max-width: var(--container-max-width);
    }
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'IRANSansWeb', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-body-light);
    line-height: 1.6;
    color: var(--text-color);
    transition: background-color 0.3s ease, color 0.3s ease;
}

body.dark-theme {
    background-color: var(--bg-body-dark);
    color: var(--text-dark);
}

/* Headings use Hamishe font */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: 'Hamishe', 'IRANSansWeb', sans-serif;
    font-weight: bold;
}

/* ============================================
   Navigation Styles
   ============================================ */
#mainNavbar {
    background-color: var(--navbar-bg) !important;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    padding: 0.6rem 0;
}

body.dark-theme #mainNavbar {
    background-color: var(--bg-secondary-dark) !important;
}

#mainNavbar.scrolled {
    background-color: var(--primary-dark) !important;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    padding: 0.25rem 0;
}

body.dark-theme #mainNavbar.scrolled {
    background-color: var(--bg-secondary-dark) !important;
}

.navbar-brand {
    display: flex;
    align-items: center;
    transition: transform 0.3s ease;
}

.navbar-brand:hover {
    transform: scale(1.05);
}

.navbar-brand img {
    transition: transform 0.3s ease;
    height: 50px !important;
    width: auto !important;
    max-height: 50px !important;
    max-width: 250px !important;
    object-fit: contain;
}

.navbar-brand:hover img {
    transform: scale(1.1);
}

/* لوگو بر اساس تم */
.navbar-brand .logo-light {
    display: block !important;
    height: 50px !important;
    width: auto !important;
    max-height: 50px !important;
    max-width: 250px !important;
}

.navbar-brand .logo-dark {
    display: none !important;
    height: 50px !important;
    width: auto !important;
    max-height: 50px !important;
    max-width: 250px !important;
}

body.dark-theme .navbar-brand .logo-light {
    display: none !important;
}

body.dark-theme .navbar-brand .logo-dark {
    display: block !important;
}


/* ============================================
   User Dropdown Responsive Styles
   ============================================ */
/* Desktop: Normal dropdown behavior in navbar */
.navbar .dropdown {
    position: relative !important;
    animation: none !important;
}

.navbar .dropdown-menu {
    position: absolute !important;
    right: 0 !important;
    left: auto !important;
    top: 100% !important;
    margin-top: 0.5rem !important;
    z-index: 1055 !important;
    min-width: 180px;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    background-color: var(--bg-color);
    border: none !important;
}

.navbar .dropdown-menu.dropdown-menu-end {
    right: 0 !important;
    left: auto !important;
}

body.dark-theme .navbar .dropdown-menu {
    background-color: var(--bg-dark);
    border: none !important;
}

.navbar .dropdown-item {
    color: var(--text-color);
    padding: 0.5rem 1rem;
    transition: all 0.2s ease;
}

body.dark-theme .navbar .dropdown-item {
    color: var(--text-dark);
}

.navbar .dropdown-item:hover {
    background-color: var(--bg-secondary);
    color: var(--text-color);
}

body.dark-theme .navbar .dropdown-item:hover {
    background-color: var(--bg-secondary-dark);
    color: var(--text-dark);
}

.navbar .dropdown-item.text-danger {
    color: var(--text-color) !important;
}

body.dark-theme .navbar .dropdown-item.text-danger {
    color: var(--text-dark) !important;
}

.navbar .dropdown-item.text-danger:hover {
    background-color: var(--bg-secondary);
    color: var(--text-color) !important;
}

body.dark-theme .navbar .dropdown-item.text-danger:hover {
    background-color: var(--bg-secondary-dark);
    color: var(--text-dark) !important;
}

/* Ensure dropdown button doesn't break on small screens */
.btn.dropdown-toggle {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

@media (max-width: 575.98px) {
    .btn.dropdown-toggle {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
        font-size: 0.875rem;
    }
    
    .btn.dropdown-toggle .d-none.d-md-inline {
        display: none !important;
    }
}


.navbar-nav .nav-link {
    color: var(--navbar-text) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    margin: 0 0.25rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    position: relative;
}


.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--text-white) !important;
    background-color: var(--bg-overlay-navbar);
}

/* Dropdown Menu Styles */
.dropdown-menu {
    background-color: var(--navbar-bg) !important;
    border: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border-radius: 0.5rem;
    padding: 0.5rem 0;
    margin-top: 0 !important;
    padding-top: 0.75rem;
    position: relative;
    min-width: 220px;
}

/* ایجاد یک پل نامرئی بین nav-link و dropdown-menu برای جلوگیری از بسته شدن dropdown */
.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -0.75rem;
    left: 0;
    right: 0;
    height: 0.75rem;
    background: transparent;
    z-index: -1;
}

body.dark-theme .dropdown-menu {
    background-color: var(--bg-secondary-dark) !important;
}

.dropdown-item {
    color: var(--navbar-text) !important;
    padding: 0.75rem 1rem;
    padding-right: 0.75rem;
    transition: all 0.3s ease;
    border-radius: 0.25rem;
    margin: 0.25rem 0.5rem;
}

.dropdown-item:hover {
    background-color: var(--bg-overlay-hover) !important;
    color: var(--navbar-text) !important;
}

.dropdown-divider {
    margin: 0.5rem 1rem;
    border-color: var(--border-white-light);
}

/* Language Toggle Button */
.language-toggle {
    background: transparent;
    border: none;
    color: var(--navbar-text) !important;
    font-size: 1rem;
    transition: all 0.3s ease;
    border-radius: 0.375rem;
    padding: 0.5rem;
    gap: 0.25rem;
    animation: none !important;
}

.language-toggle:hover {
    background-color: var(--bg-overlay-navbar);
    transform: scale(1.05);
}

.language-toggle .flag-icon-img {
    margin: 0;
    display: inline-block;
    width: 1.5em;
    height: auto;
    vertical-align: middle;
    flex-shrink: 0;
    object-fit: contain;
    border-radius: 2px;
}

.language-toggle .dropdown-toggle::after {
    margin-right: 0.25rem;
    margin-left: 0.25rem;
}

.language-item .flag-icon-img {
    width: 1.3em;
    height: auto;
    vertical-align: middle;
    display: inline-block;
    object-fit: contain;
    border-radius: 2px;
}

.language-item.active {
    background-color: var(--bg-overlay-navbar);
    font-weight: 600;
}

.language-item:hover {
    background-color: var(--bg-overlay-navbar);
}

/* Theme Toggle Button */
.theme-toggle {
    background: transparent;
    border: none;
    color: var(--navbar-text) !important;
    font-size: 1.25rem;
    transition: all 0.3s ease;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: none !important;
}

.theme-toggle:hover {
    background-color: var(--bg-overlay-navbar);
    transform: scale(1.1);
}

.theme-icon {
    transition: transform 0.3s ease;
}

/* CTA Button in Navbar */
.navbar .btn-primary {
    background-color: var(--btn-primary-bg) !important;
    color: var(--btn-primary-text) !important;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    animation: none !important;
}

.navbar .btn-primary:hover {
    background-color: var(--btn-primary-hover-bg) !important;
    color: var(--btn-primary-hover-text) !important;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.3);
}

/* Remove animations from navbar dropdown buttons */
.navbar .dropdown {
    animation: none !important;
}

.navbar .dropdown-toggle {
    animation: none !important;
}

/* Remove all animations from navbar buttons and dropdowns */
.navbar .d-flex.align-items-center.gap-3 > *,
.navbar .d-flex.align-items-center.gap-3 .dropdown,
.navbar .d-flex.align-items-center.gap-3 .dropdown-toggle,
.navbar .d-flex.align-items-center.gap-3 button,
.navbar .d-flex.align-items-center.gap-3 .btn {
    animation: none !important;
    -webkit-animation: none !important;
    -moz-animation: none !important;
    -o-animation: none !important;
}

/* Remove animate.css classes from navbar elements */
.navbar .animate__animated,
.navbar .animate__fadeInUp,
.navbar .animate__bounceInDown,
.navbar .animate__slideInUp {
    animation: none !important;
    -webkit-animation: none !important;
    -moz-animation: none !important;
    -o-animation: none !important;
    opacity: 1 !important;
    transform: none !important;
    visibility: visible !important;
}

.navbar .btn-primary i {
    color: var(--btn-primary-text) !important;
}

/* Navbar Toggler */
.navbar-toggler {
    border: none;
    padding: 0.25rem 0.5rem;
}

.navbar-toggler:focus {
    box-shadow: none;
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.85%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ============================================
   Swiper Slider Styles
   ============================================ */
.m3-section {
    margin-top: 76px;
    position: relative;
    overflow: hidden;
    height: calc(100vh - 76px);
    min-height: calc(100vh - 76px);
    background-color: var(--bg-black);
}


.main-slider {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.main-slider .swiper-wrapper {
    display: flex;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

.main-slider .swiper-slide {
    height: 100%;
    display: flex;
    align-items: center;
    width: 100%;
    flex-shrink: 0;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    transition: transform 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.slider-item {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    overflow: hidden;
    padding: 2rem 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    will-change: transform;
    transition: opacity 0.6s ease-in-out;
}

/* Hide elements before animation */
.hidden-before-animation {
    opacity: 0 !important;
    visibility: hidden !important;
}

/* Animate.css Delay Classes with fill mode */
.animate__animated {
    animation-fill-mode: both !important;
}

/* Faster animation delays */
.animate__delay-0-3s {
    animation-delay: 0.3s !important;
}

.animate__delay-0-6s {
    animation-delay: 0.6s !important;
}

.animate__delay-0-9s {
    animation-delay: 0.9s !important;
}

/* Faster animation duration */
.animate__animated {
    animation-duration: 0.8s !important;
}

.animate__bounceInDown {
    animation-duration: 0.8s !important;
}

.animate__fadeInUp {
    animation-duration: 0.8s !important;
}

/* Custom CSS animation for slider image - slide from left */
@keyframes slideInFromLeft {
    0% {
        opacity: 0;
        transform: translateX(-150px) scale(0.85);
        filter: blur(8px);
    }
    100% {
        opacity: 1;
        transform: translateX(0) scale(1);
        filter: blur(0);
    }
}

/* Initial state for slider image */
.slider-image {
    opacity: 0;
    transform: translateX(-150px) scale(0.85);
    filter: blur(8px);
    transition: none;
}

/* Animate image when slide becomes active - will be triggered by JS */
.main-slider .swiper-slide-active .slider-image {
    animation: slideInFromLeft 0.9s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
    animation-delay: 0.2s;
}

/* Reset image state for inactive slides */
.main-slider .swiper-slide:not(.swiper-slide-active) .slider-image {
    animation: none !important;
    opacity: 0;
    transform: translateX(-150px) scale(0.85);
    filter: blur(8px);
}

.m3-dark-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.slider-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.2;
    pointer-events: none;
    z-index: 0;
}

.slider-item .container {
    position: relative;
    z-index: 1;
    max-width: 1600px;
    padding-left: 1rem;
    padding-right: 1rem;
}

.min-vh-50 {
    min-height: 100%;
    height: 100%;
}

.slider-image {
    max-height: 60vh;
    max-width: 100%;
    width: auto;
    height: auto;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.3));
    animation: float 3s ease-in-out infinite;
    object-fit: contain;
}

.slider-icon {
    font-size: 200px;
    opacity: 0.3;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.3;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.5;
    }
}

/* Modern Navigation Buttons */
.main-slider .swiper-button-next,
.main-slider .swiper-button-prev {
    width: 60px;
    height: 60px;
    background: var(--gradient-white-light);
    border-radius: 50%;
    backdrop-filter: blur(15px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    color: var(--text-white);
    border: 2px solid var(--border-white-medium);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 0;
}

.main-slider .swiper-button-next::after,
.main-slider .swiper-button-prev::after {
    display: none;
}

.main-slider .swiper-button-next i,
.main-slider .swiper-button-prev i {
    font-size: 24px;
    font-weight: bold;
}

.main-slider .swiper-button-next:hover,
.main-slider .swiper-button-prev:hover {
    background: var(--gradient-white-medium);
    transform: scale(1.15) translateY(-50%);
    border-color: var(--border-white-medium);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
}

.main-slider .swiper-button-prev {
    right: 2rem;
    left: auto;
    top: 50%;
    transform: translateY(-50%);
}

.main-slider .swiper-button-next {
    left: 2rem;
    right: auto;
    top: 50%;
    transform: translateY(-50%);
}

/* Thumbnail Slider Styles */
.thumbnail-slider {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    width: auto;
    max-width: 90%;
    padding: 0;
    z-index: 10;
    margin: 0;
}

.thumbnail-slider .swiper-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    transform: none !important;
    transition: none !important;
}

.thumbnail-slider .swiper-slide {
    width: 100px !important;
    margin: 0 5px !important;
    flex-shrink: 0;
    transform: none !important;
    transition: none !important;
}

.thumbnail-item {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto;
    cursor: pointer;
    transition: border 0.3s ease;
    border: 3px solid var(--border-white-light);
    position: relative;
    background: transparent;
}

.thumbnail-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.thumbnail-item:hover .thumbnail-image {
    transform: scale(1.1);
}

.thumbnail-slider .swiper-slide {
    opacity: 1;
    transition: border 0.3s ease;
}

.thumbnail-slider .swiper-slide-thumb-active .thumbnail-item {
    border: 4px solid var(--text-white);
}

/* ============================================
   About Section Styles
   ============================================ */
.m6-section {
    overflow: hidden;
}

body.dark-theme .m6-section {
    background-color: var(--bg-secondary-dark);
}

.m6-section .container {
    max-width: var(--container-max-width);
}

.section-header {
    margin-bottom: 3rem;
}

.section-title {
    font-size: clamp(1.25rem, 3.5vw, 2rem);
    color: var(--text-color);
    position: relative;
    transition: color 0.3s ease;
}

/* اطمینان از اینکه h3.section-title همان اندازه فونت h2.section-title را دارد */
h3.section-title {
    font-size: clamp(1.25rem, 3.5vw, 2rem) !important;
}

body.dark-theme .section-title {
    color: var(--text-dark);
}

.section-title-line {
    width: 60px;
    height: 4px;
    background: var(--gradient-primary);
    border-radius: 2px;
    margin-top: 1rem;
}

.section-subtitle {
    font-size: clamp(0.95rem, 2.5vw, 1.1rem);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.8;
    white-space: normal;
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

body.dark-theme .section-subtitle {
    color: var(--text-secondary-dark);
}

.about-image-wrapper {
    position: relative;
    overflow: visible;
}

.about-image-wrapper img {
    width: 100%;
    height: auto;
    object-fit: cover;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: box-shadow 0.3s ease;
}

body.dark-theme .about-image-wrapper img {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.stats-overlay {
    position: absolute;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    z-index: 10;
    animation: fadeInUp 0.6s ease-out;
}

.stats-overlay-1 {
    top: 2rem;
    left: 2rem;
    background: var(--gradient-stats);
    color: var(--text-white);
}

.stats-overlay-2 {
    bottom: 2rem;
    right: 2rem;
    background: var(--stats-bg);
    color: var(--stats-text);
    border: 2px solid var(--stats-border);
}

.stats-number {
    font-size: 2.5rem;
    font-weight: bold;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stats-label {
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.about-content {
    padding: 2rem 0;
}

/* نمایش کامل متن subtitle در ماژول 6 */
.about-content .section-subtitle {
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
    max-width: 100% !important;
    margin: 0 !important;
}

/* Initial state for GSAP animations - will be overridden by GSAP */
.about-image-animate,
.about-text-animate {
    opacity: 0;
}

.about-content h2 {
    color: var(--text-color);
    transition: color 0.3s ease;
}

body.dark-theme .about-content h2 {
    color: var(--text-dark);
}

.about-content p {
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

body.dark-theme .about-content p {
    color: var(--text-secondary-dark);
}

.about-content .btn-primary {
    background-color: var(--primary-dark) !important;
    color: var(--text-white) !important;
    border: none;
}

.about-content .btn-primary:hover {
    background-color: var(--primary-color) !important;
    color: var(--text-white) !important;
}

.feature-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary-dark);
    color: var(--text-white);
    border-radius: 12px;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.feature-item h5 {
    color: var(--text-color);
    font-size: 1.1rem;
    transition: color 0.3s ease;
}

body.dark-theme .feature-item h5 {
    color: var(--text-dark);
}

.feature-item p {
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

body.dark-theme .feature-item p {
    color: var(--text-secondary-dark);
}

/* ============================================
   Portfolio Section Styles
   ============================================ */
.m11-section {
    /* background-color: var(--bg-light);
    transition: background-color 0.3s ease; */
}

.m11-section .container {
    max-width: var(--container-max-width);
}

body.dark-theme .m11-section {
    background-color: var(--bg-secondary-dark);
}

.portfolio-card {
    background: var(--portfolio-card-bg);
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    /* Initial state for GSAP animation */
    opacity: 0;
}

body.dark-theme .portfolio-card {
    background: var(--bg-secondary-dark);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.portfolio-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

body.dark-theme .portfolio-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
}

.portfolio-image-wrapper {
    position: relative;
    overflow: hidden;
    width: 100%;
    aspect-ratio: 4 / 2;
    background: var(--portfolio-image-bg);
}

body.dark-theme .portfolio-image-wrapper {
    background: var(--bg-dark);
}

.portfolio-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
    cursor: pointer;
}

.portfolio-card:hover .portfolio-image {
    transform: scale(1.1);
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--portfolio-overlay-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    cursor: pointer;
}

.portfolio-card:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-overlay i {
    font-size: 3rem;
    color: var(--text-white);
}

.portfolio-content {
    padding: 1rem 1.5rem 1rem 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

[dir="ltr"] .portfolio-content {
    text-align: left;
}

.portfolio-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    margin-top: 0;
    padding-top: 0;
    color: var(--text-color);
    transition: color 0.3s ease;
    text-align: right;
}

[dir="ltr"] .portfolio-title {
    text-align: left;
}

body.dark-theme .portfolio-title {
    color: var(--text-dark);
}

.portfolio-subtitle {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    margin-top: 0.5rem;
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
    transition: color 0.3s ease;
    text-align: right;
}

[dir="ltr"] .portfolio-subtitle {
    text-align: left;
}

body.dark-theme .portfolio-subtitle {
    color: var(--text-secondary-dark);
}

.portfolio-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: auto;
    margin-bottom: 0;
    padding-bottom: 0;
}

.portfolio-tag {
    display: inline-block;
    padding: 0.25rem 0.65rem;
    background: var(--portfolio-tag-bg);
    color: var(--portfolio-tag-text);
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
}

body.dark-theme .portfolio-tag {
    background: var(--portfolio-tag-bg-dark);
    color: var(--portfolio-tag-text);
}

/* Portfolio Lightbox Modal Styles */
#portfolioLightbox .modal-content {
    background: var(--bg-overlay-dark-modal) !important;
    border: none;
}

.portfolio-lightbox-slider {
    width: 100%;
    height: 100vh;
    position: relative;
}

.portfolio-lightbox-slider .swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
}

.portfolio-lightbox-slider img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}

.portfolio-lightbox-next,
.portfolio-lightbox-prev {
    color: var(--text-white) !important;
    background: var(--bg-overlay-medium) !important;
    width: 50px !important;
    height: 50px !important;
    border-radius: 50% !important;
    transition: background 0.3s ease;
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    z-index: 1000 !important;
    padding: 0 !important;
    margin: 0 !important;
    cursor: pointer !important;
    opacity: 1 !important;
    visibility: visible !important;
}

.portfolio-lightbox-next {
    left: 2rem !important;
    right: auto !important;
}

.portfolio-lightbox-prev {
    right: 2rem !important;
    left: auto !important;
}

/* Hide Swiper default icons */
.portfolio-lightbox-next::after,
.portfolio-lightbox-prev::after {
    display: none !important;
    content: none !important;
}

.portfolio-lightbox-next:hover,
.portfolio-lightbox-prev:hover {
    background: var(--bg-overlay-hover) !important;
}

.portfolio-lightbox-next i,
.portfolio-lightbox-prev i {
    font-size: 2rem !important;
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    line-height: 0 !important;
    color: var(--text-white) !important;
    width: 1em !important;
    height: 1em !important;
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    text-align: center !important;
    font-style: normal !important;
}

.check-icon {
    color: var(--icon-color);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.check-item {
    color: var(--text-secondary);
    font-size: 1rem;
    transition: color 0.3s ease;
}

body.dark-theme .check-item {
    color: var(--text-secondary-dark);
}

/* Dark Theme Text Colors */
body.dark-theme .text-muted {
    color: var(--text-secondary-dark) !important;
}

body.dark-theme h1,
body.dark-theme h2,
body.dark-theme h3,
body.dark-theme h4,
body.dark-theme h5,
body.dark-theme h6 {
    color: var(--text-dark) !important;
}

body.dark-theme p,
body.dark-theme span,
body.dark-theme div {
    color: var(--text-secondary-dark);
}

body.dark-theme .lead {
    color: var(--text-secondary-dark) !important;
}

/* ============================================
   Modern Accordion Styles
   ============================================ */
.modern-accordion {
    --accordion-border-radius: 12px;
    --accordion-spacing: 1rem;
    --accordion-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    --accordion-shadow-hover: 0 4px 20px rgba(0, 0, 0, 0.12);
    --accordion-transition: all 0.3s ease;
}

.modern-accordion .accordion-item {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--accordion-border-radius);
    margin-bottom: var(--accordion-spacing);
    overflow: hidden;
    box-shadow: var(--accordion-shadow);
    transition: var(--accordion-transition);
}

body.dark-theme .modern-accordion .accordion-item {
    background: var(--bg-secondary-dark);
    border-color: var(--border-dark);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.modern-accordion .accordion-item:hover {
    box-shadow: var(--accordion-shadow-hover);
    transform: translateY(-2px);
}

body.dark-theme .modern-accordion .accordion-item:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.modern-accordion .accordion-item:last-child {
    margin-bottom: 0;
}

.modern-accordion .accordion-header {
    margin-bottom: 0;
}

.modern-accordion .accordion-button {
    background: transparent;
    border: none;
    padding: 1.25rem 1.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color);
    box-shadow: none;
    position: relative;
    transition: var(--accordion-transition);
    display: flex;
    align-items: center;
    width: 100%;
    text-align: right;
    direction: rtl;
    justify-content: flex-start;
}

[dir="ltr"] .modern-accordion .accordion-button {
    text-align: left !important;
    direction: ltr !important;
    justify-content: flex-start !important;
}

.modern-accordion .accordion-button span {
    text-align: right;
    flex: 1;
}

[dir="ltr"] .modern-accordion .accordion-button span {
    text-align: left !important;
}

body.dark-theme .modern-accordion .accordion-button {
    color: var(--text-dark);
}

.modern-accordion .accordion-button:not(.collapsed) {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
}

body.dark-theme .modern-accordion .accordion-button:not(.collapsed) {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.2) 0%, rgba(118, 75, 162, 0.2) 100%);
    color: var(--primary-light);
    border-bottom-color: var(--primary-light);
}

.modern-accordion .accordion-button:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(139, 92, 246, 0.15);
    outline: none;
}

.modern-accordion .accordion-button::after {
    content: '';
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%238b5cf6'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
    background-size: 1.25rem;
    width: 1.25rem;
    height: 1.25rem;
    margin-left: auto;
    margin-right: 0;
    transition: transform 0.3s ease;
    order: 1;
    flex-shrink: 0;
}

[dir="ltr"] .modern-accordion .accordion-button::after {
    margin-left: auto;
    margin-right: 0;
    order: 1;
}

body.dark-theme .modern-accordion .accordion-button::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23a78bfa'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
}

.modern-accordion .accordion-button:not(.collapsed)::after {
    transform: rotate(180deg);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%238b5cf6'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
}

body.dark-theme .modern-accordion .accordion-button:not(.collapsed)::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23a78bfa'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
}

.modern-accordion .accordion-button i {
    color: var(--primary-color);
    font-size: 1.25rem;
    margin-left: 0.75rem;
    transition: var(--accordion-transition);
}

[dir="ltr"] .modern-accordion .accordion-button i {
    margin-left: 0;
    margin-right: 0.75rem;
}

body.dark-theme .modern-accordion .accordion-button i {
    color: var(--primary-light);
}

.modern-accordion .accordion-button:not(.collapsed) i {
    color: var(--primary-color);
    transform: scale(1.1);
}

body.dark-theme .modern-accordion .accordion-button:not(.collapsed) i {
    color: var(--primary-light);
}

.modern-accordion .accordion-collapse {
    transition: height 0.35s ease;
}

.modern-accordion .accordion-body {
    padding: 1.5rem;
    background: var(--bg-color);
    color: var(--text-secondary);
    line-height: 1.8;
    font-size: 1rem;
    border-top: 1px solid var(--border-color);
    text-align: right;
    direction: rtl;
}

[dir="ltr"] .modern-accordion .accordion-body {
    text-align: left !important;
    direction: ltr !important;
}

body.dark-theme .modern-accordion .accordion-body {
    background: var(--bg-secondary-dark);
    color: var(--text-secondary-dark);
    border-top-color: var(--border-dark);
}

.modern-accordion .accordion-body p {
    margin-bottom: 0;
    color: var(--text-secondary);
}

body.dark-theme .modern-accordion .accordion-body p {
    color: var(--text-secondary-dark);
}

/* FAQ Image Wrapper */
.faq-image-wrapper {
    position: sticky;
    top: 100px;
    height: fit-content;
    background: transparent;
    background-color: transparent;
}

.faq-image-wrapper img {
    width: 100%;
    height: auto;
    object-fit: cover;
    background: transparent;
    background-color: transparent;
    border-radius: 12px;
}

.faq-image-wrapper:hover img {
    transform: scale(1.02);
}

/* اندازه‌های مختلف تصویر FAQ */
.faq-image-wrapper.faq-image-large {
    max-width: 100%;
}

.faq-image-wrapper.faq-image-medium {
    max-width: 80%;
    margin: 0 auto;
}

.faq-image-wrapper.faq-image-small {
    max-width: 60%;
    margin: 0 auto;
}

/* Responsive */
@media (max-width: 768px) {
    .modern-accordion .accordion-button {
        padding: 1rem 1.25rem;
        font-size: 1rem;
    }
    
    .modern-accordion .accordion-body {
        padding: 1.25rem;
        font-size: 0.95rem;
    }
    
    .modern-accordion .accordion-button i {
        font-size: 1.1rem;
        margin-left: 0.5rem;
    }
    
    .faq-image-wrapper {
        position: relative;
        top: 0;
        margin-top: 2rem;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   Hero Section Styles
   ============================================ */
#home {
    background: var(--gradient-primary);
    color: var(--text-white);
    position: relative;
    overflow: hidden;
}

#home::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

#home .container {
    position: relative;
    z-index: 1;
}

#home h1 {
    color: var(--text-white);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

#home .btn {
    font-weight: 600;
    transition: all 0.3s ease;
}

#home .btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

/* ============================================
   Mobile Sidebar (Offcanvas) Styles
   ============================================ */
.offcanvas-dark {
    background-color: var(--primary-color) !important;
    backdrop-filter: blur(10px);
}

body.dark-theme .offcanvas-dark {
    background-color: var(--bg-secondary-dark) !important;
}

.offcanvas-header {
    padding: 1.5rem;
}

.offcanvas-title {
    font-family: 'Hamishe', 'IRANSansWeb', sans-serif;
    font-weight: bold;
    font-size: 1.25rem;
}

.offcanvas-body {
    padding: 1.5rem;
}

.offcanvas-body .navbar-nav {
    text-align: right;
}

.offcanvas-body .nav-link {
    color: var(--text-white) !important;
    font-weight: 500;
    padding: 0.75rem 1rem !important;
    margin: 0.25rem 0;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
}

.offcanvas-body .nav-link:hover,
.offcanvas-body .nav-link.active {
    color: var(--text-white) !important;
    background-color: var(--bg-overlay-navbar);
}

.offcanvas-body .dropdown-menu {
    background-color: var(--bg-overlay-dark);
    border: none;
    margin-top: 0.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.offcanvas-body .dropdown-item {
    color: var(--navbar-text) !important;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
    border-radius: 0.25rem;
    margin: 0.25rem 0.5rem;
}

.offcanvas-body .dropdown-item:hover {
    background-color: var(--bg-overlay-hover) !important;
    color: var(--navbar-text) !important;
}

.offcanvas-body .btn-primary {
    background-color: var(--btn-primary-bg) !important;
    color: var(--btn-primary-text) !important;
    border: none;
}

.offcanvas-body .btn-primary:hover {
    background-color: var(--btn-primary-hover-bg) !important;
    color: var(--btn-primary-hover-text) !important;
}

.offcanvas-body .btn-primary i {
    color: var(--btn-primary-text) !important;
}

/* ============================================
   Responsive Styles
   ============================================ */
@media (max-width: 991.98px) {
    .navbar-nav {
        text-align: right;
        padding-top: 1rem;
    }
    
    .navbar-nav .nav-link {
        padding: 0.75rem 1rem !important;
        margin: 0.25rem 0;
    }
    
    .navbar .btn-primary {
        margin-top: 1rem;
        width: 100%;
        text-align: center;
    }
    
    .dropdown-menu {
        background-color: var(--bg-overlay-scroll);
        margin-right: 1rem;
    }
}

/* ============================================
   M8 Section Styles
   ============================================ */

/* M8 Section Container */
.m8-section {
    overflow: visible !important;
}

body.dark-theme .m8-section {
    background-color: var(--bg-secondary-dark);
}

.m8-section .container {
    max-width: var(--container-max-width);
    position: relative;
    overflow: visible !important;
}

/* M8 Swiper Wrapper */
.articles-swiper-wrapper {
    position: relative;
    padding: 0 0 60px 0;
    overflow: visible;
}

.articles-slider {
    overflow: hidden;
    position: relative;
}

.articles-slider .swiper-wrapper {
    display: flex;
    align-items: stretch;
}

.articles-slider .swiper-slide {
    height: auto;
    display: flex;
    flex-shrink: 0;
}

/* M8 Loader Styles */
.module8-loader {
    min-height: 400px;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 0;
}

.loader-skeleton {
    display: flex;
    gap: 30px;
    width: 100%;
    max-width: 1200px;
    padding: 0 15px;
    flex-wrap: nowrap;
    justify-content: flex-start;
    position: relative;
}

.skeleton-item {
    flex: 0 0 calc((100% - 60px) / 3);
    min-width: 0;
    max-width: calc((100% - 60px) / 3);
    width: calc((100% - 60px) / 3);
    background: var(--portfolio-card-bg, #ffffff);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    height: auto;
    display: flex;
    flex-direction: column;
    border: none;
    position: relative;
}

body.dark-theme .skeleton-item {
    background: var(--bg-secondary-dark, #1e1e1e);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.skeleton-image {
    position: relative;
    overflow: hidden;
    background: var(--portfolio-card-bg, #f8f9fa);
    padding: 1rem;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px 12px 0 0;
    min-height: calc(250px + 2rem);
    width: 100%;
}

.skeleton-image::after {
    content: '';
    position: absolute;
    top: 1rem;
    left: 1rem;
    right: 1rem;
    height: 250px;
    background: linear-gradient(90deg, 
        var(--bg-secondary-light, #f0f0f0) 25%, 
        rgba(255, 255, 255, 0.5) 50%, 
        var(--bg-secondary-light, #f0f0f0) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
    border-radius: 12px;
}

body.dark-theme .skeleton-image {
    background: var(--bg-secondary-dark, #1e1e1e);
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

body.dark-theme .skeleton-image::after {
    background: linear-gradient(90deg, 
        var(--bg-secondary-dark, #2a2a2a) 25%, 
        rgba(255, 255, 255, 0.1) 50%, 
        var(--bg-secondary-dark, #2a2a2a) 75%);
    background-size: 200% 100%;
}

.skeleton-content {
    padding: 1rem 1.5rem 1.5rem 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    border-radius: 0 0 12px 12px;
}

.skeleton-line {
    height: 12px;
    background: var(--bg-secondary-light, #f0f0f0);
    border-radius: 6px;
    margin-bottom: 12px;
    position: relative;
    overflow: hidden;
}

.skeleton-line::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 25%, 
        rgba(255, 255, 255, 0.5) 50%, 
        transparent 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
}

body.dark-theme .skeleton-line {
    background: var(--bg-secondary-dark, #2a2a2a);
}

body.dark-theme .skeleton-line::before {
    background: linear-gradient(90deg, 
        transparent 25%, 
        rgba(255, 255, 255, 0.1) 50%, 
        transparent 75%);
    background-size: 200% 100%;
}

.skeleton-title {
    height: 20px;
    width: 80%;
    margin-bottom: 1rem;
}

.skeleton-text {
    width: 100%;
    margin-bottom: 0.5rem;
}

.skeleton-text.short {
    width: 60%;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Ensure articles-swiper-wrapper has position relative for navigation buttons */
#module8-content .articles-swiper-wrapper {
    position: relative;
}

/* Fade in animation for content */
#module8-content {
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* M8 Loader Responsive */
@media (max-width: 991.98px) and (min-width: 768px) {
    .skeleton-item {
        flex: 0 0 calc((100% - 30px) / 2);
        max-width: calc((100% - 30px) / 2);
        width: calc((100% - 30px) / 2);
    }
    
    .loader-skeleton {
        gap: 30px;
    }
}

@media (max-width: 767.98px) {
    .skeleton-item {
        flex: 0 0 100%;
        max-width: 100%;
        width: 100%;
    }
    
    .loader-skeleton {
        gap: 20px;
    }
}

/* M8 Article Card */

.article-card {
    background: var(--portfolio-card-bg);
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    border: none;
    position: relative;
}

body.dark-theme .article-card {
    background: var(--bg-secondary-dark);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.article-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px var(--shadow-medium);
}

body.dark-theme .article-card:hover {
    box-shadow: 0 8px 25px var(--shadow-darker);
}

.article-image-wrapper {
    position: relative;
    overflow: hidden;
    background: var(--portfolio-card-bg);
    padding: 1rem;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px 12px 0 0;
}

body.dark-theme .article-image-wrapper {
    background: var(--bg-secondary-dark);
}

.article-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.4s ease, border-radius 0.4s ease;
    display: block;
    border-radius: 12px;
}

.article-card:hover .article-image {
    transform: scale(1.1);
    border-radius: 0;
}


.article-content {
    padding: 1rem 1.5rem 1.5rem 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    border-radius: 0 0 12px 12px;
}

/* در LTR: text-align left */
.m8-section[dir="ltr"] .article-content {
    text-align: left;
    direction: ltr;
}

/* در RTL: text-align right */
.m8-section[dir="rtl"] .article-content {
    text-align: right;
    direction: rtl;
}

.article-meta-top {
    margin-bottom: 0.75rem;
    padding-top: 0;
    margin-top: 0;
}

.article-date-time {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

body.dark-theme .article-date-time {
    color: var(--text-secondary-dark);
}

.article-date-time i {
    font-size: 0.875rem;
}


.article-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.4;
}

.article-title a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

body.dark-theme .article-title a {
    color: var(--text-dark);
}

.article-title a:hover {
    color: var(--primary-color);
}

.article-excerpt {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
    flex-grow: 1;
}

body.dark-theme .article-excerpt {
    color: var(--text-secondary-dark);
}

.article-footer {
    display: flex;
    flex-direction: row-reverse;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

/* در LTR: flex-direction row (نه row-reverse) */
.m8-section[dir="ltr"] .article-footer {
    flex-direction: row;
}

body.dark-theme .article-footer {
    border-top: 1px solid var(--border-dark);
}

.article-read-more {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-white);
    background: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.875rem;
    padding: 0.5rem 1.25rem;
    border-radius: 20px;
    transition: all 0.3s ease;
}

body.dark-theme .article-read-more {
    background: var(--primary-light);
}

.article-read-more:hover {
    background: var(--primary-dark);
    color: var(--text-white);
    gap: 0.75rem;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

body.dark-theme .article-read-more:hover {
    background: var(--primary-color);
}

.article-read-more i {
    font-size: 1rem;
    transition: transform 0.3s ease;
}

/* در RTL: آیکون به چپ حرکت می‌کند */
.m8-section[dir="rtl"] .article-read-more:hover i {
    transform: translateX(-3px);
}

/* در LTR: آیکون به راست حرکت می‌کند */
.m8-section[dir="ltr"] .article-read-more:hover i {
    transform: translateX(3px);
}

/* Articles Swiper Navigation - Removed, using pagination dots instead */

/* Articles Navigation Buttons */
.articles-swiper-wrapper {
    position: relative;
    overflow: visible;
}

/* Ensure container doesn't clip navigation buttons */
.m8-section .container {
    overflow: visible;
    position: relative;
}

/* Base styles for both navigation buttons - Glass effect like M5 */
.articles-next,
.articles-prev {
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    z-index: 10 !important;
    width: 50px !important;
    height: 50px !important;
    background: rgba(255, 255, 255, 0.9) !important;
    border-radius: 50% !important;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: var(--primary-color) !important;
    font-size: 1.5rem !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    border: none !important;
    outline: none !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* Override Swiper's disabled state - always show buttons */
.articles-next.swiper-button-disabled,
.articles-prev.swiper-button-disabled {
    opacity: 1 !important;
    pointer-events: auto !important;
    cursor: pointer !important;
}

.articles-next:hover,
.articles-prev:hover {
    background: var(--primary-color) !important;
    color: white !important;
    transform: translateY(-50%) scale(1.1) !important;
}

/* Dark theme support */
body.dark-theme .articles-next,
body.dark-theme .articles-prev {
    background: rgba(45, 45, 45, 0.9) !important;
    color: var(--primary-light) !important;
}

body.dark-theme .articles-next:hover,
body.dark-theme .articles-prev:hover {
    background: var(--primary-color) !important;
    color: white !important;
}

/* Desktop position: دکمه‌ها روی باکس‌ها (LTR) */
.articles-next {
    right: 10px !important;
    left: auto !important;
}

.articles-prev {
    left: 10px !important;
    right: auto !important;
}

/* RTL: next در سمت چپ، prev در سمت راست */
.m8-section[dir="rtl"] .articles-next {
    left: 10px !important;
    right: auto !important;
}

.m8-section[dir="rtl"] .articles-prev {
    right: 10px !important;
    left: auto !important;
}

.articles-next::after,
.articles-prev::after {
    display: none;
}

.articles-next i,
.articles-prev i {
    display: block;
    line-height: 1;
}

/* Adjust navigation buttons position for tablet */
@media (max-width: 991.98px) {
    .articles-next {
        right: 10px !important;
        left: auto !important;
    }
    
    .articles-prev {
        left: 10px !important;
        right: auto !important;
    }
    
    /* RTL for tablet */
    .m8-section[dir="rtl"] .articles-next {
        left: 10px !important;
        right: auto !important;
    }
    
    .m8-section[dir="rtl"] .articles-prev {
        right: 10px !important;
        left: auto !important;
    }
}

/* Adjust navigation buttons position for mobile - فقط یک دکمه */
@media (max-width: 767.98px) {
    .articles-swiper-wrapper {
        padding: 0 0 40px 0;
    }
    
    .articles-next {
        right: 5px !important;
        left: auto !important;
    }
    
    /* در mobile فقط دکمه next نمایش داده می‌شود */
    .articles-prev {
        display: none !important;
    }
    
    /* RTL for mobile */
    .m8-section[dir="rtl"] .articles-next {
        left: 5px !important;
        right: auto !important;
    }
    
    .m8-section[dir="rtl"] .articles-prev {
        display: none !important;
    }
    
    .articles-next,
    .articles-prev {
        width: 40px !important;
        height: 40px !important;
        font-size: 1.2rem !important;
    }
}

/* Responsive Styles for Articles */
@media (max-width: 767.98px) {
    .articles-swiper-wrapper {
        padding: 0 0 40px 0;
    }
    
    .article-content {
        padding: 1.25rem;
    }
    
    .article-title {
        font-size: 1.1rem;
    }
}

@media (max-width: 991.98px) {
    .m3-section {
        margin-top: 0 !important;
        padding-top: 0 !important;
        height: calc(100vh - 60px);
        min-height: calc(100vh - 60px);
    }
    
    .main-slider .swiper-slide {
        height: 100%;
    }
    
    .slider-item {
        height: 100% !important;
        padding: 2rem 0;
    }
    
    .slider-item h1 {
        font-size: 2rem !important;
    }
    
    .slider-item .lead {
        font-size: 1rem !important;
    }
    
    .slider-image {
        max-height: 40vh !important;
    }
    
    .slider-icon {
        font-size: 150px !important;
    }
    
    .main-slider .swiper-button-next,
    .main-slider .swiper-button-prev {
        width: 40px;
        height: 40px;
    }
    
    .main-slider .swiper-button-prev {
        right: 1rem;
    }
    
    .main-slider .swiper-button-next {
        left: 1rem;
    }
    
    .thumbnail-slider {
        bottom: 1rem;
        max-width: 90%;
    }
    
    .thumbnail-slider .swiper-slide {
        width: 80px !important;
        margin: 0 4px !important;
    }
    
    .thumbnail-item {
        width: 80px;
        height: 80px;
    }
}

@media (max-width: 575.98px) {
    .navbar-brand img,
    .navbar-brand .logo-light,
    .navbar-brand .logo-dark {
        height: 35px !important;
        max-height: 35px !important;
    }
    
    .navbar-brand {
        font-size: 1rem;
    }
    
    .navbar-brand img,
    .navbar-brand .logo-light,
    .navbar-brand .logo-dark {
        height: 35px !important;
        max-height: 35px !important;
        width: auto !important;
        max-width: 150px !important;
    }
    
    .m3-section {
        margin-top: 0 !important;
        padding-top: 0 !important;
        height: 85vh;
        min-height: 85vh;
        padding: 0;
    }
    
    .main-slider {
        width: 100%;
    }
    
    .main-slider .swiper-slide {
        height: 100%;
    }
    
    .slider-item {
        height: 100% !important;
        padding: 1.5rem 0;
        text-align: center;
    }
    
    .slider-item h1 {
        font-size: 1.5rem !important;
        margin-bottom: 1rem !important;
    }
    
    .slider-item .lead {
        font-size: 0.9rem !important;
        margin-bottom: 1.5rem !important;
    }
    
    .slider-image {
        max-height: 30vh !important;
        margin-top: 1rem;
    }
    
    .slider-icon {
        font-size: 100px !important;
        margin-top: 1rem;
    }
    
    .slider-item .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    .thumbnail-slider {
        bottom: 0.5rem;
        max-width: 95%;
    }
    
    .thumbnail-slider .swiper-slide {
        width: 70px !important;
        margin: 0 3px !important;
    }
    
    .thumbnail-item {
        width: 70px;
        height: 70px;
        border-width: 3px;
    }
    
    .main-slider .swiper-button-next,
    .main-slider .swiper-button-prev {
        width: 45px;
        height: 45px;
        opacity: 0.8;
    }
    
    .main-slider .swiper-button-prev {
        right: 0.5rem;
    }
    
    .main-slider .swiper-button-next {
        left: 0.5rem;
    }
    
    .main-slider .swiper-button-next i,
    .main-slider .swiper-button-prev i {
        font-size: 18px;
    }
    
    #home h1 {
        font-size: 2rem;
    }
    
    #home .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    .m6-section {
        padding: 3rem 0;
    }
    
    .section-header {
        margin-bottom: 2rem;
    }
    
    .section-title {
        font-size: clamp(1.25rem, 3.5vw, 1.75rem);
    }
    
    .section-subtitle {
        font-size: clamp(0.9rem, 2vw, 1rem);
    }
    
    .about-content {
        padding: 1rem 0;
    }
    
    .stats-overlay {
        padding: 1rem;
    }
    
    .stats-overlay-1 {
        top: 1rem;
        left: 1rem;
    }
    
    .stats-overlay-2 {
        bottom: 1rem;
        right: 1rem;
    }
    
    .stats-number {
        font-size: 1.8rem;
    }
    
    .stats-label {
        font-size: 0.75rem;
    }
    
    .feature-icon {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .feature-item h5 {
        font-size: 1rem;
    }
}

/* ============================================
   Animation Classes
   ============================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.8s ease-out;
}

/* Animation for slider content */
.main-slider .swiper-slide-active .col-lg-6[data-swiper-parallax="-300"],
.main-slider .swiper-slide-active .col-lg-6[data-swiper-parallax="300"] {
    animation: fadeInUp 0.8s ease-out;
}

/* ============================================
   3D Coverflow Gallery Styles
   ============================================ */
/* Gallery Section Specific */
.m5-section .section-header {
    margin-bottom: 1.5rem;
}

.coverflow-gallery-wrapper {
    position: relative;
    padding: 0.5rem 0;
    overflow: hidden;
}

.coverflow-swiper {
    width: 100%;
    padding-top: 50px;
    padding-bottom: 50px;
    overflow: visible;
}

.coverflow-swiper .swiper-slide {
    background-position: center;
    background-size: cover;
    width: 100%;
    height: 380px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.coverflow-slide {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.coverflow-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    user-select: none;
}

body.dark-theme .coverflow-image {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Navigation Buttons */
.coverflow-nav-next,
.coverflow-nav-prev {
    color: var(--primary-color);
    background: rgba(255, 255, 255, 0.9);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
}

/* Desktop position: دکمه‌ها (LTR) */
.coverflow-nav-next {
    right: 2rem;
    left: auto;
}

.coverflow-nav-prev {
    left: 2rem;
    right: auto;
}

/* RTL: next در سمت چپ، prev در سمت راست */
.m5-section[dir="rtl"] .coverflow-nav-next {
    left: 2rem;
    right: auto;
}

.m5-section[dir="rtl"] .coverflow-nav-prev {
    right: 2rem;
    left: auto;
}

.coverflow-nav-next:hover,
.coverflow-nav-prev:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-50%) scale(1.1);
}

.coverflow-nav-next::after,
.coverflow-nav-prev::after {
    font-size: 20px;
    font-weight: bold;
}

body.dark-theme .coverflow-nav-next,
body.dark-theme .coverflow-nav-prev {
    background: rgba(45, 45, 45, 0.9);
    color: var(--primary-light);
}

body.dark-theme .coverflow-nav-next:hover,
body.dark-theme .coverflow-nav-prev:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-50%) scale(1.1);
}

/* Pagination */
.coverflow-pagination {
    position: relative;
    margin-top: 2rem;
    bottom: auto !important;
    text-align: center;
}

.coverflow-pagination .swiper-pagination-bullet {
    width: 10px;
    height: 10px;
    background: #d3d3d3;
    opacity: 1;
    transition: all 0.3s ease;
    margin: 0 4px;
}

.coverflow-pagination .swiper-pagination-bullet-active {
    background: var(--primary-color);
    transform: scale(1);
}

body.dark-theme .coverflow-pagination .swiper-pagination-bullet {
    background: #666;
}

body.dark-theme .coverflow-pagination .swiper-pagination-bullet-active {
    background: var(--primary-light);
}

/* Hover Effect - Disabled */

/* Responsive */
@media (max-width: 1400px) {
    .coverflow-swiper .swiper-slide {
        height: 340px;
    }
}

@media (max-width: 1200px) {
    .coverflow-swiper .swiper-slide {
        height: 320px;
    }
}

@media (max-width: 992px) {
    .coverflow-swiper {
        padding-top: 40px;
        padding-bottom: 40px;
    }
    
    .coverflow-swiper .swiper-slide {
        height: 300px;
    }
}

@media (max-width: 768px) {
    .coverflow-swiper {
        padding-top: 35px;
        padding-bottom: 35px;
    }
    
    .coverflow-swiper .swiper-slide {
        height: 260px;
    }
    
    .coverflow-nav-next,
    .coverflow-nav-prev {
        width: 40px;
        height: 40px;
    }
    
    .coverflow-nav-next::after,
    .coverflow-nav-prev::after {
        font-size: 16px;
    }
}

@media (max-width: 576px) {
    .coverflow-swiper {
        padding-top: 30px;
        padding-bottom: 30px;
    }
    
    .coverflow-swiper .swiper-slide {
        height: 240px;
    }
}

@media (max-width: 480px) {
    .coverflow-swiper .swiper-slide {
        height: 220px;
    }
}

/* ============================================
   Footer Styles
   ============================================ */
.main-footer {
    background: var(--primary-dark);
    padding: 2.5rem 0 0;
    margin-top: 5rem;
    border-top: 1px solid var(--border-color);
    position: relative;
}

body.dark-theme .main-footer {
    background: var(--bg-secondary-dark);
    border-top-color: var(--border-dark);
}

.main-footer .container {
    max-width: var(--container-max-width);
}

.footer-widget {
    margin-bottom: 1rem;
}

.footer-logo-img {
    max-width: 150px;
    height: auto;
    filter: brightness(0) invert(1);
    transition: transform 0.3s ease;
}

body.dark-theme .footer-logo-img {
    filter: brightness(0) invert(1);
}

.footer-logo-img:hover {
    transform: scale(1.05);
}

.footer-description {
    color: var(--text-white);
    opacity: 0.9;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

body.dark-theme .footer-description {
    color: var(--text-secondary-dark);
    opacity: 1;
}

.footer-social {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1rem;
    margin-bottom: 1rem;
}

.social-link {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-color);
    color: var(--text-white);
    border-radius: 50%;
    text-decoration: none;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    font-size: 1.1rem;
    line-height: 1;
    padding: 0;
    margin: 0;
    position: relative;
    overflow: hidden;
}

.social-link::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0;
    transition: height 0.3s ease;
    z-index: 0;
}

.social-link i,
.social-link img {
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
}

.social-link i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    font-size: 1.1rem;
    vertical-align: middle;
    margin: 0;
    padding: 0;
}

.social-link img {
    display: block;
    width: 24px;
    height: 24px;
    margin: 0 auto;
    object-fit: contain;
    vertical-align: middle;
}

/* رنگ‌های برند شبکه‌های اجتماعی */
.social-link[data-social="telegram"]:hover::before {
    background-color: #0088cc;
    height: 100%;
}

.social-link[data-social="whatsapp"]:hover::before {
    background-color: #25D366;
    height: 100%;
}

.social-link[data-social="instagram"]:hover::before {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    height: 100%;
}

.social-link[data-social="facebook"]:hover::before {
    background-color: #1877F2;
    height: 100%;
}

.social-link[data-social="x"]:hover::before,
.social-link[data-social="twitter"]:hover::before {
    background-color: #000000;
    height: 100%;
}

.social-link[data-social="linkedin"]:hover::before {
    background-color: #0077B5;
    height: 100%;
}

.social-link[data-social="youtube"]:hover::before {
    background-color: #FF0000;
    height: 100%;
}

.social-link[data-social="aparat"]:hover::before {
    background-color: #FF6600;
    height: 100%;
}

.social-link[data-social="bale"]:hover::before {
    background-color: #00A4E4;
    height: 100%;
}

.social-link[data-social="eitaa"]:hover::before {
    background-color: #00A859;
    height: 100%;
}

.social-link[data-social="rubika"]:hover::before {
    background-color: #00C853;
    height: 100%;
}

.social-link[data-social="soroush"]:hover::before {
    background-color: #00BCD4;
    height: 100%;
}

.social-link[data-social="gap"]:hover::before {
    background-color: #FF6B6B;
    height: 100%;
}

.social-link[data-social="mobile"]:hover::before,
.social-link[data-social="phone"]:hover::before {
    background-color: #4CAF50;
    height: 100%;
}

.social-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

body.dark-theme .social-link {
    background: var(--primary-light);
}

.footer-title {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--text-white);
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.75rem;
    font-family: 'Hamishe', 'IRANSansWeb', sans-serif;
    display: inline-block;
    width: auto;
}

.footer-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--portfolio-tag-bg);
    opacity: 1;
    border-radius: 2px;
}

body.dark-theme .footer-title {
    color: var(--text-dark);
}

body.dark-theme .footer-title::after {
    background: var(--primary-light);
    opacity: 1;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
}

.footer-links a {
    color: var(--text-white);
    opacity: 0.85;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    font-size: 0.95rem;
    position: relative;
    overflow: hidden;
    width: 100%;
}

/* در LTR: padding از چپ */
[dir="ltr"] .footer-links a {
    padding-left: 0;
}

/* افکت صاعقه رنگی روی کل ردیف لینک (RTL) */
.footer-links a::before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(138, 43, 226, 0.4), rgba(0, 191, 255, 0.6), rgba(138, 43, 226, 0.4), transparent);
    background-size: 200% 100%;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -1;
    box-shadow: 0 0 10px rgba(138, 43, 226, 0.5);
}

/* در LTR: افکت از چپ به راست */
[dir="ltr"] .footer-links a::before {
    right: auto;
    left: 0;
    background: linear-gradient(90deg, transparent, rgba(138, 43, 226, 0.4), rgba(0, 191, 255, 0.6), rgba(138, 43, 226, 0.4), transparent);
}

.footer-links a:hover {
    color: var(--text-white);
    opacity: 1;
}

.footer-links a:hover::before {
    width: 100%;
    animation: lightning-sweep 0.5s ease-out;
}

@keyframes lightning-sweep {
    0% {
        background-position: 0% 50%;
    }
    100% {
        background-position: 100% 50%;
    }
}

.footer-links a:hover i {
    color: var(--primary-light);
    filter: drop-shadow(0 0 5px rgba(138, 43, 226, 0.8));
    transition: all 0.3s ease;
}

.footer-links a i {
    margin-left: 5px;           /* فاصله بیشتر بین آیکون و متن */
    display: inline-block;
    transition: all 0.3s ease;
}

body.dark-theme .footer-links a {
    color: var(--text-secondary-dark);
}

body.dark-theme .footer-links a:hover {
    color: var(--primary-light);
}

/* استایل برای آیتم‌های text در فوتر */
.footer-text-item {
    color: var(--text-white);
    opacity: 0.85;
    font-size: 0.95rem;
    display: flex;            /* هر آیتم در یک خط جدا و هم‌راستای آیکون و متن */
    align-items: center;
    margin-bottom: 0.75rem;
    position: relative;
    transition: all 0.3s ease;
    overflow: hidden;
}

.footer-text-item i {
    margin-left: 5px;         /* فاصله کمی بیشتر بین آیکون و متن در حالت RTL */
    display: inline-block;
    transition: all 0.3s ease;
}

body.dark-theme .footer-text-item {
    color: var(--text-secondary-dark);
}

/* افکت صاعقه رنگی روی کل ردیف (RTL) */
.footer-text-item::before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(138, 43, 226, 0.4), rgba(0, 191, 255, 0.6), rgba(138, 43, 226, 0.4), transparent);
    background-size: 200% 100%;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -1;
    box-shadow: 0 0 10px rgba(138, 43, 226, 0.5);
}

/* در LTR: افکت از چپ به راست */
[dir="ltr"] .footer-text-item::before {
    right: auto;
    left: 0;
    background: linear-gradient(90deg, transparent, rgba(138, 43, 226, 0.4), rgba(0, 191, 255, 0.6), rgba(138, 43, 226, 0.4), transparent);
}

.footer-text-item:hover {
    color: var(--text-white);
    opacity: 1;
}

.footer-text-item:hover::before {
    width: 100%;
    animation: lightning-sweep 0.5s ease-out;
}

.footer-text-item:hover i {
    color: var(--primary-light);
    filter: drop-shadow(0 0 5px rgba(138, 43, 226, 0.8));
    transition: all 0.3s ease;
}

.footer-contact {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-contact li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1rem;
    color: var(--text-white);
    opacity: 0.85;
    font-size: 0.95rem;
    line-height: 1.6;
}

.footer-contact li i {
    color: var(--text-white);
    opacity: 0.9;
    font-size: 1.2rem;
    margin-left: 0.75rem;
    margin-top: 0.2rem;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.footer-contact li span {
    flex: 1;
}

.footer-contact li a {
    color: var(--text-white);
    opacity: 0.85;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    width: 100%;
}

/* افکت صاعقه رنگی روی کل ردیف لینک‌های تماس (RTL) */
.footer-contact li a::before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(138, 43, 226, 0.4), rgba(0, 191, 255, 0.6), rgba(138, 43, 226, 0.4), transparent);
    background-size: 200% 100%;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -1;
    box-shadow: 0 0 10px rgba(138, 43, 226, 0.5);
}

/* در LTR: افکت از چپ به راست */
[dir="ltr"] .footer-contact li a::before {
    right: auto;
    left: 0;
    background: linear-gradient(90deg, transparent, rgba(138, 43, 226, 0.4), rgba(0, 191, 255, 0.6), rgba(138, 43, 226, 0.4), transparent);
}

.footer-contact li a:hover {
    color: var(--text-white);
    opacity: 1;
}

.footer-contact li a:hover::before {
    width: 100%;
    animation: lightning-sweep 0.5s ease-out;
}

.footer-contact li:hover i {
    color: var(--primary-light);
    filter: drop-shadow(0 0 5px rgba(138, 43, 226, 0.8));
    transition: all 0.3s ease;
}

body.dark-theme .footer-contact li {
    color: var(--text-secondary-dark);
}

body.dark-theme .footer-contact li i {
    color: var(--primary-light);
}

body.dark-theme .footer-contact li a {
    color: var(--text-secondary-dark);
}

body.dark-theme .footer-contact li a:hover {
    color: var(--primary-light);
}

.footer-bottom {
    margin-top: 2rem;
    padding-top: 0.5rem;
    padding-bottom: 1rem;
    border-top: 1px solid var(--portfolio-tag-bg);
    opacity: 0.8;
}

body.dark-theme .footer-bottom {
    border-top-color: var(--portfolio-tag-bg);
    opacity: 1;
}

.footer-bottom .footer-copyright,
.footer-copyright {
    color: var(--text-white);
    opacity: 0.9;
    font-size: 0.95rem;
    font-weight: 500;
    margin: 0;
    text-align: right;
    direction: rtl;
    width: 100%;
}

.footer-bottom .footer-copyright *,
.footer-copyright * {
    text-align: inherit;
    color: var(--text-white);
    opacity: 0.9;
}

.footer-bottom .footer-copyright strong,
.footer-copyright strong {
    color: var(--text-white) !important;
    opacity: 0.9 !important;
    font-weight: 600;
}

body.dark-theme .footer-copyright {
    color: var(--text-secondary-dark);
    opacity: 1;
}

body.dark-theme .footer-copyright strong {
    color: var(--primary-light);
    opacity: 1;
}

.footer-bottom-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin: 0.5rem 0 0;
}

.footer-bottom .footer-credits,
.footer-credits {
    color: var(--text-white);
    opacity: 0.9;
    font-size: 0.9rem;
    font-weight: 500;
    margin: 0;
    text-align: left;
    direction: ltr;
    width: 100%;
}

.footer-bottom .footer-credits *,
.footer-credits * {
    text-align: inherit;
    color: var(--text-white);
    opacity: 0.9;
}

.footer-bottom .footer-credits strong,
.footer-credits strong {
    color: var(--text-white) !important;
    opacity: 0.9 !important;
    font-weight: 600;
}

body.dark-theme .footer-credits {
    color: var(--text-secondary-dark);
    opacity: 1;
}

body.dark-theme .footer-credits strong {
    color: var(--primary-light);
    opacity: 1;
}

.footer-bottom .footer-bottom-links a,
.footer-bottom-links a {
    color: var(--text-white) !important;
    opacity: 0.9 !important;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.3s ease, opacity 0.3s ease;
}

.footer-bottom .footer-bottom-links a:hover,
.footer-bottom-links a:hover {
    color: var(--text-white) !important;
    opacity: 1 !important;
    text-decoration: underline;
}

.footer-bottom .footer-bottom-links .separator,
.footer-bottom-links .separator {
    color: var(--text-white) !important;
    opacity: 0.9 !important;
    margin: 0 0.25rem;
    font-weight: 400;
}

body.dark-theme .footer-bottom-links a {
    color: var(--text-secondary-dark);
}

body.dark-theme .footer-bottom-links a:hover {
    color: var(--primary-light);
}

body.dark-theme .footer-bottom-links .separator {
    color: var(--text-secondary-dark);
}

/* ============================================
   Breadcrumb Styles
   ============================================ */
.breadcrumb {
    background-color: transparent;
    padding: 0;
    margin-bottom: 1rem;
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    align-items: center;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "/";
    display: inline-block;
    padding: 0 0.5rem;
    color: var(--text-secondary);
    font-weight: normal;
}

body.dark-theme .breadcrumb-item + .breadcrumb-item::before {
    color: var(--text-secondary-dark);
}

.breadcrumb-item a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
}

.breadcrumb-item a:hover {
    color: var(--primary-dark);
    text-decoration: none;
}

body.dark-theme .breadcrumb-item a {
    color: var(--primary-light);
}

body.dark-theme .breadcrumb-item a:hover {
    color: var(--primary-color);
}

.breadcrumb-item.active {
    color: var(--text-secondary);
    font-weight: normal;
}

body.dark-theme .breadcrumb-item.active {
    color: var(--text-secondary-dark);
}

/* Breadcrumb in Article Header */
.article-header .breadcrumb {
    background-color: transparent;
    padding: 0;
    margin: 0;
}

.article-header .breadcrumb-item a {
    color: var(--text-white);
    opacity: 0.9;
}

.article-header .breadcrumb-item a:hover {
    color: var(--text-white);
    opacity: 1;
}

.article-header .breadcrumb-item.active {
    color: var(--text-white);
    opacity: 1;
}

.article-header .breadcrumb-item + .breadcrumb-item::before {
    color: var(--text-white);
    opacity: 0.7;
}

/* ============================================
   Single Article Sidebar Styles
   ============================================ */
.sidebar-sticky {
    position: sticky;
    top: 100px;
}

.sidebar-widget {
    border-radius: 0.5rem;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease;
}

.sidebar-widget:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

body.dark-theme .sidebar-widget {
    background-color: var(--bg-secondary-dark);
    border-color: var(--border-dark);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

body.dark-theme .sidebar-widget:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.sidebar-widget-header {
    background-color: var(--primary-color);
    color: var(--text-white);
    border: none;
    padding: 1rem;
    font-weight: 600;
    min-height: 60px;
    display: flex;
    align-items: center;
}

body.dark-theme .sidebar-widget-header {
    background-color: var(--primary-dark);
}

.sidebar-widget-header h5 {
    color: var(--text-white);
    margin: 0;
    font-size: 1.1rem;
    line-height: 1.2;
}

/* Article Main Card Header - Same padding and height as sidebar */
.article-main-card .card-header.sidebar-widget-header {
    padding: 1rem;
    min-height: 60px;
    display: flex;
    align-items: center;
}

/* Article Main Card Image - Rounded corners only at bottom */
.article-main-card .card-img-top {
    border-radius: 0;
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    border-bottom-left-radius: 0.5rem;
    border-bottom-right-radius: 0.5rem;
}

/* Article Main Card Body - Match sidebar padding */
.article-main-card .card-body {
    padding: 1rem;
}

/* Responsive Typography for Article */
.article-main-card .card-title {
    font-size: clamp(1.25rem, 3vw, 1.75rem);
    line-height: 1.3;
    margin-bottom: 1rem;
}

.article-main-card .text-muted {
    font-size: clamp(0.875rem, 2vw, 1rem);
}

.article-main-card .alert-light {
    font-size: clamp(0.9rem, 2.2vw, 1.05rem);
    line-height: 2;
}

.article-main-card .article-content {
    font-size: clamp(1rem, 2.5vw, 1.125rem);
    line-height: 2;
}

.article-main-card .article-content p {
    margin-bottom: 1.25rem;
    font-size: inherit;
    line-height: 2;
}

.article-main-card .article-content h1,
.article-main-card .article-content h2,
.article-main-card .article-content h3,
.article-main-card .article-content h4,
.article-main-card .article-content h5,
.article-main-card .article-content h6 {
    font-size: clamp(1.25rem, 3vw, 1.75rem);
    line-height: 1.4;
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.article-main-card .article-content h2 {
    font-size: clamp(1.15rem, 2.8vw, 1.6rem);
}

.article-main-card .article-content h3 {
    font-size: clamp(1.05rem, 2.5vw, 1.4rem);
}

.article-main-card .article-content h4 {
    font-size: clamp(1rem, 2.2vw, 1.25rem);
}

.article-main-card .article-content ul,
.article-main-card .article-content ol {
    font-size: inherit;
    line-height: inherit;
    margin-bottom: 1rem;
    padding-right: 1.5rem;
}

.article-main-card .article-content li {
    margin-bottom: 0.5rem;
    font-size: inherit;
    line-height: inherit;
}

.article-main-card .article-content blockquote {
    font-size: clamp(1rem, 2.5vw, 1.125rem);
    line-height: 1.7;
    margin: 1.5rem 0;
    padding: 1rem 1.5rem;
    border-right: 4px solid var(--primary-color);
    background-color: var(--bg-secondary);
}

body.dark-theme .article-main-card .article-content blockquote {
    background-color: var(--bg-dark);
    border-right-color: var(--primary-light);
}

.article-main-card .article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 1.5rem 0;
}

.article-main-card .article-content a {
    color: var(--primary-color);
    text-decoration: underline;
    transition: color 0.3s ease;
}

.article-main-card .article-content a:hover {
    color: var(--primary-dark);
}

body.dark-theme .article-main-card .article-content a {
    color: var(--primary-light);
}

body.dark-theme .article-main-card .article-content a:hover {
    color: var(--primary-color);
}

/* Badge responsive */
.article-main-card .badge {
    font-size: clamp(0.75rem, 1.8vw, 0.875rem);
    padding: 0.4rem 0.75rem;
}

/* Responsive adjustments for smaller screens */
@media (max-width: 576px) {
    .article-main-card .card-body {
        padding: 0.75rem;
    }
    
    .article-main-card .card-title {
        font-size: 1.25rem;
        margin-bottom: 0.75rem;
    }
    
    .article-main-card .text-muted {
        font-size: 0.875rem;
    }
    
    .article-main-card .article-content {
        font-size: 1rem;
    }
    
    .article-main-card .article-content h1,
    .article-main-card .article-content h2,
    .article-main-card .article-content h3 {
        font-size: 1.25rem;
        margin-top: 1rem;
        margin-bottom: 0.75rem;
    }
}

/* Sidebar Widget Card Body - Match article padding */
.sidebar-widget .card-body {
    padding: 1rem;
}

.related-articles-list {
    border: none;
    margin: 0;
    padding: 0;
}

.related-article-item {
    border: none;
    border-bottom: 1px solid var(--border-color);
    padding: 0.75rem 0;
    transition: background-color 0.3s ease;
}

.related-article-item:first-child {
    padding-top: 0;
}

.related-article-item:last-child {
    padding-bottom: 0;
    border-bottom: none;
}

.related-article-item:last-child {
    border-bottom: none;
}

.related-article-item:hover {
    background-color: var(--bg-secondary);
}

body.dark-theme .related-article-item {
    border-bottom-color: var(--border-dark);
    background-color: transparent;
}

body.dark-theme .related-article-item:hover {
    background-color: var(--bg-dark);
}

.related-article-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 0.5rem;
    flex-shrink: 0;
}

.related-article-title {
    color: var(--text-color);
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.related-article-item:hover .related-article-title {
    color: var(--primary-color);
}

body.dark-theme .related-article-title {
    color: var(--text-dark);
}

body.dark-theme .related-article-item:hover .related-article-title {
    color: var(--primary-light);
}

.sidebar-ad-box {
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--bg-secondary);
    border-radius: 0.5rem;
}

body.dark-theme .sidebar-ad-box {
    background-color: var(--bg-dark);
}

@media (max-width: 991.98px) {
    .sidebar-sticky {
        position: static;
    }
    
    .sidebar-widget {
        margin-top: 2rem;
    }
}

/* ============================================
   Module 12: Blog Articles Section
   ============================================ */
.m12-section {
    /* background-color: var(--bg-color); */
    padding: 4rem 0;
}

body.dark-theme .m12-section {
    /* background-color: var(--bg-dark); */
}

.m12-article-card {
    margin-bottom: 3rem;
    border-radius: 12px;
    overflow: hidden;
}

.m12-article-card .col-md-7 {
    display: flex;
    align-items: center;
    min-height: 400px;
    position: relative;
}

.m12-article-image {
    width: 100%;
    height: 100%;
    min-height: 400px;
    overflow: hidden;
    position: relative;
    z-index: 1;
    border-radius: 12px;
}

.m12-article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.m12-article-card:hover .m12-article-image img {
    transform: scale(1.05);
}

.m12-placeholder-image {
    width: 100%;
    height: 100%;
    min-height: 500px;
    background-color: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
}

.m12-placeholder-image i {
    font-size: 4rem;
}

body.dark-theme .m12-placeholder-image {
    background-color: var(--bg-secondary-dark);
    color: var(--text-secondary-dark);
}

.m12-article-content {
    width: 100%;
    background-color: var(--bg-color);
    padding: 2rem 4rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    max-height: 75%;
    margin: auto;
    box-shadow: 0 2px 10px var(--shadow-light);
    position: relative;
    z-index: 10;
    border-radius: 12px;
    transition: background-color 0.3s ease;
}

body.dark-theme .m12-article-content {
    background-color: var(--bg-secondary-dark);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Content overlap classes */
.m12-content-overlap-left {
    left: 50px;
}

.m12-content-overlap-right {
    right: 50px;
}

/* Reversed layout (image right, content left) */
.m12-article-reversed .col-md-7 {
    display: flex;
    align-items: center;
    min-height: 400px;
    position: relative;
}

.m12-article-reversed .m12-article-image {
    border-radius: 12px;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .m12-article-card {
        flex-direction: column;
        position: relative;
    }
    
    .m12-article-card .col-md-5,
    .m12-article-card .col-md-7 {
        width: 100%;
        max-width: 100%;
        flex: 0 0 100%;
    }
    
    .m12-article-image {
        min-height: 400px;
        overflow: visible;
        border-radius: 12px;
        position: relative;
    }
    
    .m12-article-card .col-md-7 {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 0 1rem;
        margin-top: -50px;
        z-index: 10;
        pointer-events: none;
    }
    
    .m12-article-content {
        padding: 2rem;
        min-height: auto;
        width: 100%;
        max-width: 100%;
        margin: 0 auto;
        border-radius: 12px;
        position: relative;
        z-index: 10;
        pointer-events: auto;
    }
    
    .m12-content-overlap-left,
    .m12-content-overlap-right {
        left: auto !important;
        right: auto !important;
    }
    
    /* Ensure reversed layout also stacks vertically on mobile */
    .m12-article-reversed .col-md-7 {
        order: 2;
    }
    
    .m12-article-reversed .col-md-5 {
        order: 1;
    }
}

/* Mobile specific adjustments */
@media (max-width: 576px) {
    .m12-article-card {
        margin-bottom: 2rem;
        overflow: visible;
    }
    
    .m12-article-card .col-md-5 {
        padding: 0;
        margin: 0;
    }
    
    .m12-article-image {
        min-height: 300px;
        overflow: visible;
        border-radius: 12px;
        margin: 0;
    }
    
    .m12-article-card .col-md-7 {
        padding: 0;
        margin: 0;
        margin-top: -50px;
        width: 100%;
        max-width: 100%;
    }
    
    .m12-article-content {
        padding: 1.5rem;
        width: calc(100% - 1rem);
        max-width: calc(100% - 1rem);
        margin: 0 auto;
        box-sizing: border-box;
    }
    
    .m12-content-overlap-left,
    .m12-content-overlap-right {
        left: 0 !important;
        right: 0 !important;
    }
}

.m12-article-date {
    font-size: 0.85rem;
    color: #ffa366;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 1.5rem;
}

body.dark-theme .m12-article-date {
    color: #ffa366;
}

.m12-article-title {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 1rem;
    line-height: 1.15;
    letter-spacing: -0.5px;
    transition: color 0.3s ease;
}

body.dark-theme .m12-article-title {
    color: var(--text-dark);
}

body.dark-theme .m12-article-author {
    color: #999999;
}

body.dark-theme .m12-article-summary,
body.dark-theme .m12-article-content-text {
    color: #b0b0b0;
}

.m12-article-author {
    font-size: 0.9rem;
    color: #666666;
    margin-bottom: 2rem;
    font-style: normal;
    font-weight: 400;
}

body.dark-theme .m12-article-author {
    color: var(--text-secondary-dark);
}

.m12-article-summary,
.m12-article-content-text {
    font-size: 1rem;
    line-height: 1.75;
    color: #4a4a4a;
    margin-bottom: 2rem;
    font-weight: 400;
}

body.dark-theme .m12-article-summary,
body.dark-theme .m12-article-content-text {
    color: var(--text-dark);
}

.m12-article-link {
    margin-top: auto;
}

.m12-read-more {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

.m12-read-more:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

body.dark-theme .m12-read-more {
    color: var(--primary-light);
}

body.dark-theme .m12-read-more:hover {
    color: var(--primary);
}

/* Responsive Styles for Module 12 */
@media (max-width: 992px) {
    .m12-article-content {
        width: 100%;
        padding: 2rem;
    }
    
    .m12-article-title {
        font-size: 2rem;
    }
}

@media (max-width: 768px) {
    .m12-section {
        padding: 3rem 0;
    }
    
    .m12-article-image {
        min-height: 400px;
    }
    
    .m12-article-content {
        width: 100%;
        position: relative;
        padding: 2rem;
        background-color: var(--bg-color);
    }
    
    body.dark-theme .m12-article-content {
        background-color: var(--bg-secondary-dark);
    }
    
    .m12-article-title {
        font-size: 1.75rem;
    }
    
    .m12-article-date {
        font-size: 0.85rem;
    }
}

@media (max-width: 576px) {
    .m12-article-image {
        min-height: 350px;
    }
    
    .m12-article-content {
        padding: 1.5rem;
    }
    
    .m12-article-title {
        font-size: 1.5rem;
    }
    
    .m12-article-summary,
    .m12-article-content-text {
        font-size: 0.95rem;
    }
}

/* ============================================
   Module 12: Modern Grid Layout (New Design)
   ============================================ */
.m12-article-card-modern {
    border-radius: 12px 60px 12px 60px;
    overflow: hidden;
    background-color: var(--bg-color);
    box-shadow: 0 2px 10px var(--shadow-light);
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.m12-article-card-modern:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

body.dark-theme .m12-article-card-modern {
    background-color: var(--bg-secondary-dark);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

body.dark-theme .m12-article-card-modern:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.m12-article-image-modern {
    width: 100%;
    height: 250px;
    overflow: hidden;
    position: relative;
    border-radius: 12px 60px 12px 60px;
}

.m12-article-image-modern img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    border-radius: 12px 60px 12px 60px;
}

.m12-article-card-modern:hover .m12-article-image-modern img {
    transform: scale(1.1);
}

.m12-placeholder-image-modern {
    width: 100%;
    height: 100%;
    background-color: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
}

.m12-placeholder-image-modern i {
    font-size: 3rem;
}

body.dark-theme .m12-placeholder-image-modern {
    background-color: var(--bg-secondary-dark);
    color: var(--text-secondary-dark);
}

.m12-article-content-modern {
    padding: 1.25rem;
    padding-top: 1.25rem;
    padding-bottom: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.m12-article-footer-modern {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding-top: 0.25rem;
}

.m12-article-date-modern {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin: 0;
    white-space: nowrap;
    display: flex;
    align-items: center;
    padding-top: 1.25rem;
    gap: 0.4rem;
}

.m12-article-date-modern i {
    font-size: 0.85rem;
}

body.dark-theme .m12-article-date-modern {
    color: var(--text-secondary-dark);
}

.m12-article-title-modern {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 1rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.3s ease;
}

body.dark-theme .m12-article-title-modern {
    color: var(--text-dark);
}

.m12-article-summary-modern {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 0.5rem;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

body.dark-theme .m12-article-summary-modern {
    color: var(--text-secondary-dark);
}

.m12-article-link-modern {
    margin: 0;
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.m12-read-more-modern {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background-color: var(--primary-color);
    color: #fff;
    font-weight: 500;
    text-decoration: none;
    padding: 0.75rem 1.5rem;
    border-radius: 12px 60px 12px 60px;
    transition: background-color 0.3s ease, gap 0.3s ease, transform 0.3s ease;
    box-shadow: 0 2px 8px rgba(103, 41, 219, 0.2);
}

.m12-read-more-modern:hover {
    background-color: var(--primary-dark);
    color: #fff;
    gap: 0.75rem;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(103, 41, 219, 0.3);
}

.m12-read-more-modern i {
    font-size: 0.9rem;
    transition: transform 0.3s ease;
}

.m12-read-more-modern:hover i {
    transform: translateX(-3px);
}

body.dark-theme .m12-read-more-modern {
    background-color: var(--primary-light);
    color: #fff;
    box-shadow: 0 2px 8px rgba(103, 41, 219, 0.3);
}

body.dark-theme .m12-read-more-modern:hover {
    background-color: var(--primary-color);
    color: #fff;
    box-shadow: 0 4px 12px rgba(103, 41, 219, 0.4);
}

/* Responsive for Modern Grid Layout */
@media (max-width: 768px) {
    .m12-article-image-modern {
        height: 200px;
    }
    
    .m12-article-title-modern {
        font-size: 1.25rem;
    }
    
    .m12-article-content-modern {
        padding: 1.25rem;
    }
}

@media (max-width: 576px) {
    .m12-article-image-modern {
        height: 180px;
    }
    
    .m12-article-title-modern {
        font-size: 1.1rem;
    }
    
    .m12-article-content-modern {
        padding: 1rem;
    }
    
    .m12-article-summary-modern {
        font-size: 0.9rem;
    }
    
    .m12-article-footer-modern {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
    
    .m12-article-link-modern {
        width: 100%;
        justify-content: flex-end;
    }
    
    .m12-article-date-modern {
        align-self: flex-start;
    }
}

/* Responsive Footer */
@media (max-width: 992px) {
    .main-footer {
        padding: 2rem 0 0;
        margin-top: 4rem;
    }
    
    .footer-widget {
        margin-bottom: 1.5rem;
    }
    
    .footer-bottom {
        text-align: center;
    }
    
    .footer-bottom-links {
        justify-content: center;
        margin-top: 1rem;
    }
}

@media (max-width: 768px) {
    .main-footer {
        padding: 2rem 0 0;
        margin-top: 3rem;
    }
    
    .footer-logo-img {
        max-width: 120px;
    }
    
    .footer-title {
        font-size: 1.1rem;
    }
    
    .footer-social {
        gap: 0.75rem;
    }
    
    .social-link {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }
}

@media (max-width: 576px) {
    .main-footer {
        padding: 2rem 0 0;
    }
    
    .footer-bottom {
        margin-top: 2rem;
        padding-top: 1.5rem;
    }
    
    .footer-copyright {
        font-size: 0.85rem;
        margin-bottom: 1rem;
    }
    
    .footer-bottom-links {
        flex-direction: column;
        gap: 0.25rem;
    }
    
    .footer-bottom-links .separator {
        display: none;
    }
}

/* ============================================
   Articles Page Styles
   صفحه مقالات (/articles/index.php)
   ============================================ */

/* Article Cards */
.article-card {
    border-radius: 0.5rem;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
}
.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}
.article-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
}
.category-badge {
    display: inline-block;
    padding: 0.2rem 0.5rem;
    border-radius: 1rem;
    font-size: 0.7rem;
    margin: 0.15rem;
}
.pagination {
    justify-content: center;
}

/* Category Tree (Sidebar) */
.category-tree {
    list-style: none;
    padding: 0;
    margin: 0;
}
.category-tree .category-item {
    transition: all 0.3s ease;
    margin: 0 !important;
    padding: 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}
body.dark-only .category-tree .category-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.category-tree .category-item:last-child {
    border-bottom: none;
}
.category-tree .category-item[data-level="0"] {
    padding-right: 0;
}
.category-tree .category-item[data-level="1"] {
    padding-right: 1.25rem;
}
.category-tree .category-item[data-level="2"] {
    padding-right: 2rem;
}
.category-tree .category-item[data-level="3"] {
    padding-right: 2.75rem;
}
.category-tree .category-item > a {
    display: block;
    padding: 0.875rem 0;
    color: var(--text-color);
    text-decoration: none;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}
.category-tree .category-item > a:hover {
    color: var(--primary-color);
    padding-right: 0.5rem;
}
.category-tree .category-item > a i {
    margin-left: 0.5rem;
    font-size: 0.85rem;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}
.category-tree .category-item > a:hover i {
    opacity: 1;
}
.category-toggle {
    color: var(--text-color);
    font-size: 0.875rem;
    min-width: 24px;
    width: 24px;
    height: 24px;
    text-align: center;
    border: none;
    background: none;
    margin-right: 0;
    margin-left: auto;
    order: 2;
    padding: 0;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
}
.category-toggle:hover {
    color: var(--primary-color);
    background-color: rgba(var(--primary-color-rgb), 0.1);
}
.category-toggle .category-icon {
    transition: transform 0.3s ease;
    display: inline-block;
    transform-origin: center;
    font-size: 0.75rem;
}
button.category-toggle[aria-expanded="true"] > .category-icon {
    transform: rotate(180deg) !important;
}
button.category-toggle[aria-expanded="false"] > .category-icon {
    transform: rotate(0deg) !important;
}
.category-tree .collapse {
    transition: height 0.3s ease;
}
.category-tree .collapse ul {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding-right: 0;
}
.category-item-with-children {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 0.875rem 0;
}
.category-link-wrapper {
    flex-grow: 1;
    order: 1;
}
.category-link-wrapper > a {
    display: block;
    color: var(--text-color);
    text-decoration: none;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    padding: 0;
}
.category-link-wrapper > a:hover {
    color: var(--primary-color);
    padding-right: 0.5rem;
}
.category-link-wrapper > a i {
    margin-left: 0.5rem;
    font-size: 0.85rem;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}
.category-link-wrapper > a:hover i {
    opacity: 1;
}

/* Articles Cover Image */
.articles-cover-container {
    width: 100%;
    overflow: hidden;
    border-radius: 0.75rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}
.articles-cover-image {
    width: 100%;
    height: auto;
    max-height: 300px;
    object-fit: cover;
    display: block;
}
body.dark-theme .articles-cover-container {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* ============================================
   Comments Section Styles
   ============================================ */
.comments-section {
    margin-top: 2rem;
}

.comments-title {
    color: var(--text-color);
    font-weight: 700;
    font-size: clamp(1.25rem, 3vw, 1.5rem);
}

body.dark-theme .comments-title {
    color: var(--text-dark);
}

.add-comment-form {
    margin-bottom: 2rem;
}

.comment-form .form-control {
    background-color: var(--bg-color);
    border-color: var(--border-color);
    color: var(--text-color);
    transition: all 0.3s ease;
}

body.dark-theme .comment-form .form-control {
    background-color: var(--bg-secondary-dark);
    border-color: var(--border-dark);
    color: var(--text-dark);
}

.comment-form .form-control:focus {
    background-color: var(--bg-color);
    border-color: var(--primary-color);
    color: var(--text-color);
    box-shadow: 0 0 0 0.2rem rgba(103, 41, 219, 0.25);
}

body.dark-theme .comment-form .form-control:focus {
    background-color: var(--bg-secondary-dark);
    border-color: var(--primary-light);
    color: var(--text-dark);
    box-shadow: 0 0 0 0.2rem rgba(167, 139, 250, 0.25);
}

.comment-form .form-text {
    color: var(--text-secondary);
}

body.dark-theme .comment-form .form-text {
    color: var(--text-secondary-dark);
}

.comments-list {
    margin-top: 1.5rem;
}

.comment-item {
    background-color: var(--bg-color);
    border-color: var(--border-color) !important;
    color: var(--text-color);
    transition: all 0.3s ease;
    margin-bottom: 1rem;
}

body.dark-theme .comment-item {
    background-color: var(--bg-secondary-dark);
    border-color: var(--border-dark) !important;
    color: var(--text-dark);
}

.comment-item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

body.dark-theme .comment-item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.comment-pending {
    background-color: rgba(255, 193, 7, 0.1) !important;
}

body.dark-theme .comment-pending {
    background-color: rgba(255, 193, 7, 0.15) !important;
}

.comment-header {
    margin-bottom: 0.75rem;
}

.comment-author strong {
    color: var(--text-color);
    font-weight: 600;
}

body.dark-theme .comment-author strong {
    color: var(--text-dark);
}

.comment-content {
    color: var(--text-color);
    line-height: 1.7;
    margin-bottom: 0.75rem;
}

body.dark-theme .comment-content {
    color: var(--text-dark);
}

.comment-footer {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-color);
}

body.dark-theme .comment-footer {
    border-top-color: var(--border-dark);
}

.comment-actions .btn-link {
    color: var(--text-secondary);
    text-decoration: none;
    padding: 0.25rem 0.5rem;
    transition: all 0.3s ease;
}

body.dark-theme .comment-actions .btn-link {
    color: var(--text-secondary-dark);
}

.comment-actions .btn-link:hover {
    color: var(--primary-color);
    text-decoration: none;
}

body.dark-theme .comment-actions .btn-link:hover {
    color: var(--primary-light);
}

.comment-actions .btn-link.text-primary {
    color: var(--primary-color) !important;
}

body.dark-theme .comment-actions .btn-link.text-primary {
    color: var(--primary-light) !important;
}

.comment-actions .btn-link.text-danger {
    color: #dc3545 !important;
}

.reply-item {
    background-color: var(--bg-color);
    border-color: var(--primary-color) !important;
    border-width: 3px !important;
    margin-top: 0.75rem;
    padding: 0.75rem;
    border-radius: 0.5rem;
}

body.dark-theme .reply-item {
    background-color: var(--bg-secondary-dark);
    border-color: var(--primary-light) !important;
}

.reply-author strong {
    color: var(--primary-color);
    font-weight: 600;
}

body.dark-theme .reply-author strong {
    color: var(--primary-light);
}

.reply-content {
    color: var(--text-secondary);
    line-height: 1.6;
}

body.dark-theme .reply-content {
    color: var(--text-secondary-dark);
}

.reply-form-container {
    margin-top: 1rem;
}

.reply-form {
    background-color: rgba(103, 41, 219, 0.05);
    border-color: var(--primary-color) !important;
    border-radius: 0.5rem;
}

body.dark-theme .reply-form {
    background-color: rgba(167, 139, 250, 0.1);
    border-color: var(--primary-light) !important;
}

.reply-form .form-control {
    background-color: var(--bg-color);
    border-color: var(--border-color);
    color: var(--text-color);
}

body.dark-theme .reply-form .form-control {
    background-color: var(--bg-secondary-dark);
    border-color: var(--border-dark);
    color: var(--text-dark);
}

.reply-form .form-control:focus {
    background-color: var(--bg-color);
    border-color: var(--primary-color);
    color: var(--text-color);
}

body.dark-theme .reply-form .form-control:focus {
    background-color: var(--bg-secondary-dark);
    border-color: var(--primary-light);
    color: var(--text-dark);
}

.replies-container {
    margin-top: 1rem;
    padding-right: 1rem;
}

#loadMoreContainer {
    margin-top: 2rem;
}

#loadMoreBtn {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

body.dark-theme #loadMoreBtn {
    border-color: var(--primary-light);
    color: var(--primary-light);
}

#loadMoreBtn:hover {
    background-color: var(--primary-color);
    color: var(--text-white);
    border-color: var(--primary-color);
}

body.dark-theme #loadMoreBtn:hover {
    background-color: var(--primary-light);
    color: var(--text-white);
    border-color: var(--primary-light);
}

/* ============================================
   Article Page Buttons (Submit Comment & Back)
   ============================================ */
.add-comment-form .btn-primary,
.text-center .btn-primary {
    background-color: var(--primary-dark) !important;
    color: var(--text-white) !important;
    border: none !important;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
}

body.dark-theme .add-comment-form .btn-primary,
body.dark-theme .text-center .btn-primary {
    background-color: var(--primary-light) !important;
    color: var(--text-white) !important;
}

.add-comment-form .btn-primary:hover,
.text-center .btn-primary:hover {
    background-color: var(--primary-color) !important;
    color: var(--text-white) !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(103, 41, 219, 0.3);
}

body.dark-theme .add-comment-form .btn-primary:hover,
body.dark-theme .text-center .btn-primary:hover {
    background-color: var(--primary-color) !important;
    color: var(--text-white) !important;
    box-shadow: 0 4px 12px rgba(167, 139, 250, 0.4);
}

.add-comment-form .btn-primary i,
.text-center .btn-primary i {
    color: var(--text-white) !important;
}

/* Reply Form Submit Button */
.reply-form .btn-primary,
.reply-actions .btn-primary {
    background-color: var(--primary-dark) !important;
    color: var(--text-white) !important;
    border: none !important;
    font-weight: 600;
    transition: all 0.3s ease;
}

body.dark-theme .reply-form .btn-primary,
body.dark-theme .reply-actions .btn-primary {
    background-color: var(--primary-light) !important;
    color: var(--text-white) !important;
}

.reply-form .btn-primary:hover,
.reply-actions .btn-primary:hover {
    background-color: var(--primary-color) !important;
    color: var(--text-white) !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(103, 41, 219, 0.3);
}

body.dark-theme .reply-form .btn-primary:hover,
body.dark-theme .reply-actions .btn-primary:hover {
    background-color: var(--primary-color) !important;
    color: var(--text-white) !important;
    box-shadow: 0 4px 12px rgba(167, 139, 250, 0.4);
}

.reply-form .btn-primary i,
.reply-actions .btn-primary i {
    color: var(--text-white) !important;
}

/* ============================================
   SweetAlert2 Custom Styles
   ============================================ */
.swal-popup-custom {
    font-family: 'Hamishe', 'IRANSansWeb', sans-serif !important;
    border-radius: 1rem !important;
    background-color: var(--bg-color) !important;
    color: var(--text-color) !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2) !important;
}

body.dark-theme .swal-popup-custom {
    background-color: var(--bg-secondary-dark) !important;
    color: var(--text-dark) !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5) !important;
}

.swal-title-custom {
    font-family: 'Hamishe', 'IRANSansWeb', sans-serif !important;
    font-weight: 700 !important;
    font-size: 1.5rem !important;
    color: var(--text-color) !important;
    margin-bottom: 1rem !important;
}

body.dark-theme .swal-title-custom {
    color: var(--text-dark) !important;
}

.swal-content-custom {
    font-family: 'Hamishe', 'IRANSansWeb', sans-serif !important;
    color: var(--text-secondary) !important;
    font-size: 1rem !important;
    line-height: 1.7 !important;
}

body.dark-theme .swal-content-custom {
    color: var(--text-secondary-dark) !important;
}

.swal-confirm-custom {
    font-family: 'Hamishe', 'IRANSansWeb', sans-serif !important;
    font-weight: 600 !important;
    padding: 0.75rem 2rem !important;
    border-radius: 0.5rem !important;
    transition: all 0.3s ease !important;
}

.swal-confirm-custom:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
}

.swal-cancel-custom {
    font-family: 'Hamishe', 'IRANSansWeb', sans-serif !important;
    font-weight: 600 !important;
    padding: 0.75rem 2rem !important;
    border-radius: 0.5rem !important;
    transition: all 0.3s ease !important;
}

.swal-cancel-custom:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2) !important;
}

/* SweetAlert2 Icon Colors */
.swal-popup-custom .swal2-icon.swal2-success {
    border-color: var(--primary-color) !important;
    color: var(--primary-color) !important;
}

.swal-popup-custom .swal2-icon.swal2-error {
    border-color: #dc3545 !important;
    color: #dc3545 !important;
}

.swal-popup-custom .swal2-icon.swal2-warning {
    border-color: #ffc107 !important;
    color: #ffc107 !important;
}

body.dark-theme .swal-popup-custom .swal2-icon.swal2-success {
    border-color: var(--primary-light) !important;
    color: var(--primary-light) !important;
}

/* SweetAlert2 Backdrop */
.swal2-backdrop-show {
    background-color: rgba(0, 0, 0, 0.4) !important;
}

/* ============================================
   M14 Section Styles (Team Section)
   ============================================ */
.m14-section {
    padding: 5rem 0;
    background-color: var(--bg-body-light);
    transition: background-color 0.3s ease;
}

body.dark-theme .m14-section {
    background-color: var(--bg-body-dark);
}

.m14-section .container {
    max-width: var(--container-max-width);
    overflow: visible;
}

.m14-section .row {
    overflow: visible;
}

.m14-team-card {
    margin: 50px auto 0;
    border-radius: 20px;
    background: var(--bg-color);
    border: 0.5px solid var(--border-color);
    padding: 15px;
    color: var(--text-color);
    position: relative;
    transition: all 0.3s ease, background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
    box-shadow: 0 2px 10px var(--shadow-light);
}

.m14-team-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px var(--shadow-medium);
}

body.dark-theme .m14-team-card {
    background: var(--bg-secondary-dark);
    border-color: var(--border-dark);
    color: var(--text-dark);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

body.dark-theme .m14-team-card:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.m14-user-content {
    margin-top: 80px;
    position: relative;
    z-index: 1;
}

.m14-name {
    font-size: 1.25rem;
    font-family: 'Hamishe', 'IRANSansWeb', sans-serif;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

body.dark-theme .m14-name {
    color: var(--text-dark);
}

.m14-post {
    font-size: 0.9375rem;
    color: var(--primary-color);
    margin: 0.9375rem 0;
    font-weight: 400;
    font-family: 'IRANSansWeb', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    transition: color 0.3s ease;
}

body.dark-theme .m14-post {
    color: var(--primary-light);
}

.m14-star {
    display: flex;
    gap: 3px;
    margin: 0.9375rem 0;
}

.m14-star i {
    color: #ffc107;
    font-size: 0.875rem;
    transition: color 0.3s ease;
}

.m14-star i.bi-star {
    display: none;
}

.m14-star i.bi-star-half {
    color: #ffc107;
}

/* معکوس کردن ستاره نیمه در RTL تا نیمه چپ رنگی باشد */
[dir="rtl"] .m14-star i.bi-star-half {
    transform: scaleX(-1);
}

.m14-about {
    color: var(--text-secondary);
    font-family: 'IRANSansWeb', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin-top: 0.625rem;
    font-size: 0.8125rem;
    line-height: 1.6;
    margin-bottom: 0;
    transition: color 0.3s ease;
}

body.dark-theme .m14-about {
    color: var(--text-secondary-dark);
}

.m14-round-box {
    position: absolute;
    top: -20%;
    right: 10%;
    background: var(--bg-color) !important;
    width: 130px;
    height: 130px;
    border: 1px solid var(--border-color);
    border-radius: 50%;
    z-index: 333;
    transition: background-color 0.3s ease, border-color 0.3s ease;
    overflow: visible;
}

[dir="ltr"] .m14-round-box {
    right: auto;
    left: 10%;
}

body.dark-theme .m14-round-box {
    background: var(--bg-secondary-dark) !important;
    border-color: var(--border-dark);
}

.m14-img-box {
    position: absolute;
    top: -20%;
    right: 10%;
    z-index: 555;
}

[dir="ltr"] .m14-img-box {
    right: auto;
    left: 10%;
}

.m14-img-box img {
    width: 130px;
    height: 130px;
    border-radius: 50%;
    padding: 10px;
    object-fit: cover;
    transition: background-color 0.3s ease;
    display: block;
}

.m14-square-box {
    height: 90px;
    width: 136px;
    background: var(--bg-color);
    position: absolute;
    top: 0;
    right: 9%;
    z-index: 444;
    transition: background-color 0.3s ease;
}

[dir="ltr"] .m14-square-box {
    right: auto;
    left: 9%;
}

body.dark-theme .m14-square-box {
    background: var(--bg-secondary-dark);
}

/* Responsive Styles */
@media (max-width: 992px) {
    .m14-team-card {
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .m14-section {
        padding: 3rem 0;
    }
    
    .m14-team-card {
        margin-top: 30px;
    }
    
    .m14-round-box,
    .m14-img-box {
        width: 100px;
        height: 100px;
    }
    
    .m14-img-box img {
        width: 100px;
        height: 100px;
    }
    
    .m14-square-box {
        width: 110px;
        height: 70px;
    }
    
    .m14-user-content {
        margin-top: 60px;
    }
}

body.dark-theme .swal2-backdrop-show {
    background-color: rgba(0, 0, 0, 0.6) !important;
}

/* ============================================
   M7 Section Styles (Video Section)
   ============================================ */
.m7-section {
    padding: 5rem 0;
    background-color: var(--bg-body-light);
    transition: background-color 0.3s ease;
}

body.dark-theme .m7-section {
    background-color: var(--bg-body-dark);
}

.m7-section .container {
    max-width: var(--container-max-width);
}

.m7-section-subtitle {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 2rem;
    font-family: 'Hamishe', 'IRANSansWeb', sans-serif;
    transition: color 0.3s ease;
}

body.dark-theme .m7-section-subtitle {
    color: var(--text-color);
}

.m7-video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: none;
    background-color: transparent;
    transition: box-shadow 0.3s ease;
}

body.dark-theme .m7-video-wrapper {
    background-color: transparent;
    box-shadow: none;
}

.m7-video-wrapper:hover {
    box-shadow: none;
}

body.dark-theme .m7-video-wrapper:hover {
    box-shadow: none;
}

.m7-video-iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 12px;
}

.m7-video-fallback {
    position: absolute;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 1rem;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-color);
    background: rgba(0, 0, 0, 0.04);
    z-index: 2;
    pointer-events: none;
}

body.dark-theme .m7-video-fallback {
    background: rgba(0, 0, 0, 0.25);
    color: var(--text-color);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .m7-section {
        padding: 3rem 0;
    }
    
    .m7-video-wrapper {
        border-radius: 8px;
    }
    
    .m7-video-iframe {
        border-radius: 8px;
    }
}

/* ============================================
   Blog Section Styles (تم متفاوت از Articles)
   ============================================ */

/* Blog Cover Image */
.blog-cover-container {
    width: 100%;
    height: 300px;
    overflow: hidden;
    border-radius: 12px;
    margin-bottom: 2rem;
}

.blog-cover-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

body.dark-theme .blog-cover-container {
    opacity: 0.9;
}

/* Blog Card Styles - تم متفاوت از Articles */
.blog-card {
    border: none;
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    background-color: var(--bg-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.blog-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.02) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
    z-index: 1;
}

.blog-card:hover::before {
    opacity: 1;
}

.blog-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

body.dark-theme .blog-card {
    background-color: var(--bg-secondary-dark);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

body.dark-theme .blog-card::before {
    background: linear-gradient(180deg, transparent 0%, rgba(255, 255, 255, 0.03) 100%);
}

body.dark-theme .blog-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
}

.blog-image {
    width: 100%;
    height: 320px;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.blog-card:hover .blog-image {
    transform: scale(1.08);
}

.blog-card .card-body {
    padding: 1.75rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    position: relative;
    z-index: 2;
}

.blog-card .card-title {
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.blog-card .card-title a {
    color: var(--text-color);
    transition: color 0.3s ease;
}

.blog-card .card-title a:hover {
    color: var(--primary-color);
}

.blog-card .card-text {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
    flex-grow: 1;
}

.blog-card .category-badge {
    font-size: 0.8rem;
    padding: 0.4rem 0.9rem;
    border-radius: 20px;
    background-color: rgba(108, 117, 125, 0.1);
    color: var(--text-muted);
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
    display: inline-block;
    transition: all 0.3s ease;
}

.blog-card:hover .category-badge {
    background-color: var(--primary-color);
    color: white;
}

body.dark-theme .blog-card .category-badge {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--text-color);
}

.blog-card .btn {
    border-radius: 25px;
    font-weight: 600;
    padding: 0.65rem 1.5rem;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.blog-card .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.blog-card small.text-muted {
    font-size: 0.875rem;
    color: var(--text-muted);
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.blog-card-footer {
    margin-top: 1.5rem !important;
    padding-top: 1rem;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

body.dark-theme .blog-card-footer {
    border-top-color: rgba(255, 255, 255, 0.1);
}

.blog-read-more-btn {
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 25px;
    padding: 0.65rem 1.5rem;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.blog-read-more-btn:hover {
    background-color: var(--secondary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Blog Main Card (Single Page) */
.blog-main-card {
    border: none;
    border-radius: 20px;
    overflow: hidden;
    background-color: var(--bg-color);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

body.dark-theme .blog-main-card {
    background-color: var(--bg-secondary-dark);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.4);
}

.blog-main-card .card-header.sidebar-widget-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    border-bottom: none;
    padding: 1.25rem 1.5rem;
}

.blog-main-card .card-img-top {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    border-radius: 0;
}

.blog-main-card .card-body {
    padding: 2rem;
}

.blog-main-card .card-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.blog-main-card .text-muted {
    color: var(--text-muted);
}

.blog-main-card .alert-light {
    background-color: rgba(0, 0, 0, 0.03);
    border-left: 4px solid var(--primary-color);
    border-radius: 8px;
}

.blog-main-card .blog-content {
    font-size: 1.1rem;
    line-height: 1.9;
    color: var(--text-color);
    margin-top: 1.5rem;
}

.blog-main-card .blog-content p {
    margin-bottom: 1.5rem;
}

.blog-main-card .blog-content h1,
.blog-main-card .blog-content h2,
.blog-main-card .blog-content h3,
.blog-main-card .blog-content h4,
.blog-main-card .blog-content h5,
.blog-main-card .blog-content h6 {
    color: var(--text-color);
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.blog-main-card .blog-content h2 {
    font-size: 2rem;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 0.5rem;
}

.blog-main-card .blog-content h3 {
    font-size: 1.75rem;
}

.blog-main-card .blog-content h4 {
    font-size: 1.5rem;
}

.blog-main-card .blog-content ul,
.blog-main-card .blog-content ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.blog-main-card .blog-content li {
    margin-bottom: 0.75rem;
    line-height: 1.8;
}

.blog-main-card .blog-content blockquote {
    border-left: 4px solid var(--primary-color);
    padding: 1rem 1.5rem;
    margin: 2rem 0;
    background-color: rgba(0, 0, 0, 0.03);
    border-radius: 8px;
    font-style: italic;
}

body.dark-theme .blog-main-card .blog-content blockquote {
    background-color: rgba(255, 255, 255, 0.05);
}

.blog-main-card .blog-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 2rem 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.blog-main-card .blog-content a {
    color: var(--primary-color);
    text-decoration: underline;
    transition: color 0.3s ease;
}

.blog-main-card .blog-content a:hover {
    color: var(--secondary-color);
}

body.dark-theme .blog-main-card .blog-content a {
    color: #6c9eff;
}

body.dark-theme .blog-main-card .blog-content a:hover {
    color: #8bb3ff;
}

.blog-main-card .badge {
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    background-color: var(--primary-color);
    color: white;
}

/* Related Blogs List */
.related-blogs-list {
    list-style: none;
    padding: 0;
}

.related-blog-item {
    border: none;
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    transition: background-color 0.3s ease;
}

.related-blog-item:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

body.dark-theme .related-blog-item:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

.related-blog-item a {
    text-decoration: none;
    color: var(--text-color);
}

.related-blog-item a:hover {
    color: var(--primary-color);
}

.related-blog-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}

.related-blog-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

/* Responsive adjustments for Blog */
@media (max-width: 991.98px) {
    .blog-image {
        height: 280px;
    }
    
    .blog-card .card-title {
        font-size: 1.25rem;
    }
}

@media (max-width: 768px) {
    .blog-image {
        height: 240px;
    }
    
    .blog-card .card-body {
        padding: 1.5rem;
    }
    
    .blog-card .card-title {
        font-size: 1.15rem;
    }
    
    .blog-card .card-text {
        font-size: 0.95rem;
    }
    
    .blog-main-card .card-body {
        padding: 1.5rem;
    }
    
    .blog-main-card .card-title {
        font-size: 1.75rem;
    }
    
    .blog-main-card .text-muted {
        font-size: 0.9rem;
    }
    
    .blog-main-card .blog-content {
        font-size: 1rem;
        line-height: 1.8;
    }
    
    .blog-main-card .blog-content h1,
    .blog-main-card .blog-content h2,
    .blog-main-card .blog-content h3 {
        font-size: 1.5rem;
    }
}

