:root {
  --bwf-navy-deep: #040d18;
  --bwf-navy: #061828;
  --bwf-blue: #0c2844;
  --bwf-blue-light: #1a4a72;
  --bwf-sky: #4a9fd4;
  --bwf-sky-glow: rgba(74, 159, 212, 0.35);
  --bwf-gold: #f4cb52;
  --bwf-gold-dark: #d4a82e;
  --bwf-pink: #f6395f;
  --bwf-pink-glow: rgba(246, 57, 95, 0.25);

  --surface: rgba(12, 28, 48, 0.72);
  --surface-hover: rgba(255, 255, 255, 0.08);
  --border: rgba(255, 255, 255, 0.09);
  --border-focus: rgba(74, 159, 212, 0.45);
  --text: #eef4fb;
  --muted: #9bb8d4;
  --shadow: 0 24px 64px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  --shadow-glow: 0 0 48px rgba(74, 159, 212, 0.18);

  --font-sans: "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "Cascadia Code", ui-monospace, monospace;

  --radius-xl: 22px;
  --radius-lg: 16px;
  --radius-md: 12px;

  --success-bg: rgba(34, 197, 94, 0.15);
  --success-text: #86efac;
  --error-bg: rgba(239, 68, 68, 0.15);
  --error-text: #fca5a5;
  --warning: #f4cb52;

  --gradient-primary: linear-gradient(135deg, var(--bwf-gold) 0%, #f0b429 45%, var(--bwf-sky) 100%);
  --gradient-primary-hover: linear-gradient(135deg, #ffe082 0%, var(--bwf-gold) 45%, #6bb8e8 100%);
  --gradient-accent-text: linear-gradient(120deg, var(--bwf-sky) 0%, #a8daf5 40%, var(--bwf-gold) 100%);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html, body {
  margin: 0;
  min-height: 100vh;
}

body {
  font-family: var(--font-sans);
  color: var(--text);
  background-color: var(--bwf-navy-deep);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Animated ambient background */
.ambient-glow {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  animation: float-glow 14s ease-in-out infinite;
}

.glow-1 {
  width: 560px;
  height: 560px;
  top: -200px;
  left: calc(50% - 280px);
  background: radial-gradient(circle, rgba(74, 159, 212, 0.22) 0%, transparent 70%);
}

.glow-2 {
  width: 480px;
  height: 380px;
  top: 40%;
  right: -140px;
  background: radial-gradient(circle, rgba(246, 57, 95, 0.14) 0%, transparent 70%);
  animation-delay: -5s;
}

.glow-3 {
  width: 420px;
  height: 420px;
  bottom: -120px;
  left: -100px;
  background: radial-gradient(circle, rgba(244, 203, 82, 0.1) 0%, transparent 70%);
  animation-delay: -9s;
}

@keyframes float-glow {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 1; }
  33% { transform: translate(24px, -18px) scale(1.06); opacity: 0.88; }
  66% { transform: translate(-18px, 14px) scale(0.94); opacity: 1; }
}

.bg-grid {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 75% 65% at 50% 25%, black 15%, transparent 78%);
}

.bg-gradient {
  display: none;
}

.site-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 2rem;
  max-width: 960px;
  margin: 0 auto;
  gap: 1rem;
}

.header-end {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.version-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: #b8daf0;
  background: rgba(74, 159, 212, 0.12);
  border: 1px solid rgba(74, 159, 212, 0.28);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  white-space: nowrap;
}

.version-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 10px rgba(74, 222, 128, 0.8);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.55; transform: scale(0.85); }
}

.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.logo {
  height: 48px;
  width: auto;
  position: relative;
  z-index: 2;
}

/* Swimming fish logo */
.fish-brand {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.85rem 0.35rem 0.45rem;
  border-radius: 999px;
  background: linear-gradient(
    180deg,
    rgba(74, 159, 212, 0.1) 0%,
    rgba(6, 24, 40, 0.25) 100%
  );
  border: 1px solid rgba(74, 159, 212, 0.18);
  overflow: visible;
  transition: border-color 0.35s, box-shadow 0.35s, background 0.35s;
}

.fish-brand::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(
    105deg,
    transparent 30%,
    rgba(255, 255, 255, 0.12) 50%,
    transparent 70%
  );
  background-size: 220% 100%;
  animation: water-shimmer 4s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}

