/* Williams Funzone LLC — bubbly cartoon brand */
/* Fonts are loaded via <link> in index.html <head> (faster than @import). */

:root {
  --red: #E63946;
  --red-deep: #C5283D;
  --blue: #1E5BD8;
  --blue-deep: #134EB8;
  --yellow: #FFC72C;
  --yellow-deep: #F4A300;
  --green: #4CC26A;
  --pink: #FF6FB5;
  --cream: #FFF6E0;
  --sky: #BFE7FF;
  --ink: #1A1147;
  --paper: #FFFBF0;
}

* { box-sizing: border-box; }

/* Visible keyboard focus (mouse clicks stay clean via :focus-visible) */
:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
  border-radius: 6px;
}
/* On the dark booking section, the ink outline disappears — use yellow there */
#book :focus-visible { outline-color: var(--yellow); }

html { scroll-behavior: smooth; }

html, body {
  margin: 0;
  padding: 0;
  font-family: 'Fredoka', system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  overflow-x: hidden;
}

img { max-width: 100%; }

.display { font-family: 'Luckiest Guy', cursive; letter-spacing: 0.02em; font-weight: 400; }
.chunky  { font-family: 'Bagel Fat One', cursive; letter-spacing: 0.01em; font-weight: 400; }

/* Skip link for keyboard / screen-reader users */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 8px;
  background: var(--ink);
  color: var(--yellow);
  padding: 10px 16px;
  border-radius: 999px;
  z-index: 200;
  font-weight: 700;
  text-decoration: none;
}
.skip-link:focus { left: 12px; }

/* Bubbles background */
.bubbles {
  position: absolute; inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}
.bubble {
  position: absolute;
  border-radius: 50%;
  opacity: 0.55;
  animation: float 8s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(8deg); }
}

/* Confetti dot pattern background */
.confetti-bg {
  background-image:
    radial-gradient(circle at 12% 20%, var(--yellow) 4px, transparent 5px),
    radial-gradient(circle at 78% 35%, var(--red) 5px, transparent 6px),
    radial-gradient(circle at 30% 70%, var(--blue) 4px, transparent 5px),
    radial-gradient(circle at 85% 80%, var(--pink) 4px, transparent 5px),
    radial-gradient(circle at 50% 15%, var(--green) 3px, transparent 4px),
    radial-gradient(circle at 20% 90%, var(--blue) 3px, transparent 4px),
    radial-gradient(circle at 65% 55%, var(--yellow) 4px, transparent 5px);
  background-size: 280px 280px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 28px;
  border-radius: 999px;
  font-family: 'Fredoka', sans-serif;
  font-weight: 700;
  font-size: 18px;
  text-decoration: none;
  border: 4px solid var(--ink);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 6px 0 var(--ink);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 0 var(--ink); }
.btn:active { transform: translateY(4px); box-shadow: 0 2px 0 var(--ink); }
.btn-red { background: var(--red); color: white; }
.btn-blue { background: var(--blue); color: white; }
.btn-yellow { background: var(--yellow); color: var(--ink); }
.btn-white { background: white; color: var(--ink); }

/* Bubble card */
.bubble-card {
  background: white;
  border-radius: 28px;
  border: 4px solid var(--ink);
  box-shadow: 0 8px 0 var(--ink);
  padding: 24px;
  position: relative;
  overflow: hidden;
}

/* Section padding */
.section { padding: 80px 24px; position: relative; }
.container { max-width: 1200px; margin: 0 auto; position: relative; z-index: 2; }

/* Headings */
h1, h2, h3 { margin: 0; line-height: 1.05; text-wrap: balance; }
/* Even out longer prose / multi-line copy */
.hero-sub, .section-head p, .faq-a, .inv-cap, .extra p, .step p { text-wrap: pretty; }

/* Sticker-style heading with double outline */
.sticker {
  display: inline-block;
  position: relative;
  font-family: 'Luckiest Guy', cursive;
  color: var(--yellow);
  -webkit-text-stroke: 0;
  text-shadow:
    -3px 0 0 var(--ink), 3px 0 0 var(--ink), 0 -3px 0 var(--ink), 0 3px 0 var(--ink),
    -3px -3px 0 var(--ink), 3px -3px 0 var(--ink), -3px 3px 0 var(--ink), 3px 3px 0 var(--ink),
    -6px 6px 0 var(--red);
  letter-spacing: 0.03em;
  line-height: 1;
}

