/**
 * Al Umer Computer Lab - Main Stylesheet
 * Premium, responsive design with dark/light theme support
 */

/* ===== CSS Variables ===== */
:root {
  --primary: #1e40af;
  --primary-dark: #1e3a8a;
  --primary-light: #3b82f6;
  --accent: #f59e0b;
  --accent-hover: #d97706;
  --whatsapp: #25d366;
  --whatsapp-dark: #128c7e;
  --success: #10b981;
  --danger: #ef4444;

  --bg-body: #f8fafc;
  --bg-section: #f1f5f9;
  --bg-card: #ffffff;
  --bg-nav: rgba(255, 255, 255, 0.95);
  --text-primary: #0f172a;
  --text-secondary: #64748b;
  --text-muted: #94a3b8;
  --border: #e2e8f0;
  --shadow: 0 4px 24px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 50px rgba(15, 23, 42, 0.12);
  --gradient: linear-gradient(135deg, #1e40af 0%, #3b82f6 50%, #6366f1 100%);
  --hero-overlay: linear-gradient(135deg, rgba(15, 23, 42, 0.85) 0%, rgba(30, 64, 175, 0.75) 100%);
  --radius: 12px;
  --radius-lg: 20px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font-heading: 'Plus Jakarta Sans', sans-serif;
  --font-body: 'Inter', sans-serif;
}

[data-theme="dark"] {
  --bg-body: #0f172a;
  --bg-section: #1e293b;
  --bg-card: #1e293b;
  --bg-nav: rgba(15, 23, 42, 0.95);
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --border: #334155;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.4);
  --hero-overlay: linear-gradient(135deg, rgba(15, 23, 42, 0.92) 0%, rgba(30, 64, 175, 0.85) 100%);
}

/* ===== Base Styles ===== */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  overflow-x: hidden;
  max-width: 100%;
}

body {
  font-family: var(--font-body);
  background: var(--bg-body);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  max-width: 100%;
  width: 100%;
  margin: 0;
  transition: background 0.3s, color 0.3s;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
}

img { max-width: 100%; height: auto; }

a { text-decoration: none; transition: var(--transition); }

/* ===== Page Loader ===== */
html.page-loading,
body.page-loading {
  overflow: hidden;
  width: 100%;
  max-width: 100%;
}

.page-loader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  min-width: 100%;
  height: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0;
  padding: 0;
  background: var(--gradient);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: opacity 0.5s, visibility 0.5s;
}

.page-loader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
  width: 100%;
  max-width: 100%;
  padding: 0 1.25rem;
  margin: 0;
}

.loader-logo {
  font-family: var(--font-heading);
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
  width: 100%;
  margin: 0 0 1rem;
  text-align: center;
  animation: pulse 1.5s infinite;
}

.loader-content p {
  margin: 0;
  width: 100%;
  text-align: center;
}

.loader-spinner {
  width: 48px;
  height: 48px;
  border: 4px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  margin: 0 auto 1rem;
  animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.6; } }

/* ===== Navbar ===== */
.navbar {
  background: var(--bg-nav);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0.75rem 0;
  transition: var(--transition);
  box-shadow: 0 2px 20px rgba(0,0,0,0.05);
}

.navbar.scrolled {
  padding: 0.5rem 0;
  box-shadow: var(--shadow);
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-size: 1.25rem;
  color: var(--text-primary) !important;
  font-weight: 600;
}

.brand-icon {
  width: 40px;
  height: 40px;
  background: var(--gradient);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.2rem;
}

.nav-link {
  color: var(--text-secondary) !important;
  font-weight: 500;
  padding: 0.5rem 1rem !important;
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: var(--transition);
  transform: translateX(-50%);
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary) !important;
}

.nav-link:hover::after,
.nav-link.active::after { width: 60%; }

.navbar-toggler {
  border-color: var(--border);
}

[data-theme="dark"] .navbar-toggler-icon {
  filter: invert(1);
}

.btn-theme {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.btn-theme:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.btn-whatsapp-nav {
  background: var(--whatsapp) !important;
  color: #fff !important;
  border-radius: 10px;
  padding: 0.5rem 1rem !important;
  font-weight: 600;
  border: none;
}

.btn-nav-student {
  background: #059669 !important;
  color: #fff !important;
  border-radius: 10px;
  padding: 0.45rem 1rem !important;
  font-weight: 600;
  margin-left: 0.5rem;
}

.btn-nav-student:hover {
  background: #047857 !important;
  color: #fff !important;
}

.btn-whatsapp-nav:hover {
  background: var(--whatsapp-dark) !important;
  transform: translateY(-2px);
}

/* ===== Buttons ===== */
.btn-primary-custom {
  background: var(--gradient);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  transition: var(--transition);
  box-shadow: 0 4px 15px rgba(30, 64, 175, 0.35);
}

.btn-primary-custom:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(30, 64, 175, 0.45);
  color: #fff;
}

.btn-whatsapp-custom {
  background: var(--whatsapp);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  transition: var(--transition);
}

.btn-whatsapp-custom:hover {
  background: var(--whatsapp-dark);
  color: #fff;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(37, 211, 102, 0.4);
}

.btn-outline-custom {
  border: 2px solid var(--primary);
  color: var(--primary);
  border-radius: var(--radius);
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  background: transparent;
  transition: var(--transition);
}

.btn-outline-custom:hover {
  background: var(--primary);
  color: #fff;
}

/* ===== Hero Section ===== */
.hero-section {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  width: 100%;
  max-width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  isolation: isolate;
}

.hero-section .carousel,
.hero-section .carousel-inner {
  position: absolute;
  inset: 0;
  width: 100%;
  max-width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
}

.hero-section .carousel-item {
  position: absolute;
  inset: 0;
  width: 100%;
  max-width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  transition: transform 8s ease;
}

.hero-section .carousel-item.active {
  animation: kenburns 8s ease forwards;
}

@keyframes kenburns {
  from { transform: scale(1); }
  to { transform: scale(1.08); }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: var(--hero-overlay);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 120px 0 80px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.hero-content .container {
  max-width: 100%;
}

.hero-badge {
  display: inline-block;
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.25);
  color: #fff;
  padding: 0.5rem 1.25rem;
  border-radius: 50px;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4rem);
  color: #fff;
  font-weight: 800;
  margin-bottom: 1rem;
  text-shadow: 0 4px 30px rgba(0,0,0,0.3);
  letter-spacing: -0.02em;
}

