/* ==========================================================================
   ISLAMI COMICS - PAYOUTS ROOM STYLESHEET
   Matching Mockup Image 7 Pixel-Perfect Design
   ========================================================================== */

.payouts-page-body {
  background-color: #f5f8f6;
}

.payouts-main-stage {
  padding-bottom: 40px;
}

/* ==========================================================================
   1. TOP 5 METRIC SUMMARY CARDS (5-GRID)
   ========================================================================== */
.payouts-metrics-grid-5 {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

.val-green {
  color: var(--emerald-dark) !important;
}

.val-red {
  color: #dc2626 !important;
}

/* ==========================================================================
   2. MAIN 2-COLUMN LAYOUT
   ========================================================================== */
.payouts-layout-2col {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 20px;
  align-items: start;
}

.payouts-table-card {
  background: #ffffff;
  border: 1px solid var(--card-border);
  border-radius: 14px;
  box-shadow: var(--card-shadow);
  overflow: hidden;
  min-width: 0;
}

.payouts-right-col {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-width: 0;
}

/* Toolbar & Tabs Row (Modern Sleek Grid) */
.table-toolbar-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 18px;
  border-bottom: 1px solid var(--card-border);
  gap: 12px;
  flex-wrap: nowrap;
}

.table-filter-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  overflow-x: auto;
  white-space: nowrap;
  flex: 1;
  min-width: 0;
  scrollbar-width: none;
}

.table-filter-tabs::-webkit-scrollbar {
  display: none;
}

.filter-tab-btn {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 8px 10px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-sub);
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s;
  flex-shrink: 0;
}

.filter-tab-btn:hover {
  color: var(--text-main);
}

.filter-tab-btn.active {
  color: var(--emerald-dark);
  border-bottom-color: var(--emerald);
  font-weight: 800;
}

/* Toolbar Right: Date Picker & Filter */
.payouts-toolbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn-date-range-picker {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #ffffff;
  border: 1px solid var(--card-border);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-main);
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
  transition: all 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}

.btn-date-range-picker:hover {
  border-color: var(--emerald);
  background: #f8faf9;
}

.btn-toolbar-filter {
  background: #ffffff;
  border: 1px solid var(--card-border);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-main);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}

.btn-toolbar-filter:hover {
  background: #f8faf9;
  border-color: var(--emerald);
}

/* ==========================================================================
   3. PAYOUTS DATA TABLE
   ========================================================================== */
.payouts-data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  min-width: 960px;
}

.payouts-data-table thead tr {
  background: #fbfdfc;
  border-bottom: 1px solid var(--card-border);
}

.payouts-data-table th {
  padding: 12px 14px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: #64748b;
  text-transform: uppercase;
  white-space: nowrap;
}

.payouts-data-table tbody tr.payout-row {
  border-bottom: 1px solid #f1f5f3;
  transition: background 0.15s ease;
}

.payouts-data-table tbody tr.payout-row:hover {
  background: #f9fbf9;
}

.payouts-data-table td {
  padding: 13px 14px;
  vertical-align: middle;
  font-size: 12px;
}

.td-payout-id {
  font-weight: 800;
  color: #1e293b;
  white-space: nowrap;
}

.td-requested {
  white-space: nowrap;
}

.date-main {
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
}

.date-time {
  font-size: 10px;
  color: var(--text-muted);
}

/* Payout Method Cell */
.method-cell-group {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 160px;
}

.method-icon-box {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  flex-shrink: 0;
}

.icon-bank {
  background: #f1f5f9;
  color: #334155;
}

.icon-purple {
  background: #faf5ff;
  color: #7c3aed;
}

.icon-orange {
  background: #fff7ed;
  color: #ea580c;
}

.icon-blue {
  background: #eff6ff;
  color: #2563eb;
}

.method-meta {
  min-width: 0;
}

.method-name {
  font-weight: 800;
  color: var(--text-main);
  font-size: 12px;
  white-space: nowrap;
}

.method-account {
  font-size: 11px;
  color: var(--text-sub);
  white-space: nowrap;
}

.method-holder {
  font-size: 10px;
  color: var(--text-muted);
  white-space: nowrap;
}

.td-amount {
  white-space: nowrap;
}

.td-amount strong {
  font-weight: 800;
  color: var(--text-main);
  font-size: 13px;
}

/* Status Badges */
.badge-payout-status {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 10.5px;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
}

.badge-payout-status.status-pending {
  background: #fffbeb;
  color: #d97706;
}

.badge-payout-status.status-processing {
  background: #eff6ff;
  color: #2563eb;
}

.badge-payout-status.status-completed {
  background: #f0fdf4;
  color: #10b981;
}

.badge-payout-status.status-failed {
  background: #fef2f2;
  color: #dc2626;
}

.badge-payout-status.status-cancelled {
  background: #f1f5f9;
  color: #64748b;
}