.sticker-blue {
  color: white;
  text-shadow:
    -3px 0 0 var(--blue-deep), 3px 0 0 var(--blue-deep), 0 -3px 0 var(--blue-deep), 0 3px 0 var(--blue-deep),
    -3px -3px 0 var(--blue-deep), 3px -3px 0 var(--blue-deep), -3px 3px 0 var(--blue-deep), 3px 3px 0 var(--blue-deep),
    -6px 6px 0 var(--ink);
}

/* Tilt utilities */
.tilt-l { transform: rotate(-2deg); }
.tilt-r { transform: rotate(2deg); }

/* Marquee */
.marquee {
  overflow: hidden;
  white-space: nowrap;
  background: var(--ink);
  color: var(--yellow);
  padding: 18px 0;
  font-family: 'Bagel Fat One', cursive;
  font-size: 28px;
  border-top: 4px solid var(--yellow);
  border-bottom: 4px solid var(--yellow);
}
.marquee-track {
  display: inline-block;
  animation: marquee 30s linear infinite;
}
.marquee span { margin: 0 30px; }
.marquee .star { color: var(--red); }
@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Wiggle on hover */
.wiggle:hover { animation: wiggle 0.4s ease-in-out; }
@keyframes wiggle {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(-3deg); }
  75% { transform: rotate(3deg); }
}

/* Bouncing element */
.bounce { animation: bounce 2.5s ease-in-out infinite; }
@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

/* Phone link */
.phone-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  min-height: 44px;
  border-radius: 999px;
  background: white;
  border: 3px solid var(--ink);
  box-shadow: 0 4px 0 var(--ink);
  text-decoration: none;
  color: var(--ink);
  font-weight: 700;
  font-size: 16px;
  transition: transform 0.15s;
}
.phone-pill:hover { transform: translateY(-2px); box-shadow: 0 6px 0 var(--ink); }

/* Form */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) {
  .form-grid { grid-template-columns: 1fr; }
}
.field label {
  display: block;
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 6px;
  color: var(--ink);
}
.field input, .field select, .field textarea {
  width: 100%;
  padding: 14px 16px;
  border-radius: 16px;
  border: 3px solid var(--ink);
  font-family: 'Fredoka', sans-serif;
  font-size: 16px;
  background: white;
  color: var(--ink);
  outline: none;
  transition: box-shadow 0.15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  box-shadow: 0 0 0 4px var(--yellow);
}
.field textarea { min-height: 100px; resize: vertical; }

/* Inventory card */
.inv-card {
  background: white;
  border-radius: 24px;
  border: 4px solid var(--ink);
  box-shadow: 0 8px 0 var(--ink);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
}
.inv-card:hover { transform: translateY(-4px); box-shadow: 0 12px 0 var(--ink); }
.inv-thumb {
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  font-size: 92px;
  line-height: 1;
}
.inv-thumb svg { width: 88%; height: 88%; }
.inv-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.inv-body { padding: 18px 22px 22px; display: flex; flex-direction: column; flex: 1; }
.inv-tag {
  display: inline-block;
  align-self: flex-start;
  background: var(--yellow);
  color: var(--ink);
  font-weight: 700;
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 999px;
  border: 2px solid var(--ink);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.inv-title { font-size: 22px; margin: 10px 0 4px; font-weight: 700; }
.inv-cap { font-size: 14px; opacity: 0.7; margin-bottom: 10px; }
.inv-price { font-weight: 700; color: var(--red-deep); font-size: 18px; margin-top: auto; }
.inv-price small { font-weight: 500; color: var(--ink); opacity: 0.6; font-size: 13px; }
.inv-cta {
  margin-top: 12px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 44px;
  background: var(--red);
  color: white;
  text-decoration: none;
  font-weight: 700;
  font-size: 15px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 3px solid var(--ink);
  box-shadow: 0 4px 0 var(--ink);
  transition: transform 0.15s, box-shadow 0.15s;
}
.inv-cta:hover { transform: translateY(-2px); box-shadow: 0 6px 0 var(--ink); }
.inv-cta:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--ink); }

/* Gallery */
.gal-tile {
  border-radius: 20px;
  border: 4px solid var(--ink);
  box-shadow: 0 6px 0 var(--ink);
  overflow: hidden;
  position: relative;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gal-tile svg { width: 70%; height: 70%; }
.gal-tile img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Big nav */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--paper);
  border-bottom: 4px solid var(--ink);
}
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Luckiest Guy', cursive;
  font-size: 24px;
  color: var(--blue);
  text-decoration: none;
  text-shadow: 2px 2px 0 var(--ink);
}
.nav-links {
  display: flex;
  gap: 4px;
  align-items: center;
}
.nav-links a {
  padding: 8px 14px;
  border-radius: 999px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  font-size: 15px;
  transition: background 0.15s;
}
.nav-links a:hover { background: var(--yellow); }
.nav-right { display: flex; align-items: center; gap: 10px; }

