/* ============================================================
   NTM — Careers Page Styles
   Consistent with the existing NTM visual language
   ============================================================ */

/* ── JOB CARDS ─────────────────────────────────────────────── */
.careers-card {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  padding: 1.75rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.careers-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 48px rgba(0, 76, 137, 0.12);
  border-color: #9DB5D1;
}

.careers-card:focus-visible {
  outline: 2px solid #004C89;
  outline-offset: 2px;
}

.careers-card-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #003664;
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.careers-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.careers-card-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: #004C89;
  background: #f0f5fa;
  padding: 0.35rem 0.7rem;
  border-radius: 0.45rem;
  white-space: nowrap;
}

.careers-card-tag svg {
  width: 0.85rem;
  height: 0.85rem;
  flex-shrink: 0;
  color: #7F9AB1;
}

.careers-card-description {
  font-size: 0.875rem;
  color: #6b7280;
  line-height: 1.65;
  margin-bottom: 1.25rem;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.careers-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid #f3f4f6;
}

.careers-card-deadline {
  font-size: 0.75rem;
  color: #9ca3af;
}

.careers-card-deadline strong {
  color: #4b5563;
  font-weight: 700;
}

.careers-card-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: #004C89;
  transition: gap 0.2s ease, color 0.2s ease;
}

.careers-card:hover .careers-card-cta {
  gap: 0.55rem;
  color: #003664;
}

.careers-card-cta svg {
  width: 0.9rem;
  height: 0.9rem;
  transition: transform 0.2s ease;
}

.careers-card:hover .careers-card-cta svg {
  transform: translateX(2px);
}

/* ── MODAL ─────────────────────────────────────────────────── */
.careers-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1100;
  background: rgba(0, 26, 51, 0.65);
  backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.careers-modal-overlay.is-active {
  opacity: 1;
  visibility: visible;
}

.careers-modal {
  position: relative;
  background: #ffffff;
  border-radius: 1.25rem;
  width: 100%;
  max-width: 760px;
  max-height: calc(100vh - 3.5rem);
  display: flex;
  flex-direction: column;
  box-shadow: 0 32px 80px rgba(0, 54, 100, 0.24), 0 8px 24px rgba(0, 0, 0, 0.08);
  transform: translateY(24px) scale(0.97);
  opacity: 0;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.3s ease;
}

.careers-modal-overlay.is-active .careers-modal {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.careers-modal-header {
  padding: 2rem 2.25rem 1.25rem;
  border-bottom: 1px solid #f3f4f6;
  flex-shrink: 0;
}

.careers-modal-title {
  font-size: 1.65rem;
  font-weight: 900;
  color: #003664;
  line-height: 1.25;
  margin-bottom: 1rem;
  padding-right: 2.75rem;
}

.careers-modal-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}

.careers-modal-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  color: #004C89;
  background: #f0f5fa;
  padding: 0.35rem 0.75rem;
  border-radius: 0.45rem;
  font-weight: 600;
}

.careers-modal-meta-item svg {
  width: 0.95rem;
  height: 0.95rem;
  flex-shrink: 0;
  color: #7F9AB1;
}

.careers-modal-body {
  padding: 1.75rem 2.25rem 2rem;
  overflow-y: auto;
  flex: 1;
  -webkit-overflow-scrolling: touch;
}

.careers-modal-body::-webkit-scrollbar {
  width: 6px;
}
.careers-modal-body::-webkit-scrollbar-track {
  background: transparent;
}
.careers-modal-body::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 999px;
}

.careers-modal-section {
  margin-bottom: 2rem;
}

.careers-modal-section:last-child {
  margin-bottom: 0;
}