.fish-brand:hover {
  border-color: rgba(74, 159, 212, 0.45);
  box-shadow: 0 0 28px rgba(74, 159, 212, 0.25), inset 0 0 20px rgba(74, 159, 212, 0.06);
}

.fish-brand:hover .fish-logo {
  animation-duration: 2.2s;
}

.fish-brand:hover .fish-bubble {
  animation-duration: 1.6s;
}

.fish-brand--footer {
  padding: 0.15rem 0.55rem 0.15rem 0.25rem;
  vertical-align: middle;
  margin-right: 0.15rem;
}

.fish-scene {
  position: absolute;
  inset: -6px -10px -6px -4px;
  pointer-events: none;
  z-index: 0;
  overflow: visible;
}

.fish-scene--sm {
  inset: -4px -6px -4px -2px;
}

.fish-wave {
  position: absolute;
  bottom: 2px;
  left: 0;
  right: 0;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(74, 159, 212, 0.5),
    rgba(244, 203, 82, 0.35),
    transparent
  );
  opacity: 0.5;
  animation: fish-wave-drift 3s ease-in-out infinite;
}

.fish-wave--2 {
  bottom: 6px;
  opacity: 0.3;
  animation-delay: -1.5s;
  animation-duration: 4s;
}

.fish-bubble {
  position: absolute;
  bottom: 4px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: radial-gradient(
    circle at 30% 30%,
    rgba(255, 255, 255, 0.55),
    rgba(74, 159, 212, 0.25)
  );
  border: 1px solid rgba(255, 255, 255, 0.2);
  animation: bubble-rise 2.8s ease-in infinite;
  opacity: 0;
}

.fish-bubble:nth-child(3) { left: 18%; animation-delay: 0s; width: 4px; height: 4px; }
.fish-bubble:nth-child(4) { left: 42%; animation-delay: 0.7s; width: 6px; height: 6px; }
.fish-bubble:nth-child(5) { left: 68%; animation-delay: 1.4s; width: 3px; height: 3px; }
.fish-bubble:nth-child(6) { left: 85%; animation-delay: 2.1s; width: 5px; height: 5px; }

.fish-scene--sm .fish-bubble:nth-child(1) { left: 25%; animation-delay: 0.2s; }
.fish-scene--sm .fish-bubble:nth-child(2) { left: 70%; animation-delay: 1.1s; width: 4px; height: 4px; }

.fish-logo {
  animation: fish-swim 4.5s ease-in-out infinite;
  transform-origin: 35% 50%;
  filter: drop-shadow(0 3px 10px rgba(74, 159, 212, 0.35));
  transition: filter 0.35s;
}

.fish-brand:hover .fish-logo {
  filter: drop-shadow(0 6px 18px rgba(74, 159, 212, 0.55))
          drop-shadow(0 0 12px rgba(244, 203, 82, 0.25));
}

.footer-logo.fish-logo {
  height: 22px;
  animation-duration: 5.5s;
}

@keyframes fish-swim {
  0%, 100% {
    transform: translateX(0) translateY(0) rotate(0deg) scale(1);
  }
  15% {
    transform: translateX(5px) translateY(-2px) rotate(2deg) scale(1.02);
  }
  30% {
    transform: translateX(8px) translateY(0) rotate(1deg) scale(1);
  }
  45% {
    transform: translateX(3px) translateY(2px) rotate(-1deg) scale(0.98);
  }
  60% {
    transform: translateX(-4px) translateY(0) rotate(-2deg) scale(1);
  }
  75% {
    transform: translateX(-7px) translateY(-1px) rotate(-1deg) scale(1.01);
  }
  90% {
    transform: translateX(-2px) translateY(1px) rotate(1deg) scale(0.99);
  }
}

@keyframes bubble-rise {
  0% {
    opacity: 0;
    transform: translateY(0) scale(0.6);
  }
  15% {
    opacity: 0.85;
  }
  100% {
    opacity: 0;
    transform: translateY(-28px) scale(1.1);
  }
}

@keyframes fish-wave-drift {
  0%, 100% { transform: translateX(-8px) scaleX(0.9); opacity: 0.35; }
  50% { transform: translateX(8px) scaleX(1.05); opacity: 0.65; }
}

@keyframes water-shimmer {
  0%, 100% { background-position: 200% 0; opacity: 0.4; }
  50% { background-position: -200% 0; opacity: 0.75; }
}

