/* ============================================================
   HireXpert — Human Resources & Recruiting Website
   Placeholder brand styling. All colors/fonts easy to change.
   ============================================================ */

/* ---------- Design tokens (edit these to rebrand) ---------- */
:root {
  --accent:       #0847b6;   /* main brand blue */
  --accent-dark:  #062f7c;   /* darker blue */
  --accent-soft:  #eaf1fd;   /* very light blue background */
  --accent-mid:   #dbe7fb;
  --ink:          #16213b;   /* headings */
  --text:         #5b6478;   /* body text */
  --muted:        #8a93a8;
  --line:         #e6eaf2;   /* hairlines */
  --bg:           #ffffff;
  --bg-soft:      #f7f9fc;   /* light section background */
  --gold:         #f5a818;   /* rating stars / highlights */
  --success:      #1f9d61;
  --radius:       14px;
  --shadow:       0 18px 45px rgba(22, 33, 59, 0.08);
  --shadow-sm:    0 8px 22px rgba(22, 33, 59, 0.07);
  --font-head:    "Jost", "Segoe UI", Arial, sans-serif;
  --font-body:    "Inter", "Segoe UI", Arial, sans-serif;
}

/* ---------- Reset & base ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.18;
  font-weight: 600;
}

img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
ul { list-style: none; }

.wrap {
  width: min(1200px, 92%);
  margin: 0 auto;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.4px;
  padding: 14px 30px;
  border-radius: 60px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.25s ease;
  text-decoration: none;
}
.btn .arr { font-size: 1.05rem; line-height: 1; transition: transform 0.25s ease; }
.btn:hover .arr { transform: translateX(5px); }

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

.btn-outline { background: transparent; color: #fff; border-color: rgba(255,255,255,0.65); }
.btn-outline:hover { background: #fff; color: var(--accentDark, var(--accent-dark)); border-color: #fff; }

.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: var(--accent); }

/* ---------- Section scaffolding ---------- */
.section { padding: 96px 0; }
.section--soft { background: var(--bg-soft); }

.section-head { text-align: center; max-width: 680px; margin: 0 auto 56px; }
.section-head .kicker {
  display: inline-block;
  font-family: var(--font-head);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 3px;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 14px;
}
.section-head h2 { font-size: clamp(1.8rem, 3.4vw, 2.7rem); }
.section-head p { margin-top: 14px; }

