/* ============================================================
   LAYOUT — PhaseLab Instrument
   Section shells, page structures, responsive patterns.
   All values reference tokens.
   ============================================================ */


/* ── NAVBAR ─────────────────────────────────────────────────────
   White background, dark text, pill-shaped action buttons.
   ─────────────────────────────────────────────────────────────── */

.pl-navbar {
  background-color: #ffffff;
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid var(--color-border);
  padding-top: var(--sp-1);
  padding-bottom: var(--sp-1);
  transition: box-shadow var(--transition);
}
.pl-navbar.scrolled {
  box-shadow: 0 2px 16px hsl(204 30% 15% / 0.08);
  border-bottom-color: transparent;
}

/* Brand / logo */
.pl-navbar__brand {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  color: var(--text-heading) !important;
  text-decoration: none;
  padding: var(--sp-1) 0;
  flex-shrink: 0;
}
.pl-navbar__brand:hover { text-decoration: none; color: var(--color-brand) !important; }

.pl-navbar__brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.pl-navbar__brand-text strong {
  font-size: var(--text-sm);
  font-weight: var(--fw-bold);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-brand);
}
.pl-navbar__brand-text span {
  font-size: var(--text-xs);
  font-weight: var(--fw-medium);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* Nav links */
.pl-navbar .nav-link {
  color: var(--text-body) !important;
  font-size: var(--text-sm);
  font-weight: var(--fw-medium);
  padding: var(--sp-2) var(--sp-3) !important;
  transition: color var(--transition-fast);
}
.pl-navbar .nav-link:hover,
.pl-navbar .nav-link.active {
  color: var(--color-brand) !important;
}

/* Toggler on mobile */
.pl-navbar .navbar-toggler {
  border-color: var(--grey-300);
}

/* Dropdown */
.pl-navbar .dropdown-menu {
  background-color: #fff;
  border: 1px solid var(--grey-200);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}
.pl-navbar .dropdown-item {
  color: var(--text-body);
  font-size: var(--text-sm);
  padding: var(--sp-2) var(--sp-5);
}
.pl-navbar .dropdown-item:hover {
  background-color: var(--blue-50);
  color: var(--color-brand);
}

/* Logo image — explicit size to override base.css img { height: auto } */
.pl-navbar__brand img {
  height: 76px;
  width: auto;
}

/* Navbar action buttons container */
.pl-navbar__actions {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
}


/* ── SECTION SHELL ───────────────────────────────────────────────
   Base: .section
   Modifiers: --surface  --deep  --blue-tint
   ─────────────────────────────────────────────────────────────── */

.section {
  padding: var(--section-py) 0;
  background-color: var(--bg-page);
  scroll-margin-top: 5.5rem; /* offset for sticky navbar (~96px) + visual gap */
}

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

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

.section--deep-alt {
  background-color: var(--bg-deep-alt);
}

.section--blue-tint {
  background-color: var(--blue-100);
}

.section--gold-tint {
  background-color: var(--gold-100);
}

/* Reduced padding variant */
.section--compact {
  padding: var(--sp-10) 0;
}

/* Extra padding */
.section--spacious {
  padding: var(--sp-24) 0;
}


/* ── HERO ────────────────────────────────────────────────────────
   Full-width hero, typically at the top of a page.
   ─────────────────────────────────────────────────────────────── */

.hero {
  background-color: var(--bg-page);
  padding: var(--sp-16) 0 0;
  overflow: hidden;
}

.hero__text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-bottom: var(--sp-16);
}

.hero__supertitle {
  font-size: var(--text-sm);
  font-weight: var(--fw-semi);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: var(--sp-2);
}

.hero__title {
  font-size: var(--text-3xl);
  color: var(--text-heading);
  line-height: 1.1;
  margin-bottom: var(--sp-3);
}

.hero__subtitle {
  font-size: var(--text-xl);
  font-weight: var(--fw-medium);
  color: var(--text-muted);
  margin-bottom: var(--sp-4);
}

.hero__body {
  font-size: var(--text-base);
  color: var(--text-body);
  margin-bottom: var(--sp-8);
}

.hero__cta-group {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}
@media (min-width: 480px) {
  .hero__cta-group { flex-direction: row; flex-wrap: wrap; }
}

.hero__img {
  display: flex;
  align-items: flex-end;
}
.hero__img img {
  width: 100%;
  max-height: 460px;
  object-fit: contain;
}


/* ── SITE HERO — light split layout (index.html) ─────────────────
   Pale blue-white bg, text left, product image right
   ─────────────────────────────────────────────────────────────── */

.site-hero {
  background-color: var(--bg-page);
  background-image: radial-gradient(
    ellipse at 70% 50%,
    var(--blue-50) 0%,
    transparent 65%
  );
  padding: var(--sp-20) 0 var(--sp-16);
  overflow: hidden;
}

.site-hero__img-wrap {
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  position: relative;
}
.site-hero__img-wrap::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, var(--blue-200) 0%, transparent 50%);
  z-index: 0;
  opacity: 0.4;
  pointer-events: none;
}
.site-hero__img-wrap img {
  width: 100%;
  height: auto;
  display: block;
  position: relative;
  z-index: 1;
}

