/**
 * SWA RTL Specific Styles
 *
 * @package SWA
 */

/* ==========================================================================
   Base RTL Adjustments
   ========================================================================== */

/* Already handled by logical properties (inset-inline-start, etc.) in main CSS */
/* This file is for RTL-specific overrides if needed */

/* Icon flip for directional icons */
.swa-rtl .swa-icon-chevron-left {
    transform: scaleX(-1);
}

.swa-rtl .swa-icon-chevron-right {
    transform: scaleX(-1);
}

.swa-rtl .swa-icon-arrow-left {
    transform: scaleX(-1);
}

.swa-rtl .swa-icon-arrow-right {
    transform: scaleX(-1);
}

/* Breadcrumb separator direction */
.swa-rtl .swa-breadcrumb__separator {
    transform: scaleX(-1);
}

/* Form field icons position */
.swa-rtl .swa-form-input-icon {
    right: auto;
    left: var(--swa-space-3);
}

/* Tables text alignment */
.swa-rtl table th,
.swa-rtl table td {
    text-align: right;
}

/* Progress bars direction */
.swa-rtl .swa-progress-bar {
    direction: rtl;
}

/* List markers */
.swa-rtl ul,
.swa-rtl ol {
    padding-right: var(--swa-space-6);
    padding-left: 0;
}

/* Blockquote border */
.swa-rtl blockquote {
    border-right: 4px solid var(--swa-primary);
    border-left: none;
    padding-right: var(--swa-space-4);
    padding-left: 0;
}

/* Status timeline line position */
.swa-rtl .swa-status-timeline::before {
    right: 12px;
    left: auto;
}

.swa-rtl .swa-status-timeline__dot {
    right: calc(-1 * var(--swa-space-8) + 4px);
    left: auto;
}

/* Disclaimer border */
.swa-rtl .swa-disclaimer {
    border-right: 4px solid var(--swa-warning);
    border-left: none;
}

/* Modal close button position */
.swa-rtl .swa-modal-close {
    right: auto;
    left: var(--swa-space-4);
}

/* Search input icon */
.swa-rtl .swa-search-icon {
    right: auto;
    left: var(--swa-space-3);
}

/* Checkbox/Radio alignment */
.swa-rtl .swa-checkbox,
.swa-rtl .swa-radio {
    margin-left: var(--swa-space-2);
    margin-right: 0;
}

/* Select dropdown arrow */
.swa-rtl select {
    background-position: left var(--swa-space-3) center;
    padding-right: var(--swa-space-4);
    padding-left: var(--swa-space-10);
}

/* Badge with icon */
.swa-rtl .swa-badge-icon {
    margin-left: var(--swa-space-1);
    margin-right: 0;
}

/* Card actions alignment */
.swa-rtl .swa-card-actions {
    text-align: left;
}

/* Float corrections */
.swa-rtl .swa-float-left {
    float: right;
}

.swa-rtl .swa-float-right {
    float: left;
}

/* Price display */
.swa-rtl .swa-price-currency {
    order: 1;
}

/* Navigation dropdown */
.swa-rtl .swa-nav-dropdown {
    right: 0;
    left: auto;
}

/* Tooltip position */
.swa-rtl .swa-tooltip::after {
    right: auto;
    left: 50%;
    transform: translateX(50%);
}

/* Admin specific RTL */
.swa-rtl .swa-admin-sidebar {
    right: 0;
    left: auto;
}

.swa-rtl .swa-admin-content {
    margin-right: 280px;
    margin-left: 0;
}

/* Phone numbers LTR */
.swa-rtl .swa-phone-number,
.swa-rtl [dir="ltr"] {
    direction: ltr;
    text-align: right;
}

/* Email addresses LTR */
.swa-rtl .swa-email {
    direction: ltr;
    text-align: right;
}

/* Code blocks LTR */
.swa-rtl code,
.swa-rtl pre {
    direction: ltr;
    text-align: left;
}

/* Animation directions */
.swa-rtl .swa-slide-in {
    animation-name: swa-slide-in-rtl;
}

@keyframes swa-slide-in-rtl {
    from {
        transform: translateX(20px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* ==========================================================================
   WooCommerce RTL Overrides
   ========================================================================== */

.swa-rtl .woocommerce table.shop_table th,
.swa-rtl .woocommerce table.shop_table td {
    text-align: right;
}

.swa-rtl .woocommerce .quantity .qty {
    padding-right: var(--swa-space-3);
}

.swa-rtl .woocommerce .products .star-rating {
    float: right;
}

.swa-rtl .woocommerce-message::before,
.swa-rtl .woocommerce-info::before,
.swa-rtl .woocommerce-error::before {
    right: 0;
    left: auto;
}

.swa-rtl .woocommerce form .form-row-first {
    float: right;
}



/* ==========================================================================
   Footer RTL Overrides
   ========================================================================== */

/* Footer bottom layout - payment icons on left, copyright on right in RTL */
.swa-rtl .swa-footer__bottom {
    flex-direction: row-reverse;
}

@media (max-width: 767px) {
    .swa-rtl .swa-footer__bottom {
        flex-direction: column-reverse;
    }
}

/* Footer links hover effect */
.swa-rtl .swa-footer__links-column ul li a:hover {
    padding-inline-start: 0;
    padding-inline-end: var(--swa-space-1);
}



/* Footer social links */
.swa-rtl .swa-social-links {
    flex-direction: row;
}
