/*
 * PT Biru Waste Management — page-specific overrides on top of _base.css.
 *
 * Per subsidiaries-standalone-handoff.md Phase 4 + the 2026-08-11
 * follow-up chat: keeps the type family in the Space Grotesk / IBM Plex
 * family (brand-thread continuity default from §2 of the handoff), but
 * uses Space Grotesk itself for display rather than Aero's Big Shoulders
 * Display or Naval's Archivo Black, paired with a lighter weight (600)
 * than either — distinct from both siblings.
 *
 * Warm/environmental palette (kleanindustries.com / Hitachi Zosen Inova
 * direction from handoff §2) — forest green as the primary accent, a
 * warm amber as the secondary accent standing in for the pyrolysis
 * heat/fire moment in the process diagram. This does NOT borrow the main
 * site's --biru-yellow or --accent tokens (per _base.css's note: only
 * the font family is shared across the 3 standalone pages, not palette).
 *
 * Structurally lighter-weight than Aero/Naval on purpose: no capability
 * strip, no stat-spotlight — this subsidiary's whole job is a short page
 * that CTAs into /product/hydrodrive-technology (handoff §6), so the
 * page is About → Process diagram → Spec strip → Gallery → Closing CTA.
 * Not full-bleed edge-to-edge like Aero's gallery/cap-strip either —
 * kept inside a contained width throughout, matching the shorter/lighter
 * brief instead of the aerospace/naval "hardware operator" tone.
 */

.bwm {
  --bwm-font-display: "Space Grotesk", "Segoe UI", system-ui, sans-serif;
  --bwm-font-mono: "IBM Plex Mono", "Courier New", monospace;
  --bwm-font-body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;

  --bwm-bg: #f7f5ee;
  --bwm-bg-2: #ffffff;
  --bwm-ink: #12201a;
  --bwm-ink-2: #52604f;
  --bwm-line: #dde3d5;
  --bwm-accent: #2f7a4d;
  --bwm-accent-2: #5aa876;
  /* warm amber, paired with the green for the pyrolysis/heat moment in
     the process diagram — same role --iap-accent-red plays for Aero */
  --bwm-accent-warm: #d98a2b;
  --bwm-accent-warm-2: #f0b567;

  background: var(--bwm-bg);
  color: var(--bwm-ink);
  font-family: var(--bwm-font-body);
  overflow-x: hidden;
}

.bwm h1, .bwm h2, .bwm h3 {
  font-family: var(--bwm-font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
}

/* reduced motion: kill everything animated, show content immediately */
@media (prefers-reduced-motion: reduce) {
  .bwm * { animation: none !important; transition: none !important; }
}

/* ---------------------------------------------------------------------
 * Scroll-reveal
 * ------------------------------------------------------------------- */
.reveal-init {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal-init.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------------------------------------------------------------------
 * Buttons / links
 * ------------------------------------------------------------------- */
.bwm-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 24px;
  border-radius: 100px;
  font-weight: 600;
  font-size: 0.92rem;
  white-space: nowrap;
  transition: transform .25s ease, background .25s ease, color .25s ease, border-color .25s ease;
}
.bwm-btn i { transition: transform .25s ease; font-size: 0.82em; }
.bwm-btn:hover i { transform: translateX(3px); }
.bwm-btn-primary {
  background: var(--bwm-accent);
  color: #fff;
}
.bwm-btn-primary:hover { background: #256640; transform: translateY(-1px); }
.bwm-btn-outline {
  background: transparent;
  color: var(--bwm-ink);
  border: 1.5px solid var(--bwm-line);
}
.bwm-btn-outline:hover { border-color: var(--bwm-accent); color: var(--bwm-accent); }

.bwm-btn-scroll {
  background: #ffffff00;
  color: #fff;
  border: 1.5px solid rgba(255,255,255,0.35);
}
.bwm-topbar.is-scrolled .bwm-btn-scroll {
  background: var(--bwm-accent);
  color: #fff;
  border-color: var(--bwm-accent);
}
.bwm-btn-scroll:hover { transform: translateY(-1px); }

.bwm-textlink {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  color: var(--bwm-accent);
  border-bottom: 2px solid transparent;
  padding-bottom: 2px;
  transition: border-color .25s ease;
}
.bwm-textlink i { transition: transform .25s ease; }
.bwm-textlink:hover { border-color: var(--bwm-accent); }
.bwm-textlink:hover i { transform: translateX(3px); }

.bwm-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--bwm-font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--bwm-accent);
  margin-bottom: 18px;
}
.bwm-eyebrow-light { color: var(--bwm-accent-warm-2); }

/* ---------------------------------------------------------------------
 * Topbar
 * ------------------------------------------------------------------- */
