/* FishyCell theme, used by its product page and its homepage section.
   The game's reef: sunlit water, bubbles, cream panels, wooden signs and Fredoka.
   Motion is CSS only and starts after the content is already readable. */

@font-face {
  font-family: "Fredoka";
  font-style: normal;
  font-display: swap;
  font-weight: 500;
  src: url(/fonts/fredoka-latin-ext-500-normal.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Fredoka";
  font-style: normal;
  font-display: swap;
  font-weight: 500;
  src: url(/fonts/fredoka-latin-500-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Fredoka";
  font-style: normal;
  font-display: swap;
  font-weight: 600;
  src: url(/fonts/fredoka-latin-ext-600-normal.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Fredoka";
  font-style: normal;
  font-display: swap;
  font-weight: 600;
  src: url(/fonts/fredoka-latin-600-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

.fc-hero,
.fc-section,
.fc-band {
  --fc-surface: #8be4ec;
  --fc-water: #2bb6c9;
  --fc-deep: #13809d;
  --fc-abyss: #0b5b78;
  --fc-ink: #0f4458;
  --fc-cream: #fff8e8;
  --fc-sand: #f6e2b3;
  --fc-wood: #c98a4b;
  --fc-wood-dark: #8a5a2b;
  --fc-green: #4cc94a;
  --fc-green-dark: #2a8a2a;
  --fc-yellow: #ffd23f;
  --fc-coral: #ff7b7b;
  --fc-font: "Fredoka", "Archivo", "Arial Rounded MT Bold", sans-serif;
  color: #fff;
  font-family: var(--fc-font);
  font-weight: 500;
}

body.theme-fishycell {
  background: #f6e2b3;
}

.fc-wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.fc-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Bubbles rise from below; each one has its own column, size, delay and speed. */
.fc-bubbles {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.fc-bubbles span {
  position: absolute;
  left: var(--x);
  bottom: -60px;
  width: var(--s);
  height: var(--s);
  border: 1.5px solid rgba(255, 255, 255, 0.75);
  border-radius: 50%;
  background: radial-gradient(circle at 32% 30%, rgba(255, 255, 255, 0.95) 0 14%, rgba(255, 255, 255, 0.18) 15% 62%, rgba(255, 255, 255, 0.4) 100%);
  opacity: 0;
}

/* Shared parts */
.fc-tagline {
  margin-top: 14px;
  font-size: clamp(26px, 2.8vw, 40px);
  font-weight: 600;
  line-height: 1.1;
  text-shadow: 0 3px 0 rgba(11, 91, 120, 0.45);
}

.fc-lead {
  margin-top: 14px;
  max-width: 44ch;
  color: #effdff;
  font-size: clamp(18px, 1.5vw, 21px);
  line-height: 1.45;
}

/* "Coming soon" as the game's green button, but not a link. */
.fc-actions .soon-store,
.fc-home .soon-store {
  min-height: 56px;
  padding: 7px 30px 9px;
  border: 4px solid #fff;
  border-radius: 999px;
  background: linear-gradient(180deg, #86e868 0%, var(--fc-green) 55%, #36ad35 100%);
  box-shadow: 0 6px 0 var(--fc-green-dark), 0 10px 22px rgba(11, 91, 120, 0.3);
  color: #fff;
  text-align: center;
}

.fc-actions .soon-store .label,
.fc-home .soon-store .label {
  color: #f0ffe8;
  font-family: var(--fc-font);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.fc-actions .soon-store strong,
.fc-home .soon-store strong {
  font-size: 22px;
  font-weight: 600;
  text-shadow: 0 2px 0 var(--fc-green-dark);
}

.fc-actions,
.fc-home .actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 26px;
}

.fc-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 26px;
  border: 4px solid #fff;
  border-radius: 999px;
  background: var(--fc-cream);
  box-shadow: 0 5px 0 rgba(11, 91, 120, 0.35);
  color: var(--fc-ink);
  font-size: 19px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.15s ease, background-color 0.15s ease;
}

.fc-btn svg {
  width: 18px;
  height: 18px;
}

.fc-btn:hover,
.fc-btn:focus-visible {
  background: var(--fc-yellow);
  transform: translateY(-3px);
  outline: none;
}

.fc-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.fc-stats li {
  display: grid;
  place-content: center;
  width: 112px;
  height: 112px;
  border: 3px solid rgba(255, 255, 255, 0.85);
  border-radius: 50%;
  background: radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0.14) 60%);
  text-align: center;
}

.fc-stats strong {
  font-size: 30px;
  font-weight: 600;
  line-height: 1;
}

.fc-stats span {
  max-width: 9ch;
  margin-top: 4px;
  font-size: 14px;
  line-height: 1.1;
}

/* The board: the game's checkered grid in a white frame. */
.fc-board {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
  width: min(100%, 520px);
  padding: 14px;
  border: 7px solid #fff;
  border-radius: 30px;
  background: rgba(214, 248, 252, 0.55);
  box-shadow: 0 14px 0 rgba(11, 91, 120, 0.28), 0 26px 50px rgba(11, 91, 120, 0.25);
}

.fc-cell {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.55);
}

.fc-cell:nth-child(even) {
  background: rgba(194, 240, 246, 0.75);
}

.fc-cell img {
  width: 92%;
  height: auto;
  filter: drop-shadow(0 4px 0 rgba(11, 91, 120, 0.25));
  transition: transform 0.2s ease;
}

.fc-cell:hover img {
  transform: scale(1.14) rotate(-6deg);
}

.fc-wave {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  width: 100%;
  height: clamp(40px, 6vw, 80px);
  fill: var(--wave, var(--fc-cream));
}

/* Hero */
.fc-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: 28px 0 clamp(90px, 10vw, 150px);
  background: linear-gradient(180deg, var(--fc-surface) 0%, #4cc9d8 32%, var(--fc-water) 62%, var(--fc-deep) 100%);
}

.fc-rays {
  position: absolute;
  inset: -20% -10% 30%;
  z-index: -1;
  background: repeating-linear-gradient(100deg, rgba(255, 255, 255, 0.16) 0 46px, rgba(255, 255, 255, 0) 46px 150px);
  -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 85%);
  mask-image: linear-gradient(180deg, #000 0%, transparent 85%);
  transform-origin: top center;
}

.fc-crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 16px;
}

.fc-crumbs a {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.fc-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: clamp(28px, 4vw, 72px);
  align-items: center;
}

.fc-logo {
  margin-top: clamp(28px, 4vw, 56px);
}

.fc-logo img {
  width: clamp(260px, 34vw, 520px);
  height: auto;
  filter: drop-shadow(0 6px 0 rgba(11, 91, 120, 0.3));
}

.fc-hero .fc-board {
  justify-self: end;
  margin-top: clamp(24px, 4vw, 48px);
}

.fc-mascot {
  position: absolute;
  top: 6%;
  right: 6%;
  z-index: 2;
  width: clamp(72px, 8vw, 120px);
  height: auto;
  filter: drop-shadow(0 8px 0 rgba(11, 91, 120, 0.25));
  pointer-events: none;
}

/* Sections */
.fc-section {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(64px, 9vw, 120px) 0;
  background: var(--fc-water);
}

.fc-section--cream {
  background: var(--fc-cream);
  color: var(--fc-ink);
}

.fc-section--deep {
  background: linear-gradient(180deg, var(--fc-deep) 0%, var(--fc-abyss) 100%);
}

.fc-section--sand {
  background: var(--fc-sand);
  color: var(--fc-ink);
}

.fc-section--sand + .fc-section--sand {
  padding-top: 0;
}

/* Section titles on the game's wooden sign. */
.fc-head {
  display: grid;
  justify-items: start;
  gap: 16px;
  margin-bottom: clamp(28px, 4vw, 48px);
}

.fc-head h2 {
  padding: 8px 30px 10px;
  border: 5px solid var(--fc-wood-dark);
  border-radius: 20px;
  background: linear-gradient(180deg, #dca066 0%, var(--fc-wood) 60%, #b5763b 100%);
  box-shadow: 0 6px 0 rgba(90, 56, 22, 0.45);
  color: var(--fc-cream);
  font-size: clamp(30px, 4vw, 52px);
  font-weight: 600;
  line-height: 1.1;
  text-shadow: 0 3px 0 rgba(90, 56, 22, 0.6);
  transform: rotate(-1.5deg);
}

.fc-note {
  max-width: 56ch;
  font-size: clamp(18px, 1.4vw, 20px);
  line-height: 1.45;
}

/* Feature cards */
.fc-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 2vw, 28px);
  border: 0;
}

.fc-cards li {
  display: grid;
  justify-items: center;
  gap: 14px;
  padding: 26px 24px 30px;
  border: 5px solid #9be6ee;
  border-radius: 30px;
  background: #fff;
  box-shadow: 0 8px 0 #9be6ee;
  color: var(--fc-ink);
  font-size: clamp(19px, 1.6vw, 22px);
  line-height: 1.35;
  text-align: center;
  transition: transform 0.2s ease;
}

.fc-cards li::before {
  content: none;
}

.fc-cards li:hover {
  transform: translateY(-6px) rotate(-1deg);
}

.fc-cards img {
  width: 110px;
  height: auto;
}

/* Boosters */
.fc-boosters {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(14px, 2vw, 24px);
}

.fc-boosters li {
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 22px 18px 26px;
  border: 4px solid rgba(255, 255, 255, 0.85);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.18);
  text-align: center;
}

