/* ============================================================
   Kryzel brand + RTL overrides for FOSSBilling (huraga theme)
   Loaded AFTER huraga.css. Managed by _kryzel-brand/apply.sh
   ============================================================ */

/* ---- Brand colour: Kryzel blue ---- */
:root,
[data-bs-theme="light"] {
    --bs-primary: #001E99;
    --bs-primary-rgb: 0, 30, 153;
    --bs-link-color: #001E99;
    --bs-link-color-rgb: 0, 30, 153;
    --bs-link-hover-color: #001670;
}
[data-bs-theme="dark"] {
    --bs-primary: #6e88ff;
    --bs-primary-rgb: 110, 136, 255;
    --bs-link-color: #6e88ff;
    --bs-link-color-rgb: 110, 136, 255;
    --bs-link-hover-color: #8aa0ff;
}

/* Buttons / active states that use the primary colour directly */
.btn-primary {
    --bs-btn-bg: #001E99;
    --bs-btn-border-color: #001E99;
    --bs-btn-hover-bg: #001670;
    --bs-btn-hover-border-color: #001670;
    --bs-btn-active-bg: #001454;
    --bs-btn-active-border-color: #001454;
}

/* ---- RTL (Hebrew) ---- */
[dir="rtl"] body { text-align: right; }

/* Generic logical-margin fixes for Bootstrap utility spacing that
   doesn't auto-flip with the LTR stylesheet */
[dir="rtl"] .me-1,[dir="rtl"] .me-2,[dir="rtl"] .me-3 { margin-right: 0 !important; }
[dir="rtl"] .me-1 { margin-left: .25rem !important; }
[dir="rtl"] .me-2 { margin-left: .5rem  !important; }
[dir="rtl"] .me-3 { margin-left: 1rem   !important; }
[dir="rtl"] .ms-1,[dir="rtl"] .ms-2,[dir="rtl"] .ms-3 { margin-left: 0 !important; }
[dir="rtl"] .ms-1 { margin-right: .25rem !important; }
[dir="rtl"] .ms-2 { margin-right: .5rem  !important; }
[dir="rtl"] .ms-3 { margin-right: 1rem   !important; }

/* Dropdowns / text alignment */
[dir="rtl"] .text-start { text-align: right !important; }
[dir="rtl"] .text-end   { text-align: left  !important; }
[dir="rtl"] .dropdown-menu { text-align: right; }

/* Kryzel header logo sizing */
.navbar-brand img, .company-logo img { max-height: 40px; width: auto; }
