/* ==========================================================================
   PowerStar Inc. — Material Design 3 (Material You) implementation
   Single stylesheet. All design decisions live in the token block below.
   To re-theme the whole site, change the tokens — nothing else.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. TOKENS
   -------------------------------------------------------------------------- */
:root {
  /* Colour — tonal palette derived from the #6750A4 seed */
  --md-surface:              #FFFBFE;
  --md-surface-container:    #F3EDF7;
  --md-surface-container-lo: #E7E0EC;
  --md-on-surface:           #1C1B1F;
  --md-on-surface-variant:   #49454F;
  --md-primary:              #6750A4;
  --md-primary-rgb:          103 80 164;
  --md-on-primary:           #FFFFFF;
  --md-primary-container:    #EADDFF;
  --md-on-primary-container: #21005D;
  --md-secondary-container:  #E8DEF8;
  --md-on-secondary-container:#1D192B;
  --md-tertiary:             #7D5260;
  --md-tertiary-rgb:         125 82 96;
  --md-on-tertiary:          #FFFFFF;
  --md-tertiary-container:   #FFD8E4;
  --md-outline:              #79747E;
  --md-outline-variant:      #CAC4D0;

  /* Type */
  --font-body: "Roboto", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Roboto Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --type-display:  clamp(2.5rem, 1.6rem + 3.6vw, 3.5rem);
  --type-headline: clamp(2rem, 1.5rem + 2vw, 3rem);
  --type-headline-md: clamp(1.5rem, 1.25rem + 1vw, 2rem);
  --type-title:    1.5rem;
  --type-body-lg:  1.25rem;
  --type-body:     1rem;
  --type-label:    0.875rem;
  --type-label-sm: 0.75rem;

  /* Shape */
  --r-xs: 8px;
  --r-sm: 12px;
  --r-md: 16px;
  --r-lg: 24px;
  --r-xl: 28px;
  --r-2xl: 32px;
  --r-3xl: 48px;
  --r-full: 9999px;

  /* Elevation */
  --e1: 0 1px 2px rgb(0 0 0 / .06), 0 1px 3px rgb(0 0 0 / .04);
  --e2: 0 2px 6px rgb(0 0 0 / .08), 0 1px 2px rgb(0 0 0 / .04);
  --e3: 0 8px 24px rgb(0 0 0 / .10), 0 2px 6px rgb(0 0 0 / .05);
  --e4: 0 16px 40px rgb(0 0 0 / .12), 0 4px 10px rgb(0 0 0 / .06);

  /* Motion */
  --ease: cubic-bezier(0.2, 0, 0, 1);
  --dur-fast: 200ms;
  --dur: 300ms;

  /* Layout */
  --container: 1200px;
  --gutter: 24px;
}

/* --------------------------------------------------------------------------
   2. BASE
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--type-body);
  line-height: 1.6;
  color: var(--md-on-surface);
  background: var(--md-surface);
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 .5em;
}
h1 { font-size: var(--type-display); }
h2 { font-size: var(--type-headline); }
h3 { font-size: var(--type-headline-md); }
h4 { font-size: var(--type-title); }

p { margin: 0 0 1rem; }
a { color: var(--md-primary); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

:focus-visible {
  outline: 2px solid var(--md-primary);
  outline-offset: 2px;
  border-radius: var(--r-xs);
}

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.eyebrow {
  display: inline-block;
  font-size: var(--type-label);
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--md-primary);
  background: var(--md-secondary-container);
  padding: .35rem 1rem;
  border-radius: var(--r-full);
  margin-bottom: 1rem;
}
.lead { font-size: var(--type-body-lg); color: var(--md-on-surface-variant); }
.muted { color: var(--md-on-surface-variant); }
.section { padding-block: clamp(3rem, 6vw, 6rem); position: relative; }
.section--tonal { background: var(--md-surface-container); }
.center { text-align: center; }
.stack-sm > * + * { margin-top: .75rem; }

/* --------------------------------------------------------------------------
   3. ORGANIC BLUR SHAPES (signature MD3 atmosphere)
   -------------------------------------------------------------------------- */