/* ---------- Top utility bar ---------- */
.topbar {
  background: var(--ink);
  color: #cbd4e4;
  font-size: 0.85rem;
}
.topbar .wrap { display: flex; justify-content: flex-end; align-items: center; padding: 9px 0; }
.topbar a { color: #fff; }
.topbar .tb-left, .topbar .tb-right { display: flex; align-items: center; gap: 8px; }
.topbar .dot { color: var(--accent-mid); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #fff;
  box-shadow: 0 4px 20px rgba(22,33,59,0.06);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 16px 0; gap: 24px; }

.logo { display: flex; align-items: center; gap: 11px; font-family: var(--font-head); font-weight: 700; font-size: 1.5rem; color: var(--ink); text-decoration: none; }
.logo .mark {
  width: 42px; height: 42px; border-radius: 12px;
  background: linear-gradient(135deg, #2a6cf0 0%, var(--accent) 55%, var(--accent-dark) 100%);
  color: #fff; display: grid; place-items: center;
  font-size: 1.35rem; font-weight: 700; line-height: 1; letter-spacing: 0;
  box-shadow: 0 6px 16px rgba(8, 71, 182, 0.32), inset 0 1px 0 rgba(255,255,255,0.28);
  border: 1px solid rgba(255,255,255,0.18);
}
/* The brand icon inside the logo square (Font Awesome briefcase by default). */
.logo .mark i { font-size: 1.15rem; line-height: 1; }
.logo span b { color: var(--accent); }

.main-nav ul { display: flex; gap: 30px; }
.main-nav a {
  font-family: var(--font-head); font-weight: 500; font-size: 0.98rem; color: var(--ink);
  padding: 6px 0; position: relative;
}
.main-nav a::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 0;
  background: var(--accent); transition: width 0.25s ease;
}
.main-nav a:hover::after, .main-nav a.active::after { width: 100%; }
.main-nav a.active, .main-nav a:hover { color: var(--accent); }

.header-actions { display: flex; align-items: center; gap: 16px; }
.signed-in-email {
  font-size: 0.95rem; font-weight: 600; color: var(--ink); white-space: nowrap;
  max-width: 220px; overflow: hidden; text-overflow: ellipsis;
}
.search-toggle {
  background: none; border: none; cursor: pointer; font-size: 1.15rem; color: var(--ink);
  padding: 6px; border-radius: 8px;
}
.search-toggle:hover { color: var(--accent); }
.btn-touch { padding: 12px 26px; font-size: 0.9rem; }

/* Mobile nav */
.nav-toggle {
  display: none; flex-direction: column; gap: 5px; cursor: pointer; background: none; border: none;
}
.nav-toggle span { width: 26px; height: 3px; background: var(--ink); border-radius: 2px; transition: 0.3s; }

/* Search overlay */
.search-overlay {
  position: fixed; inset: 0; background: rgba(15,23,42,0.95); z-index: 100;
  display: none; align-items: center; justify-content: center;
}
.search-overlay.open { display: flex; }
.search-overlay form { width: min(640px, 90%); display: flex; }
.search-overlay input {
  flex: 1; padding: 18px 22px; font-size: 1.1rem; border: none; border-radius: 12px 0 0 12px; outline: none;
}
.search-overlay button {
  padding: 0 26px; border: none; border-radius: 0 12px 12px 0; background: var(--accent); color: #fff;
  font-family: var(--font-head); font-weight: 600; cursor: pointer;
}
.search-close {
  position: absolute; top: 28px; right: 34px; background: none; border: none; color: #fff; font-size: 2rem; cursor: pointer;
}

/* ---------- Hero (Home 2 style: tall banner slider) ---------- */
.hero {
  position: relative;
  background:
    linear-gradient(120deg, rgba(8,71,182,0.92), rgba(6,47,124,0.94)),
    url("../images/hero-bg.jpg") center/cover no-repeat;
  color: #fff;
  padding: 120px 0 150px;
  overflow: hidden;
}
.hero-slides { position: relative; }
.hero-slide {
  position: absolute; inset: 0; opacity: 0; pointer-events: none;
  transition: opacity 0.9s ease, transform 0.9s ease;
}
.hero-slide.active { opacity: 1; pointer-events: auto; position: relative; }
/* ---- Per-transition motion (chosen in the Admin panel) ----
   The hero carries data-hero-transition="fade | slide | zoom | fade_slide".
   Fade is the default look and stays as-is; the others add a transform so
   the pictures also move on top of the fade. All are pure visual changes on
   the absolutely layered slides (no layout effect). */
.hero[data-hero-transition="slide"] .hero-slide {
  transform: translateX(100%);
}
.hero[data-hero-transition="slide"] .hero-slide.active {
  transform: translateX(0);
}
.hero[data-hero-transition="zoom"] .hero-slide {
  transform: scale(0.8);
}
.hero[data-hero-transition="zoom"] .hero-slide.active {
  transform: scale(1);
}
.hero[data-hero-transition="fade_slide"] .hero-slide {
  transform: translateX(48px);
}
.hero[data-hero-transition="fade_slide"] .hero-slide.active {
  transform: translateX(0);
}
/* ---- Banner photos on the hero (set per-slide in the Admin panel) ----
   Only active when at least one slide has a photo: content.js adds
   "has-photo-slides" to the hero. The hero then has a fixed height, the
   slides layer absolutely on top of one another, and the built-in opacity
   transition fades each photo into the next. Without any photo, none of
   this applies and the hero looks exactly as before. */
.hero.has-photo-slides { min-height: 780px; }
.hero.has-photo-slides .hero-slides { position: absolute; inset: 0; }
.hero.has-photo-slides .hero-slide { position: absolute; inset: 0; }
.hero-slide.has-photo {
  background-size: cover;
  background-position: center;
}
.hero-slide.has-photo::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(120deg,
    rgba(8, 47, 120, 0.84) 0%,
    rgba(6, 47, 124, 0.74) 45%,
    rgba(6, 31, 84, 0.58) 100%);
  z-index: 1;
}
.hero.has-photo-slides .hero-slide .wrap {
  position: relative; z-index: 2;
  height: 100%;
  display: flex; flex-direction: column; justify-content: center;
}
.hero .wrap { position: relative; z-index: 2; }
.hero .kicker {
  display: inline-block; font-size: 0.8rem; letter-spacing: 3px; text-transform: uppercase;
  color: #cfe0ff; background: rgba(255,255,255,0.12); border: 1px solid rgba(255,255,255,0.25);
  padding: 8px 16px; border-radius: 40px; margin-bottom: 22px; font-family: var(--font-head); font-weight: 600;
}
.hero h1 {
  color: #fff; font-size: clamp(2.3rem, 5.4vw, 4.2rem); font-weight: 700;
  max-width: 760px;
}
.hero p { margin: 22px 0 34px; max-width: 560px; font-size: 1.08rem; color: #e6eeff; }
.hero-btns { display: flex; gap: 16px; flex-wrap: wrap; }

.hero-deco {
  position: absolute; right: 5%; bottom: 0; width: 320px; opacity: 0.5; z-index: 1;
}

/* Hero slider arrows + dots */
.hero-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 6;
  width: 52px; height: 52px; border-radius: 50%; border: 1px solid rgba(255,255,255,0.35);
  background: rgba(255,255,255,0.08); color: #fff; font-size: 1.6rem; line-height: 1;
  cursor: pointer; display: grid; place-items: center; transition: background 0.3s ease, border-color 0.3s ease;
}
.hero-arrow.prev { left: 22px; }
.hero-arrow.next { right: 22px; }
.hero-arrow:hover { background: var(--accent); border-color: var(--accent); }

.hero-dots {
  position: absolute; left: 0; right: 0; bottom: 46px; z-index: 6;
  display: flex; justify-content: center; gap: 10px;
}
.hero-dots button {
  width: 12px; height: 12px; border-radius: 50%; border: none; cursor: pointer;
  background: rgba(255,255,255,0.35); transition: background 0.3s ease, transform 0.3s ease;
}
.hero-dots button.active { background: #fff; transform: scale(1.25); }

.hero-scroll-cue {
  position: absolute; left: 50%; bottom: 44px; transform: translateX(-50%); z-index: 6;
  font-size: 0.75rem; letter-spacing: 3px; text-transform: uppercase; color: #cfe0ff;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.hero-scroll-cue::after {
  content: ""; width: 2px; height: 30px; background: linear-gradient(#fff, transparent);
  animation: scrollBounce 2s ease-in-out infinite;
}
@keyframes scrollBounce {
  0%, 100% { transform: scaleY(0.6); opacity: 0.4; }
  50% { transform: scaleY(1); opacity: 1; }
}

/* Hero slide content entrance animation (restart on each slide change) */
.hero-slide.active .kicker { animation: fadeUp 0.8s ease both; }
.hero-slide.active h1     { animation: fadeUp 0.9s ease 0.12s both; }
.hero-slide.active p      { animation: fadeUp 0.9s ease 0.24s both; }
.hero-slide.active .hero-btns { animation: fadeUp 0.9s ease 0.36s both; }
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- Feature quick boxes ---------- */
.features { margin-top: 30px; position: relative; z-index: 5; }
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.feature-card {
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 30px; display: flex; gap: 18px; align-items: flex-start;
  border-bottom: 3px solid transparent; transition: 0.25s ease; position: relative;
}
.feature-card:hover { transform: translateY(-6px); border-bottom-color: var(--accent); }
.feature-card .ico {
  flex: 0 0 54px; height: 54px; border-radius: 14px;
  background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center; font-size: 1.5rem;
}
.feature-card h5 { font-size: 1.08rem; margin-bottom: 6px; }
.feature-card p { font-size: 0.92rem; }
.feature-card a { position: absolute; right: 26px; bottom: 26px; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-soft); color: var(--ink); transition: 0.25s; }
.feature-card a:hover { background: var(--accent); color: #fff; }

/* ---------- About ---------- */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.about-media { position: relative; }
.about-media .main-img { border-radius: var(--radius); box-shadow: var(--shadow); }
.about-badge {
  position: absolute; bottom: -26px; left: 30px; background: var(--accent); color: #fff;
  padding: 20px 26px; border-radius: 14px; box-shadow: var(--shadow); display: flex; align-items: center; gap: 14px;
}
.about-badge b { font-family: var(--font-head); font-size: 1.9rem; line-height: 1; }
.about-badge span { font-size: 0.85rem; opacity: 0.9; }

.about-text .kicker { color: var(--accent); font-weight: 600; letter-spacing: 3px; text-transform: uppercase; font-size: 0.8rem; display: block; margin-bottom: 12px; font-family: var(--font-head); }
.about-text h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); margin-bottom: 16px; }
.about-text > p { margin-bottom: 22px; }

