/* ============================================================
   KTK Application Portal — Design System
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@500;700;800&display=swap');

:root {
  --primary: #0B1E3D;
  --primary-light: #1a365d;
  --primary-mid: #122848;
  --accent: #D4AF37;
  --accent-light: #f0d060;
  --accent-glow: rgba(212,175,55,0.18);
  --green: #10b981;
  --green-light: #d1fae5;
  --red: #ef4444;
  --red-light: #fee2e2;
  --orange: #f59e0b;
  --orange-light: #fef3c7;
  --blue: #3b82f6;
  --blue-light: #dbeafe;
  --bg: #f0f4f8;
  --white: #ffffff;
  --border: #e2e8f0;
  --text: #1e293b;
  --text-light: #64748b;
  --text-muted: #94a3b8;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 10px 40px -10px rgba(11,30,61,0.15);
  --shadow-sm: 0 4px 16px -4px rgba(11,30,61,0.10);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
}

/* ── Portal Header ── */
.portal-header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  padding: 0 40px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.portal-header-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.portal-logo {
  font-family: 'Outfit', sans-serif;
  font-size: 2rem;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -1px;
  text-decoration: none;
}

.portal-logo span {
  color: white;
  font-size: 0.9rem;
  font-weight: 400;
  padding-left: 14px;
  margin-left: 14px;
  border-left: 1px solid rgba(255,255,255,0.25);
}

.portal-header-links { display: flex; gap: 8px; }

.portal-header-links a {
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: 8px;
  transition: var(--transition);
}

.portal-header-links a:hover { background: rgba(255,255,255,0.1); color: white; }

/* ── Portal Wrapper ── */
.portal-wrapper {
  min-height: calc(100vh - 72px - 64px);
  padding: 50px 20px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}

.portal-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: 100%;
  max-width: 860px;
  overflow: hidden;
  border: 1px solid var(--border);
}

/* ── Progress Steps ── */
.progress-bar-container {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  padding: 30px 40px;
}

.progress-title {
  font-family: 'Outfit', sans-serif;
  color: white;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.progress-subtitle {
  color: rgba(255,255,255,0.65);
  font-size: 0.9rem;
  margin-bottom: 28px;
}

.steps-row {
  display: flex;
  align-items: center;
  gap: 0;
}

.step-item {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
}

.step-item:last-child { flex: none; }

.step-circle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
  transition: var(--transition);
  background: rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.55);
  border: 2px solid rgba(255,255,255,0.2);
}

.step-circle.active {
  background: var(--accent);
  color: var(--primary);
  border-color: var(--accent);
  box-shadow: 0 0 20px rgba(212,175,55,0.5);
}

.step-circle.done {
  background: var(--green);
  color: white;
  border-color: var(--green);
}

.step-label {
  color: rgba(255,255,255,0.6);
  font-size: 0.8rem;
  font-weight: 500;
  white-space: nowrap;
  transition: var(--transition);
}

.step-label.active { color: var(--accent); font-weight: 600; }
.step-label.done { color: rgba(255,255,255,0.85); }

.step-line {
  flex: 1;
  height: 2px;
  background: rgba(255,255,255,0.15);
  margin: 0 8px;
  border-radius: 2px;
}

.step-line.done { background: var(--green); }

/* ── Form Body ── */
.form-body {
  padding: 40px;
}

.form-section { display: none; }
.form-section.active { display: block; }

.section-heading {
  font-family: 'Outfit', sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-heading svg, .section-heading .icon {
  width: 28px;
  height: 28px;
  background: var(--accent-glow);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.section-sub {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 30px;
  padding-left: 38px;
}

/* ── Form Grid ── */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form-grid.one-col { grid-template-columns: 1fr; }
.form-grid.three-col { grid-template-columns: 1fr 1fr 1fr; }

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group.full { grid-column: 1 / -1; }

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: 0.2px;
}

.form-group label .req {
  color: var(--red);
  margin-left: 2px;
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-family: 'Inter', sans-serif;
  color: var(--text);
  background: var(--white);
  transition: var(--transition);
  outline: none;
}

.form-control:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-glow);
}

.form-control.error {
  border-color: var(--red);
  box-shadow: 0 0 0 4px rgba(239,68,68,0.1);
}

.form-control::placeholder { color: var(--text-muted); }

