/* Custom RTL Styles for Nava Miller AI */

body {
    font-family: 'Rubik', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    direction: rtl;
    text-align: right;
}

/* RTL-specific utility classes */
.rtl-flip {
    transform: scaleX(-1);
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Animation for progress bars */
@keyframes progressAnimation {
    from {
        width: 0;
    }
}

.progress-bar {
    animation: progressAnimation 0.5s ease-out;
}

/* Modal animations */
.modal-enter {
    animation: modalEnter 0.3s ease-out;
}

@keyframes modalEnter {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Task content container */
#task-content {
    position: relative;
    isolation: isolate;
}

/* Responsive tables */
@media (max-width: 768px) {
    table {
        font-size: 0.875rem;
    }

    th, td {
        padding: 0.5rem;
    }
}

/* Button loading state */
.btn-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

.btn-loading::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spinner 0.6s linear infinite;
}

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

/* Hebrew typography optimization */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    letter-spacing: 0;
}

p {
    line-height: 1.8;
}

/* Form inputs RTL */
input[type="text"],
input[type="password"],
input[type="email"],
textarea,
select {
    text-align: right;
}

/* Placeholder RTL */
::placeholder {
    text-align: right;
}

/* Tags/Chips styling */
.tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
}

/* Print styles */
@media print {
    nav,
    .no-print {
        display: none;
    }
}

/* Accessibility: Focus visible */
.focus-visible:focus {
    outline: 2px solid var(--accent, #2b8cee);
    outline-offset: 2px;
}