.about-features { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 26px 0 34px; }
.about-feature { display: flex; gap: 12px; align-items: flex-start; }
.about-feature .ico { flex: 0 0 42px; height: 42px; border-radius: 11px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-size: 1.15rem; }
.about-feature b { color: var(--ink); font-family: var(--font-head); display: block; margin-bottom: 2px; }
.about-feature p { font-size: 0.9rem; }

.check-list { margin: 22px 0 30px; }
.check-list li { position: relative; padding-left: 32px; margin-bottom: 12px; font-size: 0.98rem; }
.check-list li::before {
  content: "\f00c"; position: absolute; left: 0; top: 0; width: 22px; height: 22px;
  background: var(--accent); color: #fff; border-radius: 50%; font-size: 0.7rem;
  font-family: "Font Awesome 6 Free"; font-weight: 900; line-height: 1;
  display: grid; place-items: center;
}

/* ---------- Services (cards) ---------- */
.services-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; }
.service-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 34px 28px;
  transition: 0.28s ease; position: relative; overflow: hidden;
}
.service-card::before {
  content: ""; position: absolute; inset: 0; background: linear-gradient(160deg, var(--accent), var(--accent-dark));
  opacity: 0; transition: 0.28s ease; z-index: 0;
}
.service-card > * { position: relative; z-index: 1; }
.service-card:hover { transform: translateY(-8px); box-shadow: var(--shadow); border-color: transparent; }
.service-card:hover::before { opacity: 1; }
.service-card:hover h4, .service-card:hover p, .service-card:hover .more { color: #fff; }
.service-card .ico { width: 62px; height: 62px; border-radius: 16px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-size: 1.6rem; margin-bottom: 22px; }
.service-card h4 { font-size: 1.12rem; margin-bottom: 10px; }
.service-card p { font-size: 0.92rem; margin-bottom: 18px; }
.service-card .more { font-family: var(--font-head); font-weight: 600; font-size: 0.86rem; color: var(--accent); display: inline-flex; align-items: center; gap: 8px; }
.service-card .more .arr { transition: transform 0.25s ease; }
.service-card:hover .more .arr { transform: translateX(5px); }

/* ---------- Support CTA band ---------- */
.support-band { background: var(--accent); color: #fff; }
.support-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap; padding: 54px 0;
}
.support-inner .kicker { text-transform: uppercase; letter-spacing: 3px; font-size: 0.75rem; color: #d7e4ff; margin-bottom: 8px; font-family: var(--font-head); font-weight: 600; }
.support-inner h3 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.2rem); }
.support-contacts { display: flex; gap: 30px; flex-wrap: wrap; }
.support-contacts .sc { display: flex; align-items: center; gap: 12px; }
.support-contacts .ico { width: 48px; height: 48px; border-radius: 12px; background: rgba(255,255,255,0.15); display: grid; place-items: center; font-size: 1.2rem; }
.support-contacts span { display: block; font-size: 0.78rem; color: #d7e4ff; text-transform: uppercase; letter-spacing: 1px; }
.support-contacts b { color: #fff; font-family: var(--font-head); font-size: 1.1rem; }

/* ---------- Why choose us ---------- */
.why-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: center; }
.why-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.why-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; transition: 0.25s; }
.why-card:hover { box-shadow: var(--shadow-sm); transform: translateY(-4px); }
.why-card .ico { width: 52px; height: 52px; border-radius: 13px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-size: 1.35rem; margin-bottom: 16px; }
.why-card h4 { font-size: 1.06rem; margin-bottom: 8px; }
.why-card p { font-size: 0.92rem; }

.why-mini { margin-top: 30px; display: grid; grid-template-columns: 1fr 1fr; gap: 16px 26px; }
.why-mini li { display: flex; align-items: center; gap: 12px; font-family: var(--font-head); font-weight: 500; color: var(--ink); }
.why-mini li::before { content: "\f00c"; width: 22px; height: 22px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-size: 0.7rem; font-family: "Font Awesome 6 Free"; font-weight: 900; line-height: 1; align-items: center; justify-content: center; }