select.form-control { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2364748b' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 40px; }

.field-error {
  color: var(--red);
  font-size: 0.8rem;
  font-weight: 500;
  margin-top: 2px;
  display: none;
}

.field-error.show { display: block; }

/* ── Education Level Card ── */
.edu-list { display: flex; flex-direction: column; gap: 16px; }

.edu-card {
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 20px;
  position: relative;
  background: #fafbfc;
  transition: var(--transition);
}

.edu-card:hover { border-color: var(--accent); background: #fffef7; }

.edu-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.edu-card-title {
  font-weight: 600;
  color: var(--primary);
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 8px;
}

.edu-card-num {
  width: 24px;
  height: 24px;
  background: var(--primary);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
}

.remove-edu-btn {
  background: var(--red-light);
  color: var(--red);
  border: none;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.remove-edu-btn:hover { background: var(--red); color: white; }

.add-edu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px;
  border: 2px dashed var(--border);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-light);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: 'Inter', sans-serif;
  margin-top: 4px;
}

.add-edu-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}

/* ── Percentage Badge ── */
.pct-badge {
  display: inline-block;
  padding: 4px 10px;
  background: var(--blue-light);
  color: var(--blue);
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 700;
  margin-top: 8px;
  transition: var(--transition);
}

/* ── Review Summary ── */
.review-section {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-bottom: 20px;
}

.review-section-header {
  background: #f8fafc;
  padding: 12px 20px;
  font-weight: 600;
  color: var(--primary);
  font-size: 0.9rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
}

.review-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}

.review-item {
  padding: 12px 20px;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
}

.review-item:nth-child(even) { border-right: none; }
.review-item:nth-last-child(-n+2) { border-bottom: none; }

.review-label { font-size: 0.78rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 3px; }
.review-value { font-size: 0.92rem; color: var(--text); font-weight: 500; }

.terms-check {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  background: var(--accent-glow);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(212,175,55,0.3);
  cursor: pointer;
  margin-top: 20px;
}

.terms-check input[type="checkbox"] {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  accent-color: var(--accent);
  cursor: pointer;
  margin-top: 2px;
}

.terms-check label {
  font-size: 0.88rem;
  color: var(--text);
  cursor: pointer;
  line-height: 1.5;
}

.terms-check label a { color: var(--accent); font-weight: 600; }

/* ── Form Navigation Buttons ── */
.form-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.btn-prev, .btn-next, .btn-submit {
  padding: 13px 30px;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 8px;
  border: none;
  font-family: 'Inter', sans-serif;
}

.btn-prev {
  background: #f1f5f9;
  color: var(--text-light);
}
.btn-prev:hover { background: var(--border); color: var(--text); }

.btn-next {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(11,30,61,0.25);
}
.btn-next:hover { transform: translateY(-2px); box-shadow: 0 8px 25px rgba(11,30,61,0.3); }

.btn-submit {
  background: linear-gradient(135deg, var(--accent) 0%, #b8960a 100%);
  color: var(--primary);
  box-shadow: 0 4px 15px rgba(212,175,55,0.4);
}
.btn-submit:hover { transform: translateY(-2px); box-shadow: 0 8px 25px rgba(212,175,55,0.5); }
.btn-submit:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.step-counter {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ── Payment Page ── */
.payment-wrapper {
  max-width: 900px;
}

.success-banner {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  border-radius: var(--radius);
  padding: 32px 40px;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  gap: 24px;
  box-shadow: var(--shadow);
}

.success-icon-wrap {
  width: 64px;
  height: 64px;
  background: var(--green);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1.8rem;
  box-shadow: 0 0 30px rgba(16,185,129,0.4);
  animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
  0%, 100% { box-shadow: 0 0 30px rgba(16,185,129,0.4); }
  50% { box-shadow: 0 0 50px rgba(16,185,129,0.7); }
}

.success-text h2 {
  font-family: 'Outfit', sans-serif;
  color: white;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.success-text p { color: rgba(255,255,255,0.75); font-size: 0.9rem; line-height: 1.5; }

.app-id-badge {
  margin-top: 10px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent-glow);
  border: 1px solid rgba(212,175,55,0.5);
  border-radius: 8px;
  padding: 8px 16px;
}

.app-id-badge .label { color: rgba(255,255,255,0.6); font-size: 0.8rem; }
.app-id-badge .value { color: var(--accent); font-weight: 700; font-size: 1rem; letter-spacing: 1px; }

/* ── Payment Info Cards ── */
.payment-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 28px;
}

.info-card {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.info-card-header {
  padding: 16px 24px;
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}

.info-card-header .card-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.card-icon.gold { background: var(--accent-glow); }
.card-icon.blue { background: var(--blue-light); }
.card-icon.green { background: var(--green-light); }

.info-card-header h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--primary);
}

