/* =========================================================================
   4 Procurement — institutional website stylesheet
   Palette (Brand Book v1.0, section 6 — exact values, do not change):
     Deep blue      #0B2A4A
     Medium blue    #1E5E8C
     Teal           #2FA4A9
     Technical grey #3A3A3A
     White          #FFFFFF
   Typography: Inter (Brand Book section 7, secondary/institutional face).
   Tints are derived only as rgba() of the brand colours above.
   ========================================================================= */

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900; /* variable font */
  font-display: swap;
  src: url("../fonts/inter-latin.woff2") format("woff2");
}

:root {
  --c-deep: #0B2A4A;
  --c-blue: #1E5E8C;
  --c-teal: #2FA4A9;
  --c-grey: #3A3A3A;
  --c-white: #FFFFFF;

  --tint-bg: rgba(30, 94, 140, 0.05);      /* section background */
  --tint-border: rgba(11, 42, 74, 0.14);   /* hairlines and card borders */

  --container: 1140px;
  --radius: 6px;
}

/* ---- Reset / base ---------------------------------------------------- */

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", "Segoe UI", Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  color: var(--c-grey);
  background: var(--c-white);
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3 {
  color: var(--c-deep);
  line-height: 1.2;
  margin: 0 0 0.75rem;
  font-weight: 700;
}

h1 { font-size: clamp(1.85rem, 4.5vw, 2.75rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.1rem); }
h3 { font-size: 1.125rem; font-weight: 600; }

p {
  margin: 0 0 1rem;
}

a {
  color: var(--c-blue);
}

a:hover {
  color: var(--c-teal);
}

:focus-visible {
  outline: 3px solid var(--c-teal);
  outline-offset: 2px;
  border-radius: 2px;
}

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 1.25rem;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--c-deep);
  color: var(--c-white);
  padding: 0.6rem 1rem;
  z-index: 100;
}

.skip-link:focus {
  left: 0.5rem;
  top: 0.5rem;
}

/* Eyebrow label above section headings */
.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-blue);
  margin: 0 0 0.6rem;
}

.section {
  padding-block: 3.25rem;
}

.section--tint {
  background: var(--tint-bg);
}

.section--dark {
  background: var(--c-deep);
  color: var(--c-white);
}

.section--dark h2 {
  color: var(--c-white);
}

.lead {
  font-size: 1.08rem;
  max-width: 46rem;
}

.nowrap {
  white-space: nowrap;
}

.lead--light {
  color: rgba(255, 255, 255, 0.85);
}

/* ---- Header -----------------------------------------------------------
   Brand Book section 9 (clear space): keep a free area around the mark at
   least equal to the height of the P in the symbol. At the rendered logo
   height of 44px the symbol is ~44px tall, so the P is ~30px; the header
   padding and flex gap below keep every element at least that far away.
   ----------------------------------------------------------------------- */

.site-header {
  background: var(--c-white);
  border-bottom: 1px solid var(--tint-border);
  position: sticky;
  top: 0;
  z-index: 50;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding-block: 1.75rem; /* >= clear-space rule at 44px logo height */
}

.brand {
  display: inline-flex;
  flex-shrink: 0;
}

.brand img {
  height: 40px;
  width: auto;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--tint-border);
  border-radius: var(--radius);
  padding: 0.5rem 0.65rem;
  cursor: pointer;
}

.nav-toggle .bar {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--c-deep);
  margin: 5px 0;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.site-nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 1.75rem;
  margin: 0;
  padding: 0;
}