.fc-boosters img {
  width: 120px;
  height: auto;
  margin-bottom: 6px;
  filter: drop-shadow(0 6px 0 rgba(11, 91, 120, 0.3));
}

.fc-boosters strong {
  font-size: 24px;
  font-weight: 600;
}

.fc-boosters span {
  color: #effdff;
  font-size: 17px;
}

/* Reef map */
.fc-route {
  position: relative;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
  font-size: 18px;
  text-align: center;
}

.fc-route::before {
  content: "";
  position: absolute;
  top: 33px;
  left: 10%;
  right: 10%;
  border-top: 6px dotted rgba(255, 255, 255, 0.6);
}

.fc-route li {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 10px;
}

.fc-route-dot {
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border: 5px solid #fff;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #7ad8e6, var(--fc-deep));
  box-shadow: 0 6px 0 rgba(0, 40, 60, 0.35);
  font-size: 24px;
  font-weight: 600;
}

.fc-route li:last-child .fc-route-dot {
  background: radial-gradient(circle at 35% 30%, #ffe680, #f0a500);
  color: #6b4300;
}

.fc-friends {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  margin-top: clamp(48px, 6vw, 80px);
  text-align: center;
}

.fc-friends li {
  display: grid;
  justify-items: center;
  gap: 8px;
  font-size: 17px;
}

.fc-friends img {
  width: min(112px, 100%);
  height: auto;
  filter: drop-shadow(0 8px 0 rgba(0, 40, 60, 0.3));
}

/* Phone screens */
.fc-phones {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 300px));
  justify-content: center;
  gap: clamp(16px, 3vw, 48px);
}