.careers-modal-section-title {
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #7F9AB1;
  margin-bottom: 0.85rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.careers-modal-section-title::before {
  content: '';
  width: 20px;
  height: 2px;
  background: #7F9AB1;
  border-radius: 2px;
}

.careers-modal-description {
  font-size: 0.95rem;
  color: #4b5563;
  line-height: 1.75;
}

.careers-modal-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.careers-modal-list li {
  position: relative;
  padding-left: 1.5rem;
  font-size: 0.92rem;
  color: #4b5563;
  line-height: 1.7;
  margin-bottom: 0.65rem;
}

.careers-modal-list li::before {
  content: '';
  position: absolute;
  left: 0.15rem;
  top: 0.65rem;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #004C89;
}

.careers-modal-close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.625rem;
  border: 1px solid #e5e7eb;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #9ca3af;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  z-index: 10;
}

.careers-modal-close:hover {
  background: #f3f4f6;
  color: #374151;
  border-color: #d1d5db;
}

.careers-modal-close:focus-visible {
  outline: 2px solid #004C89;
  outline-offset: 2px;
}

.careers-modal-close svg {
  width: 1.1rem;
  height: 1.1rem;
}

.careers-modal-footer {
  padding: 1.25rem 2.25rem;
  border-top: 1px solid #f3f4f6;
  background: #f9fafb;
  border-radius: 0 0 1.25rem 1.25rem;
  flex-shrink: 0;
}

/* ── EMPTY STATE ───────────────────────────────────────────── */
.careers-empty {
  text-align: center;
  padding: 4.5rem 2rem;
  background: #ffffff;
  border-radius: 1.25rem;
  border: 1px dashed #d1d5db;
  max-width: 600px;
  margin: 0 auto;
}

.careers-empty-icon {
  width: 4.5rem;
  height: 4.5rem;
  margin: 0 auto 1.5rem;
  border-radius: 1rem;
  background: #f0f5fa;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #7F9AB1;
}

.careers-empty-icon svg {
  width: 2.25rem;
  height: 2.25rem;
}

.careers-empty h3 {
  font-size: 1.35rem;
  font-weight: 800;
  color: #003664;
  margin-bottom: 0.65rem;
}

.careers-empty p {
  font-size: 0.95rem;
  color: #7F9AB1;
  max-width: 420px;
  margin: 0 auto;
  line-height: 1.65;
}

/* ── MOBILE ────────────────────────────────────────────────── */
@media (max-width: 640px) {
  .careers-modal-overlay {
    padding: 0;
    align-items: flex-end;
  }

  .careers-modal {
    max-width: 100%;
    max-height: 100vh;
    border-radius: 1.25rem 1.25rem 0 0;
    height: 92vh;
  }

  .careers-modal-overlay.is-active .careers-modal {
    transform: translateY(0) scale(1);
  }

  .careers-modal-header {
    padding: 1.25rem 1.25rem 1rem;
  }

  .careers-modal-title {
    font-size: 1.25rem;
  }

  .careers-modal-body {
    padding: 1.25rem;
  }

  .careers-modal-footer {
    padding: 1rem 1.25rem;
  }

  .careers-card {
    padding: 1.35rem;
  }
}

@media (min-width: 641px) and (max-width: 1023px) {
  .careers-modal {
    max-width: 640px;
    max-height: calc(100vh - 4rem);
  }
}

/* ── CAREER JOURNEY (Why Build Your Career With NTM?) ────────── */
.career-journey {
  position: relative;
  overflow: hidden;
  background: #ffffff;
  border-top: 1px solid #f1f5f9;
  padding: 4.5rem 0;
}

@media (min-width: 768px) {
  .career-journey { padding: 6rem 0; }
}

.career-journey-sub {
  color: #64748b;
  font-size: 1rem;
  line-height: 1.7;
}

@media (min-width: 768px) {
  .career-journey-sub { font-size: 1.125rem; }
}

/* Journey track: vertical rail on mobile, horizontal rail on desktop */
.journey-track {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 0;
  list-style: none;
  padding: 0;
  margin: 0;
  align-items: stretch;
}

@media (min-width: 640px) {
  .journey-track { grid-template-columns: repeat(2, 1fr); gap: 0; }
}

