/* === V2: Cartoon Sunburst / Mika "Grace Kelly" vibe ============== */

:root {
  --ink: #1a1410;
  --cream: #fff6df;
  --cream-2: #ffeac0;
  --red: #e8344a;
  --pink: #ff6fa8;
  --orange: #ff8a2c;
  --yellow: #ffd23a;
  --lime: #b9d94a;
  --teal: #2fb8a6;
  --blue: #2f7cd6;
  --purple: #8e3ec7;
  --magenta: #c93cae;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body.cartoon {
  font-family: "Fraunces", "Georgia", serif;
  background: var(--cream);
  color: var(--ink);
  overflow-x: clip;
  cursor: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='28' height='28' viewBox='0 0 28 28'><circle cx='14' cy='14' r='8' fill='%23ffd23a' stroke='%231a1410' stroke-width='2.5'/><circle cx='11' cy='12' r='1.5' fill='%231a1410'/><circle cx='17' cy='12' r='1.5' fill='%231a1410'/><path d='M10 16 Q14 19 18 16' fill='none' stroke='%231a1410' stroke-width='2' stroke-linecap='round'/></svg>") 14 14, auto;
}

/* ---------- BACKGROUND: SUNBURST + DOODLES ----------------------- */

.cartoon-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.sunburst {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 200vmax;
  height: 200vmax;
  transform: translate(-50%, -50%);
  animation: spin 180s linear infinite;
}

@keyframes spin { to { transform: translate(-50%, -50%) rotate(360deg); } }
@keyframes spin-rev { to { transform: translate(-50%, -50%) rotate(-360deg); } }
@keyframes wobble { 0%,100% { transform: rotate(-3deg); } 50% { transform: rotate(3deg); } }
@keyframes float-up { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes blink { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(0.05); } }
@keyframes hue { to { filter: hue-rotate(360deg); } }

/* doodles scattered around */
.doodle {
  position: absolute;
  pointer-events: none;
}
.doodle.spin-slow { animation: spin 30s linear infinite; transform-origin: center; }
.doodle.spin-fast { animation: spin 10s linear infinite; transform-origin: center; }
.doodle.spin-rev { animation: spin-rev 22s linear infinite; transform-origin: center; }
.doodle.wobble { animation: wobble 4s ease-in-out infinite; transform-origin: center; }
.doodle.float { animation: float-up 5s ease-in-out infinite; }

/* ---------- LAYOUT ---------------------------------------------- */

.page {
  position: relative;
  z-index: 1;
  min-height: 100vh;
}

.nav-cartoon {
  position: fixed;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 50;
  display: flex;
  gap: 8px;
  padding: 6px;
  background: var(--cream);
  border: 3px solid var(--ink);
  border-radius: 999px;
  box-shadow: 4px 4px 0 var(--ink);
  font-family: "Bowlby One", "Fraunces", serif;
  font-weight: 800;
}
.nav-cartoon a {
  padding: 8px 16px;
  border-radius: 999px;
  text-decoration: none;
  color: var(--ink);
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: transform 0.15s, background 0.15s;
}
.nav-cartoon a:hover { background: var(--yellow); transform: rotate(-2deg) scale(1.05); }
.nav-cartoon a.live { background: var(--ink); color: var(--cream); }

/* ---------- HERO ------------------------------------------------- */

.hero-cartoon {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 100px 24px 60px;
  text-align: center;
}

.hero-name-svg {
  width: min(95vw, 1100px);
  height: auto;
  filter: drop-shadow(8px 8px 0 var(--ink));
}

.hero-tagline {
  margin-top: -2vw;
  font-family: "Caveat", cursive;
  font-size: clamp(28px, 5vw, 64px);
  color: var(--ink);
  position: relative;
  display: inline-block;
  transform: rotate(-2deg);
}
.hero-tagline .ribbon {
  display: inline-block;
  background: var(--cream);
  padding: 4px 28px;
  border: 3px solid var(--ink);
  border-radius: 999px;
  box-shadow: 4px 4px 0 var(--ink);
}

.hero-sub {
  margin-top: 30px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  font-family: "Bowlby One", serif;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.color-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border: 2.5px solid var(--ink);
  border-radius: 999px;
  background: var(--cream);
  box-shadow: 3px 3px 0 var(--ink);
  transform: rotate(var(--rot, 0deg));
  transition: transform 0.2s;
}
.color-chip:hover { transform: rotate(0deg) scale(1.08); }
.color-chip .dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid var(--ink);
  background: var(--c, var(--red));
}