.atmos { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.atmos > span {
  position: absolute;
  display: block;
  filter: blur(64px);
  mix-blend-mode: multiply;
  opacity: .55;
}
.atmos .blob-a {
  width: 46rem; height: 26rem; left: -12rem; top: -8rem;
  background: var(--md-secondary-container);
  border-radius: 100px 100px 100px 20px;
}
.atmos .blob-b {
  width: 32rem; height: 32rem; right: -10rem; bottom: -14rem;
  background: var(--md-tertiary-container);
  border-radius: 50%;
}
.atmos .blob-c {
  width: 28rem; height: 18rem; right: 22%; top: 30%;
  background: var(--md-primary-container);
  border-radius: 100px;
  opacity: .4;
}
.section > .container { position: relative; z-index: 1; }

/* --------------------------------------------------------------------------
   4. BUTTONS — always pill-shaped
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  min-height: 48px;
  padding: 0 1.75rem;
  border: 0;
  border-radius: var(--r-full);
  font: 500 var(--type-label)/1 var(--font-body);
  letter-spacing: .01em;
  cursor: pointer;
  text-decoration: none;
  transition: background-color var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease),
              transform var(--dur-fast) var(--ease);
}
.btn:hover { text-decoration: none; }
.btn:active { transform: scale(.95); }

.btn--filled { background: var(--md-primary); color: var(--md-on-primary); }
.btn--filled:hover { background: rgb(var(--md-primary-rgb) / .9); box-shadow: var(--e2); }
.btn--filled:active { background: rgb(var(--md-primary-rgb) / .8); }

.btn--tonal { background: var(--md-secondary-container); color: var(--md-on-secondary-container); }
.btn--tonal:hover { box-shadow: var(--e2); }

.btn--outlined {
  background: transparent;
  color: var(--md-primary);
  box-shadow: inset 0 0 0 1px var(--md-outline);
}
.btn--outlined:hover { background: rgb(var(--md-primary-rgb) / .08); }

.btn--text { background: transparent; color: var(--md-primary); padding-inline: 1rem; }
.btn--text:hover { background: rgb(var(--md-primary-rgb) / .1); }

.btn--on-dark { background: rgb(255 255 255 / .14); color: #fff; backdrop-filter: blur(6px); box-shadow: inset 0 0 0 1px rgb(255 255 255 / .22); }
.btn--on-dark:hover { background: rgb(255 255 255 / .22); }

.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; }

/* --------------------------------------------------------------------------
   5. HEADER / NAV
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgb(255 251 254 / .82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--md-outline-variant);
}
.site-header__bar {
  display: flex; align-items: center; gap: 1rem;
  min-height: 76px;
}
.brand { display: flex; align-items: center; gap: .75rem; margin-right: auto; }
.brand img { height: 42px; width: auto; }
.brand:hover { text-decoration: none; }

.nav { display: flex; align-items: center; gap: .25rem; }
/* :not(.btn) matters — without it these rules out-specify .btn--filled
   and the CTA inherits the grey nav link colour. */
.nav a:not(.btn) {
  display: inline-flex; align-items: center;
  min-height: 40px; padding: 0 .9rem;
  border-radius: var(--r-full);
  color: var(--md-on-surface-variant);
  font-size: var(--type-label); font-weight: 500;
  transition: background-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}
.nav a:not(.btn):hover { background: rgb(var(--md-primary-rgb) / .1); color: var(--md-primary); text-decoration: none; }
.nav a:not(.btn)[aria-current="page"] { background: var(--md-secondary-container); color: var(--md-on-secondary-container); }

/* Header CTA: slightly tighter than a page-level button so it sits in the bar */
.nav .btn {
  min-height: 40px;
  padding: 0 1.25rem;
  margin-left: .5rem;
  white-space: nowrap;
}

.nav__group { position: relative; }
.nav__panel {
  position: absolute; top: 100%; left: 0;
  margin-top: .5rem;
  min-width: 13rem; padding: .5rem;
  background: var(--md-surface-container);
  border-radius: var(--r-md);
  box-shadow: var(--e3);
  display: none; flex-direction: column;
}
/* Transparent bridge across the visual gap. Without it the cursor leaves
   .nav__group on the way down and the panel closes before you can click. */
.nav__panel::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: -.5rem;
  height: .5rem;
}
.nav__panel a { padding-block: .35rem; }
.nav__group:hover .nav__panel,
.nav__group:focus-within .nav__panel { display: flex; }