.bwm-topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: transparent;
  transition: background .35s ease, box-shadow .35s ease, padding .35s ease;
  padding: 22px 0;
}
.bwm-topbar.is-scrolled {
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 var(--bwm-line);
  padding: 12px 0;
}
.bwm-topbar-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 48px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.bwm-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  transition: color .35s ease;
}
.bwm-topbar.is-scrolled .bwm-logo { color: var(--bwm-ink); }
.bwm-logo-mark {
  width: 34px; height: 34px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--bwm-accent);
  color: #fff;
  font-size: 0.9rem;
  flex-shrink: 0;
}
.bwm-logo-text {
  font-family: var(--bwm-font-display);
  font-weight: 600;
  font-size: 0.78rem;
  line-height: 1.15;
  letter-spacing: 0.02em;
}
.bwm-nav {
  display: flex;
  gap: 30px;
  font-size: 0.86rem;
  font-weight: 500;
}
.bwm-nav a {
  position: relative;
  color: #fff;
  transition: color .35s ease;
  padding-bottom: 4px;
}
.bwm-topbar.is-scrolled .bwm-nav a { color: var(--bwm-ink-2); }
.bwm-nav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0; height: 2px;
  background: var(--bwm-accent);
  transition: width .25s ease;
}
.bwm-nav a:hover { color: var(--bwm-accent); }
.bwm-nav a:hover::after { width: 100%; }
.bwm-topbar-cta { flex-shrink: 0; }
.bwm-nav-toggle {
  display: none;
  background: none; border: 0;
  color: #fff;
  font-size: 1.3rem;
}
.bwm-topbar.is-scrolled .bwm-nav-toggle { color: var(--bwm-ink); }

@media (max-width: 860px) {
  .bwm-nav {
    position: fixed;
    top: 0; right: 0;
    height: 100svh;
    width: min(78vw, 320px);
    background: var(--bwm-ink);
    flex-direction: column;
    align-items: flex-start;
    gap: 26px;
    padding: 100px 32px 40px;
    transform: translateX(100%);
    transition: transform .35s ease;
  }
  .bwm-nav.is-open { transform: translateX(0); }
  .bwm-nav a { color: #fff; font-size: 1.05rem; }
  .bwm-topbar-cta { display: none; }
  .bwm-nav-toggle { display: block; position: relative; z-index: 101; }
}

/* ---------------------------------------------------------------------
 * Hero — real Hydrodrive video background, no radar/sonar motif
 * ------------------------------------------------------------------- */
.bwm-hero {
  position: relative;
  min-height: 100svh;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  background: var(--bwm-ink);
  color: #fff;
}
.bwm-hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.bwm-hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(18,32,26,0.55) 0%, rgba(18,32,26,0.6) 55%, rgba(18,32,26,0.78) 100%);
}

.bwm-hero-label {
  position: relative;
  z-index: 2;
  display: inline-block;
  margin: clamp(90px, 14vh, 150px) 0 0;
  margin-left: clamp(16px, 4vw, 44px);
  padding: 7px 16px;
  background: var(--bwm-accent);
  font-family: var(--bwm-font-mono);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: #fff;
}

.bwm-hero-content {
  position: relative;
  z-index: 2;
  padding: clamp(18px, 3vh, 30px) clamp(16px, 4vw, 44px) 0;
  max-width: 900px;
}
.bwm-hero-title {
  display: flex;
  flex-direction: column;
  font-size: clamp(2.8rem, 2vw + 3.2rem, 5.2rem);
  line-height: 1.02;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  font-weight: 600;
  text-shadow: 0 4px 30px rgba(0,0,0,0.35);
}
.bwm-hero-title-accent { color: var(--bwm-accent-2); }
.bwm-hero-subtitle {
  margin-top: 20px;
  font-size: 1.1rem;
  color: rgba(255,255,255,0.85);
  max-width: 520px;
}

.bwm-hero-info {
  position: absolute;
  z-index: 2;
  right: clamp(16px, 4vw, 44px);
  bottom: clamp(60px, 10vh, 110px);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  font-family: var(--bwm-font-mono);
}
.bwm-hero-info-badge {
  padding: 7px 16px;
  background: var(--bwm-accent-warm);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  white-space: nowrap;
}
.bwm-hero-info-tag {
  display: flex;
  align-items: stretch;
  height: 30px;
}
.bwm-hero-info-tag-text {
  display: flex;
  align-items: center;
  padding: 0 14px;
  background: var(--bwm-accent);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  white-space: nowrap;
}
.bwm-hero-info-tag-stripe {
  width: 90px;
  background: repeating-linear-gradient(
    -45deg,
    var(--bwm-accent-2) 0 8px,
    rgba(18,32,26,0.85) 8px 16px
  );
  opacity: 0.9;
}
.bwm-hero-info-line {
  font-size: 0.85rem;
  font-weight: 600;
  color: #fff;
  letter-spacing: 0.02em;
}
.bwm-hero-scroll {
  position: absolute;
  z-index: 2;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  color: rgba(255,255,255,0.6);
  font-size: 1.1rem;
  animation: bwm-bob 2.2s ease-in-out infinite;
}
@keyframes bwm-bob {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 8px); }
}

