:root {
    --bg: #faf7f2;
    --bg-card: #ffffff;
    --ink: #241f1e;
    --ink-soft: #7a6f6a;
    --mist: #ab9f99;
    --line: #ece3da;
    --primary: #9c2b2b;
    --primary-deep: #6e1d1d;
    --accent: #c98a2c;
    --accent-deep: #a06e1e;
    --secondary: #2f7a8c;
    --green: #3f8f6f;
    --rose: #d64545;
    --radius-lg: 24px;
    --radius-md: 16px;
    --radius-sm: 12px;
    --shadow-1: 0 4px 20px rgba(0,0,0,0.05);
    --shadow-2: 0 12px 40px rgba(156,43,43,0.15);
    --shadow-3: 0 20px 60px rgba(156,43,43,0.25);
    --ease: cubic-bezier(0.34, 1.56, 0.64, 1);
    --font-ui: 'Vazirmatn', system-ui, sans-serif;
    --font-mono: ui-monospace, 'Cascadia Code', Consolas, 'Vazirmatn', monospace;
}

@font-face { font-family:'Vazirmatn'; src:url('https://cdn.jsdelivr.net/gh/rastikerdar/vazirmatn@v33.003/fonts/webfonts/Vazirmatn-Regular.woff2') format('woff2'); font-weight:400; font-display:swap; }
@font-face { font-family:'Vazirmatn'; src:url('https://cdn.jsdelivr.net/gh/rastikerdar/vazirmatn@v33.003/fonts/webfonts/Vazirmatn-Bold.woff2') format('woff2'); font-weight:700; font-display:swap; }
@font-face { font-family:'Vazirmatn'; src:url('https://cdn.jsdelivr.net/gh/rastikerdar/vazirmatn@v33.003/fonts/webfonts/Vazirmatn-ExtraBold.woff2') format('woff2'); font-weight:800; font-display:swap; }

* { box-sizing: border-box; margin: 0; padding: 0; }

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-ui);
    background-color: var(--bg);
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(156,43,43,0.03), transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(201,138,44,0.04), transparent 40%);
    color: var(--ink);
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
img { max-width: 100%; height: auto; display: block; }
::selection { background: rgba(156,43,43,0.12); color: var(--primary); }

.wrap {
    max-width: 1080px;
    margin-inline: auto;
    padding-inline: clamp(16px, 4vw, 32px);
}

section {
    padding-block: clamp(30px, 6vw, 70px);
    position: relative;
    z-index: 2;
}

.reveal {
    opacity: 0;
    transform: translateY(38px) scale(0.985);
    filter: blur(6px);
    transition: opacity 0.9s cubic-bezier(.16, 1, .3, 1), 
                transform 0.9s cubic-bezier(.16, 1, .3, 1), 
                filter 0.9s cubic-bezier(.16, 1, .3, 1);
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
}

@media (prefers-reduced-motion: reduce) {
    .reveal {
        transition: opacity 0.3s ease;
        transform: none !important;
        filter: none !important;
    }
}

/* Visible keyboard focus across interactive elements */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 3px;
    border-radius: 6px;
    
}

/* ============================================ */
/* Preloader */
/* ============================================ */
#preloader {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: var(--bg);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 24px;
    transition: opacity 0.6s ease;
}

#preloader.hidden {
    opacity: 0;
    pointer-events: none;
}

.loader-ring {
    position: relative;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loader-ring .ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 3px solid transparent;
    border-top-color: var(--primary);
    animation: spin 1s linear infinite;
}

.loader-ring .ring:nth-child(2) {
    inset: 10px;
    border-top-color: var(--accent);
    animation-duration: 0.8s;
    animation-direction: reverse;
}

.loader-icon {
    font-size: 30px;
    color: var(--primary);
    z-index: 2;
    animation: pulse 1.8s ease-in-out infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}

.loader-text {
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: clamp(0.85rem, 2vw, 1rem);
}

.loader-text .prompt {
    font-family: var(--font-mono);
    color: var(--secondary);
    margin-left: 6px;
}

.loader-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    background: var(--accent);
    border-radius: 50%;
    animation: dotBounce 1.2s ease-in-out infinite both;
}

.loader-dot:nth-child(2) { animation-delay: 0.2s; }
.loader-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes dotBounce {
    0%, 80%, 100% { transform: scale(0.8); opacity: 0.5; }
    40% { transform: scale(1.4); opacity: 1; }
}

/* ============================================ */
/* Scroll Progress */
/* ============================================ */
.scroll-progress {
    position: fixed;
    top: 0;
    right: 0;
    height: 3px;
    z-index: 10000;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transition: width 0.08s linear;
    box-shadow: 0 0 14px rgba(156, 43, 43, 0.3);
}

/* ============================================ */
/* Navigation */
/* ============================================ */
.nav-shell {
    position: sticky;
    top: 14px;
    z-index: 60;
    padding-inline: clamp(12px, 4vw, 24px);
}

.nav {
    max-width: 995px;
    margin-inline: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
    background: rgb(255 255 255 / 13%);
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    border: 1px solid rgb(255 255 255 / 0%);
    border-radius: 999px;
    box-shadow: var(--shadow-1);
    transition: all 0.4s var(--ease);
    gap: 12px;
}

.nav.scrolled {
    box-shadow: var(--shadow-2);
    transform: translateY(-2px);
    border-color: rgba(156, 43, 43, 0.1);
}

.brand {
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 800;
    font-size: clamp(0.95rem, 2.5vw, 1.1rem);
    color: var(--primary);
    white-space: nowrap;
    flex-shrink: 0;
}

.brand i { color: var(--primary); }

.brand::after {
    content: '';
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #ab4a2b;
    box-shadow: 0 0 8px #9c2b2b;
    margin-right: 2px;
}

.nav-center {
    display: none;
    gap: clamp(12px, 2vw, 24px);
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--ink-soft);
    list-style: none;
    position: relative;
    flex-wrap: wrap;
    justify-content: center;
}

.nav-center a {
    transition: color 0.25s;
    position: relative;
    padding: 4px 0;
    white-space: nowrap;
}

.nav-center a::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.35s var(--ease);
}

.nav-center a:hover { color: var(--primary); }

.nav-center a:hover::after {
    width: 100%;
    left: 0;
    right: auto;
}

.nav-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 18px;
    box-shadow: 0 4px 16px rgba(156, 43, 43, 0.2);
    flex-shrink: 0;
    overflow: hidden;
    margin-left: 73px;
}

.nav-avatar span {
    display: block;
    width: 100%;
    height: 100%;
}

.nav-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.nav-actions-desktop { display: none; align-items: center; gap: 10px; flex-shrink: 0; }

.btn-sm {
    padding: 8px 18px;
    font-size: 0.85rem;
    border-radius: 999px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--primary);
    color: #fff;
    transition: all 0.3s var(--ease);
    box-shadow: 0 4px 12px rgba(156, 43, 43, 0.3);
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.btn-sm::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--accent), var(--accent-deep));
    opacity: 0;
    transition: opacity 0.3s;
}

.btn-sm:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(156, 43, 43, 0.4);
}

.btn-sm:hover::after { opacity: 1; }

.btn-sm:active {
    transform: translateY(0) scale(0.97);
    transition: transform 0.08s ease;
}

.btn-sm > * { position: relative; z-index: 1; }

.hamburger {
    display: flex;
    flex-direction: column;
    gap: 5px;
    z-index: 70;
    padding: 8px;
    flex-shrink: 0;
}

.hamburger span {
    display: block;
    width: 22px;
    height: 2.5px;
    background: var(--ink);
    border-radius: 3px;
    transition: transform 0.4s var(--ease);
}

.hamburger.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* Mobile Menu */
.menu-overlay {
    position: fixed;
    inset: 0;
    z-index: 55;
    background: rgba(0, 0, 0, 0.3);
    opacity: 0;
    visibility: hidden;
    transition: 0.4s;
}

