/*
Theme Name: PieceRelay
Theme URI: https://example.com/piecerelay
Author: beetobee
Author URI: https://example.com
Description: Responsive WordPress theme for the PieceRelay and PanicRelay mobile party games, with editable homepage, screenshot slots, and privacy policy template.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 8.0
Text Domain: piecerelay
*/

:root {
  --pr-ink: #101820;
  --pr-paper: #f6f7f2;
  --pr-teal: #177e89;
  --pr-coral: #d1495b;
  --pr-gold: #edae49;
  --pr-green: #4f8f5b;
  --pr-blue: #2e6f95;
  --pr-line: #c8d3d5;
  --pr-white: #ffffff;
  --pr-cyan: #58f4ff;
  --pr-pink: #ff5cdc;
  --pr-violet: #9357ff;
  --pr-night: #05071b;
  --pr-panel: rgba(6, 9, 37, 0.76);
  --pr-panel-solid: #0b1030;
  --pr-radius: 8px;
  --pr-shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--pr-night);
  color: #edf8ff;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

body.admin-bar .pr-site-header {
  top: 32px;
}

a {
  color: inherit;
}

img {
  display: block;
  height: auto;
  max-width: 100%;
}

.screen-reader-text {
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  overflow: hidden;
  position: absolute;
  width: 1px;
}

.pr-page {
  background:
    linear-gradient(180deg, rgba(2, 4, 24, 0.28), rgba(2, 4, 24, 0.94) 74%),
    var(--pr-night);
  min-height: 100vh;
  overflow-x: hidden;
}

.pr-site-header {
  backdrop-filter: blur(20px);
  background: rgba(5, 7, 27, 0.72);
  border-bottom: 1px solid rgba(88, 244, 255, 0.18);
  position: sticky;
  top: 0;
  z-index: 50;
}

.pr-header-inner,
.pr-section-inner {
  margin: 0 auto;
  max-width: 1160px;
  padding: 0 22px;
  width: 100%;
}

.pr-header-inner {
  align-items: center;
  display: flex;
  gap: 18px;
  justify-content: space-between;
  min-height: 72px;
}

.pr-header-actions {
  align-items: center;
  display: flex;
  gap: 14px;
  justify-content: flex-end;
}

.pr-brand {
  align-items: center;
  display: inline-flex;
  gap: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-decoration: none;
}

.pr-brand img {
  border-radius: 14px;
  height: 42px;
  width: 42px;
}

