/* =========================
   Playright Studios — Styles
   ========================= */

:root {
  --bg: #0b0c10;
  --fg: #ffffff;
  --muted: #a3a3a3;
  --card: rgba(255,255,255,.06);
  --border: rgba(255,255,255,.12);
  --accent1: #7c3aed;
  --accent2: #22d3ee;
}

/* Base */
html, body {
  height: 100%;
  overscroll-behavior: none;
}
*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100dvh;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji","Segoe UI Emoji";
  color: var(--fg);
  background: radial-gradient(1000px 600px at 50% -10%, #171717 0%, var(--bg) 60%);
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  overflow-y: auto;
}

/* Desktop pointer: custom clapper cursor */
@media (hover: hover) and (pointer: fine) {
  html, body { cursor: url("./cursor-clapper.svg") 6 6, auto; }
  a, button, .btn { cursor: pointer; }
}

/* Loader */
.loader {
  position: fixed; inset: 0; display: grid; place-items: center;
  background: #0b0c10; z-index: 9999; transition: opacity .5s ease, visibility .5s ease;
}
body.ready .loader { opacity: 0; visibility: hidden; pointer-events: none; }

.clapper {
  width: clamp(180px, 32vw, 320px);
  height: auto;
  filter: drop-shadow(0 10px 28px rgba(0,0,0,.4));
  animation: boardRise .6s ease-out both;
}
@keyframes boardRise { from { transform: translateY(10px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.clapper-top {
  transform-origin: 60px 100px;
  transform: rotate(-32deg);
  animation: clapClose 1.4s cubic-bezier(.22,.9,.24,1) .15s forwards;
}
@keyframes clapClose {
  0% { transform: rotate(-32deg); }
  70% { transform: rotate(3deg); }
  85% { transform: rotate(-2deg); }
  100% { transform: rotate(0); }
}
@media (prefers-reduced-motion: reduce) {
  .clapper, .clapper-top { animation: none !important; transform: none !important; opacity: 1 !important; }
  body.ready .loader { transition: none; }
}

/* Wrapper + animated background glow */
.wrap {
  position: relative;
  width: 100%;
  max-width: 880px;
  margin-inline: auto;
  padding: 0 24px 28px;
  text-align: center;
}
.wrap::before {
  content: "";
  position: fixed;
  inset: -12vh -12vw;
  pointer-events: none;
  background:
    radial-gradient(35% 25% at 15% 15%, color-mix(in oklab, var(--accent1) 30%, transparent) 0%, transparent 100%),
    radial-gradient(30% 30% at 85% 20%, color-mix(in oklab, var(--accent2) 35%, transparent) 0%, transparent 100%);
  filter: blur(40px);
  opacity: .58;
  z-index: -1;
  animation: glowDrift 28s ease-in-out infinite alternate;
}
@keyframes glowDrift {
  0% { transform: translate3d(0,0,0); opacity: .58; }
  50% { transform: translate3d(1.2%, -1.2%, 0); opacity: .66; }
  100% { transform: translate3d(-1.2%, 1.2%, 0); opacity: .60; }
}
body.loaded .wrap::before { opacity: .70; }

/* =========================
   Folds
   ========================= */
.fold {
  min-height: 100svh;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
}

/* First fold */
.hero {
  display: flex; align-items: center; justify-content: center;
}
.logo {
  display: block; margin: 0 auto;
  width: clamp(140px, 14vw, 210px);
  height: auto;
  transform-origin: center;
  opacity: 0;
  transform: translateY(6px);
  filter: drop-shadow(0 4px 18px rgba(0,0,0,.35));
  animation: fadeUp .6s ease .1s forwards, logoPop 1s ease-out .8s forwards;
}
@keyframes logoPop {
  0% { transform: translateY(0) scale(1);}
  50% { transform: translateY(0) scale(1.03);}
  100% { transform: translateY(0) scale(1);}
}
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px);} to { opacity: 1; transform: translateY(0);} }