.menu-overlay.open {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-panel {
    position: fixed;
    top: 0;
    right: 0;
    width: min(266px, 51vw);
    height: 100vh;
    height: 48dvh;
    z-index: 65;
    background: rgb(255 255 255 / 19%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-left: 1px solid var(--line);
    padding: 80px 20px 30px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    transform: translateX(105%);
    transition: transform 0.5s var(--ease);
    overflow-y: auto;
    box-shadow: -8px 0 30px rgba(0, 0, 0, 0.1);
    margin-top: 36px;
    border-radius: 20px 0px 0px 20px;
}

.mobile-menu-panel.open { transform: translateX(0); }

.mobile-menu-panel a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    color: #ffffff;
    transition: 0.3s;
    transform: translateX(20px);
    opacity: 0;
    font-size: 0.95rem;
}

.mobile-menu-panel.open a {
    transform: translateX(0);
    opacity: 1;
    transition-delay: calc(var(--i, 0) * 0.05s);
}

.mobile-menu-panel a:hover {
    background: rgba(156, 43, 43, 0.06);
    color: var(--primary);
}

/* Desktop Navigation */
@media (min-width: 769px) {
    .nav {
        padding: 12px 24px;
    }
    
    .nav-center {
        display: flex;
        flex: 1;
        justify-content: center;
    }
    
    .nav-avatar {
        width: 44px;
        height: 44px;
        font-size: 20px;
        position: static;
        margin-left: 28px;
    }
    
    .nav-actions-desktop { display: flex; }
    
    .hamburger { display: none; }
    
    .btn-sm {
        padding: 10px 22px;
        font-size: 0.9rem;
    }
}

/* Tablet */
@media (min-width: 769px) and (max-width: 1024px) {
    .nav-center {
        gap: 14px;
        font-size: 0.85rem;
    }
    
    .brand {
        font-size: 1rem;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .nav {
        padding: 8px 14px;
        gap: 8px;
    }
    
    .brand {
        font-size: 0.9rem;
    }
    
    .brand::after {
        width: 5px;
        height: 5px;
    }
    
    .nav-avatar {
        width: 34px;
        height: 34px;
        font-size: 16px;
    }
    
    .nav-actions-desktop { display: none; }
}

/* ============================================ */
/* Cards */
/* ============================================ */
.card {
    background: var(--bg-card);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-1);
    transition: all 0.4s var(--ease);
}

.card:hover {
    box-shadow: var(--shadow-2);
    border-color: rgba(156, 43, 43, 0.15);
    transform: translateY(-4px);
}

/* ============================================ */
/* Hero Section */
/* ============================================ */
.hero { padding-top: clamp(10px, 2vw, 20px); }

.profile {
    padding: clamp(20px, 3vw, 28px);
    display: grid;
    gap: clamp(12px, 2vw, 18px);
    margin-top: clamp(20px, 4vw, 40px);
    overflow: hidden;
}

.term-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: calc(clamp(20px, 3vw, 28px) * -1) calc(clamp(20px, 3vw, 28px) * -1) 6px;
    padding: 10px 14px;
    border-bottom: 1px solid var(--line);
    background: rgba(156, 43, 43, 0.03);
    flex-wrap: wrap;
}

.term-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.term-dot.r { background: #d64545; }
.term-dot.y { background: #c98a2c; }
.term-dot.g { background: #3f8f6f; }

/* Hero Syllabus Slider */
.term-popular-syllabus {
    margin-right: auto;
    font-family: var(--font-ui);
    font-size: clamp(0.65rem, 1.5vw, 0.75rem);
    font-weight: 700;
    color: var(--primary);
    background: rgba(156, 43, 43, 0.04);
    padding: 4px 12px;
    border-radius: 999px;
    border: 1px solid rgba(156, 43, 43, 0.15);
    position: relative;
    overflow: hidden;
    min-width: 253px;
    height: 28px;
    display: flex;
    align-items: center;
    backdrop-filter: blur(4px);
}

.syllabus-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 12px;
    white-space: nowrap;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s cubic-bezier(.16, 1, .3, 1), transform 0.6s cubic-bezier(.16, 1, .3, 1);
    pointer-events: none;
}

.syllabus-slide.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.syllabus-slide i {
    font-size: 0.9rem;
    color: var(--accent);
    animation: iconPop 2.2s ease-in-out infinite;
}

@keyframes iconPop {
    0%, 100% { transform: scale(1); opacity: 0.7; }
    50% { transform: scale(1.15); opacity: 1; }
}

.profile-top {
    display: flex;
    align-items: center;
    gap: clamp(14px, 2.5vw, 20px);
    flex-wrap: wrap;
}

.avatar {
    width: clamp(60px, 10vw, 80px);
    height: clamp(60px, 10vw, 80px);
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: clamp(24px, 5vw, 34px);
    box-shadow: 0 10px 28px rgba(156, 43, 43, 0.25);
    position: relative;
    flex-shrink: 0;
}

.avatar span {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
}

.avatar::before {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    background: conic-gradient(from 0deg, var(--primary), var(--accent), var(--secondary), var(--primary));
    z-index: -1;
    animation: avatarRingSpin 6s linear infinite;
    opacity: 0.85;
}

@keyframes avatarRingSpin {
    to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
    .avatar::before { animation: none; }
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.who h1 {
    font-size: clamp(1.2rem, 3vw, 1.6rem);
    font-weight: 800;
    letter-spacing: -0.01em;
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--primary);
    flex-wrap: wrap;
}

.who h1 .verified {
    color: #c07205;
    font-size: 0.85em;
    animation: verifiedPop 2.2s ease-in-out infinite;
}

@keyframes verifiedPop {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.who p {
    color: var(--ink-soft);
    font-size: clamp(0.85rem, 1.8vw, 0.95rem);
    margin-top: 4px;
    line-height: 1.7;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    border-top: 1px solid var(--line);
    padding-top: 14px;
}

.stat {
    text-align: center;
    padding: 6px 4px;
    transition: 0.3s;
}

.stat b {
    display: block;
    font-size: clamp(1rem, 2.5vw, 1.6rem);
    font-weight: 800;
    color: var(--primary);
}

.stat span {
    font-size: clamp(0.65rem, 1.5vw, 0.8rem);
    color: var(--mist);
}

/* Mobile Hero */
@media (max-width: 480px) {
    .profile {
        padding: 16px;
        margin-top: 16px;
    }
    
    .term-bar {
        margin: -16px -16px 6px;
        padding: 8px 10px;
        gap: 4px;
    }
    
    .term-popular-syllabus {
        min-width: 140px;
        font-size: 0.6rem;
        height: 24px;
        padding: 2px 8px;
    }
    
    .syllabus-slide {
        padding: 0 8px;
        gap: 4px;
    }
    
    .syllabus-slide i {
        font-size: 0.7rem;
    }
    
    .profile-top {
        gap: 10px;
    }
    
    .who h1 {
        font-size: 1.1rem;
    }
    
    .who p {
        font-size: 0.8rem;
    }
    
    .stats {
        gap: 4px;
        padding-top: 10px;
    }
    
    .stat b {
        font-size: 0.95rem;
    }
    
    .stat span {
        font-size: 0.6rem;
    }
}

/* ============================================ */
/* Logo Carousel */
/* ============================================ */
.logo-carousel {
    position: relative;
    width: 100%;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: var(--radius-lg);
    margin-top: 10px;
}

.logo-slide {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 999px;
    font-weight: 700;
    font-size: clamp(0.8rem, 2vw, 1rem);
    opacity: 0;
    transform: translateX(100px);
    transition: 0.5s;
    pointer-events: none;
    box-shadow: var(--shadow-1);
}

.logo-slide.active {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
    border-color: transparent;
    box-shadow: 0 0 20px rgba(156, 43, 43, 0.1);
}

.logo-slide i {
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    color: var(--primary);
    width: 30px;
    text-align: center;
}

/* ============================================ */
/* Skills Stagger Reveal Grid */
/* ============================================ */
.marquee-section {
    position: relative;
    text-align: center;
    padding-block: clamp(40px, 7vw, 70px);
    overflow: hidden;
    isolation: isolate;
}

.marquee-section::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 640px;
    height: 640px;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, rgba(156, 43, 43, 0.06), transparent 65%);
    z-index: -1;
    animation: marqueeGlowPulse 9s ease-in-out infinite;
}

@keyframes marqueeGlowPulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.85; }
    50% { transform: translate(-50%, -50%) scale(1.18); opacity: 1; }
}

.marquee-header {
    margin-bottom: clamp(28px, 4.5vw, 44px);
}

.marquee-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: clamp(0.7rem, 1.5vw, 0.85rem);
    letter-spacing: 0.08em;
    color: var(--accent);
    font-weight: 700;
    padding: 8px 20px;
    border: 1.5px solid rgba(201, 138, 44, 0.25);
    border-radius: 999px;
    background: rgba(201, 138, 44, 0.04);
    backdrop-filter: blur(8px);
    margin-bottom: clamp(14px, 2.5vw, 20px);
    text-transform: uppercase;
}

.marquee-eyebrow-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent);
    display: inline-block;
    animation: eyebrowPulse 2s ease-in-out infinite;
    box-shadow: 0 0 12px var(--accent);
}

@keyframes eyebrowPulse {
    0%, 100% { opacity: 0.6; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.5); }
}

.marquee-title {
    font-size: clamp(1.7rem, 5.5vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.3;
    margin-bottom: 10px;
    background: linear-gradient(115deg, var(--ink) 20%, var(--primary) 40%, var(--accent) 50%, var(--ink) 70%);
    background-size: 250% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: marqueeTitleShimmer 6s ease-in-out infinite;
}

@keyframes marqueeTitleShimmer {
    0% { background-position: 0% center; }
    50% { background-position: 100% center; }
    100% { background-position: 0% center; }
}

.marquee-sub {
    color: var(--ink-soft);
    max-width: 520px;
    margin-inline: auto;
    line-height: 1.9;
    font-size: clamp(0.85rem, 1.8vw, 1rem);
    padding-inline: 10px;
}

.skills-stagger-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: clamp(10px, 2vw, 16px);
}