.hero-tagline {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: rgba(255,255,255,0.9);
  max-width: 700px;
  margin: 0 auto 2rem;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

.hero-scroll {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  color: #fff;
  font-size: 1.5rem;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(10px); }
}

.hero-section .carousel-control-prev,
.hero-section .carousel-control-next {
  z-index: 2;
  width: 50px;
  height: 50px;
  background: rgba(255,255,255,0.2);
  border-radius: 50%;
  top: 50%;
  transform: translateY(-50%);
  margin: 0 20px;
  backdrop-filter: blur(4px);
}

.hero-section .carousel-indicators {
  z-index: 2;
  margin-bottom: 2rem;
}

/* ===== Stats Bar ===== */
.stats-bar {
  background: var(--bg-card);
  padding: 2.5rem 0;
  margin-top: -40px;
  position: relative;
  z-index: 10;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  margin-left: 1rem;
  margin-right: 1rem;
  border: 1px solid var(--border);
}

.stat-num {
  display: block;
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 800;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-label {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* ===== Section Common ===== */
.section-padding { padding: 5rem 0; }

.bg-section { background: var(--bg-section); }

.section-header { margin-bottom: 3rem; }

.section-tag {
  display: inline-block;
  background: rgba(30, 64, 175, 0.1);
  color: var(--primary);
  padding: 0.35rem 1rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

[data-theme="dark"] .section-tag {
  background: rgba(59, 130, 246, 0.2);
  color: var(--primary-light);
}

.section-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  margin-bottom: 0.75rem;
}

.section-subtitle {
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
}

/* ===== Course Cards ===== */
.course-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  transition: var(--transition);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.course-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary-light);
}

.course-card-img {
  position: relative;
  height: 200px;
  overflow: hidden;
}

.course-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.course-card:hover .course-card-img img {
  transform: scale(1.1);
}

.course-card-duration {
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--accent);
  color: #fff;
  padding: 0.25rem 0.75rem;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
}

.course-card-body {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.course-card-body h5 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.course-card-body p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  flex: 1;
  margin-bottom: 1rem;
}

.btn-view-details {
  width: 100%;
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
  border-radius: var(--radius);
  padding: 0.6rem;
  font-weight: 600;
  transition: var(--transition);
  cursor: pointer;
}

.btn-view-details:hover {
  background: var(--primary);
  color: #fff;
}

/* ===== Course Modal ===== */
.modal-content {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.course-modal-img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-radius: var(--radius);
  margin-bottom: 1.5rem;
}

.course-modal-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1rem;
}

.course-modal-meta span {
  background: var(--bg-section);
  padding: 0.4rem 1rem;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 500;
}

.course-skills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0;
}

.skill-tag {
  background: rgba(30, 64, 175, 0.1);
  color: var(--primary);
  padding: 0.3rem 0.8rem;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 500;
}

[data-theme="dark"] .skill-tag {
  background: rgba(59, 130, 246, 0.2);
  color: var(--primary-light);
}

/* ===== Online Fee Payment (Course Modal) ===== */
.course-modal-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

@media (max-width: 576px) {
  .course-modal-actions {
    grid-template-columns: 1fr;
  }
}

.btn-pay-fee-online {
  background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  font-weight: 600;
  width: 100%;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.btn-pay-fee-online:hover {
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(30, 64, 175, 0.35);
}

.online-fee-payment {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.online-fee-payment__title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.online-fee-payment__title i {
  color: var(--primary);
}

.online-fee-payment__subtitle {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
}

.payment-methods-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.payment-method-card {
  background: var(--bg-section);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.15rem;
  transition: var(--transition);
  height: 100%;
}

.payment-method-card:hover {
  border-color: var(--primary);
  box-shadow: 0 6px 18px rgba(30, 64, 175, 0.12);
}

.payment-method-card__icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.75rem;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.12);
}

.payment-method-card__icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.payment-method-card__icon--easypaisa,
.payment-method-card__icon--jazzcash,
.payment-method-card__icon--meezan {
  background: transparent;
  padding: 0;
}

.payment-method-card h6 {
  font-weight: 700;
  margin-bottom: 0.65rem;
  font-size: 1rem;
}

.payment-method-card dl {
  margin: 0;
  font-size: 0.85rem;
}

.payment-method-card dt {
  color: var(--text-secondary);
  font-weight: 500;
  margin-top: 0.4rem;
}

.payment-method-card dd {
  margin: 0.15rem 0 0;
  font-weight: 600;
  color: var(--text-primary);
  word-break: break-word;
}

.payment-instructions {
  background: rgba(30, 64, 175, 0.06);
  border: 1px solid rgba(30, 64, 175, 0.15);
  border-radius: var(--radius-lg);
  padding: 1.15rem 1.25rem;
  margin-bottom: 1.25rem;
}

[data-theme="dark"] .payment-instructions {
  background: rgba(59, 130, 246, 0.08);
}

.payment-instructions h6 {
  font-weight: 700;
  margin-bottom: 0.65rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.payment-instructions ol {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.payment-instructions li {
  margin-bottom: 0.35rem;
}

.payment-whatsapp-verify {
  text-align: center;
  padding: 1.25rem;
  background: rgba(37, 211, 102, 0.08);
  border: 1px solid rgba(37, 211, 102, 0.25);
  border-radius: var(--radius-lg);
}

.payment-whatsapp-verify p {
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.payment-whatsapp-verify .wa-number {
  font-weight: 700;
  color: var(--text-primary);
}

.btn-back-course-details {
  background: transparent;
  border: none;
  color: var(--primary);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0;
  margin-bottom: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  cursor: pointer;
}

.btn-back-course-details:hover {
  text-decoration: underline;
}

/* ===== Forms ===== */
.admission-form,
.contact-form {
  background: var(--bg-card);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.form-control,
.form-select {
  background: var(--bg-body);
  border: 1px solid var(--border);
  color: var(--text-primary);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  transition: var(--transition);
}

.form-control:focus,
.form-select:focus {
  background: var(--bg-body);
  border-color: var(--primary);
  color: var(--text-primary);
  box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.15);
}

.form-label {
  font-weight: 500;
  color: var(--text-primary);
}

.picture-preview img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 10px;
  border: 2px solid var(--primary);
}

.admission-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  align-items: center;
}

@media (max-width: 576px) {
  .admission-form-actions .btn {
    width: 100%;
    margin: 0 !important;
  }
}

/* ===== Reviews ===== */
.review-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
  box-shadow: var(--shadow);
}

