/* KineticPep — component styles */

/* ===== BUTTON ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: -0.005em;
  transition: transform 200ms ease, box-shadow 200ms ease, background 200ms ease, border-color 200ms ease, color 200ms ease;
  border: 1px solid transparent;
  white-space: nowrap;
  cursor: pointer;
}
.btn-primary {
  background: var(--accent-cyan);
  color: var(--ink-primary);
  font-weight: 700;
}
.btn-primary:hover {
  background: var(--accent-cyan-deep);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-cyan);
}
.btn-ghost {
  background: transparent;
  color: var(--ink-primary);
  border-color: var(--border-strong);
}
.btn-ghost.on-dark { color: #fff; border-color: rgba(255,255,255,0.25); }
.btn-ghost:hover { border-color: var(--accent-cyan); color: var(--accent-cyan); }
.btn-ghost.on-dark:hover { border-color: var(--accent-cyan); color: var(--accent-cyan); }
.btn-sm    { padding: 8px 14px; font-size: 0.8125rem; }
.btn-lg    { padding: 18px 28px; font-size: 1rem; }
.btn-block { width: 100%; }

/* ===== STATUS PILL ===== */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.pill::before {
  content: '';
  width: 6px; height: 6px; border-radius: 50%;
  background: currentColor;
}
.pill-approved { background: var(--approved-bg); color: #008060; }
.pill-research { background: var(--research-bg); color: #C25A1A; }
.pill-stock    { background: rgba(0, 200, 150, 0.12); color: #008060; }
.pill-sold-out { background: rgba(138, 149, 171, 0.15); color: var(--ink-secondary); }
.pill-lg { padding: 8px 14px; font-size: 0.75rem; }

/* ===== EYEBROW ===== */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-secondary);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: '';
  width: 6px; height: 6px;
  background: var(--accent-cyan);
  border-radius: 50%;
}
.eyebrow.on-dark { color: var(--accent-cyan); }

/* ===== CARD ===== */
.card {
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  transition: transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
}
.card.hover-lift:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-strong);
}

/* ===== INPUT ===== */
.input {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  background: var(--bg-elevated);
  font-size: 0.9375rem;
  color: var(--ink-primary);
  transition: border-color 200ms ease, box-shadow 200ms ease;
}
.input:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.15);
}
.input.on-dark {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.15);
  color: #fff;
}

/* ===== HEADER ===== */
.kp-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--bg-primary);
  border-bottom: 1px solid transparent;
  transition: all 200ms ease;
}
.kp-header.scrolled {
  background: rgba(247, 248, 250, 0.85);
  backdrop-filter: saturate(150%) blur(12px);
  -webkit-backdrop-filter: saturate(150%) blur(12px);
  border-bottom-color: var(--border-subtle);
}
.kp-header__inner {
  height: var(--header-height);
  display: flex; align-items: center; justify-content: space-between; gap: 32px;
}
.kp-header__nav { display: flex; gap: 32px; }
.kp-header__nav a {
  font-size: 0.9375rem; font-weight: 500;
  color: var(--ink-secondary);
  position: relative; padding: 8px 0;
  transition: color 200ms ease;
}
.kp-header__nav a:hover, .kp-header__nav a.active { color: var(--ink-primary); }
.kp-header__nav a.active::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--accent-cyan);
}
.kp-header__icons { display: flex; gap: 4px; align-items: center; }
.kp-header__icon-btn {
  width: 40px; height: 40px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-secondary);
  transition: all 200ms ease;
  position: relative;
  background: none; border: none; cursor: pointer;
}
.kp-header__icon-btn:hover { background: var(--bg-elevated); color: var(--ink-primary); }
.kp-cart-badge {
  position: absolute; top: 4px; right: 4px;
  background: var(--accent-cyan); color: var(--ink-primary);
  border-radius: 999px; min-width: 18px; height: 18px; padding: 0 5px;
  font-size: 0.6875rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono);
}