.pr-brand-text {
  background: linear-gradient(90deg, var(--pr-cyan), #a7b3ff 46%, var(--pr-pink));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 24px;
}

.pr-nav,
.pr-nav .menu {
  align-items: center;
  display: flex;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.pr-nav a {
  border: 1px solid transparent;
  border-radius: var(--pr-radius);
  color: #dffcff;
  font-size: 14px;
  font-weight: 800;
  padding: 9px 11px;
  text-decoration: none;
}

.pr-nav a:hover,
.pr-nav a:focus-visible {
  border-color: rgba(88, 244, 255, 0.34);
  outline: none;
}

.pr-language-switch {
  align-items: center;
  border: 1px solid rgba(151, 242, 255, 0.26);
  border-radius: var(--pr-radius);
  display: inline-flex;
  overflow: hidden;
}

.pr-language-switch a {
  color: #dffcff;
  font-size: 12px;
  font-weight: 900;
  padding: 7px 9px;
  text-decoration: none;
}

.pr-language-switch a.is-active {
  background: #23c7ff;
  color: #06102b;
}

.pr-hero {
  background-image:
    radial-gradient(circle at 14% 24%, rgba(88, 244, 255, 0.14), transparent 28%),
    radial-gradient(circle at 82% 36%, rgba(255, 92, 220, 0.16), transparent 26%),
    linear-gradient(180deg, rgba(2, 4, 24, 0.42), rgba(2, 4, 24, 0.78)),
    var(--pr-hero-bg);
  background-position: center;
  background-size: cover;
  min-height: calc(100vh - 72px);
  padding: 78px 0 40px;
}

.pr-hero-grid {
  align-items: center;
  display: grid;
  gap: 48px;
  grid-template-columns: minmax(0, 1fr) minmax(310px, 420px);
}

.pr-kicker {
  color: var(--pr-cyan);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.08em;
  margin: 0 0 12px;
  text-transform: uppercase;
}

.pr-hero h1 {
  font-size: clamp(3rem, 8vw, 6.8rem);
  line-height: 0.92;
  margin: 0;
  max-width: 880px;
  text-shadow: 0 0 30px rgba(88, 244, 255, 0.18);
}

.pr-gradient-text {
  background: linear-gradient(90deg, var(--pr-cyan), #f5b0ff 54%, #ff9a74);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.pr-hero-copy {
  color: #dfe8ff;
  font-size: clamp(1.05rem, 2vw, 1.28rem);
  font-weight: 650;
  margin: 22px 0 0;
  max-width: 680px;
}

.pr-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.pr-button {
  align-items: center;
  border-radius: var(--pr-radius);
  display: inline-flex;
  font-weight: 900;
  gap: 10px;
  justify-content: center;
  min-height: 52px;
  padding: 13px 18px;
  text-decoration: none;
}

.pr-button img {
  height: 24px;
  width: 24px;
}

.pr-button-primary {
  background: #23c7ff;
  color: #06102b;
  box-shadow: 0 12px 34px rgba(35, 199, 255, 0.28);
}

.pr-button-secondary {
  background: rgba(10, 13, 48, 0.72);
  border: 2px solid #ce62ff;
  color: #ffffff;
}

.pr-button-quiet {
  border: 1px solid rgba(151, 242, 255, 0.32);
  color: #dffcff;
}

.pr-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.pr-pill {
  align-items: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(151, 242, 255, 0.24);
  border-radius: 999px;
  color: #dffcff;
  display: inline-flex;
  font-size: 13px;
  font-weight: 850;
  gap: 8px;
  padding: 7px 11px;
}

.pr-pill img {
  height: 18px;
  width: 18px;
}

.pr-phone-cluster {
  aspect-ratio: 0.8;
  min-height: 470px;
  position: relative;
}

.pr-phone {
  background: linear-gradient(180deg, rgba(11, 16, 48, 0.92), rgba(4, 7, 28, 0.96));
  border: 1px solid rgba(151, 242, 255, 0.28);
  border-radius: 26px;
  box-shadow: var(--pr-shadow);
  overflow: hidden;
  padding: 10px;
  position: absolute;
}

.pr-phone::before {
  background: rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  content: "";
  height: 4px;
  left: 50%;
  position: absolute;
  top: 7px;
  transform: translateX(-50%);
  width: 52px;
  z-index: 2;
}

.pr-phone-main {
  inset: 0 38px auto auto;
  max-width: 286px;
  transform: rotate(3deg);
  width: 70%;
}

.pr-phone-side {
  bottom: 20px;
  left: 0;
  max-width: 230px;
  transform: rotate(-8deg);
  width: 56%;
}

.pr-phone-small {
  bottom: 70px;
  right: 0;
  max-width: 172px;
  transform: rotate(9deg);
  width: 42%;
}

.pr-phone-screen {
  align-items: center;
  aspect-ratio: 9 / 18.5;
  background:
    linear-gradient(135deg, rgba(88, 244, 255, 0.18), rgba(255, 92, 220, 0.16)),
    #080d2a;
  border-radius: 18px;
  display: flex;
  justify-content: center;
  overflow: hidden;
  width: 100%;
}

.pr-phone-screen img,
.pr-shot-media img {
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.pr-placeholder {
  align-items: center;
  color: #dffcff;
  display: flex;
  flex-direction: column;
  font-size: 12px;
  font-weight: 900;
  gap: 8px;
  justify-content: center;
  min-height: 100%;
  padding: 22px;
  text-align: center;
}

.pr-placeholder img {
  height: 52px;
  width: 52px;
}

.pr-section {
  padding: 82px 0;
}

.pr-section-light {
  background: var(--pr-paper);
  color: var(--pr-ink);
}

.pr-section-table {
  background:
    linear-gradient(90deg, rgba(5, 7, 27, 0.88), rgba(5, 7, 27, 0.46)),
    var(--pr-table-bg);
  background-position: center;
  background-size: cover;
}

.pr-section-pro {
  background:
    radial-gradient(circle at 12% 18%, rgba(88, 244, 255, 0.14), transparent 30%),
    radial-gradient(circle at 86% 70%, rgba(255, 92, 220, 0.16), transparent 28%),
    #05071b;
}

.pr-section-games {
  background: #eef8fb;
  color: var(--pr-ink);
}

.pr-section-panic {
  background:
    linear-gradient(90deg, rgba(9, 17, 28, 0.92), rgba(42, 18, 32, 0.82)),
    var(--pr-table-bg);
  background-position: center;
  background-size: cover;
}

.pr-section-heading {
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(0, 0.85fr) minmax(280px, 0.55fr);
  margin-bottom: 34px;
}

.pr-section-heading h2 {
  font-size: clamp(2rem, 5vw, 4.2rem);
  line-height: 0.98;
  margin: 0;
}

.pr-section-heading p {
  color: inherit;
  font-size: 1.04rem;
  font-weight: 650;
  margin: 0;
  opacity: 0.82;
}

.pr-feature-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

/* Occasions are a variable-length list — cards can be switched off one by one —
   so the columns fit themselves to whatever is left instead of leaving a hole
   or stranding a single card on its own row. */
.pr-occasion-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.pr-card {
  background: var(--pr-panel);
  border: 1px solid rgba(151, 242, 255, 0.22);
  border-radius: var(--pr-radius);
  padding: 20px;
}

.pr-section-light .pr-card {
  background: #ffffff;
  border-color: #d9e6e8;
  box-shadow: 0 12px 34px rgba(16, 24, 32, 0.08);
}

.pr-card img {
  height: 44px;
  margin-bottom: 18px;
  width: 44px;
}

.pr-card h3 {
  font-size: 1.08rem;
  line-height: 1.25;
  margin: 0 0 8px;
}

.pr-card p {
  color: inherit;
  font-size: 0.96rem;
  font-weight: 600;
  margin: 0;
  opacity: 0.78;
}

.pr-game-modules {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.pr-game-module {
  border: 1px solid #d9e6e8;
  border-radius: var(--pr-radius);
  min-height: 360px;
  padding: clamp(22px, 4vw, 34px);
}

.pr-game-module-piece {
  background:
    linear-gradient(135deg, rgba(35, 199, 255, 0.12), rgba(79, 143, 91, 0.12)),
    #ffffff;
}

.pr-game-module-panic {
  background:
    linear-gradient(135deg, rgba(255, 214, 122, 0.18), rgba(209, 73, 91, 0.14)),
    #ffffff;
}

.pr-game-module-top {
  align-items: center;
  display: flex;
  gap: 12px;
  margin-bottom: 28px;
}

.pr-game-module-icon {
  border-radius: 8px;
  height: 48px;
  width: 48px;
}

.pr-game-module-top span {
  color: #56656f;
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pr-game-module h3 {
  font-size: clamp(2.1rem, 5vw, 4.6rem);
  line-height: 0.95;
  margin: 0 0 16px;
}

.pr-game-module p {
  color: #26313a;
  font-size: 1.05rem;
  font-weight: 680;
  margin: 0;
  max-width: 520px;
}

.pr-module-link {
  align-items: center;
  border: 1px solid rgba(16, 24, 32, 0.18);
  border-radius: var(--pr-radius);
  display: inline-flex;
  font-weight: 900;
  margin-top: 28px;
  min-height: 48px;
  padding: 11px 14px;
  text-decoration: none;
}

.pr-steps {
  counter-reset: steps;
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.pr-panic-steps {
  counter-reset: steps;
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.pr-step {
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(151, 242, 255, 0.22);
  border-radius: var(--pr-radius);
  min-height: 180px;
  padding: 22px;
  position: relative;
}

.pr-step::before {
  background: rgba(95, 232, 255, 0.16);
  border: 1px solid rgba(95, 232, 255, 0.6);
  border-radius: 12px;
  color: #eafcff;
  content: counter(steps);
  counter-increment: steps;
  display: grid;
  font-size: 13px;
  font-weight: 900;
  height: 28px;
  place-items: center;
  width: 28px;
}

.pr-step h3 {
  font-size: 1.18rem;
  margin: 18px 0 8px;
}

.pr-step p {
  color: #dfe8ff;
  font-weight: 650;
  margin: 0;
}

.pr-pro-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.pr-pro-card {
  background: rgba(6, 9, 37, 0.78);
  border: 1px solid rgba(151, 242, 255, 0.22);
  border-radius: var(--pr-radius);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.24);
  padding: 20px;
}

.pr-pro-card-top {
  align-items: center;
  display: flex;
  justify-content: space-between;
  margin-bottom: 18px;
}

.pr-pro-card-top img {
  height: 44px;
  width: 44px;
}

.pr-pro-card-top span {
  background: linear-gradient(90deg, var(--pr-gold), #ff9a74);
  border-radius: 999px;
  color: #06102b;
  font-size: 11px;
  font-weight: 950;
  padding: 5px 8px;
}

.pr-pro-card h3 {
  font-size: 1.08rem;
  line-height: 1.25;
  margin: 0 0 8px;
}

.pr-pro-card p {
  color: #dfe8ff;
  font-size: 0.96rem;
  font-weight: 600;
  margin: 0;
  opacity: 0.82;
}

.pr-shot-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.pr-shot {
  background: #ffffff;
  border: 1px solid #d9e6e8;
  border-radius: var(--pr-radius);
  box-shadow: 0 12px 34px rgba(16, 24, 32, 0.08);
  overflow: hidden;
}

.pr-shot-media {
  align-items: center;
  aspect-ratio: 9 / 18.5;
  background: #08102d;
  display: flex;
  justify-content: center;
}

.pr-shot-caption {
  color: var(--pr-ink);
  font-size: 0.94rem;
  font-weight: 850;
  margin: 0;
  padding: 13px 14px 15px;
}

.pr-shot-grid-panic .pr-shot-media {
  background:
    linear-gradient(135deg, rgba(255, 214, 122, 0.2), rgba(209, 73, 91, 0.18)),
    #0a1026;
}

.pr-download-band {
  background: linear-gradient(90deg, #177e89, #2e6f95 47%, #d1495b);
  color: #ffffff;
  padding: 44px 0;
}

.pr-download-inner {
  align-items: center;
  display: flex;
  gap: 20px;
  justify-content: space-between;
}

.pr-download-inner h2 {
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1;
  margin: 0;
}

.pr-download-inner p {
  font-weight: 700;
  margin: 8px 0 0;
  opacity: 0.88;
}

/* Open-testing notice. Deliberately quieter than the download band below it:
   it sits right under the hero and should read as information, not as a second
   competing call to action. */
.pr-beta-band {
  background: rgba(95, 232, 255, 0.06);
  border-bottom: 1px solid rgba(151, 242, 255, 0.18);
  border-top: 1px solid rgba(151, 242, 255, 0.18);
  padding: 34px 0;
}

.pr-beta-inner {
  align-items: center;
  display: flex;
  gap: 28px;
  justify-content: space-between;
}

.pr-beta-copy {
  max-width: 720px;
}

.pr-beta-copy .pr-kicker {
  margin-bottom: 8px;
}

.pr-beta-inner h2 {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  line-height: 1.1;
  margin: 0;
}

.pr-beta-inner p {
  color: #c8d6f2;
  font-weight: 600;
  line-height: 1.6;
  margin: 10px 0 0;
}

.pr-beta-inner .pr-actions {
  flex-shrink: 0;
}

.pr-site-footer {
  background: #040617;
  border-top: 1px solid rgba(151, 242, 255, 0.16);
  color: #b9c8e8;
  padding: 34px 0;
}

.pr-footer-inner {
  align-items: center;
  display: flex;
  gap: 18px;
  justify-content: space-between;
}

.pr-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.pr-content {
  background: var(--pr-paper);
  color: var(--pr-ink);
  min-height: calc(100vh - 72px);
  padding: 72px 0;
}

.pr-content article {
  background: #ffffff;
  border: 1px solid #d9e6e8;
  border-radius: var(--pr-radius);
  margin: 0 auto;
  max-width: 900px;
  padding: clamp(22px, 4vw, 48px);
}

.pr-content h1 {
  font-size: clamp(2.1rem, 5vw, 4rem);
  line-height: 1;
  margin: 0 0 10px;
}

.pr-content h2 {
  font-size: 1.45rem;
  margin: 34px 0 10px;
}

.pr-content p,
.pr-content li {
  color: #26313a;
}

.pr-content table {
  border-collapse: collapse;
  margin: 18px 0;
  width: 100%;
}

.pr-content th,
.pr-content td {
  border-bottom: 1px solid #d9e6e8;
  padding: 12px 10px;
  text-align: left;
  vertical-align: top;
}

.pr-content th {
  color: #56656f;
  font-size: 0.86rem;
  text-transform: uppercase;
}

.pr-note {
  background: #f3fbfc;
  border: 1px solid #cfe7eb;
  border-radius: var(--pr-radius);
  padding: 14px 16px;
}

@media (max-width: 900px) {
  body.admin-bar .pr-site-header {
    top: 46px;
  }

  .pr-header-inner {
    align-items: flex-start;
    flex-direction: column;
    padding-bottom: 14px;
    padding-top: 14px;
  }

  .pr-header-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .pr-nav,
  .pr-nav .menu {
    flex-wrap: wrap;
  }

  .pr-hero {
    min-height: auto;
    padding-top: 54px;
  }

  .pr-hero-grid,
  .pr-section-heading,
  .pr-download-inner {
    grid-template-columns: 1fr;
  }

  .pr-phone-cluster {
    margin: 0 auto;
    max-width: 430px;
    width: 100%;
  }

  .pr-feature-grid,
  .pr-game-modules,
  .pr-pro-grid,
  .pr-shot-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pr-panic-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pr-steps {
    grid-template-columns: 1fr;
  }

  .pr-beta-inner,
  .pr-footer-inner,
  .pr-download-inner {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 560px) {
  .pr-header-inner,
  .pr-section-inner {
    padding-left: 16px;
    padding-right: 16px;
  }

  .pr-brand-text {
    font-size: 21px;
  }

  .pr-actions,
  .pr-button {
    width: 100%;
  }

  .pr-feature-grid,
  .pr-game-modules,
  .pr-panic-steps,
  .pr-pro-grid,
  .pr-shot-grid {
    grid-template-columns: 1fr;
  }

  .pr-phone-cluster {
    min-height: 420px;
  }

  .pr-phone-main {
    right: 22px;
  }

  .pr-content {
    padding: 32px 0;
  }

  .pr-content article {
    border-left: 0;
    border-radius: 0;
    border-right: 0;
  }
}