.review-avatar {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--primary);
  margin-bottom: 1rem;
}

.review-stars {
  color: var(--accent);
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.review-text {
  font-size: 1.1rem;
  font-style: italic;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

.review-name {
  font-weight: 700;
  font-family: var(--font-heading);
}

#reviewsCarousel .carousel-control-prev,
#reviewsCarousel .carousel-control-next {
  width: 45px;
  height: 45px;
  background: var(--primary);
  border-radius: 50%;
  top: 50%;
  opacity: 0.9;
}

/* ===== Result Card - A4 Landscape ===== */
.result-search-box {
  background: var(--bg-card);
  padding: 2rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

#resultCardWrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* A4 landscape ratio on screen (297mm x 210mm) */
.result-card-a4 {
  width: 100%;
  max-width: 1050px;
  aspect-ratio: 297 / 210;
  min-height: 480px;
}

.result-card {
  width: 100%;
  margin: 0 auto;
  background: #fff;
  color: #0f172a;
  border: 3px double #1e40af;
  border-radius: 8px;
  padding: 1.75rem 2rem;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

[data-theme="dark"] .result-card {
  background: #fff;
  color: #0f172a;
}

.result-card-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  border-bottom: 2px solid #1e40af;
  padding-bottom: 1rem;
  margin-bottom: 1rem;
}

.result-logo {
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, #1e40af, #3b82f6);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 2rem;
  flex-shrink: 0;
}

.result-academy-info {
  flex: 1;
  text-align: center;
}

.result-academy-info h2 {
  color: #1e40af;
  font-size: 1.75rem;
  margin: 0;
  font-weight: 800;
}

.result-academy-info p {
  margin: 0;
  font-size: 0.85rem;
  color: #64748b;
}

.result-doc-title {
  font-weight: 700 !important;
  color: #1e40af !important;
  font-size: 1rem !important;
  margin-top: 0.25rem !important;
  letter-spacing: 2px;
}

.result-course-banner {
  display: inline-block;
  margin-top: 0.5rem;
  padding: 0.4rem 1.5rem;
  border: 2px solid #1e40af;
  border-radius: 6px;
  font-weight: 700;
  color: #1e40af;
  font-size: 1.05rem;
  letter-spacing: 0.5px;
  background: rgba(30, 64, 175, 0.06);
}

.result-photo-box {
  width: 100px;
  height: 120px;
  border: 2px solid #1e40af;
  overflow: hidden;
  flex-shrink: 0;
}

.result-photo-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.result-card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0.5rem 0;
}

.result-card-body .row {
  width: 100%;
}

.result-field {
  display: flex;
  gap: 0.5rem;
  padding: 0.4rem 0;
  border-bottom: 1px dotted #cbd5e1;
}

.result-field label {
  font-weight: 600;
  color: #1e40af;
  min-width: 130px;
  font-size: 0.9rem;
}

.result-field span { font-size: 0.9rem; }

.result-grade span {
  font-size: 0.9rem !important;
  font-weight: 600;
  color: #1e40af;
}

.result-badge {
  display: inline-block;
  padding: 0.15rem 0.75rem;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.85rem !important;
}

.result-badge.pass {
  background: #d1fae5;
  color: #065f46;
}

.result-badge.progress {
  background: #fef3c7;
  color: #92400e;
}

.result-badge.fail {
  background: #fee2e2;
  color: #991b1b;
}

.result-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-top: auto;
  padding-top: 1rem;
  border-top: 2px solid #1e40af;
  flex-shrink: 0;
}

.signature-box {
  text-align: center;
  width: 180px;
}

.signature-line {
  height: 50px;
  border-bottom: 1px solid #334155;
  margin-bottom: 0.25rem;
}

.signature-box p {
  font-size: 0.8rem;
  font-weight: 600;
  color: #64748b;
  margin: 0;
}

.result-stamp {
  margin-top: 1.25rem;
}

.stamp-circle {
  width: 80px;
  height: 80px;
  border: 3px solid #1e40af;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 800;
  color: #1e40af;
  transform: rotate(-15deg);
  letter-spacing: 1px;
}

.result-card-note {
  text-align: center;
  margin-top: 0.75rem;
}

.result-card-note p {
  font-size: 0.7rem;
  color: #94a3b8;
  margin: 0;
}

/* ===== Print: full A4 landscape, no empty space below ===== */
@media print {
  @page {
    size: A4 landscape;
    margin: 0;
  }

  body.print-result-mode {
    margin: 0 !important;
    padding: 0 !important;
    background: #fff !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  body.print-result-mode .navbar,
  body.print-result-mode .site-footer,
  body.print-result-mode .page-loader,
  body.print-result-mode .result-actions,
  body.print-result-mode .result-search-box,
  body.print-result-mode .section-header,
  body.print-result-mode #resultError,
  body.print-result-mode #noDataMsg,
  body.print-result-mode .result-page-section > .container > .text-center {
    display: none !important;
  }

  body.print-result-mode .result-page-section {
    padding: 0 !important;
    background: #fff !important;
  }

  body.print-result-mode .result-page-section > .container {
    padding: 0 !important;
    margin: 0 !important;
    max-width: none !important;
    width: 100% !important;
  }

  body.print-result-mode #resultCardWrapper {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    max-width: none !important;
    background: #fff !important;
  }

  body.print-result-mode #resultCard,
  body.print-result-mode .result-card-a4 {
    width: 270mm !important;
    height: 180mm !important;
    max-width: none !important;
    min-height: 180mm !important;
    aspect-ratio: unset !important;
    margin: 0 auto !important;
    padding: 8mm 12mm !important;
    border: 3px double #1e40af !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    box-sizing: border-box !important;
    display: flex !important;
    flex-direction: column !important;
    page-break-inside: avoid !important;
    page-break-after: avoid !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
    background: #fff !important;
    overflow: hidden !important;
  }

  body.print-result-mode .result-card-header {
    flex-shrink: 0;
    padding-bottom: 0.5rem;
    margin-bottom: 0.5rem;
  }

  body.print-result-mode .result-academy-info h2 {
    font-size: 1.5rem !important;
  }

  body.print-result-mode .result-academy-info .result-doc-title {
    font-size: 0.85rem !important;
    letter-spacing: 2px !important;
  }

  body.print-result-mode .result-photo-box {
    width: 26mm !important;
    height: 32mm !important;
  }

  body.print-result-mode .result-card-body {
    flex: 1 !important;
    justify-content: center !important;
    padding: 0 !important;
  }

  body.print-result-mode .result-field {
    padding: 0.35rem 0 !important;
    font-size: 0.9rem !important;
  }

  body.print-result-mode .result-field label {
    color: #1e40af !important;
    font-weight: 700 !important;
  }

  body.print-result-mode .result-field span {
    font-size: 0.9rem !important;
  }

  body.print-result-mode .result-grade span {
    font-size: 0.9rem !important;
    color: #1e40af !important;
  }

  body.print-result-mode .result-badge.pass {
    background: #d1fae5 !important;
    color: #065f46 !important;
  }

  body.print-result-mode .result-badge.fail {
    background: #fee2e2 !important;
    color: #991b1b !important;
  }

  body.print-result-mode .result-badge.progress {
    background: #fef3c7 !important;
    color: #92400e !important;
  }

  body.print-result-mode .result-card-footer {
    margin-top: auto !important;
    flex-shrink: 0;
    border-top: 2px solid #1e40af !important;
    padding-top: 1rem !important;
  }

  body.print-result-mode .stamp-circle {
    color: #1e40af !important;
    border-color: #1e40af !important;
  }

  body.print-result-mode .result-stamp {
    margin-top: 1rem !important;
  }

  body.print-result-mode .result-card-note {
    flex-shrink: 0;
    margin-top: 0.5rem;
  }
}

