/* ==========================================================
   components.css
   Reusable pieces: scholarship cards, pagination, modal and toast.
   ========================================================== */

/* ---------- Scholarship cards ---------- */
.scholarship-card {
  background: linear-gradient(145deg, #EAF6FB, #E5F5F2);
  border: 1px solid #20BFA5;
  padding: 22px;
  border-radius: 5px;
  min-height: 255px;
  display: flex;
  flex-direction: column;
  transition:
    transform 0.25s,
    border 0.25s;
}
.scholarship-card:hover {
  transform: translateY(-5px);
border-color: #20BFA5;
}
.card-topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 22px;
}
.tag {
  font-size: 8px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--bright);
border: 1px solid #20BFA5;
  padding: 5px 8px;
  border-radius: 2px;
}
.save-btn {
  border: 0;
  background: transparent;
  color: #526579;
  font-size: 20px;
  cursor: pointer;
}
.save-btn.saved {
  color: #20BFA5;
}
.scholarship-card h4 {
  font: 700 19px var(--display);
  line-height: 1.4;
  margin: 0 0 6px;
  /* two lines for every title, so cards in a row line up */
  min-height: 2.8em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.provider {
  font-size: 10px;
  color: #526579;
  margin-bottom: 14px;
}
.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: auto;
}
.card-meta span {
  font-size: 9px;
  color: #526579;
background: #EAF6FB;
  padding: 5px 8px;
  border-radius: 2px;
}
.card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 19px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 9px;
  color: #526579;
}
.card-footer button {
  background: none;
  border: 0;
  color: var(--gold2);
  cursor: pointer;
  font-size: 10px;
}
.empty-state {
  grid-column: 1/-1;
  text-align: center;
  padding: 45px;
  color: #526579;
  border: 1px dashed var(--line);
}
/* ---------- Modal dialog ---------- */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 30;
  background: #050816d9;
  display: grid;
  place-items: center;
  padding: 20px;
  backdrop-filter: blur(8px);
}
.modal-backdrop[hidden] {
  display: none;
}
.modal {
  width: min(520px, 100%);
  max-height: 90vh;
  overflow: auto;
 background: #E5F5F2;
border: 1px solid #20BFA5;
  border-radius: 7px;
  padding: 30px;
  position: relative;
  box-shadow: 0 30px 100px #0009;
}
.modal-close {
  position: absolute;
  right: 16px;
  top: 12px;
  border: 0;
  background: none;
  color: #075985;
  font-size: 25px;
  cursor: pointer;
}
.modal h2 {
  font: 700 30px var(--display);
  color: #075985;
  margin: 0 30px 14px 0;
}
.modal p {
  color: #526579;
  font-size: 16px;
  line-height: 1.8;
}
.modal label {
  display: block;
  color: #075985;
  font-size: 15px;
  font-weight: 700;
  margin: 18px 0 7px;
}
.modal input,
.modal select,
.modal textarea {
  width: 100%;
  padding: 12px;
  background: #EAF6FB;
border: 1px solid #20BFA5;
color: #075985;
  border-radius: 3px;
  font-size: 16px;
}
.modal .button {
  margin-top: 22px;
  font-size: 16px;
  font-weight: 700;
  padding: 14px 22px;
}
.modal .modal-note {
  font-size: 14px;
  font-weight: 500;
  color: #526579;
  line-height: 1.7;
  margin-top: 18px;
}
.admin-list {
  font-size: 11px;
  color: #526579;
  line-height: 2;
}
/* ---------- Toast message ---------- */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translate(-50%, 20px);
 background: #20BFA5;
color: #075985;
  padding: 12px 20px;
  border-radius: 4px;
  font-size: 11px;
  opacity: 0;
  pointer-events: none;
  transition: 0.25s;
  z-index: 50;
}
.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}
.detail-list {
  font-size: 11px;
  color: #526579;
  line-height: 2;
}
.detail-list b {
  color: #075985;
}
.detail-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
/* ---------- Card status label ---------- */
.status-tag {
  font-size: 8px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
}
.status-tag.is-verified {
  color: var(--gold2);
}

/* Pagination under the results grid (built by js/render.js) */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
  margin: 32px 0;
  padding: 12px 0;
}
.pagination-info {
  width: 100%;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 8px;
}
.page-btn {
  min-width: 38px;
  padding: 10px 13px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: transparent;
  color: inherit;
  font-weight: 600;
  cursor: pointer;
}
.page-btn.is-active {
  background: #20BFA5;
  color: #075985;
}
.page-btn:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

/* Student Space: profile details */
.student-profile-details {
  display: grid;
  gap: 18px;
  margin: 24px 0;
}

.student-detail {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 16px 18px;
  background: #EAF6FB;
  border: 1px solid #cce8f0;
  border-radius: 12px;
}

.student-detail-label {
  color: #526579;
  font-size: 15px;
  font-weight: 600;
}

.student-detail strong {
  color: #075985;
  font-size: 19px;
  font-weight: 700;
  overflow-wrap: anywhere;
}