.site-nav a {
  text-decoration: none;
  color: var(--c-deep);
  font-weight: 500;
  font-size: 0.95rem;
  padding-block: 0.25rem;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover {
  color: var(--c-blue);
}

.site-nav a[aria-current="page"] {
  color: var(--c-blue);
  border-bottom-color: var(--c-teal);
}

.site-nav .nav-cta {
  background: var(--c-deep);
  color: var(--c-white);
  padding: 0.55rem 1.1rem;
  border-radius: var(--radius);
  border-bottom: none;
}

.site-nav .nav-cta:hover {
  background: var(--c-blue);
  color: var(--c-white);
}

/* ---- Hero -------------------------------------------------------------- */

.hero {
  background: var(--c-deep);
  color: var(--c-white);
  padding-block: 4.5rem;
}

/* Split hero (text panel + looping video, as on SBM Offshore / Seadrill).
   The video is decorative: muted, looped, no controls. Sources are attached
   by main.js only on wide viewports without prefers-reduced-motion, so
   phones and motion-sensitive users get the poster image instead. */
.hero--split {
  padding-block: 0;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr;
}

.hero-copy {
  display: flex;
  align-items: center;
  padding: 3.5rem 1.25rem;
}

.hero-media {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--c-deep);
  overflow: hidden;
}

.hero-media video,
.hero-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* the 16:9 footage is cropped at the sides on tall panels; the subjects
     (platform, FPSO bow, nearest turbine) sit on the right of the frame,
     so keep the right-hand side and sacrifice the open sea on the left */
  object-position: 78% 50%;
}

.hero-media video {
  display: none;
}

.hero-media video.is-active {
  display: block;
}

@media (min-width: 980px) {
  .hero-inner {
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    min-height: 560px; /* lower panel = less side cropping of the 16:9 film */
  }

  .hero-copy {
    /* keep the text aligned with the site container's left edge */
    padding: 4.5rem 3rem 4.5rem max(1.25rem, calc((100vw - var(--container)) / 2));
  }

  .hero-media {
    aspect-ratio: auto;
    min-height: 100%;
  }

  /* soft blend from the text panel into the footage */
  .hero-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, var(--c-deep) 0%, rgba(11, 42, 74, 0) 22%);
    pointer-events: none;
  }
}

.hero h1 {
  color: var(--c-white);
  max-width: 18ch;
}

.hero .tagline-sub {
  max-width: 44rem;
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.88);
}

.hero-kicker {
  color: var(--c-teal);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.8rem;
  margin-bottom: 1rem;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.75rem;
}

.btn {
  display: inline-block;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.98rem;
  padding: 0.8rem 1.5rem;
  border-radius: var(--radius);
  border: 2px solid transparent;
}

.btn--primary {
  background: var(--c-teal);
  color: var(--c-deep);
}

.btn--primary:hover {
  background: var(--c-white);
  color: var(--c-deep);
}

.btn--ghost {
  border-color: rgba(255, 255, 255, 0.55);
  color: var(--c-white);
}

.btn--ghost:hover {
  border-color: var(--c-teal);
  color: var(--c-white);
}

.btn--solid {
  background: var(--c-deep);
  color: var(--c-white);
}

.btn--solid:hover {
  background: var(--c-blue);
  color: var(--c-white);
}

/* ghost button on a light background (confirmation page) */
.btn--ghost-dark {
  border-color: var(--c-deep);
  color: var(--c-deep);
}

.btn--ghost-dark:hover {
  border-color: var(--c-teal);
  color: var(--c-deep);
}

/* ---- Cards and grids --------------------------------------------------- */

.grid {
  display: grid;
  gap: 1.25rem;
  margin-top: 2rem;
}

.grid--features { grid-template-columns: 1fr; }
.grid--products { grid-template-columns: 1fr; }
.grid--values   { grid-template-columns: 1fr; }

@media (min-width: 620px) {
  .grid--features { grid-template-columns: repeat(2, 1fr); }
  .grid--products { grid-template-columns: repeat(2, 1fr); }
  .grid--values   { grid-template-columns: repeat(2, 1fr); }
}

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

.card {
  background: var(--c-white);
  border: 1px solid var(--tint-border);
  border-top: 3px solid var(--c-teal);
  border-radius: var(--radius);
  padding: 1.5rem;
}

.card h3 {
  margin-bottom: 0.4rem;
}

.card p {
  margin: 0;
  font-size: 0.95rem;
}

/* Product cards */

