@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@500;600;700&family=Orbitron:wght@600;700;800&family=Share+Tech+Mono&display=swap');

@view-transition {
  navigation: auto;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 0.32s;
  animation-timing-function: ease-in-out;
}

::view-transition-old(root) {
  animation-name: ysl-page-out;
}

::view-transition-new(root) {
  animation-name: ysl-page-in;
}

@keyframes ysl-page-out {
  from { opacity: 1; }
  to { opacity: 0; }
}

@keyframes ysl-page-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@property --beam-angle {
  syntax: '<angle>';
  inherits: false;
  initial-value: 0deg;
}

:root {
  --bg: #060607;
  --bg-alt: #0a0a0b;
  --panel: #0c0c0d;
  --border: #221a1c;
  --red: #ff3049;
  --red-dim: #7a1e28;
  --blue: #3d6f9e;
  --text: #eae7e7;
  --text-dim: #8c8687;
  --font-head: 'Rajdhani', 'Segoe UI', sans-serif;
  --font-display: 'Orbitron', 'Rajdhani', sans-serif;
  --font-mono: 'Share Tech Mono', 'Consolas', monospace;
}

* {
  box-sizing: border-box;
}

html {
  scrollbar-gutter: stable;
  font-size: clamp(14px, 12px + 0.35vw, 18px);
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-head);
  font-size: 1rem;
  line-height: 1.6;
  position: relative;
  overflow-x: hidden;
}

