/* ==========================================================================
   RTL — Arabic / Right-to-Left Overrides for Dcodz Theme
   ========================================================================== */

/* -----------------------------------------------------------------------
   Base RTL Direction
   ----------------------------------------------------------------------- */
html[dir="rtl"] {
  overflow-x: hidden;
}

body.rtl {
  direction: rtl;
  font-family: var(--font-arabic), var(--font-body);
  overflow-x: hidden;
}

/* -----------------------------------------------------------------------
   Arabic Font Override
   ----------------------------------------------------------------------- */
body.rtl h1,
body.rtl h2,
body.rtl h3,
body.rtl h4,
body.rtl h5,
body.rtl h6,
body.rtl .h1,
body.rtl .h2,
body.rtl .h3,
body.rtl .h4,
body.rtl .h5,
body.rtl .h6 {
  font-family: var(--font-arabic), var(--font-display);
}

body.rtl .section-title,
body.rtl .section-subtitle {
  font-family: var(--font-arabic);
}

/* -----------------------------------------------------------------------
   Header RTL Adjustments
   ----------------------------------------------------------------------- */
body.rtl .site-header {
  overflow-x: clip;
}

body.rtl .site-header__inner {
  direction: rtl;
}

body.rtl .site-header__nav {
  flex: 1;
  min-inline-size: 0;
  overflow: hidden;
}

body.rtl .nav-menu {
  direction: rtl;
  flex-wrap: nowrap;
  gap: 0;
}

body.rtl .nav-menu li a {
  font-family: var(--font-arabic), var(--font-body);
  font-size: clamp(0.625rem, 0.55rem + 0.3vw, 0.8125rem);
  padding-inline: var(--space-1);
  white-space: nowrap;
}

body.rtl .site-header__cta {
  font-size: var(--text-xs);
  padding: var(--space-2) var(--space-4);
  white-space: nowrap;
}

body.rtl .hero__paragraph {
  max-inline-size: 900px;
  margin-inline: auto;
}

body.rtl .site-logo__text {
  margin-inline-start: var(--space-2);
}

/* Mobile nav slides from left in RTL */
body.rtl .mobile-nav,
body.rtl .mobile-menu {
  transform: translateX(-100%);
}

body.rtl .mobile-nav--open,
body.rtl .mobile-menu[aria-hidden="false"] {
  transform: translateX(0);
}

/* -----------------------------------------------------------------------
   Hero RTL
   ----------------------------------------------------------------------- */
body.rtl .hero__content {
  text-align: center;
}

/* -----------------------------------------------------------------------
   Process Timeline — Mirror for RTL
   ----------------------------------------------------------------------- */
body.rtl .process__timeline::before,
body.rtl .process__timeline-line {
  inset-inline-start: auto;
  inset-inline-end: 20px;
}

body.rtl .process__step,
body.rtl .process-step {
  padding-inline-start: 0;
  padding-inline-end: var(--space-16);
}

body.rtl .process__step-number,
body.rtl .process-step__number {
  inset-inline-start: auto;
  inset-inline-end: 0;
}

body.rtl .process-step__content {
  text-align: start;
}

/* -----------------------------------------------------------------------
   Startup Timeline — Mirror
   ----------------------------------------------------------------------- */
body.rtl .startup-timeline__line,
body.rtl .startup-mvp__timeline-line {
  inset-inline-start: auto;
  inset-inline-end: 28px;
}

body.rtl .startup-phase,
body.rtl .mvp-phase {
  padding-inline-start: 0;
  padding-inline-end: calc(56px + var(--space-6));
}

body.rtl .startup-phase__number,
body.rtl .mvp-phase__badge {
  inset-inline-start: auto;
  inset-inline-end: var(--space-6);
}

/* -----------------------------------------------------------------------
   Floating Actions — Position left in RTL
   ----------------------------------------------------------------------- */
body.rtl .floating-actions,
body.rtl .floating-cta {
  inset-inline-end: auto;
  inset-inline-start: var(--space-6);
}

body.rtl .floating-btn__label {
  inset-inline-end: calc(100% + var(--space-3));
  inset-inline-start: auto;
}

/* -----------------------------------------------------------------------
   Form Select Arrow
   ----------------------------------------------------------------------- */
body.rtl .form-select {
  background-position: left var(--space-4) center;
  padding-inline-end: var(--space-4);
  padding-inline-start: var(--space-10);
}

/* -----------------------------------------------------------------------
   FAQ Icon Positioning
   ----------------------------------------------------------------------- */
body.rtl .faq__question {
  text-align: start;
}

/* -----------------------------------------------------------------------
   Testimonials Slider — Flip scroll direction
   ----------------------------------------------------------------------- */
body.rtl .testimonials__slider {
  direction: rtl;
}

/* -----------------------------------------------------------------------
   Blockquote Border
   ----------------------------------------------------------------------- */
body.rtl blockquote {
  border-inline-start: 4px solid var(--color-blue);
  border-inline-end: none;
}

/* -----------------------------------------------------------------------
   Animation Direction Flips
   ----------------------------------------------------------------------- */
body.rtl .reveal--left {
  transform: translateX(40px);
}

body.rtl .reveal--left.active {
  transform: translateX(0);
}

body.rtl .reveal--right {
  transform: translateX(-40px);
}

body.rtl .reveal--right.active {
  transform: translateX(0);
}

/* -----------------------------------------------------------------------
   Code Decorations Flip
   ----------------------------------------------------------------------- */
body.rtl .startup-section__code-decoration--1 {
  inset-inline-end: auto;
  inset-inline-start: 5%;
  transform: rotate(-3deg);
}

body.rtl .startup-section__code-decoration--2 {
  inset-inline-start: auto;
  inset-inline-end: 3%;
  transform: rotate(2deg);
}

/* -----------------------------------------------------------------------
   Contact Section RTL
   ----------------------------------------------------------------------- */
body.rtl .contact__info-item {
  text-align: start;
}

/* -----------------------------------------------------------------------
   Progress Bar RTL
   ----------------------------------------------------------------------- */
body.rtl .progress-bar__fill {
  inset-inline-start: auto;
  inset-inline-end: 0;
}

/* -----------------------------------------------------------------------
   Letter Spacing Reduction for Arabic
   ----------------------------------------------------------------------- */
body.rtl * {
  letter-spacing: 0 !important;
}

/* -----------------------------------------------------------------------
   List Adjustments
   ----------------------------------------------------------------------- */
body.rtl .lead-magnet__benefit,
body.rtl .startup-phase__deliverable,
body.rtl .footer-contact__item {
  text-align: start;
}

/* -----------------------------------------------------------------------
   Navigation Dropdown RTL
   ----------------------------------------------------------------------- */
body.rtl .site-nav__dropdown-menu {
  inset-inline-start: auto;
  inset-inline-end: 0;
}

/* -----------------------------------------------------------------------
   Footer RTL
   ----------------------------------------------------------------------- */
body.rtl .site-footer__copyright {
  text-align: center;
}

body.rtl .footer-links__link {
  text-align: start;
}
