/* ===== Qatar Global Psytech – theme tokens (mirrors the original GeneratePress palette) ===== */
:root {
  --gp-contrast: #222222;
  --gp-contrast-2: #575760;
  --gp-contrast-3: #b2b2be;
  --gp-base: #f0f0f0;
  --gp-base-2: #f7f8f9;
  --gp-base-3: #ffffff;
  --gp-accent: #1e73be;
  --gp-brand: #1890d7;
  --gp-navy: #2e4a8f;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Tahoma, Arial, sans-serif;
  color: var(--gp-contrast);
  background: var(--gp-base-3);
  font-size: 17px;
  line-height: 1.7;
}

a { color: var(--gp-accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ===== Navigation (logo lives inside the menu bar, on the right) ===== */
.main-nav {
  background: var(--gp-base-3);
  border-top: 1px solid var(--gp-base);
  border-bottom: 1px solid var(--gp-base);
  padding: 0;
}
.main-nav .navbar-brand { margin: 0; padding: 8px 0; }
.nav-logo { height: 42px; width: auto; }
.main-nav .navbar-nav {
  flex-wrap: wrap;      /* safety net only — padding/breakpoint below keep this to one line */
  row-gap: 2px;
}
.main-nav .nav-link {
  color: var(--gp-contrast);
  padding: 0 9px !important;
  line-height: 60px;
  font-size: 14.5px;
  white-space: nowrap;
}
.lang-switcher .nav-link { padding-inline-end: 4px !important; }
.lang-flag { border-radius: 2px; }
.main-nav .nav-link:hover,
.main-nav .nav-link.active { color: var(--gp-accent); text-decoration: none; }
.main-nav .dropdown-menu {
  background: var(--gp-base);
  border: 0;
  border-radius: 0;
  padding: 0;
  min-width: 240px;
}
.main-nav .dropdown-item {
  padding: 12px 20px;
  font-size: 14px;
  color: var(--gp-contrast);
  border-bottom: 1px solid rgba(0,0,0,.04);
}
.main-nav .dropdown-item:hover,
.main-nav .dropdown-item:focus { background: var(--gp-base-2); color: var(--gp-accent); text-decoration: none; }
.navbar-toggler { border: 0; font-size: 1rem; padding: 14px 0; box-shadow: none !important; }
.navbar-toggler .bi { font-size: 1.4rem; vertical-align: middle; }

/* nested submenu (Talent Analytics) */
.dropend { position: relative; }
.dropend > .submenu { display: none; }
.dropend.show-sub > .submenu { display: block; }
@media (min-width: 1400px) {
  .dropend > .submenu { position: absolute; top: 0; right: 100%; }
  .dropend:hover > .submenu { display: block; }
  .main-nav .dropdown:hover > .dropdown-menu { display: block; margin-top: 0; }
}
@media (max-width: 1399.98px) {
  .main-nav .dropdown-menu { background: var(--gp-base-2); }
  .dropend > .submenu { position: static; padding-right: 1rem; box-shadow: none; }
}

/* ===== Hero slider ===== */
.hero .carousel-item {
  height: clamp(360px, 56.25vw, 720px);   /* keeps the 16:9 feel of the source images */
  background-size: cover;
  background-position: center;
}
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to left, rgba(10, 30, 60, .70) 0%, rgba(10, 30, 60, .25) 55%, rgba(10, 30, 60, 0) 100%);
}
.hero-caption {
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  color: #fff;
  max-width: 1140px;
}
.hero-caption h1 {
  font-size: clamp(1.8rem, 4vw, 3.2rem);
  font-weight: 700;
  margin-bottom: 1rem;
  max-width: 640px;
  text-shadow: 0 2px 12px rgba(0,0,0,.35);
}
.hero-caption p {
  font-size: clamp(1rem, 1.6vw, 1.3rem);
  max-width: 560px;
  margin-bottom: 1.75rem;
  text-shadow: 0 1px 8px rgba(0,0,0,.35);
}
.btn-hero {
  background: var(--gp-brand);
  color: #fff;
  border-radius: 30px;
  padding: 10px 38px;
  font-weight: 600;
  border: 2px solid var(--gp-brand);
  transition: all .25s;
}
.btn-hero:hover { background: transparent; color: #fff; border-color: #fff; text-decoration: none; }
.hero .carousel-indicators [data-bs-target] { width: 12px; height: 12px; border-radius: 50%; }

/* ===== Intro ===== */
.narrow { max-width: 900px; }
.section-title { font-size: clamp(1.6rem, 3vw, 2.3rem); font-weight: 700; }
.intro p { color: var(--gp-contrast); }
.section-divider { border: 0; height: 1px; background: var(--gp-contrast-3); opacity: 1; margin: 0; }

/* ===== Service cards ===== */
.service-card {
  background: var(--gp-base-2);
  border: 1px solid #f5f5f585;
  border-radius: 8px;
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: box-shadow .25s, transform .25s;
}
.service-card:hover { box-shadow: 0 10px 30px rgba(30, 60, 120, .12); transform: translateY(-4px); }
.service-card p { flex-grow: 1; margin: 20px 0 30px; min-height: 5.5em; }

.hover-swap { position: relative; display: block; width: 240px; max-width: 100%; aspect-ratio: 513 / 541; }
.hover-swap img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; transition: opacity .3s; }
.hover-swap .img-hover { opacity: 0; }
.hover-swap:hover .img-hover,
.hover-swap:focus .img-hover { opacity: 1; }
.hover-swap:hover .img-default,
.hover-swap:focus .img-default { opacity: 0; }

.btn-read {
  background: var(--gp-accent);
  color: #fff;
  border-radius: 24px;
  padding: 10px 20px;
  margin-top: auto;
}
.btn-read:hover { background: var(--gp-navy); color: #fff; text-decoration: none; }

.md-logo { width: 155px; height: auto; }

/* ===== Footer ===== */
.site-footer { background: var(--gp-base); color: var(--gp-contrast); }
.footer-heading { font-size: 1.15rem; font-weight: 700; margin-bottom: 1.25rem; }
.footer-links li { margin-bottom: .45rem; }
.footer-links a, .footer-contact a { color: var(--gp-contrast); }
.footer-links a:hover, .footer-contact a:hover { color: var(--gp-accent); }
.footer-contact li { display: flex; gap: 12px; margin-bottom: 1rem; }
.footer-contact .bi { color: var(--gp-accent); font-size: 1.1rem; margin-top: 2px; }

.social-links { display: flex; gap: 10px; }
.social-links a {
  width: 40px; height: 40px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1.1rem; transition: transform .2s;
}
.social-links a:hover { transform: scale(1.1); text-decoration: none; }
.social-links .fb { background: #0866ff; }
.social-links .ig { background: #f00075; }
.social-links .li { background: #0d66c2; }

.copyright-bar { background: var(--gp-base-3); font-size: 14px; color: var(--gp-contrast-2); }

/* ===== Back to top ===== */
.back-to-top {
  position: fixed; bottom: 24px; left: 24px;
  width: 44px; height: 44px; border-radius: 4px; border: 0;
  background: rgba(0,0,0,.45); color: #fff;
  opacity: 0; visibility: hidden; transition: opacity .3s, visibility .3s;
  z-index: 1030;
}
.back-to-top.show { opacity: 1; visibility: visible; }
.back-to-top:hover { background: rgba(0,0,0,.7); }

@media (max-width: 575.98px) {
  body { font-size: 16px; }
  .nav-logo { height: 38px; }
  .hero-overlay { background: rgba(10, 30, 60, .55); }
}