.status-note-sub {
  font-size: 9.5px;
  color: var(--text-muted);
  margin-top: 2px;
  white-space: nowrap;
}

.td-paid-date {
  white-space: nowrap;
}

.ref-text {
  font-size: 11px;
  color: var(--text-sub);
  white-space: nowrap;
}

.text-danger {
  color: #ef4444 !important;
}

.text-success {
  color: var(--emerald-dark) !important;
}

.btn-payout-view {
  background: #ffffff;
  border: 1px solid var(--card-border);
  border-radius: 6px;
  padding: 4px 9px;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-main);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
}

.btn-payout-view:hover {
  border-color: var(--emerald);
  color: var(--emerald-dark);
  background: #f8faf9;
}

/* ==========================================================================
   4. RIGHT COLUMN: 4 CARDS
   ========================================================================== */

/* Card 1: Payout Actions (Dark Emerald) */
.payout-action-card {
  background: linear-gradient(135deg, #053b2a 0%, #03251a 100%);
  border: 1px solid #095039;
  border-radius: 14px;
  padding: 18px 20px;
  color: #ffffff;
  box-shadow: 0 4px 16px rgba(5, 59, 42, 0.2);
}

.action-card-header {
  font-size: 13px;
  font-weight: 800;
  color: #a7f3d0;
  margin-bottom: 12px;
}

.available-title-row {
  font-size: 11px;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 2px;
}

.available-number-row {
  font-size: 20px;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -0.5px;
  margin-bottom: 14px;
}

.btn-primary-withdraw-cta {
  width: 100%;
  background: #ffffff;
  color: #064e3b;
  border: none;
  border-radius: 8px;
  padding: 10px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.btn-primary-withdraw-cta:hover {
  background: #f0fdf4;
  transform: translateY(-1px);
}

/* Card 2: Payout Method Card */
.payout-method-card {
  background: #ffffff;
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 18px 20px;
  box-shadow: var(--card-shadow);
}

.method-card-header {
  font-size: 13px;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 12px;
}

.method-card-info-box {
  background: #f8faf9;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.method-card-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid var(--card-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  color: var(--text-main);
  flex-shrink: 0;
}

.method-card-details {
  flex: 1;
  min-width: 0;
}

.details-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2px;
}

.method-type-name {
  font-size: 12.5px;
  font-weight: 800;
  color: var(--text-main);
}

.badge-default-method {
  background: #f0fdf4;
  color: #059669;
  border: 1px solid #bbf7d0;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 9.5px;
  font-weight: 800;
}

.method-number-text {
  font-size: 11.5px;
  color: var(--text-sub);
}

.method-owner-text {
  font-size: 10.5px;
  color: var(--text-muted);
}

.btn-manage-payout-method {
  width: 100%;
  background: #ffffff;
  border: 1px solid var(--card-border);
  color: var(--text-main);
  border-radius: 8px;
  padding: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s;
}

.btn-manage-payout-method:hover {
  background: #f8faf9;
  border-color: #cbd5e1;
}

/* Card 3: Payout Summary Card */
.payout-summary-card {
  background: #ffffff;
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 18px 20px;
  box-shadow: var(--card-shadow);
}

.summary-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 12px;
}

.summary-sub-tag {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}

.summary-meta-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 12px;
}

.summary-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--text-sub);
}

.summary-meta-row strong {
  color: var(--text-main);
  font-weight: 800;
}

/* Card 4: How Payouts Work Card */
.how-payouts-card {
  background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
  border: 1px solid #bbf7d0;
  border-radius: 14px;
  padding: 18px 20px;
  position: relative;
  overflow: hidden;
}

.how-card-title {
  font-size: 13px;
  font-weight: 800;
  color: #047857;
  margin-bottom: 10px;
}

.how-payouts-checklist {
  list-style: none;
  padding: 0;
  margin: 0 0 12px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  z-index: 2;
}

.how-payouts-checklist li {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  font-size: 11px;
  color: #065f46;
  line-height: 1.35;
}

.check-icon {
  font-size: 11px;
  color: #059669;
  margin-top: 1px;
  flex-shrink: 0;
}

.how-learn-more-link {
  font-size: 11.5px;
  font-weight: 800;
  color: #047857;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  position: relative;
  z-index: 2;
}

.how-learn-more-link:hover {
  text-decoration: underline;
}

/* ==========================================================================
   5. RESPONSIVE BREAKPOINTS
   ========================================================================== */
@media (max-width: 1200px) {
  .payouts-layout-2col {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1050px) {
  .payouts-metrics-grid-5 {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .payouts-metrics-grid-5 {
    grid-template-columns: repeat(2, 1fr);
  }

  .table-toolbar-row {
    flex-direction: column;
    align-items: stretch;
  }

  .payouts-toolbar-right {
    justify-content: space-between;
  }
}

@media (max-width: 540px) {
  .payouts-metrics-grid-5 {
    grid-template-columns: 1fr;
  }
}