body.home {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

body.home main {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

body.home .hero {
  padding: 40px 24px;
}

.grid-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(rgba(255, 48, 73, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 48, 73, 0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at top, rgba(0,0,0,0.9), transparent 75%);
}

a {
  color: var(--red);
  text-decoration: none;
}

/* Side decoration */

.side-deco {
  position: fixed;
  top: 0;
  bottom: 0;
  width: clamp(56px, 7.5vw, 130px);
  z-index: 0;
  pointer-events: none;
  display: flex;
  align-items: stretch;
  justify-content: center;
  overflow: visible;
}

.side-deco-left {
  left: 0;
}

.side-deco-right {
  right: 0;
}

.deco-grid {
  display: grid;
  grid-template-columns: repeat(4, clamp(9px, 1.1vw, 18px));
  grid-auto-rows: clamp(9px, 1.1vw, 18px);
  column-gap: clamp(4px, 0.55vw, 9px);
  row-gap: clamp(4px, 0.55vw, 9px);
  align-content: start;
}

.deco-tile {
  display: block;
  background: var(--panel);
  border: 1px solid var(--border);
  animation: tile-shift 5s ease-in-out infinite;
  pointer-events: auto;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.deco-tile:hover {
  animation-play-state: paused;
  background: var(--red) !important;
  border-color: var(--red) !important;
  box-shadow: 0 0 10px rgba(255, 48, 73, 0.85), 0 0 22px rgba(255, 48, 73, 0.5);
}

.side-deco-right .deco-tile {
  animation-name: tile-shift-right;
}

.deco-tile:nth-child(5n) {
  background: var(--red-dim);
  border-color: var(--red-dim);
}

.deco-tile:nth-child(7n) {
  background: var(--red);
  border-color: var(--red);
  box-shadow: 0 0 6px rgba(255, 48, 73, 0.5);
}

.deco-tile:nth-child(4n + 1) { animation-delay: 0s; }
.deco-tile:nth-child(4n + 2) { animation-delay: 0.7s; }
.deco-tile:nth-child(4n + 3) { animation-delay: 1.4s; }
.deco-tile:nth-child(4n + 4) { animation-delay: 2.1s; }

/* Right panel's grid columns run the same left-to-right order as the left
   panel, so column 1 is the innermost column there, not the outermost.
   Mirror the delay assignment so both panels wave outward-to-inward. */
.side-deco-right .deco-tile:nth-child(4n + 1) { animation-delay: 2.1s; }
.side-deco-right .deco-tile:nth-child(4n + 2) { animation-delay: 1.4s; }
.side-deco-right .deco-tile:nth-child(4n + 3) { animation-delay: 0.7s; }
.side-deco-right .deco-tile:nth-child(4n + 4) { animation-delay: 0s; }
.deco-tile:nth-child(3n) { animation-duration: 6.5s; }

@keyframes tile-shift {
  0%, 100% { opacity: 0.3; transform: translateY(0) scale(0.88); }
  50% { opacity: 1; transform: translateY(-6px) scale(1); }
}

@keyframes tile-shift-right {
  0%, 100% { opacity: 0.3; transform: translateY(0) scale(0.88); }
  50% { opacity: 1; transform: translateY(6px) scale(1); }
}

.deco-tile:active {
  transform: scale(0.86);
}

/* Tile-click shockwave */

.shockwave-ring {
  position: fixed;
  left: 0;
  top: 0;
  width: var(--sw-size, 18px);
  height: var(--sw-size, 18px);
  border-radius: 0;
  background: transparent;
  pointer-events: none;
  z-index: 9998;
  border: 2px solid rgba(255, 48, 73, 0.85);
  transform: translate(-50%, -50%) scale(1);
  opacity: 0.9;
  animation: ysl-shockwave-ring 6.5s ease-out forwards;
}

@keyframes ysl-shockwave-ring {
  0% { transform: translate(-50%, -50%) scale(1); opacity: 0.9; }
  100% { transform: translate(-50%, -50%) scale(var(--sw-scale, 14)); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .shockwave-ring {
    animation: ysl-shockwave-ring-reduced 0.4s ease-out forwards;
  }

  @keyframes ysl-shockwave-ring-reduced {
    0% { transform: translate(-50%, -50%) scale(1); opacity: 0.9; }
    100% { transform: translate(-50%, -50%) scale(2.5); opacity: 0; }
  }
}

@media (max-width: 480px) {
  .side-deco {
    display: none;
  }
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 40px;
  background: rgba(10, 12, 16, 0.85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.logo {
  font-family: var(--font-mono);
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--text);
  view-transition-name: site-logo;
}

.logo-bracket {
  color: var(--red);
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}

.site-nav a {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
  transition: color 0.2s ease, border-color 0.2s ease;
  position: relative;
  padding-bottom: 3px;
  border-bottom: 1px solid transparent;
}

.site-nav a:hover {
  color: var(--red);
}

.site-nav a.is-active {
  color: var(--red);
  border-bottom-color: var(--red);
}

/* Hero */

.hero {
  position: relative;
  z-index: 1;
  min-width: 0;
  max-width: 100%;
  text-align: center;
  padding: clamp(46px, 8vw, 85px) 24px clamp(38px, 6vw, 68px);
  background: var(--bg);
}

.title-frame {
  position: relative;
  display: inline-block;
  padding: clamp(18px, 5vw, 30px) clamp(16px, 6vw, 56px);
  max-width: 100%;
}

.title-frame::before {
  content: '';
  position: absolute;
  inset: 0;
  border: 1px solid var(--border);
}

.title-frame::after {
  content: '';
  position: absolute;
  inset: 0;
  padding: 1.5px;
  background: conic-gradient(from var(--beam-angle), transparent 0deg, var(--red) 14deg, transparent 34deg, transparent 360deg);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  filter: drop-shadow(0 0 5px var(--red));
  animation: title-beam 8s linear infinite;
  pointer-events: none;
}

@keyframes title-beam {
  to { --beam-angle: 360deg; }
}

.hero h1 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.8rem, 5.4vw, 3.2rem);
  letter-spacing: 0.05em;
  color: var(--text);
  animation: title-pulse 2.6s ease-in-out infinite;
}

@keyframes title-pulse {
  0%, 100% { text-shadow: 0 0 6px rgba(255, 48, 73, 0.15); }
  50% { text-shadow: 0 0 16px rgba(255, 48, 73, 0.55), 0 0 2px rgba(255, 48, 73, 0.8); }
}

.glitch {
  position: relative;
  display: inline-block;
}

.glitch::before,
.glitch::after {
  content: attr(data-text);
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  overflow: hidden;
  opacity: 0.6;
}

.glitch::before {
  color: var(--red);
  clip-path: inset(0 0 55% 0);
  transform: translate(-2px, -1px);
  animation: glitch-a 5s infinite linear;
}

.glitch::after {
  color: var(--blue);
  opacity: 0.4;
  clip-path: inset(55% 0 0 0);
  transform: translate(2px, 1px);
  animation: glitch-b 5s infinite linear;
}

@keyframes glitch-a {
  0%, 94%, 100% { transform: translate(-2px, -1px); }
  95% { transform: translate(2px, -1px); }
  97% { transform: translate(-2px, 1px); }
}

@keyframes glitch-b {
  0%, 94%, 100% { transform: translate(2px, 1px); }
  96% { transform: translate(-2px, 1px); }
  98% { transform: translate(2px, -1px); }
}

.hero-sub {
  margin-top: 18px;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  color: var(--text-dim);
}

.hero-sub-page {
  padding-bottom: 45px;
}

.hero-links {
  margin-top: 34px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

.hero-btn {
  display: inline-block;
  background: transparent;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 12px 26px;
  border-radius: 6px;
  border: 1px solid var(--border);
  color: var(--text-dim);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease,
              transform 0.15s ease, box-shadow 0.2s ease;
}

.hero-btn:hover {
  border-color: var(--red);
  background: var(--red);
  color: var(--bg);
  transform: translateY(-2px) scale(1.04);
  box-shadow: 0 0 16px rgba(255, 48, 73, 0.5);
}

.hero-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
}

.hero-btn-primary {
  border-color: var(--red);
  color: var(--red);
}

.hero-btn-primary:hover {
  background: var(--red);
  color: var(--bg);
}

/* Content sections (homepage) */

.content-section {
  margin-bottom: 64px;
  scroll-margin-top: 90px;
}

/* Page layout with a LineSidebar-style in-page nav (About/Admission/Rules) —
   ported from the React Bits LineSidebar component to plain JS + CSS. */

.page-with-sidebar {
  position: relative;
}

.page-sidebar-col {
  position: fixed;
  top: 380px;
  white-space: nowrap;
  z-index: 1;
}

.page-content-col {
  width: 100%;
}

.page-section {
  scroll-margin-top: 100px;
}

.page-section + .page-section {
  margin-top: 76px;
}

@media (max-width: 1340px) {
  .page-sidebar-col {
    display: none;
  }
}

@media (max-width: 760px) {
  .page-with-sidebar {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .page-sidebar-col {
    display: flex;
    position: static;
  }

  .line-sidebar--markers {
    padding-left: 0;
  }

  .line-sidebar__marker,
  .line-sidebar--markers .line-sidebar__item:not(:last-child)::after {
    display: none;
  }

  .line-sidebar__list {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px 22px;
    padding: 0 0 20px;
  }
}

.line-sidebar {
  --accent-color: var(--red);
  --text-color: var(--text);
  --marker-color: var(--text);
  --marker-length: 46px;
  --marker-gap: 14px;
  --tick-scale: 0.5;
  --max-shift: 18px;
  --item-gap: 28px;
  --font-size: 1.12rem;
  --smoothing: 80ms;

  position: relative;
  display: flex;
  justify-content: flex-start;
}

.line-sidebar--markers {
  padding-left: calc(var(--marker-length) + var(--marker-gap));
}

.line-sidebar__list {
  list-style: none;
  margin: 0;
  padding: 1rem 0;
  display: flex;
  flex-direction: column;
  gap: var(--item-gap);
}

.line-sidebar__item {
  position: relative;
  cursor: pointer;
}

.line-sidebar__item::before {
  content: '';
  position: absolute;
  inset: -6px -24px;
}

.line-sidebar__label {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  font-family: var(--font-mono);
  font-size: var(--font-size);
  line-height: 1.2;
  color: color-mix(in srgb, var(--accent-color) calc(var(--effect, 0) * 100%), var(--text-color));
  text-shadow: 0 0 calc(var(--effect, 0) * 12px) color-mix(in srgb, var(--accent-color) calc(var(--effect, 0) * 100%), transparent);
  transform: translateX(calc(var(--effect, 0) * var(--max-shift)));
}

.line-sidebar__index {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  margin-right: 0.6rem;
  font-size: 0.85em;
  opacity: calc(0.55 + var(--effect, 0) * 0.45);
}

.line-sidebar__marker {
  position: absolute;
  top: 50%;
  left: calc(-1 * var(--marker-length) - var(--marker-gap));
  height: 1px;
  width: var(--marker-length);
  background-color: color-mix(in srgb, var(--accent-color) calc(var(--effect, 0) * 100%), var(--marker-color));
  box-shadow: 0 0 calc(var(--effect, 0) * 10px) color-mix(in srgb, var(--accent-color) calc(var(--effect, 0) * 100%), transparent);
  transform-origin: left center;
  transform: translateY(-50%) scaleX(calc(0.7 + var(--effect, 0) * 0.5));
}

.line-sidebar--markers .line-sidebar__item:not(:last-child)::after {
  content: '';
  position: absolute;
  top: calc(100% + var(--item-gap) / 2);
  left: calc(-1 * var(--marker-length) - var(--marker-gap));
  height: 1px;
  width: calc(var(--marker-length) * var(--tick-scale));
  background-color: color-mix(in srgb, var(--accent-color) calc(var(--effect, 0) * 100%), var(--marker-color));
  box-shadow: 0 0 calc(var(--effect, 0) * 8px) color-mix(in srgb, var(--accent-color) calc(var(--effect, 0) * 100%), transparent);
  opacity: calc(0.5 + var(--effect, 0) * 0.5);
  transform: translateY(-50%);
}

.line-sidebar--scale-tick .line-sidebar__item:not(:last-child)::after {
  transform-origin: left center;
  transform: translateY(-50%) scaleX(calc(0.7 + var(--effect, 0) * 0.6));
}

.line-sidebar__item[aria-current="true"] .line-sidebar__marker {
  background-color: var(--accent-color);
  transform: translateY(-50%) scaleX(1);
}

@media (prefers-reduced-motion: reduce) {
  .line-sidebar__label,
  .line-sidebar__marker {
    transition: none;
  }
}

.content-section h2 {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 1.4rem;
  letter-spacing: 0.04em;
  color: var(--text);
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 14px;
}

.content-block {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 24px 26px;
  color: var(--text-dim);
}

.content-block p {
  margin: 0 0 14px;
}

.content-block p:last-child {
  margin-bottom: 0;
}

/* Oath */

.oath-block {
  background: var(--panel);
  border: 1px solid var(--border);
  border-left: 3px solid var(--red-dim);
  border-radius: 6px;
  padding: 26px 30px;
  margin-top: 22px;
}

.section-subhead {
  margin: 0 0 16px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--red);
}

.oath-intro {
  color: var(--text-dim);
  font-style: italic;
  margin: 0 0 18px;
}

.oath-list {
  margin: 0;
  padding-left: 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.oath-list li {
  color: var(--text);
  font-size: 1rem;
}

.oath-list li::marker {
  color: var(--red);
  font-family: var(--font-mono);
}

/* Timeline */

.timeline {
  position: relative;
  padding-left: 30px;
  border-left: 2px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.timeline--pending {
  margin-top: 32px;
  border-left-color: transparent;
}

.timeline--pending::before {
  content: '';
  position: absolute;
  left: -2px;
  top: var(--connector-top, -102px);
  height: var(--connector-height, 120px);
  width: 2px;
  background-image:
    linear-gradient(var(--red), var(--red)),
    linear-gradient(var(--red), var(--red)),
    repeating-linear-gradient(to bottom, var(--red) 0 6px, transparent 6px 14px);
  background-repeat: no-repeat, no-repeat, repeat-y;
  background-size: 2px 10px, 2px 14px, 2px 28px;
  background-position: top, bottom, 0 0;
  animation: timeline-dash-flow 0.8s linear infinite;
}

@keyframes timeline-dash-flow {
  from { background-position: top, bottom, 0 0; }
  to { background-position: top, bottom, 0 28px; }
}

.timeline-item {
  position: relative;
}

.timeline-dot {
  position: absolute;
  left: -37px;
  top: 4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--red);
  box-shadow: 0 0 6px rgba(255, 48, 73, 0.6);
}

.timeline-date {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 6px;
}

.timeline-item h3 {
  margin: 0 0 8px;
  font-size: 1.1rem;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}

.timeline-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  line-height: 1;
  filter: grayscale(0.15);
}

.timeline-item p {
  margin: 0;
  color: var(--text-dim);
  font-size: 0.95rem;
}

/* Rules list */

.rules-list {
  margin: 0 0 16px;
  padding-left: 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rules-list li {
  color: var(--text-dim);
}

.rules-list li::marker {
  color: var(--red);
}

/* FAQ sections */

main {
  position: relative;
  z-index: 1;
  max-width: 860px;
  margin: 0 auto;
  padding: 0 24px clamp(60px, 8vw, 100px);
}

.faq-section {
  margin-bottom: 64px;
  scroll-margin-top: 90px;
}

.faq-section h2 {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 1.4rem;
  letter-spacing: 0.04em;
  color: var(--text);
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 14px;
}

.tag {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--bg);
  background: var(--red);
  padding: 2px 8px;
  border-radius: 2px;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.faq-item:hover {
  border-color: rgba(255, 48, 73, 0.35);
}

.faq-question {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  color: var(--text);
  font-family: var(--font-head);
  font-size: 1rem;
  font-weight: 600;
  padding: 18px 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.faq-icon {
  font-family: var(--font-mono);
  color: var(--red);
  font-size: 1.2rem;
  flex-shrink: 0;
  transition: transform 0.25s ease;
}

.faq-item.open .faq-icon {
  transform: rotate(45deg);
  color: var(--red);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  border-top: 1px solid transparent;
}

.faq-item.open .faq-answer {
  max-height: 400px;
  border-top: 1px solid var(--border);
}

.faq-answer p {
  margin: 0;
  padding: 16px 20px 20px;
  color: var(--text-dim);
  font-size: 0.95rem;
}

.faq-answer strong {
  color: var(--text);
}

.section-note {
  color: var(--text-dim);
  font-size: 0.9rem;
  margin: -6px 0 20px;
}

.hero-btn + .section-note {
  margin-top: 16px;
}

.fish-controls-row + .section-note {
  margin-top: 18px;
}

/* Footer */

.site-footer {
  position: relative;
  z-index: 1;
  max-width: 860px;
  margin: 0 auto;
  text-align: center;
  padding: 30px 24px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-dim);
}

/* Loader */

body.loading-lock {
  overflow: hidden;
}

.loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 26px;
  cursor: pointer;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.loader.loader-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-emblem {
  position: relative;
  width: 150px;
  height: 150px;
}

.loader-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px dashed var(--border);
}

.loader-ring-spin {
  border: none;
  background: conic-gradient(from 0deg, transparent 0%, var(--red) 8%, transparent 22%, transparent 100%);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 2px), #000 calc(100% - 2px));
  mask: radial-gradient(farthest-side, transparent calc(100% - 2px), #000 calc(100% - 2px));
  filter: drop-shadow(0 0 6px var(--red));
  animation: loader-ring-spin 1.6s linear infinite;
}

@keyframes loader-ring-spin {
  to { transform: rotate(360deg); }
}

.frame-edge {
  position: absolute;
  background: var(--red);
}

.frame-top,
.frame-bottom {
  left: 15px;
  right: 15px;
  height: 3px;
}

.frame-top {
  top: 15px;
  transform: translateY(-70px) scaleX(0.3);
  animation: frame-in-y 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) 0.1s forwards;
}

.frame-bottom {
  bottom: 15px;
  transform: translateY(70px) scaleX(0.3);
  animation: frame-in-y 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) 0.25s forwards;
}

.frame-left,
.frame-right {
  top: 15px;
  bottom: 15px;
  width: 3px;
}

.frame-left {
  left: 15px;
  transform: translateX(-70px) scaleY(0.3);
  animation: frame-in-x 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) 0.4s forwards;
}

