.edufee-page {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  min-width: 0;
}

.fee-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.85rem;
}

.fee-stat-card {
  border-radius: var(--radius-md);
  padding: 0.95rem 1.05rem;
  color: #FFFFFF;
  display: flex;
  flex-direction: column;
  gap: 3px;
  box-shadow: 0 5px 15px rgba(15, 41, 66, 0.09);
  min-width: 0;
}

.fee-stat-card.is-navy {
  background: #0F2942;
}

.fee-stat-card.is-blue {
  background: #2563EB;
}

.fee-stat-card.is-teal {
  background: #0F766E;
}

.fee-stat-card.is-red {
  background: #DC2626;
}

.fee-stat-label {
  font-size: 0.76rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.88);
}

.fee-stat-value {
  font-size: 1.38rem;
  font-weight: 700;
  line-height: 1.2;
}

.fee-stat-sub {
  font-size: 0.72rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
}

.fee-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.fee-search-wrap {
  position: relative;
  flex: 1;
  min-width: 210px;
  max-width: 320px;
}

.fee-search-icon {
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  pointer-events: none;
}

.fee-search-input {
  width: 100%;
  height: 38px;
  padding: 0 14px 0 38px;
  border: none;
  border-radius: var(--radius-pill);
  background: var(--bg-white);
  color: var(--navy-900);
  font-family: inherit;
  font-size: 0.86rem;
  font-weight: 500;
  box-shadow: 0 2px 8px rgba(15, 41, 66, 0.05);
  outline: none;
}

.fee-search-input:focus {
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.25);
}

.fee-filters-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.fee-select {
  height: 36px;
  padding: 0 0.8rem;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  background: var(--bg-white);
  color: var(--navy-900);
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  outline: none;
  cursor: pointer;
}

.fee-select:focus {
  border-color: var(--blue-600);
}

.fee-table-wrap {
  width: 100%;
  max-width: 100%;
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  box-shadow: 0 4px 16px rgba(15, 41, 66, 0.05);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.fee-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
}

.fee-table th {
  background: var(--bg-page);
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 700;
  text-align: left;
  padding: 0.8rem 1rem;
  border-bottom: 1px solid var(--border-subtle);
  white-space: nowrap;
}

.fee-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border-subtle);
  font-size: 0.88rem;
  color: var(--navy-900);
  vertical-align: middle;
}

.fee-table tbody tr {
  cursor: pointer;
  transition: background-color 0.16s ease;
}

.fee-table tbody tr:hover {
  background: #F8FAFF;
}

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

.fee-st-name {
  font-weight: 700;
  color: var(--navy-900);
}

.fee-st-meta {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
}

.fee-id-code {
  font-family: var(--font-en);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--blue-600);
}

.fee-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.22rem 0.68rem;
  border-radius: var(--radius-pill);
  font-size: 0.74rem;
  font-weight: 700;
  white-space: nowrap;
}

.fee-pill.is-paid {
  background: #16A34A;
  color: #FFFFFF;
}

.fee-pill.is-unpaid {
  background: #DC2626;
  color: #FFFFFF;
}

.fee-pill.is-inactive {
  background: #E2E8F0;
  color: var(--text-muted);
}

.unpaid-count-pill {
  display: inline-block;
  padding: 0.2rem 0.62rem;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 700;
}

.unpaid-count-pill.is-zero {
  background: var(--success-bg);
  color: var(--success-ink);
}

.unpaid-count-pill.is-due {
  background: var(--danger-bg);
  color: var(--danger-ink);
}

.receipts-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.receipt-row {
  background: var(--bg-page);
  border-radius: var(--radius-md);
  padding: 0.75rem 0.9rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.receipt-month-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--navy-900);
}

.receipt-sub-info {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-muted);
}

.receipt-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-mark-paid {
  background: #16A34A;
  color: #FFFFFF;
  padding: 0.34rem 0.8rem;
  font-size: 0.76rem;
}

.btn-mark-paid:hover {
  background: #15803D;
}

@media (max-width: 900px) {
  .fee-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .fee-search-wrap {
    max-width: none;
    width: 100%;
  }

  .fee-filters-group {
    width: 100%;
  }

  .fee-select {
    flex: 1;
    min-width: 110px;
  }
}