/* ===== PDF Capture Mode (used by html2canvas to capture clean snapshot) ===== */
body.pdf-capture-mode #resultCard,
body.pdf-capture-mode .result-card-a4 {
  width: 297mm !important;
  height: 210mm !important;
  max-width: none !important;
  min-height: 210mm !important;
  aspect-ratio: unset !important;
  margin: 0 !important;
  padding: 12mm 16mm !important;
  border: 3px double #1e40af !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  box-sizing: border-box !important;
  display: flex !important;
  flex-direction: column !important;
  background: #fff !important;
  overflow: hidden !important;
}

body.pdf-capture-mode .result-card-body {
  flex: 1 !important;
  justify-content: center !important;
}

body.pdf-capture-mode .result-card-footer {
  margin-top: auto !important;
}

/* ===== About Section ===== */
.about-image-wrap {
  position: relative;
}

.about-image-wrap img {
  box-shadow: var(--shadow-lg);
}

.about-badge {
  position: absolute;
  bottom: -15px;
  right: 20px;
  background: var(--gradient);
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 700;
  box-shadow: var(--shadow);
}

.about-lead {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.about-card {
  display: flex;
  gap: 1rem;
  padding: 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 1rem;
  transition: var(--transition);
}

.about-card:hover {
  transform: translateX(8px);
  border-color: var(--primary-light);
  box-shadow: var(--shadow);
}

.about-card-icon {
  width: 50px;
  height: 50px;
  background: var(--gradient);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.about-card h5 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.about-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin: 0;
}

/* ===== FAQ Accordion ===== */
.faq-accordion .accordion-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius) !important;
  margin-bottom: 0.75rem;
  overflow: hidden;
}

.faq-accordion .accordion-button {
  background: var(--bg-card);
  color: var(--text-primary);
  font-weight: 600;
  font-family: var(--font-heading);
  box-shadow: none;
}

.faq-accordion .accordion-button:not(.collapsed) {
  background: rgba(30, 64, 175, 0.08);
  color: var(--primary);
}

.faq-accordion .accordion-button::after {
  filter: none;
}

[data-theme="dark"] .faq-accordion .accordion-button::after {
  filter: invert(1);
}

.faq-accordion .accordion-body {
  color: var(--text-secondary);
  background: var(--bg-card);
}

/* ===== Contact Section ===== */
.contact-info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  height: 100%;
  box-shadow: var(--shadow);
}

.contact-item {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.contact-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  color: #fff;
  flex-shrink: 0;
}

.contact-icon.whatsapp { background: var(--whatsapp); }
.contact-icon.email { background: var(--primary); }
.contact-icon.location { background: var(--accent); }

.contact-item h6 {
  margin: 0 0 0.25rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.contact-item a,
.contact-item p {
  margin: 0;
  color: var(--text-primary);
  font-weight: 500;
}

.contact-item a:hover { color: var(--primary); }

/* ===== Footer ===== */
.site-footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 4rem 0 1.5rem;
}

.site-footer h6 {
  color: #fff;
  font-weight: 700;
  margin-bottom: 1.25rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-size: 1.25rem;
  color: #fff;
  font-weight: 700;
  margin-bottom: 1rem;
}

.footer-social {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

.footer-social a {
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,0.1);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.1rem;
  transition: var(--transition);
}

