/* Altınbaş Cyprus University — online payment pages (same palette as the student portal login) */
:root { --p: #1565c0; --p-dark: #1a237e; --navy: #0b1a4a; --bg: #f3f5f9; --border: #e5e7eb; --muted: #6c757d; --text: #1a2035; }
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { min-height: 100%; }
body { font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif; background: var(--bg); color: var(--text); display: flex; min-height: 100vh; }

/* Left cover */
.pay-cover { flex: 0 0 42%; position: relative; min-height: 100vh; background: var(--navy) url('images/bgstaff.jpg') center/cover no-repeat; }
.pay-cover::after { content: ''; position: absolute; inset: 0; background: linear-gradient(160deg, rgba(11,26,74,.55), rgba(21,101,192,.45)); }
.pay-cover .brand { position: absolute; left: 40px; bottom: 40px; right: 40px; z-index: 1; color: #fff; }
.pay-cover .brand img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; box-shadow: 0 6px 20px rgba(0,0,0,.3); margin-bottom: 14px; }
.pay-cover .brand h1 { font-size: 26px; font-weight: 800; line-height: 1.2; }
.pay-cover .brand p { opacity: .85; font-size: 14px; margin-top: 6px; }

/* Right panel */
.pay-main { flex: 1; display: flex; align-items: center; justify-content: center; padding: 28px 24px; position: relative; min-height: 100vh; }
.home-btn { position: absolute; top: 18px; right: 22px; display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: 999px; background: #fff; border: 1px solid var(--border); color: var(--navy); font-weight: 700; font-size: 13px; text-decoration: none; box-shadow: 0 4px 14px rgba(11,26,74,.08); z-index: 5; }
.home-btn:hover { color: var(--p); border-color: var(--p); }
.secure-note { margin-top: 14px; text-align: center; font-size: 12.5px; color: var(--muted); }
.secure-note i { color: #167a3f; margin-right: 4px; }
.debt-list { max-height: 34vh; overflow-y: auto; padding-right: 6px; border: 1px solid var(--border); border-radius: 12px; padding: 0 14px; }
.debt-list::-webkit-scrollbar { width: 6px; } .debt-list::-webkit-scrollbar-thumb { background: #cfd6e4; border-radius: 3px; }
.pay-box { width: 100%; max-width: 560px; }
.pay-box.wide { max-width: 860px; }
.pay-head { text-align: center; margin-bottom: 14px; }
.pay-head .logo-sm { display: none; width: 60px; height: 60px; border-radius: 50%; object-fit: cover; margin: 0 auto 10px; box-shadow: 0 6px 18px rgba(0,0,0,.15); }
.pay-head h2 { font-size: 20px; font-weight: 800; color: var(--navy); }
.pay-head p { color: var(--muted); font-size: 14px; margin-top: 4px; }
.pay-card { background: #fff; border: 1px solid var(--border); border-radius: 16px; box-shadow: 0 10px 30px rgba(11,26,74,.08); padding: 20px 22px; }
.pay-card + .pay-card { margin-top: 16px; }

/* Amount block */
.amount-box { text-align: center; padding: 14px 14px 12px; border-radius: 14px; background: linear-gradient(135deg, var(--navy), var(--p)); color: #fff; margin-bottom: 12px; position: relative; overflow: hidden; }
.amount-box::after { content: ''; position: absolute; right: -50px; top: -50px; width: 180px; height: 180px; border-radius: 50%; background: rgba(255,255,255,.08); }
.amount-box .lbl { font-size: 11px; letter-spacing: 1.2px; text-transform: uppercase; opacity: .8; }
.amount-box .amt { font-size: 40px; font-weight: 800; line-height: 1.1; margin: 4px 0; }
.amount-box .amt small { font-size: 20px; font-weight: 700; margin-left: 6px; opacity: .9; }
.amount-box .note { font-size: 12.5px; opacity: .85; }
.portion { display: flex; gap: 10px; justify-content: center; margin-top: 8px; flex-wrap: wrap; position: relative; z-index: 1; }
.portion button { border: 1.5px solid rgba(255,255,255,.55); background: rgba(255,255,255,.12); color: #fff; border-radius: 999px; padding: 8px 18px; font-weight: 700; font-size: 13px; cursor: pointer; transition: all .15s; }
.portion button.active { background: #fff; color: var(--p-dark); border-color: #fff; }

/* Countdown */
.timer { display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 13px; color: var(--muted); margin-bottom: 10px; }
.timer b { font-variant-numeric: tabular-nums; font-size: 16px; color: var(--navy); }
.timer.warn b { color: #b02a37; }

/* Fields */
.field { position: relative; margin-bottom: 10px; }
.field i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: #9ca3af; font-size: 14px; }
.field input { width: 100%; padding: 11px 14px 11px 42px; border: 1.5px solid var(--border); border-radius: 10px; font-size: 15px; background: #f9fafb; outline: none; transition: border-color .2s, box-shadow .2s; letter-spacing: .3px; }
.field input:focus { border-color: var(--p); background: #fff; box-shadow: 0 0 0 3px rgba(21,101,192,.12); }
.field .brand-icon { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); height: 22px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.btn-pay { width: 100%; padding: 12px; border: none; border-radius: 10px; font-size: 15px; font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--p), var(--p-dark)); cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; transition: opacity .2s, transform .1s; margin-top: 6px; }
.btn-pay:hover { opacity: .92; transform: translateY(-1px); }
.btn-outline { display: inline-flex; align-items: center; gap: 6px; padding: 10px 16px; border-radius: 10px; border: 1.5px solid var(--p); color: var(--p); background: #fff; font-weight: 700; font-size: 13px; text-decoration: none; cursor: pointer; }
.btn-outline:hover { background: var(--p); color: #fff; }
.btn-ghost { display: inline-block; margin-top: 16px; color: var(--muted); font-size: 13px; text-decoration: none; }
.btn-ghost:hover { color: var(--p); }

.badges { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 18px; }
.badges div { text-align: center; padding: 10px 6px; border: 1px solid var(--border); border-radius: 10px; background: #fafbfd; font-size: 11px; color: var(--muted); }
.badges div i { display: block; font-size: 18px; color: var(--p); margin-bottom: 4px; }
.badges div b { display: block; color: var(--text); font-size: 12px; }

/* Debts */
.student-chip { display: inline-flex; align-items: center; gap: 8px; background: #e7f0fd; color: var(--p-dark); border-radius: 999px; padding: 6px 14px; font-weight: 700; font-size: 13px; }
.debt-total { display: flex; flex-wrap: wrap; gap: 10px; margin: 12px 0 12px; }
.debt-total .box { flex: 1 1 160px; border-radius: 12px; padding: 14px 16px; color: #fff; background: linear-gradient(135deg, #b02a37, #e0475c); }
.debt-total .box.zero { background: linear-gradient(135deg, #147a44, #1e9e5a); }
.debt-total .box small { display: block; font-size: 11px; letter-spacing: 1px; text-transform: uppercase; opacity: .85; }
.debt-total .box b { font-size: 22px; font-weight: 800; }
.debt-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 0; border-bottom: 1px dashed var(--border); flex-wrap: wrap; }
.debt-row:last-child { border-bottom: none; }
.debt-row .amt { font-size: 20px; font-weight: 800; color: #b02a37; }
.debt-row .meta { font-size: 12.5px; color: var(--muted); }
.debt-row .actions { display: flex; gap: 8px; }
.tag { display: inline-block; font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 8px; background: #fdeaed; color: #b02a37; }
.custom-amount { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border); }
.custom-amount h6 { font-size: 13px; font-weight: 800; color: var(--navy); margin-bottom: 10px; text-transform: uppercase; letter-spacing: .6px; }
.custom-amount .row-i { display: grid; grid-template-columns: 1fr 140px auto; gap: 10px; }
.custom-amount input, .custom-amount select { padding: 11px 12px; border: 1.5px solid var(--border); border-radius: 10px; background: #f9fafb; font-size: 14px; outline: none; }
.custom-amount input:focus, .custom-amount select:focus { border-color: var(--p); background: #fff; }

/* Result */
.result { text-align: center; padding: 10px 0; }
.result .ico { width: 84px; height: 84px; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; font-size: 40px; }
.result.ok .ico { background: #e6f6ec; color: #167a3f; }
.result.ko .ico { background: #fdeaed; color: #b02a37; }
.result h2 { font-size: 24px; font-weight: 800; color: var(--navy); }
.result p { color: var(--muted); margin-top: 8px; line-height: 1.6; }

/* Modal (bank accounts) */
.modal-content { border-radius: 16px; border: none; }
.modal-header { border-bottom: 1px solid var(--border); }
.modal-body .table th { font-size: 11px; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); }
.modal-body .table td { font-size: 13px; }

.pay-footer { text-align: center; color: #b0b7c3; font-size: 12px; margin-top: 14px; }

@media (max-width: 991px) {
  body { flex-direction: column; }
  .pay-cover { flex: 0 0 150px; min-height: 150px; }
  .pay-cover .brand { left: 20px; bottom: 16px; }
  .pay-cover .brand img { display: none; }
  .pay-cover .brand h1 { font-size: 20px; }
  .pay-main { padding: 60px 14px 24px; align-items: flex-start; min-height: auto; }
  .home-btn { top: 12px; right: 12px; }
  .debt-list { max-height: none; }
  .pay-card { padding: 18px; }
  .amount-box .amt { font-size: 36px; }
  .custom-amount .row-i { grid-template-columns: 1fr; }
  .debt-row .actions { width: 100%; }
  .debt-row .actions a { flex: 1; justify-content: center; }
}
@media (max-width: 991px) { .pay-head .logo-sm { display: block; } }