.panel {
  max-width: min(900px, 92vw);
  margin: 0 auto;
  padding: clamp(28px, 5vw, 56px);
  background: rgba(20,22,26,.55);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 20px;
  backdrop-filter: blur(14px) saturate(120%);
  -webkit-backdrop-filter: blur(14px) saturate(120%);
  box-shadow: 0 10px 30px rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.06);
  animation: fadeUp .8s ease both;
}

/* Headline / tagline */
.headline {
  margin: 0 0 12px;
  font-weight: 800;
  font-size: clamp(34px, 6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  background: linear-gradient(92deg, #8e7dfb 0%, #5fb8ff 50%, #42e6c5 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.tagline {
  color: rgba(255,255,255,.78);
  font-size: clamp(14px, 1.6vw, 18px);
  margin: 8px 0 20px;
  min-height: 1.3em;
}
.tagline.typing::after {
  content: "▌";
  margin-left: 2px;
  animation: blink 1s steps(1,end) infinite;
  opacity: .9;
}
@keyframes blink { 50% { opacity: 0; } }

/* CTA */
.btn {
  display: inline-block;
  padding: 12px 18px;
  border-radius: 12px;
  background: linear-gradient(180deg, #ffffff, #e9e9e9);
  color: #0b0c10;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,.35);
  box-shadow: 0 6px 16px rgba(0,0,0,.25);
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, filter .18s ease;
}
.btn:hover {
  transform: translateY(-1px) rotate(-0.4deg);
  box-shadow: 0 12px 28px rgba(0,0,0,.32), 0 0 0 3px color-mix(in oklab, var(--accent2) 35%, transparent);
}

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  display: inline-flex;
}
.scroll-indicator .chevron {
  width: 14px; height: 14px;
  border-right: 2px solid rgba(255,255,255,.7);
  border-bottom: 2px solid rgba(255,255,255,.7);
  transform: rotate(45deg);
  animation: bounce 1.8s ease-in-out infinite;
}
@keyframes bounce {
  0%,100% { transform: translateY(0) rotate(45deg); }
  50% { transform: translateY(8px) rotate(45deg); }
}

/* =========================
   Fold 2 — About
   ========================= */
.fold--about {
  display: flex;
  align-items: center;           /* vertical center */
  justify-content: center;       /* horizontal center */
  padding: 0 32px;
  min-height: 100vh;              /* ensure full screen height */
  background: transparent;        /* no black box */
}

.about-inner {
  max-width: 820px;
  width: 100%;
  text-align: left;
}

.fold--about h2 {
  font-size: clamp(28px, 3.8vw, 36px);
  font-weight: 800;
  letter-spacing: -0.01em;
  margin-bottom: 18px;
}

.fold--about p {
  margin: 14px 0;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.7;
  color: rgba(255,255,255,.85);
}

/* Footer */
.foot {
  color: rgba(255,255,255,.62);
  font-size: 12.5px;
  margin: 10px 0 6px;
}
.social {
  display: flex; gap: 14px; justify-content: center; margin-bottom: 6px;
}
.social .icon {
  color: rgba(255,255,255,.72);
  transition: color .2s ease, transform .15s ease;
}
.social .icon:hover { color: #fff; transform: translateY(-1px); }

/* Mobile tweaks: make Fold 2 content top-aligned and footer compact */
@media (max-width: 640px){
  .fold--about{
    min-height: auto;           /* don't force full screen on mobile */
    align-items: flex-start;     /* top align */
    justify-content: flex-start; 
    padding: 24px 20px 0;        /* comfortable page padding */
  }
  .about-inner{
    margin: 48px 0 16px;         /* space above, less below */
    max-width: 680px;            /* a bit wider feel on phones */
  }
  .fold--about h2{
    font-size: clamp(24px, 6vw, 32px);
    margin-bottom: 14px;
  }
  .fold--about p{
    font-size: clamp(16px, 4.2vw, 19px);
    line-height: 1.65;
  }

  /* Footer: same background, smaller, safe-area padding */
  .foot{
    background: transparent;
    margin: 10px 0 0;
    padding: 12px 0 calc(12px + env(safe-area-inset-bottom));
    font-size: 12px;
    color: rgba(255,255,255,.68);
    text-align: center;
  }
}