/* تنسيق صفحة المصحف */

/* الألوان والمتغيرات */
/* متغيرات الوضع الفاتح */
:root:not([data-theme="dark"]) {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --success-color: #059669;
    --danger-color: #dc2626;
    --warning-color: #d97706;
    --dark-bg: #f8fafc;
    --darker-bg: #ffffff;
    --card-bg: #ffffff;
    --text-primary: #1f2937;
    --text-secondary: #4b5563;
    --text-muted: #6b7280;
    --border-color: #e5e7eb;
    --shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

/* متغيرات الوضع المظلم */
[data-theme="dark"] {
    --primary-color: #3b82f6;
    --secondary-color: #2563eb;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --dark-bg: #1f2937;
    --darker-bg: #111827;
    --card-bg: #374151;
    --text-primary: #f9fafb;
    --text-secondary: #d1d5db;
    --text-muted: #9ca3af;
    --border-color: #4b5563;
    --shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.4);
}

/* إعدادات عامة */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Amiri', 'Noto Sans Arabic', Arial, sans-serif;
    background: linear-gradient(135deg, var(--darker-bg) 0%, var(--dark-bg) 100%);
    color: var(--text-primary);
    line-height: 1.6;
    direction: rtl;
    min-height: 100vh;
    transition: background 0.3s ease, color 0.3s ease;
}

/* خلفية متدرجة للوضع الفاتح */
body:not([data-theme="dark"]) {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

/* خلفية متدرجة للوضع المظلم */
[data-theme="dark"] body {
    background: linear-gradient(135deg, #111827 0%, #1f2937 100%);
}

/* شاشة التحميل */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--darker-bg);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

.loading-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid var(--border-color);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-text {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-top: 10px;
}

/* الحاوي الرئيسي */
.main-container {
    display: flex;
    height: 100vh;
    overflow: hidden;
}

/* الشريط الجانبي */
.sidebar {
    width: 350px;
    background: var(--card-bg);
    border-left: 1px solid var(--border-color);
    display: none;
    flex-direction: column;
    transition: transform 0.3s ease;
    z-index: 1000;
}

.sidebar.open {
    display: flex;
}

/* إخفاء الشريط الجانبي افتراضياً على الشاشات الصغيرة */
@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        top: 0;
        right: 0;
        width: 85vw;
        max-width: 320px;
        height: 100%;
        z-index: 1001;
        transform: translateX(100%);
        transition: transform 0.3s ease;
        backdrop-filter: blur(10px);
        border-left: 1px solid var(--border-color);
        visibility: hidden;
    }
    
    .sidebar.open {
        transform: translateX(0);
        visibility: visible;
    }
    
    .sidebar .sidebar-content {
        padding: 20px 16px;
        height: 100%;
        overflow-y: auto;
    }
    
    #surahs-list {
        max-height: calc(100vh - 200px);
        padding-bottom: 20px;
    }
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    background: var(--darker-bg);
}

.sidebar-title {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--text-primary);
    margin-bottom: 10px;
    text-align: center;
}

.search-container {
    position: relative;
    margin-top: 15px;
}

