
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-latin-400-normal.woff2') format('woff2'),
       url('/fonts/inter-latin-400-normal.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-latin-500-normal.woff2') format('woff2'),
       url('/fonts/inter-latin-500-normal.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-latin-600-normal.woff2') format('woff2'),
       url('/fonts/inter-latin-600-normal.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-latin-700-normal.woff2') format('woff2'),
       url('/fonts/inter-latin-700-normal.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-latin-800-normal.woff2') format('woff2'),
       url('/fonts/inter-latin-800-normal.woff2') format('woff2');
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Vazirmatn';
  src: url('../fonts/Vazirmatn-Regular.woff2') format('woff2'),
       url('/fonts/Vazirmatn-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF;
}

@font-face {
  font-family: 'Vazirmatn';
  src: url('../fonts/Vazirmatn-Medium.woff2') format('woff2'),
       url('/fonts/Vazirmatn-Medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF;
}

@font-face {
  font-family: 'Vazirmatn';
  src: url('../fonts/Vazirmatn-SemiBold.woff2') format('woff2'),
       url('/fonts/Vazirmatn-SemiBold.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF;
}

@font-face {
  font-family: 'Vazirmatn';
  src: url('../fonts/Vazirmatn-Bold.woff2') format('woff2'),
       url('/fonts/Vazirmatn-Bold.woff2') format('woff2');
  font-weight: 700 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF;
}

:lang(fa), [dir="rtl"], [dir="rtl"] *, .font-fa, .font-vazir, [lang="fa"], [data-lang="fa"] {
  font-family: 'Vazirmatn', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

body, button, input, textarea, select, h1, h2, h3, h4, h5, h6, p, span, div, a, label {
  font-family: 'Vazirmatn', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Go Again Persian Typography */
#homeGoAgainCard,
#homeGoAgainCard *,
#goAgainSheet,
#goAgainSheet *,
#goAgainDetailsSheet,
#goAgainDetailsSheet * {
  font-family: 'Vazirmatn', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}
#goAgainDestTitle,
#goAgainDestSubtitle,
#goAgainOriginText,
#goAgainDestInput,
#gaDetailsOriginText,
#gaDetailsDestText,
#inputGoAgainTotalPrice {
  font-family: 'Vazirmatn', -apple-system, BlinkMacSystemFont, sans-serif !important;
}

/* Compact Go Again Sheet */
#goAgainSheet {
  height: auto !important;
  max-height: calc(100vh - 80px) !important;
  border-radius: 36px !important;
  overflow: hidden !important;
}
#goAgainSheet .glass-content {
  height: auto !important;
}
#goAgainSheet .sheet-scroll-body {
  padding-left: 20px !important;
  padding-right: 20px !important;
  padding-top: 10px !important;
  padding-bottom: 8px !important;
}

/* Compact Trip & Payment Details Sheet (Apple HIG Dynamic Content Sizing) */
#panel-trip-payment-details {
  height: auto !important;
  max-height: calc(100vh - 70px) !important;
  border-radius: 36px !important;
  overflow: hidden !important;
}
#panel-trip-payment-details > div {
  height: auto !important;
}
#panel-trip-payment-details .sheet-scroll-body {
  max-height: calc(100vh - 180px) !important;
  padding-bottom: 24px !important;
}
#goAgainSheet .liquid-glass-sheet-footer {
  position: relative !important;
  bottom: auto !important;
  padding: 8px 20px 22px 20px !important;
  background: transparent !important;
}