/* ---------- SECTION HEADERS ------------------------------------- */

.section {
  position: relative;
  padding: 90px 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 50px;
  position: relative;
}
.section-eyebrow {
  display: inline-block;
  font-family: "Caveat", cursive;
  font-size: 28px;
  background: var(--cream);
  padding: 4px 20px;
  border: 2.5px solid var(--ink);
  border-radius: 999px;
  box-shadow: 3px 3px 0 var(--ink);
  transform: rotate(-3deg);
  margin-bottom: 14px;
}
.section-title {
  font-family: "Bowlby One", "Fraunces", serif;
  font-size: clamp(48px, 9vw, 120px);
  font-weight: 900;
  line-height: 0.9;
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--ink);
  text-shadow:
    -2px -2px 0 var(--cream),
    2px -2px 0 var(--cream),
    -2px 2px 0 var(--cream),
    2px 2px 0 var(--cream),
    8px 8px 0 var(--ink);
}
.section-title .accent { color: var(--red); }
.section-title .accent-2 { color: var(--blue); }
.section-title .accent-3 { color: var(--orange); }

/* ---------- PROJECT CARDS --------------------------------------- */

.project-card {
  position: relative;
  background: var(--cream);
  border: 4px solid var(--ink);
  border-radius: 32px;
  box-shadow: 12px 12px 0 var(--ink);
  padding: 28px;
  margin-bottom: 90px;
  transform: rotate(var(--rot, -1deg));
}
.project-card.right { --rot: 1deg; }

.project-tag {
  position: absolute;
  top: -22px;
  left: 40px;
  padding: 6px 22px;
  background: var(--c, var(--yellow));
  border: 3px solid var(--ink);
  border-radius: 999px;
  box-shadow: 3px 3px 0 var(--ink);
  font-family: "Bowlby One", serif;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  transform: rotate(-3deg);
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-bottom: 22px;
  padding: 0 14px;
}
.project-name {
  font-family: "Bowlby One", serif;
  font-size: clamp(36px, 5vw, 56px);
  margin: 0;
  letter-spacing: -0.02em;
}
.project-blurb {
  font-family: "Caveat", cursive;
  font-size: 26px;
  line-height: 1.1;
  margin: 0;
  flex: 1;
  min-width: 280px;
}