.search-input {
    width: 100%;
    padding: 12px 40px 12px 15px;
    background: var(--dark-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

/* قائمة السور */
.surahs-container {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
}

.surahs-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.surah-item {
    width: 100%;
    text-align: right;
    padding: 12px 16px;
    background: var(--dark-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 15px;
    min-height: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.surah-item:hover {
    background: var(--border-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border-color: var(--secondary-color);
}

.surah-item.active {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-color: var(--secondary-color);
    box-shadow: 0 4px 16px rgba(59, 130, 246, 0.4);
}

/* تحسينات للأجهزة المحمولة */
@media (max-width: 768px) {
    .surah-item {
        padding: 14px 18px;
        font-size: 16px;
        min-height: 65px;
        border-radius: 14px;
    }
    
    .surah-item:active {
        transform: scale(0.98);
        background: var(--primary-color);
    }
}

@media (max-width: 480px) {
    .surahs-list {
        gap: 8px;
    }
    
    .surah-item {
        padding: 16px 20px;
        font-size: 17px;
        min-height: 70px;
        border-radius: 16px;
        touch-action: manipulation;
    }
    
    .surah-item:hover {
        transform: none;
    }
    
    .surah-item:active {
        transform: scale(0.96);
        transition: transform 0.1s ease;
    }
}

.surah-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
    width: 100%;
}

.surah-name {
    font-weight: 600;
    font-size: 16px;
    flex: 1;
    text-align: right;
}

.surah-number {
    background: rgba(255, 255, 255, 0.15);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    min-width: 35px;
    text-align: center;
    margin-left: 12px;
}

/* تحسينات للأجهزة المحمولة */
@media (max-width: 768px) {
    .surah-name {
        font-size: 17px;
        font-weight: 600;
    }
    
    .surah-number {
        padding: 5px 12px;
        font-size: 14px;
        min-width: 40px;
        margin-left: 14px;
    }
}

@media (max-width: 480px) {
    .surah-header {
        margin-bottom: 8px;
    }
    
    .surah-name {
        font-size: 18px;
        font-weight: 700;
    }
    
    .surah-number {
        padding: 6px 14px;
        font-size: 15px;
        min-width: 45px;
        margin-left: 16px;
        border-radius: 25px;
    }
}

.surah-info {
    font-size: 12px;
    opacity: 0.8;
}

/* المحتوى الرئيسي */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* رأس الصفحة */
.header {
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-title {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--text-primary);
}

.header-controls {
    display: flex;
    gap: 10px;
    align-items: center;
}

.sidebar-toggle {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.sidebar-toggle:hover {
    background: var(--secondary-color);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* تحسينات للأجهزة المحمولة */
@media (max-width: 768px) {
    .sidebar-toggle {
        padding: 12px 16px;
        border-radius: 8px;
        font-size: 16px;
        min-width: 50px;
        min-height: 50px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .sidebar-toggle:active {
        transform: scale(0.95);
        background: var(--secondary-color);
    }
}

@media (max-width: 480px) {
    .sidebar-toggle {
        padding: 14px 18px;
        border-radius: 10px;
        font-size: 18px;
        min-width: 55px;
        min-height: 55px;
        touch-action: manipulation;
    }
    
    .sidebar-toggle:hover {
        transform: none;
    }
}

/* قسم القراء */
.readers-section {
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    padding: 20px;
}

.readers-title {
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.readers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
}

.reader-btn {
    padding: 12px 16px;
    background: var(--dark-bg);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    text-align: center;
}

.reader-btn:hover {
    background: var(--border-color);
    transform: translateY(-1px);
}

.reader-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--secondary-color);
}

/* مشغل الصوت */
.audio-player {
    background: var(--darker-bg);
    border-top: 1px solid var(--border-color);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.player-info {
    text-align: center;
    color: var(--text-secondary);
    font-size: 14px;
}

.player-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
}

.control-btn {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 12px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.control-btn:hover {
    background: var(--border-color);
    transform: scale(1.05);
}

.play-pause-btn {
    width: 60px;
    height: 60px;
    font-size: 1.2rem;
}

.play-pause-btn.playing {
    background: var(--danger-color);
    border-color: var(--danger-color);
}

.play-pause-btn.paused {
    background: var(--success-color);
    border-color: var(--success-color);
}

/* شريط التقدم */
.progress-section {
    display: flex;
    align-items: center;
    gap: 15px;
}

.time-display {
    font-size: 12px;
    color: var(--text-muted);
    min-width: 40px;
    text-align: center;
}

.progress-container {
    flex: 1;
    height: 6px;
    background: var(--border-color);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--primary-color);
    border-radius: 3px;
    transition: width 0.1s ease;
    width: 0%;
}

/* التحكم في الصوت */
.volume-section {
    display: flex;
    align-items: center;
    gap: 10px;
}

.volume-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 5px;
    transition: color 0.3s ease;
}

.volume-btn:hover {
    color: var(--text-primary);
}

.volume-slider {
    width: 100px;
    height: 4px;
    background: var(--border-color);
    border-radius: 2px;
    outline: none;
    cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
    appearance: none;
    width: 16px;
    height: 16px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
}

.volume-slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

/* منطقة المحتوى */
.content-area {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

/* رأس السورة */
.surah-header-section {
    text-align: center;
    margin-bottom: 30px;
    padding: 30px;
    background: var(--card-bg);
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.surah-name-display {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--text-primary);
    margin-bottom: 10px;
    font-family: 'Amiri', serif;
}

.surah-info-display {
    color: var(--text-muted);
    font-size: 1rem;
}

/* الآيات */
.ayahs-container {
    max-width: 800px;
    margin: 0 auto;
}

.ayah-text {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    line-height: 2;
    font-size: 1.4rem;
    font-family: 'Amiri', serif;
}

.ayah-text:hover {
    background: var(--border-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.ayah-text.ayah-playing {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-color: var(--primary-color);
    box-shadow: var(--shadow-lg);
}

.ayah-content {
    display: block;
    margin-bottom: 15px;
    text-align: justify;
}

.ayah-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    height: 30px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    font-size: 14px;
    font-weight: bold;
    margin-right: 10px;
    float: left;
}

.ayah-playing .ayah-number {
    background: white;
    color: var(--primary-color);
}

/* الطبقة المتراكبة */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(2px);
}

.overlay.active {
    opacity: 1;
    visibility: visible;
}

/* تحسينات عامة للأجهزة المحمولة */
@media (max-width: 768px) {
    .overlay {
        background: rgba(0, 0, 0, 0.6);
        backdrop-filter: blur(3px);
    }
    
    /* تحسين الأداء للأجهزة المحمولة */
    * {
        -webkit-tap-highlight-color: transparent;
    }
    
    /* تحسين التمرير */
    .sidebar {
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
    }
    
    #surahs-list {
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
    }
}

@media (max-width: 480px) {
    .overlay {
        background: rgba(0, 0, 0, 0.7);
    }
}

/* الفئات المساعدة */

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.text-left {
    text-align: left;
}

.mb-4 {
    margin-bottom: 1rem;
}

.mt-4 {
    margin-top: 1rem;
}

.p-4 {
    padding: 1rem;
}



@media (max-width: 480px) {
    .sidebar {
        width: 95vw;
        max-width: none;
    }
    
    .sidebar .sidebar-content {
        padding: 24px 20px;
    }
    
    .sidebar-title {
        font-size: 18px;
        margin-bottom: 20px;
    }
    
    #surahs-list {
        max-height: calc(100vh - 180px);
        padding-bottom: 30px;
    }
}

/* تحسينات للشاشات الصغيرة جداً */
@media (max-width: 450px) {
    .sidebar {
        width: 98vw;
    }
    
    .sidebar .sidebar-content {
        padding: 20px 16px;
    }
    
    #surahs-list {
        max-height: calc(100vh - 160px);
        padding-bottom: 25px;
    }
    
    .sidebar .sidebar-content {
        padding: 24px 20px;
    }
    
    .sidebar-title {
        font-size: 18px;
        margin-bottom: 20px;
    }
    
    #surahs-list {
        max-height: calc(100vh - 180px);
        padding-bottom: 30px;
    }
    
    .main-content {
        width: 100%;
    }
    
    .header {
        padding: 15px;
    }
    
    .header-title {
        font-size: 1.5rem;
    }
    
    .readers-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 8px;
    }
    
    .reader-btn {
        padding: 10px 12px;
        font-size: 13px;
    }
    
    .audio-player {
        padding: 15px;
    }
    
    .player-controls {
        gap: 10px;
    }
    
    .control-btn {
        width: 45px;
        height: 45px;
        padding: 10px;
    }
    
    .play-pause-btn {
        width: 55px;
        height: 55px;
    }
    
    .content-area {
        padding: 15px;
    }
    
    .surah-header-section {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .surah-name-display {
        font-size: 2rem;
    }
    
    .ayah-text {
        padding: 20px;
        font-size: 1.2rem;
        margin-bottom: 15px;
    }
    
    .volume-section {
        display: none;
    }
}

@media (max-width: 480px) {
    .header-title {
        font-size: 1.2rem;
    }
    
    .readers-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .progress-section {
        flex-direction: column;
        gap: 10px;
    }
    
    .time-display {
        order: 2;
    }
    
    .progress-container {
        order: 1;
        width: 100%;
    }
    
    .surah-name-display {
        font-size: 1.8rem;
    }
    
    .ayah-text {
        font-size: 1.1rem;
        padding: 15px;
    }
}

/* تحسينات إضافية */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.slide-in {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
    }
    to {
        transform: translateX(0);
    }
}