@font-face {
  font-family: 'Aeternum';
  src: url('../fonts/Aeternum-Medium.ttf') format('truetype'),
       url('/fonts/Aeternum-Medium.ttf') format('truetype');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'BBAnonymPro';
  src: url('../fonts/BBAnonymPro-Medium.ttf') format('truetype'),
       url('/fonts/BBAnonymPro-Medium.ttf') format('truetype');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

/* Titles and page/card headers across the entire application */
h1, h2, h3, h4, h5, h6,
.font-display,
.page-title,
.card-title,
.sheet-title {
  font-family: 'BBAnonymPro', 'Vazirmatn', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
}

/* Search and filter inputs text and placeholders across the application */
input[type="search"],
input[id*="search" i],
input[id*="Search"],
input[id*="Filter" i],
input[placeholder*="Search" i],
input[placeholder*="Filter" i],
.search-input {
  font-family: 'BBAnonymPro', 'Vazirmatn', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
}

input[type="search"]::placeholder,
input[id*="search" i]::placeholder,
input[id*="Search"]::placeholder,
input[id*="Filter" i]::placeholder,
input[placeholder*="Search" i]::placeholder,
input[placeholder*="Filter" i]::placeholder,
.search-input::placeholder {
  font-family: 'BBAnonymPro', 'Vazirmatn', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
}

:root {
      --box-w: 390px;
      --box-compact-w: 270px;
      --box-h: 530px;
      --box-r: 34px;
      --box-fill: rgba(255, 255, 255, 0.75);
      --secondary: rgba(191, 191, 191, 0.12);
      --text: #1a1a1a;
      --divider: #e5e5ea;
      --control: #ededed;
      --ios-spring-curve: cubic-bezier(0.25, 1, 0.5, 1);
      --ios-bounce-curve: cubic-bezier(0.175, 0.885, 0.32, 1.15);
      --ios-page-curve: cubic-bezier(0.32, 0.72, 0, 1);
      --ios-reveal-curve: cubic-bezier(0.25, 1, 0.5, 1);
      --spring-duration: 0.28s;
    }

    * {
      box-sizing: border-box;
      -webkit-tap-highlight-color: transparent;
      user-select: none;
    }

    body {
      margin: 0;
      font-family: 'Inter', 'Vazirmatn', -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", sans-serif;
      background-color: #0b0f19;
      color: #f3f4f6;
      min-height: 100vh;
      overflow-x: hidden;
    }

    @media (max-width: 640px) {
      html, body {
        margin: 0;
        padding: 0;
        width: 100%;
        height: 100%;
        min-height: 100%;
        min-height: -webkit-fill-available;
        overflow: hidden !important;
        position: fixed;
        inset: 0;
        background-color: #ffffff;
      }
      #appContainer {
        min-height: 100%;
        min-height: 100dvh;
        min-height: -webkit-fill-available;
      }
    }

    /* Enforce clean sans-serif Inter typography on code/tags */
    code, kbd, samp, pre, .font-mono {
      font-family: 'Inter', 'Vazirmatn', -apple-system, BlinkMacSystemFont, sans-serif !important;
      font-weight: 600;
      letter-spacing: -0.01em;
    }

    /* 120Hz Zero-Delay Touch Feedback across all interactive components */
    html,
    body,
    #appContainer,
    #deviceScreen,
    button,
    a,
    input,
    select,
    textarea,
    .tactile-press,
    [role="button"],
    .ios-cell,
    .ride-card,
    .notif-item,
    .carousel-dot,
    .dock-container,
    #loadingPillContainer,
    #loadingPillContainer * {
      touch-action: manipulation;
      -webkit-tap-highlight-color: transparent;
    }

    /* 120Hz Smooth Native Scrollable Elements */
    .clean-scroll,
    .scroll-viewport,
    .scroll-content,
    /* Outer chassis must NEVER scroll or rubber-band */
    html, body, #appContainer, #deviceScreen {
      overscroll-behavior-y: none !important;
    }

    /* Scrollable Containers: allow local bounce on iOS WebKit without chaining */
    .clean-scroll,
    .home-scroll-area,
    #homeScrollArea,
    #notificationView,
    #findRideView,
    #matesView,
    #clubScrollArea,
    #profileScrollBody,
    #walletView,
    .ios-sheet .overflow-y-auto,
    .ios-sheet .overflow-auto,
    .cr-sheet-scroll,
    .sheet-scroll-body {
      -webkit-overflow-scrolling: touch !important;
      touch-action: pan-y !important;
      overscroll-behavior-y: auto !important;
    }

    /* 120Hz Compositor Layer Promotion & Hardware Acceleration */
    .ios-sheet,
    .ios-nested-sheet,
    .cr-campus-sheet,
    .page-view {
      -webkit-transform: translateZ(0);
      transform: translateZ(0);
      -webkit-backface-visibility: hidden;
      backface-visibility: hidden;
    }

    /* Mobile Smooth Scrolling and Viewport Containment */
    #trip-list > *,
    #tripsContainer > *,
    #notifList > * {
      content-visibility: auto;
      contain-intrinsic-size: 0 76px;
    }

    .tactile-press {
      transition: transform 0.12s cubic-bezier(0.2, 0.8, 0.4, 1);
      will-change: transform;
    }
    .tactile-press:active, .tactile-press.is-pressed {
      transform: translateY(1px) scale(0.975) !important;
    }

    .ios-glass-surface {
      position: relative;
      background: #ffffff !important;
      border-radius: var(--box-r);
      border: 1px solid rgba(0, 0, 0, 0.08) !important;
      box-shadow:
        0 10px 30px rgba(0, 0, 0, 0.20),
        0 2px 6px rgba(0, 0, 0, 0.04) !important;
      backdrop-filter: none !important;
      -webkit-backdrop-filter: none !important;
      overflow: hidden;
      contain: paint;
    }

    .ios-glass-surface::before {
      display: none !important;
    }

    .glass-content {
      position: relative;
      z-index: 2;
    }

    .carousel-slide {
      position: absolute !important;
      inset: 0 !important;
      width: 100% !important;
      height: 100% !important;
      opacity: 0;
      transform: translate3d(100%, 0, 0);
      transition: transform 0.42s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.35s ease;
      pointer-events: none;
      will-change: transform, opacity;
    }
    .carousel-slide.active-slide {
      opacity: 1;
      transform: translate3d(0, 0, 0);
      pointer-events: auto;
    }
    .carousel-slide.prev-slide {
      opacity: 0;
      transform: translate3d(-100%, 0, 0);
      pointer-events: none;
    }
    .carousel-dot { transition: all 0.3s cubic-bezier(0.2, 0.8, 0.4, 1); }

    /* Progressive blur overlays disabled to remove blur ON the sheets and avoid GPU cost */
    .progressive-blur-top,
    .progressive-blur-dock {
      display: none !important;
    }

    .ride-card {
      position: relative;
      transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
      background-color: transparent;
    }
    .ride-card:hover {
      background-color: rgba(255, 255, 255, 0.85);
    }
    .ride-card.is-selected {
      background-color: #ffffff;
      box-shadow: 0 4px 14px -2px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0, 0, 0, 0.05);
      border-color: rgba(0, 0, 0, 0.08);
    }
    .ride-card .check-badge {
      opacity: 0;
      transform: scale(0.6);
      transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    }
    .ride-card.is-selected .check-badge {
      opacity: 1;
      transform: scale(1);
    }
    .ride-card .vehicle-icon {
      opacity: 1;
      transform: scale(1);
      transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    }
    .ride-card.is-selected .vehicle-icon {
      opacity: 0;
      transform: scale(0.6);
    }

    .device-screen {
      transform-origin: center top;
      transition: none;
    }

    .device-screen.recessed {
      transform: none !important;
      filter: none !important;
      pointer-events: none;
    }

    .device-screen.recessed > :not(.sheet-scrim):not(.ios-sheet):not(.ios-nested-sheet):not(#pageViewsAnchor) {
      pointer-events: none;
    }

    .sheet-scrim {
      position: absolute;
      inset: 0;
      z-index: 30 !important;
      transition: opacity var(--spring-duration) ease, visibility 0s linear var(--spring-duration);
      opacity: 0;
      visibility: hidden;
      pointer-events: none;
      will-change: opacity;
      background: rgba(15, 23, 42, 0.45) !important;
      backdrop-filter: none !important;
      -webkit-backdrop-filter: none !important;
    }
    .sheet-scrim.visible {
      opacity: 1;
      visibility: visible;
      pointer-events: auto !important;
      transition: opacity var(--spring-duration) ease, visibility 0s linear 0s;
    }

    .ios-sheet {
      position: absolute;
      left: 0;
      right: 0;
      bottom: 14px;
      margin: 0 auto;
      width: calc(100% - 24px);
      max-width: 480px;
      border-radius: var(--box-r, 36px);
      transform: translate3d(0, calc(100% + 40px), 0);
      transition: transform var(--spring-duration) var(--ios-spring-curve), 
                  filter var(--spring-duration) ease,
                  visibility 0s linear var(--spring-duration);
      will-change: transform, filter;
      contain: paint;
      z-index: 40;
      touch-action: none;
      visibility: hidden;
      pointer-events: none;
      background: #ffffff !important;
      backdrop-filter: none !important;
      -webkit-backdrop-filter: none !important;
    }
    .ios-sheet.open {
      visibility: visible;
      pointer-events: auto !important;
      transform: translate3d(0, 0, 0);
      transition: transform var(--spring-duration) var(--ios-spring-curve),
                  filter var(--spring-duration) ease,
                  visibility 0s linear 0s;
    }
    .ios-sheet.dragging { 
      transition: none !important; 
      visibility: visible !important;
      pointer-events: auto !important;
    }

    .ios-sheet.stacked-compressed {
      transform: scale(0.94) translateY(-16px) !important;
      filter: brightness(0.90) contrast(1.02) !important;
      pointer-events: none !important;
      transition: transform var(--spring-duration) var(--ios-spring-curve),
                  filter var(--spring-duration) ease !important;
    }

    .ios-nested-sheet {
      position: absolute;
      left: 0;
      right: 0;
      bottom: 12px;
      margin: 0 auto;
      width: calc(100% - 20px);
      max-width: 350px;
      transform: translate3d(0, calc(100% + 40px), 0);
      transition: transform var(--spring-duration) var(--ios-spring-curve),
                  visibility 0s linear var(--spring-duration);
      will-change: transform;
      z-index: 50;
      border-radius: 32px;
      touch-action: none;
      visibility: hidden;
      pointer-events: none;
      background: #ffffff !important;
      border: 1px solid rgba(0, 0, 0, 0.08) !important;
      box-shadow: 0 18px 45px rgba(0, 0, 0, 0.24) !important;
      backdrop-filter: none !important;
      -webkit-backdrop-filter: none !important;
    }
    .ios-nested-sheet.open { 
      visibility: visible;
      pointer-events: auto !important;
      transform: translate3d(0, 0, 0); 
      transition: transform var(--spring-duration) var(--ios-spring-curve),
                  visibility 0s linear 0s;
    }

    .cr-sheet-backdrop {
      position: absolute;
      inset: 0;
      background: rgba(0, 0, 0, 0.38);
      backdrop-filter: blur(8px);
      -webkit-backdrop-filter: blur(8px);
      opacity: 0;
      visibility: hidden;
      pointer-events: none;
      transition: opacity 0.35s ease, visibility 0s linear 0.35s;
      z-index: 45;
    }
    .cr-sheet-backdrop.active {
      opacity: 1;
      visibility: visible;
      pointer-events: auto;
      transition: opacity 0.35s ease, visibility 0s linear 0s;
    }

    #campusSelectNestedSheet,
    .cr-campus-sheet {
      position: absolute !important;
      left: 0;
      right: 0;
      bottom: 16px;
      margin: 0 auto;
      width: calc(100% - 24px);
      max-width: 390px;
      height: 375px;
      max-height: calc(100% - 90px);
      transform: translate3d(0, calc(100% + 40px), 0);
      transition: transform var(--spring-duration) var(--ios-spring-curve),
                  height 0.38s var(--ios-spring-curve),
                  visibility 0s linear var(--spring-duration);
      transform-origin: bottom center;
      will-change: transform, height;
      z-index: 60;
      border-radius: 36px !important;
      visibility: hidden;
      pointer-events: none;
      background: #ffffff !important;
      contain: paint;
      isolation: isolate;
      box-shadow: 
        0 28px 65px -12px rgba(0, 0, 0, 0.18),
        0 0 0 1px rgba(0, 0, 0, 0.05) !important;
      overflow: hidden !important;
    }
    #campusSelectNestedSheet.open,
    .cr-campus-sheet.open {
      visibility: visible;
      pointer-events: auto !important;
      transform: translate3d(0, 0, 0);
      transition: transform var(--spring-duration) var(--ios-spring-curve),
                  height 0.38s var(--ios-spring-curve),
                  visibility 0s linear 0s;
    }
    #campusSelectNestedSheet.is-expanded,
    .cr-campus-sheet.is-expanded {
      height: min(580px, calc(100% - 70px)) !important;
    }

    .ios-sheet.rides-sheet {
      bottom: 14px;
      width: calc(100% - 24px);
      max-width: 480px;
      border-radius: var(--box-r, 36px);
    }

    .ios-grab-pill {
      width: 36px;
      height: 4.8px;
      background-color: rgba(60, 60, 67, 0.32);
      border-radius: 9999px;
      transition: transform 0.2s ease, background-color 0.2s ease, width 0.2s ease;
    }
    .ios-sheet.dragging .ios-grab-pill, .ios-grab-pill.active-drag {
      background-color: rgba(60, 60, 67, 0.65);
      width: 48px;
    }
    .ios-sheet [id*="DragZone"], .ios-sheet [id*="dragZone"], .ios-sheet .cursor-grab {
      touch-action: none !important;
      user-select: none !important;
      cursor: grab;
    }
    .ios-sheet.dragging [id*="DragZone"], .ios-sheet.dragging [id*="dragZone"], .ios-sheet.dragging .cursor-grab {
      cursor: grabbing !important;
    }

    .ios-cell { transition: background-color 0.15s ease, transform 0.12s cubic-bezier(0.2, 0.8, 0.4, 1); }
    .ios-cell:active { background-color: rgba(0, 0, 0, 0.05); transform: translateY(1px) scale(0.985); }

    .scroll-content {
      will-change: transform, translate;
      transform: translate3d(0, 0, 0);
      touch-action: pan-y;
    }
    .scroll-content.is-rebounding {
      transition: transform 0.38s cubic-bezier(0.22, 1, 0.36, 1), translate 0.38s cubic-bezier(0.22, 1, 0.36, 1);
    }

    .clean-scroll {
      -webkit-overflow-scrolling: touch;
      overscroll-behavior-y: contain;
      scrollbar-width: none;
    }
    .clean-scroll::-webkit-scrollbar { display: none; }

    .scroll-edge-mask {
      -webkit-mask-image: none !important;
      mask-image: none !important;
    }

    .top-edge-blur {
      position: absolute; left: 0; right: 0; top: 0; height: 60px; pointer-events: none; z-index: 20;
      background: linear-gradient(180deg, rgba(255, 255, 255, 0.85) 0%, rgba(255, 255, 255, 0.45) 45%, rgba(255, 255, 255, 0.12) 75%, rgba(255, 255, 255, 0) 100%);
      backdrop-filter: none !important;
      -webkit-backdrop-filter: none !important;
      -webkit-mask-image: none !important;
      mask-image: none !important;
    }

    /* Fixed top header layer helper */
    .page-fixed-header {
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      z-index: 25;
      pointer-events: auto;
      display: flex;
      align-items: center;
      justify-content: space-between;
      width: 100%;
      box-sizing: border-box;
    }

    /* Standardized Top Navigation Title Capsule */
    .header-title-capsule {
      display: inline-flex;
      align-items: center;
      gap: 0.5rem;
      width: max-content;
      max-width: calc(100% - 90px);
      border-radius: 9999px;
      background-color: rgba(255, 255, 255, 0.95);
      border: 1px solid rgba(226, 232, 240, 0.85);
      box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.04);
      padding: 0.5rem 0.875rem; /* py-2 px-3.5 */
      box-sizing: border-box;
      flex-shrink: 0;
    }

    /* Strict Title Typography Bounds: 18px-22px, weight: 700, tracking: normal to tight */
    .header-title-capsule h1,
    .header-title-capsule h2,
    .header-title-capsule .header-title-text {
      font-size: 19px !important;
      font-weight: 700 !important;
      letter-spacing: -0.01em !important;
      line-height: 1 !important;
      color: #0f172a;
      margin: 0 !important;
      padding: 0 !important;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    /* Screen icon inside title capsule */
    .header-title-capsule .header-screen-icon {
      width: 1.125rem;
      height: 1.125rem;
      flex-shrink: 0;
      color: #334155;
      display: inline-flex;
      align-items: center;
      justify-content: center;
    }

    /* Home Profile Capsule: Fluid Transition between Trippy SVG and Real Name */
    #homeProfileCapsule {
      transition: width 0.28s cubic-bezier(0.32, 0.72, 0, 1),
                  max-width 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    }

    #homeTrippyLogo {
      display: flex;
      align-items: center;
      transition: opacity 0.2s ease, transform 0.2s ease;
    }

    #homeTrippyLogo svg {
      height: 15px;
      width: auto;
      display: block;
    }

    #homeUserNameWrap {
      transition: opacity 0.2s ease, transform 0.2s ease;
    }

    /* Header action container aligned to far right */
    .header-actions {
      display: flex;
      align-items: center;
      gap: 0.5rem;
      flex-shrink: 0;
    }

    /* Search bars: subtle transparent background when idle, pure white #FFFFFF on focus */
    #routeSearchInput,
    .route-search-input,
    #mateSearchBox,
    .mate-search-box {
      background: rgba(255, 255, 255, 0.70) !important;
      border: 1px solid rgba(0, 0, 0, 0.08) !important;
      transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease !important;
    }
    #routeSearchInput:focus,
    .route-search-input:focus,
    #mateSearchBox:focus-within,
    .mate-search-box:focus-within {
      background: #ffffff !important;
      border-color: rgba(0, 0, 0, 0.16) !important;
      box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06) !important;
    }

    .bottom-edge-blur {
      position: absolute; left: 0; right: 0; bottom: 0; height: 50px; pointer-events: none; z-index: 20;
      background: linear-gradient(0deg, rgba(255, 255, 255, 0.85) 0%, rgba(255, 255, 255, 0.45) 45%, rgba(255, 255, 255, 0.12) 75%, rgba(255, 255, 255, 0) 100%);
      backdrop-filter: none !important;
      -webkit-backdrop-filter: none !important;
      -webkit-mask-image: none !important;
      mask-image: none !important;
    }

    /* Desktop and sheet guardrails: disable bottom-edge blur layer to avoid dark rounded corner bleeding */
    @media (min-width: 640px) {
      .bottom-edge-blur,
      #bottomEdgeBlurLayer {
        display: none !important;
      }
    }

    body[data-active-page] #bottomEdgeBlurLayer,
    .sheet-scrim.visible ~ #bottomEdgeBlurLayer,
    .sheet-scrim.active ~ #bottomEdgeBlurLayer,
    #deviceScreen:has(.ios-sheet.open) #bottomEdgeBlurLayer,
    #deviceScreen:has(.ios-nested-sheet.open) #bottomEdgeBlurLayer {
      display: none !important;
    }

    .busy-bg-morning,
    #deviceScreen.busy-bg-morning .page-view,
    #deviceScreen.busy-bg-morning #homeView {
      background: radial-gradient(320px 250px at 15% 26%, rgba(254, 240, 138, 0.80), transparent 75%), radial-gradient(300px 240px at 85% 34%, rgba(253, 186, 116, 0.70), transparent 75%), linear-gradient(180deg, #fefce8 0%, #fdf4ff 35%, #f8fafc 70%, #f1f5f9 100%) !important;
    }
    .busy-bg-afternoon,
    #deviceScreen.busy-bg-afternoon .page-view,
    #deviceScreen.busy-bg-afternoon #homeView {
      background: radial-gradient(320px 250px at 20% 28%, rgba(251, 191, 36, 0.70), transparent 75%), radial-gradient(300px 240px at 80% 36%, rgba(248, 113, 113, 0.55), transparent 75%), linear-gradient(180deg, #ffedd5 0%, #fae8ff 38%, #f8fafc 72%, #f1f5f9 100%) !important;
    }
    .busy-bg-night,
    #deviceScreen.busy-bg-night .page-view,
    #deviceScreen.busy-bg-night #homeView {
      background: radial-gradient(330px 260px at 22% 26%, rgba(199, 210, 254, 0.90), transparent 75%), radial-gradient(300px 240px at 82% 32%, rgba(221, 214, 254, 0.80), transparent 75%), linear-gradient(180deg, #e0e7ff 0%, #ede9fe 34%, #f1f5f9 68%, #e2e8f0 100%) !important;
    }


    /* Ambient Noisy Grained Gradient Surface Overlay (1:1 with Profile Hub) */
    .ambient-grain {
      background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.82' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
      background-size: 110px 110px;
    }

/* Apple Fluid Text Blur -> Transmit Rule */
.ios-fluid-text {
  display: inline-block;
  transition: filter 0.22s cubic-bezier(0.18, 0.89, 0.32, 1),
              opacity 0.22s ease,
              transform 0.24s cubic-bezier(0.18, 0.89, 0.32, 1);
  will-change: filter, opacity, transform;
}
.ios-fluid-text.is-blurring {
  filter: blur(8px);
  opacity: 0.18;
  transform: translateY(2px) scale(0.97);
}

/* Apple Breathing / Blinking Text Animation (GPU-composited opacity & subtle scale) */
@keyframes appleBreathing {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.99); }
}
.apple-breathing-text {
  animation: appleBreathing 1.8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
  will-change: opacity, transform;
}

/* iOS Tabular Rolling Counter with Directional Motion Blur */
.ios-rolling-counter {
  display: inline-flex;
  align-items: center;
  height: 1.3em;
  line-height: 1.3em;
  overflow: hidden;
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
  vertical-align: middle;
}
.ios-rolling-col {
  display: inline-flex;
  flex-direction: column;
  height: 1.3em;
  width: 0.62em;
  overflow: hidden;
  position: relative;
  text-align: center;
}
.ios-rolling-strip {
  display: flex;
  flex-direction: column;
  transition: transform 0.44s cubic-bezier(0.18, 0.89, 0.32, 1.08), filter 0.26s ease;
  will-change: transform, filter;
}
.ios-rolling-strip.is-rolling {
  filter: blur(1.5px);
}
.ios-rolling-digit {
  height: 1.3em;
  line-height: 1.3em;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.ios-rolling-char {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 1.3em;
  line-height: 1.3em;
}

.page-stretch-container {
  transition: transform var(--spring-duration) var(--ios-spring-curve);
  will-change: transform;
}
.page-stretch-container.is-pulling {
  transition: none !important;
}

.pull-reveal-indicator {
  transition: opacity 0.25s ease, transform 0.25s ease;
  will-change: opacity, transform;
}

/* ---- Multi-page view system with iOS Push/Pop Animations ---- */
.nav-stack-container {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.page-view {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 0;
  transform: translate3d(100%, 0, 0);
  filter: brightness(1);
  background: radial-gradient(320px 250px at 15% 26%, rgba(254, 240, 138, 0.80), transparent 75%), radial-gradient(300px 240px at 85% 34%, rgba(253, 186, 116, 0.70), transparent 75%), linear-gradient(180deg, #fefce8 0%, #fdf4ff 35%, #f8fafc 70%, #f1f5f9 100%);
  opacity: 1;
  box-shadow: none;
  transition: transform var(--spring-duration) var(--ios-page-curve);
  will-change: transform;
  pointer-events: none;
  z-index: 25;
  isolation: isolate;
  display: none;
}

.page-view.page-active {
  display: block;
  transform: translate3d(0, 0, 0);
  box-shadow: -12px 0 32px rgba(0, 0, 0, 0.22);
  pointer-events: auto;
  z-index: 25;
}

#pageClub {
  background: #f8fafc !important;
  background-color: #f8fafc !important;
}

.page-view.is-transitioning,
.page-view.is-dragging {
  display: block;
  box-shadow: -12px 0 32px rgba(0, 0, 0, 0.22);
}

.page-view.page-recessed {
  transform: translate3d(-28%, 0, 0);
  pointer-events: none;
  z-index: 5;
}

.page-view.is-recessed-hidden,
#homeView.is-recessed-hidden {
  visibility: hidden !important;
  pointer-events: none !important;
}

.page-view.is-dragging {
  transition: none !important;
}

#homeView {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block !important;
  pointer-events: auto !important;
  background: inherit;
  transform: translate3d(0, 0, 0);
  transition: transform var(--spring-duration) var(--ios-page-curve);
  will-change: transform;
  z-index: 10;
}

#homeView.page-recessed {
  transform: translate3d(-28%, 0, 0);
  filter: brightness(0.86);
  pointer-events: none !important;
}

body[data-active-page] #homeView #topEdgeBlurLayer,
body[data-active-page] #homeView .top-edge-blur,
body[data-active-page] #bottomEdgeBlurLayer,
body[data-active-page] #bottomNav {
  opacity: 0 !important;
  display: none !important;
  pointer-events: none !important;
}

body[data-active-page] .backdrop-blur-xl {
  opacity: 0 !important;
  transform: translate3d(0, 32px, 0) scale(0.95);
  pointer-events: none !important;
  transition: opacity 0.28s ease, transform 0.28s var(--ios-spring-curve);
}

.backdrop-blur-xl {
  transition: opacity 0.28s ease, transform 0.28s var(--ios-spring-curve);
}

/* Desktop Hardware Chassis & Mobile Responsive Ratio */
@media (min-width: 640px) {
  body {
    background-color: #0b0f19 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 1.5rem !important;
    min-height: 100vh !important;
  }
  #appContainer {
    max-width: 390px !important;
    height: 780px !important;
    max-height: 96vh !important;
    border-radius: 52px !important;
    padding: 11px !important;
    background: #000000 !important;
    box-shadow: 0 25px 60px -15px rgba(0,0,0,0.8), 0 0 0 1px rgba(255,255,255,0.12), inset 0 0 4px 2px rgba(255,255,255,0.18) !important;
  }
  #deviceScreen {
    border-radius: 42px !important;
  }
}

@media (max-width: 639px) {
  body {
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
    display: block !important;
    align-items: flex-start !important;
    justify-content: flex-start !important;
  }
  #appContainer {
    width: 100% !important;
    max-width: 100% !important;
    height: 100dvh !important;
    height: 100% !important;
    max-height: 100% !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
  }
  #deviceScreen {
    width: 100% !important;
    height: 100% !important;
    min-height: 100% !important;
    border-radius: 0 !important;
  }
}

/* iOS Fluid List Filtering Transitions (Blur -> Fade -> Seat Exchange) */
.ios-filterable-card {
  transition: transform 0.38s cubic-bezier(0.18, 0.89, 0.32, 1),
              opacity 0.28s ease,
              filter 0.28s ease,
              max-height 0.38s cubic-bezier(0.16, 1, 0.3, 1),
              margin 0.35s ease,
              padding 0.35s ease,
              border-color 0.2s ease !important;
  will-change: transform, opacity, filter, max-height;
  transform-origin: top center;
  overflow: hidden;
  max-height: 260px;
  opacity: 1;
  filter: blur(0);
  transform: translateY(0) scale(1);
}

.ios-filterable-card.is-filtered-out {
  opacity: 0 !important;
  filter: blur(10px) !important;
  transform: translateY(-8px) scale(0.92) !important;
  max-height: 0 !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  border-width: 0 !important;
  pointer-events: none !important;
}

@keyframes trippy-shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-6px); }
  40%, 80% { transform: translateX(6px); }
}
.animate-shake {
  animation: trippy-shake 0.35s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

/* =============================================================================
   Fluid Accordion & Morph Transitions (Apple Easing Invariants)
   ============================================================================= */
.fluid-accordion {
  display: grid !important;
  grid-template-rows: 0fr !important;
  opacity: 0 !important;
  transition: grid-template-rows 0.32s cubic-bezier(0.32, 0.72, 0, 1),
              opacity 0.28s ease,
              margin 0.28s ease !important;
  pointer-events: none;
  will-change: grid-template-rows, opacity;
}

.fluid-accordion.is-expanded {
  grid-template-rows: 1fr !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

.fluid-accordion > .fluid-accordion-inner {
  overflow: hidden !important;
  min-height: 0 !important;
}

/* Vertical rolling text slot for stage transitions (Rock-solid overlapping stack) */
.rolling-text-slot {
  position: relative;
  overflow: hidden;
  height: 18px;
  display: inline-grid !important;
  grid-template-columns: 1fr !important;
  grid-template-rows: 1fr !important;
  align-items: center !important;
  justify-items: center !important;
}

.rolling-text-slot > * {
  grid-area: 1 / 1 / 2 / 2 !important;
}

.rolling-text-item {
  display: inline-block;
  white-space: nowrap;
  transition: transform 0.32s cubic-bezier(0.32, 0.72, 0, 1),
              opacity 0.28s ease;
  will-change: transform, opacity;
}

/* Explicit button transitions avoiding Tailwind duration bugs */
.badge-btn-transition {
  transition: background-color 0.35s cubic-bezier(0.32, 0.72, 0, 1),
              border-color 0.35s cubic-bezier(0.32, 0.72, 0, 1),
              color 0.35s ease,
              box-shadow 0.2s ease,
              transform 0.12s cubic-bezier(0.2, 0.8, 0.4, 1) !important;
  will-change: background-color, border-color, color;
}

.badge-icon-morph {
  transition: opacity 0.3s cubic-bezier(0.32, 0.72, 0, 1),
              transform 0.3s cubic-bezier(0.32, 0.72, 0, 1),
              width 0.3s cubic-bezier(0.32, 0.72, 0, 1),
              margin 0.3s cubic-bezier(0.32, 0.72, 0, 1) !important;
  will-change: opacity, transform, width, margin;
}

/* =============================================================================
   UBER x LIQUID GLASS SHEET DESIGN SYSTEM (design/visual-references/sheets.jpg)
   Concentric corners, inset card containers, floating header pill & black pills
   ============================================================================= */
.liquid-glass-sheet {
  border-top-left-radius: 32px !important;
  border-top-right-radius: 32px !important;
  background: #ffffff !important;
  box-shadow: 0 -16px 48px rgba(0, 0, 0, 0.12), 0 -1px 0 rgba(0, 0, 0, 0.04) !important;
  overflow: hidden !important;
}

/* Scrollable Sheet Content with deep bottom padding for progressive dock */
.sheet-scroll-body {
  overflow-y: auto !important;
  -webkit-overflow-scrolling: touch !important;
  touch-action: pan-y !important;
  overscroll-behavior-y: contain !important;
  padding-bottom: 7rem !important; /* pb-28: allows content to flow seamlessly under the floating dock & buttons */
}

/* Progressive Gradient Blur Dock disabled on sheets to eliminate live GPU blur passes */
.progressive-blur-dock {
  display: none !important;
}
.progressive-blur-dock::before,
.progressive-blur-dock::after {
  display: none !important;
}

/* Elevated Fixed Bottom Action Toolbar (Floating over blurred dock, listed-sheets.html) */
.liquid-glass-sheet-footer {
  position: absolute !important;
  bottom: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  padding: 4px 16px 14px 16px !important;
  background: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: none !important;
  z-index: 30 !important;
  pointer-events: auto !important;
  flex-shrink: 0 !important;
}

/* ============================================================
   WHITE SHIMMER PILL BUTTON & EXPANDING SHEET SYSTEM
   (Exact implementation from white_shimmer_pill_button (1).html)
   ============================================================ */
@keyframes shimmerSlide {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: 0% 0;
  }
}

.shimmer-text {
  background: linear-gradient(
    90deg,
    rgba(71, 85, 105, 0.85) 0%,
    rgba(71, 85, 105, 0.85) 24%,
    rgba(148, 163, 184, 0.95) 36%,
    rgba(2, 132, 199, 1) 48%,
    rgba(14, 165, 233, 1) 52%,
    rgba(148, 163, 184, 0.95) 64%,
    rgba(71, 85, 105, 0.85) 76%,
    rgba(71, 85, 105, 0.85) 100%
  );
  background-size: 200% 100%;
  background-repeat: repeat-x;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmerSlide 2.8s infinite linear;
}

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

.spinner-ring {
  border: 2px solid rgba(0, 0, 0, 0.14);
  border-top-color: #000000;
  border-radius: 50%;
  animation: spinnerRotate 0.85s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@keyframes textBlurIn {
  0% {
    opacity: 0;
    filter: blur(10px);
    transform: translate3d(0, 6px, 0);
  }
  100% {
    opacity: 1;
    filter: blur(0px);
    transform: translate3d(0, 0, 0);
  }
}

.animate-badge-enter {
  animation: textBlurIn 0.5s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}

.badge-exit {
  opacity: 0 !important;
  filter: blur(10px);
  transform: translate3d(0, -6px, 0);
  pointer-events: none;
  transition: opacity 0.25s ease, filter 0.25s ease, transform 0.25s ease;
}

.morph-sheet {
  width: 360px;
  max-width: calc(100% - 24px);
  border-radius: 32px;
  height: 58px;
  box-shadow: 
    0 18px 36px -8px rgba(0, 0, 0, 0.3),
    0 6px 14px -3px rgba(0, 0, 0, 0.14),
    0 0 0 1px rgba(0, 0, 0, 0.04);
  transition: height 0.62s cubic-bezier(0.16, 1, 0.3, 1);
  transform-origin: bottom center;
}

.dock-container {
  transition: transform 0.5s cubic-bezier(0.32, 0.72, 0, 1),
              opacity 0.4s ease;
  transform: translate3d(0, 135%, 0);
  opacity: 0;
  pointer-events: none !important;
  will-change: transform, opacity;
}

.dock-container:not(.is-visible) {
  display: none !important;
}

.dock-container.is-visible {
  display: flex !important;
  transform: translate3d(0, 0, 0);
  opacity: 1;
  pointer-events: auto !important;
}

/* ============================================================
   GROUP CARDS: JOIN A CLUB & ADD MATES
   (Exact implementation from join_a_club_add_mates_cards.html)
   ============================================================ */
.carousel-slide button,
#btn-home-club,
#btn-home-mates,
#homeProfileBtn {
  width: auto !important;
  min-width: fit-content !important;
  max-width: 100% !important;
  white-space: nowrap !important;
  padding: 8px 18px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-sizing: border-box !important;
}

.btn-violet {
  background-color: #493df5 !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.btn-violet:hover {
  background-color: #3b2fe0 !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(73, 61, 245, 0.35);
}
.btn-violet:active {
  transform: translateY(0);
  background-color: #3225c9 !important;
  box-shadow: 0 2px 6px rgba(73, 61, 245, 0.25);
}

.btn-blue {
  background-color: #4b63f6 !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.btn-blue:hover {
  background-color: #3b51e4 !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(75, 99, 246, 0.32);
}

.card-shadow {
  box-shadow: 0 12px 36px -6px rgba(15, 23, 42, 0.07), 0 4px 8px -2px rgba(15, 23, 42, 0.03) !important;
}

.card-inner-depth {
  box-shadow: 
    inset 0 1.5px 3px 0 rgba(255, 255, 255, 0.9),
    inset 0 -1.5px 3px 0 rgba(255, 255, 255, 0.4),
    inset 0 0 16px 2px rgba(255, 255, 255, 0.35);
}

.slash-mask {
  -webkit-mask-image: linear-gradient(110deg, transparent 0%, transparent 4%, rgba(0, 0, 0, 0.45) 12%, black 22%);
  mask-image: linear-gradient(110deg, transparent 0%, transparent 4%, rgba(0, 0, 0, 0.45) 12%, black 22%);
}

.slash-fade-overlay {
  background: linear-gradient(110deg, #ffffff 0%, #ffffff 4%, rgba(255, 255, 255, 0.45) 12%, transparent 22%);
}

/* iOS Switch Component (Canonical Blue Active Color) */
.ios-switch {
  position: relative;
  display: inline-block;
  width: 46px;
  height: 26px;
  flex-shrink: 0;
}

.ios-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.ios-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #e2e8f0;
  transition: .28s cubic-bezier(0.2, 0.8, 0.4, 1);
  border-radius: 9999px;
}

.ios-slider:before {
  position: absolute;
  content: "";
  height: 22px;
  width: 22px;
  left: 2px;
  bottom: 2px;
  background-color: white;
  transition: .28s cubic-bezier(0.2, 0.8, 0.4, 1);
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0,0,0,0.22);
}

.ios-switch input:checked + .ios-slider,
#pageProfile input:checked + .ios-slider {
  background-color: #2563eb !important;
}

.ios-switch input:checked + .ios-slider:before,
#pageProfile input:checked + .ios-slider:before {
  transform: translateX(20px) !important;
}


.liquid-glass-inset-card {
  border-radius: 20px !important;
  background: #f7f7f8 !important;
  border: 1px solid rgba(0, 0, 0, 0.04) !important;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.liquid-glass-header-pill {
  border-radius: 9999px !important;
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.liquid-glass-header-btn {
  width: 34px;
  height: 34px;
  border-radius: 9999px;
  background: #f1f2f4;
  border: 1px solid rgba(0, 0, 0, 0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #1e293b;
  flex-shrink: 0;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.liquid-glass-header-btn:hover {
  background: #e4e6ea;
  color: #000000;
}
.liquid-glass-header-btn:active {
  transform: scale(0.92);
}

.liquid-glass-pill-btn {
  position: relative !important;
  z-index: 35 !important;
  height: 52px !important;
  border-radius: 9999px !important;
  background: #000000 !important;
  color: #ffffff !important;
  font-weight: 700 !important;
  font-size: 14px !important;
  letter-spacing: -0.01em !important;
  display: flex;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  box-shadow: 0 10px 24px -4px rgba(0, 0, 0, 0.28) !important;
  transition: transform 0.15s cubic-bezier(0.2, 0.8, 0.4, 1), background-color 0.2s ease, box-shadow 0.2s ease !important;
}
.liquid-glass-pill-btn.hidden,
.hidden {
  display: none !important;
}
.liquid-glass-pill-btn:hover {
  background: #18181b !important;
}
.liquid-glass-pill-btn:active {
  transform: scale(0.98) !important;
}

.liquid-glass-pill-btn:disabled,
.liquid-glass-pill-btn[disabled],
.liquid-glass-pill-btn.is-disabled {
  background: #e4e4e7 !important;
  color: #8e8e93 !important;
  box-shadow: none !important;
  cursor: not-allowed !important;
  pointer-events: none !important;
  transform: none !important;
  opacity: 0.65 !important;
}

.liquid-glass-pill-btn.is-loading,
.liquid-glass-pill-btn:disabled:has(.spinner-ring:not(.hidden)),
.liquid-glass-pill-btn[disabled]:has(.spinner-ring:not(.hidden)) {
  background: #000000 !important;
  color: #ffffff !important;
  box-shadow: 0 10px 24px -4px rgba(0, 0, 0, 0.28) !important;
  cursor: wait !important;
  pointer-events: none !important;
  opacity: 0.95 !important;
}

.liquid-glass-pill-btn:disabled:hover,
.liquid-glass-pill-btn[disabled]:hover,
.liquid-glass-pill-btn.is-disabled:hover,
.liquid-glass-pill-btn:disabled:active,
.liquid-glass-pill-btn[disabled]:active,
.liquid-glass-pill-btn.is-disabled:active {
  background: #e4e4e7 !important;
  color: #8e8e93 !important;
  transform: none !important;
  box-shadow: none !important;
}

.liquid-glass-icon-btn {
  height: 52px !important;
  width: 52px !important;
  border-radius: 20px !important;
  background: #f2f2f4 !important;
  border: 1px solid rgba(0, 0, 0, 0.04) !important;
  color: #18181b !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0 !important;
  transition: transform 0.15s cubic-bezier(0.2, 0.8, 0.4, 1), background-color 0.2s ease !important;
}
.liquid-glass-icon-btn:hover {
  background: #e5e7eb !important;
}
.liquid-glass-icon-btn:active {
  transform: scale(0.94) !important;
}

/* ============================================================
   Focused Spatial Loading Badge & Shimmer System
   Adapted from focused_spatial_loading_badge.html
   Supports both Dark Mode & Light Mode seamlessly
   ============================================================ */

/* Continuous seamless linear text shimmer */
@keyframes shimmerSlide {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: 0% 0;
  }
}

/* Dark Mode Shimmer (Ice-Blue & Crisp White Specular Pass) */
.shimmer-text,
.shimmer-text-dark {
  background: linear-gradient(
    90deg,
    rgba(148, 163, 184, 0.45) 0%,
    rgba(148, 163, 184, 0.45) 25%,
    rgba(56, 189, 248, 0.75) 38%,
    rgba(255, 255, 255, 1) 50%,
    rgba(56, 189, 248, 0.75) 62%,
    rgba(148, 163, 184, 0.45) 75%,
    rgba(148, 163, 184, 0.45) 100%
  );
  background-size: 200% 100%;
  background-repeat: repeat-x;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmerSlide 2.8s infinite linear;
}

/* Light Mode Shimmer (Slate Grey Base, Silver Band & Sky-Blue Highlight) */
.shimmer-text-light,
body.light .shimmer-text,
.light .shimmer-text {
  background: linear-gradient(
    90deg,
    rgba(71, 85, 105, 0.85) 0%,
    rgba(71, 85, 105, 0.85) 24%,
    rgba(148, 163, 184, 0.95) 36%,
    rgba(2, 132, 199, 1) 48%,
    rgba(14, 165, 233, 1) 52%,
    rgba(148, 163, 184, 0.95) 64%,
    rgba(71, 85, 105, 0.85) 76%,
    rgba(71, 85, 105, 0.85) 100%
  );
  background-size: 200% 100%;
  background-repeat: repeat-x;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmerSlide 2.8s infinite linear;
}

/* GPU-Composited Fluid Blur Entrance */
@keyframes textBlurIn {
  0% {
    opacity: 0;
    filter: blur(14px);
    transform: translate3d(0, 7px, 0);
  }
  100% {
    opacity: 1;
    filter: blur(0px);
    transform: translate3d(0, 0, 0);
  }
}

.animate-blur-enter {
  display: inline-flex;
  align-items: center;
  animation: textBlurIn 0.65s cubic-bezier(0.19, 1, 0.22, 1) both;
  will-change: transform, opacity, filter;
  backface-visibility: hidden;
  transform: translateZ(0);
}

.shimmer-text.animate-blur-enter,
.shimmer-text-light.animate-blur-enter {
  animation: shimmerSlide 2.8s infinite linear, textBlurIn 0.65s cubic-bezier(0.19, 1, 0.22, 1) both !important;
}

/* Fluid Blur Exit for Stage Transitions */
@keyframes textBlurOut {
  0% {
    opacity: 1;
    filter: blur(0px);
    transform: translate3d(0, 0, 0);
  }
  100% {
    opacity: 0;
    filter: blur(10px);
    transform: translate3d(0, -6px, 0);
  }
}

.animate-blur-exit {
  animation: textBlurOut 0.35s cubic-bezier(0.4, 0, 1, 1) both;
  will-change: transform, opacity, filter;
  backface-visibility: hidden;
  transform: translateZ(0);
}

/* Focused Circular Spinner Ring */
@keyframes spinnerRotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.spinner-ring {
  border: 2px solid rgba(255, 255, 255, 0.18);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: spinnerRotate 0.85s cubic-bezier(0.4, 0, 0.2, 1) infinite;
  display: inline-block;
  box-sizing: border-box;
}

/* Light Mode Spinner: Dark Slate Ring with Solid Sky-Blue/Black Spinner */
.spinner-ring-light,
body.light .spinner-ring,
.light .spinner-ring {
  border: 2px solid rgba(0, 0, 0, 0.12);
  border-top-color: #0284c7;
}

/* Spatial Loading Badge Container - Solid white / black without live GPU blur passes */
.spatial-loading-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  background: #000000 !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: 1px solid #1e293b !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25) !important;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.spatial-loading-badge-light {
  background: #ffffff !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08) !important;
}

/* Floating Bottom Navigation Bar - Solid White */
.floating-bottom-nav,
#bottomNav {
  background: #ffffff !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: 1px solid rgba(0, 0, 0, 0.08) !important;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.10), 0 4px 10px -2px rgba(0, 0, 0, 0.05) !important;
}

/* Checkmark Path Animation */
.checkmark-path {
  stroke-dasharray: 40;
  stroke-dashoffset: 40;
  transition: stroke-dashoffset 0.55s cubic-bezier(0.65, 0, 0.45, 1) 0.15s;
}

.is-complete .checkmark-path {
  stroke-dashoffset: 0;
}

/* Startup Loading Screen (Pure White Screen with Centered Black Trippy) */
#startupOverlay {
  background-color: #ffffff !important;
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.5s cubic-bezier(0.16, 1, 0.3, 1),
              visibility 0.5s;
  will-change: opacity, transform;
}

#startupOverlay.overlay-dimmed {
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
}

#startupOverlay.overlay-cleared {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  transform: scale(1.02);
}

#startupBrandTitle {
  width: clamp(170px, 48vw, 240px);
  max-width: 80vw;
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
}

#startupBrandTitle svg {
  width: 100%;
  height: auto;
  display: block;
}

@keyframes ambientFloat {
  0%, 100% { transform: translateY(0px) scale(1); opacity: 0.75; }
  50% { transform: translateY(-16px) scale(1.08); opacity: 1; }
}

.animate-ambient {
  animation: ambientFloat 6.5s ease-in-out infinite;
}

#badgeContainer {
  transition: background-color 0.5s ease,
              border-color 0.5s ease,
              box-shadow 0.55s ease,
              transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
}

#badgeContainer.is-ready {
  border-color: rgba(56, 189, 248, 0.7);
  box-shadow: 0 0 35px rgba(56, 189, 248, 0.35), 
              0 8px 24px -4px rgba(14, 165, 233, 0.25);
}

.badge-dissolve {
  animation: badgeDissolve 0.75s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes badgeDissolve {
  0% {
    transform: scale(1) translate3d(0, 0, 0);
    filter: blur(0px);
    opacity: 1;
  }
  100% {
    transform: scale(1.05) translate3d(0, -6px, 0);
    filter: blur(8px);
    opacity: 0;
  }
}

/* ============================================================ */
/* iOS Native Micro-Bounce Physics for Typing Fields           */
/* ============================================================ */
@keyframes iosInputMicroBounce {
  0% {
    transform: scale(0.985);
  }
  55% {
    transform: scale(1.008);
  }
  100% {
    transform: scale(1);
  }
}

input[type="text"],
input[type="tel"],
input[type="number"],
input[type="search"],
input:not([type="checkbox"]):not([type="radio"]):not([type="button"]):not([type="submit"]):not([type="range"]),
textarea {
  transition: transform 0.24s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.22s ease,
              border-color 0.2s ease,
              background-color 0.2s ease;
  will-change: transform;
}

input[type="text"]:focus,
input[type="tel"]:focus,
input[type="number"]:focus,
input[type="search"]:focus,
input:not([type="checkbox"]):not([type="radio"]):not([type="button"]):not([type="submit"]):not([type="range"]):focus,
textarea:focus {
  animation: iosInputMicroBounce 0.24s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  outline: none !important;
  --tw-ring-shadow: none !important;
  --tw-ring-offset-shadow: none !important;
}

/* Ensure ALL search and filter inputs across the entire application NEVER display any rectangular border, ring, or box-shadow */
input[type="search"],
input[id*="search" i],
input[id*="Search"],
input[id*="Filter" i],
input[placeholder*="Search" i],
input[placeholder*="Filter" i],
.search-input,
#mateSearchInput,
#routeSearchInput {
  outline: none !important;
  border: none !important;
  box-shadow: none !important;
  --tw-ring-shadow: none !important;
  --tw-ring-offset-shadow: none !important;
  -webkit-appearance: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

input[type="search"]:focus,
input[id*="search" i]:focus,
input[id*="Search"]:focus,
input[id*="Filter" i]:focus,
input[placeholder*="Search" i]:focus,
input[placeholder*="Filter" i]:focus,
.search-input:focus,
#mateSearchInput:focus,
#routeSearchInput:focus {
  outline: none !important;
  border: none !important;
  box-shadow: none !important;
  --tw-ring-shadow: none !important;
  --tw-ring-offset-shadow: none !important;
  -webkit-appearance: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

input[type="text"]:active,
input[type="tel"]:active,
input[type="number"]:active,
input[type="search"]:active,
textarea:active {
  transform: scale(0.99);
}

/* ============================================================
   MINIMAL WELCOMING & LOGIN EXPERIENCE (login-flow.html specs)
   ============================================================ */
.rounded-apple {
  border-radius: 36px !important;
}
.rounded-apple-btn {
  border-radius: 36px !important;
}
.rounded-apple-input {
  border-radius: 28px !important;
}

.fluid-transition {
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.screen-slide {
  transition: transform 0.55s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.drag-active {
  border-color: #000000 !important;
  background-color: #F4F4F5 !important;
  transform: scale(0.985);
}

@keyframes textShimmer {
  0% {
    background-position: 200% center;
  }
  100% {
    background-position: -200% center;
  }
}
.text-shimmer {
  background: linear-gradient(
    90deg,
    #71717A 0%,
    #71717A 32%,
    #18181B 42%,
    #FFFFFF 50%,
    #18181B 58%,
    #71717A 68%,
    #71717A 100%
  );
  background-size: 200% 100%;
  color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
  display: inline-block;
  line-height: 1.3;
  padding: 2px 0;
  margin: 0;
  box-sizing: content-box;
  animation: textShimmer 3.8s ease-in-out infinite;
}

.text-shimmer-btn {
  background: linear-gradient(
    90deg,
    #FFFFFF 0%,
    #FFFFFF 35%,
    #A1A1AA 45%,
    #3F3F46 50%,
    #A1A1AA 55%,
    #FFFFFF 65%,
    #FFFFFF 100%
  );
  background-size: 200% 100%;
  color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
  display: inline-block;
  line-height: inherit !important;
  padding: 0 !important;
  margin: 0 !important;
  box-sizing: border-box !important;
  animation: textShimmer 3.8s ease-in-out infinite;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-6px); }
  40%, 80% { transform: translateX(6px); }
}
.animate-shake {
  animation: shake 0.4s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

.otp-input-base {
  transition: border-color 0.45s ease, background-color 0.45s ease, color 0.45s ease, transform 0.45s ease;
}
.input-error {
  border-color: #EF4444 !important;
  color: #EF4444 !important;
  background-color: #FEF2F2 !important;
}
.input-success {
  border-color: #10B981 !important;
  color: #10B981 !important;
  background-color: #ECFDF5 !important;
  transform: scale(1.05);
}

/* ==========================================================================
   Trippy Dynamic Aspect Ratio & Fluid Scaling Engine
   ========================================================================== */
:root {
  --trippy-vh: 100vh;
  --trippy-vw: 100vw;
  --trippy-aspect-ratio: 2.16;
  --trippy-stage-scale: 1;

  /* Reference button styling: 56px height, 16px font-size, 36px border radius */
  --fluid-login-btn-height: 56px;
  --fluid-login-btn-font: 16px;
  --fluid-login-btn-py: 16px;
}

/* Edge-to-Edge Image Canvas: Left, right and top touch screen boundaries */
#loginIllustrationSection {
  flex: 1 1 0% !important;
  width: 100% !important;
  min-height: 0 !important;
  overflow: hidden !important;
  position: relative !important;
  padding: 0 !important;
  margin: 0 !important;
}

#loginImageDisplayContainer {
  width: 100% !important;
  height: 100% !important;
  overflow: hidden !important;
  position: relative !important;
  padding: 0 !important;
  margin: 0 !important;
}

#loginCustomImage,
.login-step-img {
  width: 100% !important;
  min-width: 100% !important;
  max-width: 100% !important;
  height: 100% !important;
  aspect-ratio: 1792 / 2344 !important;
  object-fit: contain !important;
  object-position: center bottom !important;
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  display: block !important;
  transform-origin: center bottom !important;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.18s cubic-bezier(0.16, 1, 0.3, 1), transform 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

#loginCustomImage.active,
.login-step-img.active {
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
}

/* GUARDRAIL 1: Single-line Titles with increased size and bold Apple presence */
#loginScreen h1,
#loginScreen h2,
#loginScreen .login-dynamic-title {
  font-family: 'Vazirmatn', 'Inter', -apple-system, BlinkMacSystemFont, "SF Pro Display", sans-serif !important;
  letter-spacing: -0.03em !important;
  margin-left: 0 !important;
  padding-left: 0 !important;
  white-space: nowrap !important;
  font-size: clamp(27px, 7.8vw, 32px) !important;
  line-height: 1.12 !important;
}

/* GUARDRAIL 2: Fixed Header-to-Buttons Gap (20px standard guardrail) */
#loginScreen .login-header-wrap {
  margin-bottom: 20px !important;
}

#loginScreen .login-dynamic-sub {
  font-family: 'Vazirmatn', 'Inter', -apple-system, BlinkMacSystemFont, "SF Pro Text", sans-serif !important;
  letter-spacing: -0.01em !important;
  margin-left: 0 !important;
  padding-left: 0 !important;
  margin-top: 6px !important;
  font-size: 13.5px !important;
  line-height: 1.35 !important;
}

/* Slide Stack: CSS Grid Stack with top-aligned boxes for guaranteed fixed Image-to-Title distance */
.login-slide-stack {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  align-items: start !important;
  width: 100% !important;
  max-width: 100% !important;
  position: relative !important;
  overflow: hidden !important;
  box-sizing: border-box !important;
}

.login-slide-stack > .screen-slide {
  grid-column: 1 / 2 !important;
  grid-row: 1 / 2 !important;
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: flex-start !important;
  transition: opacity 0.32s cubic-bezier(0.16, 1, 0.3, 1), transform 0.32s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.login-slide-stack > .screen-slide.slide-hidden {
  display: none !important;
}

/* GUARDRAIL 3: Single-line Button Titles with fixed 56px height, no tap expansion */
#loginScreen button.rounded-apple-btn {
  min-height: 56px !important;
  height: 56px !important;
  padding: 0 20px !important;
  font-size: 15px !important;
  line-height: 1.25 !important;
  border-radius: 36px !important;
  box-sizing: border-box !important;
  white-space: nowrap !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  transform: none !important;
}

#loginScreen button.rounded-apple-btn:active {
  transform: none !important;
  opacity: 0.92;
}

#loginScreen button.rounded-apple-btn span {
  white-space: nowrap !important;
}

/* GUARDRAIL 4: Fixed standard gaps from Image Bottom Boundary and Screen Bottom */
#loginBottomArea {
  margin-top: 0 !important;
  position: relative !important;
  z-index: 20 !important;
  width: 100% !important;
  flex-shrink: 0 !important;
  box-sizing: border-box !important;
  padding-left: 28px !important;
  padding-right: 28px !important;
  padding-top: 20px !important;    /* Standard 20px guardrail gap between image bottom and title */
  padding-bottom: 24px !important;
}

/* GUARDRAIL 5: Match TOS distance with Subtitle-to-Button distance (20px) */
#loginTOSNotice {
  margin-top: 20px !important;
}

/* Compact devices (short screens, height < 720px or aspect < 1.84) */
[data-aspect-profile="compact"] #loginBottomArea {
  padding-left: 24px !important;
  padding-right: 24px !important;
  padding-top: 16px !important;
  padding-bottom: 18px !important;
}

[data-aspect-profile="compact"] #loginScreen .login-header-wrap {
  margin-bottom: 16px !important;
}

[data-aspect-profile="compact"] #loginTOSNotice {
  margin-top: 16px !important;
}

[data-aspect-profile="compact"] .login-dynamic-title {
  font-size: clamp(23px, 6.4vw, 27px) !important;
}

[data-aspect-profile="compact"] .login-dynamic-sub {
  font-size: 12.5px !important;
  margin-top: 4px !important;
}

/* Standard devices (720px - 845px, e.g. iPhone 13/14/15) */
[data-aspect-profile="standard"] #loginBottomArea {
  padding-left: 28px !important;
  padding-right: 28px !important;
  padding-top: 20px !important;
  padding-bottom: 24px !important;
}

/* Tall devices (> 845px, 19.5:9, 20:9 e.g. modern flagships) */
[data-aspect-profile="tall"] #loginBottomArea {
  padding-left: 28px !important;
  padding-right: 28px !important;
  padding-top: 20px !important;
  padding-bottom: 28px !important;
}

/* ============================================================
   RTL & Persian Localization Layer
   Mirrors layout, alignments, directional controls, and typography
   Modeled after Telegram Web / Instagram Web bidirectional standards.
   ============================================================ */

[dir="rtl"] {
  direction: rtl;
  text-align: right;
}