.skill-chip {
    --i: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: 16px;
    background: #fff;
    border: 1.5px solid var(--line);
    font-weight: 700;
    font-size: clamp(0.8rem, 1.6vw, 0.92rem);
    color: var(--ink);
    box-shadow: var(--shadow-1);
    opacity: 0;
    transform: translateY(28px) scale(0.92);
    transition: opacity 0.6s cubic-bezier(.16,1,.3,1),
                transform 0.6s cubic-bezier(.16,1,.3,1),
                box-shadow 0.35s var(--ease),
                border-color 0.35s var(--ease);
    transition-delay: calc(var(--i) * 0.06s);
    will-change: transform, opacity;
}

.skill-chip.in-view {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.skill-chip:hover {
    border-color: rgba(156, 43, 43, 0.2);
    box-shadow: var(--shadow-2), 0 14px 28px -10px rgba(156, 43, 43, 0.25);
    transform: translateY(-4px) scale(1.02);
}

.skill-chip-icon {
    width: clamp(32px, 4.5vw, 38px);
    height: clamp(32px, 4.5vw, 38px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: clamp(14px, 2vw, 16px);
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    transition: transform 0.35s var(--ease);
}

.skill-chip:hover .skill-chip-icon {
    transform: rotate(-12deg) scale(1.12);
}

@media (prefers-reduced-motion: reduce) {
    .skill-chip {
        transition: opacity 0.3s ease;
        transform: none !important;
    }
    .marquee-section::before {
        animation: none;
    }
}

@media (max-width: 480px) {
    .skills-stagger-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    .skill-chip {
        padding: 10px 12px;
        font-size: 0.78rem;
    }
}

/* ============================================ */
/* Section Headings */
/* ============================================ */
.section-heading {
    text-align: center;
    font-size: clamp(1.4rem, 4.5vw, 2.3rem);
    font-weight: 800;
    letter-spacing: -0.015em;
    margin-bottom: 10px;
    color: var(--primary);
    position: relative;
    padding-bottom: 16px;
}

.section-heading::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 56px;
    height: 3px;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: translateX(-50%) scaleX(0);
    transform-origin: center;
    transition: transform 0.9s cubic-bezier(.16, 1, .3, 1) 0.15s;
}

.reveal.revealed .section-heading::after {
    transform: translateX(-50%) scaleX(1);
}

.section-sub {
    text-align: center;
    color: var(--ink-soft);
    max-width: 600px;
    margin-inline: auto;
    line-height: 1.8;
    font-size: clamp(0.85rem, 1.8vw, 0.95rem);
    margin-bottom: clamp(20px, 4vw, 30px);
    padding-inline: 10px;
}

/* ============================================ */
/* Courses Grid */
/* ============================================ */
.course-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: clamp(14px, 2vw, 20px);
}

.course {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: clamp(16px, 2.5vw, 31px) clamp(12px, 2vw, 7px);
    border-radius: var(--radius-lg);
    color: #fff;
    text-align: center;
    box-shadow: 0 8px 20px -8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s var(--ease);
    position: relative;
    overflow: hidden;
    min-height: 181px;
        background: linear-gradient(135deg, #00a74b, #145A3A);

}

.course::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0) 40%, rgba(0, 0, 0, 0.2) 100%);
    pointer-events: none;
}

.course:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 12px 30px -8px rgba(0, 0, 0, 0.15);
}

.course .ic {
    width: clamp(42px, 6vw, 52px);
    height: clamp(42px, 6vw, 52px);
    border-radius: clamp(12px, 2vw, 16px);
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: clamp(18px, 3vw, 22px);
    margin-bottom: 10px;
    position: relative;
    z-index: 1;
}

.course .tx { position: relative; z-index: 1; }

.course .tx b {
    display: block;
    font-size: clamp(0.95rem, 2vw, 1.1rem);
    font-weight: 800;
}

.course .tx span {
    font-size: clamp(0.65rem, 1.5vw, 0.75rem);
    opacity: 0.8;
    font-weight: 400;
}

.course .course-price {
    position: relative;
    z-index: 1;
    margin-top: 8px;
    font-weight: 800;
    font-size: clamp(0.8rem, 1.6vw, 0.92rem);
    background: rgba(255, 255, 255, 0.18);
    padding: 3px 12px;
    border-radius: 999px;
    letter-spacing: -0.01em;
}

.course .syllabus-btn {
    margin-top: 10px;
    padding: 6px 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    font-weight: 700;
    font-size: clamp(0.7rem, 1.5vw, 0.8rem);
    transition: 0.3s;
    position: relative;
    z-index: 1;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.course .syllabus-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.course .enroll-direct-btn {
    background: rgba(255, 255, 255, 0.95) !important;
    color: var(--ink) !important;
    box-shadow: none !important;
}

.course .enroll-direct-btn:hover {
    background: #fff !important;
    transform: translateY(-2px) !important;
}

.course-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255, 255, 255, 0.2);
    padding: 2px 10px;
    border-radius: 999px;
    font-size: clamp(0.55rem, 1vw, 0.6rem);
    font-weight: 700;
    z-index: 1;
    backdrop-filter: blur(4px);
}