.project-frame {
  border: 3px solid var(--ink);
  border-radius: 22px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.06);
  background: #fff;
  position: relative;
}
.project-frame.bro-frame { background: linear-gradient(180deg, #fff6df, #ffe5b3); padding: 28px; }
.project-frame.exp-frame { background: #fafafa; }

/* ---------- LABEL PILL CHAINS ----------------------------------- */

.pill-chain {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 20px;
}
.pill {
  padding: 8px 18px;
  border: 2.5px solid var(--ink);
  border-radius: 999px;
  background: var(--c, var(--yellow));
  box-shadow: 3px 3px 0 var(--ink);
  font-family: "Bowlby One", serif;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  transform: rotate(var(--rot, 0deg));
  transition: transform 0.2s;
}
.pill:hover { transform: rotate(0) scale(1.1); }

/* ---------- HOW / NOW ------------------------------------------- */

.how-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
  margin-top: 30px;
}
.how-card {
  background: var(--c, var(--yellow));
  border: 3.5px solid var(--ink);
  border-radius: 24px;
  padding: 24px;
  box-shadow: 6px 6px 0 var(--ink);
  transform: rotate(var(--rot, -1deg));
  transition: transform 0.2s;
}
.how-card:hover { transform: rotate(0) translateY(-4px); }
.how-num {
  font-family: "Bowlby One", serif;
  font-size: 56px;
  line-height: 1;
  margin: 0 0 10px;
  -webkit-text-stroke: 2px var(--ink);
  color: var(--cream);
}
.how-title {
  font-family: "Bowlby One", serif;
  font-size: 22px;
  margin: 0 0 8px;
}
.how-body {
  font-family: "Fraunces", serif;
  font-size: 16px;
  line-height: 1.4;
  margin: 0;
}

.now-strip {
  background: var(--ink);
  color: var(--cream);
  border: 4px solid var(--ink);
  border-radius: 28px;
  padding: 28px 32px;
  box-shadow: 10px 10px 0 var(--red);
  position: relative;
  overflow: hidden;
}
.now-strip::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(45deg,
      transparent 0 30px,
      rgba(255,255,255,0.03) 30px 31px);
  pointer-events: none;
}
.now-list {
  position: relative;
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 14px;
}
.now-row {
  display: grid;
  grid-template-columns: 90px 1fr auto;
  gap: 16px;
  align-items: baseline;
  padding-bottom: 12px;
  border-bottom: 1.5px dashed rgba(255,246,223,0.25);
}
.now-row:last-child { border-bottom: none; }
.now-tag {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  background: var(--c, var(--lime));
  color: var(--ink);
  padding: 3px 10px;
  border-radius: 999px;
  text-align: center;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.now-text { font-family: "Fraunces", serif; font-size: 17px; }
.now-when { font-family: "IBM Plex Mono", monospace; font-size: 12px; opacity: 0.6; }

/* ---------- FOOTER ---------------------------------------------- */

.footer-cartoon {
  text-align: center;
  padding: 100px 24px 60px;
  position: relative;
}
.footer-big {
  font-family: "Bowlby One", serif;
  font-size: clamp(48px, 12vw, 160px);
  line-height: 1;
  margin: 0;
  padding-bottom: 0.18em;
  background: linear-gradient(90deg, var(--red), var(--orange), var(--yellow), var(--lime), var(--teal), var(--blue), var(--purple));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-stroke: 2px var(--ink);
  filter: drop-shadow(6px 6px 0 var(--ink));
}
.footer-mail {
  display: inline-block;
  margin-top: 36px;
  padding: 14px 36px;
  background: var(--cream);
  border: 3px solid var(--ink);
  border-radius: 999px;
  box-shadow: 5px 5px 0 var(--ink);
  font-family: "Bowlby One", serif;
  font-size: 18px;
  color: var(--ink);
  text-decoration: none;
  text-transform: lowercase;
  transition: transform 0.2s;
}
.footer-mail:hover { transform: translate(-2px, -2px) rotate(-2deg); box-shadow: 7px 7px 0 var(--red); }

/* ---------- PROJECT CTA BUTTON --------------------------------- */

.project-cta {
  display: block;
  width: fit-content;
  margin: 24px auto 0 0;
  padding: 14px 28px;
  background: var(--c, var(--yellow));
  border: 3px solid var(--ink);
  border-radius: 999px;
  box-shadow: 5px 5px 0 var(--ink);
  font-family: "Bowlby One", serif;
  font-size: 16px;
  letter-spacing: 0.02em;
  color: var(--ink);
  text-decoration: none;
  text-transform: lowercase;
  transform: rotate(-1deg);
  transition: transform 0.2s, box-shadow 0.2s;
}
.project-cta:hover {
  transform: translate(-2px, -2px) rotate(-2deg);
  box-shadow: 7px 7px 0 var(--ink);
}
.project-card.right .project-cta { margin: 24px 0 0 auto; transform: rotate(1deg); }
.project-card.right .project-cta:hover { transform: translate(-2px, -2px) rotate(2deg); }

/* ---------- FRAME OVERRIDES (to soft-blend mockups in) ---------- */

.bro-frame .ip-shell { transform: scale(0.78) rotate(-3deg); transform-origin: center; }
.exp-frame { padding: 0; }

/* ---------- POPUP RIBBON ---------------------------------------- */

.ribbon-shape {
  position: absolute;
  font-family: "Bowlby One", serif;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 8px 26px 8px 18px;
  background: var(--c, var(--red));
  color: #fff;
  border: 2.5px solid var(--ink);
  clip-path: polygon(0 0, 100% 0, calc(100% - 12px) 50%, 100% 100%, 0 100%);
  box-shadow: 3px 3px 0 var(--ink);
  transform: rotate(var(--rot, -4deg));
}

/* ---------- ENTRANCE ANIMS -------------------------------------- */

.reveal {
  opacity: 0;
  transform: translateY(20px) rotate(0.5deg);
  transition: opacity 0.6s, transform 0.6s;
}
.reveal.in { opacity: 1; transform: translateY(0) rotate(var(--rot, 0deg)); }

/* ---------- TWEAKS overrides ----------------------------------- */

body.cartoon.no-spin .sunburst,
body.cartoon.no-spin .doodle { animation-play-state: paused; }

body.cartoon.tone-acid {
  --cream: #f6ffeb;
  --cream-2: #d6ff8c;
  background: var(--cream);
}
body.cartoon.tone-bubblegum {
  --cream: #ffe5f1;
  --cream-2: #ffb8d8;
  background: var(--cream);
}
body.cartoon.tone-cosmic {
  --cream: #1a1235;
  --cream-2: #2a1a55;
  --ink: #fff6df;
  background: var(--cream);
  color: var(--ink);
}
