/* ==================================================================== *
 * PRISM RULES — LANDING & PLAY STYLESHEET
 * Sleek, minimal darkroom optics aesthetic
 * ==================================================================== */

:root {
  --bg:          #070709;
  --bg-card:     #0f0f14;
  --bg-card-hi:  #15151c;
  --text:        #f3f3f6;
  --text-dim:    #9b9ba6;
  --text-muted:  #636370;
  --line:        rgba(255, 255, 255, 0.10);
  --line-hi:     rgba(255, 255, 255, 0.22);
  
  /* Optics & dispersion spectrum accents */
  --beam-white:  #ffffff;
  --good:        rgb(125, 255, 194);
  --good-dim:    rgba(125, 255, 194, 0.15);
  --prism-cyan:  #5ce1e6;
  --prism-blue:  #4d7cfe;
  --prism-violet:#a855f7;
  --prism-amber: #f59e0b;
  --prism-coral: #f43f5e;

  --mono:        "Syne Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
  --sans:        -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --shadow:      0 12px 36px rgba(0, 0, 0, 0.6);
  --shadow-glow: 0 0 25px rgba(125, 255, 194, 0.15);
}

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

html, body {
  min-height: 100%;
}

body {
  background-color: var(--bg);
  background-image: 
    radial-gradient(circle at 50% 0%, rgba(92, 225, 230, 0.05) 0%, transparent 60%),
    radial-gradient(circle at 100% 40%, rgba(168, 85, 247, 0.04) 0%, transparent 50%),
    radial-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 32px 32px;
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* CONTAINER */

.container {
  max-width: 880px;
  margin: 0 auto;
  padding: 0 24px 100px;
}

/* CARDS */

.card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  border-color: var(--line-hi);
  transform: translateY(-2px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8);
}

/* HERO SECTION */

.hero {
  position: relative;
  width: 100%;
  padding: 100px 24px 70px;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  border-bottom: 1px solid var(--line);
  background: radial-gradient(circle at 50% 30%, rgba(255, 255, 255, 0.03), transparent 70%);
}

.hero-content {
  max-width: 680px;
  width: 100%;
}

.hero-title {
  font-family: var(--mono);
  font-size: clamp(40px, 7vw, 76px);
  font-weight: 400;
  margin: 0 0 16px;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: #fff;
  text-transform: lowercase;
}

.hero-title .glow {
  color: var(--good);
  text-shadow: 0 0 30px rgba(125, 255, 194, 0.4);
}

.hero-subtitle {
  font-family: var(--mono);
  font-size: clamp(16px, 2.5vw, 20px);
  color: var(--text-dim);
  margin: 10px 0;
  text-transform: lowercase;
}

.hero-tags {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 28px;
}

.hero-tag {
  font-family: var(--mono);
  font-size: 13px;
  padding: 6px 14px;
  border-radius: 4px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-dim);
  text-transform: lowercase;
}

/* SECTIONS */

.section {
  padding: 40px 0;
}

.section-title {
  font-family: var(--mono);
  font-size: 28px;
  font-weight: 400;
  text-align: center;
  margin-bottom: 24px;
  color: #fff;
  text-transform: lowercase;
  letter-spacing: -0.01em;
}

.text-center {
  text-align: center;
}

/* PURCHASE SECTION */

#purchase-section {
  padding-top: 40px;
  padding-bottom: 20px;
}

.purchase-card {
  max-width: 480px;
  margin: 0 auto;
  padding: 24px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.price-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 20px;
}

.price {
  font-family: var(--mono);
  font-size: 56px;
  line-height: 1;
  color: var(--good);
}

.price-note {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--text-dim);
  margin-top: 6px;
  text-transform: lowercase;
}

.signin-link {
  display: block;
  margin-top: 14px;
  font-family: var(--mono);
  font-size: 14.5px;
  color: var(--text-dim);
  text-decoration: underline;
  text-underline-offset: 4px;
  cursor: pointer;
  transition: color 0.15s ease;
  text-transform: lowercase;
}

.signin-link:hover {
  color: #fff;
}

/* BUTTONS */

.btn {
  font-family: var(--mono);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.04em;
  background: #fff;
  color: #000;
  border: 1px solid #fff;
  border-radius: 4px;
  padding: 14px 28px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  text-transform: uppercase;
  transition: all 0.15s ease;
}

.btn:hover {
  background: var(--good);
  border-color: var(--good);
  box-shadow: 0 0 20px rgba(125, 255, 194, 0.3);
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(1px);
}

.btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-primary {
  background: var(--good);
  border-color: var(--good);
  color: #05140b;
}