@media (min-width: 1024px) {
  .journey-track { grid-template-columns: repeat(4, 1fr); }
}

/* Connector rail */
.journey-track::before {
  content: '';
  position: absolute;
  background: rgba(0, 76, 137, 0.18);
}

@media (max-width: 639px) {
  .journey-track { padding-left: 0; }
  .journey-track::before { left: 50px; top: 1.75rem; bottom: 1.75rem; width: 2px; }
}

@media (min-width: 640px) and (max-width: 1023px) {
  .journey-track::before { display: none; }
}

@media (min-width: 1024px) {
  .journey-track::before { top: 52px; left: 1.5rem; right: 1.5rem; height: 2px; }
}

.journey-item {
  position: relative;
  display: flex;
  gap: 1.25rem;
  border-radius: 1rem;
  padding: 1.75rem 1.25rem;
  transition: transform 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
}

@media (min-width: 1024px) {
  .journey-item { flex-direction: column; gap: 0; align-items: center; text-align: center; padding: 0 1rem; height: 100%; }
  .journey-node { margin-top: 0; margin-bottom: 1.5rem; }
  .journey-content { padding-top: 0; width: 100%; }
}

.journey-item:hover {
  transform: translateY(-4px);
  background: #f8fafc;
  box-shadow: 0 10px 30px -10px rgba(0, 54, 100, 0.08);
}

/* Number medallion sitting on the rail */
.journey-node {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 9999px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border: 1px solid rgba(0, 76, 137, 0.32);
  color: #004C89;
  box-shadow: 0 8px 22px rgba(0, 54, 100, 0.12);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  position: relative;
  z-index: 1;
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease, color 0.3s ease;
}

.journey-item:hover .journey-node {
  background: #004C89;
  border-color: #004C89;
  color: #ffffff;
  box-shadow: 0 0 0 7px rgba(0, 76, 137, 0.14), 0 12px 28px rgba(0, 54, 100, 0.25);
  transform: translateY(-2px);
}

.journey-content {
  position: relative;
  flex: 1;
  min-width: 0;
  padding-top: 0.2rem;
}

/* Large ghost numeral anchoring each stage */
.journey-ghost {
  position: absolute;
  top: -0.4rem;
  right: -0.25rem;
  font-size: 4.25rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.02em;
  color: rgba(0, 54, 100, 0.08);
  user-select: none;
  pointer-events: none;
  transition: color 0.3s ease;
}

@media (min-width: 1024px) {
  .journey-ghost { display: none; }
}

.journey-item:hover .journey-ghost { color: rgba(0, 76, 137, 0.16); }

.journey-title {
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 0.65rem;
  color: #003664;
  font-weight: 800;
  font-size: 1.15rem;
  line-height: 1.35;
  margin: 0 0 0.6rem;
  padding-right: 3.25rem;
  min-height: 3.15rem;
}

@media (min-width: 1024px) {
  .journey-title { flex-direction: column; align-items: center; padding-right: 0; min-height: 5.6rem; gap: 0.75rem; }
  .journey-title svg { width: 1.5rem; height: 1.5rem; }
}

.journey-title svg {
  width: 1.35rem;
  height: 1.35rem;
  flex-shrink: 0;
  color: #004C89;
  transition: transform 0.3s ease, color 0.3s ease;
}

.journey-item:hover .journey-title svg {
  transform: translateX(3px) scale(1.08);
  color: #003664;
}

.journey-desc {
  color: #5b6470;
  font-size: 0.9rem;
  line-height: 1.75;
  margin: 0;
}

/* Screen-reader step prefix (numbers are aria-hidden visuals) */
.journey-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (prefers-reduced-motion: reduce) {
  .journey-item,
  .journey-node,
  .journey-title svg,
  .journey-ghost {
    transition: none !important;
  }
  .journey-item:hover,
  .journey-item:hover .journey-node {
    transform: none;
  }
}

