/* Elite Security & Safety — corporate security theme (Securitas-inspired) */
:root {
  --color-primary: #0a2342;
  --color-primary-light: #123a5c;
  --color-accent: #c9a227;
  --color-accent-hover: #ddb52e;
  --color-bg: #f4f6f8;
  --color-bg-dark: #0d1f33;
  --color-text: #1a1a1a;
  --color-text-muted: #4a5568;
  --color-border: #e2e8f0;
  --font-en: "Inter", system-ui, sans-serif;
  --font-ar: "Cairo", "Tajawal", sans-serif;
  --header-h: 72px;
  --radius: 4px;
  --shadow: 0 4px 24px rgba(10, 35, 66, 0.08);
  --max-w: 1180px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html[lang="ar"] {
  font-family: var(--font-ar);
}

html[lang="en"] {
  font-family: var(--font-en);
}

body {
  margin: 0;
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.65;
  font-size: 1rem;
}

html[lang="ar"] body {
  font-family: var(--font-ar);
}

html[lang="en"] body {
  font-family: var(--font-en);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-primary-light);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.en-only,
.ar-only {
  display: block;
}

html[lang="en"] .ar-only {
  display: none !important;
}

html[lang="ar"] .en-only {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  background: var(--color-primary);
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 10000;
  border-radius: var(--radius);
}

.skip-link:focus {
  top: 1rem;
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-h);
  background: var(--color-primary);
  color: #fff;
  z-index: 1000;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
  overflow: visible;
}

.header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.25rem;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  overflow: visible;
  position: relative;
  z-index: 1;
}

.logo {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.2;
}

.logo-with-img {
  flex-direction: row;
  align-items: center;
  gap: 0.75rem;
}

.site-logo {
  height: 48px;
  width: auto;
  max-width: min(200px, 42vw);
  object-fit: contain;
  object-position: left center;
}

html[lang="ar"] .site-logo {
  object-position: right center;
}

.logo:hover {
  text-decoration: none;
  color: var(--color-accent);
}

.logo:hover .site-logo {
  opacity: 0.95;
}

.logo small {
  font-weight: 500;
  font-size: 0.72rem;
  opacity: 0.9;
}

.nav-desktop {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.nav-desktop a {
  color: rgba(255, 255, 255, 0.92);
  padding: 0.45rem 0.65rem;
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: var(--radius);
}

.nav-desktop a:hover,
.nav-desktop a:focus-visible {
  background: rgba(255, 255, 255, 0.12);
  text-decoration: none;
}

/* Services dropdown in header */
.nav-item--services {
  position: relative;
  display: flex;
  align-items: center;
  z-index: 2;
}

.nav-item--services:hover,
.nav-item--services.is-open {
  z-index: 1002;
}

@media (hover: hover) and (pointer: fine) {
  .nav-item--services:focus-within {
    z-index: 1002;
  }
}

.nav-item__link {
  color: rgba(255, 255, 255, 0.92);
  padding: 0.45rem 0.65rem;
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: var(--radius);
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
}

.nav-item__link:hover,
.nav-item__link:focus-visible {
  background: rgba(255, 255, 255, 0.12);
  text-decoration: none;
}

.nav-item__caret {
  display: inline-block;
  width: 0;
  height: 0;
  margin-inline-start: 0.15rem;
  border-inline-start: 4px solid transparent;
  border-inline-end: 4px solid transparent;
  border-top: 5px solid rgba(255, 255, 255, 0.75);
}

.nav-submenu {
  display: none;
  position: absolute;
  /* Flush with trigger + overlap bridge so the pointer never crosses a dead gap */
  top: 100%;
  margin-top: -0.35rem;
  padding-top: 0.5rem;
  inset-inline-start: 0;
  min-width: min(300px, 88vw);
  max-width: 92vw;
  margin-inline-end: 0;
  margin-inline-start: 0;
  padding-inline: 0;
  padding-bottom: 0.4rem;
  list-style: none;
  background: var(--color-primary-light);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.22);
  z-index: 1001;
}

.nav-submenu a {
  display: block;
  padding: 0.5rem 0.9rem;
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.94);
  text-decoration: none;
  border-radius: 0;
}

.nav-submenu a:hover,
.nav-submenu a:focus-visible {
  background: rgba(255, 255, 255, 0.1);
  text-decoration: none;
}

/* Submenu: default hidden. Show on :hover / :focus-within only for real pointers (not touch-primary).
   Touch + wide screens use .is-open from JS. Plain :focus-within caused “always open” on some hosts. */

@media (hover: hover) and (pointer: fine) {
  .nav-item--services:hover .nav-submenu,
  .nav-item--services:focus-within .nav-submenu {
    display: block;
  }
}

.nav-item--services.is-open .nav-submenu {
  display: block;
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.lang-switch button {
  font: inherit;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: transparent;
  color: #fff;
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius);
  font-size: 0.8rem;
}