/* تحسين شريط التمرير */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--dark-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* تحسين التركيز */
button:focus,
input:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* تحسين الطباعة */
@media print {
    .sidebar,
    .audio-player,
    .header-controls {
        display: none;
    }
    
    .main-content {
        width: 100%;
    }
    
    .ayah-text {
        background: white;
        color: black;
        border: 1px solid #ccc;
    }
}

/* تحسينات إضافية للتجربة */
.floating-control {
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.progress-bar {
    transition: width 0.3s ease;
}

.volume-slider::-webkit-slider-thumb {
    transition: all 0.2s ease;
}

.volume-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

/* تمييز الآية الحالية في التفسير */
.ayah-highlighted {
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.1) 0%, rgba(59, 130, 246, 0.05) 100%);
    border-left: 4px solid #3b82f6;
    padding-left: 12px;
    margin-left: -16px;
    border-radius: 0 8px 8px 0;
    animation: highlightPulse 2s ease-in-out;
}

@keyframes highlightPulse {
    0%, 100% { background-color: rgba(59, 130, 246, 0.1); }
    50% { background-color: rgba(59, 130, 246, 0.2); }
}

/* تحسين عرض نتائج البحث */
mark {
    background-color: #fbbf24;
    color: #1f2937;
    padding: 2px 4px;
    border-radius: 3px;
    font-weight: 600;
}

