/* ===== TRANSLATION SYSTEM STYLES ===== */

/* RTL Support */
[dir="rtl"] {
    direction: rtl;
    text-align: right;
}

[dir="rtl"] .navbar-menu {
    text-align: right;
}

[dir="rtl"] .nav-list {
    flex-direction: row-reverse;
}

[dir="rtl"] .dropdown-menu {
    right: auto;
    left: 0;
}

[dir="rtl"] .hero-content {
    text-align: right;
}

[dir="rtl"] .about-content {
    text-align: right;
}

[dir="rtl"] .section-header {
    text-align: center;
}

[dir="rtl"] .feature-item {
    text-align: right;
}

[dir="rtl"] .testimonial-content {
    text-align: right;
}

[dir="rtl"] .contact-info {
    text-align: right;
}

[dir="rtl"] .form-group {
    text-align: right;
}

/* Language Toggle Button */
.language-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 25px;
    color: white;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.language-toggle:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.language-toggle i {
    font-size: 1rem;
}

.language-toggle span {
    font-weight: 600;
    min-width: 20px;
    text-align: center;
}

/* Translation Status Messages */
.translation-status {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    z-index: 10000;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    animation: slideInRight 0.3s ease;
}

.translation-status-success {
    background-color: #28a745;
}

.translation-status-error {
    background-color: #dc3545;
}

.translation-status-info {
    background-color: #17a2b8;
}

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

/* RTL Specific Adjustments */
[dir="rtl"] .translation-status {
    right: auto;
    left: 20px;
    animation: slideInLeft 0.3s ease;
}

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

/* Persian Font Support */
[lang="fa"] {
    font-family: 'Tahoma', 'Arial', sans-serif;
}

[lang="fa"] h1, [lang="fa"] h2, [lang="fa"] h3, 
[lang="fa"] h4, [lang="fa"] h5, [lang="fa"] h6 {
    font-family: 'Tahoma', 'Arial', sans-serif;
    font-weight: 600;
}

/* Translation Loading States */
.translating {
    opacity: 0.7;
    pointer-events: none;
}

.translating::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Responsive Adjustments for RTL */
@media (max-width: 768px) {
    [dir="rtl"] .navbar-menu {
        text-align: right;
    }
    
    [dir="rtl"] .nav-list {
        flex-direction: column;
    }
    
    [dir="rtl"] .dropdown-menu {
        right: auto;
        left: 0;
    }
    
    [dir="rtl"] .translation-status {
        right: 10px;
        left: 10px;
        width: calc(100% - 20px);
        text-align: center;
    }
}

/* No Translate Class */
.no-translate {
    /* Elements with this class will not be translated */
}

/* Translation Cache Indicator */
[data-translated="true"] {
    /* Optional: Add visual indicator for translated content */
    /* border-left: 2px solid #28a745; */
} 