@media (max-width: 640px) {
  .bwm-hero-title { font-size: clamp(2.2rem, 10vw, 3.4rem); }
  .bwm-hero-info { display: none; }
}

/* ---------------------------------------------------------------------
 * About / proof split
 * ------------------------------------------------------------------- */
.bwm-about {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  align-items: stretch;
  background: var(--bwm-bg-2);
}
.bwm-about-media { overflow: hidden; }
.bwm-about-media img {
  width: 100%; height: 100%;
  min-height: 380px;
  object-fit: cover;
}
.bwm-about-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(48px, 6vw, 96px) clamp(24px, 6vw, 88px);
  max-width: 640px;
}
.bwm-about-title {
  font-size: clamp(1.8rem, 1.1rem + 2.4vw, 2.6rem);
  margin-bottom: 20px;
}
.bwm-about-text {
  font-size: 1.02rem;
  line-height: 1.75;
  color: var(--bwm-ink-2);
  margin-bottom: 18px;
}

@media (max-width: 860px) {
  .bwm-about { grid-template-columns: 1fr; }
  .bwm-about-media img { min-height: 260px; }
}

/* ---------------------------------------------------------------------
 * Shared section header (process + specs + gallery all use this)
 * ------------------------------------------------------------------- */
.bwm-cap-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(20px, 5vw, 64px) clamp(28px, 4vw, 40px);
  gap: 20px;
  flex-wrap: wrap;
}
.bwm-cap-title {
  font-size: clamp(1.7rem, 1.1rem + 2vw, 2.4rem);
}

/* ---------------------------------------------------------------------
 * Process diagram — signature section, replaces the spotlight/subsystem
 * strip Aero/Naval use. Waste in -> pyrolysis -> clean output, animated
 * flow-path (a dot travelling along each connector line, looped).
 * ------------------------------------------------------------------- */
.bwm-process { background: var(--bwm-bg); padding: clamp(56px, 7vw, 96px) 0; }

.bwm-flow {
  padding: 0 clamp(20px, 5vw, 64px);
  display: flex;
  align-items: flex-start;
  gap: 0;
}
.bwm-flow-stage {
  flex: 1 1 0;
  background: var(--bwm-bg-2);
  border: 1px solid var(--bwm-line);
  border-radius: 12px;
  padding: clamp(24px, 3vw, 36px) clamp(18px, 2.4vw, 26px);
  text-align: center;
}
.bwm-flow-icon {
  width: 56px; height: 56px;
  margin: 0 auto 16px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--bwm-accent);
  color: #fff;
  font-size: 1.35rem;
}
.bwm-flow-stage-heat .bwm-flow-icon { background: var(--bwm-accent-warm); }
.bwm-flow-index {
  display: block;
  font-family: var(--bwm-font-mono);
  font-size: 0.75rem;
  color: var(--bwm-ink-2);
  letter-spacing: 0.08em;
  margin-bottom: 6px;
}
.bwm-flow-title { font-size: 1.15rem; margin-bottom: 8px; }
.bwm-flow-desc { font-size: 0.92rem; line-height: 1.55; color: var(--bwm-ink-2); }

.bwm-flow-connector {
  position: relative;
  flex: 0 0 clamp(28px, 6vw, 90px);
  align-self: center;
  height: 24px;
  margin-top: -40px;
}
.bwm-flow-connector svg { width: 100%; height: 100%; overflow: visible; }
.bwm-flow-line {
  stroke: var(--bwm-line);
  stroke-width: 2;
}
.bwm-flow-dot {
  position: absolute;
  top: 50%; left: 0;
  width: 8px; height: 8px;
  margin-top: -4px;
  border-radius: 50%;
  background: var(--bwm-accent-2);
  box-shadow: 0 0 0 4px rgba(90, 168, 118, 0.2);
  animation: bwm-flow-travel 2.6s linear infinite;
}
.bwm-flow-dot-delay { animation-delay: 1.3s; }
@keyframes bwm-flow-travel {
  0% { left: 0; opacity: 0; }
  8% { opacity: 1; }
  92% { opacity: 1; }
  100% { left: calc(100% - 8px); opacity: 0; }
}

@media (max-width: 860px) {
  .bwm-flow { flex-direction: column; }
  .bwm-flow-connector {
    flex: 0 0 auto;
    width: 24px;
    height: clamp(28px, 6vh, 60px);
    margin: -8px auto;
    transform: rotate(90deg);
  }
}

