/* "Periodic table of supply" explorer on the products page. */
.pt-section {
  position: relative; overflow: hidden; color: #fff; padding: clamp(64px, 9vw, 112px) 0;
  background:
    radial-gradient(900px 420px at 80% 0%, rgba(31,138,138,.28), transparent 60%),
    radial-gradient(700px 380px at 0% 100%, rgba(227,163,54,.12), transparent 60%),
    var(--ink);
}
.pt-section-compact { padding: 48px 0 56px; }
.pt-section .section-head h2 { color: #fff; }
.pt-section .section-head .muted { color: rgba(255,255,255,.65); }
.pt-section .eyebrow { color: #7fd0cc; }

.pt-legend { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.pt-fam {
  display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; cursor: pointer;
  border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.03); color: rgba(255,255,255,.8);
  font: 600 .84rem var(--font-body); transition: all .2s;
}
.pt-fam i { width: 10px; height: 10px; border-radius: 3px; background: var(--c); box-shadow: 0 0 10px var(--c); }
.pt-fam:hover, .pt-fam.is-on { border-color: var(--c); color: #fff; background: color-mix(in srgb, var(--c) 16%, transparent); }

.pt-grid { display: grid; grid-template-columns: repeat(11, 1fr); gap: 8px; }
.pt-el {
  position: relative; aspect-ratio: 1 / 1.06; min-width: 0; padding: 8px 8px 7px; border-radius: 10px; cursor: pointer;
  display: flex; flex-direction: column; align-items: flex-start; text-align: left; color: #fff;
  background: linear-gradient(160deg, color-mix(in srgb, var(--c) 22%, #0e3446), color-mix(in srgb, var(--c) 8%, #0b2a3a));
  border: 1px solid color-mix(in srgb, var(--c) 40%, transparent);
  font-family: var(--font-body);
  transition: transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s, opacity .3s, background .25s, color .25s;
}
.pt-el::before { content: ""; position: absolute; left: 8px; right: 8px; top: 0; height: 2px; border-radius: 0 0 2px 2px; background: var(--c); }
.pt-n { font-size: .66rem; font-weight: 600; opacity: .65; line-height: 1; }
.pt-sym { font-family: var(--font-display); font-size: clamp(1.25rem, 2.1vw, 1.85rem); font-weight: 600; line-height: 1; margin: auto 0 4px; }
.pt-nm { width: 100%; font-size: .6rem; font-weight: 600; letter-spacing: .03em; text-transform: uppercase; opacity: .75; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pt-el:hover, .pt-el:focus-visible {
  transform: translateY(-4px) scale(1.04); z-index: 2;
  box-shadow: 0 0 0 1px var(--c), 0 12px 30px color-mix(in srgb, var(--c) 40%, transparent);
}
.pt-el.is-active { background: var(--c); color: var(--ink); box-shadow: 0 0 0 2px #fff, 0 12px 34px color-mix(in srgb, var(--c) 55%, transparent); }
.pt-el.is-active::before { background: #fff; }
.pt-el.is-dim { opacity: .16; transform: scale(.96); }

/* entrance */
.js .ptable .pt-el { opacity: 0; transform: translateY(14px) scale(.9); }
.js .ptable.pt-in .pt-el { animation: ptIn .55s cubic-bezier(.2,.8,.2,1) forwards; animation-delay: calc(var(--i) * 22ms); }
.js .ptable.pt-in .pt-el.is-dim { animation: none; opacity: .16; transform: scale(.96); }
@keyframes ptIn { to { opacity: 1; transform: none; } }

/* key panel */
.pt-key {
  grid-column: 4 / span 5; grid-row: 1 / span 2; display: flex; gap: 18px; align-items: flex-start; min-width: 0;
  padding: 16px 18px; border-radius: 14px; background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.1); border-top: 3px solid var(--c); overflow: hidden;
}
.pt-key.pt-pop { animation: ptPop .35s ease; }
@keyframes ptPop { from { opacity: .3; transform: translateY(4px); } }
.pt-key-tile {
  flex: none; width: 96px; aspect-ratio: 1 / 1.06; padding: 9px; border-radius: 12px; background: var(--c); color: var(--ink);
  display: flex; flex-direction: column; box-shadow: 0 10px 30px color-mix(in srgb, var(--c) 40%, transparent);
}
.pt-key-tile .pt-sym { font-size: 2.4rem; }
.pt-key-tile .pt-nm { font-size: .62rem; opacity: .85; }
.pt-key-body { min-width: 0; }
.pt-key-eyebrow { margin: 0 0 4px; font-size: .7rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--c); }
.pt-key-body h3 { color: #fff; font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; margin-bottom: 6px; }
.pt-key-body h3 small { display: block; margin-top: 3px; font-family: var(--font-body); font-size: .78rem; font-weight: 600; color: rgba(255,255,255,.6); }
.pt-key-body > p { margin: 0 0 8px; font-size: .86rem; line-height: 1.5; color: rgba(255,255,255,.72); }
.pt-apps { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 10px; }
.pt-apps li { font-size: .72rem; padding: 3px 9px; border-radius: 6px; background: rgba(255,255,255,.08); color: rgba(255,255,255,.85); }
.pt-actions { display: flex; align-items: center; gap: 16px; }
.pt-more { font-weight: 700; font-size: .86rem; color: var(--c); }
.pt-more:hover { color: #fff; }

.p-card.p-flash { animation: pFlash 1.6s ease; }
@keyframes pFlash { 0%, 40% { box-shadow: 0 0 0 3px var(--gold), var(--shadow-lg); } }

@media (max-width: 1100px) {
  .pt-grid { grid-template-columns: repeat(8, 1fr); }
  .pt-key { grid-column: 1 / -1; grid-row: auto; }
}
@media (max-width: 640px) {
  .pt-grid { grid-template-columns: repeat(5, 1fr); gap: 6px; }
  .pt-el { padding: 6px 6px 5px; border-radius: 8px; }
  .pt-nm { font-size: .5rem; }
  .pt-key { flex-direction: column; gap: 12px; }
  .pt-key-tile { width: 76px; }
  .pt-key-tile .pt-sym { font-size: 1.9rem; }
}
@media (prefers-reduced-motion: reduce) {
  .js .ptable .pt-el, .js .ptable.pt-in .pt-el { opacity: 1; transform: none; animation: none; }
}