.btn-primary:hover {
  background: #9efcd0;
  border-color: #9efcd0;
}

.btn--large {
  font-size: 18px;
  padding: 16px 36px;
  width: 100%;
}

.btn-sm {
  padding: 8px 18px;
  font-size: 13.5px;
}

/* PIECES GRID */

.pieces-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 18px;
  margin-top: 16px;
}

.piece-card {
  padding: 24px 20px;
  text-align: left;
  display: flex;
  flex-direction: column;
}

.piece-icon {
  font-family: var(--mono);
  font-size: 28px;
  margin-bottom: 12px;
  color: var(--good);
}

.piece-card h3 {
  font-family: var(--mono);
  font-size: 18px;
  color: #fff;
  margin-bottom: 8px;
  text-transform: lowercase;
}

.piece-card p {
  font-size: 14.5px;
  color: var(--text-dim);
  line-height: 1.5;
}

/* FEATURES CARD */

.features-card {
  padding: 36px 30px;
}

.features {
  list-style: none;
  max-width: 680px;
  margin: 0 auto;
}

.features li {
  font-family: var(--mono);
  font-size: 16px;
  color: var(--text);
  padding: 10px 0 10px 32px;
  position: relative;
  line-height: 1.5;
  text-transform: lowercase;
}

.features li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--good);
  font-family: var(--mono);
  font-size: 18px;
}

/* FAQ ACCORDION */

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 760px;
  margin: 0 auto;
}

.faq-item {
  border-radius: 6px;
}

.faq-item summary {
  font-family: var(--mono);
  font-size: 17px;
  color: #fff;
  padding: 16px 20px;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
  text-transform: lowercase;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-family: var(--mono);
  font-size: 18px;
  color: var(--good);
  transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-answer {
  padding: 0 20px 20px;
  font-size: 15px;
  color: var(--text-dim);
  line-height: 1.6;
  border-top: 1px solid var(--line);
  margin-top: 4px;
  padding-top: 14px;
}

.faq-answer p {
  margin-bottom: 10px;
}

.faq-answer p:last-child {
  margin-bottom: 0;
}

/* STATUS / LOADING */

.status {
  padding: 24px 0;
  font-family: var(--mono);
  font-size: 16px;
  color: var(--good);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.pulse-text {
  animation: pulse 1.6s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

/* STICKY BAR */

.sticky-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 12px 24px;
  z-index: 100;
  transform: translateY(-100%);
  transition: transform 0.3s ease;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(15, 15, 20, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.sticky-bar.visible {
  transform: translateY(0);
}

#sticky-buy, #sticky-play {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

/* CLERK EMBED */

.clerk-embed-container {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-top: 14px;
}

/* HIDDEN */

.hidden {
  display: none !important;
}

/* FOOTER */

.footer {
  padding: 50px 0 30px;
  text-align: center;
  border-top: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 14px;
  color: var(--text-muted);
  text-transform: lowercase;
}

.footer-links {
  margin-bottom: 14px;
}

.footer-links a {
  color: var(--text-dim);
  margin: 0 12px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer-links a:hover {
  color: #fff;
}

/* RESPONSIVE */

@media (max-width: 600px) {
  .hero {
    padding: 60px 16px 40px;
  }
  
  .hero-title {
    font-size: 38px;
  }
  
  .pieces-grid {
    grid-template-columns: 1fr;
  }
  
  .purchase-card {
    padding: 20px 16px;
  }
  
  .price {
    font-size: 46px;
  }
  
  .btn--large {
    font-size: 16px;
    padding: 14px 24px;
  }
}

/* PLAY PAGE FULLSCREEN CONTAINER */

.container--full {
  max-width: 100% !important;
  width: 100% !important;
  height: 100dvh !important;
  padding: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  background: #000;
}

.header {
  display: none;
  justify-content: space-between;
  align-items: center;
  padding: 12px 24px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--line);
  z-index: 10;
}

.header__logo {
  font-family: var(--mono);
  font-size: 20px;
  color: #fff;
  text-transform: lowercase;
}

.header__user {
  display: flex;
  align-items: center;
}

#game-container {
  flex: 1;
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 0;
  background: #000;
}

.denied {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
  padding: 40px 20px;
  text-align: center;
}

.denied h1 {
  font-family: var(--mono);
  font-size: 32px;
  color: var(--prism-coral);
  margin-bottom: 12px;
  text-transform: uppercase;
}

.denied p {
  font-family: var(--mono);
  font-size: 16px;
  color: var(--text-dim);
  margin-bottom: 24px;
  text-transform: lowercase;
}