/* ===== TRUST BAR ===== */
.kp-trust-bar {
  background: #0B1F3A; color: rgba(255,255,255,0.85);
  height: 36px; display: flex; align-items: center; overflow: hidden;
}
.kp-trust-bar__inner {
  width: 100%; display: flex; gap: 36px; align-items: center; overflow-x: auto;
}
.kp-trust-bar__item {
  display: flex; align-items: center; gap: 8px;
  font-size: 0.75rem; white-space: nowrap;
  font-family: var(--font-mono); letter-spacing: 0.04em;
}
.kp-trust-bar__item svg { color: var(--accent-cyan); }

/* ===== FOOTER ===== */
.kp-footer { background: #08182E; color: rgba(255,255,255,0.65); padding: 80px 0 32px; }
.kp-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 64px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.kp-footer__grid h5 {
  font-family: var(--font-heading); font-size: 0.8125rem; font-weight: 600; color: #fff;
  letter-spacing: 0.08em; text-transform: uppercase; margin: 0 0 20px 0;
}
.kp-footer__grid a {
  display: block; padding: 6px 0; font-size: 0.875rem;
  transition: color 200ms ease;
}
.kp-footer__grid a:hover { color: var(--accent-cyan); }
.kp-footer__brand { max-width: 320px; margin: 0; }
.kp-footer__social { display: flex; gap: 8px; margin-top: 24px; }
.kp-footer__social a {
  width: 36px; height: 36px; border: 1px solid rgba(255,255,255,0.15); border-radius: 8px;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-size: 0.6875rem; letter-spacing: 0.05em;
  transition: all 200ms ease;
  padding: 0;
}
.kp-footer__social a:hover {
  background: var(--accent-cyan); color: var(--ink-primary);
  border-color: var(--accent-cyan);
}
.kp-footer__legal {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 32px; gap: 24px; flex-wrap: wrap; font-size: 0.8125rem;
}
@media (max-width: 768px) {
  .kp-footer__grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .kp-header__nav { display: none; }
}

/* ===== PRODUCT CARD ===== */
.kp-product-card {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.kp-product-card__media {
  position: relative;
  aspect-ratio: 1;
  background: linear-gradient(135deg, #F7F8FA 0%, #EEF1F6 100%);
  overflow: hidden;
}
.kp-product-card__pill-tl { position: absolute; top: 12px; left: 12px; z-index: 2; }
.kp-product-card__pill-tr { position: absolute; top: 12px; right: 12px; z-index: 2; }
.kp-product-card__vial {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
}
.kp-product-card__vial svg { width: 70%; height: 70%; }
.kp-product-card__body {
  padding: 24px;
  display: flex; flex-direction: column; gap: 8px; flex: 1;
}
.kp-product-card__cat {
  font-family: var(--font-mono);
  font-size: 0.6875rem; color: var(--ink-muted);
  letter-spacing: 0.1em; text-transform: uppercase;
}
.kp-product-card__meta {
  font-family: var(--font-mono); font-size: 0.875rem; color: var(--ink-secondary);
}
.kp-product-card__short {
  font-size: 0.875rem; color: var(--ink-secondary); margin: 4px 0 12px; flex: 1;
}
.kp-product-card__price-row {
  display: flex; justify-content: space-between; align-items: center; margin-top: auto;
}
.kp-product-card__price-label {
  font-family: var(--font-mono);
  font-size: 0.6875rem; color: var(--ink-muted);
  letter-spacing: 0.06em;
}
.kp-product-card__price {
  font-family: var(--font-heading);
  font-size: 1.25rem; font-weight: 600;
}

/* ===== CART DRAWER (static) ===== */
.kp-cart-drawer {
  position: fixed; top: 0; right: 0; bottom: 0;
  width: 420px; max-width: 100vw;
  background: var(--bg-elevated);
  box-shadow: var(--shadow-lg);
  display: flex; flex-direction: column;
  z-index: 100;
}
.kp-cart-drawer__head {
  padding: 24px;
  display: flex; justify-content: space-between; align-items: center;
  border-bottom: 1px solid var(--border-subtle);
}
.kp-cart-drawer__body { flex: 1; overflow-y: auto; padding: 16px 24px; }
.kp-cart-drawer__foot {
  padding: 24px;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-primary);
}
.kp-cart-line {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border-subtle);
  align-items: center;
}
.kp-cart-line__thumb {
  width: 64px; height: 64px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #F7F8FA 0%, #EEF1F6 100%);
  display: flex; align-items: center; justify-content: center;
}

/* ===== KP MOBILE NAV (burger + drawer) ===== */
.kp-header__burger {
  display: none;
  width: 40px; height: 40px; border-radius: 10px;
  align-items: center; justify-content: center;
  color: var(--ink-primary);
  background: none; border: none; cursor: pointer;
  margin-right: 4px;
}
.kp-header__burger:hover { background: var(--bg-elevated); }

@media (max-width: 768px) {
  .kp-header__burger { display: inline-flex; }
  .kp-header__nav { display: none; }
  .kp-header__inner { gap: 12px; }
  .kp-header__logo { margin-right: auto; }
}

/* Drawer */
.kp-mobile-drawer {
  position: fixed; top: 0; left: 0; bottom: 0;
  width: 320px; max-width: 86vw;
  background: var(--bg-elevated);
  z-index: 110;
  transform: translateX(-100%);
  transition: transform 280ms cubic-bezier(0.4, 0, 0.2, 1);
  display: flex; flex-direction: column;
  box-shadow: var(--shadow-lg);
  visibility: hidden;
}
.kp-mobile-drawer.is-open {
  transform: translateX(0);
  visibility: visible;
}
.kp-mobile-drawer__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-subtle);
}
.kp-mobile-drawer__close {
  width: 36px; height: 36px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-secondary);
  background: none; border: none; cursor: pointer;
}
.kp-mobile-drawer__close:hover { background: var(--bg-primary); color: var(--ink-primary); }
.kp-mobile-drawer__nav {
  display: flex; flex-direction: column;
  padding: 16px 8px;
  flex-grow: 0;
}
.kp-mobile-drawer__nav a {
  padding: 14px 16px;
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--ink-primary);
  border-radius: 10px;
  transition: background 200ms ease, color 200ms ease;
}
.kp-mobile-drawer__nav a:hover {
  background: var(--bg-primary);
  color: var(--accent-cyan-deep);
}
.kp-mobile-drawer__nav--secondary a {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--ink-secondary);
}
.kp-mobile-drawer__divider {
  height: 1px;
  background: var(--border-subtle);
  margin: 8px 24px;
}
.kp-mobile-drawer__foot {
  margin-top: auto;
  padding: 24px;
  border-top: 1px solid var(--border-subtle);
}

