/* Fee Details Page Styles - Simple & Elegant */
.fee-details-page {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background-color: #fafafa;
  min-height: 100vh;
  color: #333;
}

/* Student Header */
.fee-details-page .student-header {
  display: flex;
  align-items: center;
  background: white;
  padding: 20px;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
  margin-bottom: 20px;
}

.fee-details-page .student-photo {
  width: 50px;
  height: 50px;
  background-color: #f5f5f5;
  border-radius: 50%;
  margin-right: 20px;
  border: 2px solid #e0e0e0;
  position: relative;
}

.fee-details-page .student-photo::after {
  content: "👤";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 20px;
  opacity: 0.6;
}

.fee-details-page .student-info {
  flex: 1;
}

.fee-details-page .student-info div {
  margin-bottom: 6px;
  color: #555;
  font-size: 14px;
}

.fee-details-page .student-info strong {
  color: #333;
  margin-right: 8px;
}

.fee-details-page hr {
  border: none;
  height: 1px;
  background-color: #e0e0e0;
  margin: 25px 0;
}

/* Section Title */
.fee-details-page .section-title {
  font-size: 20px;
  font-weight: 600;
  color: #333;
  margin-bottom: 20px;
  text-align: left;
}

/* Table Container */
.fee-details-page .table-box {
  background: white;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
  overflow: hidden;
}

.fee-details-page .fee-table {
  width: 100%;
  border-collapse: collapse;
}

.fee-details-page .fee-table thead th {
  background-color: #f8f9fa;
  color: #333;
  padding: 16px;
  text-align: left;
  font-weight: 600;
  font-size: 14px;
  border-bottom: 1px solid #e0e0e0;
}

.fee-details-page .fee-table tbody td {
  padding: 16px;
  border-bottom: 1px solid #f0f0f0;
  vertical-align: middle;
}

.fee-details-page .fee-table tbody tr:hover {
  background-color: #fbfbfb;
}

.fee-details-page .fee-table tbody tr:last-child td {
  border-bottom: none;
}

/* Fee Badges - FIXED SIZE */
.fee-details-page .fee-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 90px;    /* consistent width */
  height: 32px;       /* consistent height */
  font-size: 14px;
  border-radius: 4px;
  box-sizing: border-box;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0 8px;     /* allow spacing for longer numbers */
  text-align: center;
}

.fee-details-page .fee-badge.paid {
  background-color: #f0f9f0;
  color: #2d5a2d;
  border: 1px solid #d4edda;
}

.fee-details-page .fee-badge.unpaid {
  background-color: #fdf2f2;
  color: #6b2c2c;
  border: 1px solid #f5c6cb;
}

.fee-details-page .fee-badge:hover {
  opacity: 0.8;
}

/* Total Box */
.fee-details-page .total-box {
  background-color: #f8f9fa;
  text-align: center;
  vertical-align: middle;
  position: relative;
  border-left: 1px solid #e0e0e0;
}

.fee-details-page .total-box .amount {
  font-size: 16px;
  font-weight: 600;
  margin: 0;
  cursor: pointer;
  transition: color 0.2s ease;
}

.fee-details-page .total-box .amount:hover {
  opacity: 0.8;
}

.fee-details-page .total-box .amount.red {
  color: #d73527;
}

.fee-details-page .total-box .amount.green {
  color: #28a745;
}

.fee-details-page .total-box .label {
  font-size: 12px;
  color: #666;
  font-weight: 400;
  margin: 0;
  line-height: 1.4;
}

.fee-details-page .total-box .label.red {
  color: #d73527;
}

.fee-details-page .total-box .label.green {
  color: #28a745;
}

/* Amount Click Effect */
.fee-details-page .amount-click {
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.fee-details-page .amount-click:hover {
  opacity: 0.8;
}

/* Popup Styles */
.fee-details-page .pending-popup {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  box-sizing: border-box;
}

.fee-details-page .popup-content {
  background: white;
  border-radius: 8px;
  width: 90%;
  max-width: 420px;   /* smaller popup */
  max-height: none;
  overflow-y: visible;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  animation: fadeIn 0.3s ease-out;
  margin: auto;
  position: relative;
  padding-bottom: 10px;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.fee-details-page .popup-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 16px; /* reduced */
  background-color: #f8f9fa;
  border-bottom: 1px solid #e0e0e0;
  border-radius: 8px 8px 0 0;
}

.fee-details-page .popup-header span {
  font-size: 13px;   /* smaller heading */
  font-weight: 500;
  color: #333;
}

.fee-details-page .close-btn {
  background: none;
  border: none;
  color: #666;
  font-size: 16px;
  cursor: pointer;
  width: 26px;
  height: 26px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease;
}

.fee-details-page .close-btn:hover {
  background-color: #e9ecef;
  color: #333;
}

.fee-details-page .popup-body {
  padding: 15px;
}

.fee-details-page .popup-amount-box {
  display: flex;
  align-items: center;
  padding: 10px;
  background: #f8f9fa;
  border-radius: 6px;
  margin-bottom: 15px;
  border: 1px solid #e9ecef;
}

.fee-details-page .popup-amount-box .icon {
  width: 30px;
  height: 30px;
  background-color: #6c757d;
  border-radius: 50%;
  margin-right: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 9px;
  font-weight: 600;
}

.fee-details-page .account-label {
  font-weight: 500;
  color: #333;
  font-size: 13px;
}

.fee-details-page .txn-no {
  color: #666;
  font-size: 11px;
  margin-top: 3px;
}

.fee-details-page .popup-amount-box .date {
  margin-left: auto;
  font-size: 11px;
  color: #666;
  font-weight: 500;
}

.fee-details-page .amount-info {
  text-align: center;
  margin-bottom: 15px;
}

.fee-details-page .amount-info .amount {
  font-size: 22px;  /* smaller amount */
  font-weight: 600;
  color: #333;
  margin-bottom: 10px;
}

.fee-details-page .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
}