/* View page */
.view-heading {
  font-size: clamp(1.25rem, 4vw, 1.65rem);
  background: linear-gradient(135deg, var(--text) 0%, var(--bwf-sky) 55%, var(--bwf-gold) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.support-contact {
  text-align: center;
  margin-top: 0.5rem;
  padding: 1.75rem 1.5rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(244, 203, 82, 0.22);
  background: linear-gradient(
    165deg,
    rgba(244, 203, 82, 0.06) 0%,
    rgba(12, 28, 48, 0.55) 100%
  );
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: border-color 0.35s, box-shadow 0.35s;
}

.support-contact:hover {
  border-color: rgba(244, 203, 82, 0.38);
  box-shadow: 0 0 32px rgba(244, 203, 82, 0.08);
}

.support-contact-text {
  max-width: 480px;
  margin: 0 auto 1rem;
  font-size: 0.95rem;
  line-height: 1.6;
}

.support-contact .btn-primary {
  margin-top: 0.25rem;
}

.container {
  position: relative;
  z-index: 1;
  max-width: 820px;
  margin: 0 auto;
  padding: 0 1.25rem 3rem;
}

.site-footer {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 2rem 1rem 2.5rem;
  color: var(--muted);
  font-size: 0.85rem;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
  font-weight: 700;
  color: var(--text);
}

.footer-logo {
  height: 22px;
  width: auto;
  opacity: 0.9;
}

.footer-note {
  margin: 0.4rem 0 0;
  font-size: 0.8rem;
  opacity: 0.75;
}

/* Entrance animations */
.animate-fade-up {
  animation: fade-up 0.75s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.18s; }
.delay-3 { animation-delay: 0.26s; }

@keyframes fade-up {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Hero banner */
.hero-banner {
  position: relative;
  text-align: center;
  margin-bottom: 1.5rem;
  padding: 2rem 1.25rem 2.25rem;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(74, 159, 212, 0.2);
  background: linear-gradient(165deg, rgba(12, 40, 68, 0.85) 0%, rgba(6, 24, 40, 0.55) 100%);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow), var(--shadow-glow);
  overflow: hidden;
}

.hero-banner-glow {
  position: absolute;
  inset: -40%;
  background: radial-gradient(circle at 50% 0%, rgba(74, 159, 212, 0.15), transparent 55%);
  pointer-events: none;
}

.hero-banner--compact {
  padding: 1.5rem 1.25rem 1.75rem;
  margin-bottom: 1.25rem;
}

.hero-banner-inner {
  position: relative;
  z-index: 1;
}

.hero-logo-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 1rem;
}

.hero-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  background: linear-gradient(145deg, var(--bwf-blue-light) 0%, var(--bwf-sky) 55%, var(--bwf-gold) 100%);
  color: white;
  box-shadow: 0 10px 36px rgba(74, 159, 212, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.35s;
}

.hero-banner:hover .hero-icon {
  transform: translateY(-3px) rotate(-2deg);
  box-shadow: 0 14px 44px rgba(74, 159, 212, 0.5);
}

.hero-title {
  margin: 0;
  font-size: clamp(1.75rem, 5vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.hero-title--sm {
  font-size: clamp(1.5rem, 4vw, 2rem);
}

.hero-title-main {
  display: block;
  color: var(--text);
}

.hero-title-accent {
  display: block;
  background: var(--gradient-accent-text);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-tagline {
  max-width: 580px;
  margin: 0.85rem auto 1.5rem;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.65;
}

.hero-banner--compact .hero-tagline {
  margin-bottom: 0;
}

.feature-pills {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.55rem;
}

.feature-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  transition: background 0.25s, border-color 0.25s, color 0.25s, transform 0.2s;
  cursor: default;
  user-select: none;
}

.feature-pill svg {
  opacity: 0.75;
  flex-shrink: 0;
}

.feature-pill:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
  color: var(--text);
  transform: translateY(-2px);
}

.feature-pill.is-pressed {
  transform: scale(0.97);
}

.feature-pill--accent {
  border-color: rgba(74, 159, 212, 0.35);
  color: #9dd4f5;
  background: rgba(74, 159, 212, 0.08);
}

.card {
  background: var(--surface);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow);
  transition: border-color 0.35s, box-shadow 0.35s, transform 0.35s;
}

.card:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.card:focus-within {
  border-color: var(--border-focus);
  box-shadow: var(--shadow), var(--shadow-glow);
}

.card.narrow {
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}

.card.center {
  text-align: center;
}

.card.hero {
  text-align: center;
  padding: 2.5rem 2rem;
}

.card.hero h1 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, var(--text), var(--bwf-sky));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.lead {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: 520px;
  margin: 0 auto 2rem;
}