.frame-right {
  right: 15px;
  transform: translateX(70px) scaleY(0.3);
  animation: frame-in-x 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) 0.55s forwards;
}

@keyframes frame-in-y {
  to { transform: translateY(0) scaleX(1); }
}

@keyframes frame-in-x {
  to { transform: translateX(0) scaleY(1); }
}

.frame-corner {
  position: absolute;
  width: 16px;
  height: 16px;
  opacity: 0;
  transform: scale(0.4);
  border-color: var(--red);
  animation: corner-in 0.4s ease-out 0.85s forwards;
}

.corner-tl { top: 5px; left: 5px; border-top: 2px solid; border-left: 2px solid; }
.corner-tr { top: 5px; right: 5px; border-top: 2px solid; border-right: 2px solid; }
.corner-bl { bottom: 5px; left: 5px; border-bottom: 2px solid; border-left: 2px solid; }
.corner-br { bottom: 5px; right: 5px; border-bottom: 2px solid; border-right: 2px solid; }

@keyframes corner-in {
  to { opacity: 1; transform: scale(1); }
}

.loader-core {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 22px;
  height: 22px;
  margin: -11px;
  background: var(--red);
  opacity: 0;
  transform: translate(0, 0) rotate(45deg) scale(0);
  box-shadow: 0 0 16px rgba(255, 48, 73, 0.7);
  animation: core-in 0.5s ease-out 1.05s forwards, core-pulse 1.8s ease-in-out 1.6s infinite;
}