/* Hamburger toggle */
.nav-toggle {
  display: none;
  background: var(--yellow);
  border: 3px solid var(--ink);
  border-radius: 12px;
  width: 46px;
  height: 44px;
  cursor: pointer;
  padding: 0;
  box-shadow: 0 4px 0 var(--ink);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 3px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.2s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--paper);
    border-bottom: 4px solid var(--ink);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 16px 16px;
    box-shadow: 0 10px 20px rgba(26,17,71,0.18);
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a {
    padding: 14px 12px;
    font-size: 18px;
    border-bottom: 1px solid rgba(26,17,71,0.08);
  }
  /* Hide the desktop "Book Now" button on mobile; Book lives in the menu */
  .nav-book-desktop { display: none; }
}
@media (min-width: 861px) {
  .nav-toggle { display: none; }
}

/* Footer */
footer {
  background: var(--ink);
  color: var(--cream);
  padding: 48px 24px 24px;
  text-align: center;
}
footer a { color: var(--yellow); }
.footer-links {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 20px;
}
.footer-links a { text-decoration: none; font-weight: 600; }

/* Sun rays bg */
.rays {
  background:
    repeating-conic-gradient(from 0deg at 50% 110%, var(--yellow) 0deg 12deg, var(--yellow-deep) 12deg 24deg);
}

/* Pop-in */
.pop-in { animation: popIn 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) both; }
@keyframes popIn {
  0% { transform: scale(0.5); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

/* Hero */
.hero { position: relative; overflow: hidden; min-height: 640px; background: linear-gradient(180deg, #BFE7FF 0%, #FFF6E0 100%); }
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 40px;
  align-items: center;
  padding: 60px 0;
  min-height: 640px;
}
.hero-h1 { font-size: clamp(48px, 8vw, 110px); line-height: 0.9; }
.hero-sub { font-size: clamp(18px, 2.4vw, 24px); font-weight: 500; max-width: 540px; line-height: 1.4; }
.avail-pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: white; border: 3px solid var(--ink); border-radius: 999px;
  padding: 6px 16px; box-shadow: 0 4px 0 var(--ink);
  margin-bottom: 20px; font-weight: 700; font-size: 14px;
}
.avail-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(76,194,106,0.3); }
.hero-art { position: relative; }

@media (max-width: 820px) {
  .hero-grid { grid-template-columns: 1fr; gap: 24px; text-align: center; min-height: 0; padding: 40px 0 56px; }
  .hero-sub { margin-left: auto; margin-right: auto; }
  .hero-grid .hero-btns,
  .hero-grid .hero-phones { justify-content: center; }
  .hero-art { max-width: 420px; margin: 0 auto; }
  .hero { min-height: 0; }
}

/* Star burst */
.starburst {
  position: absolute;
  width: 180px;
  height: 180px;
  background: var(--red);
  clip-path: polygon(
    50% 0%, 61% 35%, 98% 35%, 68% 57%,
    79% 91%, 50% 70%, 21% 91%, 32% 57%,
    2% 35%, 39% 35%
  );
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-family: 'Luckiest Guy', cursive;
  color: white;
  text-shadow: 2px 2px 0 var(--ink);
  font-size: 16px;
  line-height: 1.1;
  padding: 0;
  animation: spin 12s linear infinite;
}
.starburst-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 56%;
  height: 56%;
}
.starburst-inner .small { font-size: 13px; opacity: 0.95; }
.starburst-inner .big { font-size: 30px; line-height: 1; margin-top: 2px; }
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
@media (max-width: 820px) {
  .starburst { width: 130px; height: 130px; font-size: 13px; }
  .starburst-inner .big { font-size: 24px; }
}

/* Logo image sizing */
.castle-img {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 12px 0 rgba(26, 17, 71, 0.18));
}

/* Stats row */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.stat {
  text-align: center;
  padding: 18px;
  border-radius: 20px;
  background: white;
  border: 3px solid var(--ink);
  box-shadow: 0 5px 0 var(--ink);
}
.stat-num { font-family: 'Luckiest Guy', cursive; font-size: 38px; line-height: 1; }
.stat-lbl { font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; margin-top: 6px; }
@media (max-width: 700px) { .stats { grid-template-columns: repeat(2, 1fr); } }