/* ---------------------------------------------------------------------
 * Spec strip — real Hydrodrive numbers (page_spec_items, page id 69)
 * ------------------------------------------------------------------- */
.bwm-specs { background: var(--bwm-bg-2); padding: clamp(48px, 6vw, 80px) 0; }
.bwm-spec-grid {
  padding: 0 clamp(20px, 5vw, 64px);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px 20px;
}
.bwm-spec { border-left: 2px solid var(--bwm-accent); padding-left: 16px; }
.bwm-spec-value {
  display: block;
  font-family: var(--bwm-font-mono);
  font-weight: 600;
  font-size: clamp(1.15rem, 0.9rem + 0.7vw, 1.4rem);
  color: var(--bwm-ink);
}
.bwm-spec-label {
  display: block;
  margin-top: 4px;
  font-size: 0.8rem;
  color: var(--bwm-ink-2);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

@media (max-width: 860px) {
  .bwm-spec-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---------------------------------------------------------------------
 * Gallery — full-bleed large panels (same treatment as Aero/Naval:
 * overrides _base.css's .sub-gallery small-tile grid for THIS page,
 * re-skinned to the green/amber palette). This is shared plumbing per
 * the handoff, not something the shorter brief should have trimmed.
 * ------------------------------------------------------------------- */
.bwm-gallery-section { background: var(--bwm-bg); padding-top: clamp(56px, 7vw, 96px); }
.bwm-gallery-head { padding-bottom: clamp(24px, 3vw, 36px); }

.bwm-gallery-section .sub-gallery {
  display: flex;
  width: 100%;
  height: clamp(360px, 60vh, 640px);
  gap: 0;
}
.bwm-gallery-section .sub-gallery-item {
  position: relative;
  flex: 1 1 0;
  height: 100%;
  border-radius: 0;
  overflow: hidden;
  transition: flex-grow .45s ease;
}
.bwm-gallery-section .sub-gallery-item:hover { flex-grow: 1.6; }
.bwm-gallery-section .sub-gallery-item img {
  aspect-ratio: unset;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
}
.bwm-gallery-section .sub-gallery-item:hover img { transform: scale(1.05); }
.bwm-gallery-section .sub-gallery-item::after {
  content: attr(data-caption);
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 18px clamp(12px, 2vw, 20px);
  font-family: var(--bwm-font-mono);
  font-size: 0.78rem;
  color: #fff;
  background: linear-gradient(0deg, rgba(18,32,26,0.75) 0%, rgba(18,32,26,0) 100%);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .3s ease, transform .3s ease;
}
.bwm-gallery-section .sub-gallery-item:hover::after { opacity: 1; transform: translateY(0); }

@media (max-width: 720px) {
  .bwm-gallery-section .sub-gallery { flex-direction: column; height: auto; }
  /* flex-basis must be explicit here, not the desktop rule's "0" — see
     Aero's identical note: column-direction flex-basis:0 wins over
     height and every item collapses to ~0px tall otherwise. */
  .bwm-gallery-section .sub-gallery-item { flex: 0 0 260px; height: 260px; }
  .bwm-gallery-section .sub-gallery-item:hover { flex-grow: 0; }
}

/* ---------------------------------------------------------------------
 * Closing CTA band
 * ------------------------------------------------------------------- */
.bwm-closing {
  position: relative;
  min-height: 54vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: #fff;
  text-align: center;
}
.bwm-closing-bg {
  position: absolute; inset: 0;
  background-size: cover;
  background-position: center;
  background-color: var(--bwm-ink);
}
.bwm-closing-overlay {
  position: absolute; inset: 0;
  background: rgba(18,32,26,0.84);
}
.bwm-closing-content {
  position: relative;
  z-index: 2;
  padding: 72px clamp(20px, 5vw, 64px);
  max-width: 720px;
}
.bwm-closing-title {
  font-size: clamp(1.7rem, 1.1rem + 2.2vw, 2.6rem);
  margin-bottom: 16px;
}
.bwm-closing-text {
  font-size: 1rem;
  color: rgba(255,255,255,0.8);
  line-height: 1.6;
  margin-bottom: 30px;
}

/* ---------------------------------------------------------------------
 * Footer
 * ------------------------------------------------------------------- */
.bwm-footer {
  background: var(--bwm-ink);
  color: rgba(255,255,255,0.6);
  text-align: center;
  padding: 22px clamp(20px, 5vw, 64px);
  font-size: 0.82rem;
}
.bwm-footer a { color: rgba(255,255,255,0.85); font-weight: 600; }
.bwm-footer a:hover { color: var(--bwm-accent-2); }