/* =========================================
   1. FONTS & GLOBAL VARIABLES
   ========================================= */
@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@300;400;500;700;800&display=swap');

:root {
    /* Colors */
    --bg-main: #0b1120;
    --bg-card: rgba(30, 41, 59, 0.6);
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --accent: #8b5cf6;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    
    /* Text Colors */
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --text-dark: #64748b;
    
    /* Borders & Shadows */
    --border-light: rgba(255, 255, 255, 0.1);
    --border-glow: rgba(99, 102, 241, 0.3);
    --shadow-card: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    --shadow-glow: 0 0 20px rgba(99, 102, 241, 0.2);
}

/* Base Reset */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Vazirmatn', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    min-height: 100vh;
    margin: 0;
    padding: 0;
    background-image: 
        radial-gradient(circle at 15% 50%, rgba(99, 102, 241, 0.08), transparent 30%),
        radial-gradient(circle at 85% 30%, rgba(139, 92, 246, 0.08), transparent 30%);
    background-attachment: fixed;
}

/* =========================================
   2. TYPOGRAPHY & UTILITIES
   ========================================= */
h1, h2, h3, h4, h5, h6 {
    color: var(--text-main);
    font-weight: 700;
}

.text-gradient {
    background: linear-gradient(135deg, #818cf8 0%, #c084fc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.text-muted {
    color: var(--text-muted) !important;
}

/* =========================================
   3. HEADER & NAVBAR
   ========================================= */
.navbar-custom {
    background: rgba(11, 17, 32, 0.75) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-light);
    padding: 12px 0;
    transition: all 0.3s ease;
}

.navbar-brand {
    font-size: 1.7rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    text-decoration: none;
    color: var(--text-main) !important;
}

.navbar-brand i {
    color: var(--primary);
}

.nav-link {
    color: var(--text-muted) !important;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-link:hover, .nav-link.active {
    color: var(--text-main) !important;
}

.btn-nav {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-light);
    color: var(--text-main);
    border-radius: 8px;
    padding: 8px 20px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-nav:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--border-glow);
    color: var(--text-main);
    box-shadow: var(--shadow-glow);
}

/* Avatar */
.avatar-circle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    font-weight: bold;
    font-size: 0.9rem;
}

/* =========================================
   4. BUTTONS
   ========================================= */
.btn-gradient {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: #ffffff;
    border: none;
    border-radius: 10px;
    padding: 12px 28px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-gradient:hover {
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(99, 102, 241, 0.3);
}

/* =========================================
   5. GLASSMORPHISM CARDS
   ========================================= */
.glass-card {
    background: var(--bg-card);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    box-shadow: var(--shadow-card);
    transition: all 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-5px);
    border-color: var(--border-glow);
    box-shadow: var(--shadow-glow);
}

a .glass-card {
    color: inherit;
    text-decoration: none;
}

a:hover .glass-card h4 {
    color: var(--primary) !important;
}

/* =========================================
   6. FORMS & INPUTS
   ========================================= */
.form-control, .form-select {
    background-color: rgba(15, 23, 42, 0.6) !important;
    border: 1px solid var(--border-light) !important;
    color: var(--text-main) !important;
    border-radius: 10px;
    padding: 12px 16px;
    transition: all 0.3s ease;
}

.form-control:focus, .form-select:focus {
    background-color: rgba(15, 23, 42, 0.8) !important;
    border-color: var(--primary) !important;
    box-shadow: 0 0 0 0.25rem rgba(99, 102, 241, 0.25) !important;
    color: var(--text-main);
}

.form-control::placeholder {
    color: var(--text-dark) !important;
}

.form-label {
    color: var(--text-main);
    font-weight: 600;
    margin-bottom: 8px;
}

/* =========================================
   7. SEARCH BAR
   ========================================= */