.course.c-word { background: linear-gradient(135deg, #185ABD, #0D3B7A); }
.course.c-excel { background: linear-gradient(135deg, #217346, #145A3A); }
.course.c-ppt { background: linear-gradient(135deg, #D24726, #A6351B); }
.course.c-web { background: linear-gradient(135deg, #8b5cf6, #6d28d9); }
.course.c-graphic { background: linear-gradient(135deg, #d64545, #9c2b2b); }
.course.c-win { background: linear-gradient(135deg, #2f7a8c, #24606f); }

/* Mobile Courses */
@media (max-width: 480px) {
    .course-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .course {
        min-height: unset;
        padding: 23px 12px;
    }
}

/* ============================================ */
/* Syllabus Modal */
/* ============================================ */
.syllabus-overlay {
    position: fixed;
    inset: 0;
    z-index: 300;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s var(--ease);
    padding: 16px;
}

.syllabus-overlay.open {
    opacity: 1;
    visibility: visible;
}

.syllabus-modal {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: clamp(20px, 4vw, 32px);
    width: 100%;
    max-width: 720px;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.12);
    transform: scale(0.95) translateY(20px);
    transition: all 0.4s var(--ease);
    position: relative;
}

.syllabus-overlay.open .syllabus-modal {
    transform: scale(1) translateY(0);
}

.syllabus-modal::-webkit-scrollbar { width: 6px; }
.syllabus-modal::-webkit-scrollbar-track { background: transparent; }
.syllabus-modal::-webkit-scrollbar-thumb { background: var(--mist); border-radius: 999px; }

.syllabus-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 2px solid var(--line);
    flex-wrap: wrap;
    gap: 12px;
}

.syllabus-header .title-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.syllabus-header .title-icon {
    width: clamp(38px, 6vw, 48px);
    height: clamp(38px, 6vw, 48px);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: clamp(18px, 3vw, 22px);
    flex-shrink: 0;
}

.syllabus-header h3 {
    font-size: clamp(1.1rem, 2.5vw, 1.3rem);
    font-weight: 800;
    color: var(--ink);
}

.syllabus-header .subtitle {
    font-size: clamp(0.75rem, 1.5vw, 0.85rem);
    color: var(--ink-soft);
    margin-top: 2px;
}

.syllabus-close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.04);
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s var(--ease);
    color: var(--ink);
    flex-shrink: 0;
}

.syllabus-close:hover {
    background: rgba(156, 43, 43, 0.08);
    color: var(--primary);
    transform: rotate(90deg);
}

.syllabus-body {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.syllabus-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 14px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    border: 1px solid var(--line);
    transition: all 0.2s var(--ease);
}

.syllabus-item:hover {
    border-color: rgba(156, 43, 43, 0.15);
    transform: translateX(-4px);
    background: #fff;
}

.syllabus-item .num {
    font-family: var(--font-mono);
    font-size: clamp(0.65rem, 1.2vw, 0.75rem);
    font-weight: 700;
    color: var(--mist);
    min-width: 24px;
    padding-top: 2px;
}

.syllabus-item .text {
    font-size: clamp(0.82rem, 1.5vw, 0.92rem);
    color: var(--ink);
    line-height: 1.6;
}

.syllabus-footer {
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid var(--line);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.syllabus-footer .meta {
    display: flex;
    gap: clamp(8px, 2vw, 16px);
    font-size: clamp(0.75rem, 1.5vw, 0.85rem);
    color: var(--ink-soft);
    flex-wrap: wrap;
}

.syllabus-footer .meta i {
    color: var(--accent);
    margin-left: 4px;
}

/* ============================================ */
/* Features Grid */
/* ============================================ */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: clamp(14px, 2vw, 18px);
}

.feature {
    padding: clamp(16px, 2.5vw, 24px) clamp(14px, 2vw, 20px);
}

.feature:hover { transform: translateY(-6px); }

.feature .ic {
    width: clamp(46px, 7vw, 56px);
    height: clamp(46px, 7vw, 56px);
    border-radius: clamp(14px, 2vw, 18px);
    margin-bottom: 12px;
    font-size: clamp(20px, 3.5vw, 26px);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}

.feature h3 {
    font-size: clamp(1rem, 2vw, 1.2rem);
}

.feature p {
    font-size: clamp(0.8rem, 1.5vw, 0.9rem);
    color: var(--ink-soft);
    margin-bottom: 8px;
}

.feature ul {
    list-style: none;
    display: grid;
    gap: 6px;
    margin-top: 10px;
}

.feature li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: clamp(0.78rem, 1.3vw, 0.85rem);
    color: var(--ink-soft);
}

.feature li i {
    color: var(--accent);
    font-size: clamp(0.6rem, 1vw, 0.7rem);
}

.feature.f1 .ic { background: linear-gradient(135deg, #217346, #145A3A); }
.feature.f2 .ic { background: linear-gradient(135deg, #185ABD, #0D3B7A); }
.feature.f3 .ic { background: linear-gradient(135deg, #D24726, #A6351B); }
.feature.f4 .ic { background: linear-gradient(135deg, #8b5cf6, #6d28d9); }
.feature.f5 .ic { background: linear-gradient(135deg, #d64545, #9c2b2b); }
.feature.f6 .ic { background: linear-gradient(135deg, #2f7a8c, #24606f); }

/* Mobile Features */
@media (max-width: 480px) {
    .feature-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================ */
/* Courses / Templates Divider */
/* ============================================ */
.courses-divider {
    display: flex;
    align-items: center;
    gap: clamp(10px, 2vw, 18px);
    margin: clamp(30px, 5vw, 46px) 0 clamp(14px, 2.5vw, 20px);
}

.courses-divider-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--line) 20%, var(--line) 80%, transparent);
}

.courses-divider-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 800;
    font-size: clamp(0.95rem, 2vw, 1.15rem);
    color: var(--primary);
    white-space: nowrap;
    padding: 6px 4px;
}

.courses-divider-label i {
    color: var(--accent);
    font-size: 0.85em;
}

/* ============================================ */
/* Templates Grid */
/* ============================================ */
.template-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: clamp(14px, 2vw, 18px);
}

.template-item {
    padding: clamp(16px, 2.5vw, 24px) clamp(12px, 2vw, 16px);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    position: relative;
}

.template-item:hover { transform: translateY(-6px); }

.template-preview {
    width: clamp(56px, 9vw, 72px);
    height: clamp(56px, 9vw, 72px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: clamp(24px, 4vw, 32px);
}

.template-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 2px 10px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--accent), var(--accent-deep));
    color: #fff;
    font-size: clamp(0.55rem, 1vw, 0.65rem);
    font-weight: 700;
}

.template-type {
    font-family: var(--font-mono);
    font-size: clamp(0.65rem, 1.2vw, 0.72rem);
    color: var(--mist);
}

/* ============================================ */
/* Buttons */
/* ============================================ */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: clamp(10px, 1.5vw, 12px) clamp(18px, 3vw, 24px);
    border-radius: 999px;
    font-weight: 700;
    font-size: clamp(0.85rem, 1.5vw, 0.95rem);
    background: var(--primary);
    color: #fff;
    box-shadow: 0 6px 20px rgba(156, 43, 43, 0.3);
    transition: all 0.3s var(--ease);
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.btn-primary::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #d6454512, #d6454547);
    opacity: 0;
    transition: opacity 0.3s;
}

.btn-primary:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 34px rgba(156, 43, 43, 0.4);
}

.btn-primary:hover::after { opacity: 1; }

.btn-primary:active {
    transform: translateY(-1px) scale(0.98);
    box-shadow: 0 6px 16px rgba(156, 43, 43, 0.35);
    transition: transform 0.08s ease, box-shadow 0.08s ease;
}

.btn-primary:disabled {
    opacity: 0.6;
    pointer-events: none;
}

.btn-primary > * { position: relative; z-index: 1; }

.btn-primary .fa-spinner { animation: spin 0.8s linear infinite; }

.btn-primary { isolation: isolate; }

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    right: -60%;
    width: 40%;
    height: 100%;
    background: linear-gradient(115deg, transparent, rgba(255,255,255,0.35), transparent);
    transform: skewX(-20deg);
    transition: right 0.6s ease;
    z-index: 0;
    pointer-events: none;
}

.btn-primary:hover::before {
    right: 130%;
}

@media (prefers-reduced-motion: reduce) {
    .btn-primary::before { display: none; }
}

/* ============================================ */
/* Testimonials */
/* ============================================ */
.testimonial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: clamp(14px, 2vw, 18px);
}

.testimonial {
    padding: clamp(14px, 2vw, 20px);
    display: flex;
    gap: clamp(10px, 1.5vw, 16px);
    align-items: flex-start;
}

.testimonial .avatar-icon {
    width: clamp(38px, 6vw, 48px);
    height: clamp(38px, 6vw, 48px);
    border-radius: 50%;
    background: var(--line);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--primary);
    flex-shrink: 0;
}

.testimonial-content p {
    font-size: clamp(0.85rem, 1.5vw, 0.95rem);
    color: var(--ink-soft);
    line-height: 1.7;
    margin-bottom: 8px;
}

.testimonial-content .author {
    font-weight: 700;
    font-size: clamp(0.8rem, 1.3vw, 0.9rem);
}

/* ============================================ */
/* CTA */
/* ============================================ */
.cta {
    padding: clamp(24px, 4vw, 36px) clamp(16px, 3vw, 24px);
    display: grid;
    gap: clamp(12px, 2vw, 16px);
    text-align: center;
}

.cta-actions {
    display: flex;
    gap: clamp(10px, 2vw, 16px);
    justify-content: center;
    flex-wrap: wrap;
}

.btn-ghost {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: clamp(10px, 1.5vw, 12px) clamp(18px, 3vw, 24px);
    border-radius: 999px;
    font-weight: 700;
    background: rgba(0, 0, 0, 0.02);
    border: 1px solid var(--line);
    transition: all 0.3s var(--ease);
    font-size: clamp(0.85rem, 1.5vw, 0.95rem);
}

.btn-ghost:hover {
    background: rgba(156, 43, 43, 0.04);
    border-color: var(--primary);
    transform: translateY(-4px);
}

/* ============================================ */
/* Store */
/* ============================================ */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: clamp(16px, 3vw, 24px);
}

.filter-btn {
    padding: 7px 18px;
    border-radius: 999px;
    font-weight: 700;
    font-size: clamp(0.78rem, 1.3vw, 0.9rem);
    background: #fff;
    border: 1px solid var(--line);
    color: var(--ink-soft);
    transition: all 0.3s var(--ease);
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.filter-btn:hover { background: rgba(156, 43, 43, 0.04); }

.filter-btn.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 6px 20px rgba(156, 43, 43, 0.3);
}

.store-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: clamp(14px, 2vw, 20px);
    margin-top: 12px;
}

.store-item {
    padding: clamp(14px, 2vw, 22px) clamp(10px, 1.5vw, 16px);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transition: 0.4s;
    position: relative;
    cursor: pointer;
}

.store-item:hover { transform: translateY(-8px); box-shadow: var(--shadow-2); }

.store-item-icon {
    width: 100%;
    height: 160px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: clamp(22px, 4vw, 30px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
    position: relative;
}

.store-item:hover .store-item-icon {
    box-shadow: 0 18px 32px rgba(0, 0, 0, 0.18);
}

.store-item-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.store-item:hover .store-item-icon img {
    transform: scale(1.08);
}

.store-item-icon .icon-placeholder {
    font-size: 48px;
    color: #fff;
    opacity: 0.8;
}

/* magnifier hint on hover */
.store-item-icon::after {
    content: '\f002';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.35);
    color: #fff;
    font-size: 22px;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.store-item:hover .store-item-icon::after {
    opacity: 1;
}

.store-item-info h3 {
    font-size: clamp(0.95rem, 1.8vw, 1.05rem);
    font-weight: 700;
}

.store-item-info p {
    font-size: clamp(0.78rem, 1.3vw, 0.85rem);
    color: var(--ink-soft);
}

.store-price {
    font-weight: 800;
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--primary);
    margin: 4px 0;
}

.store-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 999px;
    background: linear-gradient(135deg, #d64545, #9c2b2b);
    color: #fff;
    font-size: clamp(0.55rem, 1vw, 0.65rem);
    font-weight: 700;
}

.store-badge.in-stock-badge {
    background: linear-gradient(135deg, var(--green), #2e6f53);
}

.store-badge.out-stock-badge {
    background: linear-gradient(135deg, var(--mist), #8a7f79);
}

.store-category-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255, 255, 255, 0.85);
    color: var(--primary);
    padding: 2px 10px;
    border-radius: 999px;
    font-size: clamp(0.5rem, 0.9vw, 0.6rem);
    font-weight: 700;
    backdrop-filter: blur(4px);
    border: 1px solid var(--line);
    z-index: 2;
}

.store-item .add-to-cart {
    margin-top: 4px;
    padding: 8px 16px;
    font-size: clamp(0.8rem, 1.3vw, 0.9rem);
    width: 100%;
    justify-content: center;
    position: relative;
    z-index: 5;
}

/* ============================================ */
/* Cart Sidebar */
/* ============================================ */
.cart-overlay {
    position: fixed;
    inset: 0;
    z-index: 90;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.cart-overlay.open {
    opacity: 1;
    visibility: visible;
}

.cart-sidebar {
    position: fixed;
    top: 0;
    right: 0;
    width: min(420px, 92vw);
    height: 100vh;
    height: 100dvh;
    z-index: 95;
    background: #ffffff;
    border-left: 1px solid var(--line);
    box-shadow: -12px 0 48px rgba(0, 0, 0, 0.08);
    padding: clamp(20px, 3vw, 28px) clamp(16px, 2.5vw, 24px);
    display: flex;
    flex-direction: column;
    transform: translateX(105%);
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.cart-sidebar.open { transform: translateX(0); }

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 14px;
    border-bottom: 1.5px solid var(--line);
    margin-bottom: 16px;
}

.cart-header h3 {
    font-size: clamp(1.1rem, 2vw, 1.25rem);
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
}

.cart-header h3 i { color: var(--accent); }

.cart-close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.04);
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s var(--ease);
    color: var(--ink);
    border: 1px solid transparent;
}

.cart-close:hover {
    background: rgba(185, 28, 28, 0.08);
    color: var(--primary);
    transform: rotate(90deg) scale(1.05);
    border-color: var(--primary);
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-bottom: 16px;
}

.cart-items::-webkit-scrollbar { width: 4px; }
.cart-items::-webkit-scrollbar-track { background: transparent; }
.cart-items::-webkit-scrollbar-thumb { background: var(--mist); border-radius: 999px; }

.cart-empty {
    text-align: center;
    color: var(--mist);
    padding: 40px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    font-size: clamp(0.85rem, 1.5vw, 0.95rem);
}

.cart-empty i {
    font-size: 2.5rem;
    color: var(--line);
    opacity: 0.6;
}

.cart-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    transition: all 0.3s var(--ease);
    position: relative;
}

.cart-item:hover {
    border-color: rgba(185, 28, 28, 0.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
    transform: translateX(-4px);
}

.cart-item-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 16px;
    flex-shrink: 0;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.cart-item-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-info { flex: 1; min-width: 0; }

.cart-item-title {
    font-weight: 700;
    font-size: clamp(0.85rem, 1.5vw, 0.95rem);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--ink);
}

.cart-item-price {
    font-size: clamp(0.7rem, 1.2vw, 0.8rem);
    color: var(--ink-soft);
    margin-top: 2px;
    font-weight: 500;
}

.cart-item-qty {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #ffffff;
    padding: 2px;
    border-radius: 999px;
    border: 1px solid var(--line);
}

.cart-item-qty .qty-btn {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: transparent;
    font-size: 0.9rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s var(--ease);
    color: var(--ink-soft);
    border: none;
}

.cart-item-qty .qty-btn:hover {
    background: var(--primary);
    color: #fff;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(185, 28, 28, 0.3);
}

.cart-item-qty span {
    font-weight: 700;
    min-width: 20px;
    text-align: center;
    font-size: clamp(0.85rem, 1.3vw, 0.95rem);
    color: var(--ink);
}

.cart-item-remove {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(239, 68, 68, 0.06);
    color: #d64545;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s var(--ease);
    flex-shrink: 0;
    border: 1px solid transparent;
    opacity: 0.6;
}

.cart-item:hover .cart-item-remove { opacity: 1; }

.cart-item-remove:hover {
    background: rgba(239, 68, 68, 0.12);
    transform: scale(1.15) rotate(8deg);
    border-color: rgba(239, 68, 68, 0.2);
    opacity: 1;
}

.cart-footer {
    border-top: 1.5px solid var(--line);
    padding-top: 16px;
    margin-top: 4px;
    background: #fff;
    border-radius: 0 0 var(--radius-md) var(--radius-md);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: clamp(1rem, 1.8vw, 1.1rem);
    font-weight: 800;
    margin-bottom: 14px;
    color: var(--ink);
}

.total-price { color: var(--primary); }

.cart-footer .btn-primary {
    width: 100%;
    justify-content: center;
    padding: 12px 20px;
    font-size: clamp(0.9rem, 1.5vw, 1rem);
    border-radius: var(--radius-md);
}

.cart-badge {
    position: absolute;
    top: -8px;
    right: -10px;
    background: var(--rose);
    color: #fff;
    font-size: 0.6rem;
    font-weight: 700;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.35);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    border: 2px solid #ffffff;
}

.nav-actions-desktop .btn-sm { position: relative; }

/* ============================================ */
/* Checkout Modal */
/* ============================================ */
.checkout-overlay {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: 0.3s;
    padding: 16px;
}

.checkout-overlay.open {
    opacity: 1;
    visibility: visible;
}

.checkout-modal {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: clamp(16px, 3vw, 24px);
    padding: clamp(20px, 4vw, 32px);
    width: 100%;
    max-width: 460px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.06);
    transform: scale(0.95);
    transition: 0.3s;
}

.checkout-overlay.open .checkout-modal { transform: scale(1); }

.checkout-modal h3 {
    font-size: clamp(1rem, 2vw, 1.2rem);
    font-weight: 800;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
}

/* Checkout step indicator */
.checkout-steps {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 20px;
}

.checkout-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.checkout-step .step-dot {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 1.5px solid var(--line);
    color: var(--mist);
    font-size: 0.75rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s var(--ease);
}

.checkout-step .step-label {
    font-size: clamp(0.6rem, 1.2vw, 0.68rem);
    color: var(--ink-soft);
    font-weight: 700;
    white-space: nowrap;
}

.checkout-step.done .step-dot {
    background: var(--green);
    border-color: var(--green);
    color: #fff;
}

.checkout-step.done .step-label { color: var(--green); }

.checkout-step.active .step-dot {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
    box-shadow: 0 0 0 4px rgba(156, 43, 43, 0.12);
}

.checkout-step.active .step-label { color: var(--primary); }

.checkout-step-line {
    flex: 1;
    height: 2px;
    background: var(--line);
    margin-bottom: 18px;
}

.checkout-section-label {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: clamp(0.75rem, 1.3vw, 0.82rem);
    font-weight: 800;
    color: var(--ink);
    margin: 18px 0 10px;
    padding-bottom: 6px;
    border-bottom: 1px dashed var(--line);
}

.checkout-section-label i { color: var(--accent); }

.checkout-section-label .optional-tag {
    margin-right: auto;
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--mist);
    background: var(--bg-card);
    border: 1px solid var(--line);
    padding: 1px 8px;
    border-radius: 999px;
}

/* Bank card payment card */
.payment-card-box {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-deep) 100%);
    border-radius: var(--radius-md);
    padding: 18px 20px;
    margin-bottom: 18px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 28px rgba(156, 43, 43, 0.25);
}