.lang-switch button:hover,
.lang-switch button[aria-pressed="true"] {
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--color-accent);
}

.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
}

@media (max-width: 1024px) {
  .nav-desktop {
    display: none;
    position: absolute;
    top: var(--header-h);
    left: 0;
    right: 0;
    background: var(--color-primary-light);
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
    gap: 0;
    box-shadow: var(--shadow);
  }

  .nav-desktop.is-open {
    display: flex;
  }

  .nav-desktop > a {
    padding: 0.75rem 1rem;
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .nav-item--services {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .nav-item__link--services {
    padding: 0.75rem 1rem;
    width: 100%;
    justify-content: space-between;
  }

  .nav-submenu {
    display: block;
    position: static;
    min-width: unset;
    max-width: none;
    margin: 0;
    padding: 0 0 0.5rem;
    border: none;
    box-shadow: none;
    background: rgba(0, 0, 0, 0.12);
    border-radius: 0;
  }

  .nav-submenu a {
    padding: 0.55rem 1rem 0.55rem 1.75rem;
    font-size: 0.84rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }

  .nav-submenu li:last-child a {
    border-bottom: none;
  }

  .menu-toggle {
    display: flex;
  }
}

/* Hero */
.hero {
  margin-top: var(--header-h);
  position: relative;
  min-height: min(78vh, 640px);
  display: flex;
  align-items: flex-end;
  background: var(--color-bg-dark);
  color: #fff;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg, rgba(10, 35, 66, 0.92) 0%, rgba(10, 35, 66, 0.72) 45%, rgba(13, 31, 51, 0.5) 100%),
    url("../images/DSC00779.JPG") center / cover no-repeat;
}

.hero-bg.no-image {
  background:
    linear-gradient(135deg, #0a2342 0%, #1a4a6e 50%, #0d1f33 100%);
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 4rem 1.25rem 3.5rem;
  width: 100%;
}

.hero h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  margin: 0 0 1rem;
  line-height: 1.2;
  max-width: 38ch;
}

.hero-lead {
  font-size: 1.05rem;
  max-width: 52ch;
  opacity: 0.95;
  margin: 0 0 1.5rem;
}

.btn {
  display: inline-block;
  padding: 0.65rem 1.35rem;
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

.btn-primary {
  background: var(--color-accent);
  color: var(--color-primary);
}

.btn-primary:hover {
  background: var(--color-accent-hover);
  text-decoration: none;
}

.btn-outline {
  background: transparent;
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.85);
  margin-inline-start: 0.5rem;
}

html[lang="ar"] .btn-outline {
  margin-inline-start: 0;
  margin-inline-end: 0.5rem;
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.12);
  text-decoration: none;
}

/* Sections */
.section {
  padding: 3.5rem 1.25rem;
}

.section-alt {
  background: #fff;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.section-dark {
  background: var(--color-primary);
  color: #fff;
}

.section-dark h2,
.section-dark h3 {
  color: #fff;
}

.section-dark .section-lead {
  color: rgba(255, 255, 255, 0.88);
}

.section-inner {
  max-width: var(--max-w);
  margin: 0 auto;
}

.section-head {
  margin-bottom: 2rem;
  text-align: center;
}

.section-kicker {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--color-accent);
  margin: 0 0 0.5rem;
}

.section-dark .section-kicker {
  color: var(--color-accent);
}

h2 {
  font-size: clamp(1.5rem, 2.5vw, 1.85rem);
  margin: 0 0 0.75rem;
  color: var(--color-primary);
}

.section-dark h2 {
  color: #fff;
}

.section-lead {
  color: var(--color-text-muted);
  font-size: 1.05rem;
  max-width: 65ch;
  margin: 0 auto;
}

.grid-2 {
  display: grid;
  gap: 2rem;
}

@media (min-width: 768px) {
  .grid-2 {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

.grid-3 {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Services: one full-width block per service (no side-by-side columns) */
.services-stack {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  max-width: 52rem;
  margin-inline: auto;
}

.services-stack .card-service {
  width: 100%;
}

/* Careers: two job cards per row (general requirements spans full width below) */
.services-stack.jobs-stack {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.75rem;
  max-width: var(--max-w);
  margin-inline: auto;
}

.services-stack.jobs-stack > .card {
  min-width: 0;
}

@media (min-width: 768px) {
  .services-stack.jobs-stack {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .services-stack.jobs-stack > .card:last-child {
    grid-column: 1 / -1;
  }
}

.card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
}

.section-dark .card {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.95);
}

.section-dark .card h3 {
  color: #fff;
}

.card h3 {
  font-size: 1.1rem;
  margin: 0 0 0.75rem;
  color: var(--color-primary);
}

/* Services: expanded detail lists */
.card-service .service-intro {
  margin: 0 0 0.85rem;
  font-size: 0.95rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}

.card-service .service-detail-list {
  font-size: 0.9rem;
  line-height: 1.55;
}

.card-service .service-detail-list li:last-child {
  margin-bottom: 0;
}

.card-service[id] {
  scroll-margin-top: calc(var(--header-h) + 1rem);
}

/* Section blocks without .section-head (titles centered to match) */
#standards .section-inner > h2 {
  text-align: center;
}

#standards .section-inner > p.section-lead {
  text-align: center;
}