.fee-details-page .tag {
  padding: 3px 6px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 500;
  border: 1px solid transparent;
}

.fee-details-page .tag.pink {
  background-color: #fdf2f8;
  color: #be185d;
  border-color: #f3e8ff;
}

.fee-details-page .tag.red {
  background-color: #fef2f2;
  color: #dc2626;
  border-color: #fecaca;
}

.fee-details-page .tag.blue {
  background-color: #eff6ff;
  color: #2563eb;
  border-color: #dbeafe;
}

.fee-details-page .tag.green {
  background-color: #f0fdf4;
  color: #16a34a;
  border-color: #bbf7d0;
}

.fee-details-page .pay-box {
  text-align: center;
  margin-bottom: 15px;
}

.fee-details-page .pay-now-btn {
  background-color: #495057;
  color: white;
  border: none;
  padding: 8px 18px; /* smaller button */
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.fee-details-page .pay-now-btn:hover {
  background-color: #343a40;
}

.fee-details-page .payment-breakup {
  background: #f8f9fa;
  border-radius: 6px;
  padding: 12px;
  border: 1px solid #e9ecef;
}

.fee-details-page .breakup-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  font-weight: 600;
  color: #333;
  font-size: 13px;
}

.fee-details-page .payment-breakup table {
  width: 100%;
  border-collapse: collapse;
}

.fee-details-page .payment-breakup table td {
  padding: 6px 0;
  border-bottom: 1px solid #e9ecef;
  font-size: 13px;
  color: #555;
}

.fee-details-page .payment-breakup table tr:last-child td {
  border-bottom: none;
}

.fee-details-page .payment-breakup table .total-row {
  border-top: 1px solid #dee2e6;
  padding-top: 6px;
}

.fee-details-page .payment-breakup table .total-row td {
  font-size: 14px;
  color: #333;
  font-weight: 600;
  padding-top: 10px;
}

/* Payment section wrapper */
.fee-details-page .payment-section {
  display: flex;
  align-items: flex-start;
  gap: 30px;
  margin: 20px 0;
}

/* Left side: radio buttons */
.fee-details-page .payment-methods {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 150px;
}

/* Right side: Upload section */
.fee-details-page .upload-section {
  flex: 1;
  padding: 15px;
  background: #f9f9f9;
  border: 1px dashed #bbb;
  border-radius: 6px;
  font-size: 13px;
}

/* Vertical radio button styling */
.options-list {
 display: flex;
 flex-direction: column;
 gap: 10px;
}

.options-list label {
 display: flex;
 align-items: center;
 padding: 8px 12px;
 border: 1px solid #ddd;
 border-radius: 6px;
 cursor: pointer;
 transition: background-color 0.2s ease;
}

.options-list label:hover {
 background-color: #f8f9fa;
}

.options-list input[type="radio"] {
 margin-right: 10px;
 margin-left: 0;
}

.options-list label:has(input:checked) {
 background-color: #e3f2fd;
 border-color: #007bff;
}

/* Align Amount column consistently */
.fee-details-page .fee-table td:nth-child(2) {
  text-align: center;
  width: 120px;           
  font-variant-numeric: tabular-nums;
  font-family: monospace, 'Segoe UI', sans-serif;
}


.fee-details-page .fee-table .fee-badge {
  margin: 0 auto;
}

.fee-details-page .fee-badge,
.fee-details-page .total-box .amount,
.fee-details-page .popup-amount-box .amount,
.fee-details-page .payment-breakup td:last-child {
  font-size: 14px !important;
  font-weight: 600 !important;
  font-variant-numeric: tabular-nums !important;
  font-family: monospace, 'Segoe UI', sans-serif !important;
  min-width: 90px !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
}

/* Responsive Design */
@media (max-width: 768px) {
  .fee-details-page {
    padding: 15px;
  }
  
  .fee-details-page .student-header {
    flex-direction: column;
    text-align: center;
  }
  
  .fee-details-page .student-photo {
    margin-right: 0;
    margin-bottom: 15px;
  }
  
  .fee-details-page .fee-table thead th,
  .fee-details-page .fee-table tbody td {
    padding: 12px 8px;
    font-size: 12px;
  }
  
  .fee-details-page .total-box .amount {
    font-size: 14px;
  }
  
  .fee-details-page .popup-content {
    width: 95%;
    margin: 10px;
    max-width: 360px; 
  }
  
  .fee-details-page .amount-info .amount {
    font-size: 20px;
  }
  
  .fee-details-page .payment-section {
    flex-direction: column;
    gap: 15px;
  }
  
  .fee-details-page .payment-methods {
    min-width: 100%;
  }
}

@media (max-width: 480px) {
  .fee-details-page {
    padding: 10px;
  }
  
  .fee-details-page .fee-table {
    font-size: 11px;
  }
  
  .fee-details-page .fee-table thead th,
  .fee-details-page .fee-table tbody td {
    padding: 8px 4px;
  }
  
  .fee-details-page .fee-badge {
    min-width: 70px;
    height: 28px;
    font-size: 12px;
  }
  
  .fee-details-page .popup-content {
    width: 98%;
    max-width: 320px;
  }
}

.fee-details-page .fee-table tbody tr:nth-child(1) td,
.fee-details-page .fee-table tbody tr:nth-child(7) td {
  text-align: center;
  width: 120px; 
}

.fee-details-page .fee-table td:first-child {
  font-size: 14px;
  font-weight: 600;
  color: #333;
  text-align: center;
  padding-left: 16px; 
}