.center-note {
  margin-top: 2rem;
  font-size: 0.9rem;
}

.support-notice {
  text-align: center;
  border-color: rgba(244, 203, 82, 0.35);
  background: linear-gradient(165deg, rgba(244, 203, 82, 0.06) 0%, rgba(12, 28, 48, 0.72) 100%);
}

.result-card {
  text-align: center;
  border-color: rgba(74, 222, 128, 0.3);
  background: linear-gradient(165deg, rgba(34, 197, 94, 0.08) 0%, rgba(12, 28, 48, 0.72) 100%);
  animation: result-in 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes result-in {
  from { opacity: 0; transform: scale(0.97) translateY(12px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.result-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: white;
  box-shadow: 0 8px 24px rgba(34, 197, 94, 0.35);
}

.link-box {
  border-style: solid;
  border-color: rgba(74, 159, 212, 0.25);
  background: rgba(6, 24, 40, 0.5);
  transition: border-color 0.3s, box-shadow 0.3s;
}

.link-box:hover {
  border-color: rgba(74, 159, 212, 0.45);
  box-shadow: 0 0 24px rgba(74, 159, 212, 0.12);
}

.support-badge {
  display: inline-block;
  margin: 0 0 0.75rem;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: rgba(244, 203, 82, 0.15);
  color: var(--bwf-gold);
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.02em;
}

.support-notice .muted {
  max-width: 520px;
  margin: 0 auto 1rem;
}

.support-notice .btn-primary {
  margin-top: 0.25rem;
}

.footer-note {
  margin-top: 0.35rem;
  font-size: 0.8rem;
  color: var(--muted);
  opacity: 0.85;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  text-align: left;
}

.feature {
  background: var(--surface-hover);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s, background 0.3s;
}

.interactive-card:hover {
  border-color: rgba(74, 159, 212, 0.35);
  background: rgba(74, 159, 212, 0.06);
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.25);
}

.interactive-card.is-pressed {
  transform: translateY(-1px) scale(0.99);
}

.feature-icon {
  font-size: 1.5rem;
  display: block;
  margin-bottom: 0.5rem;
}

.feature h3 {
  margin: 0 0 0.35rem;
  font-size: 0.95rem;
  color: var(--bwf-gold);
}

.feature p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
}

h1, h2 {
  margin-top: 0;
}

.muted {
  color: var(--muted);
}

.hint {
  font-size: 0.88rem;
  color: var(--muted);
}

.hint.warning {
  color: var(--warning);
}

.header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
}

.form label {
  display: block;
  margin: 1rem 0 0.35rem;
  font-weight: 600;
  font-size: 0.9rem;
}

.form input[type="text"],
.form input[type="password"],
.form input[type="file"],
.form select,
.form textarea {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(6, 24, 40, 0.6);
  color: var(--text);
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form input:focus,
.form select:focus,
.form textarea:focus {
  outline: none;
  border-color: var(--bwf-sky);
  box-shadow: 0 0 0 3px rgba(74, 159, 212, 0.25);
}

.form textarea {
  resize: vertical;
  min-height: 140px;
  font-family: var(--font-mono);
  font-size: 0.92rem;
  line-height: 1.6;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 1rem;
  cursor: pointer;
  font-weight: 600;
}

.checkbox-row input[type="checkbox"] {
  width: 1.1rem;
  height: 1.1rem;
  accent-color: var(--bwf-gold);
  cursor: pointer;
}

.inline-form {
  margin: 0;
}

.inline-form button {
  margin-top: 0;
}

.download-box {
  text-align: center;
}

.download-label {
  margin: 0 0 0.25rem;
  font-weight: 600;
  color: var(--bwf-gold);
}

.file-name {
  margin: 0 0 0.75rem;
  font-size: 0.9rem;
}

.narrow-form {
  max-width: 360px;
  margin: 0 auto;
  text-align: left;
}

.type-tabs {
  display: flex;
  gap: 0.5rem;
  margin: 1rem 0;
}

.type-tab {
  flex: 1;
  cursor: pointer;
}

.type-tab input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.type-tab span {
  display: block;
  text-align: center;
  padding: 0.65rem 1rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(6, 24, 40, 0.4);
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.2s;
}

.type-tab input:checked + span {
  background: linear-gradient(135deg, var(--bwf-blue-light), var(--bwf-sky));
  border-color: var(--bwf-sky);
  color: white;
}

.btn-primary,
.btn-secondary,
.btn-ghost,
.btn-danger,
button,
input[type="submit"],
a.btn-primary,
a.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  margin-top: 1rem;
  padding: 0.75rem 1.35rem;
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.3s cubic-bezier(0.34, 1.2, 0.64, 1), box-shadow 0.3s, background 0.3s, border-color 0.3s;
  position: relative;
  overflow: hidden;
}

