/* Reset and base */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Poppins, sans-serif;
  background-color: #f3f7fa;
  color: #242424;
  line-height: 1.5;
  font-size: 14px;
}

/* Container for the entire page */
.page-container {
  max-width: 1940px;
  margin: 20px auto;
  padding: 0 15px;
}

/* Header */
h1 {
  font-weight: 900;
  font-size: 40px;
  margin-bottom: 5px;
  color: #222;
  
}

p.subtitle {
  margin-top: 0;
  color: #555;
  font-size: 16px;
  font-weight: 400;
  margin-bottom: 25px;
  padding: 0px;
}

.main-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: flex-start;
  max-width: 1650px;
  width: 100%;
}

.form-wrapper {
  display: flex;
  box-shadow: 0 1px 4px rgb(0 0 0 / 0.1);
  margin-top: 25px;
  width: 100%;
}

.main-form-wrapper {
  display: flex;
  flex-direction: column;
  background-color: #fff;
  border-radius: 10px;
  width: 100%;
}

.sidebar-left {
  background: white;

  padding: 0px 20px;
  width: 25%;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.sidebar-left strong.title {
  font-weight: 700;
  color: #222;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 10px;
  margin-bottom: 15px;
  font-size: 0.95rem;
}

strong.top-title.title {
  padding: 20px 24px;
  font-size: 16px;
  border-bottom: 1px solid #0000001a;
}

.balance-box {
  background-color: #005bff;
  border-radius: 6px;
  color: white;
  padding: 10px 15px;
  font-weight: 700;
  font-size: 20px;
  width: 100%;
  user-select: none;
  box-shadow: 0 3px 7px rgb(0 91 255 / 0.3);
}

.balance-box small {
  display: block;
  font-weight: 600;
  font-size: 0.85rem;
}

.center-panel {
  background: white;
  border-radius: 0 10px 10px 0px;
  padding: 0 30px 30px 30px;
  flex-grow: 1;
  max-width: 850px;
  border-left: 1px solid #eaeaea;
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.center-panel strong.section-title {
  font-size: 30px;
  font-weight: 700;
  padding-bottom: 8px;
  color: #222;
  user-select: none;
}

.center-panel small.section-subtitle {
  color: #555;
  font-weight: 400;
  display: block;
  font-size: 15px;
}

/* Request Payment Form */
form.payment-form {
  display: flex;
  gap: 15px;
  align-items: flex-start;
  margin-bottom: 32px;
}

form.payment-form label {
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 6px;
  color: #222;
  user-select: none;
  display: block;
}

form.payment-form input[type="number"],
form.payment-form input[type="text"] {
  border: 1px solid #cbd5e1 !important;
  border-radius: 12px;
  padding: 5px 14px;
  font-size: 0.9rem;
  flex-grow: 1;
  min-width: 170px;
  transition: border-color 0.15s ease-in-out;
}

form.payment-form input[type="number"]:focus,
form.payment-form input[type="text"]:focus {
  outline: none;
  border-color: #005bff;
  box-shadow: 0 0 5px #005bffaa;
}

form.payment-form .form-group {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  min-width: 170px;
}

form.payment-form button.submit-btn {
  background-color: #005bff;
  color: white;
  font-weight: 500;
  border-radius: 8px;
  padding: 11px 21px;
  border: none;
  cursor: pointer;
  font-size: 0.85rem;
  margin-top: 26px;
  align-self: flex-start;
  user-select: none;
  transition: background-color 0.2s ease;
  white-space: nowrap;
}

form.payment-form button.submit-btn:hover {
  background-color: #0041c2;
}

.separator {
  border-top: 1px solid #e2e8f0;
  margin: 8px 0 4px 0;
}

.request-history {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.request-history .filters {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
  align-items: flex-start;
  margin-bottom: 10px;
  width: 100%;
}

.fil-div {
  width: 23%;
}

.request-history .filters label {
  font-weight: 600;
  font-size: 0.9rem;
  color: #222;
  user-select: none;
}

.request-history .filters select,
.request-history .filters input[type="date"] {
  padding: 5px 12px;
  font-size: 0.9rem;
  border-radius: 8px;
  border: 1px solid #cbd5e1 !important;
  transition: border-color 0.15s ease-in-out;
  min-width: 130px;
  margin-top: 5px;
  width: 100%;
}

.request-history .filters select:focus,
.request-history .filters input[type="date"]:focus {
  outline: none;
  border-color: #005bff;
  box-shadow: 0 0 5px #005bffaa;
  padding: 5px 12px;
}

.request-history button.search-btn {
  background-color: #005bff;
  color: white;
  border-radius: 8px;
  padding: 10px 16px;
  border: none;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 500;
  user-select: none;
  transition: background-color 0.2s ease;
  white-space: nowrap;
  margin-top: 24px;
}

.request-history button.search-btn:hover {
  background-color: #0041c2;
}

.history-table-container {
  background: rgb(241, 241, 241);
  border-radius: 15px;
  padding: 25px 15px 15px 15px;
  box-sizing: border-box;
  overflow-x: auto;
}

table.history-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

table.history-table thead tr {
  background: rgb(255, 255, 255);
  user-select: none;
}

table.history-table th,
table.history-table td {
  padding: 12px 12px;
  text-align: left;
  border-bottom: 1px solid #dde1e6;
  color: #494949;
  white-space: nowrap;
}

table.history-table th {
  font-weight: 600;
  font-size: 0.85rem;
}

table.history-table td.empty-msg {
  text-align: center;
  color: #d33c3c;
  font-weight: 600;
  padding: 18px 12px;
  white-space: normal;
  background-color: rgb(246 247 251);
}

.pagination {
  margin-top: 12px;
}

.pagination button {
  background-color: #005bff;
  border: none;
  padding: 7px 13px;
  border-radius: 5px;
  color: white;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  user-select: none;
  margin-right: 6px;
  transition: background-color 0.15s ease-in-out;
}

.pagination button:hover {
  background-color: #003fbb;
}

.sidebar-right {
  background: white;
  border-radius: 10px;
  padding: 20px;
  width: 100%;
  box-shadow: 0 1px 4px rgb(0 0 0 / 0.1);
  border: 1px solid #eaeaea;
  user-select: none;
  font-size: 0.9rem;
  color: #242424;
}

.sidebar-right strong.title {
  font-weight: 700;
  font-size: 16px;
  display: block;
  margin-bottom: 10px;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 8px;
  color: #222;
}

.sidebar-right p.help-text {
  font-weight: 400;
  line-height: 1.3;
  color: #555;
  font-size: 16px;
}

.sidebar-right p.help-text strong {
  font-weight: 700;
  margin-bottom: 7px;
  display: block;
  color: #222;
}

@media (max-width: 960px) {
  .main-content {
    flex-direction: column;
  }

  .sidebar-left,
  .sidebar-right {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 20px;
  }

  .center-panel {
    max-width: 100%;
    border-radius: 10px;
  }
}

@keyframes fadeInOut {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(20px);
  }

  10% {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }

  90% {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }

  100% {
    opacity: 0;
    transform: translateX(-50%) translateY(20px);
  }
}

.center-panel small.section-subtitle {
  margin-bottom: 15px;
}

#min-withdraw-note {
  color: #666;
  display: block;
  margin-top: 6px;
}

.request-history strong.section-title {
  font-size: 22px;
}

.request-history small.section-subtitle {
  margin-bottom: 12px;
}

nav.pagination {
  display: flex;
  gap: 8px;
}

#bottom-alert {
  display: none;
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  background-color: rgb(18, 78, 17);
  color: #000;
  padding: 12px 24px;
  border-radius: 6px;
  box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.15);
  font-size: 18px;
  z-index: 9999;
  animation: fadeInOut 1.2s ease-in-out;
}

.status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 8px;
  color: #000;
  font-weight: 600;
  white-space: nowrap;
}

.status-badge.approved {
  background-color: #39c645; 
}

.status-badge.rejected {
  background-color: #d22d2d; 
}

.status-badge.pending {
  background-color: #f9bc06; 
}

/* Pagination buttons previously styled inline in JS */
.pagination .page-btn {
  background-color: #005bff;
  color: #fff;
  border: none;
  padding: 6px 12px;
  margin: 0 4px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  user-select: none;
  transition: background-color 0.15s ease-in-out;
}

.pagination .page-btn:hover {
  background-color: #003fbb;
}

.pagination .page-btn.active {
  outline: 2px solid #fff;
}

/* Show bottom alert when JS toggles the class */
#bottom-alert.visible {
  display: block;
}

@media (max-width:768px){
  .form-wrapper{
    display:block;
  }
  form.payment-form{
    display:block;
  }
  .request-history .filters{
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .fil-div {
    width:100%;
  }
}