.info-card-body { padding: 20px 24px; }

/* ── Bank Details ── */
.bank-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.bank-row:last-child { border-bottom: none; }

.bank-row .bk-label { font-size: 0.82rem; color: var(--text-muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.3px; }
.bank-row .bk-value { font-size: 0.95rem; color: var(--text); font-weight: 600; }
.bank-row .bk-value.accent { color: var(--primary); font-size: 1.1rem; letter-spacing: 1px; }

.copy-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 0.75rem;
  color: var(--text-light);
  cursor: pointer;
  transition: var(--transition);
}

.copy-btn:hover { background: var(--primary); color: white; border-color: var(--primary); }

/* ── Payment Instructions ── */
.instruction-list { list-style: none; padding: 0; }

.instruction-list li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--text);
  line-height: 1.5;
}

.instruction-list li:last-child { border-bottom: none; }

.step-num {
  width: 26px;
  height: 26px;
  background: var(--primary);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
}

/* ── Video Section ── */
.video-section {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  margin-bottom: 28px;
}

.video-embed {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
}

.video-embed iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: none;
}

/* ── Upload Section ── */
.upload-section {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  padding: 32px;
  margin-bottom: 28px;
}

.upload-zone {
  border: 3px dashed var(--border);
  border-radius: var(--radius-sm);
  padding: 48px 24px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  background: #fafbfc;
  position: relative;
}

.upload-zone.drag-over {
  border-color: var(--accent);
  background: var(--accent-glow);
}

.upload-zone.has-file {
  border-color: var(--green);
  background: var(--green-light);
}

.upload-zone input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}

.upload-icon { font-size: 3rem; margin-bottom: 12px; }

.upload-zone h4 { font-size: 1rem; font-weight: 700; color: var(--text); margin-bottom: 6px; }
.upload-zone p { font-size: 0.85rem; color: var(--text-muted); }