.search-form .input-group {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.search-form .input-group-text {
    border-right: none;
    padding-right: 15px;
    background-color: rgba(15, 23, 42, 0.6) !important;
}

.search-form .form-control {
    border-left: none;
    border-right: none;
    box-shadow: none !important;
}

.search-form .btn-gradient {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
}

/* =========================================
   8. PAGINATION (Dark Theme)
   ========================================= */
.custom-pagination {
    display: flex;
    justify-content: center;
    padding: 0;
    list-style: none;
    gap: 5px;
}

.custom-pagination .page-item {
    display: inline-block;
}

.custom-pagination .page-link {
    background-color: rgba(30, 41, 59, 0.7) !important; /* پس‌زمینه تیره شیشه‌ای */
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: var(--text-muted) !important;
    margin: 0;
    border-radius: 8px !important;
    transition: all 0.3s ease;
    padding: 8px 16px;
    font-weight: 600;
    text-align: center;
    min-width: 45px;
}

.custom-pagination .page-link:hover {
    background-color: rgba(99, 102, 241, 0.2) !important;
    color: var(--text-main) !important;
    border-color: var(--primary) !important;
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.3);
}

.custom-pagination .page-item.active .page-link {
    background: linear-gradient(135deg, var(--primary), var(--accent)) !important;
    color: white !important;
    border-color: transparent !important;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
}

.custom-pagination .page-item.disabled .page-link {
    background-color: rgba(30, 41, 59, 0.3) !important;
    color: rgba(255, 255, 255, 0.2) !important;
    border-color: rgba(255, 255, 255, 0.05) !important;
    cursor: not-allowed;
    box-shadow: none !important;
}

/* =========================================
   9. PROMPT OUTPUT BOX
   ========================================= */
.prompt-box {
    background-color: #0f172a;
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 12px;
    padding: 20px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1rem;
    line-height: 1.6;
    color: var(--success);
    direction: ltr;
    text-align: left;
    white-space: pre-wrap;
    word-break: break-word;
}

/* =========================================
   10. LANDING PAGE (HOME)
   ========================================= */
.min-vh-75 { min-height: 75vh; }

.badge-pill {
    display: inline-flex;
    align-items: center;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.2);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    color: #a5b4fc;
}

.badge-dot {
    width: 8px;
    height: 8px;
    background-color: #818cf8;
    border-radius: 50%;
    margin-left: 8px;
    box-shadow: 0 0 10px #818cf8;
}

.hero-visual {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.glow-circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.4;
    z-index: 0;
}
.glow-1 { width: 150px; height: 150px; background: #6366f1; top: -20px; right: -20px; }
.glow-2 { width: 200px; height: 200px; background: #8b5cf6; bottom: -50px; left: -50px; }

.mockup-window {
    background: rgba(15, 23, 42, 0.9);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 15px;
    position: relative;
    z-index: 1;
}

.mockup-header { padding-bottom: 10px; border-bottom: 1px solid rgba(255, 255, 255, 0.05); }
.dot { width: 10px; height: 10px; border-radius: 50%; }
.dot.red { background: #ef4444; }
.dot.yellow { background: #f59e0b; }
.dot.green { background: #10b981; }

.feature-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

/* =========================================
   11. FOOTER (Minimal & Centered)
   ========================================= */
.footer-custom {
    background: rgba(11, 17, 32, 0.95);
    border-top: 1px solid var(--border-light);
    padding: 60px 0 30px 0;
    position: relative;
    margin-top: auto;
}

.footer-custom::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    opacity: 0.4;
}

.footer-brand {
    font-weight: 800;
    font-size: 1.6rem;
    color: var(--text-main) !important;
    display: inline-block;
}

.footer-brand:hover {
    color: var(--text-main) !important;
}

.footer-text {
    color: var(--text-dark);
    font-size: 0.95rem;
    line-height: 1.8;
}

.footer-link {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.footer-link:hover {
    color: var(--primary);
}

/* آیکون‌های شبکه‌های اجتماعی */
.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-muted);
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: var(--primary);
    color: white !important;
    transform: translateY(-3px);
    border-color: var(--primary);
    box-shadow: 0 5px 15px rgba(99, 102, 241, 0.3);
}

/* =========================================
   12. SCROLLBAR
   ========================================= */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-main); }
::-webkit-scrollbar-thumb { background: #334155; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }