 * {
      margin: 0;
      padding: 0;
      box-sizing: border-box
    }

    html,
    body {
      min-height: 100vh;
      display: flex;
      flex-direction: column;
      overflow-x: hidden
    }

    body {
      font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
      font-size: 16px;
      line-height: 1.6;
      color: #0E2747
    }

    /* ========= HEADER ========= */
    .header {
      position: relative;
      padding: 10px 28px;
      background: #edf2fb;
      border-top: 1px solid rgba(0, 0, 0, .1);
      box-shadow: 0 1px 0 rgba(255, 255, 255, .6) inset;
      z-index: 1001;
    }

    .header-row {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      flex-direction: row !important;
    }

    .header-actions {
      display: flex;
      align-items: center;
      gap: 10px;
      flex-shrink: 0;
    }

    .center-logo-text {
      color: #335b92;
      font-size: 24px;
      font-weight: 700;
      display: flex;
      align-items: center;
      gap: 8px;
      position: absolute;
      left: 50%;
      transform: translateX(-50%);
      white-space: nowrap;
      max-width: 40vw;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .center-logo-text img {
      width: 28px;
      height: 28px;
    }

    html[lang="ar"] .center-logo-text {
      flex-direction: row;
      text-align: right;
    }

    html[lang="en"] .center-logo-text {
      flex-direction: row;
      text-align: right;
      direction: rtl;
    }

    .logo-section {
      display: flex;
      align-items: center;
      gap: 12px;
      flex-shrink: 0;
      direction: ltr !important;
    }

    html[lang="ar"] .logo-section {
      flex-direction: row-reverse;
    }

    html[lang="ar"] .logo-text .line {
      text-align: right;
    }

    html[lang="en"] .logo-section {
      flex-direction: row;
    }

    html[lang="en"] .logo-text .line {
      text-align: left;
    }

    .logo-badge {
      width: 50px;
      height: 50px;
      display: grid;
      place-items: center;
    }

    .logo-badge img {
      width: 50px;
      height: 50px;
      object-fit: contain;
    }

    .logo-text {
      line-height: 1.3;
    }

    .logo-text .line {
      color: #6b7280;
      font-size: 13px;
      font-weight: 600;
      white-space: nowrap;
      text-align: left;
    }

    .icon-btn {
      width: 40px;
      height: 40px;
      background: #fff;
      border: 1px solid #cfd6e3;
      border-radius: 50%;
      display: grid;
      place-items: center;
      cursor: pointer;
      transition: transform .12s ease;
      flex-shrink: 0;
    }

    .icon-btn:hover {
      transform: translateY(-1px)
    }

    .icon-btn img {
      width: 60px;
      height: 60px;
      display: block;
    }

    .lang-switch {
      display: flex;
      border-radius: 9999px;
      border: 1px solid #32507b;
      background: #fff;
      padding: 2px;
      gap: 2px;
      flex-shrink: 0;
    }

    .lang-switch button {
      border: 0;
      background: transparent;
      color: #6b7280;
      padding: 6px 14px;
      border-radius: 9999px;
      font-size: 12px;
      cursor: pointer;
    }

    .lang-switch button.active {
      background: #223c63;
      color: #fff;
    }

    /* Sidebar */
    .sidebar-overlay {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background: rgba(0, 0, 0, 0.5);
      z-index: 998;
      display: none;
    }

    .sidebar-overlay.show {
      display: block;
    }

    .sidebar {
      position: fixed;
      top: 0;
      right: -100%;
      width: 320px;
      max-width: 85vw;
      height: 100%;
      background: #fff;
      z-index: 999;
      transition: right .3s ease;
      overflow-y: auto;
      box-shadow: -5px 0 15px rgba(0, 0, 0, .2);
    }

    .sidebar.show {
      right: 0;
    }

    html[dir="ltr"] .sidebar {
      right: auto;
      left: -100%;
      transition: left .3s ease;
      box-shadow: 5px 0 15px rgba(0, 0, 0, .2);
    }

    html[dir="ltr"] .sidebar.show {
      left: 0;
    }

    .sidebar-header {
      padding: 20px;
      background: linear-gradient(180deg, #335b92 0%, #2a4a75 100%);
      color: #fff;
      display: flex;
      justify-content: space-between;
      align-items: center;
    }

    .sidebar-header h3 {
      margin: 0;
      font-size: 20px;
      font-weight: 700;
    }

    .sidebar-close {
      background: transparent;
      border: none;
      color: #fff;
      font-size: 28px;
      cursor: pointer;
      width: 32px;
      height: 32px;
      display: flex;
      align-items: center;
      justify-content: center;
      line-height: 1;
    }

    .sidebar-menu {
      padding: 0;
      margin: 0;
      list-style: none;
    }

    .sidebar-menu li a {
      display: block;
      padding: 16px 20px;
      color: #333;
      text-decoration: none;
      border-bottom: 1px solid #eee;
      transition: background .2s;
    }

    .sidebar-menu li a:hover {
      background: #f5f5f5;
      color: #003DA6;
    }

    .sidebar-menu li a.active {
      background: #003DA6;
      color: #fff;
    }

    /* ====== PAGE BACKGROUND ====== */
    .background-bg {
      background-image: url('assets/NewTopImage.png');
      background-color: #ced7ea;
      background-size: cover;
      background-position: center;
      background-repeat: no-repeat;
      position: relative;
      width: 100%;
      min-height: 100vh;
    }

    .background-bg::before {
      content: "";
      position: absolute;
      inset: 0;
      opacity: .45;
      pointer-events: none;
    }

    .background-bg::after {
      content: "";
      position: absolute;
      inset: 0;
      pointer-events: none;
      mix-blend-mode: normal;
    }

    /* ====== BLUE RIBBON ====== */
    .hero-section {
      color: #fff;
      padding: 5px 25px;
      position: relative;
      overflow: hidden;
      background: linear-gradient(135deg, #4A65B2 0%, #365090 100%);
      background-size: cover;
      background-position: center;
    }

    .hero-section::before {
      content: '';
      position: absolute;
      inset: 0;
      background-image: repeating-linear-gradient(90deg, rgba(255, 255, 255, .03) 0, transparent 1px, transparent 40px), repeating-linear-gradient(0deg, rgba(255, 255, 255, .03) 0, transparent 1px, transparent 40px)
    }

    .hero-content {
      position: relative;
      z-index: 1;
    }

    .all-panel-title {
      display: flex;
      align-items: center;
      gap: 15px;
      font-size: 25px;
      font-weight: bold;
    }

    .all-panel-title .title-sm {
      font-size: 13px;
      font-weight: 500;
      opacity: .85;
    }

    .panel-icon {
      width: 55px;
      height: 60px;
    }

    /* ====== Tiles ====== */
    .tiles-wrap {
      position: relative;
      z-index: 1;
    }

    .tiles-row {
      margin-top: 50px;
      padding-right: 400px;
      padding-left: 300px;
    }

    .tile-btn {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      gap: 8px;
      background: #f5f8ff82;
      border: 1px solid rgba(255, 255, 255, .22);
      border-radius: 16px;
      padding: 18px 16px;
      height: 110px;
      color: #1A3269;
      text-decoration: none;
      text-align: center;
      transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
      box-shadow: 0 4px 10px rgba(0, 0, 0, .04);
    }

    .tile-btn img {
      /*width: 80px;*/
      height: 80px;
      object-fit: contain;
    }

    .tile-btn .t-title {
      font-weight: 800;
      font-size: 14px;
      color: #1A3269;
    }

    .tile-btn:hover {
      background: linear-gradient(135deg, #4A65B2 0%, #365090 100%);
      box-shadow: 0 12px 24px rgba(0, 0, 0, .22);
      transform: translateY(-6px);
    }

    .tile-btn:hover .t-title {
      color: #fff;
    }

    .tile-btn:hover img {
      filter: brightness(0) invert(1);
    }

    .tile-btn.active {
      background: linear-gradient(135deg, #4A65B2 0%, #365090 100%);
      border-color: rgba(255, 255, 255, .35);
      box-shadow: 0 12px 24px rgba(0, 0, 0, .22);
    }

    .tile-btn.active .t-title {
      color: #fff;
    }

    .tile-btn.active img {
      filter: brightness(0) invert(1);
    }

    /* ====== Content Cards ====== */
    .content-wrap {
      padding: 28px 40px;
      position: relative;
      z-index: 1;
    }

    .sidebar-card {
      background: #FFFFFF7D;
      border-radius: 18px;
      padding: 14px;
      border: 1px solid #e5e7eb;
    }

    .side-item {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 12px;
      border-radius: 30px;
      margin-bottom: 8px;
      position: relative;
      border: 1px solid #e9edf5;
      color: #0E2747;
      text-decoration: none;
    }

    .side-item:not(:last-child)::after {
      content: "";
      position: absolute;
      left: 12px;
      right: 12px;
      bottom: -1px;
      height: 1px;
      background: rgba(14, 39, 71, .12);
      pointer-events: none;
    }

    .side-item.active,
    .side-item:hover {
      background: linear-gradient(135deg, #4A65B2 0%, #365090 100%);
      color: #fff;
      border-color: #003DA6;
    }

    .side-item i {
      opacity: .6;
    }

    .main-card {
      background: #FFFFFF7D;
      border-radius: 18px;
      padding: 18px;
      border: 1px solid #e5e7eb;
    }

    .note-box {
      color: #0E2747;
      border-radius: 12px;
      padding: 14px 16px;
      margin-bottom: 14px;
    }

    .note-box strong {
      margin-inline-start: 6px;
    }

    .talk-chip {
      display: flex;
      align-items: center;
      gap: 10px;
      background: #FFFFFF6D;
      border: 1px solid #E3E9F9;
      border-radius: 14px;
      padding: 12px 14px;
      margin-bottom: 14px;
    }

    .talk-chip .badge-round {
      width: 42px;
      height: 42px;
      border-radius: 999px;
      background: linear-gradient(180deg, #e9f0ff, #d7e4ff);
      display: grid;
      place-items: center;
    }

    .form-shell {
      border-radius: 18px;
      padding: 20px 20px 22px;
      background: #f5f8ff;
      border: 1px solid #dfe6f5;
    }

    /* ===== Rent table UI ===== */
    .form-shell.rent-shell {
      background: #fff;
      border: 1px solid #dfe6f5;
      padding: 18px;
    }

    .rent-search {
      position: relative;
      margin-bottom: 14px;
    }

    .rent-search input {
      width: 100%;
      height: 56px;
      border-radius: 14px;
      border: 1px solid #e5e7eb;
      padding: 0 56px 0 56px;
      font-size: 16px;
      background: #fff;
      outline: none;
    }

    .rent-search .icon-right,
    .rent-search .icon-left {
      position: absolute;
      top: 50%;
      transform: translateY(-50%);
      color: #6b7280;
      font-size: 18px;
      pointer-events: none;
    }

    .rent-search .icon-right {
      right: 18px;
    }

    .rent-search .icon-left {
      left: 18px;
    }

    .rent-table-wrap {
      border: 1px solid #e5e7eb;
      border-radius: 14px;
      overflow: hidden;
      background: #fff;
    }

    .rent-table {
      width: 100%;
      border-collapse: separate;
      border-spacing: 0;
      direction: rtl;
    }

    .rent-table thead th {
      font-weight: 700;
      font-size: 14px;
      padding: 12px 10px;
      background: #f8fafc;
      border-bottom: 1px solid #e5e7eb;
      color: #0E2747;
      white-space: nowrap;
    }

    .rent-table tbody td {
      padding: 14px 10px;
      border-bottom: 1px solid #edf2f7;
      font-size: 16px;
      color: #0E2747;
      vertical-align: middle;
      background: #fff;
    }

    .rent-table tbody tr:last-child td {
      border-bottom: none;
    }

    .fee-pill {
      display: inline-block;
      min-width: 72px;
      text-align: center;
      padding: 6px 12px;
      border-radius: 999px;
      background: #f6d6cf;
      color: #1f2937;
      font-weight: 700;
      font-size: 14px;
    }

    .month-select {
      width: 140px;
      height: 52px;
      border-radius: 12px;
      border: 1px solid #d5def2;
      background: #fff;
      padding: 0 16px 0 40px;
      font-size: 16px;
      appearance: none;
    }

    .month-select-wrap {
      position: relative;
      display: inline-block;
    }

    .month-select-wrap i {
      position: absolute;
      left: 14px;
      top: 50%;
      transform: translateY(-50%);
      color: #6b7280;
      font-size: 14px;
      pointer-events: none;
    }

    .pay-check {
      width: 28px;
      height: 28px;
      accent-color: #365090;
      cursor: pointer;
    }

    /* force footer layout baseline so swap is predictable */

    .table-footer {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      padding-top: 12px;
      flex-wrap: wrap;
      direction: ltr;

    }

    /* arabic view: pagination left, page size right */
    html[dir="rtl"] .table-footer .pagination-box {
      order: 1;
    }

    html[dir="rtl"] .table-footer .page-size {
      order: 2;
    }

    /* english view: pagination right, page size left */
    html[dir="ltr"] .table-footer .pagination-box {
      order: 2;
    }

    html[dir="ltr"] .table-footer .page-size {
      order: 1;
    }


    .pagination-box {
      display: flex;
      align-items: stretch;
      background: #fff;
      border: 1px solid #d7deea;
      border-radius: 10px;
      overflow: hidden;
      height: 48px;
    }

    .pagination-box button {
      background: transparent;
      border: 0;
      height: 48px;
      padding: 0 14px;
      font-size: 16px;
      color: #7a89a6;
      min-width: 48px;
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 8px;
      line-height: 1;
    }

    /* thin separators between segments */
    .pagination-box button+button {
      border-inline-start: 1px solid #e6ebf3;
    }

    .pagination-box button.active {
      background: #e9eef9;
      color: #1f2a44;
      font-weight: 700;
    }

    /* make first and last feel like the rounded ends */
    .pagination-box button:first-child {
      padding-inline-start: 18px;
    }

    .pagination-box button:last-child {
      padding-inline-end: 18px;
    }

    .page-size {
      display: flex;
      align-items: center;
      gap: 12px;
      font-size: 18px;
      color: #0E2747;
      white-space: nowrap;
    }

    .page-size select {
      height: 48px;
      width: 96px;
      border: 1px solid #d7deea;
      border-radius: 10px;
      padding: 0 12px;
      font-size: 16px;
      background: #fff;
      appearance: none;
      text-align: center;
      cursor: pointer;
      box-shadow: 0 2px 6px rgba(15, 23, 42, 0.06);
    }

    /* small caret on the left in rtl, right in ltr */
    .page-size {
      position: relative;
    }

    .page-size select {
      padding-inline-start: 28px;
      padding-inline-end: 12px;
    }

    .page-size::before {
      content: "\f078";
      font-family: "Font Awesome 6 Free";
      font-weight: 900;
      position: absolute;
      inset-inline-start: 110px;
      /* sits inside the select */
      top: 50%;
      transform: translateY(-50%);
      font-size: 12px;
      color: #7a89a6;
      pointer-events: none;
    }


    .action-row {
      display: flex;
      gap: 14px;
      margin-top: 18px;
    }

    .btn-outline {
      background: #fff;
      color: #365090;
      border: 2px solid #365090;
      padding: 10px 22px;
      border-radius: 999px;
      font-size: 18px;
      font-weight: 700;
      cursor: pointer;
    }

    .btn-pay {
      border-radius: 999px;
      padding: 10px 22px;
      font-size: 18px;
      font-weight: 700;
    }

    /* Inputs more like mockup */
    .moj-input {
      width: 100%;
      background: #ffffff;
      border: 1px solid #d5def2;
      border-radius: 10px;
      padding: 12px 16px;
      font-size: 14px;
    }

    /* Select styling */
    .select-wrapper {
      position: relative;
    }

    .select-input {
      appearance: none;
      -webkit-appearance: none;
      -moz-appearance: none;
      padding-inline-end: 38px;
      background-color: #fff;
      border-radius: 10px;
      border: 1px solid #d5def2;
      box-shadow: 0 2px 6px rgba(15, 23, 42, 0.06);
      cursor: pointer;
    }

    .select-caret {
      position: absolute;
      top: 50%;
      left: 14px;
      transform: translateY(-50%);
      font-size: 12px;
      color: #6b7280;
      pointer-events: none;
    }

    .select-input option {
      padding: 8px 14px;
      border-bottom: 1px solid #edf2fb;
    }

    .select-input:focus {
      outline: none;
      box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.2);
      border-color: #3b82f6;
    }

    /* Upload box */
    .upload-area {
      border: 2px dashed #c5d0ea;
      border-radius: 16px;
      background: #f6f8ff;
      padding: 26px 18px;
      position: relative;
    }

    .upload-inner {
      pointer-events: none;
    }

    .upload-input {
      position: absolute;
      inset: 0;
      opacity: 0;
      cursor: pointer;
    }

    .upload-icon {
      width: 70px;
      height: 120px;
      border-radius: 16px;
      padding: 20px;
      display: flex;
      align-items: center;
      justify-content: center;
      margin: 0 auto 10px;
      font-size: 24px;
      color: #003da6;
    }

    /* Checkbox text alignment */
    .custom-check input {
      margin-top: 4px;
    }

    .custom-check span {
      font-size: 13px;
      color: #0e2747;
    }

    .check-title {
      display: block;
      color: #e11d48;
      font-weight: 700;
      margin-bottom: 4px;
    }

    /* Make recaptcha box look closer to sample */
    .recaptcha-box {
      background: #fff;
      border-style: solid;
      border-color: #d5def2;
    }

    .btn-primary {
      background: linear-gradient(135deg, #4A65B2 0%, #365090 100%);
      color: #fff;
      border: none;
      padding: 12px 24px;
      border-radius: 8px;
      cursor: pointer;
      font-size: 14px;
      font-weight: 700;
      transition: background .18s ease;
    }

    .btn-primary:hover {
      background: linear-gradient(135deg, #365090 0%, #4A65B2 100%);
    }

    /* ====== Footer ====== */
    .footer {
      background: linear-gradient(to bottom, #4A65B2, #365090);
      border-top: 1px solid #c9c9c9;
      padding: 12px 24px;
      margin-top: auto;
      display: flex;
      justify-content: space-between;
      align-items: center;
      font-size: 12px;
      color: #fff;
      direction: rtl;
      gap: 12px;
      flex-wrap: wrap;
    }

    .footer-left,
    .footer-right {
      display: flex;
      align-items: center;
      gap: 16px;
      flex-wrap: wrap
    }

    .footer-item {
      cursor: pointer;
      transition: color .2s ease
    }

    .footer-left .footer-item:hover {
      color: #144767
    }

    .footer-right .footer-item {
      cursor: default;
    }

    /* Hide rent shell by default */
    #rentShell {
      display: none;
    }

    /* ====== Responsive ====== */
    @media (max-width:992px) {
      .content-wrap {
        padding: 20px
      }

      .tiles-row {
        margin-top: 20px;
        padding: 20px;
      }

      .t-title {
        padding: 0;
      }
    }

    @media (max-width:768px) {
      .header {
        padding: 12px 16px;
      }

      .header-row {
        display: grid;
        grid-template-columns: auto 1fr auto;
        grid-template-areas: "actions title logo";
        gap: 10px;
      }

      .header-actions {
        grid-area: actions;
        gap: 8px;
      }

      .center-logo-text {
        grid-area: title;
        position: static;
        transform: none;
        justify-content: center;
        font-size: 16px;
        max-width: none;
      }

      .center-logo-text img {
        width: 20px;
        height: 20px;
      }

      .logo-section {
        grid-area: logo;
        gap: 8px;
      }

      .logo-badge {
        width: 40px;
        height: 40px;
      }

      .logo-badge img {
        width: 40px;
        height: 40px;
      }

      .logo-text {
        display: none;
      }

      .icon-btn {
        width: 36px;
        height: 36px;
      }

      .icon-btn img {
        width: 36px;
        height: 36px;
      }

      .content-wrap {
        padding: 18px
      }

      .tiles-row .col-md-3 {
        margin-bottom: 10px
      }

      .tile-btn {
        height: 100px
      }

      .tile-btn img {
        width: 40px;
        height: 40px
      }
    }