@keyframes core-in {
  to { opacity: 1; transform: translate(0, 0) rotate(45deg) scale(1); }
}

@keyframes core-pulse {
  0%, 100% { box-shadow: 0 0 10px rgba(255, 48, 73, 0.5); }
  50% { box-shadow: 0 0 22px rgba(255, 48, 73, 0.9); }
}

.loader-status {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin: 0;
}

.loader-bar {
  width: 220px;
  height: 3px;
  background: var(--border);
  overflow: hidden;
}

.loader-bar-fill {
  height: 100%;
  width: 0%;
  background: var(--red);
  box-shadow: 0 0 8px rgba(255, 48, 73, 0.6);
}

.loader-percent {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  color: var(--red);
  margin: 0;
}

/* Scroll reveal */

.reveal {
  position: relative;
  opacity: 0.4;
  transform: translateY(18px) scale(0.98);
  filter: blur(3px);
  transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              filter 0.3s ease-out;
}

.reveal::before {
  content: '';
  position: absolute;
  inset: -6px;
  border: 2px solid var(--red);
  box-shadow: 0 0 10px rgba(255, 48, 73, 0.35);
  opacity: 0;
  pointer-events: none;
}

.reveal.reveal-active {
  opacity: 1;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

.reveal.reveal-active::before {
  animation: lock-flash 0.45s ease-out forwards;
}

@keyframes lock-flash {
  0% { opacity: 0.5; inset: -10px; }
  40% { opacity: 0.45; inset: -6px; }
  100% { opacity: 0; inset: -6px; }
}

.reveal:nth-child(1) { transition-delay: 0s; }
.reveal:nth-child(2) { transition-delay: 0.04s; }
.reveal:nth-child(3) { transition-delay: 0.08s; }
.reveal:nth-child(4) { transition-delay: 0.12s; }
.reveal:nth-child(5) { transition-delay: 0.16s; }
.reveal:nth-child(n + 6) { transition-delay: 0.18s; }

/* Media grid */

.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

.media-card {
  display: block;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  text-decoration: none;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.media-card:hover {
  border-color: var(--red);
  transform: translateY(-3px);
}

.media-thumb {
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--panel), var(--red-dim));
}