.payment-card-box::before {
    content: '';
    position: absolute;
    top: -30%;
    left: -10%;
    width: 60%;
    height: 160%;
    background: rgba(255, 255, 255, 0.06);
    transform: rotate(20deg);
}

.payment-card-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: clamp(0.7rem, 1.2vw, 0.78rem);
    color: rgba(255, 255, 255, 0.85);
    font-weight: 700;
    margin-bottom: 10px;
    position: relative;
    z-index: 1;
}

.payment-card-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    position: relative;
    z-index: 1;
}

.payment-card-number {
    font-family: var(--font-mono);
    font-size: clamp(1rem, 3vw, 1.25rem);
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.06em;
    direction: ltr;
    unicode-bidi: plaintext;
}

.payment-card-copy {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #fff;
    font-size: clamp(0.72rem, 1.3vw, 0.8rem);
    font-weight: 700;
    transition: all 0.25s var(--ease);
    flex-shrink: 0;
}

.payment-card-copy:hover {
    background: rgba(255, 255, 255, 0.28);
    transform: translateY(-1px);
}

.payment-card-copy.copied {
    background: var(--green);
    border-color: var(--green);
}

.payment-card-holder {
    margin-top: 12px;
    font-size: clamp(0.72rem, 1.2vw, 0.8rem);
    color: rgba(255, 255, 255, 0.8);
    position: relative;
    z-index: 1;
}

.form-group { margin-bottom: 14px; }

.form-group label {
    display: block;
    font-size: clamp(0.78rem, 1.2vw, 0.85rem);
    font-weight: 700;
    color: var(--ink-soft);
    margin-bottom: 5px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid var(--line);
    border-radius: 10px;
    font-family: inherit;
    font-size: clamp(0.82rem, 1.3vw, 0.9rem);
    outline: none;
    transition: 0.2s;
    background: #fff;
    color: var(--ink);
}