[dir="rtl"],
[dir="rtl"] body,
[dir="rtl"] button,
[dir="rtl"] input,
[dir="rtl"] textarea,
[dir="rtl"] select,
[dir="rtl"] h1,
[dir="rtl"] h2,
[dir="rtl"] h3,
[dir="rtl"] h4,
[dir="rtl"] h5,
[dir="rtl"] h6,
[dir="rtl"] span,
[dir="rtl"] p,
[dir="rtl"] div,
[dir="rtl"] a,
[dir="rtl"] label,
[dir="rtl"] strong,
[dir="rtl"] em,
[dir="rtl"] li {
  font-family: 'Vazirmatn', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

/* Text alignment mirroring */
[dir="rtl"] .text-left {
  text-align: right !important;
}
[dir="rtl"] .text-right {
  text-align: left !important;
}

/* Directional flipping for navigation back icons, chevrons, and swipe handles */
[dir="rtl"] .flip-rtl,
[dir="rtl"] .rtl-flip,
[dir="rtl"] .nav-back-btn svg,
[dir="rtl"] #loginNavBackBtn svg,
[dir="rtl"] button[title*="Back"] svg,
[dir="rtl"] .back-arrow svg,
[dir="rtl"] button[onclick*="rewindToGoAgain"] svg,
[dir="rtl"] button[onclick*="closePage"] svg,
[dir="rtl"] button[onclick*="popPage"] svg,
[dir="rtl"] #actionBtnIcon,
[dir="rtl"] #originChevronIcon,
[dir="rtl"] #quickNextStepArrow,
[dir="rtl"] .disclosure-chevron,
[dir="rtl"] .card-chevron,
[dir="rtl"] #homeActiveRideRouteChevron,
.route-chevron-mirror,
.disclosure-chevron,
.card-chevron,
#quickNextStepArrow {
  display: inline-block;
  transform-origin: center;
  transition: transform 0.2s ease;
}

[dir="rtl"] .route-chevron-mirror,
html[dir="rtl"] .route-chevron-mirror,
:lang(fa) .route-chevron-mirror,
[dir="rtl"] #quickNextStepArrow,
html[dir="rtl"] #quickNextStepArrow,
:lang(fa) #quickNextStepArrow {
  transform: scaleX(-1) !important;
}

[dir="rtl"] .route-chevron-mirror {
  transform: scaleX(-1) !important;
}

/* Edge swipe handle mirrors to right edge */
[dir="rtl"] .edge-swipe-handle {
  left: auto !important;
  right: 0 !important;
}

/* Floating GPS button on map mirrors to left side */
[dir="rtl"] #btnFetchUserLocation {
  right: auto !important;
  left: 1rem !important;
}



/* Fixed subpage headers follow natural RTL flex flow */
[dir="rtl"] .page-fixed-header {
  flex-direction: row !important;
  justify-content: space-between !important;
  text-align: right;
}

[dir="rtl"] .header-title-capsule {
  flex-direction: row !important;
}

[dir="rtl"] .header-title-capsule h1,
[dir="rtl"] .header-title-capsule h2,
[dir="rtl"] .header-title-capsule .header-title-text {
  text-align: right;
  letter-spacing: normal !important;
}

/* Home Header: Avatar & welcome back on right, notifications on left in RTL */
[dir="rtl"] #homeHeaderContainer {
  flex-direction: row !important;
  justify-content: space-between !important;
}
[dir="rtl"] #homeHeaderContainer > div:first-child {
  flex-direction: row !important;
}
[dir="rtl"] #homeHeaderContainer .text-left {
  text-align: right !important;
}

/* Home unread notification dot */
[dir="rtl"] #homeNotifBadge {
  right: auto !important;
  left: 0.125rem !important;
}

/* Carousel graphic cards (Join a club & Add Mates): mirror slash mask and artwork position */
[dir="rtl"] .slash-mask {
  right: auto !important;
  left: 0 !important;
  justify-content: flex-start !important;
  padding-right: 0 !important;
  padding-left: 0.25rem !important;
  -webkit-mask-image: linear-gradient(to right, black 70%, transparent 100%) !important;
  mask-image: linear-gradient(to right, black 70%, transparent 100%) !important;
}
[dir="rtl"] #clubCardImage,
[dir="rtl"] #matesCardImage {
  object-position: left !important;
  transform: scaleX(-1) translateY(-8px) !important;
}

/* Search inputs in Find Ride and Mates */
[dir="rtl"] .route-search-input {
  padding-left: 2rem !important;
  padding-right: 2.25rem !important;
  text-align: right !important;
}
[dir="rtl"] #findRidePullableContent .absolute.left-2\.5 {
  left: auto !important;
  right: 0.625rem !important;
}
[dir="rtl"] #findRidePullableContent #clearSearchBtn {
  right: auto !important;
  left: 0.625rem !important;
}
[dir="rtl"] #mateSearchBox {
  flex-direction: row-reverse;
}
[dir="rtl"] #mateSearchInput {
  text-align: right !important;
}

/* Total estimated fare card currency unit position */
[dir="rtl"] #crFareCard .relative > span.absolute {
  right: auto !important;
  left: 0.75rem !important;
}
[dir="rtl"] #inputMapTotalPrice {
  padding-right: 0.75rem !important;
  padding-left: 2.5rem !important;
  text-align: right !important;
}

/* White shimmer loading pill dock */
[dir="rtl"] #loadingPillContainer {
  flex-direction: row-reverse;
  padding-left: 1rem !important;
  padding-right: 0.625rem !important;
}
[dir="rtl"] #loadingPillContainer button {
  margin-right: 0 !important;
  margin-left: 0.625rem !important;
}

/* Go Again card strict single-line ellipsis and fluid bounds */
#homeGoAgainCard #goAgainDestTitle,
#homeGoAgainCard #goAgainDestSubtitle {
  display: block !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  max-width: 100% !important;
  min-width: 0 !important;
}

#homeGoAgainCard .go-again-text-wrap {
  min-width: 0 !important;
  flex: 1 1 0% !important;
  overflow: hidden !important;
}

[dir="rtl"] #homeGoAgainCard .go-again-text-wrap {
  text-align: right !important;
}
[dir="ltr"] #homeGoAgainCard .go-again-text-wrap {
  text-align: left !important;
}

[dir="rtl"] #homeGoAgainCard #goAgainHeader {
  text-align: right !important;
}
[dir="ltr"] #homeGoAgainCard #goAgainHeader {
  text-align: left !important;
}

/* Go Again card and chevron */
[dir="rtl"] #homeGoAgainCard .text-slate-400.text-xs.font-bold {
  transform: scaleX(-1);
  display: inline-block;
}

/* Travel for free card chevron */
[dir="rtl"] #code-badge-1 span.text-slate-400.text-xs.font-bold {
  transform: scaleX(-1);
  display: inline-block;
}

/* Profile page action chevrons */
[dir="rtl"] #pageProfile .text-slate-400 > span:last-child {
  transform: scaleX(-1);
  display: inline-block;
}

/* Protected LTR Islands: Maps, Numbers, Dialing code & OTP */
[dir="rtl"] #createRideMap,
[dir="rtl"] .maplibregl-map,
[dir="rtl"] .maplibregl-canvas-container,
[dir="rtl"] .map-ltr-island {
  direction: ltr !important;
  text-align: left !important;
}

[dir="rtl"] #loginPhoneForm,
[dir="rtl"] #loginOtpForm,
[dir="rtl"] .otp-input-base {
  direction: ltr !important;
}

[dir="rtl"] .tabular-nums {
  direction: ltr !important;
  unicode-bidi: embed;
}

/* Latin code tokens and explicit LTR elements only; do NOT force LTR on general font-mono price labels */
[dir="rtl"] code.font-mono,
[dir="rtl"] pre.font-mono,
[dir="rtl"] .font-mono.latin-token {
  direction: ltr !important;
  unicode-bidi: isolate;
}

/* Ensure price and numeric labels maintain correct Persian BiDi isolation */
[dir="rtl"] .font-mono {
  unicode-bidi: isolate;
}

/* Loading shimmer animation under RTL */
@keyframes shimmerSlideRtl {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

[dir="rtl"] .shimmer-text,
[dir="rtl"] .shimmer-text-light {
  display: inline-block !important;
  animation: shimmerSlideRtl 2.8s infinite linear !important;
}

/* Design System & Legacy Layout Tokens */
:root {
  --trippy-top-action-gap: 16px;
  --trippy-content-safe-top: env(safe-area-inset-top, 24px);
  --trippy-safe-top: env(safe-area-inset-top, 24px);
}

.tactile-press {
  transition: transform 0.12s cubic-bezier(0.2, 0.8, 0.4, 1), box-shadow 0.12s ease;
  will-change: transform, box-shadow;
}
.tactile-press:active, .tactile-press.is-pressed {
  transform: translateY(1px) scale(0.975) !important;
}

.btn-press {
  transition: transform 0.15s ease-out;
}
.btn-press:active {
  transform: scale(0.96);
}

.side-page-col {
  padding-top: max(calc(var(--trippy-content-safe-top) + var(--trippy-top-action-gap, 16px)), calc(var(--trippy-safe-top) + var(--trippy-top-action-gap, 16px)), 80px);
}

#standard-header {
  top: max(calc(var(--trippy-content-safe-top) + var(--trippy-top-action-gap, 8px)), calc(var(--trippy-safe-top) + var(--trippy-top-action-gap, 8px)), 80px);
  direction: ltr;
}

html[lang="fa"] #standard-header #step1-dot, html[lang="fa"] #standard-header #step2-dot {
  padding-top: 1.5px;
}

#radar-container {
  padding-top: max(calc(var(--trippy-content-safe-top) + var(--trippy-top-action-gap, 16px)), calc(var(--trippy-safe-top) + var(--trippy-top-action-gap, 16px)), 80px);
}

#home-top-boundary {
  height: max(var(--trippy-content-safe-top), var(--tg-content-safe-area-inset-top, 0px), var(--tg-safe-area-inset-top, 0px), env(safe-area-inset-top, 0px), 64px);
}

#active-island-container {
  padding-top: max(calc(var(--trippy-content-safe-top) + 24px), calc(var(--trippy-safe-top) + 24px), 88px);
}

@supports not (height: 1dvh) {
  #home-top-boundary {
    height: 64px;
  }
}

#map, .maplibregl-ctrl { direction: ltr; }
#standard-header { direction: ltr; }
html[lang="fa"] #standard-header #step1-dot, html[lang="fa"] #standard-header #step2-dot { padding-top: 1.5px; }

html[dir="rtl"] .rtl-flip {
  transform: scaleX(-1);
}

html[dir="rtl"] .route-timeline {
  padding-left: 0;
  padding-right: 1.5rem;
  margin-left: 0;
  margin-right: 1rem;
  border-left: none;
  border-right: 1.5px solid #e5e7eb;
}

html[dir="rtl"] .route-timeline > #btn-swap-route {
  left: auto;
  right: -14px;
}

html[dir="rtl"] #wallet-screen,
html[dir="rtl"] #profile-screen,
html[dir="rtl"] #notifications-screen {
  transform: translateX(100%);
}

/* Bottom Sheet System Specification (Solid opaque white background, 32px rounded top, elevation) */
.bottom-sheet {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  background: #ffffff !important;
  background-color: #ffffff !important;
  border-top-left-radius: 32px !important;
  border-top-right-radius: 32px !important;
  box-shadow: 0 -16px 48px rgba(0, 0, 0, 0.16), 0 -1px 0 rgba(0, 0, 0, 0.04) !important;
  transition: transform 0.4s cubic-bezier(0.32, 0.72, 0, 1);
  padding-bottom: env(safe-area-inset-bottom, 24px);
  will-change: transform;
}

.bottom-sheet.sheet-boot-parked { box-shadow: none; visibility: hidden; }







/* Host Details Sheet Action Buttons */
#btnDetailsSheetFinishRide {
  background: #059669 !important;
  color: #ffffff !important;
}
#btnDetailsSheetFinishRide:disabled,
#btnDetailsSheetFinishRide[disabled],
#btnDetailsSheetFinishRide.is-disabled {
  background: #e4e4e7 !important;
  color: #8e8e93 !important;
  opacity: 0.65 !important;
}
#panel-trip-payment-details button[onclick*="closeTripPaymentDetailsSheet"] {
  background: #f1f5f9 !important;
  color: #334155 !important;
  box-shadow: none !important;
}

/* Mirror prize banner artwork in RTL */
[dir="rtl"] #code-badge-1 img,
[dir="rtl"] .travel-free-banner-img {
  transform: scaleX(-1) !important;
}