.media-play {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid var(--red);
  color: var(--red);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  background: rgba(0, 0, 0, 0.45);
}

.media-info {
  padding: 14px 16px;
}

.media-info h3 {
  margin: 0 0 6px;
  font-size: 1rem;
  color: var(--text);
}

.media-info p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-dim);
}

/* Minigame */

.game-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 22px 24px;
}

.game-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}

.game-header h3 {
  margin: 0;
  font-family: var(--font-display);
  letter-spacing: 0.04em;
  color: var(--text);
}

.game-stats {
  display: flex;
  gap: 18px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-dim);
}

.game-stats strong {
  color: var(--red);
}

.game-arena {
  position: relative;
  height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-image:
    linear-gradient(rgba(255, 48, 73, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 48, 73, 0.05) 1px, transparent 1px);
  background-size: 24px 24px;
  border: 1px dashed var(--border);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 16px;
}

.game-target {
  position: absolute;
  width: 38px;
  height: 38px;
  padding: 0;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 14px rgba(255, 48, 73, 0.7);
  border: none;
  cursor: pointer;
}

.game-trail-dot {
  position: absolute;
  width: 8px;
  height: 8px;
  margin-left: -4px;
  margin-top: -4px;
  border-radius: 50%;
  background: var(--red);
  opacity: 0.6;
  pointer-events: none;
  animation: game-trail-fade 3s ease-out forwards;
}

@keyframes game-trail-fade {
  from { opacity: 0.6; transform: scale(1); }
  to { opacity: 0; transform: scale(0.35); }
}

.game-result {
  text-align: center;
  color: var(--text);
  font-family: var(--font-mono);
}

.game-result p {
  margin: 0 0 10px;
}

.game-result strong {
  color: var(--red);
  font-size: 1.6rem;
}

/* Cross-game stats banner */