.form-group textarea {
    resize: vertical;
    min-height: 50px;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(156, 43, 43, 0.06);
}

.form-group input.invalid,
.form-group textarea.invalid {
    border-color: var(--rose);
}

.form-hint {
    font-size: clamp(0.65rem, 1vw, 0.75rem);
    color: var(--mist);
    margin-top: 4px;
}

.receipt-upload {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border: 1.5px dashed var(--line);
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    transition: 0.2s;
    font-size: clamp(0.78rem, 1.2vw, 0.85rem);
    color: var(--ink-soft);
}

.receipt-upload:hover { border-color: var(--primary); }

.receipt-upload input { display: none; }

.receipt-preview {
    margin-top: 8px;
    display: none;
    align-items: center;
    gap: 10px;
}

.receipt-preview img {
    width: 44px;
    height: 44px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid var(--line);
}

.receipt-preview .remove-receipt {
    color: var(--rose);
    font-size: clamp(0.7rem, 1.1vw, 0.8rem);
    font-weight: 700;
    cursor: pointer;
}

.order-summary-box {
    background: var(--bg-card);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 14px;
    font-size: clamp(0.78rem, 1.2vw, 0.85rem);
}

.order-summary-box .row {
    display: flex;
    justify-content: space-between;
    padding: 5px 0;
}

.order-summary-box .total-row {
    font-weight: 800;
    font-size: clamp(0.95rem, 1.8vw, 1.1rem);
    color: var(--primary);
    border-top: 1px solid var(--line);
    padding-top: 10px;
    margin-top: 5px;
}

.checkout-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.checkout-submit {
    flex: 1;
    justify-content: center;
}

.btn-secondary {
    padding: 10px 18px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.02);
    color: var(--ink);
    font-family: inherit;
    font-size: clamp(0.85rem, 1.4vw, 0.9rem);
    font-weight: 700;
    cursor: pointer;
    border: 1px solid var(--line);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.25s var(--ease);
}

.btn-secondary:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(156, 43, 43, 0.04);
}

.form-error {
    color: var(--rose);
    font-size: clamp(0.7rem, 1vw, 0.8rem);
    margin-top: 8px;
    min-height: 16px;
}

/* Checkout success state */
.checkout-success {
    text-align: center;
    padding: 10px 0 4px;
}

.checkout-success .success-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(63, 143, 111, 0.1);
    color: var(--green);
    font-size: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.checkout-success h4 {
    font-size: clamp(1rem, 2vw, 1.15rem);
    font-weight: 800;
    margin-bottom: 6px;
    color: var(--ink);
}

.checkout-success p {
    font-size: clamp(0.8rem, 1.4vw, 0.9rem);
    color: var(--ink-soft);
    line-height: 1.8;
}

.order-code-row {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
    padding: 6px 6px 6px 14px;
    border-radius: 999px;
    background: var(--bg-card);
    border: 1px solid var(--line);
}

.order-code {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    color: var(--primary);
    font-weight: 700;
    direction: ltr;
    unicode-bidi: plaintext;
}

.order-code-copy {
    background: var(--primary);
    border-color: var(--primary);
    padding: 5px 12px;
    font-size: 0.7rem;
}

.order-code-copy:hover {
    background: var(--primary-deep);
}

.order-code-copy.copied {
    background: var(--green);
    border-color: var(--green);
}

/* ============================================ */
/* Footer */
/* ============================================ */
footer {
    text-align: center;
    padding-block: clamp(30px, 5vw, 40px) clamp(20px, 3vw, 30px);
}

.socials {
    display: flex;
    justify-content: center;
    gap: clamp(12px, 2vw, 18px);
    margin-bottom: 16px;
}

.social {
    width: clamp(40px, 6vw, 48px);
    height: clamp(40px, 6vw, 48px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid var(--line);
    color: var(--ink);
    font-size: clamp(16px, 2.5vw, 20px);
    transition: all 0.3s var(--ease);
}

.social:hover {
    transform: translateY(-6px) scale(1.1);
}

.social.tg:hover { background: #2AABEE; color: #fff; }
.social.ig:hover { background: #E1306C; color: #fff; }
.social.yt:hover { background: #FF0000; color: #fff; }

.footer-legal {
    margin-top: 14px;
    font-size: 0.75rem;
    color: var(--mist);
}

/* ============================================ */
/* Floating Action Button (FAB) */
/* ============================================ */
.fab-container {
    position: fixed;
    bottom: clamp(16px, 3vw, 24px);
    right: clamp(16px, 3vw, 24px);
    z-index: 1000;
    display: flex;
    flex-direction: column-reverse;
    align-items: flex-end;
    gap: 10px;
}

.fab-main {
    width: clamp(44px, 7vw, 56px);
    height: clamp(44px, 7vw, 56px);
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-deep));
    color: #fff;
    font-size: clamp(18px, 3vw, 24px);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(156, 43, 43, 0.4);
    border: none;
    cursor: pointer;
    transition: transform 0.3s var(--ease), box-shadow 0.3s ease;
    position: relative;
    z-index: 2;
    top: -110px;
}

.fab-main:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 28px rgba(156, 43, 43, 0.5);
}

.fab-main i {
    transition: transform 0.3s var(--ease);
}

.fab-container.active .fab-main i {
    transform: rotate(135deg);
}

.fab-menu {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 116px;
    pointer-events: none;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s ease, transform 0.3s var(--ease);
    position: absolute;
    bottom: 65px;
    right: 0;
    width: max-content;
    flex-direction: column;
}

.fab-container.active .fab-menu {
    pointer-events: auto;
    opacity: 1;
    transform: translateY(0);
}

.fab-child {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    border: 1px solid var(--line);
    padding: 7px 16px;
    border-radius: 999px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
    color: var(--ink);
    font-weight: 600;
    font-size: clamp(0.8rem, 1.3vw, 0.9rem);
    transition: all 0.2s ease;
    cursor: pointer;
    white-space: nowrap;
    text-decoration: none;
}

.fab-child:hover {
    background: var(--bg);
    border-color: var(--primary);
    color: var(--primary);
    transform: translateX(-4px);
    box-shadow: 0 6px 16px rgba(156, 43, 43, 0.1);
}

.fab-child i {
    width: 18px;
    text-align: center;
    font-size: clamp(0.9rem, 1.5vw, 1.1rem);
    color: var(--primary);
}

/* ============================================ */
/* Floating Elements */
/* ============================================ */
.floating-elements {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.floating-bubble {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, rgba(156, 43, 43, 0.08), rgba(201, 138, 44, 0.05));
    animation: floatBubble 18s ease-in-out infinite;
    backdrop-filter: blur(2px);
    border: 1px solid rgba(156, 43, 43, 0.05);
}

.floating-bubble:nth-child(1) { width: 120px; height: 120px; top: 8%; left: -4%; animation-duration: 22s; }
.floating-bubble:nth-child(2) { width: 80px; height: 80px; bottom: 15%; right: -2%; animation-duration: 18s; animation-delay: -4s; background: radial-gradient(circle at 30% 30%, rgba(201, 138, 44, 0.10), rgba(156, 43, 43, 0.04)); }
.floating-bubble:nth-child(3) { width: 180px; height: 180px; top: 45%; left: -8%; animation-duration: 26s; animation-delay: -8s; background: radial-gradient(circle at 30% 30%, rgba(47, 122, 140, 0.05), rgba(156, 43, 43, 0.03)); }
.floating-bubble:nth-child(4) { width: 60px; height: 60px; bottom: 30%; right: 5%; animation-duration: 14s; animation-delay: -2s; background: radial-gradient(circle at 30% 30%, rgba(63, 143, 111, 0.08), rgba(201, 138, 44, 0.04)); }
.floating-bubble:nth-child(5) { width: 100px; height: 100px; top: 65%; right: -3%; animation-duration: 20s; animation-delay: -6s; background: radial-gradient(circle at 30% 30%, rgba(156, 43, 43, 0.06), rgba(47, 122, 140, 0.03)); }

@keyframes floatBubble {
    0% { transform: translate(0, 0) scale(1) rotate(0deg); opacity: .14; }
    25% { transform: translate(30px, -22px) scale(1.06) rotate(3deg); opacity: .26; }
    50% { transform: translate(-15px, 16px) scale(0.95) rotate(-2deg); opacity: .18; }
    75% { transform: translate(22px, -10px) scale(1.03) rotate(2deg); opacity: .3; }
    100% { transform: translate(0, 0) scale(1) rotate(0deg); opacity: .14; }
}

.floating-icon {
    position: absolute;
    opacity: 0.07;
    animation: floatIcon 26s ease-in-out infinite;
    color: var(--primary);
}

.floating-icon:nth-child(6) { top: 12%; left: 12%; font-size: 32px; animation-duration: 24s; animation-delay: -3s; color: var(--accent); }
.floating-icon:nth-child(7) { bottom: 20%; left: 18%; font-size: 20px; animation-duration: 16s; animation-delay: -7s; color: var(--secondary); }
.floating-icon:nth-child(8) { top: 35%; right: 15%; font-size: 28px; animation-duration: 22s; animation-delay: -5s; color: var(--green); }
.floating-icon:nth-child(9) { bottom: 45%; right: 8%; font-size: 18px; animation-duration: 18s; animation-delay: -1s; color: var(--primary); }

@keyframes floatIcon {
    0% { transform: translate(0, 0) rotate(0deg) scale(1); opacity: .05; }
    25% { transform: translate(16px, -12px) rotate(8deg) scale(1.08); opacity: .1; }
    50% { transform: translate(-10px, 10px) rotate(-6deg) scale(0.94); opacity: .04; }
    75% { transform: translate(13px, -6px) rotate(5deg) scale(1.05); opacity: .09; }
    100% { transform: translate(0, 0) rotate(0deg) scale(1); opacity: .05; }
}

.floating-particle {
    position: absolute;
    border-radius: 50%;
    background: var(--primary);
    animation: driftParticle 40s linear infinite;
    opacity: .03;
}

.floating-particle:nth-child(10) { width: 3px; height: 3px; top: 20%; left: 30%; }
.floating-particle:nth-child(11) { width: 4px; height: 4px; top: 60%; left: 70%; animation-duration: 32s; animation-delay: -5s; background: var(--accent); }
.floating-particle:nth-child(12) { width: 2px; height: 2px; top: 40%; left: 50%; animation-duration: 45s; animation-delay: -12s; background: var(--secondary); }
.floating-particle:nth-child(13) { width: 5px; height: 5px; top: 75%; left: 25%; animation-duration: 28s; animation-delay: -8s; background: var(--green); }
.floating-particle:nth-child(14) { width: 3px; height: 3px; top: 15%; left: 80%; animation-duration: 38s; animation-delay: -15s; }

@keyframes driftParticle {
    0% { transform: translate(0, 0); opacity: .02; }
    25% { transform: translate(80px, -60px); opacity: .08; }
    50% { transform: translate(-40px, 90px); opacity: .03; }
    75% { transform: translate(70px, 30px); opacity: .07; }
    100% { transform: translate(0, 0); opacity: .02; }
}

/* ============================================ */
/* Utility */
/* ============================================ */
@keyframes dot {
    70% { box-shadow: 0 0 0 8px rgba(63, 143, 111, 0); }
}

/* ============================================ */
/* Toast notifications */
/* ============================================ */
.toast-container {
    position: fixed;
    top: 18px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 99998;
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
    width: min(360px, 92vw);
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 10px 18px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--ink);
    opacity: 0;
    transform: translateY(-14px);
    transition: all 0.35s var(--ease);
    width: 100%;
    justify-content: center;
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}

