/* ==== Careers Page (scoped) ============================================= */

/* === Global heading centering for Careers === */
.page-career .section-title{
  display:block;
  width:100%;
  text-align:center;
  margin:0 auto 1rem;
}

/* (Optional) fine-tune common subtitle blocks under centered titles */
.page-career .section-subtitle,
.page-career .lead { text-align:center; }

/* === Stats strip === */
.career-facts {
  display:grid; grid-template-columns:repeat(4,minmax(0,1fr));
  gap:1rem; margin-block:3rem;
}
.career-facts .stat{
  position:relative; padding:1.25rem; border-radius:14px;
  background:var(--glass-bg,rgba(255,255,255,.08));
  box-shadow:0 1px 0 rgba(0,0,0,.06), inset 0 0 0 1px var(--line,rgba(26,32,44,.12));
  text-align:center;
  transition:transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s ease;
}
.career-facts .stat-value{
  font-size:clamp(1.75rem,2.5vw,2.5rem); font-weight:800;
  color:var(--accent-base,#A2EBCC)!important;
  display:inline-block; min-width:5.6ch;
  font-variant-numeric:tabular-nums; font-feature-settings:"tnum" 1;
}
.career-facts .stat-unit{ margin-left:.15rem; opacity:1; font-weight:800; color:var(--accent-base,#A2EBCC); }
.career-facts .stat-label{ display:block; margin-top:.25rem; color:var(--muted,#718096); }

/* === Why Mintarex === */
.career-why{ margin-block:4rem; }
.career-why .why-grid{ display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:1rem; }
.career-why .why-card{
  padding:1.25rem; border-radius:16px; background:var(--glass-bg,rgba(255,255,255,.08));
  backdrop-filter:blur(6px);
  box-shadow:0 1px 0 rgba(0,0,0,.06), inset 0 0 0 1px var(--line,rgba(26,32,44,.12));
  transition:transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s ease;
}
.career-why .why-card h3{ margin:0 0 .25rem; color:var(--ink,#1A202C); }

/* === Open roles === */
.career-roles{ margin-block:4rem; }

/* Center the whole header block while keeping filters tidy underneath on desktop */
.career-roles .roles-header{
  display:flex; flex-direction:column; align-items:center; justify-content:center;
  gap:.5rem; margin-bottom:1rem; text-align:center;
}

.role-filters{ display:flex; gap:.5rem; flex-wrap:wrap; justify-content:center; }
.role-filters .chip{
  border:1px solid var(--line,rgba(26,32,44,.12)); background:transparent; color:var(--ink,#1A202C);
  padding:.45rem .8rem; border-radius:999px; cursor:pointer;
  transition:transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.role-filters .chip:hover{ transform:translateY(-1px); }
.role-filters .chip.is-active{
  border-color:var(--accent-base,#A2EBCC);
  box-shadow:0 0 0 2px rgba(162,235,204,.25) inset;
}

/* grid + cards */
.roles-grid{ display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:1rem; }
.role-card{
  position:relative; padding:1.1rem 1.1rem 1rem; border-radius:16px;
  background:linear-gradient(180deg,rgba(162,235,204,.06),rgba(32,141,122,.04));
  box-shadow:0 1px 0 rgba(0,0,0,.06), inset 0 0 0 1px var(--line,rgba(26,32,44,.12));
  transition:transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s ease;
  display:flex; flex-direction:column;
  min-height:200px;
}
.role-card h3{ margin:.25rem 0 .35rem; color:var(--ink,#1A202C); }
.role-card p{ margin:0 0 .75rem; }
.role-card .meta{ display:flex; gap:.75rem; flex-wrap:wrap; color:var(--muted,#718096); margin-bottom:.75rem; }
.role-card .actions{
  margin-top:auto;
  display:flex; gap:.5rem; flex-wrap:wrap; align-items:center; justify-content:flex-start;
}
.role-card .actions .btn{
  display:inline-flex; align-items:center; justify-content:center;
  min-width:104px;
}

/* === Process === */
.career-process{ margin-block:4rem; }
.process-steps{
  display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:1rem;
  counter-reset:step; padding-left:0; list-style:none;
}
.process-steps li{
  position:relative; padding:1rem; border-radius:14px;
  background:var(--glass-bg,rgba(255,255,255,.08));
  box-shadow:inset 0 0 0 1px var(--line,rgba(26,32,44,.12));
  transition:transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s ease;
}
.process-steps .step-index{
  display:inline-grid; place-items:center; width:28px; height:28px; border-radius:50%;
  background:radial-gradient(90% 90% at 50% 50%, var(--accent-base,#A2EBCC), transparent);
  color:#0b1f1b; font-weight:800; margin-right:.4rem;
}

/* === Perks === */
.career-perks{ margin-block:4rem; }
.perks-grid{ display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:1rem; }
.perk{
  padding:1rem; border-radius:14px; background:var(--glass-bg,rgba(255,255,255,.08));
  box-shadow:inset 0 0 0 1px var(--line,rgba(26,32,44,.12));
  transition:transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s ease;
}
.perk h3{ margin:.1rem 0 .35rem; }

/* === FAQ === */
.career-faq{ margin-block:4rem; }

/* center FAQ title too (covered by the global selector) */
.career-faq .faq details{
  border-radius:14px; padding:.9rem 1rem; background:var(--glass-bg,rgba(255,255,255,.08));
  box-shadow:inset 0 0 0 1px var(--line,rgba(26,32,44,.12));
  transition:transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s ease;
}
.career-faq .faq details+details{ margin-top:.75rem; }
.career-faq .faq summary{ cursor:pointer; font-weight:600; }

/* === Apply modal (centered & responsive) === */
.apply-modal{
  position:fixed; inset:0; display:none; z-index:9999;
  padding:1rem; align-items:center; justify-content:center;
}
.apply-modal.is-open{ display:flex; }
.apply-backdrop{ position:absolute; inset:0; background:rgba(0,0,0,.45); }
.apply-panel{
  position:relative; width:min(640px,92vw); max-height:88vh; overflow:auto;
  background:#fff; color:#1A202C; border-radius:16px; padding:1rem 1rem 1.25rem;
  box-shadow:0 12px 40px rgba(0,0,0,.25), 0 0 0 1px rgba(26,32,44,.12) inset;
  overscroll-behavior:contain;
}
.apply-close{
  position:absolute; right:.75rem; top:.4rem; background:transparent; border:none; font-size:1.75rem; line-height:1; cursor:pointer;
  color:var(--accent-base,#A2EBCC);
}
.apply-close:hover{ filter:brightness(.95); }
.apply-form label{ display:block; font-weight:600; margin-top:.75rem; }
.apply-form input,.apply-form textarea{
  width:100%; margin-top:.35rem; padding:.65rem .7rem; border-radius:10px; border:1px solid rgba(26,32,44,.2);
  outline:0; transition:border-color .2s ease, box-shadow .2s ease;
}
.apply-form input:focus,.apply-form textarea:focus{
  border-color:var(--accent-base,#A2EBCC);
  box-shadow:0 0 0 3px rgba(162,235,204,.35);
}
.apply-form .form-actions{
  display:flex; gap:.5rem; margin-top:1rem; flex-wrap:wrap;
  justify-content:center;
}
.apply-form .form-actions .btn{ min-width:180px; justify-content:center; }

/* === Glass-morphism POP (re-usable hover) === */
.page-career .stat:hover,
.page-career .why-card:hover,
.page-career .role-card:hover,
.page-career .process-steps li:hover,
.page-career .perk:hover,
.page-career .career-faq .faq details:hover{
  transform:translateY(-2px);
  box-shadow:0 6px 22px rgba(0,0,0,.10), 0 0 0 1px rgba(26,32,44,.10) inset, 0 0 0 2px rgba(162,235,204,.15);
}

/* === Force primary buttons on careers (uses your tokenized primary) === */
.page-career .btn{
  background:var(--accent-base,#A2EBCC); color:#0b1f1b; border:none;
  box-shadow:0 8px 24px rgba(162,235,204,.35), 0 0 0 1px rgba(26,32,44,.10) inset;
}
.page-career .btn:hover{ filter:brightness(.95); transform:translateY(-1px); }
.page-career .btn:active{ transform:translateY(0); }

/* === Responsive — tablets down === */
@media (max-width:1024px){
  .career-facts{ grid-template-columns:repeat(2,1fr); }
  .career-why .why-grid{ grid-template-columns:repeat(2,1fr); }
  .roles-grid{ grid-template-columns:repeat(2,1fr); }
  .process-steps{ grid-template-columns:repeat(2,1fr); }
  .perks-grid{ grid-template-columns:repeat(2,1fr); }
}

/* === Responsive — phones === */
@media (max-width:640px){
  .career-facts{ grid-template-columns:1fr 1fr; }
  .career-facts .stat{ min-height:88px; }
  .career-why .why-grid{ grid-template-columns:1fr; }
  .roles-grid{ grid-template-columns:1fr; }
  .process-steps{ grid-template-columns:1fr; }
  .perks-grid{ grid-template-columns:1fr; }
  .role-card{ min-height:200px; }
  .career-roles .roles-header{ flex-direction:column; align-items:center; gap:.75rem; }
  .role-filters{ justify-content:center; }
  .apply-form .form-actions{ justify-content:center; }
  .apply-form .form-actions .btn{ flex:1 1 100%; min-width:0; }
}

/* === Ultra-small devices (JioPhone 2 & peers: 240–280px wide) ========= */
@media (max-width:280px){
  html, body { overflow-x:hidden; }
  .page-career .wrap{ padding-left:.6rem; padding-right:.6rem; }
  .page-career .hero .hero-content h1{ font-size:1.1rem; line-height:1.15; }
  .page-career .hero .hero-content .lead{ font-size:.8rem; }
  .career-facts{ gap:.6rem; }
  .career-facts .stat{ padding:.75rem; }
  .career-facts .stat-value{ min-width:auto; font-size:1.2rem; }
  .role-card{ min-height:auto; padding:.8rem; }
  .role-card h3{ font-size:1rem; }
  .role-card p{ font-size:.85rem; }
  .role-card .actions{ gap:.35rem; }
  .role-card .actions .btn{ min-width:84px; padding:.45rem .55rem; font-size:.85rem; }
  .role-filters .chip{ padding:.3rem .5rem; font-size:.8rem; }
  .perks-grid{ grid-template-columns:1fr; gap:.6rem; }
  .apply-panel{ width:95vw; border-radius:12px; padding:.75rem .75rem 1rem; }
  .apply-form .form-actions{ gap:.4rem; align-items:stretch; }
  .apply-form .form-actions .btn{ min-width:0; width:100%; }
  #backToTop{ right:.35rem; bottom:.35rem; width:36px; height:36px; }
}
@media (max-width:260px){
  .page-career .wrap{ padding-left:.5rem; padding-right:.5rem; }
  .role-card .actions .btn{ min-width:76px; }
  .career-roles .roles-header{ gap:.5rem; }
  .apply-panel{ width:96vw; }
}

/* height-guard for landscape microscreens */
@media (max-height:560px){ .apply-panel{ max-height:94vh; } }

/* --- NEW: apply form status line + loading + turnstile hide --- */
.apply-form .form-status{
  margin-top:.6rem;
  font-size:.95rem;
  line-height:1.3;
  min-height:1.1em;
  text-align: center;
}
.apply-form .form-status[data-tone="success"]{ color:#1f9d55; }
.apply-form .form-status[data-tone="error"]  { color:#c53030; }
.apply-form .form-status[data-tone="info"]   { color:#4a5568; }
.apply-form .is-loading{ opacity:.7; pointer-events:none; }

.cf-turnstile{ width:0; height:0; overflow:hidden; }