.stats-banner {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.stats-banner-item {
  flex: 1 1 140px;
  min-width: 0;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stats-banner-label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.stats-banner-value {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
}

.stats-banner-value.stat-positive {
  color: #3ddc7a;
}

.stats-banner-value.stat-negative {
  color: var(--red);
}

/* Game tabs */

.game-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.game-tab {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 10px 18px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.game-tab:hover {
  border-color: var(--red);
  color: var(--red);
}

.game-tab.active {
  border-color: var(--red);
  color: var(--red);
  background: rgba(255, 48, 73, 0.08);
}

.game-panel {
  display: none;
}

.game-panel.active {
  display: block;
}

/* Casino */

.casino-subtabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.casino-subtab {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 8px 16px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.casino-subtab:hover {
  border-color: var(--red);
  color: var(--red);
}

.casino-subtab.active {
  border-color: var(--red);
  color: var(--red);
  background: rgba(255, 48, 73, 0.08);
}

.casino-subpanel {
  display: none;
}

.casino-subpanel.active {
  display: block;
}

.slots-reels {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin: 20px 0;
}

.slots-reel {
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  transition: border-color 0.2s ease;
}

.slots-reel.win-pair {
  border-color: #ffd700;
  animation: slots-glow-pair 0.9s ease-in-out infinite;
}

.slots-reel.win-jackpot {
  border-color: var(--red);
  animation: slots-glow-jackpot 0.7s ease-in-out infinite;
}

@keyframes win-flash-pulse {
  0% { box-shadow: 0 0 0 rgba(255, 215, 0, 0); }
  50% { box-shadow: 0 0 20px 6px rgba(255, 215, 0, 0.55); }
  100% { box-shadow: 0 0 0 rgba(255, 215, 0, 0); }
}

.bj-card.win-glow {
  animation: win-flash-pulse 0.7s ease-out 2;
}

@media (prefers-reduced-motion: reduce) {
  .bj-card.win-glow {
    animation: none;
    box-shadow: 0 0 16px 4px rgba(255, 215, 0, 0.6);
  }
}

@keyframes slots-glow-pair {
  0%, 100% { box-shadow: 0 0 10px 2px rgba(255, 215, 0, 0.5); }
  50% { box-shadow: 0 0 20px 6px rgba(255, 215, 0, 0.85); }
}

@keyframes slots-glow-jackpot {
  0%, 100% { box-shadow: 0 0 16px 4px rgba(255, 48, 73, 0.6), 0 0 32px 10px rgba(255, 215, 0, 0.35); transform: scale(1); }
  50% { box-shadow: 0 0 28px 10px rgba(255, 48, 73, 0.95), 0 0 48px 16px rgba(255, 215, 0, 0.6); transform: scale(1.06); }
}

@media (prefers-reduced-motion: reduce) {
  .slots-reel.win-pair,
  .slots-reel.win-jackpot {
    animation: none;
    box-shadow: 0 0 14px 4px rgba(255, 215, 0, 0.7);
  }
}

.mines-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  max-width: 320px;
  margin: 20px auto;
}

.mines-cell {
  aspect-ratio: 1;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--panel);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mines-cell:hover:not(.is-safe):not(.is-bomb) {
  border-color: var(--red);
  background: rgba(255, 48, 73, 0.08);
}

.mines-cell.is-safe {
  border-color: var(--blue);
  background: rgba(61, 111, 158, 0.18);
  box-shadow: 0 0 10px 2px rgba(255, 215, 0, 0.5);
  cursor: default;
}

.mines-cell.is-bomb {
  border-color: var(--red);
  background: rgba(255, 48, 73, 0.25);
  cursor: default;
}

.mines-cell.is-hit {
  box-shadow: 0 0 10px 3px rgba(255, 48, 73, 0.65);
}

.mines-cell.is-bomb::after {
  content: '\1F4A3';
}

.mines-cell.is-safe::after {
  content: '\1F48E';
  font-size: 0.85rem;
}

.mines-bomb-label {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-dim);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.mines-bomb-label .bj-input {
  width: 60px;
}

/* Torture Paladin */

.stick-stage {
  position: relative;
  height: 240px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  border: 1px dashed var(--border);
  border-radius: 4px;
  background-image:
    linear-gradient(rgba(255, 48, 73, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 48, 73, 0.05) 1px, transparent 1px);
  background-size: 24px 24px;
}

#paladin-canvas {
  position: relative;
  z-index: 5;
  display: block;
  max-width: 100%;
}

.weapon-fx {
  position: absolute;
  top: 55px;
  left: 50%;
  width: 40px;
  height: 40px;
  margin-left: -20px;
  font-size: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  z-index: 2;
}

.weapon-fx.size-huge {
  font-size: 5rem;
  top: 40px;
}

.weapon-fx.dir-top {
  animation: weapon-in-top 0.55s ease-out;
}

.weapon-fx.dir-left {
  animation: weapon-in-left 0.55s ease-out;
}

.weapon-fx.dir-right {
  animation: weapon-in-right 0.55s ease-out;
}

@keyframes weapon-in-top {
  0% { opacity: 0; transform: translate(0, -170px) rotate(-25deg) scale(0.8); }
  55% { opacity: 1; transform: translate(0, 0) rotate(8deg) scale(1.1); }
  75% { opacity: 1; transform: translate(0, 0) rotate(0deg) scale(1); }
  100% { opacity: 0; transform: translate(0, 12px) rotate(0deg) scale(0.9); }
}

@keyframes weapon-in-right {
  0% { opacity: 0; transform: translate(170px, -10px) rotate(25deg) scale(0.8); }
  55% { opacity: 1; transform: translate(0, 0) rotate(-10deg) scale(1.1); }
  75% { opacity: 1; transform: translate(0, 0) rotate(0deg) scale(1); }
  100% { opacity: 0; transform: translate(-12px, 0) rotate(0deg) scale(0.9); }
}

@keyframes weapon-in-left {
  0% { opacity: 0; transform: translate(-170px, -10px) rotate(-25deg) scale(0.8); }
  55% { opacity: 1; transform: translate(0, 0) rotate(10deg) scale(1.1); }
  75% { opacity: 1; transform: translate(0, 0) rotate(0deg) scale(1); }
  100% { opacity: 0; transform: translate(12px, 0) rotate(0deg) scale(0.9); }
}

.laser-beam {
  position: absolute;
  z-index: 3;
  pointer-events: none;
}

.laser-beam.dir-top {
  top: -115px;
  left: 50%;
  width: 6px;
  height: 170px;
  margin-left: -3px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(255, 48, 73, 0.9));
  box-shadow: 0 0 14px rgba(255, 48, 73, 0.9), 0 0 28px rgba(255, 48, 73, 0.6);
  transform-origin: top center;
  animation: laser-fire-top 0.45s ease-out forwards;
}

.laser-beam.dir-right {
  top: 55px;
  right: -170px;
  width: 170px;
  height: 6px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.95), rgba(255, 48, 73, 0.9));
  box-shadow: 0 0 14px rgba(255, 48, 73, 0.9), 0 0 28px rgba(255, 48, 73, 0.6);
  transform-origin: right center;
  animation: laser-fire-right 0.45s ease-out forwards;
}

.laser-beam.dir-left {
  top: 55px;
  left: -170px;
  width: 170px;
  height: 6px;
  background: linear-gradient(270deg, rgba(255, 255, 255, 0.95), rgba(255, 48, 73, 0.9));
  box-shadow: 0 0 14px rgba(255, 48, 73, 0.9), 0 0 28px rgba(255, 48, 73, 0.6);
  transform-origin: left center;
  animation: laser-fire-left 0.45s ease-out forwards;
}

@keyframes laser-fire-top {
  0% { opacity: 0; transform: scaleY(0); }
  30% { opacity: 1; transform: scaleY(1); }
  70% { opacity: 1; transform: scaleY(1); }
  100% { opacity: 0; transform: scaleY(1); }
}

@keyframes laser-fire-right {
  0% { opacity: 0; transform: scaleX(0); }
  30% { opacity: 1; transform: scaleX(1); }
  70% { opacity: 1; transform: scaleX(1); }
  100% { opacity: 0; transform: scaleX(1); }
}

@keyframes laser-fire-left {
  0% { opacity: 0; transform: scaleX(0); }
  30% { opacity: 1; transform: scaleX(1); }
  70% { opacity: 1; transform: scaleX(1); }
  100% { opacity: 0; transform: scaleX(1); }
}

.speech-bubble {
  position: absolute;
  top: 14px;
  left: 50%;
  transform: translateX(-50%) translateY(-6px);
  background: var(--panel);
  border: 1px solid var(--red);
  border-radius: 6px;
  padding: 8px 14px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text);
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

.speech-bubble.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.tool-rack {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}

.tool-btn {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  padding: 10px 14px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text-dim);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.tool-btn:hover {
  border-color: var(--red);
  color: var(--red);
}

.tool-btn.active {
  border-color: var(--red);
  color: var(--red);
  background: rgba(255, 48, 73, 0.08);
}

/* Catch a Fish */