.toast.toast-success { border-color: rgba(63, 143, 111, 0.3); color: var(--green); }
.toast.toast-error { border-color: rgba(214, 69, 69, 0.3); color: var(--rose); }
.toast.toast-info { border-color: rgba(47, 122, 140, 0.3); color: var(--secondary); }

/* ============================================ */
/* Media Queries Final Overrides */
/* ============================================ */

/* Tablet */
@media (min-width: 481px) and (max-width: 768px) {
    .course-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .feature-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .template-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .store-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .testimonial-grid {
        grid-template-columns: 1fr;
    }
}

/* Mobile */
@media (max-width: 480px) {
    html {
        font-size: 15px;
    }
    
    .wrap {
        padding-inline: 12px;
    }
    
    section {
        padding-block: 40px;
    }
    
    .course-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .feature-grid {
        grid-template-columns: 1fr;
    }
    
    .template-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .store-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .testimonial-grid {
        grid-template-columns: 1fr;
    }
    
    .term-popular-syllabus {
        min-width: 192px;
        height: 24px;
        font-size: 0.6rem;
    }
    
    .syllabus-slide {
        padding: 0 8px;
        gap: 4px;
    }
    
    .syllabus-slide i {
        font-size: 0.7rem;
    }
    
    .filter-bar {
        gap: 6px;
    }
    
    .filter-btn {
        padding: 6px 14px;
        font-size: 0.75rem;
    }
    
    .checkout-modal {
        padding: 16px;
    }
    
    .cart-sidebar {
        width: 95vw;
    }

    .payment-card-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .payment-card-copy {
        width: 29%;
        justify-content: center;
    }
}

/* Ultra Small Mobile */
@media (max-width: 360px) {
    .course-grid {
        grid-template-columns: 1fr;
    }
    
    .template-grid {
        grid-template-columns: 1fr;
    }
    
    .store-grid {
        grid-template-columns: 1fr;
    }
    
    .term-popular-syllabus {
        min-width: 178px;
        font-size: 0.55rem;
        height: 22px;
    }
    
    .syllabus-slide i {
        font-size: 0.65rem;
    }
}

/* ============ چت‌بات ============ */
.chat-widget {
    position: fixed;
    bottom: 24px;
    left: 24px;
    z-index: 9999;
    font-family: var(--font-ui);
}

.chat-toggle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-deep));
    color: #fff;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(156, 43, 43, 0.4);
    transition: all 0.3s var(--ease);
    border: none;
    position: relative;
    bottom: 45px;
}

.chat-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 28px rgba(156, 43, 43, 0.5);
}

.chat-toggle .chat-badge {
    position: absolute;
    top: -4px;
    left: -4px;
    width: 12px;
    height: 12px;
    background: var(--green);
    border-radius: 50%;
    border: 2px solid #fff;
    animation: chatPulse 2s infinite;
}

@keyframes chatPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(63, 143, 111, 0.5); }
    50% { box-shadow: 0 0 0 8px rgba(63, 143, 111, 0); }
}

.chat-box {
    position: absolute;
    bottom: 111px;
    left: 0;
    width: 340px;
    max-width: calc(100vw - 48px);
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    border: 1px solid var(--line);
    overflow: hidden;
    display: none;
    flex-direction: column;
    transition: all 0.3s var(--ease);
}

.chat-box.open {
    display: flex;
    animation: chatSlideIn 0.4s var(--ease);
}

@keyframes chatSlideIn {
    from { opacity: 0; transform: translateY(20px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.chat-header {
    background: linear-gradient(135deg, var(--primary), var(--primary-deep));
    color: #fff;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.chat-header h3 {
    font-size: 0.95rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 8px;
}

.chat-header .online-dot {
    width: 8px;
    height: 8px;
    background: #4ade80;
    border-radius: 50%;
    display: inline-block;
}

.chat-close-btn {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.2s;
}

.chat-close-btn:hover {
    background: rgba(255, 255, 255, 0.25);
}

.chat-messages {
    padding: 16px;
    height: 300px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: var(--bg);
}

.chat-messages::-webkit-scrollbar { width: 4px; }
.chat-messages::-webkit-scrollbar-track { background: transparent; }
.chat-messages::-webkit-scrollbar-thumb { background: var(--mist); border-radius: 999px; }

.chat-msg {
    max-width: 85%;
    padding: 10px 14px;
    border-radius: 16px;
    font-size: 0.85rem;
    line-height: 1.6;
    word-wrap: break-word;
    animation: msgPop 0.3s ease;
}

@keyframes msgPop {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.chat-msg.admin {
    align-self: flex-start;
    background: #fff;
    border: 1px solid var(--line);
    border-bottom-right-radius: 4px;
    color: var(--ink);
}

.chat-msg.user {
    align-self: flex-end;
    background: var(--primary);
    color: #fff;
    border-bottom-left-radius: 4px;
}

.chat-msg .time {
    font-size: 0.65rem;
    opacity: 0.6;
    margin-top: 4px;
    text-align: left;
}

.chat-input-area {
    padding: 12px 16px;
    border-top: 1px solid var(--line);
    display: flex;
    gap: 8px;
    align-items: center;
    background: #fff;
}

.chat-input-area input {
    flex: 1;
    padding: 10px 14px;
    border-radius: 999px;
    border: 1.5px solid var(--line);
    font-size: 0.85rem;
    outline: none;
    font-family: inherit;
    transition: 0.2s;
}

.chat-input-area input:focus {
    border-color: var(--primary);
}

.chat-send-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.2s;
    font-size: 0.9rem;
}

.chat-send-btn:hover {
    background: var(--primary-deep);
    transform: scale(1.05);
}

/* ریسپانسیو چت‌بات */
@media (max-width: 480px) {
    .chat-box {
        width: calc(100vw - 32px);
        left: -8px;
    }
    
    .chat-widget {
        bottom: 16px;
        left: 16px;
    }
    
    .chat-toggle {
        width: 48px;
        height: 48px;
        font-size: 20px;
    }
}

/* ============ نوار فیلتر فروشگاه ============ */
.filter-bar-desktop {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: clamp(16px, 3vw, 24px);
}

.filter-btn-desktop {
    padding: 8px 18px;
    border-radius: 999px;
    font-weight: 700;
    font-size: clamp(0.8rem, 1.3vw, 0.9rem);
    background: #fff;
    border: 1.5px solid var(--line);
    color: var(--ink-soft);
    cursor: pointer;
    font-family: inherit;
    transition: all 0.3s var(--ease);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.filter-btn-desktop:hover {
    background: rgba(156, 43, 43, 0.04);
    border-color: var(--primary);
}

.filter-btn-desktop.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 6px 20px rgba(156, 43, 43, 0.3);
}

/* ============ مدال نمایش عکس محصول ============ */
.image-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    padding: 20px;
    cursor: pointer;
}

.image-modal-overlay.open {
    opacity: 1;
    visibility: visible;
}

.image-modal {
    position: relative;
    max-width: min(600px, 90vw);
    max-height: 85vh;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.4);
    transform: scale(0.9);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    cursor: default;
    background: #fff;
}

.image-modal-overlay.open .image-modal {
    transform: scale(1);
}

.image-modal img {
    width: 100%;
    height: auto;
    max-height: 60vh;
    object-fit: contain;
    display: block;
    background: #fff;
}

.image-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
    backdrop-filter: blur(8px);
}

