/* ===== GOVI Careers — واجهة وظائف عصرية مستقلة تمامًا عن لوحة التحكم ===== */
/* ضمان احترام خاصية hidden (قواعد .cx-btn وغيرها تضبط display وتتجاوز قاعدة المتصفّح الافتراضية) */
[hidden] { display: none !important; }
:root {
  --c-primary: #4f46e5;
  --c-accent: #7c3aed;
  --c-cols: 3;
  --c-radius: 24px;
  --ink: #0b1020;
  --muted: #6b7280;
  --line: #eceef3;
  --bg: #fbfbfd;
  --card: #ffffff;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; font-family: 'Tajawal', system-ui, sans-serif; color: var(--ink);
  background: var(--bg); line-height: 1.6; -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.wrap { width: min(1180px, 92%); margin-inline: auto; }

/* ===== Header (glass) ===== */
.cx-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: saturate(180%) blur(14px);
  background: rgba(255,255,255,.72);
  border-bottom: 1px solid var(--line);
}
.cx-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.cx-brand { display: flex; align-items: center; gap: 12px; font-weight: 800; font-size: 1.15rem; }
.cx-brand img { height: 34px; width: auto; }
.cx-brand .logo-fallback {
  width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center;
  color: #fff; font-weight: 800; background: linear-gradient(135deg, var(--c-primary), var(--c-accent));
}
.cx-pill {
  font-size: .8rem; font-weight: 700; color: var(--c-primary);
  background: color-mix(in srgb, var(--c-primary) 12%, white);
  padding: 7px 14px; border-radius: 999px;
  display: inline-flex; align-items: center; gap: 7px;
}
.cx-pill .dot { width: 8px; height: 8px; border-radius: 50%; background: #16a34a; box-shadow: 0 0 0 4px rgba(22,163,74,.18); }

/* ===== Hero ===== */
.cx-hero { position: relative; overflow: hidden; padding: 86px 0 64px; text-align: center; }
.cx-hero.bg-mesh::before, .cx-hero.bg-gradient::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
}
.cx-hero.bg-mesh::before {
  background:
    radial-gradient(60% 60% at 18% 0%, color-mix(in srgb, var(--c-primary) 26%, transparent), transparent 60%),
    radial-gradient(50% 50% at 92% 12%, color-mix(in srgb, var(--c-accent) 24%, transparent), transparent 60%),
    radial-gradient(40% 40% at 50% 100%, color-mix(in srgb, var(--c-primary) 14%, transparent), transparent 70%);
}
.cx-hero.bg-gradient::before { background: linear-gradient(135deg, color-mix(in srgb, var(--c-primary) 16%, white), color-mix(in srgb, var(--c-accent) 14%, white)); }
.cx-hero h1 {
  font-size: clamp(2rem, 5vw, 3.4rem); font-weight: 900; letter-spacing: -.5px;
  margin: 0 0 14px; line-height: 1.15;
}
.cx-hero h1 .grad {
  background: linear-gradient(120deg, var(--c-primary), var(--c-accent));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.cx-hero p { font-size: clamp(1rem, 2vw, 1.25rem); color: var(--muted); margin: 0 auto; max-width: 620px; }
.cx-hero .count {
  margin-top: 28px; display: inline-flex; align-items: center; gap: 10px;
  background: var(--card); border: 1px solid var(--line); border-radius: 999px;
  padding: 10px 20px; font-weight: 700; box-shadow: 0 8px 30px rgba(16,24,64,.06);
}
.cx-hero .count b { color: var(--c-primary); font-size: 1.15rem; }

/* ===== Jobs grid ===== */
.cx-jobs { padding: 8px 0 80px; }
.cx-grid {
  display: grid; gap: 22px;
  grid-template-columns: repeat(var(--c-cols), minmax(0, 1fr));
}
@media (max-width: 1024px) { .cx-grid { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 640px)  { .cx-grid { grid-template-columns: 1fr; } }

.cx-card {
  position: relative; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--c-radius); padding: 26px;
  display: flex; flex-direction: column; gap: 14px;
  transition: transform .25s cubic-bezier(.2,.7,.2,1), box-shadow .25s, border-color .25s;
  overflow: hidden;
}
.cx-card::before {
  content: ""; position: absolute; inset-block-start: 0; inset-inline: 0; height: 4px;
  background: linear-gradient(90deg, var(--c-primary), var(--c-accent));
  transform: scaleX(0); transform-origin: inline-start; transition: transform .3s;
}
.cx-card:hover { transform: translateY(-6px); box-shadow: 0 24px 50px rgba(16,24,64,.12); border-color: transparent; }
.cx-card:hover::before { transform: scaleX(1); }
.style-glass .cx-card { background: rgba(255,255,255,.6); backdrop-filter: blur(8px); }
.style-outline .cx-card { box-shadow: none; }

.cx-card .top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.cx-card .ic {
  width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center;
  color: var(--c-primary); background: color-mix(in srgb, var(--c-primary) 10%, white); font-size: 1.4rem;
}
.cx-card h3 { font-size: 1.25rem; font-weight: 800; margin: 0; }
.cx-card .en { color: var(--muted); font-size: .85rem; font-weight: 500; direction: ltr; text-align: start; }
.cx-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.cx-chip {
  font-size: .8rem; font-weight: 600; color: #475569;
  background: #f4f5fa; border-radius: 999px; padding: 6px 12px;
  display: inline-flex; align-items: center; gap: 6px;
}
.cx-card .salary { font-weight: 800; color: var(--ink); }
.cx-card .salary span { color: var(--muted); font-weight: 600; font-size: .85rem; }
.cx-card .foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; padding-top: 8px; border-top: 1px solid var(--line); }
.cx-card .date { color: var(--muted); font-size: .8rem; }