.fc-phones a {
  display: block;
  overflow: hidden;
  border: 10px solid var(--fc-ink);
  border-radius: 38px;
  background: var(--fc-ink);
  box-shadow: 0 14px 0 rgba(11, 91, 120, 0.3);
  transition: transform 0.2s ease;
}

.fc-phones a:hover {
  transform: translateY(-8px) rotate(-1.5deg);
}

.fc-phones img {
  width: 100%;
  border-radius: 28px;
}

.fc-phones figcaption {
  margin-top: 14px;
  font-size: 17px;
  text-align: center;
}

/* Support and related rows on sand */
.fc-split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 24px clamp(28px, 5vw, 80px);
  align-items: start;
}

.fc-section .link-list {
  display: grid;
  gap: 10px;
  border: 0;
}

.fc-section .link-list a {
  padding: 16px 22px;
  border: 4px solid #fff;
  border-radius: 22px;
  background: var(--fc-cream);
  box-shadow: 0 5px 0 rgba(138, 90, 43, 0.25);
}

.fc-section .link-list strong {
  font-family: var(--fc-font);
  font-size: 21px;
  font-weight: 600;
}

.fc-section .link-list span {
  color: #5a7480;
}

.fc-section .link-list a:hover {
  background: var(--fc-water);
  color: #fff;
  padding-left: 22px;
  padding-right: 22px;
}

