/* =====================================================================
   Orchid University — Careers job board: category sections, opening
   cards, detail modal and the application form.
   ===================================================================== */

/* ---------- a category section ---------- */
.cr-cat { margin-top: clamp(38px, 5vw, 62px); }
.cr-cat:first-of-type { margin-top: 0; }
.cr-cat__h {
  display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap;
  padding-bottom: 12px; border-bottom: 2px solid var(--navy); margin-bottom: 6px;
}
.cr-cat__h h3 {
  font-family: 'aesthet-nova', 'Fraunces', serif; font-weight: 700; color: var(--navy);
  font-size: clamp(22px, 2.6vw, 30px); line-height: 1.1; margin: 0;
}
.cr-cat__n {
  font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  background: var(--pale-green-3, #e9f7e4); color: #1c7a2f; border-radius: 999px; padding: 5px 12px;
}
.cr-cat__blurb { color: var(--muted); font-size: 15px; margin: 12px 0 0; max-width: 70ch; }

/* ---------- opening card ---------- */
.cr-list { display: grid; gap: 14px; margin-top: 24px; }
.cr-job {
  border: 1px solid var(--line); border-radius: 16px; background: #fff; padding: 22px 24px;
  display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center;
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}
.cr-job:hover { border-color: var(--green); transform: translateY(-2px); box-shadow: 0 18px 34px -24px rgba(20,28,70,.45); }
/* Fade in on injection. An animation (not a JS-gated transition) always runs
   to completion, so a card can never be left invisible. */
@keyframes cr-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.cr-job { animation: cr-in .45s cubic-bezier(.2,.7,.2,1) both; }
.cr-list .cr-job:nth-child(2) { animation-delay: .06s; }
.cr-list .cr-job:nth-child(3) { animation-delay: .12s; }
.cr-list .cr-job:nth-child(4) { animation-delay: .18s; }
.cr-list .cr-job:nth-child(n+5) { animation-delay: .24s; }
@media (prefers-reduced-motion: reduce) { .cr-job { animation: none; } }
.cr-job__t {
  font-family: 'aesthet-nova', 'Fraunces', serif; font-weight: 700; color: var(--navy);
  font-size: clamp(18px, 1.8vw, 22px); line-height: 1.2; margin: 0 0 10px;
}
.cr-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.cr-meta span {
  font-size: 12.5px; font-weight: 600; color: #2b3350;
  background: #f4f6fa; border-radius: 7px; padding: 4px 10px;
}
.cr-meta .hot { background: var(--green); color: #fff; }
.cr-meta .walkin { background: #fdf3dd; color: #9a6a05; }
.cr-req { display: grid; gap: 6px; }
.cr-req div { font-size: 13.5px; color: var(--muted); line-height: 1.45; padding-left: 20px; position: relative; }
.cr-req div::before { content: ""; position: absolute; left: 0; top: 7px; width: 7px; height: 7px; border-radius: 50%; background: var(--green); }
.cr-req b { color: var(--navy); font-weight: 700; }
.cr-job__a { display: flex; flex-direction: column; gap: 9px; }
.cr-btn {
  border: none; border-radius: 11px; padding: 12px 22px; font: inherit; font-weight: 700; font-size: 14.5px;
  cursor: pointer; white-space: nowrap; text-decoration: none; text-align: center; transition: filter .15s ease, background .15s ease, color .15s ease;
}
.cr-btn.solid { background: var(--green); color: #fff; }
.cr-btn.solid:hover { filter: brightness(1.07); }
.cr-btn.ghost { background: #fff; color: var(--navy); border: 1.5px solid var(--line); }
.cr-btn.ghost:hover { border-color: var(--navy); }
.cr-empty { border: 1px dashed var(--line); border-radius: 16px; padding: 34px; text-align: center; color: var(--muted); }

/* ---------- detail modal ---------- */
.cr-modal {
  position: fixed; inset: 0; z-index: 3000; display: none;
  background: rgba(12,18,42,.55); backdrop-filter: blur(3px);
  padding: clamp(12px, 4vw, 46px); overflow: auto;
}
.cr-modal.open { display: block; }
.cr-modal__box {
  background: #fff; border-radius: 22px; max-width: 780px; margin: 0 auto;
  box-shadow: 0 40px 80px -30px rgba(10,16,40,.6); overflow: hidden;
}
.cr-modal__hd { padding: clamp(24px, 3vw, 36px); border-bottom: 1px solid var(--line); position: relative; }
.cr-modal__hd h3 {
  font-family: 'aesthet-nova', 'Fraunces', serif; font-weight: 700; color: var(--navy);
  font-size: clamp(22px, 3vw, 32px); line-height: 1.12; margin: 0 0 12px; padding-right: 44px;
}
.cr-modal__x {
  position: absolute; top: 20px; right: 20px; width: 36px; height: 36px; border-radius: 50%;
  border: 1px solid var(--line); background: #fff; cursor: pointer; font-size: 17px; color: var(--navy); line-height: 1;
}
.cr-modal__x:hover { border-color: var(--navy); }
.cr-modal__bd { padding: clamp(24px, 3vw, 36px); }
.cr-modal__bd h4 {
  font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--green); margin: 26px 0 12px;
}
.cr-modal__bd h4:first-child { margin-top: 0; }
.cr-modal__bd p { color: #2b3350; font-size: 15.5px; line-height: 1.7; margin: 0; }
.cr-modal__bd ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.cr-modal__bd li { font-size: 15px; color: #2b3350; line-height: 1.6; padding-left: 24px; position: relative; }
.cr-modal__bd li::before { content: ""; position: absolute; left: 0; top: 9px; width: 8px; height: 8px; border-radius: 50%; background: var(--green); }
.cr-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; }
.cr-facts div { background: var(--bg-warm, #F8F3F3); border-radius: 12px; padding: 14px 16px; }
.cr-facts .k { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.cr-facts .v { color: var(--navy); font-weight: 600; font-size: 14.5px; margin-top: 4px; line-height: 1.35; }
.cr-modal__ft {
  padding: 20px clamp(24px, 3vw, 36px); background: #f7f9fc; border-top: 1px solid var(--line);
  display: flex; gap: 12px; flex-wrap: wrap; align-items: center; justify-content: space-between;
}
.cr-modal__ft .note { font-size: 13px; color: var(--muted); }

/* ---------- application form ---------- */
.cr-form { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 26px; }
.cr-form .full { grid-column: 1 / -1; }
.cr-fld { display: grid; gap: 7px; }
.cr-fld label { font-size: 13px; font-weight: 700; color: var(--navy); }
.cr-fld label .req { color: #c8372d; }
.cr-fld input, .cr-fld select, .cr-fld textarea {
  border: 1.5px solid var(--line); border-radius: 11px; padding: 13px 15px; font: inherit; font-size: 15px;
  color: var(--navy); background: #fff; width: 100%;
}
.cr-fld textarea { min-height: 110px; resize: vertical; }
.cr-fld input:focus, .cr-fld select:focus, .cr-fld textarea:focus {
  outline: none; border-color: var(--green); box-shadow: 0 0 0 3px rgba(52,180,74,.15);
}
.cr-fld input[type=file] { padding: 11px; background: #fbfcfe; }
.cr-fld .hint { font-size: 12px; color: var(--muted); }
.cr-form__msg { grid-column: 1 / -1; border-radius: 12px; padding: 14px 18px; font-size: 14.5px; display: none; }
.cr-form__msg.err { display: block; background: #fdeceb; color: #a3271c; border: 1px solid #f3c4bf; }
.cr-form__msg.ok  { display: block; background: var(--pale-green-3, #e9f7e4); color: #1c7a2f; border: 1px solid #b9e4bd; }
.cr-hp { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }
.cr-ok {
  text-align: center; padding: 46px 30px; border: 1px solid var(--line); border-radius: 18px;
  background: var(--pale-green-3, #e9f7e4); margin-top: 26px;
}
.cr-ok .ic {
  width: 56px; height: 56px; border-radius: 50%; background: var(--green); color: #fff;
  display: grid; place-items: center; font-size: 26px; margin: 0 auto 16px;
}
.cr-ok h4 { font-family: 'aesthet-nova', serif; color: var(--navy); font-size: 24px; margin: 0 0 8px; }
.cr-ok p { color: #2b3350; margin: 0; font-size: 15px; }

@media (max-width: 760px) {
  .cr-job { grid-template-columns: 1fr; }
  .cr-job__a { flex-direction: row; }
  .cr-job__a .cr-btn { flex: 1; }
  .cr-form { grid-template-columns: 1fr; }
  .cr-modal__ft { flex-direction: column; align-items: stretch; }
  .cr-modal__ft .cr-btn { width: 100%; }
}