.product-card {
  background: var(--c-white);
  border: 1px solid var(--tint-border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.product-card figure {
  margin: 0;
  background: var(--c-white);
  border-bottom: 1px solid var(--tint-border);
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem;
}

.product-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.product-card .product-body {
  padding: 1.1rem 1.25rem 1.35rem;
}

.product-card h2 {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.product-card p {
  margin: 0;
  font-size: 0.92rem;
}

/* ---- Pull quote / statement ------------------------------------------- */

.statement {
  border-left: 4px solid var(--c-teal);
  padding: 0.35rem 0 0.35rem 1.25rem;
  margin: 1.75rem 0;
  font-weight: 600;
  color: var(--c-deep);
  font-size: 1.05rem;
  max-width: 40rem;
}

.sector-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding: 0;
  margin: 1.5rem 0 0;
}

.sector-list li {
  border: 1px solid var(--tint-border);
  border-radius: 999px;
  padding: 0.35rem 1rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--c-deep);
  background: var(--c-white);
}

/* ---- Key figures band --------------------------------------------------- */

.figures {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
  margin-top: 2.25rem;
  text-align: center;
}

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

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

.figure-item .figure-value {
  display: block;
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--c-teal);
  margin-bottom: 0.4rem;
  line-height: 1.15;
}

.figure-item p {
  margin: 0;
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.85);
}

/* ---- Process timeline (How We Work) ------------------------------------ */

.process {
  list-style: none;
  counter-reset: step;
  margin: 2.5rem 0 0;
  padding: 0;
  max-width: 46rem;
}

.process li {
  counter-increment: step;
  position: relative;
  padding: 0 0 2.25rem 4.25rem;
}

.process li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  background: var(--c-deep);
  color: var(--c-white);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.process li::after {
  content: "";
  position: absolute;
  left: calc(1.375rem - 1px);
  top: 3rem;
  bottom: 0.25rem;
  width: 2px;
  background: var(--tint-border);
}

.process li:last-child { padding-bottom: 0; }
.process li:last-child::after { display: none; }

.process h2 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
}
.process p { margin: 0; font-size: 0.97rem; }

/* ---- Value propositions (Why 4 Procurement) ---------------------------- */

.value-item {
  border-left: 4px solid var(--c-blue);
  padding: 0.25rem 0 0.25rem 1.25rem;
}

/* Text + photo layout mirroring the Commercial Value page of the company
   profile (photo beside the value propositions on wide screens) */
.why-layout,
.media-split {
  display: grid;
  gap: 2.5rem;
}

@media (min-width: 980px) {
  .why-layout,
  .media-split {
    grid-template-columns: 3fr 2fr;
    align-items: start;
  }

  .media-split--sticky figure {
    position: sticky;
    top: 7rem;
  }
}

.why-photo,
.media-split figure {
  margin: 0;
}

.why-photo img,
.media-split figure img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
}

.media-split figcaption {
  margin-top: 0.6rem;
  font-size: 0.82rem;
  color: var(--c-grey);
}

.value-item h2 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}
.value-item p { margin: 0; font-size: 0.97rem; }

/* ---- CTA strip ---------------------------------------------------------- */

.cta-strip {
  background: var(--c-blue);
  color: var(--c-white);
  padding-block: 3rem;
  text-align: center;
}

.cta-strip h2 {
  color: var(--c-white);
  margin-bottom: 0.5rem;
}

.cta-strip p {
  color: rgba(255, 255, 255, 0.88);
  max-width: 40rem;
  margin-inline: auto;
}

.cta-strip .btn--primary { margin-top: 1.25rem; }

/* ---- Contact page ------------------------------------------------------- */

.contact-layout {
  display: grid;
  gap: 2.5rem;
  grid-template-columns: 1fr;
  margin-top: 2rem;
}

@media (min-width: 900px) {
  .contact-layout { grid-template-columns: 2fr 3fr; }
}

.contact-details h2 {
  font-size: 1.25rem;
}

.contact-details dl {
  margin: 1.25rem 0 0;
}

.contact-details dt {
  font-weight: 600;
  color: var(--c-deep);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-top: 1.1rem;
}

.contact-details dd {
  margin: 0.15rem 0 0;
}

.legal-note {
  margin-top: 1.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--tint-border);
  font-size: 0.85rem;
}

.contact-photo {
  margin: 2rem 0 0;
}

.contact-photo img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
}