.footer-social a:hover {
  background: var(--primary);
  transform: translateY(-3px);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li { margin-bottom: 0.5rem; }

.footer-links a {
  color: #94a3b8;
  font-size: 0.9rem;
}

.footer-links a:hover { color: #fff; }

.footer-contact {
  list-style: none;
  padding: 0;
}

.footer-contact li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
}

.footer-contact a { color: #94a3b8; }
.footer-contact a:hover { color: #fff; }

.footer-divider {
  border-color: rgba(255,255,255,0.1);
  margin: 2rem 0 1.5rem;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-bottom p { margin: 0; font-size: 0.9rem; }

.btn-back-top {
  width: 45px;
  height: 45px;
  background: var(--gradient);
  border: none;
  border-radius: 12px;
  color: #fff;
  font-size: 1.25rem;
  cursor: pointer;
  transition: var(--transition);
  opacity: 0;
  visibility: hidden;
}

.btn-back-top.visible {
  opacity: 1;
  visibility: visible;
}

.btn-back-top:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(30, 64, 175, 0.4);
}

/* ===== Responsive ===== */
@media (max-width: 991px) {
  .stats-bar { margin-top: 0; border-radius: 0; }
  .hero-content { padding: 100px 0 60px; }
  .admission-form, .contact-form { padding: 1.5rem; }
}

@media (max-width: 767px) {
  .section-padding { padding: 3.5rem 0; }
  .result-card-a4 {
    aspect-ratio: auto;
    min-height: auto;
  }
  .result-card {
    padding: 1rem;
  }
  .result-card-header { flex-wrap: wrap; }
  .result-field { flex-direction: column; gap: 0; }
  .result-field label { min-width: auto; }
  .result-card-footer { flex-direction: column; gap: 1.5rem; align-items: center; }
  .hero-buttons { flex-direction: column; align-items: stretch; width: 100%; }
  .hero-buttons .btn { width: 100%; max-width: 100%; }

  /* Hero: no zoom overflow on phones */
  .hero-section .carousel-item.active {
    animation: none !important;
    transform: none !important;
  }

  .hero-section .carousel-control-prev,
  .hero-section .carousel-control-next {
    display: none;
  }

  .hero-content {
    padding: 96px 0 72px;
  }

  .hero-content .container,
  .navbar > .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .hero-content .row {
    margin-left: 0;
    margin-right: 0;
  }

  .hero-content [class*='col-'] {
    padding-left: 0;
    padding-right: 0;
    max-width: 100%;
  }

  .hero-title {
    font-size: clamp(1.65rem, 7.5vw, 2.35rem);
    line-height: 1.15;
    word-break: break-word;
  }

  .hero-tagline {
    font-size: 0.95rem;
    line-height: 1.55;
    margin-bottom: 1.5rem;
    padding: 0 0.15rem;
  }

  .hero-badge {
    font-size: 0.78rem;
    padding: 0.4rem 0.85rem;
    margin-bottom: 1rem;
    max-width: 100%;
    line-height: 1.35;
  }

  .navbar-brand {
    font-size: 0.95rem;
    min-width: 0;
    flex: 1;
    margin-right: 0.5rem;
  }

  .brand-text {
    line-height: 1.2;
    white-space: normal;
    word-break: break-word;
  }

  .stats-bar {
    margin-left: 0.75rem;
    margin-right: 0.75rem;
    border-radius: var(--radius);
  }
}

@media (max-width: 576px) {
  .about-badge { font-size: 0.8rem; padding: 0.5rem 1rem; }
}

/* ===== Free CV Builder ===== */
.cv-promo-banner {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, #059669, #10b981);
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  margin: 1rem auto 0.5rem;
  box-shadow: 0 8px 24px rgba(5, 150, 105, 0.25);
}

.cv-form-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}

.cv-block-title {
  color: var(--primary);
  font-weight: 700;
  margin-top: 0.75rem;
  margin-bottom: 0.85rem;
  letter-spacing: 0.04em;
  word-spacing: 0.12em;
}

.cv-section-divider {
  margin-top: 1.5rem !important;
  margin-bottom: 0.5rem !important;
  opacity: 0.35;
}

.cv-feedback-modal .modal-title {
  font-weight: 700;
  color: var(--primary);
  width: 100%;
  text-align: center;
}

.cv-feedback-message {
  font-size: 1.08rem;
  line-height: 1.65;
  color: var(--text-primary);
  font-weight: 500;
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}

.cv-feedback-wa-btn {
  font-weight: 600;
  max-width: 320px;
  margin: 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.cv-action-btns {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.cv-photo-wrap {
  width: 120px;
  height: 120px;
  margin: 0 auto;
  position: relative;
  border-radius: 50%;
  overflow: hidden;
}

.cv-photo-preview,
.cv-photo-placeholder {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--primary-light);
}

.cv-photo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-section);
  color: var(--text-muted);
  font-size: 3rem;
}

.cv-repeat-block {
  background: var(--bg-section);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1rem 0.25rem;
  margin-bottom: 1rem;
}

.cv-form-hint {
  font-style: italic;
}

/* ===== Services Section (homepage) ===== */
.services-section {
  background: var(--bg-section);
}

.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 1.75rem 1.25rem 1.5rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: var(--transition);
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(30, 64, 175, 0.2);
}

.service-icon-wrap {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1rem;
  flex-shrink: 0;
}

.service-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
  line-height: 1.35;
}

.service-desc-urdu {
  font-family: 'Noto Nastaliq Urdu', 'Jameel Noori Nastaleeq', serif;
  font-size: 1rem;
  line-height: 1.9;
  color: var(--text-secondary);
  margin: 0 0 1.25rem;
  flex-grow: 1;
  text-align: center;
}

.service-contact-btn {
  min-width: 8.5rem;
  border-radius: 50px;
  font-weight: 600;
  padding: 0.45rem 1.25rem;
}

.services-help-bar {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.25rem;
  padding: 1.5rem 1.75rem;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.12) 0%, rgba(30, 64, 175, 0.08) 100%);
  border: 1px solid rgba(30, 64, 175, 0.15);
  border-radius: var(--radius-lg);
}

.services-help-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  flex-shrink: 0;
}

.services-help-text {
  flex: 1;
  min-width: 200px;
}

.services-help-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--primary);
  margin: 0 0 0.35rem;
}

.services-help-urdu {
  font-family: 'Noto Nastaliq Urdu', 'Jameel Noori Nastaleeq', serif;
  font-size: 1.05rem;
  line-height: 1.85;
  color: var(--text-secondary);
  margin: 0;
  direction: rtl;
}

.services-help-btn {
  border-radius: 50px;
  font-weight: 600;
  white-space: nowrap;
  margin-left: auto;
}

@media (max-width: 767.98px) {
  .services-help-bar {
    flex-direction: column;
    text-align: center;
  }

  .services-help-btn {
    margin-left: 0;
    width: 100%;
    max-width: 280px;
  }

  .services-help-urdu {
    text-align: center;
  }
}

/* CV Hero Card on index.html — unified heading + CTA */
.cv-hero-card {
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid #e2e8f0;
  border-radius: 1.5rem;
  padding: 2.5rem;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.1);
  position: relative;
  overflow: hidden;
}

.cv-hero-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  background: linear-gradient(90deg, #2563eb 0%, #10b981 50%, #2563eb 100%);
}

.cv-hero-header {
  text-align: center;
  margin-bottom: 1.75rem;
}

.cv-hero-title {
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 1rem;
}

.cv-hero-banner {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  font-weight: 600;
  padding: 0.65rem 1.5rem;
  border-radius: 999px;
  box-shadow: 0 8px 18px rgba(16, 185, 129, 0.3);
  margin: 0;
}