.image-modal-close:hover {
    background: rgba(239, 68, 68, 0.8);
    transform: scale(1.1) rotate(90deg);
}

.image-modal-info {
    padding: 16px 20px;
    background: #fff;
}

.image-modal-info h3 {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--ink);
    margin-bottom: 4px;
}

.image-modal-info p {
    font-size: 0.85rem;
    color: var(--ink-soft);
    margin-bottom: 6px;
}

.image-modal-info .image-modal-price {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--primary);
}

.add-to-cart {
    position: relative;
    z-index: 5;
}

/* ============================================ */
/* تم‌های اختصاصی قالب‌ها (کامل برای همه نوع‌ها) */
/* ============================================ */

/* ----- قالب ورد (آبی + W) ----- */
.template-item.tpl-word {
    background: linear-gradient(135deg, #185ABD 0%, #0D3B7A 100%);
    color: #fff;
    position: relative;
    overflow: hidden;
}
.tpl-word::before {
    content: "W W W W W W W W W";
    position: absolute;
    font-size: 2.5rem;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.08);
    white-space: pre-wrap;
    line-height: 1.4;
    top: -20%;
    left: -10%;
    right: -10%;
    bottom: -20%;
    transform: rotate(-5deg);
    pointer-events: none;
    animation: floatW 15s linear infinite;
}
@keyframes floatW {
    0% { transform: translateY(0) rotate(-5deg); }
    50% { transform: translateY(-10px) rotate(-5deg); }
    100% { transform: translateY(0) rotate(-5deg); }
}

/* ----- قالب اکسل (سبز + E) ----- */
.template-item.tpl-excel {
    background: linear-gradient(135deg, #217346, #145A3A);
    color: #fff;
}
.tpl-excel::before {
    content: "E E E E E E E E";
    font-size: 2.2rem;
    font-weight: 900;
    color: rgba(255,255,255,0.06);
    position: absolute;
    top: -10%;
    left: -5%;
    right: -5%;
    bottom: -10%;
    transform: rotate(3deg);
    animation: floatE 18s linear infinite;
    pointer-events: none;
}
@keyframes floatE {
    0% { transform: translateX(0) rotate(3deg); }
    50% { transform: translateX(8px) rotate(3deg); }
    100% { transform: translateX(0) rotate(3deg); }
}

/* ----- قالب پاورپوینت (نارنجی + P) ----- */
.template-item.tpl-powerpoint {
    background: linear-gradient(135deg, #D24726, #A6351B);
    color: #fff;
}
.tpl-powerpoint::before {
    content: "P P P P P P P P";
    font-size: 2.2rem;
    font-weight: 900;
    color: rgba(255,255,255,0.07);
    position: absolute;
    top: -10%;
    left: -5%;
    right: -5%;
    bottom: -10%;
    transform: rotate(-3deg);
    animation: floatP 17s linear infinite;
    pointer-events: none;
}
@keyframes floatP {
    0% { transform: translateY(0) rotate(-3deg); }
    50% { transform: translateY(-8px) rotate(-3deg); }
    100% { transform: translateY(0) rotate(-3deg); }
}

/* ----- قالب HTML (بنفش + </>) ----- */
.template-item.tpl-html {
    background: linear-gradient(135deg, #8b5cf6, #6d28d9);
    color: #fff;
}
.tpl-html::before {
    content: "</> </> </> </> </>";
    font-size: 1.6rem;
    font-weight: 900;
    color: rgba(255,255,255,0.06);
    position: absolute;
    top: -10%;
    left: -5%;
    right: -5%;
    bottom: -10%;
    transform: rotate(5deg);
    animation: floatHTML 20s linear infinite;
    pointer-events: none;
    white-space: pre-wrap;
}
@keyframes floatHTML {
    0% { transform: translate(0, 0) rotate(5deg); }
    50% { transform: translate(10px, -5px) rotate(5deg); }
    100% { transform: translate(0, 0) rotate(5deg); }
}

/* ----- قالب وردپرس (فیروزه‌ای + WP) ----- */
.template-item.tpl-wordpress {
    background: linear-gradient(135deg, #0073aa, #005177);
    color: #fff;
}
.tpl-wordpress::before {
    content: "WP WP WP WP WP";
    font-size: 1.8rem;
    font-weight: 900;
    color: rgba(255,255,255,0.06);
    position: absolute;
    top: -10%;
    left: -5%;
    right: -5%;
    bottom: -10%;
    transform: rotate(-2deg);
    animation: floatWP 19s linear infinite;
    pointer-events: none;
    white-space: pre-wrap;
}
@keyframes floatWP {
    0% { transform: translate(0, 0) rotate(-2deg); }
    50% { transform: translate(-8px, 4px) rotate(-2deg); }
    100% { transform: translate(0, 0) rotate(-2deg); }
}

/* ----- قالب فایل فشرده (خاکستری + ZIP) ----- */
.template-item.tpl-archive {
    background: linear-gradient(135deg, #6b7280, #4b5563);
    color: #fff;
}
.tpl-archive::before {
    content: "ZIP ZIP ZIP ZIP";
    font-size: 1.6rem;
    font-weight: 900;
    color: rgba(255,255,255,0.06);
    position: absolute;
    top: -10%;
    left: -5%;
    right: -5%;
    bottom: -10%;
    transform: rotate(2deg);
    animation: floatZIP 16s linear infinite;
    pointer-events: none;
    white-space: pre-wrap;
}
@keyframes floatZIP {
    0% { transform: translate(0, 0) rotate(2deg); }
    50% { transform: translate(-6px, 3px) rotate(2deg); }
    100% { transform: translate(0, 0) rotate(2deg); }
}

/* ----- سایر قالب‌ها (پیش‌فرض ملایم) ----- */
.template-item.tpl-other {
    background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
    color: var(--ink);
}
.tpl-other::before {
    content: "★ ★ ★ ★ ★ ★";
    font-size: 1.8rem;
    font-weight: 900;
    color: rgba(0,0,0,0.03);
    position: absolute;
    top: -10%;
    left: -5%;
    right: -5%;
    bottom: -10%;
    transform: rotate(0deg);
    animation: floatOther 20s linear infinite;
    pointer-events: none;
}
@keyframes floatOther {
    0% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
    100% { transform: translateY(0); }
}
.tpl-other .template-preview {
    background: rgba(0,0,0,0.05);
}
.tpl-other h3, .tpl-other p {
    color: var(--ink);
}
.tpl-other .template-type {
    color: var(--ink-soft);
}

/* ----- تنظیمات مشترک برای خوانایی متن در تم‌های تیره ----- */
.tpl-word .template-type,
.tpl-word .template-badge,
.tpl-word h3,
.tpl-word p,
.tpl-excel .template-type,
.tpl-excel .template-badge,
.tpl-excel h3,
.tpl-excel p,
.tpl-powerpoint .template-type,
.tpl-powerpoint .template-badge,
.tpl-powerpoint h3,
.tpl-powerpoint p,
.tpl-html .template-type,
.tpl-html .template-badge,
.tpl-html h3,
.tpl-html p,
.tpl-wordpress .template-type,
.tpl-wordpress .template-badge,
.tpl-wordpress h3,
.tpl-wordpress p,
.tpl-archive .template-type,
.tpl-archive .template-badge,
.tpl-archive h3,
.tpl-archive p {
    position: relative;
    z-index: 1;
    color: #fff;
}

/* پیش‌نمایش آیکن در تم‌های رنگی */
.tpl-word .template-preview,
.tpl-excel .template-preview,
.tpl-powerpoint .template-preview,
.tpl-html .template-preview,
.tpl-wordpress .template-preview,
.tpl-archive .template-preview {
    background: rgba(255,255,255,0.15);
    box-shadow: 0 0 20px rgba(255,255,255,0.1);
}

/* اگر قالبی نوع ناشناخته‌ای داشت (fallback) */
.template-item:not([class*="tpl-"]) {
    background: var(--bg-card);
    color: var(--ink);
}