.fc-more .rows {
  border-top-color: rgba(15, 68, 88, 0.3);
  font-family: var(--font);
}

.fc-more .row {
  border-bottom-color: rgba(15, 68, 88, 0.3);
}

.fc-more .row:hover,
.fc-more .row:focus-visible {
  background: var(--fc-water);
  color: #fff;
}

/* Homepage section */
.fc-band {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(96px, 11vw, 160px) 0 clamp(96px, 11vw, 150px);
  background: linear-gradient(180deg, var(--fc-surface) 0%, var(--fc-water) 55%, var(--fc-deep) 100%);
}

.fc-band .bar {
  font-family: var(--font);
}

.fc-band .bar .label,
.fc-band .text-link {
  color: #fff;
}

.fc-band .text-link:hover {
  color: var(--fc-yellow);
}

.fc-wave--top {
  top: -1px;
  bottom: auto;
  transform: scaleY(-1);
  fill: var(--paper);
}

.fc-band > .fc-wave:not(.fc-wave--top) {
  fill: var(--paper);
}

/* Straight after the Dead Drift band the water meets asphalt, not paper. */
.dd-band + .fc-band .fc-wave--top {
  fill: #0e0f11;
}

.fc-home {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(28px, 4vw, 72px);
  align-items: center;
  margin-top: clamp(28px, 4vw, 48px);
}

.fc-home .fc-board {
  width: min(100%, 460px);
}

.fc-home-logo img {
  width: clamp(240px, 28vw, 440px);
  height: auto;
  filter: drop-shadow(0 6px 0 rgba(11, 91, 120, 0.3));
}

.fc-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.fc-facts li {
  padding: 5px 16px 6px;
  border: 3px solid rgba(255, 255, 255, 0.85);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  font-size: 17px;
  font-weight: 600;
}