.kp-mobile-overlay {
  position: fixed; inset: 0;
  background: rgba(11, 31, 58, 0.5);
  z-index: 105;
  opacity: 0;
  visibility: hidden;
  transition: opacity 240ms ease, visibility 240ms ease;
}
.kp-mobile-overlay.is-open { opacity: 1; visibility: visible; }

body.kp-no-scroll { overflow: hidden; }

/* ===== KP PDP CUSTOMIZATIONS ===== */
.kp-pdp-media img,
.kp-pdp-media svg {
  width: 100%;
  height: auto;
  max-width: 360px;
}
.kp-pdp-status[data-tag="Approved"] {
  background: var(--approved-bg);
  color: #008060;
}
.kp-pdp-status[data-tag="Research"] {
  background: var(--research-bg);
  color: #C25A1A;
}
/* Default pill style if no data-tag set */
.kp-pdp-status:not([data-tag]) {
  background: rgba(0, 212, 255, 0.12);
  color: var(--accent-cyan-deep);
}
.kp-pdp-info .price {
  font-family: var(--font-heading);
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--ink-primary);
}
.kp-pdp-info .price del {
  color: var(--ink-muted);
  font-size: 1.25rem;
  font-weight: 500;
  margin-right: 8px;
}
.kp-pdp-info .price ins {
  text-decoration: none;
  color: var(--accent-cyan-deep);
}
/* WC add-to-cart form styling */
.kp-pdp-cta form.cart {
  display: flex;
  gap: 12px;
  align-items: stretch;
}
.kp-pdp-cta form.cart .quantity {
  display: flex;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-elevated);
}
.kp-pdp-cta form.cart input.qty {
  width: 64px;
  padding: 14px 12px;
  border: none;
  background: transparent;
  font-family: var(--font-mono);
  font-size: 0.9375rem;
  text-align: center;
  color: var(--ink-primary);
  appearance: textfield;
}
.kp-pdp-cta form.cart input.qty::-webkit-outer-spin-button,
.kp-pdp-cta form.cart input.qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.kp-pdp-cta form.cart button[type="submit"],
.kp-pdp-cta form.cart .single_add_to_cart_button {
  flex: 1;
  background: var(--accent-cyan);
  color: var(--ink-primary);
  font-weight: 700;
  padding: 14px 24px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  font-size: 0.9375rem;
  cursor: pointer;
  transition: transform 200ms ease, box-shadow 200ms ease, background 200ms ease, color 200ms ease;
}
.kp-pdp-cta form.cart button[type="submit"]:hover,
.kp-pdp-cta form.cart .single_add_to_cart_button:hover {
  background: var(--accent-cyan-deep);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-cyan);
}
/* Related products grid via Bricks/WC */
ul.products {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
ul.products li.product {
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 16px;
  transition: transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
}
ul.products li.product:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-strong);
}
ul.products li.product img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  background: linear-gradient(135deg, #F7F8FA 0%, #EEF1F6 100%);
  border-radius: var(--radius-md);
}
ul.products li.product h2,
ul.products li.product .woocommerce-loop-product__title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  margin-top: 12px;
  color: var(--ink-primary);
}
ul.products li.product .price {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1.125rem;
  color: var(--ink-primary);
  display: block;
  margin-top: 4px;
}
ul.products li.product .button {
  margin-top: 12px;
  display: inline-block;
  padding: 8px 14px;
  border-radius: var(--radius-md);
  background: var(--ink-primary);
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 600;
  text-decoration: none;
}
ul.products li.product .button:hover {
  background: var(--accent-cyan-deep);
}
@media (max-width: 992px) {
  .kp-pdp-grid { grid-template-columns: 1fr !important; }
  ul.products { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  ul.products { grid-template-columns: 1fr; }
  .kp-pdp-specs { grid-template-columns: 1fr 1fr !important; }
}
/* ===== KP PDP POLISH (links inside pills + dynamic status colors) ===== */
.kp-pdp-status a,
.kp-pdp-info .mono a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 200ms ease;
}
.kp-pdp-status a:hover,
.kp-pdp-info .mono a:hover {
  border-bottom-color: currentColor;
}
.kp-pdp-status:has(a[href*="/approved"]) {
  background: var(--approved-bg);
}
.kp-pdp-status:has(a[href*="/approved"]) a {
  color: #008060;
}
.kp-pdp-status:has(a[href*="/research"]) {
  background: var(--research-bg);
}
.kp-pdp-status:has(a[href*="/research"]) a {
  color: #C25A1A;
}

/* WC price block: hide deep-nested wrapper bloat */
.kp-pdp-price .woocommerce-Price-amount {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--ink-primary);
}
.kp-pdp-price del .woocommerce-Price-amount {
  color: var(--ink-muted);
  font-size: 1.25rem;
  font-weight: 500;
  margin-right: 8px;
}
.kp-pdp-price ins {
  text-decoration: none;
}

/* Featured image via Bricks {featured_image} sometimes wraps in figure */
.kp-pdp-media figure,
.kp-pdp-media .woocommerce-product-gallery {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}
.kp-pdp-media .woocommerce-product-gallery__image img {
  width: 100%;
  max-width: 360px;
  height: auto;
}