.site-hero__eyebrow {
  font-size: var(--text-xs);
  font-weight: var(--fw-semi);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--sp-4);
}

.site-hero__title {
  margin-bottom: var(--sp-4);
  line-height: 1.1;
}
.site-hero__title--lead {
  display: block;
  font-weight: var(--fw-bold);
  color: var(--text-heading);
}
.site-hero__title--accent {
  display: block;
  font-weight: var(--fw-bold);
  color: var(--blue-500);
  margin-top: var(--sp-1);
}

.site-hero__sub {
  font-size: var(--text-lg);
  font-weight: var(--fw-medium);
  color: var(--text-muted);
  letter-spacing: 0.02em;
  margin-bottom: var(--sp-4);
}

.site-hero__body {
  font-size: var(--text-base);
  color: var(--text-body);
  max-width: 50ch;
  margin-bottom: var(--sp-8);
  line-height: 1.75;
}

.site-hero__ctas {
  display: flex;
  gap: var(--sp-3);
  flex-wrap: wrap;
}

@media (max-width: 991px) {
  .site-hero { padding: var(--sp-12) 0; }
}



/* ── SPLIT LAYOUT ────────────────────────────────────────────────
   2-column section, image one side, content the other.
   Default: text left, image right.
   Modifier --reverse: image left, text right.
   ─────────────────────────────────────────────────────────────── */

.split {
  display: flex;
  align-items: center;
  gap: var(--sp-12);
  margin-bottom: var(--sp-16);
}
.split:last-child { margin-bottom: 0; }

.split__text { flex: 1 1 50%; }
.split__media { flex: 1 1 45%; }

.split__media img {
  width: 100%;
  border-radius: var(--radius-md);
  object-fit: cover;
}

.split--reverse { flex-direction: row-reverse; }

@media (max-width: 768px) {
  .split, .split--reverse { flex-direction: column; gap: var(--sp-8); }
}


/* ── FULL-WIDTH BANNER IMAGE ─────────────────────────────────────
   A full-bleed image with optional overlay text.
   ─────────────────────────────────────────────────────────────── */

.full-banner {
  width: 100%;
  position: relative;
  overflow: hidden;
}

.full-banner img {
  width: 100%;
  height: 380px;
  object-fit: cover;
  display: block;
}

.full-banner--tall img { height: 520px; }
.full-banner--short img { height: 240px; }

/* Optional text overlay */
.full-banner__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    hsl(204 70% 15% / 0.72) 0%,
    transparent 60%
  );
  display: flex;
  align-items: center;
}
.full-banner__overlay-content {
  padding: 0 var(--sp-12);
  color: var(--text-on-deep);
  max-width: 600px;
}


/* ── FEATURES BANNER ─────────────────────────────────────────────
   Dark band with icon + text feature columns.
   ─────────────────────────────────────────────────────────────── */

.features-banner {
  background-color: var(--bg-deep);
  padding: var(--sp-16) 0;
}

.features-banner__title {
  font-size: var(--text-lg);
  font-weight: var(--fw-semi);
  color: var(--text-on-deep);
  text-align: center;
  margin-bottom: var(--sp-12);
}


/* ── GRID HELPERS ────────────────────────────────────────────────
   Simple semantic grids using CSS grid.
   Bootstrap's col-* system is still available for complex layouts.
   ─────────────────────────────────────────────────────────────── */

/* 3-column responsive grid */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--sp-6);
}

/* 2-column responsive grid */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: var(--sp-6);
}

/* 5-column responsive grid (team cards) */
.grid-5 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--sp-5);
}


/* ── FOOTER ──────────────────────────────────────────────────────
   ─────────────────────────────────────────────────────────────── */

.pl-footer {
  background-color: var(--bg-deep-alt);
  color: var(--text-on-deep);
  padding: var(--sp-16) 0 0;
}

.pl-footer__col-title {
  font-size: var(--text-sm);
  font-weight: var(--fw-bold);
  color: var(--text-on-deep);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: var(--sp-5);
}

.pl-footer__text {
  font-size: var(--text-sm);
  color: rgba(255,255,255,0.6);
  line-height: var(--line-height);
}

.pl-footer__links {
  list-style: none;
  padding: 0;
  margin: 0;
}
.pl-footer__links li { margin-bottom: var(--sp-3); }
.pl-footer__links a {
  color: rgba(255,255,255,0.6);
  font-size: var(--text-sm);
  text-decoration: none;
  transition: color var(--transition-fast);
}
.pl-footer__links a:hover { color: #fff; text-decoration: none; }

.pl-footer__bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: var(--sp-4) 0;
  margin-top: var(--sp-12);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-3);
  font-size: var(--text-xs);
  color: rgba(255,255,255,0.4);
}
.pl-footer__bottom a {
  color: rgba(255,255,255,0.4);
  text-decoration: none;
}
.pl-footer__bottom a:hover { color: rgba(255,255,255,0.8); }
.pl-footer__bottom-links {
  display: flex;
  gap: var(--sp-5);
}