.nav-toggle {
  display: none;
  width: 48px; height: 48px;
  border: 0; border-radius: var(--r-full);
  background: transparent; cursor: pointer;
  color: var(--md-on-surface);
}
.nav-toggle:hover { background: rgb(var(--md-primary-rgb) / .1); }

@media (max-width: 1024px) {
  .nav-toggle { display: grid; place-items: center; }
  .nav {
    position: fixed; inset: 76px 0 auto 0;
    flex-direction: column; align-items: stretch;
    gap: .25rem; padding: 1rem var(--gutter) 1.5rem;
    background: var(--md-surface-container);
    border-bottom-left-radius: var(--r-xl);
    border-bottom-right-radius: var(--r-xl);
    box-shadow: var(--e3);
    max-height: calc(100dvh - 76px); overflow-y: auto;
    transform: translateY(-8px);
    opacity: 0; visibility: hidden;
    transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease), visibility var(--dur);
  }
  .nav[data-open="true"] { opacity: 1; visibility: visible; transform: translateY(0); }
  .nav a { min-height: 48px; }
  .nav__panel { position: static; display: flex; box-shadow: none; background: transparent; margin-top: 0; padding: 0 0 0 1rem; }
  .nav__panel::before { display: none; }
  .nav .btn { margin-left: 0; margin-top: .5rem; min-height: 48px; }
}

/* --------------------------------------------------------------------------
   6. HERO
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  margin: 1.25rem var(--gutter) 0;
  border-radius: var(--r-3xl);
  overflow: hidden;
  background: var(--md-surface-container);
  isolation: isolate;
}
.hero__inner {
  position: relative; z-index: 2;
  max-width: var(--container); margin-inline: auto;
  padding: clamp(3rem, 7vw, 6.5rem) clamp(1.5rem, 4vw, 4rem);
}
.hero--photo { color: #fff; }
.hero--photo::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(105deg, rgb(28 27 31 / .88) 0%, rgb(33 0 93 / .70) 55%, rgb(103 80 164 / .45) 100%);
}
.hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.hero--photo .eyebrow { background: rgb(255 255 255 / .16); color: #fff; }
.hero--photo .lead { color: rgb(255 255 255 / .86); }
.hero h1 { max-width: 18ch; }
.hero .lead { max-width: 60ch; }

.hero__meta {
  display: flex; flex-wrap: wrap; gap: .5rem .75rem;
  margin-top: 2rem; padding-top: 1.5rem;
  border-top: 1px solid rgb(255 255 255 / .18);
}
.chip {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .4rem 1rem;
  border-radius: var(--r-full);
  font-size: var(--type-label-sm); font-weight: 500; letter-spacing: .04em;
  background: var(--md-secondary-container); color: var(--md-on-secondary-container);
}
.hero--photo .chip { background: rgb(255 255 255 / .14); color: #fff; box-shadow: inset 0 0 0 1px rgb(255 255 255 / .2); }

/* page banner for interior pages */
.page-head {
  margin: 1.25rem var(--gutter) 0;
  padding: clamp(2.5rem, 5vw, 4.5rem) clamp(1.5rem, 4vw, 4rem);
  border-radius: var(--r-3xl);
  background: var(--md-surface-container);
  position: relative; overflow: hidden;
}
.page-head__inner { position: relative; z-index: 1; max-width: var(--container); margin-inline: auto; }
.page-head h1 { margin-bottom: .5rem; }

/* --------------------------------------------------------------------------
   7. CARDS & GRIDS
   -------------------------------------------------------------------------- */
.grid { display: grid; gap: 1.5rem; }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }

.card {
  background: var(--md-surface-container);
  border-radius: var(--r-lg);
  padding: 2rem;
  box-shadow: var(--e1);
  transition: box-shadow var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.card--interactive:hover { box-shadow: var(--e2); transform: scale(1.02); }
.card h3, .card h4 { margin-bottom: .5rem; }
.card p:last-child { margin-bottom: 0; }

.card--product {
  display: flex; flex-direction: column;
  padding: 0; overflow: hidden;
  color: inherit;
}
.card--product:hover { text-decoration: none; }
.card--product__media {
  aspect-ratio: 4 / 3;
  background: var(--md-surface-container-lo);
  display: grid; place-items: center;
  overflow: hidden; padding: 1.5rem;
}
.card--product__media img {
  max-height: 100%; width: auto; object-fit: contain;
  transition: transform var(--dur) var(--ease);
}
.card--product:hover .card--product__media img { transform: scale(1.05); }
.card--product__body { padding: 1.25rem 1.5rem 1.5rem; display: flex; flex-direction: column; gap: .5rem; flex: 1; }
.card--product__body h3 { font-size: var(--type-title); margin: 0; }
.card--product__spec { font-size: var(--type-label); color: var(--md-on-surface-variant); }
.card--product__cta { margin-top: auto; padding-top: .75rem; font-size: var(--type-label); font-weight: 500; color: var(--md-primary); }

.icon-badge {
  width: 56px; height: 56px;
  display: grid; place-items: center;
  border-radius: var(--r-md);
  background: var(--md-primary-container);
  color: var(--md-on-primary-container);
  margin-bottom: 1rem;
  font-weight: 500;
}
.icon-badge svg { width: 26px; height: 26px; fill: currentColor; }

/* feature list with check marks */
.ticks { list-style: none; margin: 0; padding: 0; display: grid; gap: .75rem; }
.ticks li { display: flex; gap: .75rem; align-items: flex-start; }
.ticks li::before {
  content: ""; flex: 0 0 auto;
  width: 22px; height: 22px; margin-top: .18rem;
  border-radius: var(--r-full);
  background: var(--md-primary-container);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%2321005D'%3E%3Cpath d='M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z'/%3E%3C/svg%3E");
  background-size: 16px; background-repeat: no-repeat; background-position: center;
}

/* split media + text */
.split { display: grid; gap: clamp(2rem, 5vw, 4rem); align-items: center; grid-template-columns: 1fr; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; } }
.split__media img { border-radius: var(--r-2xl); box-shadow: var(--e2); width: 100%; }
.split--reverse .split__media { order: -1; }
@media (min-width: 900px) { .split--reverse .split__media { order: 2; } }