.contact-photo figcaption {
  margin-top: 0.6rem;
  font-size: 0.82rem;
  color: var(--c-grey);
}

/* Form */

.rfq-form {
  background: var(--c-white);
  border: 1px solid var(--tint-border);
  border-radius: var(--radius);
  padding: 1.75rem;
}

.form-grid {
  display: grid;
  gap: 1.1rem;
  grid-template-columns: 1fr;
}

@media (min-width: 620px) {
  .form-grid { grid-template-columns: 1fr 1fr; }
  .form-grid .form-field--full { grid-column: 1 / -1; }
}

.form-field label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--c-deep);
  margin-bottom: 0.35rem;
}

.form-field .required {
  color: var(--c-blue);
}

.form-field input,
.form-field textarea {
  width: 100%;
  font: inherit;
  color: var(--c-grey);
  padding: 0.65rem 0.8rem;
  border: 1px solid var(--tint-border);
  border-radius: var(--radius);
  background: var(--c-white);
}

.form-field input:focus,
.form-field textarea:focus {
  outline: 3px solid var(--c-teal);
  outline-offset: 1px;
  border-color: var(--c-teal);
}

.form-hint {
  font-size: 0.82rem;
  margin: 0.3rem 0 0;
  color: var(--c-grey);
}

.form-status {
  margin-top: 1rem;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--c-deep);
}

.form-status[hidden] { display: none; }

.form-status--error {
  color: var(--c-blue);
}

/* Honeypot field: kept out of sight and out of the tab order for people;
   bots that fill every input reveal themselves. */
.form-field--hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ---- Disclaimer --------------------------------------------------------- */

.disclaimer {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--tint-border);
  font-size: 0.83rem;
  color: var(--c-grey);
  max-width: 52rem;
}

/* ---- Footer ------------------------------------------------------------- */

.site-footer {
  background: var(--c-deep);
  color: rgba(255, 255, 255, 0.85);
  padding-block: 3rem 0;
  font-size: 0.92rem;
}

.footer-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
  padding-bottom: 2.5rem;
}

@media (min-width: 760px) {
  .footer-grid { grid-template-columns: 2fr 1.5fr 1fr; }
}

/* Footer lockmark (white version). Same clear-space rule as the header: at
   the rendered height of 40px the P in the symbol is ~28px, kept free by the
   footer padding, the grid gap and the 1.75rem margin below the mark. */
.footer-logo {
  height: 40px;
  width: auto;
  margin-bottom: 1.75rem;
}

.footer-brand-name {
  color: var(--c-white);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.04em;
  margin-bottom: 0.5rem;
}

.footer-tagline {
  color: var(--c-teal);
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.site-footer h2 {
  color: var(--c-white);
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.9rem;
}

.site-footer address {
  font-style: normal;
}

.site-footer a {
  color: var(--c-white);
  text-decoration-color: rgba(255, 255, 255, 0.4);
}

.site-footer a:hover {
  color: var(--c-teal);
}

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

.footer-nav li {
  margin-bottom: 0.5rem;
}

.footer-nav a {
  text-decoration: none;
}

.footer-legal {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-block: 1.25rem;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.65);
}

/* ---- Mobile navigation -------------------------------------------------- */

@media (max-width: 859px) {
  .header-inner {
    padding-block: 1.1rem; /* logo 36px -> P ~25px; padding + border keep clear space */
    flex-wrap: wrap;
  }

  .brand img { height: 36px; }

  .nav-toggle { display: block; }

  .site-nav {
    flex-basis: 100%;
  }

  .site-nav ul {
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding-block: 0.5rem 1rem;
  }

  .site-nav ul.is-open { display: flex; }

  .site-nav a {
    display: block;
    padding: 0.8rem 0.25rem;
    border-bottom: 1px solid var(--tint-border);
  }

  .site-nav a[aria-current="page"] {
    border-bottom-color: var(--tint-border);
    border-left: 3px solid var(--c-teal);
    padding-left: 0.75rem;
  }

  .site-nav .nav-cta {
    margin-top: 0.75rem;
    text-align: center;
  }

  .nav-toggle[aria-expanded="true"] .bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .bar:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] .bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