.file-preview {
  display: none;
  margin-top: 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.file-preview.show { display: block; }

.file-preview img {
  width: 100%;
  max-height: 300px;
  object-fit: contain;
  background: #f8fafc;
}

.file-preview-info {
  padding: 12px 16px;
  background: #f8fafc;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.file-preview-name { font-size: 0.9rem; font-weight: 600; color: var(--text); }
.file-preview-size { font-size: 0.8rem; color: var(--text-muted); }

.upload-error {
  display: none;
  margin-top: 12px;
  padding: 12px 16px;
  background: var(--red-light);
  border-radius: var(--radius-sm);
  color: var(--red);
  font-size: 0.9rem;
  font-weight: 500;
}

.upload-error.show { display: block; }

.btn-upload {
  margin-top: 20px;
  width: 100%;
  padding: 15px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  font-family: 'Inter', sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.btn-upload:hover { transform: translateY(-2px); box-shadow: 0 8px 25px rgba(11,30,61,0.3); }
.btn-upload:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.upload-success {
  display: none;
  text-align: center;
  padding: 30px;
  background: var(--green-light);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(16,185,129,0.3);
}

.upload-success.show { display: block; }
.upload-success .check { font-size: 3rem; margin-bottom: 12px; }
.upload-success h3 { color: var(--green); font-family: 'Outfit', sans-serif; font-size: 1.2rem; font-weight: 700; margin-bottom: 6px; }
.upload-success p { color: var(--text-light); font-size: 0.9rem; }

/* ── Lookup / Result Page ── */
.lookup-card {
  max-width: 600px;
  text-align: center;
  padding: 60px 40px;
}

.lookup-icon { font-size: 4rem; margin-bottom: 20px; }

.lookup-card h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.8rem;
  color: var(--primary);
  font-weight: 800;
  margin-bottom: 8px;
}

.lookup-card p { color: var(--text-light); margin-bottom: 32px; font-size: 0.95rem; }

.lookup-input-group {
  display: flex;
  gap: 12px;
}

.lookup-input-group .form-control { flex: 1; }

.btn-lookup {
  padding: 12px 24px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  font-family: 'Inter', sans-serif;
  white-space: nowrap;
}

.btn-lookup:hover { transform: translateY(-2px); box-shadow: 0 8px 25px rgba(11,30,61,0.3); }

/* ── Result Card ── */
.result-card {
  display: none;
  text-align: left;
  margin-top: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.result-card.show { display: block; }

.result-card-header {
  padding: 20px 28px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.result-student-name { font-family: 'Outfit', sans-serif; color: white; font-size: 1.2rem; font-weight: 700; }
.result-roll { color: var(--accent); font-size: 0.9rem; font-weight: 600; }

.pass-badge, .fail-badge {
  padding: 6px 16px;
  border-radius: 20px;
  font-weight: 700;
  font-size: 0.85rem;
}

.pass-badge { background: var(--green); color: white; }
.fail-badge { background: var(--red); color: white; }

.result-body { padding: 28px; }

.marks-display {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  margin: 20px 0;
  flex-wrap: wrap;
}

.mark-item { text-align: center; }
.mark-value { font-family: 'Outfit', sans-serif; font-size: 2.5rem; font-weight: 800; color: var(--primary); line-height: 1; }
.mark-label { font-size: 0.8rem; color: var(--text-muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; margin-top: 4px; }

.pct-circle {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: conic-gradient(var(--green) calc(var(--pct) * 1%), var(--border) 0%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Outfit', sans-serif;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--primary);
  position: relative;
}

.pct-circle::before {
  content: '';
  position: absolute;
  width: 80px;
  height: 80px;
  background: white;
  border-radius: 50%;
}

.pct-circle span { position: relative; z-index: 1; }

/* ── Roll Slip ── */
.rollslip-card {
  background: white;
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  overflow: hidden;
  max-width: 600px;
  margin: 0 auto;
  box-shadow: var(--shadow);
}

.rollslip-header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  padding: 24px 30px;
  text-align: center;
}

.rollslip-logo { font-family: 'Outfit', sans-serif; font-size: 2.5rem; font-weight: 800; color: var(--accent); }
.rollslip-org { color: rgba(255,255,255,0.8); font-size: 0.85rem; margin-top: 4px; }
.rollslip-title { color: white; font-size: 1rem; font-weight: 600; margin-top: 8px; text-transform: uppercase; letter-spacing: 2px; }

.rollslip-body { padding: 28px 30px; }

.rollslip-row {
  display: flex;
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
}

.rollslip-row:last-child { border-bottom: none; }
.rollslip-key { font-weight: 600; color: var(--text-muted); font-size: 0.85rem; width: 140px; flex-shrink: 0; }
.rollslip-val { font-weight: 600; color: var(--text); font-size: 0.95rem; }

.rollslip-rn-box {
  text-align: center;
  margin: 20px 0;
  padding: 16px;
  background: var(--primary);
  border-radius: var(--radius-sm);
}

.rollslip-rn-label { color: rgba(255,255,255,0.7); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 1px; }
.rollslip-rn { color: var(--accent); font-family: 'Outfit', sans-serif; font-size: 2rem; font-weight: 800; letter-spacing: 3px; margin-top: 4px; }

.btn-print {
  display: block;
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, var(--accent) 0%, #b8960a 100%);
  color: var(--primary);
  border: none;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 20px;
  font-family: 'Inter', sans-serif;
  transition: var(--transition);
}

.btn-print:hover { transform: translateY(-2px); box-shadow: 0 8px 25px rgba(212,175,55,0.5); }

/* ── Portal Closed ── */
.portal-closed {
  text-align: center;
  padding: 60px 40px;
}

.portal-closed .closed-icon { font-size: 5rem; margin-bottom: 20px; }
.portal-closed h2 { font-family: 'Outfit', sans-serif; font-size: 2rem; font-weight: 800; color: var(--primary); margin-bottom: 10px; }
.portal-closed p { color: var(--text-light); max-width: 480px; margin: 0 auto 30px; }

/* ── Fee Badge ── */
.fee-highlight {
  background: linear-gradient(135deg, var(--accent) 0%, #b8960a 100%);
  color: var(--primary);
  font-family: 'Outfit', sans-serif;
  font-size: 1.8rem;
  font-weight: 800;
  padding: 14px 30px;
  border-radius: var(--radius-sm);
  display: inline-block;
  box-shadow: 0 4px 20px rgba(212,175,55,0.4);
  margin-bottom: 6px;
}

.fee-note {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.fee-note .asterisk { color: var(--red); font-weight: 700; }

/* ── Alerts ── */
.alert {
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
}

.alert-info { background: var(--blue-light); color: #1d4ed8; border: 1px solid rgba(59,130,246,0.2); }
.alert-success { background: var(--green-light); color: #065f46; border: 1px solid rgba(16,185,129,0.2); }
.alert-warning { background: var(--orange-light); color: #92400e; border: 1px solid rgba(245,158,11,0.2); }
.alert-error { background: var(--red-light); color: #991b1b; border: 1px solid rgba(239,68,68,0.2); }

/* ── Portal Footer ── */
.portal-footer {
  background: var(--primary);
  color: rgba(255,255,255,0.5);
  text-align: center;
  padding: 18px;
  font-size: 0.82rem;
}

/* ── Spinner ── */
.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: inline-block;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ── Responsive ── */
@media (max-width: 768px) {
  .portal-header { padding: 0 15px; position: static; }
  .portal-header-inner { flex-direction: column; height: auto; padding: 15px 0; gap: 10px; }
  .portal-header-links { flex-wrap: wrap; justify-content: center; }
  .portal-header-links a { font-size: 0.8rem; padding: 6px 10px; }
  .portal-wrapper { padding: 20px 10px; }
  .form-body { padding: 24px 15px; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid.three-col { grid-template-columns: 1fr; }
  .progress-bar-container { padding: 20px 15px; }
  .steps-row { gap: 0; }
  .step-label { display: none; }
  .payment-grid { grid-template-columns: 1fr; }
  .review-grid { grid-template-columns: 1fr; }
  .lookup-input-group { flex-direction: column; }
  .marks-display { gap: 20px; }
  .success-banner { flex-direction: column; text-align: center; }
  .progress-title { font-size: 1.2rem; }
  .form-nav { flex-direction: column-reverse; gap: 15px; align-items: stretch; }
  .form-nav button { width: 100%; justify-content: center; }
  .step-counter { text-align: center; margin-bottom: 5px; }
}

@media print {
  .portal-header, .portal-footer, .btn-print, .lookup-card { display: none; }
  .portal-wrapper { padding: 0; }
  .rollslip-card { box-shadow: none; border: 2px solid #000; }
}

/* -- Premium Bank Card -- */
.premium-bank-card {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    border-radius: 16px;
    padding: 24px;
    color: white;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    border: 1px solid rgba(255,255,255,0.1);
    transition: transform 0.3s ease;
}
.premium-bank-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.3);
}
.premium-bank-card::before {
    content: '';
    position: absolute;
    top: -50%; right: -20%;
    width: 300px; height: 300px;
    background: radial-gradient(circle, rgba(212,175,55,0.15) 0%, transparent 70%);
    border-radius: 50%;
}
.card-chip {
    width: 45px; height: 32px;
    background: linear-gradient(135deg, #d4af37 0%, #fcd34d 100%);
    border-radius: 6px;
    margin-bottom: 20px;
    opacity: 0.9;
    position: relative;
    overflow: hidden;
}
.card-chip::after {
    content: '';
    position: absolute;
    top: 50%; left: 0; right: 0;
    height: 1px; background: rgba(0,0,0,0.2);
}
.card-bank-name {
    position: absolute;
    top: 24px; right: 24px;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 1.1rem;
    color: rgba(255,255,255,0.8);
    letter-spacing: 1px;
}
.card-field {
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}
.card-field label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: rgba(255,255,255,0.5);
    margin-bottom: 6px;
}
.card-value-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}
.card-value {
    font-family: monospace;
    font-size: 1.3rem;
    letter-spacing: 2px;
    color: white;
    font-weight: 600;
}
.card-value.iban-text {
    font-size: 1rem;
    letter-spacing: 1px;
    color: #e2e8f0;
}
.card-value.title-text {
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    letter-spacing: 0;
    text-transform: uppercase;
    color: rgba(255,255,255,0.8);
}
.card-copy-btn {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 6px;
    color: white;
    width: 32px; height: 32px;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}
.card-copy-btn:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--primary);
    transform: scale(1.05);
}
.card-copy-btn:active {
    transform: scale(0.95);
}
.card-footer-flex {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-top: 25px;
    margin-bottom: 0;
    position: relative;
    z-index: 1;
}
.card-footer-flex .card-field { margin-bottom: 0; }
.card-logo-mark {
    font-family: 'Outfit', sans-serif;
    font-weight: 800;
    font-size: 1.5rem;
    color: rgba(212,175,55,0.8);
    font-style: italic;
}

/* Mobile Adjustments for Bank Card */
@media (max-width: 480px) {
    .premium-bank-card {
        padding: 20px 15px;
    }
    .card-value {
        font-size: 1.1rem;
        letter-spacing: 1px;
        word-break: break-all;
    }
    .card-value.iban-text {
        font-size: 0.85rem;
    }
    .card-bank-name {
        font-size: 0.95rem;
        top: 20px; right: 15px;
    }
    .card-footer-flex {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    .card-logo-mark {
        align-self: flex-end;
    }
}