.cx-btn {
  display: inline-flex; align-items: center; gap: 8px; cursor: pointer; border: 0;
  font-family: inherit; font-weight: 800; font-size: .95rem; color: #fff;
  background: linear-gradient(120deg, var(--c-primary), var(--c-accent));
  padding: 12px 22px; border-radius: 999px;
  transition: transform .2s, box-shadow .2s, filter .2s;
  box-shadow: 0 10px 24px color-mix(in srgb, var(--c-primary) 35%, transparent);
}
.cx-btn:hover { transform: translateY(-2px); filter: brightness(1.05); }
.cx-btn.sm { padding: 9px 18px; font-size: .85rem; }
.cx-btn.ghost { background: transparent; color: var(--c-primary); box-shadow: none; border: 1.5px solid color-mix(in srgb, var(--c-primary) 30%, white); }

/* ===== Empty ===== */
.cx-empty { text-align: center; padding: 90px 0; color: var(--muted); }
.cx-empty .big { font-size: 3rem; margin-bottom: 8px; }

/* ===== Detail ===== */
.cx-detail { padding: 40px 0 80px; }
.cx-back { color: var(--muted); font-weight: 700; display: inline-flex; gap: 6px; margin-bottom: 22px; }
.cx-layout { display: grid; grid-template-columns: 1fr 380px; gap: 28px; align-items: start; }
@media (max-width: 900px) { .cx-layout { grid-template-columns: 1fr; } }
.cx-panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--c-radius); padding: 30px; }
.cx-panel h1 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); font-weight: 900; margin: 0 0 6px; }
.cx-panel .sec { margin-top: 26px; }
.cx-panel .sec h4 { font-size: 1.05rem; font-weight: 800; margin: 0 0 12px; display: flex; align-items: center; gap: 8px; }
.cx-panel .sec h4::before { content: ""; width: 5px; height: 18px; border-radius: 3px; background: linear-gradient(var(--c-primary), var(--c-accent)); }
.cx-panel p, .cx-panel li { color: #374151; }
.cx-prose { white-space: pre-line; }
.cx-tags { display: flex; flex-wrap: wrap; gap: 8px; }

.cx-apply { position: sticky; top: 92px; background: var(--card); border: 1px solid var(--line); border-radius: var(--c-radius); padding: 26px; box-shadow: 0 16px 50px rgba(16,24,64,.08); }
.cx-apply h3 { margin: 0 0 4px; font-weight: 900; font-size: 1.3rem; }
.cx-apply .sub { color: var(--muted); margin: 0 0 18px; font-size: .9rem; }
.cx-field { margin-bottom: 14px; }
.cx-field label { display: block; font-weight: 700; font-size: .85rem; margin-bottom: 6px; }
.cx-input, .cx-textarea {
  width: 100%; font-family: inherit; font-size: .95rem; color: var(--ink);
  background: #f7f8fc; border: 1.5px solid transparent; border-radius: 14px; padding: 12px 14px;
  transition: border-color .2s, background .2s;
}
.cx-input:focus, .cx-textarea:focus { outline: none; background: #fff; border-color: var(--c-primary); }
.cx-textarea { resize: vertical; min-height: 96px; }
.cx-file {
  border: 1.5px dashed #cdd2e0; border-radius: 14px; padding: 16px; text-align: center;
  color: var(--muted); cursor: pointer; transition: border-color .2s, background .2s; font-size: .88rem;
}
.cx-file:hover { border-color: var(--c-primary); background: color-mix(in srgb, var(--c-primary) 5%, white); }
.cx-file input { display: none; }
.cx-err { color: #e11d48; font-size: .8rem; margin-top: 5px; }
.cx-success {
  background: color-mix(in srgb, #16a34a 10%, white); color: #15803d; border: 1px solid color-mix(in srgb,#16a34a 25%, white);
  border-radius: 16px; padding: 22px; text-align: center; font-weight: 700;
}
.cx-success .big { font-size: 2.4rem; }

/* ===== Footer ===== */
.cx-footer { background: #0b1020; color: #b9c0d4; padding: 40px 0; margin-top: 40px; }
.cx-footer .wrap { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 14px; }
.cx-footer a { color: #fff; font-weight: 700; }
.cx-footer .muted { font-size: .85rem; }

/* ===== Nav ===== */
.cx-nav { display: flex; align-items: center; gap: 22px; }
.cx-nav a { font-weight: 700; color: #4b5563; transition: color .2s; }
.cx-nav a:hover, .cx-nav a.on { color: var(--c-primary); }
.cx-nav a.cx-btn { color: #fff; }
@media (max-width: 640px) { .cx-nav a:not(.cx-btn) { display: none; } }

/* ===== Hero search ===== */
.cx-search {
  margin: 30px auto 0; max-width: 640px; display: flex; align-items: center; gap: 8px;
  background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 8px 8px 8px 18px;
  box-shadow: 0 18px 50px rgba(16,24,64,.10);
}
.cx-search .ic { font-size: 1.1rem; opacity: .6; }
.cx-search input { flex: 1; border: 0; outline: none; font-family: inherit; font-size: 1rem; background: transparent; color: var(--ink); }

/* ===== Stats band ===== */
.cx-stats {
  margin-top: -34px; position: relative; z-index: 2; background: var(--card);
  border: 1px solid var(--line); border-radius: var(--c-radius);
  box-shadow: 0 20px 50px rgba(16,24,64,.08);
  display: grid; grid-template-columns: repeat(3, 1fr); padding: 26px;
}
.cx-stat { text-align: center; border-inline-end: 1px solid var(--line); }
.cx-stat:last-child { border-inline-end: 0; }
.cx-stat b { display: block; font-size: 2.2rem; font-weight: 900; color: var(--c-primary); line-height: 1; }
.cx-stat span { color: var(--muted); font-weight: 600; font-size: .9rem; }
@media (max-width: 560px) { .cx-stat b { font-size: 1.6rem; } }

/* ===== Sections ===== */
.cx-section { padding: 64px 0 8px; }
.cx-section-head { text-align: center; margin-bottom: 36px; }
.cx-section-head.row { display: flex; align-items: center; justify-content: space-between; text-align: start; }
.cx-section-head h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); font-weight: 900; margin: 0 0 8px; }
.cx-section-head p { color: var(--muted); margin: 0; }

/* Value props */
.cx-vp { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
@media (max-width: 820px) { .cx-vp { grid-template-columns: 1fr; } }
.cx-vp-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--c-radius);
  padding: 30px; text-align: center; transition: transform .25s, box-shadow .25s;
}
.cx-vp-card:hover { transform: translateY(-5px); box-shadow: 0 22px 46px rgba(16,24,64,.10); }
.cx-vp-card .emoji {
  width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 18px; display: grid; place-items: center;
  font-size: 1.8rem; background: linear-gradient(135deg, color-mix(in srgb, var(--c-primary) 14%, white), color-mix(in srgb, var(--c-accent) 14%, white));
}
.cx-vp-card h3 { font-size: 1.2rem; font-weight: 800; margin: 0 0 8px; }
.cx-vp-card p { color: var(--muted); margin: 0; }

/* CTA */
.cx-cta {
  margin: 56px 0 0; border-radius: var(--c-radius); padding: 54px 30px; text-align: center; color: #fff;
  background: linear-gradient(120deg, var(--c-primary), var(--c-accent)); position: relative; overflow: hidden;
}
.cx-cta h2 { font-size: clamp(1.5rem, 3.4vw, 2.3rem); font-weight: 900; margin: 0 0 10px; }
.cx-cta p { opacity: .92; margin: 0 0 24px; font-size: 1.05rem; }
.cx-cta .cx-btn { background: #fff; color: var(--c-primary); }

/* ===== Results page ===== */
.cx-results-hero { padding: 56px 0 40px; text-align: center; position: relative; overflow: hidden; }
.cx-results-hero h1 { font-size: clamp(1.7rem, 4vw, 2.6rem); font-weight: 900; margin: 0 0 18px; }
.cx-search-layout { display: grid; grid-template-columns: 290px 1fr; gap: 26px; padding: 36px 0 80px; align-items: start; }
@media (max-width: 860px) { .cx-search-layout { grid-template-columns: 1fr; } }

.cx-filters { position: sticky; top: 92px; background: var(--card); border: 1px solid var(--line); border-radius: var(--c-radius); padding: 22px; }
@media (max-width: 860px) { .cx-filters { position: static; } }
.cx-filters-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.cx-filters-head h3 { margin: 0; font-size: 1.05rem; font-weight: 800; }
.cx-filters-head .clear { color: #e11d48; font-weight: 700; font-size: .82rem; }
.cx-filter { margin-bottom: 16px; }
.cx-filter label { display: block; font-weight: 700; font-size: .82rem; margin-bottom: 6px; color: #374151; }
.cx-filter select, .sortform select {
  width: 100%; font-family: inherit; font-size: .92rem; color: var(--ink); cursor: pointer;
  background: #f7f8fc; border: 1.5px solid transparent; border-radius: 12px; padding: 11px 12px; transition: border-color .2s;
}
.cx-filter select:focus, .sortform select:focus { outline: none; border-color: var(--c-primary); background: #fff; }

.cx-results-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.cx-results-bar .count { font-weight: 700; color: var(--ink); }
.cx-results-bar .count b { color: var(--c-primary); font-size: 1.2rem; }
.sortform { display: flex; align-items: center; gap: 8px; }
.sortform label { color: var(--muted); font-weight: 700; font-size: .85rem; }
.sortform select { width: auto; }
.cx-grid.results { grid-template-columns: repeat(2, minmax(0,1fr)); }
@media (max-width: 640px) { .cx-grid.results { grid-template-columns: 1fr; } }

/* Pager */
.cx-pager { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 36px; }
.cx-pager a { font-weight: 800; color: var(--c-primary); padding: 10px 18px; border-radius: 12px; border: 1.5px solid color-mix(in srgb, var(--c-primary) 25%, white); transition: background .2s; }
.cx-pager a:hover { background: color-mix(in srgb, var(--c-primary) 8%, white); }
.cx-pager a.off { color: #cbd1de; border-color: var(--line); pointer-events: none; }
.cx-pager .meta { color: var(--muted); font-weight: 700; font-size: .9rem; }

/* ===== Language toggle ===== */
.cx-lang {
  font-weight: 800; font-size: .82rem; color: var(--c-primary);
  border: 1.5px solid color-mix(in srgb, var(--c-primary) 30%, white);
  border-radius: 999px; padding: 6px 13px; transition: background .2s;
}
.cx-lang:hover { background: color-mix(in srgb, var(--c-primary) 8%, white); }

/* ===== Contact page ===== */
.cx-contact { padding: 40px 0 80px; }
.cx-contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: start; }
@media (max-width: 820px) { .cx-contact-grid { grid-template-columns: 1fr; } }
.cx-contact-info { background: linear-gradient(135deg, var(--c-primary), var(--c-accent)); color: #fff; border-radius: var(--c-radius); padding: 36px; }
.cx-contact-info h2 { font-size: 1.8rem; font-weight: 900; margin: 0 0 12px; }
.cx-contact-info p { opacity: .92; margin: 0 0 22px; }
.cx-contact-info .line { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; font-weight: 600; }
.cx-contact-info .line .em { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: rgba(255,255,255,.18); font-size: 1.2rem; }

/* ===== Bullets (job duties) ===== */
.cx-bullets { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.cx-bullets li { position: relative; padding-inline-start: 26px; color: #374151; line-height: 1.7; }
.cx-bullets li::before {
  content: ""; position: absolute; inset-inline-start: 4px; top: 10px; width: 9px; height: 9px;
  border-radius: 50%; background: linear-gradient(135deg, var(--c-primary), var(--c-accent));
}

/* ===== Candidate account / wizard ===== */
.cx-account { padding: 36px 0 80px; }
.cx-wizard { max-width: 720px; margin-inline: auto; background: var(--card); border: 1px solid var(--line); border-radius: var(--c-radius); padding: 32px; box-shadow: 0 16px 50px rgba(16,24,64,.06); }
.cx-steps { display: flex; gap: 8px; margin-bottom: 26px; }
.cx-step { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; position: relative; opacity: .5; transition: opacity .25s; }
.cx-step.on { opacity: 1; }
.cx-step .n { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; background: #eef0f6; color: var(--muted); }
.cx-step.on .n { background: linear-gradient(135deg, var(--c-primary), var(--c-accent)); color: #fff; }
.cx-step .t { font-size: .78rem; font-weight: 700; color: var(--muted); text-align: center; }
.cx-step.on .t { color: var(--ink); }
.cx-pane { border: 0; padding: 0; margin: 0; }
.cx-wizard-nav { display: flex; gap: 10px; justify-content: space-between; margin-top: 22px; }
.cx-wizard-nav .cx-btn { flex: 1; justify-content: center; }
.cx-account .cx-input, .cx-account select.cx-input { width: 100%; }

/* ===== Wizard rows / repeaters ===== */
.cx-row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .cx-row2 { grid-template-columns: 1fr; } }
.opt { color: var(--muted); font-weight: 500; font-size: .8rem; }
.cx-rep { margin-bottom: 16px; }
.cx-rep-label { display: block; font-weight: 700; font-size: .85rem; margin-bottom: 8px; }
.cx-rep-rows { display: flex; flex-direction: column; gap: 8px; }
.cx-rep-row { display: flex; gap: 8px; align-items: center; }
.cx-rep-row .cx-input { flex: 1; }
.cx-rep-del { width: 40px; height: 44px; flex-shrink: 0; border: 0; border-radius: 12px; cursor: pointer; font-size: 1.3rem; font-weight: 800; background: color-mix(in srgb, #e11d48 12%, white); color: #e11d48; }
.cx-rep-del:hover { background: color-mix(in srgb, #e11d48 20%, white); }
.cx-rep-add { margin-top: 8px; border: 1.5px dashed color-mix(in srgb, var(--c-primary) 35%, white); background: transparent; color: var(--c-primary); font-weight: 700; font-family: inherit; border-radius: 12px; padding: 9px 16px; cursor: pointer; }
.cx-rep-add:hover { background: color-mix(in srgb, var(--c-primary) 6%, white); }

/* ===== Jobs table ===== */
.cx-table-wrap { background: var(--card); border: 1px solid var(--line); border-radius: var(--c-radius); overflow: hidden; }
.cx-table { width: 100%; border-collapse: collapse; }
.cx-table thead th { text-align: start; font-size: .78rem; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .3px; padding: 16px 18px; background: #fafbfe; border-bottom: 1px solid var(--line); }
.cx-table tbody td { padding: 16px 18px; border-bottom: 1px solid var(--line); color: #475569; font-size: .92rem; vertical-align: middle; }
.cx-table tbody tr { cursor: pointer; transition: background .15s; }
.cx-table tbody tr:hover { background: color-mix(in srgb, var(--c-primary) 4%, white); }
.cx-table tbody tr:last-child td { border-bottom: 0; }
.cx-table .t-title { font-weight: 800; color: var(--ink); font-size: 1rem; }
.cx-table .t-sub { color: var(--c-primary); font-weight: 700; font-size: .82rem; margin-top: 3px; }
.cx-table .t-act { text-align: end; white-space: nowrap; }
@media (max-width: 760px) { .cx-table thead { display: none; } .cx-table tbody td { display: block; padding: 6px 16px; border: 0; } .cx-table tbody tr { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); } .cx-table .t-act { text-align: start; padding-top: 10px; } }