.cv-hero-banner i {
  font-size: 1.1rem;
}

.cv-hero-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, #e2e8f0, transparent);
  margin: 0 0 1.75rem 0;
}

.cv-cta-inner {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  text-decoration: none;
  color: #0f172a;
  padding: 1.5rem;
  border-radius: 1rem;
  background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 100%);
  border: 1px solid #e2e8f0;
  transition: all 0.25s ease;
}

.cv-cta-inner:hover,
.cv-cta-inner:focus {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(37, 99, 235, 0.2);
  border-color: #93c5fd;
  color: #0f172a;
  text-decoration: none;
}

.cv-cta-icon {
  flex-shrink: 0;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  box-shadow: 0 10px 26px rgba(37, 99, 235, 0.32);
}

.cv-cta-body {
  flex: 1 1 auto;
}

.cv-cta-body h3 {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  color: #0f172a;
}

.cv-cta-body p {
  color: #475569;
  margin-bottom: 1rem;
}

.cv-cta-features {
  list-style: none;
  padding: 0;
  margin: 0 0 1.25rem 0;
}

.cv-cta-features li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #334155;
  font-size: 0.92rem;
  padding: 3px 0;
}

.cv-cta-features li i {
  color: #16a34a;
  font-size: 1rem;
}

@media (max-width: 576px) {
  .cv-hero-card {
    padding: 1.5rem 1.25rem;
    border-radius: 1.25rem;
  }
  .cv-hero-banner {
    padding: 0.55rem 1rem;
    font-size: 0.85rem;
    text-align: center;
  }
  .cv-cta-inner {
    flex-direction: column;
    text-align: center;
    padding: 1.25rem;
    gap: 1rem;
  }
  .cv-cta-icon {
    width: 80px;
    height: 80px;
    font-size: 2.4rem;
  }
  .cv-cta-features li {
    justify-content: center;
  }
}

/* Standalone cv.html page styling */
.cv-page-section {
  padding-top: 110px; /* avoid fixed navbar overlap */
  min-height: 100vh;
}

.cv-page-header .cv-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.5rem;
}

.cv-page-hero-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1.75rem;
  margin-top: 1.25rem;
  max-width: 920px;
  margin-left: auto;
  margin-right: auto;
}

.cv-provider-photo-box {
  flex-shrink: 0;
  width: 200px;
  height: 240px;
  padding: 0.5rem;
  background: #fff;
  border: 2px solid #e2e8f0;
  border-radius: 1rem;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.1);
  overflow: hidden;
}

.cv-provider-photo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  border-radius: 0.65rem;
}

.cv-page-hero-text {
  flex: 1;
  min-width: 260px;
  max-width: 640px;
}

.cv-page-hero-text .section-subtitle {
  margin-left: 0;
  margin-right: 0;
}

@media (max-width: 767.98px) {
  .cv-provider-photo-box {
    width: 168px;
    height: 200px;
  }

  .cv-page-hero-text .cv-promo-banner {
    font-size: 0.9rem;
  }
}

/* Standalone result-card.html page styling */
.result-page-section {
  padding-top: 110px;
  min-height: 100vh;
}

.result-view-container {
  max-width: 920px;
}

/* Punjab University–style web result sheet */
.pu-result-sheet {
  background: #fff;
  border: 1px solid #cbd5e1;
  box-shadow: 0 4px 24px rgba(15, 23, 42, 0.08);
  padding: 2rem 2.25rem 1.5rem;
  margin: 0 auto 2rem;
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  color: #0f172a;
}

.pu-result-header {
  text-align: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid #1e3a8a;
}

.pu-logo-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 0.75rem;
}

.pu-logo {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1e40af, #2563eb);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  box-shadow: 0 4px 12px rgba(30, 64, 175, 0.35);
}

.pu-title {
  font-family: 'Merriweather', Georgia, serif;
  font-size: 1.75rem;
  font-weight: 700;
  color: #1e3a8a;
  margin: 0 0 0.25rem;
  line-height: 1.2;
}

.pu-subtitle {
  font-size: 0.9rem;
  color: #64748b;
  margin: 0 0 0.75rem;
}

.pu-exam-title {
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0.5rem 0 0.35rem;
  line-height: 1.4;
}

.pu-exam-course {
  font-size: 0.88rem;
  color: #475569;
  margin: 0;
}

.pu-info-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  margin-bottom: 1.25rem;
  font-size: 0.92rem;
}

.pu-info-table .pu-col-label,
.pu-info-table .pu-col-value {
  width: 25%;
}

.pu-info-table th,
.pu-info-table td {
  border: 1px solid #e2e8f0;
  padding: 0.55rem 0.65rem;
  vertical-align: middle;
  word-wrap: break-word;
}

.pu-info-table th {
  background: #f8fafc;
  color: #334155;
  font-weight: 700;
  text-align: left;
}

.pu-info-table td {
  color: #0f172a;
}

.pu-marks-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  margin-bottom: 1.25rem;
  font-size: 0.92rem;
}

.pu-marks-table .pu-col-equal {
  width: 25%;
}

.pu-marks-table thead th {
  background: #1e3a8a;
  color: #fff;
  font-weight: 700;
  padding: 0.65rem 0.85rem;
  text-align: center;
  border: 1px solid #1e3a8a;
}

.pu-marks-table tbody td {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  padding: 0.6rem 0.85rem;
  text-align: center;
  color: #0f172a;
}

.pu-marks-table tbody td:first-child {
  text-align: left;
  font-weight: 600;
}

.pu-marks-obtained {
  font-weight: 700;
  font-size: 1rem;
  color: #1e40af;
}

.pu-status-badge {
  display: inline-block;
  padding: 0.2rem 0.65rem;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.85rem;
}

.pu-status-pass {
  background: #d1fae5;
  color: #065f46;
}

.pu-status-fail {
  background: #fee2e2;
  color: #991b1b;
}

.pu-status-pending {
  background: #fef3c7;
  color: #92400e;
}

.pu-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  text-align: center;
}

.pu-summary-item {
  border: 1px solid #e2e8f0;
  padding: 0.75rem 0.5rem;
  background: #f8fafc;
}

.pu-summary-label {
  display: block;
  font-size: 0.78rem;
  color: #64748b;
  margin-bottom: 0.35rem;
  font-weight: 600;
}