/* Wallet: tabular figures for amount typography (RTL direction rule further below) */
.tabular-nums {
  font-variant-numeric: tabular-nums;
}

/* Wallet: balance group compact + high on the page (owner mock) */
#walletBalanceSection {
  padding-block: 8px;
}
#walletBalanceValue {
  font-size: clamp(32px, 9vw, 56px);
}

.bidi-isolate, bdi {
  unicode-bidi: isolate !important;
  text-align: start;
}
[dir="rtl"] .bidi-isolate, [dir="rtl"] bdi {
  text-align: right;
}
[dir="ltr"] .bidi-isolate, [dir="ltr"] bdi {
  text-align: left;
}

/* iOS Fluid Sheet Context Transitions */
.ios-fluid-expand {
  transition: max-height 0.4s cubic-bezier(0.32, 0.72, 0, 1),
              opacity 0.32s cubic-bezier(0.32, 0.72, 0, 1),
              transform 0.4s cubic-bezier(0.32, 0.72, 0, 1),
              margin 0.32s cubic-bezier(0.32, 0.72, 0, 1),
              padding 0.32s cubic-bezier(0.32, 0.72, 0, 1);
  overflow: hidden;
  will-change: max-height, opacity, transform;
}
.ios-fluid-expand.collapsed {
  max-height: 0 !important;
  opacity: 0 !important;
  transform: translateY(-8px) scale(0.97) !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  border-width: 0 !important;
  pointer-events: none !important;
}
.ios-fluid-expand.expanded {
  max-height: 180px !important;
  opacity: 1 !important;
  transform: translateY(0) scale(1) !important;
  margin-top: 12px !important;
  pointer-events: auto !important;
}

.ios-fluid-morph {
  transition: background-color 0.35s cubic-bezier(0.32, 0.72, 0, 1),
              color 0.25s ease,
              border-color 0.35s ease,
              box-shadow 0.35s ease,
              transform 0.2s cubic-bezier(0.32, 0.72, 0, 1);
  will-change: background-color, transform;
}

.ios-crossfade {
  transition: opacity 0.28s cubic-bezier(0.32, 0.72, 0, 1),
              transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
  will-change: opacity, transform;
}

/* Wallet page — owner mock palette (scoped; no global shifts) */
.wallet-page-bg { background: #F8F9FA; }
.wallet-btn { background: #1C1F24; }
.wallet-btn-disabled,
.wallet-btn[disabled] {
  background: #e4e4e7 !important;
  color: #8e8e93 !important;
  box-shadow: none !important;
  cursor: not-allowed !important;
  opacity: 0.65 !important;
}
.wallet-hairline { border-color: rgba(17,17,17,0.07); }
.wallet-box {
  background: #E3E4EA;
  border: 1px solid rgba(30, 35, 47, 0.06);
  box-shadow: 0 10px 28px rgba(30, 35, 47, 0.08);
}
.wallet-navy { color: #1E232F; }
.wallet-secondary { color: #62666F; }
.wallet-icon-gray { color: #A7ABB1; }

/* Mobile Viewport Auto-Zoom & Pinch Prevention (iOS Safari hardening) */
@media screen and (max-width: 768px) {
  input, textarea, select {
    font-size: 16px !important;
  }
}
html, body {
  touch-action: pan-x pan-y;
  -webkit-text-size-adjust: 100%;
}

/* Wallet In-Progress Indicator */
@keyframes walletSpinBorder {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
.wallet-in-progress-spinner {
  position: absolute;
  inset: -4px;
  border-radius: 9999px;
  border: 2.5px solid transparent;
  border-top-color: #10B981;
  border-right-color: #34D399;
  animation: walletSpinBorder 1s linear infinite;
  pointer-events: none;
}
.wallet-icon-pastel-green {
  background-color: #D1FAE5 !important;
  color: #059669 !important;
  border: 1px solid #A7F3D0 !important;
}


/* Brand Login Buttons & State transitions */
#loginBtnTelegramAuth,
.bg-\[\#24A1DE\] {
  background-color: #24A1DE !important;
  color: #ffffff !important;
}
#loginBtnTelegramAuth:hover,
.hover\:bg-\[\#208fc4\]:hover {
  background-color: #208fc4 !important;
}

#loginBtnBaleAuth,
.bg-\[\#00c569\] {
  background-color: #00c569 !important;
  color: #ffffff !important;
}
#loginBtnBaleAuth:hover,
.hover\:bg-\[\#00b05e\]:hover {
  background-color: #00b05e !important;
}

.bg-rose-500 {
  background-color: #f43f5e !important;
  color: #ffffff !important;
}


/* Mate Remove Button: smooth expand & collapse transition */
.mate-row-remove-btn {
  box-sizing: border-box;
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 32px;
  min-width: 32px;
  padding: 0;
  border-radius: 9999px;
  background-color: #fff1f2;
  color: #f43f5e;
  border: 1px solid rgba(254, 205, 211, 0.8);
  transition: background-color 0.25s ease,
              border-color 0.25s ease,
              color 0.25s ease,
              box-shadow 0.25s ease,
              padding 0.28s cubic-bezier(0.2, 0.8, 0.2, 1),
              transform 0.15s ease;
  flex-shrink: 0;
  cursor: pointer;
}

.mate-row-remove-btn:active {
  transform: scale(0.92);
}

.mate-row-remove-btn .mate-remove-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  max-width: 16px;
  opacity: 1;
  transform: scale(1);
  overflow: hidden;
  pointer-events: none;
  transition: max-width 0.28s cubic-bezier(0.2, 0.8, 0.2, 1),
              opacity 0.2s ease,
              transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.mate-row-remove-btn .mate-remove-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 0;
  opacity: 0;
  transform: scale(0.85);
  overflow: hidden;
  white-space: nowrap;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.025em;
  pointer-events: none;
  transition: max-width 0.28s cubic-bezier(0.2, 0.8, 0.2, 1),
              opacity 0.2s ease,
              transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1),
              padding 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.mate-row-remove-btn[data-armed="true"] {
  background-color: #e11d48 !important;
  color: #ffffff !important;
  border-color: transparent !important;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
  padding: 0 10px !important;
}

.mate-row-remove-btn[data-armed="true"] .mate-remove-icon {
  max-width: 0 !important;
  opacity: 0 !important;
  transform: scale(0.5) !important;
}

.mate-row-remove-btn[data-armed="true"] .mate-remove-label {
  max-width: 80px !important;
  opacity: 1 !important;
  transform: scale(1) !important;
  padding: 0 2px !important;
}

/* Club page action button boundary fitting */
.btn-stage-enter {
  box-sizing: border-box !important;
  max-width: 100% !important;
}
.btn-stage-enter input {
  min-width: 0 !important;
  box-sizing: border-box !important;
}
.btn-stage-enter button {
  flex-shrink: 0 !important;
  white-space: nowrap !important;
  box-sizing: border-box !important;
}


/* Club Camera Scanner Active Mode */
#pageClub.club-camera-active #topEdgeBlurLayer_pclub,
#pageClub.club-camera-active #clubHeader,
#pageClub.club-camera-active #clubSquircleCard,
#pageClub.club-camera-active #clubPageTitle,
#pageClub.club-camera-active #clubStatsRow,
#pageClub.club-camera-active #btnClubTopQr {
  opacity: 0 !important;
  pointer-events: none !important;
  transition: opacity 0.28s cubic-bezier(0.2, 0.8, 0.2, 1) !important;
}

#clubLowerContainer {
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), border-radius 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.35s ease !important;
  will-change: transform, border-radius;
}

#pageClub.club-camera-active #clubLowerContainer {
  transform: translate3d(0, calc(100% - 110px), 0) !important;
  border-top-left-radius: 36px !important;
  border-top-right-radius: 36px !important;
  box-shadow: 0 -12px 35px rgba(0, 0, 0, 0.25) !important;
}

#pageClub.club-camera-active #clubActionStageContainer {
  opacity: 0 !important;
  pointer-events: none !important;
  transform: translate3d(0, 40px, 0) !important;
  transition: opacity 0.25s ease, transform 0.25s ease !important;
}


/* Find Ride Centered Empty State */
#emptyState {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem 1rem;
}
#findRideListSheet #emptyState {
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  top: 124px !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  align-items: center !important;
  padding: 1.5rem 1rem !important;
  pointer-events: auto !important;
  z-index: 10 !important;
}
#emptyState.hidden {
  display: none !important;
}

/* Login Provider Action Buttons (Telegram & Bale Brand Colors) */
#loginBtnTelegramAuth {
  background-color: #24A1DE !important;
  color: #ffffff !important;
}
#loginBtnTelegramAuth:hover {
  background-color: #208fc4 !important;
}
#loginBtnBaleAuth {
  background-color: #00c569 !important;
  color: #ffffff !important;
}
#loginBtnBaleAuth:hover {
  background-color: #00b05e !important;
}


/* ============================================================
   MAP-FIRST FIND RIDE: MARKERS & SYNCHRONIZED BOTTOM SHEET
   ============================================================ */
.find-ride-user-puck {
  width: 22px;
  height: 22px;
  position: relative;
  pointer-events: none;
}
.find-ride-user-puck .user-puck-pulse {
  position: absolute;
  inset: -6px;
  border-radius: 9999px;
  background: rgba(14, 165, 233, 0.35);
  animation: puckPulse 2.2s infinite ease-out;
}
.find-ride-user-puck .user-puck-dot {
  position: absolute;
  inset: 3px;
  border-radius: 9999px;
  background: #0284c7;
  border: 2.5px solid #ffffff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.28);
}
@keyframes puckPulse {
  0% { transform: scale(0.85); opacity: 0.8; }
  70% { transform: scale(2.2); opacity: 0; }
  100% { transform: scale(2.2); opacity: 0; }
}

.find-ride-marker {
  cursor: pointer;
  user-select: none;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: transform;
}
.find-ride-marker:hover {
  transform: scale(1.08);
}
.find-ride-marker.is-selected {
  transform: scale(1.18);
  z-index: 10;
}
.find-ride-marker .marker-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  border-radius: 9999px;
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.12);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.14);
  font-family: 'Vazirmatn', 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.find-ride-marker.is-selected .marker-pill {
  border-color: #0284c7;
  box-shadow: 0 6px 20px rgba(2, 132, 199, 0.35);
}
.find-ride-marker .marker-dot {
  width: 7px;
  height: 7px;
  border-radius: 9999px;
  background: #10b981;
  flex-shrink: 0;
}
.find-ride-marker .marker-square {
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: #0f172a;
  flex-shrink: 0;
}
.find-ride-marker .dest-pill {
  background: #0f172a;
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.2);
}
.find-ride-marker.is-selected .dest-pill {
  border-color: #38bdf8;
  box-shadow: 0 6px 20px rgba(14, 165, 233, 0.45);
}

/* Synchronized Draggable Bottom Sheet */
#findRideListSheet {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  background: #ffffff;
  border-top-left-radius: 28px;
  border-top-right-radius: 28px;
  box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.14), 0 -1px 0 rgba(0, 0, 0, 0.04);
  z-index: 25;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  will-change: height;
  transition: height 0.32s cubic-bezier(0.32, 0.72, 0, 1);
}
#findRideListSheet.is-dragging {
  transition: none !important;
}
#findRideListSheet .sheet-drag-handle {
  width: 100%;
  padding-top: 10px;
  padding-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
  touch-action: none;
  user-select: none;
}
#findRideListSheet .sheet-drag-handle:active {
  cursor: grabbing;
}
#findRideListSheet .sheet-drag-pill {
  width: 38px;
  height: 5px;
  border-radius: 9999px;
  background: #cbd5e1;
}

/* Card Selection Highlight */
.trip-card-item.is-map-selected {
  border-color: #0284c7 !important;
  background: rgba(240, 249, 255, 0.95) !important;
  box-shadow: 0 4px 16px rgba(2, 132, 199, 0.18) !important;
}

/* Radius selector active state */
.radius-pill-btn.is-active {
  background-color: #ffffff !important;
  color: #0f172a !important;
  font-weight: 700 !important;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
}