/* glass panel on a coloured surface */
.panel-primary {
  background: var(--md-primary);
  color: var(--md-on-primary);
  border-radius: var(--r-3xl);
  padding: clamp(2.5rem, 5vw, 4rem);
  position: relative; overflow: hidden;
  box-shadow: var(--e3);
}
.panel-primary h2, .panel-primary h3 { color: #fff; }
.panel-primary p { color: rgb(255 255 255 / .85); }
.glass {
  background: rgb(255 255 255 / .12);
  border: 1px solid rgb(255 255 255 / .18);
  backdrop-filter: blur(8px);
  border-radius: var(--r-2xl);
  padding: 1.75rem;
}
.glass h3, .glass h4 { color: #fff; margin-bottom: .35rem; }
.glass p { color: rgb(255 255 255 / .82); margin: 0; }

/* stats */
.stat { text-align: center; }
.stat__value { font-size: var(--type-headline); font-weight: 700; color: var(--md-primary); line-height: 1.1; }
.panel-primary .stat__value { color: #fff; }
.stat__label { font-size: var(--type-label); color: var(--md-on-surface-variant); }
.panel-primary .stat__label { color: rgb(255 255 255 / .8); }

/* compliance badges */
.badges { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: center; }
.badges img {
  height: 84px; width: auto; object-fit: contain;
  background: #fff; padding: .75rem 1rem;
  border-radius: var(--r-md); box-shadow: var(--e1);
}

/* --------------------------------------------------------------------------
   8. MODEL FINDER  (signature component: NSN / part-number spec tables)
   -------------------------------------------------------------------------- */
.finder {
  background: var(--md-surface-container);
  border-radius: var(--r-2xl);
  padding: 1.5rem;
  box-shadow: var(--e1);
}
.finder__controls {
  display: flex; flex-wrap: wrap; gap: 1rem; align-items: flex-end;
  margin-bottom: 1.25rem;
}
.field { display: flex; flex-direction: column; flex: 1 1 260px; }
.field label {
  font-size: var(--type-label-sm); font-weight: 500;
  color: var(--md-on-surface-variant);
  padding: .35rem .9rem 0;
}
.field input, .field select {
  height: 56px;
  padding: 0 1rem;
  font: 400 var(--type-body)/1 var(--font-body);
  color: var(--md-on-surface);
  background: var(--md-surface-container-lo);
  border: 0;
  border-bottom: 2px solid var(--md-outline);
  border-radius: var(--r-sm) var(--r-sm) 0 0;
  transition: border-color var(--dur-fast) var(--ease), background-color var(--dur-fast) var(--ease);
}
.field input::placeholder { color: rgb(28 27 31 / .5); }
.field input:focus, .field select:focus {
  outline: none;
  border-bottom-color: var(--md-primary);
  background: #fff;
}
.finder__count { font-size: var(--type-label); color: var(--md-on-surface-variant); padding-bottom: 1rem; }

.table-scroll { overflow-x: auto; border-radius: var(--r-md); background: var(--md-surface); box-shadow: var(--e1); }
table.spec { width: 100%; border-collapse: collapse; font-size: var(--type-label); }
table.spec th, table.spec td { padding: .85rem 1rem; text-align: left; white-space: nowrap; }
table.spec thead th {
  position: sticky; top: 0;
  background: var(--md-secondary-container);
  color: var(--md-on-secondary-container);
  font-weight: 500; letter-spacing: .04em; text-transform: uppercase;
  font-size: var(--type-label-sm);
}
table.spec tbody tr { border-top: 1px solid var(--md-outline-variant); }
table.spec tbody tr:hover { background: rgb(var(--md-primary-rgb) / .06); }
table.spec td:first-child { font-weight: 500; font-family: var(--font-mono); }
table.spec td.nsn { font-family: var(--font-mono); color: var(--md-on-surface-variant); }
table.spec .empty { color: var(--md-outline); }
.no-results { padding: 2rem; text-align: center; color: var(--md-on-surface-variant); }

/* --------------------------------------------------------------------------
   9. FORMS
   -------------------------------------------------------------------------- */
.form { display: grid; gap: 1rem; }
.form textarea {
  min-height: 160px; padding: 1rem;
  font: 400 var(--type-body)/1.5 var(--font-body);
  background: var(--md-surface-container-lo);
  border: 0; border-bottom: 2px solid var(--md-outline);
  border-radius: var(--r-sm) var(--r-sm) 0 0;
  resize: vertical; color: var(--md-on-surface);
}
.form textarea:focus { outline: none; border-bottom-color: var(--md-primary); background: #fff; }

/* --------------------------------------------------------------------------
   10. FOOTER
   -------------------------------------------------------------------------- */
.site-footer {
  margin-top: clamp(3rem, 6vw, 5rem);
  background: var(--md-on-surface);
  color: rgb(255 255 255 / .78);
  border-top-left-radius: var(--r-3xl);
  border-top-right-radius: var(--r-3xl);
  padding: clamp(3rem, 5vw, 4.5rem) 0 2rem;
}
.site-footer a { color: rgb(255 255 255 / .78); }
.site-footer a:hover { color: #fff; }
.site-footer h4 { color: #fff; font-size: var(--type-label); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 1rem; }
.site-footer img.footer-logo { height: 48px; width: auto; margin-bottom: 1rem; }
.footer-grid { display: grid; gap: 2.5rem; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.footer-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; font-size: var(--type-label); }
.footer-bottom {
  margin-top: 3rem; padding-top: 1.5rem;
  border-top: 1px solid rgb(255 255 255 / .16);
  display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between;
  font-size: var(--type-label-sm); color: rgb(255 255 255 / .6);
}

/* --------------------------------------------------------------------------
   11. UTIL / MOTION PREFERENCES
   -------------------------------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity 500ms var(--ease), transform 500ms var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

@media (max-width: 640px) {
  .hero, .page-head { border-radius: var(--r-lg); margin-inline: 12px; }
  .panel-primary { border-radius: var(--r-2xl); }
  .card { padding: 1.5rem; }
}