/* Section heading wrapper */
.section-head {
  text-align: center;
  margin-bottom: 48px;
  position: relative;
}
.section-head .sticker { font-size: clamp(40px, 6vw, 72px); }
.section-head p { margin-top: 18px; font-size: 18px; color: var(--ink); opacity: 0.8; max-width: 640px; margin-left: auto; margin-right: auto; }

/* Inventory grid */
.inv-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

/* Extra strip */
.extras-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 18px;
}
.extra {
  text-align: center;
  padding: 22px 14px;
  border-radius: 22px;
  background: white;
  border: 4px solid var(--ink);
  box-shadow: 0 6px 0 var(--ink);
  transition: transform 0.2s;
}
.extra:hover { transform: translateY(-4px) rotate(-1deg); }
.extra-icon {
  width: 64px; height: 64px;
  margin: 0 auto 10px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  font-size: 32px;
}
.extra h3 { margin: 6px 0 4px; font-size: 16px; }
.extra p { margin: 0; font-size: 13px; opacity: 0.75; }

/* How it works */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
@media (max-width: 800px) { .steps { grid-template-columns: 1fr 1fr; } }
.step {
  text-align: center;
  position: relative;
}
.step-num {
  width: 80px; height: 80px;
  margin: 0 auto 14px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: var(--yellow);
  border: 4px solid var(--ink);
  box-shadow: 0 6px 0 var(--ink);
  font-family: 'Luckiest Guy', cursive;
  font-size: 38px;
  color: var(--ink);
}
.step h3 { font-size: 20px; margin: 0 0 6px; }
.step p { font-size: 14px; margin: 0; opacity: 0.8; }

/* Booking grid */
.book-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 28px;
  align-items: start;
}
@media (max-width: 760px) {
  .book-grid { grid-template-columns: 1fr; }
}

/* FAQ */
.faq-item {
  background: white;
  border-radius: 18px;
  border: 3px solid var(--ink);
  margin-bottom: 14px;
  overflow: hidden;
}
.faq-q {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 22px;
  cursor: pointer;
  font-weight: 600;
  font-size: 17px;
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  font-family: 'Fredoka', sans-serif;
  color: var(--ink);
}
.faq-q:hover { background: var(--cream); }
.faq-a {
  padding: 0 22px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  font-size: 15px;
  opacity: 0.85;
}
.faq-item.open .faq-a { max-height: 260px; padding: 0 22px 18px; }
.faq-q .chev {
  flex: 0 0 auto;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--blue);
  color: white;
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 700;
  transition: transform 0.3s;
}
.faq-item.open .chev { transform: rotate(45deg); }

/* Party packages */
.pkg-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}
.pkg-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: white;
  color: var(--ink);
  border: 4px solid var(--ink);
  border-radius: 24px;
  box-shadow: 0 8px 0 var(--ink);
  padding: 26px 24px 24px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.pkg-card:hover { transform: translateY(-4px); box-shadow: 0 12px 0 var(--ink); }
.pkg-featured { background: var(--yellow); }
.pkg-ribbon {
  position: absolute;
  top: -14px;
  right: 18px;
  background: var(--red);
  color: white;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 6px 14px;
  border-radius: 999px;
  border: 3px solid var(--ink);
  box-shadow: 0 3px 0 var(--ink);
}
.pkg-title { font-size: 24px; font-weight: 700; margin-bottom: 2px; }
.pkg-tag { font-size: 14px; font-weight: 600; opacity: 0.7; margin: 0 0 14px; }
.pkg-list { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 9px; flex: 1; }
.pkg-list li {
  position: relative;
  padding-left: 28px;
  font-size: 15px;
  line-height: 1.35;
}
.pkg-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: -1px;
  width: 20px;
  height: 20px;
  background: var(--green);
  color: white;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pkg-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  background: var(--red);
  color: white;
  text-decoration: none;
  font-weight: 700;
  font-size: 15px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 3px solid var(--ink);
  box-shadow: 0 4px 0 var(--ink);
  transition: transform 0.15s, box-shadow 0.15s;
}
.pkg-cta:hover { transform: translateY(-2px); box-shadow: 0 6px 0 var(--ink); }
.pkg-cta:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--ink); }

/* Respect reduced-motion: kill decorative loops */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .bounce, .bubble, .starburst, .marquee-track, .wiggle:hover, .pop-in {
    animation: none !important;
  }
  .btn, .phone-pill, .inv-card, .extra, .inv-cta { transition: none !important; }
}