.pu-summary-item strong {
  font-size: 1rem;
  color: #0f172a;
}

.pu-comments-pass {
  color: #2563eb !important;
}

.pu-remarks {
  font-size: 0.9rem;
  line-height: 1.65;
  color: #334155;
  margin-bottom: 1rem;
}

.pu-remarks strong {
  color: #0f172a;
}

.pu-remarks p {
  margin: 0.35rem 0 0;
}

.pu-result-footer {
  text-align: center;
  border-top: 1px solid #e2e8f0;
  padding-top: 0.85rem;
  font-size: 0.78rem;
  color: #94a3b8;
}

.pu-result-footer p {
  margin: 0.2rem 0;
}

.pu-copy {
  font-size: 0.72rem;
}

/* Mobile: result card web view only (PDF uses jsPDF — unchanged) */
@media (max-width: 767px) {
  .result-view-page .result-view-container {
    max-width: 100%;
    padding-left: 0.75rem;
    padding-right: 0.75rem;
  }

  .result-view-page #resultCardWrapper {
    width: 100%;
    align-items: stretch;
  }

  .result-view-page .pu-result-sheet {
    width: 100%;
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
    padding: 1.15rem 0.85rem 1.25rem;
    box-sizing: border-box;
    overflow-x: hidden;
  }

  .result-view-page .pu-title {
    font-size: 1.35rem;
  }

  .result-view-page .pu-exam-title {
    font-size: 0.9rem;
  }

  /* Student info: each row becomes 2 label/value pairs (full width) */
  .result-view-page .pu-info-table {
    table-layout: auto;
    border: 0;
    margin-bottom: 1rem;
  }

  .result-view-page .pu-info-table colgroup {
    display: none;
  }

  .result-view-page .pu-info-table tbody {
    display: block;
    width: 100%;
  }

  .result-view-page .pu-info-table tr {
    display: grid;
    grid-template-columns: minmax(6.75rem, 42%) 1fr;
    width: 100%;
    margin-bottom: 0.65rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
  }

  .result-view-page .pu-info-table th,
  .result-view-page .pu-info-table td {
    display: block;
    width: auto;
    box-sizing: border-box;
    border: none;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.55rem 0.65rem;
    word-break: break-word;
  }

  .result-view-page .pu-info-table th {
    border-right: 1px solid #e2e8f0;
    background: #f8fafc;
  }

  .result-view-page .pu-info-table tr > :nth-child(3),
  .result-view-page .pu-info-table tr > :nth-child(4) {
    border-bottom: none;
  }

  /* Marks table: stack rows on mobile (no horizontal cut-off) */
  .result-view-page .pu-table-scroll {
    width: 100%;
    max-width: 100%;
    overflow-x: visible;
    margin-bottom: 1.25rem;
  }

  .result-view-page .pu-marks-table {
    min-width: 0;
    width: 100%;
    table-layout: fixed;
    font-size: 0.85rem;
  }

  .result-view-page .pu-marks-table colgroup {
    display: none;
  }

  .result-view-page .pu-marks-table thead {
    display: none;
  }

  .result-view-page .pu-marks-table tbody {
    display: block;
    width: 100%;
  }

  .result-view-page .pu-marks-table tbody tr {
    display: block;
    width: 100%;
    border: 1px solid #a7f3d0;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 0;
  }

  .result-view-page .pu-marks-table tbody td {
    display: grid;
    grid-template-columns: minmax(6.5rem, 40%) 1fr;
    align-items: center;
    gap: 0.35rem;
    text-align: left !important;
    padding: 0.55rem 0.65rem;
    border: none;
    border-bottom: 1px solid #bbf7d0;
    word-break: break-word;
  }

  .result-view-page .pu-marks-table tbody td:last-child {
    border-bottom: none;
  }

  .result-view-page .pu-marks-table tbody td::before {
    content: attr(data-label);
    font-weight: 700;
    font-size: 0.78rem;
    color: #334155;
  }

  .result-view-page .pu-summary {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .result-view-page .pu-summary-item {
    text-align: left;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.65rem 0.85rem;
  }

  .result-view-page .pu-summary-label {
    margin-bottom: 0;
  }
}

/* Standalone admission.html page styling */
.admission-page-section {
  padding-top: 110px;
  min-height: 100vh;
}

/* Standalone portal.html page styling */
.portal-select-section {
  padding-top: 110px;
  min-height: 100vh;
}

.portal-select-card {
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid #e2e8f0;
  border-radius: 1.5rem;
  padding: 2.5rem;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.1);
  position: relative;
  overflow: hidden;
}

.portal-select-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #2563eb, #059669);
}

.portal-select-header {
  text-align: center;
  margin-bottom: 1rem;
}

.portal-select-title {
  font-size: 2rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0.5rem 0 0.75rem;
}

.portal-select-subtitle {
  color: #64748b;
  margin: 0;
  font-size: 0.95rem;
}

.portal-select-divider {
  height: 1px;
  background: #e2e8f0;
  margin: 1.5rem 0 2rem;
}

.portal-select-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.portal-option {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  padding: 1.75rem;
  border: 1px solid #e2e8f0;
  border-radius: 1rem;
  background: #ffffff;
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.portal-option:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.14);
  border-color: #cbd5e1;
  color: inherit;
  text-decoration: none;
}

.portal-option-icon {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
}

.portal-option-tuition .portal-option-icon {
  background: linear-gradient(135deg, #059669, #14b8a6);
}

.portal-option-body {
  flex: 1;
}

.portal-option-body h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.5rem;
}

.portal-option-body > p {
  color: #64748b;
  font-size: 0.92rem;
  margin: 0 0 0.85rem;
  line-height: 1.55;
}

.portal-option-features {
  list-style: none;
  padding: 0;
  margin: 0 0 1.1rem;
}

.portal-option-features li {
  color: #475569;
  font-size: 0.875rem;
  padding: 0.2rem 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.portal-option-features li i {
  color: #16a34a;
  font-size: 0.95rem;
}

.portal-option-tuition .portal-option-features li i {
  color: #14b8a6;
}

.portal-option .btn {
  font-size: 0.9rem;
  padding: 0.55rem 1.1rem;
}

@media (max-width: 768px) {
  .portal-select-card {
    padding: 1.5rem;
  }

  .portal-select-title {
    font-size: 1.5rem;
  }

  .portal-select-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .portal-option {
    flex-direction: column;
    text-align: center;
    align-items: center;
  }
}

/* Admission CTA Hero Card on homepage */
.admission-side-image-wrap {
  position: relative;
  min-height: 100%;
  border-radius: 1.25rem;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.15);
}