#fleet > h2 {
  text-align: center;
}

#fleet > p {
  text-align: center;
  max-width: 65ch;
  margin-inline: auto;
}

/* Careers — job listings (one card per role, details = read more) */
.careers-opps-title {
  font-size: clamp(1.2rem, 2vw, 1.45rem);
  margin: 0 0 1.25rem;
  color: var(--color-primary);
  text-align: center;
}

.jobs-stack .job-card[id] {
  scroll-margin-top: calc(var(--header-h) + 1rem);
}

.job-meta {
  font-size: 0.92rem;
  color: var(--color-text-muted);
  margin: 0 0 0.75rem;
  line-height: 1.55;
}

.job-meta strong {
  color: var(--color-text);
  font-weight: 600;
}

.job-details {
  margin-top: 0.15rem;
}

.job-read-more {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  list-style: none;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--color-accent);
  padding: 0.4rem 0;
  user-select: none;
}

.job-read-more:hover,
.job-read-more:focus-visible {
  color: var(--color-primary-light);
  text-decoration: underline;
  outline: none;
}

.job-read-more::-webkit-details-marker {
  display: none;
}

.job-details:not([open]) .label-close {
  display: none;
}

.job-details[open] .label-open {
  display: none;
}

.job-details-body {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--color-border);
}

.job-details-body h4 {
  font-size: 0.98rem;
  margin: 1.1rem 0 0.45rem;
  color: var(--color-primary);
}

.job-details-body > h4:first-of-type {
  margin-top: 0;
}

.job-details-body p {
  margin: 0 0 0.85rem;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--color-text-muted);
}

.job-details-body ul {
  margin: 0 0 1rem;
  padding-inline-start: 1.25rem;
}

.job-details-body li {
  margin-bottom: 0.4rem;
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--color-text-muted);
}

ul.check {
  margin: 0;
  padding: 0;
  list-style: none;
}

ul.check li {
  position: relative;
  padding-inline-start: 1.5rem;
  margin-bottom: 0.6rem;
}

ul.check li::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  top: 0.55em;
  width: 6px;
  height: 6px;
  background: var(--color-accent);
  border-radius: 1px;
}

.section-dark ul.check li::before {
  background: var(--color-accent);
}

.split-image {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--color-border);
  min-height: 220px;
  background: linear-gradient(145deg, #e8ecf0, #dfe5eb);
}

.split-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.placeholder-note {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-top: 0.75rem;
}

/* In-section photography */
.section-media {
  margin: 0 0 2rem;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow);
  background: #0d1f33;
}

.section-media-img {
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.media-caption {
  margin: 0;
  padding: 0.65rem 1rem;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.9);
  background: var(--color-primary);
}

.operations-banner {
  margin: 0 0 2rem;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow);
}

.operations-banner img {
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.operations-banner .media-caption {
  background: var(--color-bg);
  color: var(--color-text-muted);
  border-top: 1px solid var(--color-border);
}

.split-image--brand {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 260px;
  background: #fff;
  padding: 1.5rem;
}

.about-brand-img {
  width: 100%;
  max-height: 320px;
  object-fit: contain;
}

.footer-brand-wrap {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer-logo {
  height: 40px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
  opacity: 0.95;
}

/* Footer */
.site-footer {
  background: #071525;
  color: rgba(255, 255, 255, 0.82);
  padding: 2.5rem 1.25rem;
  font-size: 0.9rem;
}

.site-footer a {
  color: #fff;
}

.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1.5rem;
  align-items: center;
}

.footer-brand {
  font-weight: 700;
  color: #fff;
}

/* Contact block */
.contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.contact-list li {
  margin-bottom: 0.75rem;
  padding-inline-start: 0;
}

.contact-list strong {
  color: var(--color-primary);
  display: inline-block;
  min-width: 6rem;
}

.section-dark .contact-list strong {
  color: var(--color-accent);
}

.placeholder {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  background: rgba(201, 162, 39, 0.2);
  border-radius: 2px;
  font-style: italic;
}

/* Subsections */
h3.subsection-title {
  font-size: 1.15rem;
  margin: 2rem 0 0.75rem;
  color: var(--color-primary-light);
}

.section-dark h3.subsection-title {
  color: #fff;
}

h3.subsection-title:first-of-type {
  margin-top: 0;
}

p {
  margin: 0 0 1rem;
}

.stack-gap > * + * {
  margin-top: 1.25rem;
}
