/* Shared PPV2 presentation layer. Business behavior remains plugin-owned. */

.pp-live-woo-transition {
  color: var(--pp-color-foreground);
  background: var(--pp-color-background);
  font-family: var(--pp-font-sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.pp-live-woo-transition :where(h1, h2, h3) {
  color: var(--pp-color-foreground);
  font-family: var(--pp-font-sans);
  font-weight: 650;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.pp-live-woo-transition :where(p, li) {
  text-wrap: pretty;
}

.pp-live-woo-transition :where(a) {
  color: var(--pp-color-primary);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
  transition: color var(--pp-transition);
}

.pp-live-woo-transition :where(a:hover) {
  color: var(--pp-color-primary-deep);
}

.pp-live-woo-transition
  :where(
    a,
    button,
    input,
    select,
    textarea,
    [tabindex]:not([tabindex="-1"])
  ):focus-visible {
  border-radius: var(--pp-radius-sm);
  outline: 2px solid var(--pp-color-primary);
  outline-offset: 2px;
  box-shadow: var(--pp-focus-ring);
}

.pp-live-woo-transition
  :where(
    button,
    .button,
    input[type="button"],
    input[type="submit"],
    .wp-element-button,
    .woocommerce a.button,
    .woocommerce button.button,
    .woocommerce input.button
  ) {
  min-height: 44px;
  border: 0;
  border-radius: var(--pp-radius-pill);
  background: var(--pp-color-primary);
  color: var(--pp-color-surface);
  font-family: var(--pp-font-sans);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.15;
  padding: 0.75rem 1.35rem;
  transition:
    background-color var(--pp-transition),
    color var(--pp-transition),
    transform var(--pp-transition);
}

.pp-live-woo-transition
  :where(
    button,
    .button,
    input[type="button"],
    input[type="submit"],
    .wp-element-button,
    .woocommerce a.button,
    .woocommerce button.button,
    .woocommerce input.button
  ):hover {
  background: var(--pp-color-primary-deep);
  color: var(--pp-color-surface);
}

.pp-live-woo-transition
  :where(button, .button, input[type="button"], input[type="submit"]):active {
  transform: translateY(1px);
}

.pp-live-woo-transition
  :where(
    button,
    .button,
    input[type="button"],
    input[type="submit"],
    select
  ):disabled,
.pp-live-woo-transition :where(.button.disabled, .button:disabled) {
  cursor: not-allowed;
  opacity: 0.55;
}

.pp-live-woo-transition
  :where(
    input[type="text"],
    input[type="email"],
    input[type="tel"],
    input[type="number"],
    input[type="password"],
    input[type="search"],
    select,
    textarea
  ) {
  min-height: 48px;
  border: 1px solid var(--pp-color-border-strong);
  border-radius: var(--pp-radius-sm);
  background: var(--pp-color-surface);
  color: var(--pp-color-foreground);
  font-family: var(--pp-font-sans);
  font-size: 1rem;
  line-height: 1.35;
  padding: 0.75rem 0.875rem;
  transition:
    border-color var(--pp-transition),
    box-shadow var(--pp-transition);
}

.pp-live-woo-transition
  :where(
    input[type="text"],
    input[type="email"],
    input[type="tel"],
    input[type="number"],
    input[type="password"],
    input[type="search"],
    select,
    textarea
  ):focus {
  border-color: var(--pp-color-primary);
  outline: 0;
  box-shadow: var(--pp-focus-ring);
}

.pp-live-woo-transition :where(input, textarea)::placeholder {
  color: var(--pp-color-text-soft);
  opacity: 1;
}

.pp-live-woo-transition
  :where(.woocommerce-error, .woocommerce-info, .woocommerce-message) {
  border: 1px solid var(--pp-color-border);
  border-radius: var(--pp-radius-md);
  box-shadow: none;
  color: var(--pp-color-foreground);
  font-size: 0.9375rem;
  line-height: 1.5;
  padding: 1rem 1.125rem 1rem 3rem;
}

.pp-live-woo-transition .woocommerce-message {
  border-color: color-mix(in srgb, var(--pp-color-success) 35%, white);
  background: var(--pp-color-success-soft);
}

.pp-live-woo-transition .woocommerce-info {
  background: var(--pp-color-info-soft);
}

.pp-live-woo-transition .woocommerce-error {
  border-color: color-mix(in srgb, var(--pp-color-danger) 35%, white);
  background: var(--pp-color-danger-soft);
}

.pp-live-woo-transition :where(.screen-reader-text, .visually-hidden) {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.pp-live-woo-transition :where(.screen-reader-text, .visually-hidden):focus {
  z-index: var(--pp-z-toast);
  top: 0.75rem;
  left: 0.75rem;
  width: auto !important;
  height: auto !important;
  clip: auto !important;
  padding: 0.75rem 1rem !important;
  margin: 0 !important;
  background: var(--pp-color-surface);
  color: var(--pp-color-foreground);
}

@media (prefers-reduced-motion: reduce) {
  .pp-live-woo-transition *,
  .pp-live-woo-transition *::before,
  .pp-live-woo-transition *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media (forced-colors: active) {
  .pp-live-woo-transition :where(button, .button, input, select, textarea) {
    border: 1px solid ButtonText;
  }
}

/*
 * Match the public Next header on the Woo-owned account and checkout routes.
 * The temporary WordPress header keeps ownership of links, cart state, and
 * its accessible mobile drawer; these rules only rearrange its presentation.
 */
.pp-live-woo-transition .pp-temp-header {
  border-color: var(--pp-color-border) !important;
  background: rgb(255 255 255 / 96%) !important;
  font-family: var(--pp-font-sans) !important;
  box-shadow: none !important;
}

.pp-live-woo-transition
  .pp-temp-header__logo[data-pp-continuity-wordmark="true"] {
  display: inline-flex !important;
  min-width: 0;
  align-items: center !important;
  color: var(--pp-color-foreground) !important;
  font-family: var(--pp-font-sans) !important;
  text-decoration: none !important;
}

.pp-live-woo-transition .pp-continuity-wordmark {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: 0.625rem;
}

.pp-live-woo-transition
  .pp-temp-header__logo
  img.pp-continuity-wordmark__mark {
  display: block;
  width: 2rem !important;
  height: 2rem !important;
  flex: 0 0 2rem;
  object-fit: contain;
}

.pp-live-woo-transition .pp-continuity-wordmark__text {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.pp-live-woo-transition .pp-continuity-wordmark__title {
  color: var(--pp-color-foreground);
  font-family: var(--pp-font-sans);
  font-size: 1.55rem;
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1;
  white-space: nowrap;
}

.pp-live-woo-transition .pp-continuity-wordmark__partners {
  color: var(--pp-color-primary);
}

.pp-live-woo-transition .pp-continuity-wordmark__tagline {
  margin-top: 0.18rem;
  color: rgb(110 90 143 / 82%);
  font-family: var(--pp-font-sans);
  font-size: 0.4375rem;
  font-weight: 550;
  letter-spacing: 0.22em;
  line-height: 1.2;
  text-transform: uppercase;
  white-space: nowrap;
}

@media (min-width: 1181px) {
  .pp-live-woo-transition .pp-temp-header__desktop {
    position: relative;
    display: block !important;
    padding-top: 30px;
  }

  .pp-live-woo-transition .pp-temp-header__mobile {
    display: none !important;
  }

  .pp-live-woo-transition .pp-temp-header__utility {
    border-bottom: 0 !important;
    background: var(--pp-color-surface) !important;
  }

  .pp-live-woo-transition .pp-temp-header__utility-row {
    min-height: 72px !important;
    padding-block: 10px !important;
  }

  .pp-live-woo-transition .pp-temp-header__contact-list {
    position: absolute !important;
    z-index: 2;
    top: 0;
    right: max(24px, calc((100vw - 1280px) / 2 + 32px));
    left: max(24px, calc((100vw - 1280px) / 2 + 32px));
    min-height: 30px;
    justify-content: flex-end !important;
    gap: 20px !important;
  }

  .pp-live-woo-transition .pp-temp-header__contact:first-child {
    margin-right: auto;
  }

  .pp-live-woo-transition .pp-temp-header__contact,
  .pp-live-woo-transition .pp-temp-header__contact-link {
    align-items: center !important;
    color: var(--pp-color-text-muted) !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
  }

  .pp-live-woo-transition .pp-temp-header__contact:first-child,
  .pp-live-woo-transition .pp-temp-header__contact:first-child a {
    color: var(--pp-color-foreground) !important;
    font-weight: 650 !important;
  }

  .pp-live-woo-transition .pp-temp-header__contact svg {
    margin: 0 !important;
    color: var(--pp-color-primary) !important;
  }

  .pp-live-woo-transition .pp-temp-header__utility-right {
    gap: 140px !important;
  }

  .pp-live-woo-transition .pp-temp-header__search {
    width: 244px;
    min-height: 48px;
    border-color: var(--pp-color-border) !important;
    background: var(--pp-color-surface) !important;
    padding: 4px 5px 4px 16px !important;
    box-shadow: var(--pp-shadow-control) !important;
  }

  .pp-live-woo-transition .pp-temp-header__search input {
    width: 100% !important;
    min-height: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    padding: 0 !important;
    box-shadow: none;
  }

  .pp-live-woo-transition .pp-temp-header__search button {
    width: 40px !important;
    min-width: 40px !important;
    height: 40px !important;
    min-height: 40px !important;
    padding: 0 !important;
  }

  .pp-live-woo-transition .pp-temp-header__cart-button {
    display: inline-flex !important;
    width: 102px !important;
    min-width: 102px;
    height: 48px !important;
    min-height: 48px;
    gap: 9px;
    border-color: var(--pp-color-border) !important;
    background: var(--pp-color-surface) !important;
    color: var(--pp-color-foreground) !important;
    font-size: 11px;
    font-weight: 750;
    letter-spacing: 0.16em;
    box-shadow: var(--pp-shadow-control) !important;
  }

  .pp-live-woo-transition .pp-temp-header__cart-button::after {
    content: "Cart";
    text-transform: uppercase;
  }

  .pp-live-woo-transition
    .pp-temp-header__desktop
    > .pp-temp-header__wrap {
    position: relative;
    z-index: 3;
    height: 0;
  }

  .pp-live-woo-transition .pp-temp-header__nav-row {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    min-height: 72px !important;
    justify-content: flex-start !important;
    padding: 0 !important;
    pointer-events: none;
  }

  .pp-live-woo-transition .pp-temp-header__nav-links {
    margin-left: 274px;
    gap: clamp(14px, 1.35vw, 24px) !important;
    pointer-events: auto;
  }

  .pp-live-woo-transition .pp-temp-header__nav-links a {
    position: relative;
    color: var(--pp-color-foreground) !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    white-space: nowrap;
  }

  .pp-live-woo-transition .pp-temp-header__nav-links a.is-current {
    color: var(--pp-color-primary) !important;
  }

  .pp-live-woo-transition .pp-temp-header__nav-links a.is-current::after {
    position: absolute;
    right: 0;
    bottom: -15px;
    left: 0;
    height: 2px;
    border-radius: var(--pp-radius-pill);
    background: var(--pp-color-primary);
    content: "";
  }

  .pp-live-woo-transition .pp-temp-header__account-link {
    position: absolute;
    right: 136px;
    display: inline-flex !important;
    min-width: 126px;
    min-height: 48px;
    justify-content: center;
    border: 1px solid var(--pp-color-border);
    border-radius: var(--pp-radius-pill);
    background: var(--pp-color-surface);
    color: var(--pp-color-foreground) !important;
    box-shadow: var(--pp-shadow-control);
    pointer-events: auto;
  }
}

@media (min-width: 992px) and (max-width: 1180px) {
  .pp-live-woo-transition .pp-temp-header__desktop {
    display: none !important;
  }

  .pp-live-woo-transition .pp-temp-header__mobile {
    display: block !important;
  }
}

@media (max-width: 1180px) {
  .pp-live-woo-transition .pp-continuity-wordmark {
    gap: 0.5rem;
  }

  .pp-live-woo-transition .pp-continuity-wordmark__title {
    font-size: 1rem;
    letter-spacing: -0.035em;
  }

  .pp-live-woo-transition .pp-continuity-wordmark__tagline {
    font-size: 0.375rem;
    letter-spacing: 0.18em;
  }
}

@media (max-width: 359px) {
  .pp-live-woo-transition .pp-continuity-wordmark__text {
    display: none;
  }
}