/* Find Ride Floating Controls & Search Components */
#findRideFloatingControls {
  position: absolute !important;
  top: 86px !important;
  left: 0 !important;
  right: 0 !important;
  padding: 0 16px !important;
  z-index: 20 !important;
  pointer-events: none !important;
  transition: opacity 0.35s cubic-bezier(0.32, 0.72, 0, 1),
              transform 0.35s cubic-bezier(0.32, 0.72, 0, 1) !important;
  will-change: opacity, transform !important;
}

#findRideHeader {
  transition: opacity 0.35s cubic-bezier(0.32, 0.72, 0, 1),
              transform 0.35s cubic-bezier(0.32, 0.72, 0, 1) !important;
  will-change: opacity, transform !important;
}

/* Fluid hide when bottom sheet expands to FULL state */
#findRideFloatingControls.is-hidden-by-sheet,
#findRideHeader.is-hidden-by-sheet {
  opacity: 0 !important;
  pointer-events: none !important;
  transform: translateY(-16px) scale(0.96) !important;
}

.find-ride-marker.origin-marker {
  /* Origin marker descriptor */
}

.find-ride-marker.dest-marker {
  /* Dest marker descriptor */
}

/* Route Search Bar - Direction & Responsive Robustness */
.route-search-wrapper {
  position: relative !important;
  width: 100% !important;
  display: flex !important;
  align-items: center !important;
}

.route-search-input {
  width: 100% !important;
  height: 36px !important;
  padding-left: 36px !important;
  padding-right: 36px !important;
  padding-inline-start: 36px !important;
  padding-inline-end: 36px !important;
  box-sizing: border-box !important;
  border-radius: 9999px !important;
  border: 1px solid #e2e8f0 !important;
  background-color: rgba(248, 250, 252, 0.95) !important;
  font-size: 12px !important;
  line-height: 1.4 !important;
  color: #1e293b !important;
  outline: none !important;
  transition: all 0.2s ease !important;
}

.route-search-input:focus {
  background-color: #ffffff !important;
  border-color: #cbd5e1 !important;
  box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.15) !important;
}

.route-search-icon {
  position: absolute !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  left: 11px !important;
  inset-inline-start: 11px !important;
  width: 16px !important;
  height: 16px !important;
  color: #94a3b8 !important;
  pointer-events: none !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

[dir="rtl"] .route-search-icon {
  left: auto !important;
  right: 11px !important;
}

#clearSearchBtn {
  position: absolute !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  right: 10px !important;
  inset-inline-end: 10px !important;
  width: 20px !important;
  height: 20px !important;
  border-radius: 9999px !important;
  background-color: #e2e8f0 !important;
  color: #475569 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  flex-shrink: 0 !important;
  z-index: 5 !important;
  border: none !important;
  padding: 0 !important;
  transition: transform 0.15s ease, background-color 0.15s ease !important;
}

#clearSearchBtn:hover {
  background-color: #cbd5e1 !important;
  color: #1e293b !important;
}

#clearSearchBtn:active {
  transform: translateY(-50%) scale(0.92) !important;
}

[dir="rtl"] #clearSearchBtn {
  right: auto !important;
  left: 10px !important;
}

/* Empty State Centering */
#findRideScrollArea {
  display: flex !important;
  flex-direction: column !important;
  min-height: 0 !important;
}

#emptyState {
  margin-top: auto !important;
  margin-bottom: auto !important;
}


/* =============================================================================
   FIND RIDE LOCATION BUTTON STATES (Active / Locating / Error)
   ============================================================================= */
#findRideLocateBtn {
  transition: all 0.25s cubic-bezier(0.2, 0.8, 0.4, 1) !important;
}

#findRideLocateBtn.is-locating {
  border-color: #38bdf8 !important;
  color: #0284c7 !important;
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.2) !important;
}

#findRideLocateBtn.is-locating svg {
  animation: spin 1.2s linear infinite;
}

#findRideLocateBtn.is-success {
  border-color: #0284c7 !important;
  color: #0284c7 !important;
  background-color: #f0f9ff !important;
}

#findRideLocateBtn.is-error {
  border-color: #f87171 !important;
  color: #dc2626 !important;
  background-color: #fef2f2 !important;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2) !important;
  animation: shakeGps 0.45s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

@keyframes shakeGps {
  10%, 90% { transform: translate3d(-1px, 0, 0); }
  20%, 80% { transform: translate3d(2px, 0, 0); }
  30%, 50%, 70% { transform: translate3d(-3px, 0, 0); }
  40%, 60% { transform: translate3d(3px, 0, 0); }
}

/* =============================================================================
   FIND RIDE SHEET - APP STANDARD THEME & STRICT VERTICAL-ONLY MORPHING
   Matches standard .ios-sheet / .rides-sheet geometry:
   - Position & layout: bottom 14px, left 0, right 0, margin 0 auto, width calc(100% - 24px), max-width 480px (LOCKED on all states)
   - Fixed border-radius 36px (var(--box-r)) on ALL states (including PEEK)
     Eliminates circular/radial warping so expansion happens strictly along Y-axis!
   - PEEK state: height 68px, centered capsule bar with fluid cross-fade text transitions
   - MID & FULL states: height 48% / 82%, standard expanded content
   - Fluid iOS spring transition: inspired directly by #morphCapsule in create-ride
     (height, box-shadow, and stacked absolute child content cross-fades)
   ============================================================================= */

#findRideListSheet {
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 14px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  width: calc(100% - 24px) !important;
  max-width: 480px !important;
  background: #ffffff !important;
  border-radius: var(--box-r, 36px) !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
  box-shadow: 0 16px 40px -8px rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.04) !important;
  z-index: 25 !important;
  display: flex !important;
  flex-direction: column !important;
  overflow: hidden !important;
  will-change: height, box-shadow !important;
  /* iOS spring transition: STRICTLY vertical (height) with zero radial/corner distortion */
  transition: height 0.44s cubic-bezier(0.32, 0.72, 0, 1),
              box-shadow 0.44s cubic-bezier(0.32, 0.72, 0, 1) !important;
}

#findRideListSheet.is-dragging {
  transition: none !important;
}

/* Collapsed PEEK State: Same 36px rounded rect as standard sheets */
#findRideListSheet.is-capsule-mode {
  border-radius: var(--box-r, 36px) !important;
  box-shadow: 0 12px 32px -4px rgba(0, 0, 0, 0.14), 0 0 0 1px rgba(0, 0, 0, 0.04) !important;
}

/* Drag Handle */
#findRideListSheet .sheet-drag-handle {
  width: 100% !important;
  padding-top: 8px !important;
  padding-bottom: 6px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: grab !important;
  touch-action: none !important;
  user-select: none !important;
  z-index: 20 !important;
}

#findRideListSheet.is-capsule-mode .sheet-drag-handle {
  padding-top: 6px !important;
  padding-bottom: 2px !important;
}

#findRideListSheet .sheet-drag-pill {
  width: 38px !important;
  height: 5px !important;
  border-radius: 9999px !important;
  background: #cbd5e1 !important;
  transition: width 0.3s ease, height 0.3s ease, background 0.3s ease;
}

#findRideListSheet.is-capsule-mode .sheet-drag-pill {
  width: 28px !important;
  height: 3.5px !important;
  background: #94a3b8 !important;
}

/* Collapsed Capsule Bar: Center Aligned & Symmetrical (Like primaryActionBtn) */
.find-ride-capsule-bar {
  position: absolute;
  top: 10px;
  left: 0;
  right: 0;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0 24px;
  cursor: pointer;
  user-select: none;
  z-index: 15;
  opacity: 0;
  pointer-events: none;
  transform: translateY(4px) scale(0.98);
  transition: opacity 0.28s cubic-bezier(0.32, 0.72, 0, 1),
              transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
  will-change: opacity, transform;
}

.capsule-icon-wrap {
  width: 32px;
  height: 32px;
  border-radius: 9999px;
  background-color: #f0f9ff;
  border: 1px solid #bae6fd;
  display: flex;
  align-items: center;
  justify-content: center;
}

.capsule-text-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-width: 0;
}

/* Apple blur-fade cross-dissolve keyframe for fluid content update */
.capsule-fluid-text {
  display: block;
  transition: opacity 0.22s cubic-bezier(0.32, 0.72, 0, 1),
              transform 0.22s cubic-bezier(0.32, 0.72, 0, 1),
              filter 0.22s cubic-bezier(0.32, 0.72, 0, 1);
  will-change: opacity, transform, filter;
}

.capsule-fluid-text.is-updating {
  opacity: 0 !important;
  transform: translateY(3px) scale(0.97) !important;
  filter: blur(3px) !important;
}

.capsule-expand-cue {
  width: 32px;
  height: 32px;
  border-radius: 9999px;
  background-color: #f8fafc;
  border: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease;
}

.find-ride-capsule-bar:active .capsule-expand-cue {
  transform: translateY(-2px);
}

/* Expanded View Wrap (Like #completionSheetContent in create-ride) */
.sheet-expanded-content-wrap {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.35s cubic-bezier(0.32, 0.72, 0, 1) 0.04s,
              transform 0.35s cubic-bezier(0.32, 0.72, 0, 1) 0.04s;
  will-change: opacity, transform;
}

/* Mode toggles: Fluid iOS cross-fade between capsule bar and expanded view */
#findRideListSheet.is-capsule-mode .find-ride-capsule-bar {
  opacity: 1 !important;
  pointer-events: auto !important;
  transform: translateY(0) scale(1) !important;
}

#findRideListSheet.is-capsule-mode .sheet-expanded-content-wrap {
  opacity: 0 !important;
  pointer-events: none !important;
  transform: translateY(12px) scale(0.98) !important;
}

/* ==========================================================================
   iOS Fluid Segmented Control System
   ========================================================================== */
.ios-segmented-track {
  display: inline-flex !important;
  align-items: center !important;
  position: relative !important;
  background: rgba(255, 255, 255, 0.76) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border: 1px solid rgba(226, 232, 240, 0.85) !important;
  border-radius: 9999px !important;
  padding: 3px !important;
  gap: 2px !important;
  user-select: none !important;
  -webkit-user-select: none !important;
  box-shadow: inset 0 1px 1.5px 0 rgba(255, 255, 255, 0.9), 0 1px 3px 0 rgba(0, 0, 0, 0.04) !important;
}

.ios-segmented-indicator {
  position: absolute !important;
  top: 3px !important;
  bottom: 3px !important;
  left: 0 !important;
  border-radius: 9999px !important;
  background: #ffffff !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04) !important;
  pointer-events: none !important;
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), width 0.24s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.15s ease-out !important;
  z-index: 1 !important;
}

.ios-segment-btn {
  position: relative !important;
  z-index: 2 !important;
  border-radius: 9999px !important;
  border: none !important;
  background: transparent !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: color 0.2s ease, font-weight 0.15s ease !important;
  -webkit-tap-highlight-color: transparent !important;
}

.ios-segment-btn.is-active {
  color: #0f172a !important;
  font-weight: 700 !important;
}

.ios-segment-btn:not(.is-active) {
  color: #64748b !important;
  font-weight: 600 !important;
}

.ios-segment-btn:not(.is-active):hover {
  color: #0f172a !important;
}

/* When Club Camera is active, disable pointer-events on background scroll area so camera controls receive touches */
#pageClub.club-camera-active #clubScrollArea {
  pointer-events: none !important;
}

#clubCameraScanModal {
  pointer-events: auto !important;
  z-index: 100 !important;
}
#clubCameraScanModal button,
#clubCameraScanModal label {
  pointer-events: auto !important;
}

/* Scrim header exemption: allow header action buttons to remain clickable across fast sheet switches */
#matesHeader {
  z-index: 40 !important;
}
#btnMateHeaderQr, #btnMateHeaderAdd {
  position: relative !important;
  z-index: 50 !important;
  pointer-events: auto !important;
}

/* Go Again Route Summary Row (Under Title) */
#gaRouteSummaryRow {
  box-sizing: border-box !important;
  width: 100% !important;
}

[dir="rtl"] #gaRouteSummaryRow {
  direction: rtl !important;
}

[dir="rtl"] #gaRouteSummaryRow .route-chevron-mirror,
html[dir="rtl"] #gaRouteSummaryRow .route-chevron-mirror,
:lang(fa) #gaRouteSummaryRow .route-chevron-mirror {
  transform: scaleX(-1) !important;
}