.admission-side-image-wrap img {
  min-height: 100%;
  object-fit: cover;
}

.admission-side-badge {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  background: linear-gradient(135deg, #1d4ed8, #2563eb);
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.5rem 0.9rem;
  border-radius: 999px;
  box-shadow: 0 8px 20px rgba(30, 64, 175, 0.35);
}

.admission-hero-card {
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid #e2e8f0;
  border-radius: 1.5rem;
  padding: 2.5rem;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.1);
  position: relative;
  overflow: hidden;
}

.admission-hero-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #2563eb, #7c3aed, #ec4899);
}

.admission-hero-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.admission-hero-title {
  font-size: 2rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0.5rem 0 0.75rem;
}

.admission-hero-subtitle {
  color: #64748b;
  margin: 0;
  font-size: 0.95rem;
}

.admission-hero-divider {
  height: 1px;
  background: #e2e8f0;
  margin: 1.5rem 0 2rem;
}

.admission-cta-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.admission-cta-card {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  padding: 1.5rem;
  border: 1px solid #e2e8f0;
  border-radius: 1rem;
  background: #ffffff;
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.admission-cta-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.12);
  border-color: #cbd5e1;
  color: inherit;
  text-decoration: none;
}

.admission-cta-icon {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  color: #ffffff;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
}

.admission-cta-tuition .admission-cta-icon {
  background: linear-gradient(135deg, #059669, #14b8a6);
}

.admission-cta-body {
  flex: 1;
}

.admission-cta-body h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.5rem;
}

.admission-cta-body p {
  color: #64748b;
  font-size: 0.9rem;
  margin: 0 0 1rem;
  line-height: 1.5;
}

.admission-cta-body .btn {
  font-size: 0.875rem;
  padding: 0.5rem 1rem;
}

@media (max-width: 768px) {
  .admission-side-image-wrap {
    min-height: 240px;
  }

  .admission-hero-card {
    padding: 1.5rem;
  }

  .admission-hero-title {
    font-size: 1.5rem;
  }

  .admission-cta-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .admission-cta-card {
    flex-direction: column;
    text-align: center;
    align-items: center;
  }
}

/* Student Portal Dropdown — simple clean menu (click to open) */
.portal-dropdown .dropdown-toggle::after {
  margin-left: 0.4rem;
  border-top-color: currentColor;
  vertical-align: middle;
}

.portal-menu {
  border: none;
  border-radius: 8px;
  padding: 6px 0;
  min-width: 220px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.15);
  margin-top: 8px !important;
  background: #ffffff;
  animation: portalDrop 0.15s ease-out;
}

@keyframes portalDrop {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.portal-menu .portal-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  font-size: 0.95rem;
  font-weight: 500;
  color: #1f2937;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
  border: none;
  background: transparent;
}

.portal-menu .portal-menu-item i {
  font-size: 1.05rem;
  color: #6b7280;
  width: 18px;
  text-align: center;
  transition: color 0.15s ease;
}

.portal-menu .portal-menu-item:hover,
.portal-menu .portal-menu-item:focus {
  background: #f3f4f6;
  color: #2563eb;
}

.portal-menu .portal-menu-item:hover i,
.portal-menu .portal-menu-item:focus i {
  color: #2563eb;
}

.portal-menu .portal-menu-item.active,
.portal-menu .portal-menu-item:active {
  background: #eff6ff;
  color: #2563eb;
}

/* Admission type switch — segmented control (matches form width below) */
.admission-type-switch {
  display: flex;
  width: 100%;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 6px;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
  gap: 4px;
}
.admission-type-btn {
  flex: 1 1 auto;
  min-width: 0;
  background: transparent;
  border: none;
  border-radius: 8px;
  padding: 0.75rem 1.25rem;
  text-align: center;
  font-size: 0.95rem;
  font-weight: 600;
  color: #475569;
  transition: all 0.25s ease;
  cursor: pointer;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.admission-type-btn:hover {
  color: #1e40af;
  background: #f8fafc;
}
.admission-type-btn.active {
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.35);
}
.admission-type-btn.active:hover {
  color: #ffffff;
  background: linear-gradient(135deg, #1e3a8a 0%, #1d4ed8 100%);
}

/* Stack form-type tabs on tablet/phone — prevents label overlap */
@media (max-width: 991px) {
  .admission-type-switch {
    flex-direction: column;
    align-items: stretch;
    gap: 0.65rem;
    padding: 8px;
  }

  .admission-type-btn {
    flex: 0 0 auto;
    width: 100%;
    min-height: 48px;
    padding: 0.85rem 1rem;
    white-space: normal;
    overflow: visible;
    text-overflow: unset;
    line-height: 1.4;
  }

  .admission-type-btn.active {
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.28);
  }
}

@media (max-width: 767px) {
  .admission-page-section .section-title {
    font-size: 1.65rem;
  }

  .admission-page-section .section-subtitle {
    font-size: 0.92rem;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }

  .admission-page-section .admission-form {
    padding: 1.25rem;
  }

  .admission-page-section h3.text-center {
    font-size: 1.15rem;
    line-height: 1.45;
    padding-left: 0.25rem;
    padding-right: 0.25rem;
  }
}

.cv-profile-summary {
  min-height: 220px;
  resize: vertical;
  font-size: 0.95rem;
  line-height: 1.6;
}

.cv-skills-area {
  min-height: 200px;
  resize: vertical;
  font-size: 0.95rem;
  line-height: 1.6;
}

.cv-languages-area {
  min-height: 90px;
  resize: vertical;
  font-size: 0.95rem;
  line-height: 1.6;
}

@media (max-width: 576px) {
  .cv-profile-summary {
    min-height: 180px;
  }
  .cv-skills-area {
    min-height: 160px;
  }
  .cv-languages-area {
    min-height: 80px;
  }
}

@media print {
  .cv-form-hint,
  .cv-action-btns .text-muted,
  #addWorkBtn,
  #addEduBtn,
  .cv-remove-block {
    display: none !important;
  }
}