.has-ripple {
  position: relative;
  overflow: hidden;
}

.ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
  transform: scale(0);
  animation: ripple-out 0.55s ease-out forwards;
  pointer-events: none;
}

@keyframes ripple-out {
  to { transform: scale(1); opacity: 0; }
}

.btn-shine::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, 0.18) 50%, transparent 65%);
  transform: translateX(-100%);
  transition: transform 0.65s;
}

.btn-shine:hover::before {
  transform: translateX(100%);
}

.btn-primary,
button[type="submit"]:not(.btn-danger):not(.btn-secondary):not(.btn-ghost) {
  background: var(--gradient-primary);
  color: var(--bwf-navy-deep);
  box-shadow: 0 10px 28px rgba(244, 203, 82, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.btn-primary:hover,
button[type="submit"]:not(.btn-danger):not(.btn-secondary):not(.btn-ghost):hover {
  background: var(--gradient-primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 14px 36px rgba(244, 203, 82, 0.45);
}

.btn-primary:active,
button[type="submit"]:not(.btn-danger):not(.btn-secondary):not(.btn-ghost):active {
  transform: translateY(0);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.18);
  transform: translateY(-1px);
}

.btn-ghost {
  margin-top: 0;
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--border);
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
}

.btn-ghost:hover {
  color: var(--text);
  border-color: var(--bwf-sky);
  background: rgba(74, 159, 212, 0.08);
  transform: translateY(-1px);
}

.btn-danger {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  color: white;
}

.btn-danger.small {
  margin-top: 0;
  padding: 0.35rem 0.7rem;
  font-size: 0.8rem;
}

.content-box {
  margin: 1.25rem 0;
  padding: 1.25rem;
  background: rgba(6, 24, 40, 0.65);
  border: 1px dashed var(--border);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  align-items: stretch;
}

.content-box.reveal .password-display {
  font-size: 1.4rem;
  letter-spacing: 0.04em;
  word-break: break-all;
}

.content-box.text-view pre {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  text-align: left;
  font-family: var(--font-mono);
  font-size: 0.92rem;
  line-height: 1.6;
  max-height: 400px;
  overflow-y: auto;
}

code {
  font-family: var(--font-mono);
}

.link-code {
  font-size: 0.78rem;
  word-break: break-all;
  color: var(--bwf-sky);
}

.badge {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: rgba(74, 159, 212, 0.2);
  color: var(--bwf-sky);
}

.alert {
  padding: 0.85rem 1rem;
  border-radius: 10px;
  margin-bottom: 1rem;
  border: 1px solid transparent;
}

.alert-success {
  background: var(--success-bg);
  color: var(--success-text);
  border-color: rgba(34, 197, 94, 0.3);
}

.alert-error {
  background: var(--error-bg);
  color: var(--error-text);
  border-color: rgba(239, 68, 68, 0.3);
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  text-align: left;
  padding: 0.7rem 0.5rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

@media (max-width: 640px) {
  .site-header {
    padding: 1rem;
    flex-wrap: wrap;
  }

  .header-end {
    width: 100%;
    justify-content: space-between;
  }

  .version-badge {
    font-size: 10px;
    padding: 5px 10px;
  }

  .fish-brand {
    padding: 0.25rem 0.55rem 0.25rem 0.35rem;
  }

  .logo {
    height: 36px;
  }

  .header-row {
    flex-direction: column;
  }

  .hero-banner {
    padding: 1.5rem 1rem 1.75rem;
  }

  .hero-title {
    font-size: 1.6rem;
  }

  .card.hero h1 {
    font-size: 1.5rem;
  }

  .code-editor-header {
    flex-wrap: wrap;
  }

  .code-editor-toolbar,
  .server-ready {
    width: 100%;
    justify-content: flex-end;
    margin-left: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .glow-orb {
    animation: none;
  }

  .fish-logo,
  .fish-bubble,
  .fish-wave,
  .fish-brand::after {
    animation: none !important;
  }
}

/* Code editor (dashboard + view) */
.code-editor-card {
  margin: 0.35rem 0 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid rgba(74, 159, 212, 0.28);
  background: #0a1018;
  box-shadow: var(--shadow);
  transition: border-color 0.35s, box-shadow 0.35s;
}

.code-editor-card:focus-within {
  border-color: var(--border-focus);
  box-shadow: var(--shadow), var(--shadow-glow);
}

.server-ready {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.45);
  margin-left: auto;
  margin-right: 0.5rem;
}

.server-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 8px rgba(74, 222, 128, 0.7);
  animation: pulse-dot 2s ease-in-out infinite;
}

.code-editor-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.55rem 0.85rem;
  background: linear-gradient(180deg, #1a2332 0%, #141c28 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.window-controls {
  display: flex;
  gap: 0.35rem;
  flex-shrink: 0;
}

.control-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.control-dot.red { background: #ff5f57; }
.control-dot.yellow { background: #febc2e; }
.control-dot.green { background: #28c840; }

.code-editor-tab {
  flex: 1;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.75);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.code-editor-toolbar {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-left: auto;
}

.toolbar-label {
  margin: 0 !important;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  font-weight: 500;
}

.toolbar-select {
  width: auto !important;
  min-width: 130px;
  padding: 0.35rem 0.55rem !important;
  font-size: 0.82rem !important;
  border-radius: 6px !important;
  background: rgba(0, 0, 0, 0.35) !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
}

.syntax-badge {
  margin-left: auto;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: rgba(74, 159, 212, 0.2);
  color: var(--bwf-sky);
}

.code-editor-body {
  display: flex;
  position: relative;
  min-height: 220px;
  max-height: 420px;
}

.code-editor-gutter {
  flex-shrink: 0;
  width: 3rem;
  padding: 0.85rem 0.5rem;
  text-align: right;
  overflow: hidden;
  user-select: none;
  background: rgba(0, 0, 0, 0.25);
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.28);
}

.code-editor-gutter span {
  display: block;
}

.code-editor-body textarea {
  flex: 1;
  width: 100%;
  min-height: 220px;
  max-height: 420px;
  margin: 0 !important;
  padding: 0.85rem 1rem;
  border: none !important;
  border-radius: 0 !important;
  resize: none;
  background: transparent;
  color: #e6edf3;
  font-family: var(--font-mono);
  font-size: 0.92rem;
  line-height: 1.6;
  box-shadow: none !important;
}

.code-editor-body textarea:focus {
  outline: none;
  box-shadow: none !important;
}

.code-viewer-body {
  max-height: 480px;
}

.code-viewer-pre {
  flex: 1;
  margin: 0;
  padding: 0.85rem 1rem;
  overflow: auto;
  background: transparent !important;
  font-family: var(--font-mono);
  font-size: 0.92rem;
  line-height: 1.6;
}

.code-viewer-pre code {
  display: block;
  white-space: pre;
  background: transparent !important;
  font-size: inherit;
}

.code-editor-footer {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.45rem 0.85rem;
  background: rgba(0, 0, 0, 0.35);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.45);
}

.code-editor-footer .small-copy {
  margin-left: auto;
  margin-top: 0;
  padding: 0.3rem 0.65rem;
  font-size: 0.78rem;
}

.btn-kbd {
  margin-left: 0.5rem;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.72rem;
  font-family: inherit;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.15);
  font-weight: 500;
}

.copy-toast {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  padding: 0.65rem 1.15rem;
  border-radius: 999px;
  background: var(--gradient-primary);
  color: var(--bwf-navy-deep);
  font-weight: 700;
  font-size: 0.9rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
  z-index: 200;
  box-shadow: 0 10px 32px rgba(244, 203, 82, 0.4);
}

.copy-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.view-card .code-editor-card {
  margin-top: 1rem;
}

/* Prism overrides for dark editor */
.code-viewer-pre code[class*="language-"],
.code-viewer-pre pre[class*="language-"] {
  text-shadow: none;
}