/* ---------- FAQ ---------- */
.faq-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 50px; align-items: start; }
.faq-list { display: flex; flex-direction: column; gap: 16px; }
.faq-item { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: #fff; transition: 0.2s; }
.faq-item.open { box-shadow: var(--shadow-sm); border-color: var(--accent-mid); }
.faq-q {
  width: 100%; text-align: left; background: none; border: none; cursor: pointer;
  font-family: var(--font-head); font-weight: 600; font-size: 1.02rem; color: var(--ink);
  padding: 20px 22px; display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.faq-q .chev { flex: 0 0 28px; height: 28px; border-radius: 50%; background: var(--bg-soft); color: var(--accent); display: grid; place-items: center; transition: 0.25s; font-size: 0.85rem; }
.faq-item.open .chev { transform: rotate(180deg); background: var(--accent); color: #fff; }
.faq-a { max-height: 0; overflow: hidden; transition: max-height 0.35s ease; }
.faq-a p { padding: 0 22px 20px; font-size: 0.95rem; }

.faq-side { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 40px 34px; text-align: center; box-shadow: var(--shadow-sm); }
.faq-side .stars { color: var(--gold); font-size: 1.4rem; letter-spacing: 4px; }
.faq-side h5 { font-size: 1.5rem; margin: 12px 0 6px; }
.faq-side p { font-size: 0.92rem; margin-bottom: 24px; }
.faq-side .rating-note { font-size: 0.82rem; color: var(--muted); }

/* ---------- Blog / Insights ---------- */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.blog-card {
  display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden; text-decoration: none; color: inherit;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.blog-card:hover { transform: translateY(-8px); box-shadow: var(--shadow); }
.blog-thumb { position: relative; height: 210px; }
.blog-thumb::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(135deg, #0847b6 0%, #0a5cd8 55%, #f5a818 100%);
  opacity: 0.9;
}
.blog-thumb .blog-cat {
  position: absolute; top: 18px; left: 18px; background: var(--accent); color: #fff;
  font-family: var(--font-head); font-size: 0.72rem; font-weight: 600; letter-spacing: 1px;
  text-transform: uppercase; padding: 7px 14px; border-radius: 999px;
}
.blog-thumb::after {
  content: "\f0b1"; position: absolute; inset: 0; display: grid; place-items: center;
  font-family: "Font Awesome 6 Free"; font-weight: 900; font-size: 5rem; color: rgba(255,255,255,0.22);
}
.blog-body { padding: 24px 26px 26px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.blog-meta { font-size: 0.8rem; color: var(--muted); letter-spacing: 0.3px; }
.blog-body h4 { font-size: 1.18rem; line-height: 1.4; transition: color 0.3s ease; }
.blog-card:hover .blog-body h4 { color: var(--accent); }
.blog-body p { font-size: 0.92rem; color: var(--muted); flex: 1; }
.blog-more { font-family: var(--font-head); font-size: 0.8rem; font-weight: 700; letter-spacing: 2px; color: var(--accent); }
.blog-more .arr { display: inline-block; transition: transform 0.3s ease; }
.blog-card:hover .blog-more .arr { transform: translateX(5px); }

/* ---------- Contact CTA ---------- */
.contact-cta { background: var(--ink); color: #fff; }
.contact-cta .wrap { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 40px; align-items: center; padding: 54px 0; }
.contact-cta .kicker { color: var(--accent-mid); text-transform: uppercase; letter-spacing: 3px; font-size: 0.78rem; font-weight: 600; font-family: var(--font-head); }
.contact-cta h3 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.3rem); margin: 10px 0 8px; }
.contact-cta p { color: #cbd4e4; max-width: 520px; margin-bottom: 22px; }
.socials { display: flex; gap: 12px; }
.socials a { width: 44px; height: 44px; border-radius: 11px; background: rgba(255,255,255,0.1); color: #fff; display: grid; place-items: center; font-size: 1.05rem; transition: 0.25s; overflow: hidden; }
.socials a:hover { background: var(--accent); transform: translateY(-3px); color: #fff; }
/* Uploaded logo pictures: fill the round button (keeps its shape), with a
   light backing so a transparent logo is still visible on the dark section. */
.socials a.has-logo-img { background: rgba(255,255,255,0.14); padding: 0; }
.socials a.has-logo-img img { width: 100%; height: 100%; object-fit: contain; display: block; }

/* ---------- Jobs page specific ---------- */
.jobs-hero {
  background: linear-gradient(120deg, var(--accent), var(--accent-dark)); color: #fff;
  padding: 70px 0; text-align: center;
}
.jobs-hero h1 { color: #fff; font-size: clamp(2rem, 4vw, 3rem); }
.jobs-hero p { color: #e6eeff; margin-top: 10px; }

.job-toolbar { background: #fff; box-shadow: var(--shadow-sm); border-radius: 14px; padding: 22px; margin: -40px auto 40px; position: relative; z-index: 5; }
.job-toolbar .wrap { display: flex; gap: 16px; flex-wrap: wrap; }
.job-toolbar input, .job-toolbar select {
  border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; font-family: var(--font-body); font-size: 0.95rem; color: var(--ink); background: #fff; outline: none;
}
.job-toolbar input { flex: 1 1 260px; }
.job-toolbar select { flex: 0 1 200px; }
.job-toolbar input:focus, .job-toolbar select:focus { border-color: var(--accent); }

.count-line { font-size: 0.9rem; color: var(--muted); margin-bottom: 22px; }
.count-line b { color: var(--accent); }

.jobs-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.job-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px;
  transition: 0.25s ease; display: flex; flex-direction: column;
}
.job-card:hover { box-shadow: var(--shadow); transform: translateY(-5px); border-color: transparent; }
.job-card .job-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.job-badge { font-size: 0.72rem; font-weight: 600; letter-spacing: 1px; text-transform: uppercase; padding: 5px 12px; border-radius: 40px; }
.job-badge.fulltime { background: var(--accent-soft); color: var(--accent); }
.job-badge.remote { background: #e7f7ef; color: #147a4c; }
.job-badge.contract { background: #fdf0e0; color: #b26a00; }
.job-card h3 { font-size: 1.2rem; margin-bottom: 6px; }
.job-card .company { color: var(--muted); font-size: 0.9rem; margin-bottom: 14px; }
.job-meta { display: flex; flex-wrap: wrap; gap: 12px; font-size: 0.85rem; color: var(--text); margin-bottom: 18px; }
.job-meta span { display: inline-flex; align-items: center; gap: 6px; }
.job-card .btn { margin-top: auto; align-self: flex-start; padding: 11px 22px; font-size: 0.88rem; }

.no-jobs { text-align: center; padding: 40px 0; color: var(--muted); display: none; }
.no-jobs.show { display: block; }

/* ---------- Jobs page: posting actions + forms + available now ---------- */
.posting-actions { margin: 6px 0 8px; }
.posting-actions-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap;
  background: var(--ink); color: #fff; border-radius: var(--radius); padding: 22px 26px;
}
.posting-actions-left strong { display: block; font-size: 1.05rem; }
.posting-actions-left span { color: #b9c6df; font-size: 0.9rem; }
.posting-actions-btns { display: flex; gap: 12px; flex-wrap: wrap; }
.posting-actions-btns .btn { padding: 12px 22px; font-size: 0.9rem; }
.posting-actions-btns .btn.active { outline: 3px solid var(--accent); outline-offset: 2px; }
.posting-actions-btns .btn-outline { border-color: rgba(255,255,255,0.7); }
.posting-actions-btns .btn-outline.active { color: #fff; }

.posting-form-wrap { margin: 26px 0 10px; }
.posting-form {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); padding: 30px;
}
.posting-form h3 { font-size: 1.35rem; margin-bottom: 6px; }
.posting-form-note { color: var(--muted); font-size: 0.92rem; margin-bottom: 22px; }
.posting-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.posting-grid label, .posting-full label { display: block; }
.posting-grid label > span, .posting-full label > span {
  display: block; font-size: 0.85rem; font-weight: 600; color: var(--ink); margin-bottom: 6px;
}
.posting-grid label > span small { color: var(--muted); font-weight: 400; }
.posting-form input[type="text"], .posting-form input[type="email"], .posting-form input[type="tel"],
.posting-form input[type="number"], .posting-form select, .posting-form textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px;
  font-family: var(--font-body); font-size: 0.95rem; color: var(--ink); background: #fff; outline: none;
  box-sizing: border-box;
}
.posting-form input:focus, .posting-form select:focus, .posting-form textarea:focus { border-color: var(--accent); }
.posting-full { margin-top: 16px; }
.posting-full textarea { resize: vertical; }
/* Salary min – max pair with a per-year / per-month selector */
.salary-block { margin-top: 16px; }
.salary-pair { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.salary-pair input[type="number"] { flex: 1 1 150px; }
.salary-pair .salary-dash { color: var(--muted); font-weight: 600; }
.salary-pair select { flex: 0 1 150px; }
/* CV file picker in the posting forms (matches the other boxes) */
.posting-form input[type="file"] {
  width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px;
  font-family: var(--font-body); font-size: 0.95rem; color: var(--ink); background: #fff;
  cursor: pointer; box-sizing: border-box;
}
.posting-form input[type="file"]:focus { border-color: var(--accent); }
/* Tiny "CV attached" marker on an available-person card */
.available-cv-chip {
  display: inline-block; font-size: 0.78rem; font-weight: 600; color: #14608a;
  background: #e7f2f9; border: 1px solid #c2e0f0; padding: 4px 10px; border-radius: 40px;
  margin: 8px 0 10px;
}
.hp-field { position: absolute !important; left: -9999px !important; width: 1px !important; height: 1px !important; opacity: 0; }
/* Job-title suggestion dropdown (LinkedIn-style) */
.title-field { position: relative; }
.title-suggest {
  position: absolute; z-index: 50; top: calc(100% - 8px); left: 0; right: 0;
  background: #fff; border: 1px solid var(--line); border-top: none;
  border-radius: 0 0 10px 10px; box-shadow: var(--shadow-sm);
  max-height: 220px; overflow-y: auto;
}
.title-suggest button {
  display: block; width: 100%; text-align: left; border: 0; background: none;
  padding: 10px 14px; font-family: var(--font-body); font-size: 0.92rem;
  color: var(--ink); cursor: pointer;
}
.title-suggest button .role-hint {
  display: block; font-size: 0.78rem; color: var(--muted); margin-top: 1px;
}
.title-suggest button:hover, .title-suggest button.sug-active { background: #eef4ff; }
.title-suggest:empty { display: none; }
.posting-err { color: #d54848; font-size: 0.9rem; margin-top: 14px; min-height: 0; }
.posting-err.ok { color: #147a4c; }
.posting-form-btns { display: flex; gap: 12px; margin-top: 20px; flex-wrap: wrap; }
.posting-form-btns .btn { padding: 12px 24px; font-size: 0.9rem; }
.posting-form-btns .btn-outline { color: var(--accent); border-color: var(--accent); }
.posting-form-btns .btn-outline:hover { background: var(--accent); color: #fff; }

.available-title { font-size: 1.6rem; }
.available-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-bottom: 26px; }
.available-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; display: flex; flex-direction: column; gap: 10px;
}
.available-card:hover { box-shadow: var(--shadow); border-color: transparent; }
.available-head { display: flex; flex-direction: column; gap: 2px; }
.available-name { font-family: var(--font-head); font-weight: 700; font-size: 1.12rem; color: var(--ink); }
.available-role {
  font-size: 0.88rem; color: var(--accent); font-weight: 600;
}
.available-meta { display: flex; flex-wrap: wrap; gap: 14px; font-size: 0.85rem; color: var(--text); }
.available-meta span { display: inline-flex; align-items: center; gap: 6px; }
.available-notes { color: var(--muted); font-size: 0.88rem; }
.available-card .btn { margin-top: auto; align-self: flex-start; padding: 10px 18px; font-size: 0.85rem; }
.available-card .btn-outline { color: var(--accent); border-color: var(--accent); }
.available-card .btn-outline:hover { background: var(--accent); color: #fff; }

.btn-sm { padding: 9px 16px; font-size: 0.85rem; }
.job-cta { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: auto; }
.job-cta .btn { margin-top: 0; }
.community-tag {
  font-size: 0.7rem; font-weight: 600; letter-spacing: 0.5px; text-transform: uppercase;
  background: #eef1f7; color: #5b6b86; padding: 4px 10px; border-radius: 40px; white-space: nowrap;
}

@media (max-width: 820px) {
  .posting-grid, .available-grid, .jobs-grid { grid-template-columns: 1fr; }
  .posting-actions-inner { flex-direction: column; align-items: flex-start; }
}

/* ---------- Apply page ---------- */
.apply-hero { background: linear-gradient(120deg, var(--accent), var(--accent-dark)); color: #fff; padding: 64px 0; }
.apply-hero h1 { color: #fff; font-size: clamp(2rem, 4vw, 2.7rem); }
.apply-hero p { color: #e6eeff; margin-top: 8px; }

.apply-layout { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 40px; margin-top: -44px; position: relative; z-index: 5; align-items: start; }
.apply-info { background: var(--ink); color: #e6eeff; border-radius: var(--radius); padding: 34px; }
.apply-info h3 { color: #fff; margin-bottom: 14px; }
.apply-info .ai { margin-bottom: 20px; }
.apply-info .ai b { display: block; color: #fff; font-family: var(--font-head); margin-bottom: 2px; }
.apply-info .ai p { font-size: 0.92rem; }
.apply-info hr { border: none; border-top: 1px solid rgba(255,255,255,0.12); margin: 18px 0; }

.apply-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 40px; }
.apply-card h3 { margin-bottom: 22px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-field { display: flex; flex-direction: column; gap: 6px; }
.form-field.full { grid-column: 1 / -1; }
.form-field label { font-family: var(--font-head); font-size: 0.88rem; font-weight: 600; color: var(--ink); }
.form-field label .req { color: #d64b4b; }
.form-field input, .form-field select, .form-field textarea {
  border: 1px solid var(--line); border-radius: 10px; padding: 13px 15px; font-family: var(--font-body); font-size: 0.95rem; color: var(--ink); outline: none; background: #fff; width: 100%;
}
.form-field textarea { resize: vertical; min-height: 120px; }
.form-field input:focus, .form-field select:focus, .form-field textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.form-field input[type="file"] { padding: 10px 12px; cursor: pointer; }
.cv-status { font-size: 0.85rem; margin-top: 6px; }
.cv-status.ok { color: #147a4c; }
.cv-status.bad { color: #b33a3a; }
.form-note { font-size: 0.82rem; color: var(--muted); margin-top: 14px; }

.form-success {
  display: none; background: #e7f7ef; color: #147a4c; border: 1px solid #bfe8d3;
  border-radius: 12px; padding: 16px 20px; font-weight: 500; margin-bottom: 18px;
}
.form-success.show { display: block; }
.form-error {
  display: none; background: #fdecec; color: #b33a3a; border: 1px solid #f5c6c6;
  border-radius: 12px; padding: 14px 18px; margin-bottom: 18px; font-size: 0.92rem;
}
.form-error.show { display: block; }

/* ---------- Auth / admin pages ---------- */
.auth-section { background: var(--bg-soft); padding: 80px 0 100px; min-height: 60vh; display: flex; align-items: center; }
.auth-card {
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 44px 42px; max-width: 480px; margin: 0 auto; width: 100%;
}
.auth-card h3 { margin-bottom: 8px; }
.auth-sub { color: var(--muted); margin-bottom: 26px; font-size: 0.95rem; }
.auth-card .form-field { margin-bottom: 18px; }
.auth-alt { margin-top: 22px; font-size: 0.92rem; color: var(--muted); text-align: center; }
.auth-alt a { color: var(--accent); font-weight: 600; }
.auth-note { margin-top: 14px; font-size: 0.82rem; color: var(--muted); line-height: 1.55; }

/* Inline red "wrong password" / error line inside the sign-up steps */
.e-err, .g-err, .ms-err {
  color: #d93025; font-size: 13px; line-height: 1.4; margin-top: 6px; margin-bottom: 0;
}
.ms-err { color: #d13438; }
/* Sign-up success box (shown after the account is created) */
.wizard-ok {
  background: #e7f7ef; color: #147a4c; border: 1px solid #bfe8d3;
  border-radius: 12px; padding: 16px 20px; font-weight: 500; margin-top: 4px;
}

/* Email-first signup: divider + social sign-up buttons */
.auth-divider {
  display: flex; align-items: center; gap: 14px; margin: 22px 0 18px;
  color: var(--muted); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 1px;
}
.auth-divider::before, .auth-divider::after {
  content: ""; flex: 1; height: 1px; background: var(--line);
}
.social-btn {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; padding: 12px 16px; margin-bottom: 12px;
  border: 1px solid var(--line); border-radius: 10px; background: #fff;
  color: var(--ink); font-family: var(--font-head); font-size: 0.95rem; font-weight: 600;
  transition: 0.2s; cursor: pointer; text-decoration: none;
}
.social-btn:hover { border-color: var(--accent); box-shadow: var(--shadow-sm); }
.social-btn .social-icon { width: 20px; height: 20px; flex: none; border-radius: 3px; }
.social-gmail:hover { border-color: #4285F4; color: #4285F4; }
.social-outlook:hover { border-color: #0078D4; color: #0078D4; }
.social-email:hover { border-color: var(--accent); color: var(--accent); }

@media (max-width: 540px) {
  .auth-card { padding: 30px 22px; }
}

/* ---------- Footer ---------- */
.footer { background: #0d1526; color: #b7c1d6; }
.footer-top { display: grid; grid-template-columns: 1.3fr 0.8fr 1fr 1.1fr; gap: 36px; padding: 70px 0 50px; }
.footer h4 { color: #fff; font-size: 1.05rem; margin-bottom: 20px; }
.footer .logo { color: #fff; margin-bottom: 18px; }
.footer p { font-size: 0.93rem; }
.footer .newsletter { margin-top: 22px; }
.footer .newsletter form { display: flex; margin-top: 12px; }
.footer .newsletter input {
  flex: 1; padding: 13px 15px; border: 1px solid rgba(255,255,255,0.18); border-radius: 10px 0 0 10px;
  background: rgba(255,255,255,0.06); color: #fff; outline: none; font-size: 0.92rem;
}
.footer .newsletter button {
  padding: 0 20px; border: none; border-radius: 0 10px 10px 0; background: var(--accent); color: #fff; cursor: pointer; font-size: 1rem;
}
.footer .newsletter .nl-note { font-size: 0.8rem; margin-top: 8px; }

.footer-links li { margin-bottom: 11px; }
.footer-links a { color: #b7c1d6; font-size: 0.93rem; transition: 0.2s; }
.footer-links a:hover { color: #fff; padding-left: 6px; }

.footer-contact li { display: flex; gap: 12px; margin-bottom: 14px; font-size: 0.93rem; align-items: flex-start; }
.footer-contact .ico { color: var(--accent-mid); }

.footer-bottom { border-top: 1px solid rgba(255,255,255,0.09); padding: 20px 0; font-size: 0.85rem; }
.footer-bottom .wrap { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.footer-bottom a { color: #fff; }

/* ---------- Marquee strip ---------- */
.marquee {
  background: var(--accent); color: #fff; overflow: hidden; padding: 18px 0; position: relative; z-index: 4;
}
.marquee-track {
  display: flex; align-items: center; gap: 34px; white-space: nowrap;
  animation: marqueeScroll 28s linear infinite; width: max-content;
}
.marquee-track span {
  font-family: var(--font-head); font-size: 1.1rem; font-weight: 500; letter-spacing: 1px; text-transform: uppercase;
}
.marquee-track .dot { color: rgba(255,255,255,0.7); font-size: 0.8rem; }
@keyframes marqueeScroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ---------- Animated number counters (Why Choose Us) ---------- */
.hero-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px;
  margin-top: 60px; padding: 40px 30px; border-radius: var(--radius);
  background: var(--bg-soft); border: 1px solid var(--line);
}
.hero-stats .stat { text-align: center; }
.hero-stats .stat-num {
  display: inline-block; font-family: var(--font-head); font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700; color: var(--accent); line-height: 1;
}
.hero-stats .stat-label {
  display: block; margin-top: 10px; font-size: 0.85rem; letter-spacing: 1px;
  text-transform: uppercase; color: var(--muted); font-weight: 600;
}

/* ---------- Scroll reveal (fade-up on view) ----------
   Content is VISIBLE by default. The fade-up only applies once the
   reveal script has booted (it adds "js-reveal" to <html>), so the
   site can never be left invisible if the script fails to run. */
.js-reveal .reveal {
  opacity: 0; transform: translateY(36px);
  transition: opacity 0.7s cubic-bezier(0.25, 1, 0.45, 1), transform 0.7s cubic-bezier(0.25, 1, 0.45, 1);
  will-change: opacity, transform;
}
.js-reveal .reveal.in { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .js-reveal .reveal { opacity: 1; transform: none; transition: none; }
  .marquee-track { animation: none; }
  .hero-dots, .hero-scroll-cue { display: none; }
}

/* ---------- Breadcrumb / simple pages ---------- */
.breadcrumb { font-size: 0.85rem; color: var(--muted); margin-bottom: 22px; }
.breadcrumb a { color: var(--accent); }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .why-grid, .about-grid, .faq-grid, .contact-cta .wrap, .apply-layout { grid-template-columns: 1fr; }
  .features-grid { grid-template-columns: 1fr; }
  .jobs-grid { grid-template-columns: repeat(2, 1fr); }
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-stats { grid-template-columns: 1fr; gap: 30px; }
}
@media (max-width: 760px) {
  .section { padding: 64px 0; }
  .nav-toggle { display: flex; }
  .main-nav {
    position: fixed; inset: 0 0 0 auto; width: 280px; background: #fff; z-index: 60;
    transform: translateX(100%); transition: transform 0.3s ease; padding: 80px 30px; box-shadow: -10px 0 40px rgba(0,0,0,0.1);
  }
  .main-nav.open { transform: translateX(0); }
  .main-nav ul { flex-direction: column; gap: 22px; }
  .btn-touch { display: none; }
  .about-features { grid-template-columns: 1fr; }
  .services-grid, .why-cards, .why-mini, .jobs-grid, .form-grid { grid-template-columns: 1fr; }
  .blog-grid { grid-template-columns: 1fr; }
  .apply-card { padding: 26px; }
  .hero { padding: 90px 0 130px; }
  .hero-arrow { width: 42px; height: 42px; font-size: 1.3rem; top: 42%; }
  .hero-arrow.prev { left: 10px; }
  .hero-arrow.next { right: 10px; }
  .hero-dots { bottom: 38px; }
  .hero-scroll-cue { bottom: 34px; }
  .marquee-track span { font-size: 0.95rem; }
}

/* ============================================================
   Snack bar — a small message bar at the bottom of the screen.
   Managed from the Admin panel ("Snack bar" section in Site
   settings). Completely hidden unless the admin turns it on and
   adds a message, so it never changes the look of the site.
   Colours follow the site palette (--accent / --ink / --success).
   ============================================================ */
.snackbar {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 200;
  display: flex;
  align-items: center;
  gap: 14px;
  max-width: min(540px, calc(100vw - 32px));
  padding: 12px 16px 12px 12px;
  border-radius: 14px;
  background: #16213b;           /* --ink */
  color: #fff;
  box-shadow: 0 18px 45px rgba(22, 33, 59, 0.3);
  font-family: var(--font-body);
  font-size: 0.95rem;
  line-height: 1.4;
  transform: translateX(-50%) translateY(130%);
  opacity: 0;
  visibility: hidden;
  transition: transform 0.4s ease, opacity 0.4s ease, visibility 0.4s;
}
.snackbar.in {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  visibility: visible;
}
.snackbar-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.snackbar-img {
  width: 40px;
  height: 40px;
  object-fit: cover;
  border-radius: 10px;
  flex-shrink: 0;
  display: block;
}
/* Download button in the snack bar — shown for any uploaded file (PDF, EXE,
   ZIP, image, …). Clicking it always downloads the file. */
.snackbar-link {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.2s ease, transform 0.2s ease;
}
.snackbar-link:hover {
  background: rgba(255, 255, 255, 0.9);
  color: var(--accent);
  transform: translateY(-1px);
}
.snackbar-message {
  min-width: 0;
}
.snackbar-close {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  margin-left: 2px;
  border: none;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease;
}
.snackbar-close:hover {
  background: rgba(255, 255, 255, 0.26);
}

/* ============================================================
   CV Builder sign-in note — a small toast that appears when a
   visitor who is NOT signed in clicks the "CV Builder" menu item
   (that download is private). Matches the snack bar's look.
   ============================================================ */
.cv-auth-note {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 200;
  max-width: min(420px, calc(100vw - 32px));
  padding: 12px 16px;
  border-radius: 14px;
  background: #16213b;           /* --ink */
  color: #fff;
  box-shadow: 0 18px 45px rgba(22, 33, 59, 0.3);
  font-family: var(--font-body);
  font-size: 0.95rem;
  line-height: 1.4;
  text-align: center;
  transform: translateX(-50%) translateY(130%);
  opacity: 0;
  visibility: hidden;
  transition: transform 0.4s ease, opacity 0.4s ease, visibility 0.4s;
}
.cv-auth-note.in {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  visibility: visible;
}
.cv-auth-note a {
  color: #fff;
  font-weight: 700;
  text-decoration: underline;
  margin-left: 6px;
}
.cv-auth-note a:hover {
  color: #ffe9a8;
}

/* ============================================================
   Popup — a small window in the MIDDLE of the screen (a modal).
   Managed from the Admin panel ("Popup" section in Site
   settings). Completely hidden unless the admin turns it on and
   adds a message, so it never changes the look of the site.
   A dim backdrop covers the page behind it; clicking the
   backdrop or the X (top-right) closes it. Sits above the snack bar.
   ============================================================ */
.popup-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(22, 33, 59, 0.45);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s;
}
.popup-overlay.in {
  opacity: 1;
  visibility: visible;
}
.popup {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  width: min(420px, 100%);
  max-height: calc(100vh - 80px);
  overflow: auto;
  padding: 30px 26px 26px;
  border-radius: 18px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 24px 60px rgba(22, 33, 59, 0.4);
  font-family: var(--font-body);
  text-align: center;
  transform: scale(0.92);
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.popup-overlay.in .popup {
  transform: scale(1);
  opacity: 1;
}
.popup-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  width: 100%;
}
.popup-img {
  max-width: 100%;
  max-height: 220px;
  object-fit: contain;
  border-radius: 12px;
  display: block;
}
.popup-message {
  font-size: 1.05rem;
  line-height: 1.5;
}
/* Download button in the popup — shown for any uploaded file (PDF, EXE,
   ZIP, image, …). Clicking it always downloads the file. */
.popup-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.2s ease, transform 0.2s ease;
}
.popup-link:hover {
  background: rgba(255, 255, 255, 0.9);
  color: var(--accent);
  transform: translateY(-1px);
}
.popup-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 30px;
  height: 30px;
  border: none;
  border-radius: 10px;
  background: rgba(22, 33, 59, 0.12);
  color: var(--ink);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease;
}
.popup-close:hover {
  background: rgba(22, 33, 59, 0.22);
}

/* ============================================================
   Chat box — a private message window in the bottom-right corner.
   Built by js/chatbox.js. Only appears for a signed-in user.
   The user talks to the site admin; only that user (and the
   admin, from the admin panel) can see the conversation.
   Sits above the page (z-index 150) but below the snack bar
   (200) and popup (300).
   ============================================================ */
.chat-fab {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 150;
  width: 58px;
  height: 58px;
  border: none;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(22, 33, 59, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, background 0.2s ease;
}
.chat-fab:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
}
.chat-fab-dot {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #e2322d;
  border: 2px solid #fff;
  display: none;
}
.chat-fab-dot.show { display: block; }

.chat-panel {
  position: fixed;
  right: 22px;
  bottom: 90px;
  z-index: 150;
  width: min(340px, calc(100vw - 28px));
  height: min(480px, calc(100vh - 130px));
  display: flex;
  flex-direction: column;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 24px 60px rgba(22, 33, 59, 0.3);
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s;
  font-family: var(--font-body);
}
.chat-panel.open { opacity: 1; visibility: visible; transform: translateY(0); }

.chat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 13px 16px;
  background: var(--accent);
  color: #fff;
}
.chat-head-title {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  font-size: 0.98rem;
}
.chat-head-title .chat-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}
.chat-close {
  border: none;
  background: transparent;
  color: #fff;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}
.chat-close:hover { opacity: 0.85; }

.chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 14px 14px 8px;
  background: #f2f5fb;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.chat-day {
  text-align: center;
  font-size: 0.72rem;
  color: var(--muted);
  margin: 2px 0 4px;
}
.chat-msg {
  max-width: 78%;
  padding: 9px 12px;
  border-radius: 14px;
  font-size: 0.9rem;
  line-height: 1.45;
  word-wrap: break-word;
  white-space: pre-wrap;
}
.chat-msg b { font-weight: 600; }
.chat-msg .chat-who { font-size: 0.7rem; display: block; margin-bottom: 2px; opacity: 0.8; }
.chat-msg .chat-time { font-size: 0.68rem; display: block; text-align: right; margin-top: 3px; opacity: 0.78; }
.chat-msg.user {
  align-self: flex-end;
  background: var(--accent);
  color: #fff;
  border-bottom-right-radius: 4px;
}
.chat-msg.admin {
  align-self: flex-start;
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--line);
  border-bottom-left-radius: 4px;
}
.chat-empty {
  margin: auto;
  text-align: center;
  color: var(--muted);
  font-size: 0.88rem;
  padding: 0 12px;
}

.chat-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-top: 1px solid var(--line);
  background: #fff;
}
.chat-input {
  flex: 1;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 9px 13px;
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--ink);
  outline: none;
  resize: none;
  max-height: 90px;
  transition: border-color 0.2s ease;
}
.chat-input:focus { border-color: var(--accent); }
.chat-send {
  flex-shrink: 0;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  background: var(--accent);
  color: #fff;
  font-size: 1.05rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}
.chat-send:hover { background: var(--accent-dark); }
.chat-send:disabled { opacity: 0.55; cursor: default; }
.chat-error {
  font-size: 0.8rem;
  color: #b33a3a;
  padding: 0 14px 8px;
  display: none;
}
.chat-error.show { display: block; }