.fc-small {
  display: inline-block;
  margin-top: 20px;
  color: #fff;
  font-size: 17px;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.fc-small:hover {
  color: var(--fc-yellow);
}

/* Motion: page load */
@media (prefers-reduced-motion: no-preference) {
  .fc-bubbles span {
    animation: fc-rise var(--t) var(--d) linear infinite;
  }

  .fc-rays {
    animation: fc-sway 9s ease-in-out infinite alternate;
  }

  .fc-mascot {
    animation: fc-swim-down 1.6s cubic-bezier(0.25, 1.2, 0.4, 1) both, fc-bob 3.2s 1.6s ease-in-out infinite;
  }

  .fc-hero .fc-logo img {
    animation: fc-pop 0.8s 0.2s cubic-bezier(0.3, 1.6, 0.5, 1) both;
  }

  .fc-hero .fc-tagline,
  .fc-hero .fc-lead,
  .fc-hero .fc-actions {
    animation: fc-float-in 0.7s cubic-bezier(0.25, 1.2, 0.4, 1) both;
  }

  .fc-hero .fc-tagline { animation-delay: 0.45s; }
  .fc-hero .fc-lead { animation-delay: 0.55s; }
  .fc-hero .fc-actions { animation-delay: 0.65s; }

  .fc-hero .fc-stats li {
    animation: fc-pop 0.6s calc(0.8s + var(--i) * 0.12s) cubic-bezier(0.3, 1.6, 0.5, 1) both;
  }

  /* Pieces fall into the board bottom row first, like a level refilling. */
  .fc-hero .fc-cell img {
    animation: fc-drop 0.75s calc(0.3s + var(--c) * 0.07s + (3 - var(--r)) * 0.11s) cubic-bezier(0.3, 1.35, 0.5, 1) both;
  }
}

@keyframes fc-rise {
  0% { transform: translate(0, 0); opacity: 0; }
  10% { opacity: 0.9; }
  50% { transform: translate(14px, -55vh); }
  90% { opacity: 0.8; }
  100% { transform: translate(-6px, -115vh); opacity: 0; }
}

@keyframes fc-sway {
  from { transform: skewX(-4deg) translateX(-2%); }
  to { transform: skewX(5deg) translateX(2%); }
}

@keyframes fc-swim-down {
  0% { transform: translate(-40px, -280%) rotate(-25deg); opacity: 0; }
  60% { transform: translate(10px, 10%) rotate(8deg); opacity: 1; }
  100% { transform: none; opacity: 1; }
}

@keyframes fc-bob {
  50% { transform: translateY(-12px) rotate(-4deg); }
}

@keyframes fc-pop {
  from { transform: scale(0.4); opacity: 0; }
  to { transform: none; opacity: 1; }
}

@keyframes fc-float-in {
  from { transform: translateY(36px); opacity: 0; }
  to { transform: none; opacity: 1; }
}

@keyframes fc-drop {
  from { transform: translateY(-520%); opacity: 0; }
  20% { opacity: 1; }
  to { transform: none; opacity: 1; }
}

@keyframes fc-tilt-in {
  from { transform: translateY(70px) rotate(-6deg) scale(0.9); opacity: 0; }
  to { transform: none; opacity: 1; }
}

/* Motion: scrolling. Browsers without scroll timelines show everything in place. */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .fc-head h2 {
      animation: fc-pop linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 100%;
    }

    .fc-cards li,
    .fc-phones figure {
      animation: fc-tilt-in linear both;
      animation-timeline: view();
      animation-range: entry calc(var(--i) * 10%) entry 100%;
    }

    .fc-boosters li,
    .fc-friends li,
    .fc-route li {
      animation: fc-pop linear both;
      animation-timeline: view();
      animation-range: entry calc(var(--i) * 6%) entry 100%;
    }

    /* Homepage: the board fills as it comes into view. */
    .fc-home .fc-cell img {
      animation: fc-drop linear both;
      animation-timeline: view();
      animation-range: entry calc(8% + var(--c) * 3% + (3 - var(--r)) * 5%) entry 100%;
    }

    .fc-home-copy > * {
      animation: fc-float-in linear both;
      animation-timeline: view();
      animation-range: entry 5% entry 100%;
    }
  }
}

/* Layout */
@media (max-width: 1024px) {
  .fc-hero-grid,
  .fc-home,
  .fc-split {
    grid-template-columns: 1fr;
  }

  .fc-hero .fc-board {
    justify-self: start;
  }

  .fc-boosters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .fc-friends {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    row-gap: 28px;
  }
}

@media (max-width: 720px) {
  .fc-cards {
    grid-template-columns: 1fr;
  }

  .fc-phones {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
  }

  .fc-phones a {
    border-width: 5px;
    border-radius: 20px;
  }

  .fc-phones img {
    border-radius: 14px;
  }

  .fc-phones figcaption {
    font-size: 14px;
  }

  .fc-route {
    grid-template-columns: 1fr;
    justify-items: start;
    text-align: left;
  }

  .fc-route::before {
    top: 10%;
    bottom: 10%;
    left: 33px;
    right: auto;
    border-top: 0;
    border-left: 6px dotted rgba(255, 255, 255, 0.6);
  }

  .fc-route li {
    grid-template-columns: 72px 1fr;
    align-items: center;
    justify-items: start;
    gap: 16px;
  }

  .fc-stats li {
    width: 96px;
    height: 96px;
  }

  .fc-stats strong {
    font-size: 25px;
  }

  .fc-mascot {
    top: 2%;
    right: 4%;
  }
}
