/* ================= interaction layer ================= */
.catalog-home,
.info-page {
  --v3-dur: 180ms;
  --v3-ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --v3-ring: 0 0 0 2px #fff, 0 0 0 4px rgba(107, 75, 245, 0.65);
}

/* keyboard focus: always visible, never removed without a replacement */
.catalog-home :focus-visible,
.info-page :focus-visible {
  outline: 2px solid var(--v3-violet, #6b4bf5);
  outline-offset: 2px;
  border-radius: 6px;
}
.catalog-home .btn:focus-visible,
.info-page .btn:focus-visible {
  outline: none;
  box-shadow: var(--v3-ring);
}
.catalog-home .skip-link:focus {
  outline: 2px solid #fff;
  outline-offset: 0;
}

/* buttons: default / hover / active / disabled, one accent only */
.catalog-home .btn,
.info-page .btn {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color var(--v3-dur) var(--v3-ease),
              border-color var(--v3-dur) var(--v3-ease),
              color var(--v3-dur) var(--v3-ease),
              transform var(--v3-dur) var(--v3-ease),
              box-shadow var(--v3-dur) var(--v3-ease);
}
.catalog-home .btn-primary:hover,
.info-page .btn-primary:hover { background-color: #5636e6; }
.catalog-home .btn-primary:active,
.info-page .btn-primary:active { background-color: #4826cc; transform: translateY(1px); }
.catalog-home .btn-ghost:hover,
.info-page .btn-ghost:hover { border-color: #c9c4ea; background-color: #f7f5ff; }
.catalog-home .btn-ghost:active,
.info-page .btn-ghost:active { transform: translateY(1px); }
.catalog-home .btn:disabled,
.catalog-home .btn[disabled],
.info-page .btn:disabled,
.info-page .btn[disabled] {
  cursor: not-allowed;
  opacity: 0.55;
  transform: none;
  box-shadow: none;
}

/* cards: border emphasis + 2px lift, no large shadow */
.catalog-home .v3-feature,
.catalog-home .family-card,
.catalog-home .plan-card,
.info-page .info-card,
.info-page .policy-block {
  transition: border-color var(--v3-dur) var(--v3-ease),
              transform var(--v3-dur) var(--v3-ease),
              background-color var(--v3-dur) var(--v3-ease);
  will-change: transform;
}
.catalog-home .v3-feature:hover,
.catalog-home .family-card:hover {
  border-color: #c9c4ea;
  transform: translateY(-2px);
}
.catalog-home .v3-feature:active,
.catalog-home .family-card:active { transform: translateY(0); }

/* nav + footer links: underline grows in, transform only */
.catalog-home .hdr a:not(.btn),
.catalog-home .ftr a:not(.btn) {
  position: relative;
  -webkit-tap-highlight-color: transparent;
}
.catalog-home .hdr a:not(.btn)::after,
.catalog-home .ftr a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -3px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform var(--v3-dur) var(--v3-ease);
  opacity: 0.7;
}
.catalog-home .hdr a:not(.btn):hover::after,
.catalog-home .hdr a:not(.btn):focus-visible::after,
.catalog-home .ftr a:not(.btn):hover::after { transform: scaleX(1); }

/* inline links: same underline rhythm */
.catalog-home .v3-feature a,
.catalog-home .text-link,
.info-page .info-article a:not(.btn) {
  position: relative;
  text-decoration: none;
  cursor: pointer;
  transition: color var(--v3-dur) var(--v3-ease);
}
/* keep the underline the width of the label, not the full card */
.catalog-home .v3-feature a { align-self: flex-start; }
.catalog-home .text-link { display: inline-block; justify-self: start; }
.catalog-home .v3-feature a::after,
.catalog-home .text-link::after,
.info-page .info-article a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform var(--v3-dur) var(--v3-ease);
}
.catalog-home .v3-feature a:hover::after,
.catalog-home .v3-feature a:focus-visible::after,
.catalog-home .text-link:hover::after,
.info-page .info-article a:hover::after { transform: scaleX(1); }

/* filter chips: colour + border only, no movement */
.catalog-home .family-tab,
.catalog-home .model-chip,
.catalog-home .chip {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color var(--v3-dur) var(--v3-ease),
              border-color var(--v3-dur) var(--v3-ease),
              color var(--v3-dur) var(--v3-ease);
}
.catalog-home .family-tab:hover,
.catalog-home .model-chip:hover,
.catalog-home .chip:hover { border-color: #c9c4ea; background-color: #f7f5ff; }
.catalog-home .family-tab:active,
.catalog-home .model-chip:active,
.catalog-home .chip:active { background-color: #efeaff; }

/* pointer affordance for every clickable surface */
.catalog-home a,
.catalog-home button,
.catalog-home summary,
.info-page a,
.info-page button { cursor: pointer; }
.catalog-home summary { -webkit-tap-highlight-color: transparent; }
.catalog-home .faq-item summary { transition: color var(--v3-dur) var(--v3-ease); }
.catalog-home .faq-item summary:hover { color: var(--v3-violet); }

/* respect reduced motion without losing affordances */
@media (prefers-reduced-motion: reduce) {
  .catalog-home *,
  .info-page * {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .catalog-home .v3-feature:hover,
  .catalog-home .family-card:hover,
  .catalog-home .btn:active,
  .info-page .btn:active { transform: none; }
}

/* catalog type tabs are generated without a class; target them structurally */
.catalog-home #familyTabs button {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color var(--v3-dur) var(--v3-ease),
              border-color var(--v3-dur) var(--v3-ease),
              color var(--v3-dur) var(--v3-ease);
}
.catalog-home #familyTabs button:hover {
  border-color: #c9c4ea;
  background-color: #f7f5ff;
  color: var(--v3-ink);
}
.catalog-home #familyTabs button:active { background-color: #efeaff; }
.catalog-home #familyTabs button[aria-selected="true"] { cursor: default; }