[data-theme="dark"] mark {
    background-color: #f59e0b;
    color: #111827;
}

/* تحسين أزرار التفسير */
.tafsir-controls {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 12px;
}

.tafsir-btn {
    padding: 6px 12px;
    border: none;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.tafsir-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.tafsir-btn:active {
    transform: translateY(0);
}

/* تحسين الأكورديون */
.accordion-item {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.accordion-item:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.1);
}

.accordion-header {
    background: var(--card-bg);
    padding: 16px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.2s ease;
}

.accordion-header:hover {
    background: var(--dark-bg);
}

.accordion-content {
    padding: 16px;
    background: var(--darker-bg);
    border-top: 1px solid var(--border-color);
}

.accordion-icon {
    transition: transform 0.3s ease;
}

.accordion-item.open .accordion-icon {
    transform: rotate(180deg);
}

/* تحسين شريط البحث */
.search-input {
    position: relative;
}

.search-input::before {
    content: '🔍';
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
}

.search-input input {
    padding-left: 40px;
}

/* تحسين رسائل الخطأ */
.error-container {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(220, 38, 38, 0.05) 100%);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 12px;
    padding: 24px;
    text-align: center;
}

.error-icon {
    color: #ef4444;
    margin-bottom: 16px;
}

.error-title {
    color: #ef4444;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
}

.error-message {
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.6;
}

.error-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

/* تحسين التحميل */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* تحسين الإشعارات */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--card-bg);
    color: var(--text-primary);
    padding: 16px 20px;
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    border-left: 4px solid var(--success-color);
    z-index: 1000;
    animation: slideInRight 0.3s ease;
}

.notification.error {
    border-left-color: var(--danger-color);
}

.notification.warning {
    border-left-color: var(--warning-color);
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* تحسين الاستجابة للشاشات الصغيرة */
@media (max-width: 640px) {
    .floating-control {
        bottom: 80px;
        left: 10px;
        right: 10px;
        padding: 12px;
    }
    
    .floating-control .flex {
        flex-direction: column;
        gap: 8px;
    }
    
    .floating-control .progress-container {
        order: -1;
    }
    
    .tafsir-controls {
        justify-content: center;
    }
    
    .error-actions {
        flex-direction: column;
    }
    
    .notification {
        right: 10px;
        left: 10px;
        top: 10px;
    }
    
    .accordion-header {
        padding: 12px;
    }
    
    .accordion-content {
        padding: 12px;
    }
}