.dock-scene {
  position: relative;
  height: 380px;
  margin-bottom: 14px;
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg);
}

.dock-sky {
  position: absolute;
  inset: 0 0 58% 0;
  background: linear-gradient(180deg, var(--bg) 0%, var(--panel) 100%);
  overflow: hidden;
}

.dock-star {
  position: absolute;
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: var(--text);
  box-shadow: 0 0 3px 1px rgba(234, 231, 231, 0.8);
  animation: ysl-dock-twinkle 3.4s ease-in-out infinite;
}

@keyframes ysl-dock-twinkle {
  0%, 100% { opacity: 0.25; }
  50% { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .dock-star {
    animation: none;
    opacity: 0.7;
  }
}

.dock-bucket {
  position: absolute;
  left: 25%;
  top: 69px;
  width: 24px;
  height: 22px;
  z-index: 1;
}

.bucket-body {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 17px;
  background: linear-gradient(180deg, var(--panel), var(--bg-alt));
  border: 2px solid var(--red-dim);
  border-top: none;
  clip-path: polygon(12% 0, 88% 0, 100% 100%, 0% 100%);
}

.bucket-handle {
  position: absolute;
  top: -7px;
  left: 15%;
  width: 70%;
  height: 10px;
  border: 2px solid var(--red-dim);
  border-bottom: none;
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
}

.dock-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.dock-piling {
  position: absolute;
  top: 28%;
  bottom: 0;
  width: 9px;
  background: linear-gradient(90deg, var(--bg-alt), var(--panel) 40%, var(--bg-alt));
  border-left: 1px solid var(--red-dim);
  border-right: 1px solid var(--red-dim);
}

.piling-left {
  left: 9%;
}

.piling-right {
  left: 36%;
}

.dock-platform {
  position: absolute;
  top: 24%;
  left: 6%;
  right: 58%;
  height: 16px;
  background:
    repeating-linear-gradient(90deg, var(--panel) 0 18px, var(--bg-alt) 18px 20px);
  border: 2px solid var(--red-dim);
  box-shadow: 0 3px 0 var(--red-dim), 0 6px 8px rgba(0, 0, 0, 0.45);
}

.angler {
  position: absolute;
  top: 1%;
  left: 10%;
  z-index: 1;
}


.fish-status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--border);
  display: inline-block;
  margin-right: 4px;
}

.fish-status-dot.waiting {
  background: var(--red-dim);
  animation: status-pulse 1s ease-in-out infinite;
}

.fish-status-dot.biting {
  background: var(--red);
  box-shadow: 0 0 8px rgba(255, 48, 73, 0.8);
  animation: status-pulse 0.4s ease-in-out infinite;
}

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

.fish-banner {
  margin: 0 0 16px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-dim);
  text-align: center;
}

.fish-banner.is-legendary {
  color: var(--red);
  animation: fish-shimmer-text 1.2s ease-in-out infinite;
}

@keyframes fish-shimmer-text {
  0%, 100% { text-shadow: 0 0 4px rgba(255, 48, 73, 0.4); }
  50% { text-shadow: 0 0 14px rgba(255, 48, 73, 0.9); }
}

.fish-controls-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 8px;
}

.fish-code-entry {
  display: flex;
  gap: 8px;
}

.fish-upgrades {
  margin-top: 26px;
}

.titles-shop {
  margin-top: 26px;
}

.equipped-title {
  margin: 4px 0 14px;
  color: var(--text);
  font-size: 0.92rem;
}

.equipped-title strong {
  color: var(--red);
}

.upgrades-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.upgrade-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 12px 16px;
}

.upgrade-name {
  margin: 0 0 2px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text);
}

.upgrade-name .upgrade-level {
  color: var(--red);
  margin-left: 6px;
}

.upgrade-desc {
  margin: 0;
  font-size: 0.8rem;
  color: var(--text-dim);
}

.upgrade-effect {
  margin: 4px 0 0;
  font-size: 0.78rem;
  color: var(--red);
}

.fish-index {
  margin-top: 22px;
}

.fish-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(108px, 1fr));
  gap: 10px;
}

.fish-entry {
  position: relative;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 16px 8px 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.fish-entry .fish-tier {
  position: absolute;
  top: 4px;
  right: 5px;
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.03em;
  color: var(--text-dim);
}

.fish-entry .fish-icon {
  display: block;
  font-size: 1.6rem;
  margin-bottom: 4px;
}

.fish-entry .fish-name {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text);
}

.fish-entry .fish-chance {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text);
}

.fish-entry .fish-chance-delta {
  color: var(--red);
}

.fish-entry .fish-caught-count {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-dim);
}

.fish-entry.locked .fish-name {
  color: var(--text-dim);
}

.fish-entry.rarity-A:not(.locked) {
  border-color: #cd7f32;
  box-shadow: 0 0 9px rgba(205, 127, 50, 0.55);
}

.fish-entry.rarity-A:not(.locked) .fish-tier {
  color: #cd7f32;
}

.fish-entry.rarity-S:not(.locked) {
  border-color: #d9d9d9;
  box-shadow: 0 0 10px rgba(217, 217, 217, 0.6);
  animation: fish-glow-pulse 2.2s ease-in-out infinite;
}

.fish-entry.rarity-S:not(.locked) .fish-tier {
  color: #d9d9d9;
}

.fish-entry.rarity-SS:not(.locked) {
  border-color: #ffd700;
  box-shadow: 0 0 14px rgba(255, 215, 0, 0.75);
  animation: fish-glow-pulse 1.8s ease-in-out infinite;
}

.fish-entry.rarity-SS:not(.locked) .fish-tier {
  color: #ffd700;
}

.fish-entry.rarity-SSS:not(.locked) {
  border-color: #ffffff;
  animation: fish-glow-rainbow 3s linear infinite;
}

.fish-entry.rarity-SSS:not(.locked) .fish-tier {
  color: #ffffff;
  font-weight: 700;
}

