
/* ==========================================
   main.css - استایل‌های مشترک پروژه
   جشنواره حکیم برهان الدین کرمانی
   ========================================== */

/* ==========================================
   ۱. ایمپورت فونت وزیرمتن
   ========================================== */
@import url('https://cdn.jsdelivr.net/gh/rastikerdar/vazirmatn@v33.003/Vazirmatn-font-face.css');

/* ==========================================
   ۲. ریست و تنظیمات پایه
   ========================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ==========================================
   ۳. متغیرهای CSS (رنگ‌ها و تنظیمات)
   ========================================== */
:root {
    /* رنگ‌های اصلی */
    --primary-purple: #6C5CE7;
    --primary-blue: #0984E3;
    --primary-light: #a29bfe;
    
    /* رنگ‌های تاکیدی */
    --accent-gold: #FDCB6E;
    --accent-orange: #F39C12;
    
    /* رنگ‌های پس‌زمینه */
    --bg-light: #ffffff;
    --bg-gradient: linear-gradient(135deg, #f8f9ff 0%, #f0f4ff 100%);
    
    /* رنگ‌های متن */
    --text-dark: #1a1a2e;
    --text-muted: #6c757d;
    --text-light: #ffffff;
    
    /* رنگ‌های وضعیت */
    --success-color: #00b894;
    --error-color: #e74c3c;
    --warning-color: #f39c12;
    
    /* سایه‌ها */
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 5px 20px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 10px 40px rgba(108, 92, 231, 0.2);
    --shadow-xl: 0 20px 60px rgba(108, 92, 231, 0.3);
    
    /* بوردر ردیوس */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 30px;
    
    /* ترنزیشن */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* ==========================================
   ۴. تنظیمات بدنه
   ========================================== */
body {
    font-family: 'Vazirmatn', sans-serif;
    direction: rtl;
    min-height: 100vh;
    background: var(--bg-light);
    color: var(--text-dark);
    overflow-x: hidden;
    line-height: 1.6;
}

/* ==========================================
   ۵. انیمیشن‌های مشترک
   ========================================== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-8px); }
    40% { transform: translateX(8px); }
    60% { transform: translateX(-8px); }
    80% { transform: translateX(8px); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0.3; }
}

/* ==========================================
   ۶. استایل‌های مشترک دکمه‌ها
   ========================================== */
.btn {
    padding: 12px 28px;
    border: none;
    border-radius: var(--radius-xl);
    font-family: 'Vazirmatn', sans-serif;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    color: var(--text-light);
    box-shadow: 0 4px 15px rgba(108, 92, 231, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(108, 92, 231, 0.5);
}

.btn-secondary {
    background: linear-gradient(135deg, var(--accent-gold), var(--accent-orange));
    color: var(--text-dark);
    box-shadow: 0 4px 15px rgba(253, 203, 110, 0.3);
}

.btn-secondary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(253, 203, 110, 0.5);
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

/* ==========================================
   ۷. استایل‌های مشترک فرم
   ========================================== */
.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
}

.form-input {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid #e0e0e0;
    border-radius: var(--radius-md);
    font-family: 'Vazirmatn', sans-serif;
    font-size: 15px;
    transition: all var(--transition-normal);
    background: var(--bg-light);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-purple);
    box-shadow: 0 0 0 4px rgba(108, 92, 231, 0.1);
}

.form-input.error {
    border-color: var(--error-color);
    animation: shake 0.5s ease;
}

.form-input.success {
    border-color: var(--success-color);
}

.error-message {
    display: none;
    color: var(--error-color);
    font-size: 12px;
    margin-top: 6px;
    padding-right: 5px;
}

.error-message.show {
    display: flex;
    align-items: center;
    gap: 5px;
    animation: fadeIn 0.3s ease;
}

/* ==========================================
   ۸. یوتیلیتی‌ها
   ========================================== */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }

.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 20px; }
.mt-3 { margin-top: 30px; }

.mb-1 { margin-bottom: 10px; }
.mb-2 { margin-bottom: 20px; }
.mb-3 { margin-bottom: 30px; }