.fish-entry.rarity-X:not(.locked) {
  border-color: #ffffff;
  animation: fish-glow-rainbow 1.1s linear infinite;
  transform: scale(1.03);
}

.fish-entry.rarity-X:not(.locked) .fish-tier {
  color: #ffffff;
  font-weight: 700;
}

@keyframes fish-glow-pulse {
  0%, 100% { filter: brightness(1); }
  50% { filter: brightness(1.4); }
}

@keyframes fish-glow-rainbow {
  0% { box-shadow: 0 0 14px 2px #ff3049; }
  20% { box-shadow: 0 0 14px 2px #ff9d3a; }
  40% { box-shadow: 0 0 14px 2px #f4e04d; }
  60% { box-shadow: 0 0 14px 2px #52e07a; }
  80% { box-shadow: 0 0 14px 2px #4aa8ff; }
  100% { box-shadow: 0 0 14px 2px #ff3049; }
}

/* Blackjack */

.bj-table {
  display: flex;
  flex-direction: column;
  gap: 22px;
  margin-bottom: 16px;
}

.bj-label {
  margin: 0 0 8px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-dim);
}

.bj-label span {
  color: var(--red);
}

.bj-hand {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 84px;
}

.bj-card {
  width: 54px;
  height: 78px;
  border-radius: 6px;
  background: #f2efe9;
  color: #1a1a1a;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.05rem;
  border: 1px solid rgba(0, 0, 0, 0.15);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.5);
  animation: bj-card-deal 0.25s ease-out;
}

.bj-card.is-red {
  color: #b3122a;
}

.bj-card-back {
  background: repeating-linear-gradient(45deg, var(--red-dim) 0 6px, var(--panel) 6px 12px);
  border: 1px solid var(--red);
}

@keyframes bj-card-deal {
  from { transform: translateY(-18px) scale(0.9); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}

.bj-bet-controls,
.bj-action-controls,
.bj-beg-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
  align-items: center;
}

.bj-input {
  width: 100px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  padding: 10px 12px;
}

.bj-input:focus {
  outline: none;
  border-color: var(--red);
}

.is-hidden {
  display: none;
}

/* Dino Run */

.dino-map-select {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}

.dino-arena {
  position: relative;
  height: 380px;
  margin-bottom: 14px;
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg);
}

.dino-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.dino-overlay-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  white-space: nowrap;
}

.hero-btn.dino-overlay-btn:hover {
  transform: translate(-50%, -50%) translateY(-2px) scale(1.04);
}

.powerup-legend {
  margin-top: 22px;
}

.powerup-legend-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}

.powerup-legend-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 12px 14px;
}

.powerup-swatch {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  line-height: 1;
}

/* Notable members */

.members-section {
  margin-bottom: 44px;
}

.members-section:last-child {
  margin-bottom: 0;
}

.members-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}

.member-card {
  position: relative;
  z-index: 0;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 24px 20px;
  text-align: center;
}

/* Electric border effect (Founders cards) — ported from the React Bits
   ElectricBorder component to plain canvas + CSS, no framework required. */

.electric-border {
  --electric-border-color: var(--red);
  --electric-light-color: oklch(from var(--electric-border-color) l c h);
  isolation: isolate;
}

.eb-canvas-container {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 2;
}

.eb-canvas {
  display: block;
}

.eb-content {
  position: relative;
  border-radius: inherit;
  z-index: 1;
}

.eb-layers {
  display: none;
}

.member-card:hover {
  z-index: 10;
}

.member-avatar {
  width: 60px;
  height: 60px;
  margin: 0 auto 14px;
  border-radius: 50%;
  border: 2px solid var(--red);
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.2rem;
  letter-spacing: 0.04em;
  color: var(--red);
}

.member-card h3 {
  margin: 0 0 4px;
  font-size: 1.05rem;
  color: var(--text);
}

.member-card p:last-child {
  margin: 0;
  color: var(--text-dim);
  font-size: 0.9rem;
}

.member-discord,
.member-color {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-dim);
  margin: 0 0 4px;
}

.member-roles {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
}

.role-chip {
  position: relative;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 8px;
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-dim);
  background: var(--bg);
  cursor: default;
}

.role-chip[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  width: max-content;
  max-width: 200px;
  text-align: left;
  text-transform: none;
  letter-spacing: normal;
  background: var(--panel);
  border: 1px solid var(--red-dim);
  color: var(--text);
  font-size: 0.72rem;
  line-height: 1.4;
  padding: 7px 10px;
  border-radius: 4px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s ease, transform 0.15s ease;
  z-index: 5;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.role-chip[data-tooltip]:hover::after,
.role-chip[data-tooltip].tooltip-active::after {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .role-chip[data-tooltip]::after {
    transition: none;
  }
}

/* Custom cursor */

.custom-cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 11px;
  height: 11px;
  margin-top: -5.5px;
  margin-left: -5.5px;
  pointer-events: none;
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.2s ease;
  will-change: transform;
}

.custom-cursor.is-visible {
  opacity: 1;
}

.custom-cursor::before,
.custom-cursor::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.custom-cursor::before {
  inset: 0;
  background: var(--red);
}

.custom-cursor::after {
  inset: 1.5px;
  background: var(--bg);
}

.custom-cursor.is-hover::before,
.custom-cursor.is-hover::after {
  transform: scale(1.3);
}

.custom-cursor.is-hover::after {
  opacity: 0;
}

body.custom-cursor-active,
body.custom-cursor-active * {
  cursor: none !important;
}

/* Responsive */

@media (max-width: 700px) {
  .site-header {
    flex-direction: column;
    gap: 14px;
    padding: 16px 20px;
  }

  .site-nav {
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px 20px;
  }

  .hero {
    padding: 80px 20px 60px;
  }
}
