:root {
  --bg: #fbf8ef;
  --surface: #ffffff;
  --surface-soft: #fbfbfd;
  --ink: #1d1d1f;
  --muted: #6e6e73;
  --subtle: #86868b;
  --line: rgba(0, 0, 0, 0.10);
  --line-strong: rgba(0, 0, 0, 0.18);
  --accent: #0071e3;
  --accent-strong: #005bb5;
  --success: #34c759;
  --shadow-soft: 0 20px 60px rgba(0, 0, 0, 0.08);
  --shadow-card: 0 10px 30px rgba(0, 0, 0, 0.07);
  --nav-bg: rgba(245, 245, 247, 0.78);
  --field-bg: rgba(255, 255, 255, 0.82);
  color-scheme: light;
}

html[data-theme="dark"] {
  --bg: #000000;
  --surface: #161617;
  --surface-soft: #1d1d1f;
  --ink: #f5f5f7;
  --muted: #a1a1a6;
  --subtle: #86868b;
  --line: rgba(255, 255, 255, 0.14);
  --line-strong: rgba(255, 255, 255, 0.22);
  --accent: #2997ff;
  --accent-strong: #5eb0ff;
  --success: #30d158;
  --shadow-soft: 0 24px 70px rgba(0, 0, 0, 0.42);
  --shadow-card: 0 16px 36px rgba(0, 0, 0, 0.30);
  --nav-bg: rgba(0, 0, 0, 0.72);
  --field-bg: rgba(255, 255, 255, 0.08);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  scroll-behavior: smooth;
  text-size-adjust: 100%;
  scrollbar-color: rgba(0, 113, 227, 0.72) rgba(255, 255, 255, 0.32);
  scrollbar-width: thin;
}

html::-webkit-scrollbar {
  width: 13px;
}

html::-webkit-scrollbar-track {
  background:
    linear-gradient(180deg, rgba(0, 113, 227, 0.08), rgba(52, 199, 89, 0.08)),
    rgba(255, 255, 255, 0.48);
}

html::-webkit-scrollbar-thumb {
  border: 3px solid transparent;
  border-radius: 999px;
  background:
    linear-gradient(180deg, #0071e3, #34c759 52%, #ff9500) border-box;
  background-clip: content-box;
}

html[data-theme="dark"] {
  scrollbar-color: rgba(41, 151, 255, 0.76) rgba(255, 255, 255, 0.10);
}

body {
  position: relative;
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(125deg, rgba(255, 255, 255, 0.94) 0%, rgba(239, 247, 255, 0.92) 34%, rgba(255, 246, 232, 0.88) 68%, rgba(244, 251, 242, 0.90) 100%),
    linear-gradient(180deg, #ffffff 0, var(--bg) 620px),
    var(--bg);
  background-size: 180% 180%, 100% 100%, auto;
  animation: ambientGradient 22s ease-in-out infinite;
  overflow-x: hidden;
}

body::before,
body::after {
  position: fixed;
  inset: -20%;
  z-index: 0;
  pointer-events: none;
  content: "";
}

body::before {
  background-image:
    repeating-linear-gradient(112deg, rgba(0, 113, 227, 0.14) 0 1px, transparent 1px 56px),
    repeating-linear-gradient(24deg, rgba(52, 199, 89, 0.10) 0 1px, transparent 1px 78px),
    repeating-linear-gradient(156deg, rgba(255, 149, 0, 0.09) 0 1px, transparent 1px 96px);
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.44) 62%, transparent 100%);
  opacity: 0.92;
  transform: translate3d(-1.5%, -1%, 0) rotate(-1deg);
  animation: ambientLines 34s linear infinite;
}

body::after {
  background:
    linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.70) 45%, transparent 100%),
    linear-gradient(180deg, transparent 0%, rgba(0, 113, 227, 0.12) 48%, transparent 100%);
  mix-blend-mode: soft-light;
  opacity: 0.58;
  transform: translate3d(0, 0, 0);
  animation: ambientWash 26s ease-in-out infinite alternate;
}

html[data-theme="dark"] body {
  background:
    linear-gradient(125deg, rgba(0, 0, 0, 0.96) 0%, rgba(8, 21, 35, 0.94) 36%, rgba(30, 23, 13, 0.92) 72%, rgba(11, 24, 19, 0.94) 100%),
    linear-gradient(180deg, #050505 0, var(--bg) 620px),
    var(--bg);
}

html[data-theme="dark"] body::before {
  background-image:
    repeating-linear-gradient(112deg, rgba(41, 151, 255, 0.22) 0 1px, transparent 1px 56px),
    repeating-linear-gradient(24deg, rgba(48, 209, 88, 0.14) 0 1px, transparent 1px 78px),
    repeating-linear-gradient(156deg, rgba(255, 159, 10, 0.12) 0 1px, transparent 1px 96px);
  opacity: 0.70;
}

html[data-theme="dark"] body::after {
  background:
    linear-gradient(90deg, transparent 0%, rgba(41, 151, 255, 0.18) 45%, transparent 100%),
    linear-gradient(180deg, transparent 0%, rgba(48, 209, 88, 0.10) 48%, transparent 100%);
  opacity: 0.36;
}

.ambient-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.82;
}

.burst-layer {
  position: fixed;
  inset: 0;
  z-index: 80;
  overflow: hidden;
  pointer-events: none;
}

.custom-cursor {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 90;
  width: 34px;
  height: 34px;
  pointer-events: none;
  opacity: 0;
  transform: translate3d(-100px, -100px, 0) translate(-50%, -50%);
  transition: opacity 160ms ease;
  contain: layout paint style;
  will-change: transform;
}

.cursor-ring,
.cursor-core {
  position: absolute;
  left: 50%;
  top: 50%;
  border-radius: 999px;
  transform: translate(-50%, -50%);
}

.cursor-ring {
  width: 32px;
  height: 32px;
  border: 1px solid rgba(0, 113, 227, 0.50);
  background: transparent;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.34),
    0 0 18px rgba(0, 113, 227, 0.18);
  transition: width 120ms ease, height 120ms ease, border-color 120ms ease, transform 120ms ease;
}

.cursor-core {
  width: 4px;
  height: 4px;
  background: var(--accent);
  box-shadow: 0 0 12px rgba(0, 113, 227, 0.34);
  transition: width 120ms ease, height 120ms ease, border-radius 120ms ease, background 120ms ease;
}

body.cursor-active .custom-cursor {
  opacity: 1;
}

body.cursor-interactive .cursor-ring {
  width: 42px;
  height: 42px;
  border-color: rgba(255, 149, 0, 0.64);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.38),
    0 0 22px rgba(255, 149, 0, 0.22);
}

body.cursor-pressing .cursor-ring {
  transform: translate(-50%, -50%) scale(0.70);
}

body.cursor-text .cursor-ring {
  width: 34px;
  height: 34px;
  border-color: rgba(52, 199, 89, 0.72);
}

body.cursor-text .cursor-core {
  width: 2px;
  height: 22px;
  border-radius: 3px;
  background: var(--success);
}

html[data-theme="dark"] .cursor-ring {
  border-color: rgba(41, 151, 255, 0.62);
  background: transparent;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12),
    0 0 22px rgba(41, 151, 255, 0.24);
}

.scroll-progress {
  position: fixed;
  top: 78px;
  right: 13px;
  bottom: 18px;
  z-index: 75;
  width: 12px;
  border: 1px solid rgba(0, 113, 227, 0.20);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.44);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.44),
    0 12px 36px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(14px);
  pointer-events: none;
}

.scroll-progress span {
  position: absolute;
  left: 50%;
  bottom: 4px;
  width: 5px;
  height: calc((100% - 8px) * var(--scroll-progress, 0));
  min-height: 18px;
  border-radius: 999px;
  background: linear-gradient(180deg, #ff9500 0%, #34c759 45%, #0071e3 100%);
  box-shadow:
    0 0 18px rgba(0, 113, 227, 0.32),
    0 0 28px rgba(52, 199, 89, 0.18);
  transform: translateX(-50%);
  transition: height 90ms linear;
}

html[data-theme="dark"] .scroll-progress {
  border-color: rgba(41, 151, 255, 0.28);
  background: rgba(0, 0, 0, 0.28);
}

.burst-spark {
  position: absolute;
  left: 0;
  top: 0;
  width: var(--spark-size, 6px);
  height: var(--spark-size, 6px);
  border-radius: 999px;
  background: rgb(var(--spark-color, 0, 113, 227));
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.72),
    0 0 18px rgba(var(--spark-color, 0, 113, 227), 0.72),
    0 0 34px rgba(var(--spark-color, 0, 113, 227), 0.36);
  transform: translate(-50%, -50%) scale(0.32);
  animation: burstSpark 920ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.burst-spark::after {
  position: absolute;
  top: 50%;
  left: 50%;
  width: calc(var(--spark-size, 6px) * 4.2);
  height: 2px;
  border-radius: 999px;
  background: rgba(var(--spark-color, 0, 113, 227), 0.72);
  content: "";
  transform: translate(-50%, -50%) rotate(var(--spark-rotate, 0deg));
}

@keyframes burstSpark {
  0% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(0.82);
  }

  68% {
    opacity: 0.96;
  }

  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--spark-x, 0px)), calc(-50% + var(--spark-y, 0px))) scale(0.46);
  }
}

@keyframes ambientGradient {
  0% {
    background-position: 0% 50%, 0 0, 0 0;
  }

  50% {
    background-position: 100% 50%, 0 0, 0 0;
  }

  100% {
    background-position: 0% 50%, 0 0, 0 0;
  }
}

@keyframes ambientLines {
  0% {
    transform: translate3d(-1.5%, -1%, 0) rotate(-1deg);
  }

  50% {
    transform: translate3d(1.5%, 1%, 0) rotate(1deg);
  }

  100% {
    transform: translate3d(-1.5%, -1%, 0) rotate(-1deg);
  }
}

@keyframes ambientWash {
  0% {
    transform: translate3d(-4%, -2%, 0) skewX(-4deg);
  }

  100% {
    transform: translate3d(4%, 2%, 0) skewX(4deg);
  }
}

button,
input {
  font: inherit;
}

button {
  color: inherit;
}

.app-shell {
  position: relative;
  z-index: 1;
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 0 0 64px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 52px;
  margin: 0 calc((100vw - 100%) / -2);
  padding: 0 max(20px, calc((100vw - 1180px) / 2));
  border-bottom: 1px solid var(--line);
  background: var(--nav-bg);
  backdrop-filter: saturate(180%) blur(20px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 7px;
  background: var(--ink);
  color: var(--bg);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 14px;
  line-height: 1.1;
}

.brand small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.topbar-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.topbar-links {
  display: flex;
  align-items: center;
  gap: 16px;
}

.topbar-links a {
  color: var(--muted);
  text-decoration: none;
}

.topbar-links a:hover,
.topbar-links a:focus-visible {
  color: var(--ink);
  outline: none;
}

.topbar-meta span {
  line-height: 1;
}

.theme-toggle {
  min-height: 30px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 12px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font-size: 12px;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease, color 150ms ease;
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
  border-color: var(--line-strong);
  outline: none;
}

main {
  display: block;
}

.mode-switch {
  position: sticky;
  top: 52px;
  z-index: 10;
  display: flex;
  gap: 8px;
  padding: 12px 0 8px;
  background: rgba(251, 248, 239, 0.86);
  backdrop-filter: saturate(180%) blur(24px);
}

html[data-theme="dark"] .mode-switch {
  background: rgba(0, 0, 0, 0.78);
}

.mode-button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 16px;
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
  font-weight: 700;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

.mode-button.is-active {
  border-color: var(--accent);
  background: var(--accent);
  color: #ffffff;
}

.hero-section {
  display: none;
  min-height: auto;
  padding: 22px 0 12px;
}

body.is-searching .hero-section {
  grid-template-columns: 1fr;
  min-height: auto;
  padding-bottom: 18px;
}

body.is-searching .hero-visual-card,
body.is-searching .workflow-section,
body.is-searching .playbook-section,
body.is-searching .decision-section,
body.is-searching .formula-section,
body.is-searching .lab-section,
body.is-searching .resource-section,
body.is-searching .faq-section,
body.is-searching .saved-section,
body.is-searching .featured-section {
  display: none;
}

.hero-copy {
  display: grid;
  justify-items: start;
  gap: 12px;
}

.eyebrow {
  margin: 0;
  color: var(--accent);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.25;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 680px;
  margin-bottom: 0;
  font-size: 34px;
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: 0;
}

.hero-subtitle {
  display: none;
}

.hero-actions {
  display: none;
}

.primary-link,
.secondary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 999px;
  padding: 0 20px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
}

.primary-link {
  background: var(--accent);
  color: #ffffff;
}

.primary-link:hover {
  background: var(--accent-strong);
}

.secondary-link {
  color: var(--accent);
}

.secondary-link:hover {
  text-decoration: underline;
}

.search-box {
  display: grid;
  gap: 10px;
  width: min(100%, 520px);
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.search-box input {
  width: 100%;
  min-height: 54px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 20px;
  background: var(--field-bg);
  color: var(--ink);
  outline: none;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.04);
  backdrop-filter: blur(18px);
}

.search-box input::placeholder {
  color: var(--subtle);
}

.search-box input:focus {
  border-color: rgba(0, 113, 227, 0.64);
  box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.14);
}

.tool-strip {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 560px;
  color: var(--muted);
  font-size: 12px;
}

.tool-strip span {
  margin-right: 2px;
  color: var(--subtle);
}

.tool-strip strong {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 10px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--ink);
  font-weight: 600;
}

html[data-theme="dark"] .tool-strip strong {
  background: rgba(255, 255, 255, 0.08);
}

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  width: min(100%, 520px);
}

.hero-metrics div {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 13px 14px;
  background: rgba(255, 255, 255, 0.54);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.035);
}

html[data-theme="dark"] .hero-metrics div {
  background: rgba(255, 255, 255, 0.07);
}

.hero-metrics strong,
.hero-metrics span {
  display: block;
}

.hero-metrics strong {
  color: var(--ink);
  font-size: 24px;
  line-height: 1;
}

.hero-metrics span {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
}

.hero-visual-card {
  position: relative;
  display: grid;
  gap: 16px;
  align-self: stretch;
  min-height: 570px;
}

.showcase-main {
  display: grid;
  align-content: space-between;
  min-height: 420px;
  border-radius: 8px;
  padding: 34px;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.94)),
    #ffffff;
  box-shadow: var(--shadow-soft);
}

html[data-theme="dark"] .showcase-main {
  background:
    linear-gradient(180deg, rgba(40, 40, 42, 0.90), rgba(22, 22, 23, 0.96)),
    var(--surface);
}

.showcase-label {
  width: max-content;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 11px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.showcase-main strong {
  max-width: 430px;
  margin-top: 28px;
  font-size: 42px;
  line-height: 1.08;
}

.showcase-main p {
  max-width: 420px;
  margin: 10px 0 26px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.5;
}

.showcase-image {
  min-height: 210px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px var(--line);
}

.showcase-image .visual {
  height: 100%;
  min-height: 210px;
}

.showcase-rail {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.mini-preview {
  display: grid;
  align-content: end;
  min-height: 134px;
  border-radius: 8px;
  padding: 16px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px var(--line);
}

.mini-preview span {
  color: rgba(255, 255, 255, 0.78);
  font-size: 12px;
  font-weight: 600;
}

.mini-preview strong {
  margin-top: 5px;
  color: #ffffff;
  font-size: 18px;
  line-height: 1.2;
}

.tabs-section {
  position: sticky;
  top: 114px;
  z-index: 8;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  margin: 4px 0 0;
  padding: 12px 0;
  border: 0;
  border-radius: 0;
  background: rgba(251, 248, 239, 0.82);
  box-shadow: none;
  backdrop-filter: saturate(180%) blur(24px);
}

html[data-theme="dark"] .tabs-section {
  background: rgba(0, 0, 0, 0.76);
}

.category-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}

.category-tabs::-webkit-scrollbar {
  display: none;
}

.tab-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 17px;
  background: rgba(255, 255, 255, 0.68);
  color: var(--muted);
  cursor: pointer;
  white-space: nowrap;
  font-size: 15px;
  font-weight: 600;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

.tab-button:hover,
.tab-button:focus-visible {
  color: var(--ink);
  outline: none;
}

.tab-button span {
  color: var(--subtle);
  font-size: 12px;
}

.tab-button.is-active {
  border-color: rgba(76, 40, 15, 0.42);
  background: #fffaf2;
  color: var(--ink);
  box-shadow: inset 0 0 0 2px rgba(76, 40, 15, 0.12), 0 5px 16px rgba(0, 0, 0, 0.05);
}

html[data-theme="dark"] .tab-button.is-active {
  background: rgba(255, 255, 255, 0.10);
}

.quick-search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.quick-search {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0 16px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--subtle);
  font-size: 13px;
}

html[data-theme="dark"] .quick-search {
  background: rgba(255, 255, 255, 0.08);
}

.quick-search span {
  font-weight: 700;
}

.quick-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  outline: none;
}

.quick-search input::placeholder {
  color: var(--subtle);
}

.clear-filters {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 16px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--muted);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

.clear-filters:hover,
.clear-filters:focus-visible {
  border-color: var(--line-strong);
  color: var(--ink);
  outline: none;
}

html[data-theme="dark"] .clear-filters {
  background: rgba(255, 255, 255, 0.08);
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin: 58px 0 18px;
}

.library-section .section-heading {
  margin: 18px 0 12px;
}

.section-heading h2 {
  margin-bottom: 0;
  font-size: 36px;
  line-height: 1.1;
}

.section-heading span {
  color: var(--muted);
  font-size: 15px;
  text-align: right;
}

.featured-section,
.workflow-section,
.playbook-section,
.decision-section,
.formula-section,
.lab-section,
.faq-section,
.resource-section,
.saved-section,
.showcase-section,
.library-section {
  position: relative;
}

body[data-view="showcase"] .tabs-section,
body[data-view="showcase"] .library-section {
  display: none;
}

body[data-view="prompts"] .showcase-section {
  display: none;
}

.topbar-links,
.hero-visual-card,
.tool-strip,
.hero-metrics,
.featured-section,
.workflow-section,
.playbook-section,
.decision-section,
.formula-section,
.lab-section,
.faq-section,
.resource-section,
.saved-section {
  display: none;
}

.playbook-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}

.showcase-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}

.showcase-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  overflow-x: auto;
  scrollbar-width: none;
}

.showcase-tabs::-webkit-scrollbar {
  display: none;
}

.showcase-tab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 13px;
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 700;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

.showcase-tab span {
  color: var(--subtle);
  font-size: 11px;
}

.showcase-tab.is-active {
  border-color: var(--accent);
  background: rgba(0, 113, 227, 0.08);
  color: var(--accent);
}

.showcase-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(18px);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

html[data-theme="dark"] .showcase-card {
  background: rgba(22, 22, 23, 0.78);
}

.showcase-card:hover,
.showcase-card:focus-within {
  transform: translateY(-2px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-soft);
}

.showcase-card.is-target {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.18), var(--shadow-soft);
}

.showcase-pick {
  display: grid;
  width: 100%;
  color: inherit;
  text-align: left;
}

.showcase-visual {
  position: relative;
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #111827;
  cursor: ew-resize;
  touch-action: pan-y;
}

.before-layer,
.after-layer,
.ba-handle {
  position: absolute;
  inset: 0;
}

.before-layer {
  background: var(--before-img, none),
  background-size: cover;
  background-position: center;
    linear-gradient(180deg, rgba(0, 0, 0, 0.02), rgba(0, 0, 0, 0.42)),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.08) 0 1px, transparent 1px 34px),
    linear-gradient(145deg, #6b7280, #d1d5db);
}

.after-layer {
  width: var(--split);
  overflow: hidden;
  will-change: width;
  background: var(--after-img, none),
  background-size: cover;
  background-position: center;
    radial-gradient(circle at 75% 22%, rgba(255, 255, 255, 0.30), transparent 18%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #111827, #2579d8 58%, #b7d7ff);
}

.theme-b .after-layer {
  background: var(--after-img, none),
    radial-gradient(circle at 75% 22%, rgba(255, 255, 255, 0.28), transparent 18%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #264d3a, #75c7a6 56%, #f5e8cf);
}

.theme-c .after-layer {
  background: var(--after-img, none),
    radial-gradient(circle at 75% 22%, rgba(255, 255, 255, 0.28), transparent 18%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #4b3b73, #7ba7ff 58%, #f6d5f7);
}

.theme-d .after-layer {
  background: var(--after-img, none),
    radial-gradient(circle at 75% 22%, rgba(255, 255, 255, 0.28), transparent 18%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #7a3d42, #f2a8a1 56%, #f7f1df);
}

.theme-e .after-layer {
  background: var(--after-img, none),
    radial-gradient(circle at 75% 22%, rgba(255, 255, 255, 0.28), transparent 18%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #183c5a, #66d1e8 58%, #e7f7ff);
}

.theme-f .after-layer {
  background: var(--after-img, none),
    radial-gradient(circle at 75% 22%, rgba(255, 255, 255, 0.28), transparent 18%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #6a3f10, #f4bf5c 56%, #fff4d7);
}

.before-layer span,
.after-layer span {
  position: absolute;
  top: 10px;
  border-radius: 999px;
  padding: 5px 8px;
  background: rgba(255, 255, 255, 0.82);
  color: #111827;
  font-size: 11px;
  font-weight: 800;
}

.before-layer span {
  left: 10px;
}

.after-layer span {
  right: 10px;
}

.ba-handle {
  left: var(--split);
  width: 2px;
  right: auto;
  transform: translateX(-1px);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.18);
}

.ba-handle span {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 34px;
  height: 34px;
  border: 2px solid rgba(255, 255, 255, 0.95);
  border-radius: 999px;
  background: rgba(17, 24, 39, 0.72);
  transform: translate(-50%, -50%);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
}

.showcase-like {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  border: 0;
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.92);
  color: #111827;
  cursor: pointer;
  font-size: 14px;
  font-weight: 800;
  transition: transform 150ms ease, box-shadow 150ms ease, background 150ms ease;
}

.showcase-like:hover,
.showcase-like:focus-visible {
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
  outline: none;
  transform: translateY(-1px);
}

.showcase-copy {
  display: grid;
  gap: 8px;
  padding: 12px;
}

.showcase-title {
  color: var(--ink);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.3;
}

.showcase-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.playbook-card {
  display: grid;
  align-content: end;
  min-height: 220px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  overflow: hidden;
  color: #ffffff;
  text-decoration: none;
  box-shadow: var(--shadow-card);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.playbook-card:hover,
.playbook-card:focus-visible {
  transform: translateY(-3px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-soft);
  outline: none;
}

.playbook-card span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 700;
}

.playbook-card strong {
  margin-top: 8px;
  font-size: 22px;
  line-height: 1.08;
}

.playbook-card p {
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
  line-height: 1.5;
}

.compact-heading {
  margin-top: 34px;
}

.decision-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.decision-card {
  display: grid;
  align-content: start;
  min-height: 178px;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.72);
  color: inherit;
  text-decoration: none;
  box-shadow: 0 10px 28px rgba(42, 34, 18, 0.06);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

html[data-theme="dark"] .decision-card {
  background: rgba(255, 255, 255, 0.07);
}

.decision-card:hover,
.decision-card:focus-visible {
  transform: translateY(-2px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-card);
  outline: none;
}

.decision-card strong {
  font-size: 19px;
  line-height: 1.18;
}

.decision-card p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.decision-card span {
  align-self: end;
  margin-top: 18px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
}

.resource-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.resource-card {
  display: grid;
  align-content: start;
  min-height: 210px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  box-shadow: var(--shadow-card);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.resource-card:hover,
.resource-card:focus-visible {
  transform: translateY(-3px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-soft);
  outline: none;
}

.resource-card span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
}

.resource-card strong {
  margin-top: 18px;
  font-size: 24px;
  line-height: 1.15;
}

.resource-card p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.workflow-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.workflow-card {
  display: grid;
  align-content: start;
  min-height: 190px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  background: var(--surface);
  box-shadow: var(--shadow-card);
}

.workflow-card span {
  width: max-content;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
}

.workflow-card strong {
  margin-top: 18px;
  font-size: 24px;
  line-height: 1.16;
}

.workflow-card p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

.formula-panel {
  display: grid;
  grid-template-columns: minmax(280px, 0.72fr) minmax(0, 1.28fr);
  gap: 28px;
  margin-top: 58px;
  border: 1px solid var(--line);
  border-radius: 26px;
  padding: 28px;
  background:
    radial-gradient(circle at 15% 20%, rgba(0, 113, 227, 0.12), transparent 30%),
    radial-gradient(circle at 84% 16%, rgba(255, 204, 0, 0.16), transparent 28%),
    rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow-card);
}

html[data-theme="dark"] .formula-panel {
  background:
    radial-gradient(circle at 15% 20%, rgba(41, 151, 255, 0.18), transparent 30%),
    radial-gradient(circle at 84% 16%, rgba(255, 204, 0, 0.08), transparent 28%),
    rgba(255, 255, 255, 0.06);
}

.formula-panel h2 {
  margin-bottom: 12px;
  font-size: 34px;
  line-height: 1.12;
}

.formula-panel p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.formula-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.formula-steps article {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.68);
}

html[data-theme="dark"] .formula-steps article {
  background: rgba(0, 0, 0, 0.18);
}

.formula-steps span {
  display: inline-grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 50%;
  background: var(--ink);
  color: var(--bg);
  font-size: 12px;
  font-weight: 800;
}

.formula-steps strong {
  display: block;
  margin-top: 14px;
  font-size: 19px;
}

.formula-steps p {
  margin-top: 8px;
  font-size: 13px;
  line-height: 1.6;
}

.lab-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.lab-card {
  min-height: 190px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  background:
    radial-gradient(circle at 18% 18%, rgba(0, 113, 227, 0.10), transparent 34%),
    var(--surface);
  box-shadow: var(--shadow-card);
}

.lab-card span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
}

.lab-card strong {
  display: block;
  margin-top: 18px;
  font-size: 23px;
  line-height: 1.16;
}

.lab-card p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.featured-grid,
.effect-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 12px;
}

.effect-card {
  position: relative;
  display: block;
  min-height: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow-card);
  cursor: pointer;
  text-align: left;
  backdrop-filter: blur(18px);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

html[data-theme="dark"] .effect-card {
  background: rgba(22, 22, 23, 0.78);
}

.effect-card:hover,
.effect-card:focus-within {
  transform: translateY(-3px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-soft);
  outline: none;
}

.effect-card.is-target {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.18), var(--shadow-soft);
}

.card-open {
  position: relative;
  display: block;
  width: 100%;
  min-height: 0;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
}

.card-open:focus-visible {
  outline: 3px solid rgba(0, 113, 227, 0.34);
  outline-offset: -5px;
}

.visual {
  position: relative;
  min-height: 138px;
  overflow: hidden;
  background:
    radial-gradient(circle at 30% 22%, rgba(255, 255, 255, 0.30), transparent 16%),
    linear-gradient(160deg, #b8d8ff, #f2f2f7);
}

.visual::before,
.visual::after {
  content: "";
  position: absolute;
  border-radius: 28px;
}

.visual::before {
  width: 42%;
  height: 52%;
  left: 11%;
  bottom: 17%;
  background: rgba(255, 255, 255, 0.70);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.12);
}

.visual::after {
  width: 28%;
  height: 34%;
  right: 13%;
  top: 20%;
  background: rgba(255, 255, 255, 0.38);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.10);
}

.effect-card .visual {
  display: none;
}

.effect-card .visual::before,
.effect-card .visual::after,
.photo-shape {
  content: "";
  position: absolute;
  border-radius: 28px;
}

.effect-card .visual::before {
  width: auto;
  height: auto;
  left: auto;
  bottom: auto;
  inset: 0;
  border-radius: 0;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.22) 0%, transparent 28%, rgba(0, 0, 0, 0.88) 100%),
    radial-gradient(circle at 78% 16%, rgba(255, 255, 255, 0.22), transparent 18%);
  box-shadow: none;
  z-index: 2;
}

.effect-card .visual::after {
  width: 115%;
  height: 42%;
  left: -7%;
  right: auto;
  top: auto;
  bottom: -19%;
  border-radius: 50% 50% 0 0;
  background: rgba(6, 9, 18, 0.48);
  filter: blur(12px);
  box-shadow: none;
  z-index: 1;
}

.photo-shape {
  display: block;
  z-index: 0;
}

.shape-one {
  width: 48%;
  height: 42%;
  left: 8%;
  bottom: 19%;
  background: rgba(255, 255, 255, 0.20);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18);
}

.shape-two {
  width: 34%;
  height: 28%;
  right: 9%;
  top: 18%;
  background: rgba(255, 255, 255, 0.16);
}

.shape-three {
  width: 24%;
  height: 16%;
  right: 18%;
  bottom: 31%;
  background: rgba(255, 255, 255, 0.22);
  transform: rotate(-8deg);
}

.theme-a .visual,
.theme-a {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.18), transparent 42%),
    linear-gradient(145deg, #111827, #2579d8 58%, #b7d7ff);
}

.theme-b .visual,
.theme-b {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.20), transparent 42%),
    linear-gradient(145deg, #264d3a, #75c7a6 56%, #f5e8cf);
}

.theme-c .visual,
.theme-c {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.22), transparent 42%),
    linear-gradient(145deg, #4b3b73, #7ba7ff 58%, #f6d5f7);
}

.theme-d .visual,
.theme-d {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.22), transparent 42%),
    linear-gradient(145deg, #7a3d42, #f2a8a1 56%, #f7f1df);
}

.theme-e .visual,
.theme-e {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.20), transparent 42%),
    linear-gradient(145deg, #183c5a, #66d1e8 58%, #e7f7ff);
}

.theme-f .visual,
.theme-f {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.20), transparent 42%),
    linear-gradient(145deg, #6a3f10, #f4bf5c 56%, #fff4d7);
}

.card-body {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: start;
  gap: 8px;
  padding: 14px 14px 10px;
  color: var(--ink);
}

.card-kicker {
  position: static;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
}

.card-title {
  margin-bottom: 0;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.25;
  letter-spacing: 0;
}

.card-scene {
  display: none;
}

.card-prompt {
  display: -webkit-box;
  min-height: 116px;
  border: 1px solid var(--line);
  border-radius: 8px;
  margin-bottom: 0;
  padding: 10px;
  overflow: hidden;
  background: var(--surface-soft);
  color: var(--ink);
  font-size: 13px;
  line-height: 1.58;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 6;
}

.tag-row,
.tool-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag,
.tool-chip,
.difficulty {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 8px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--muted);
  font-size: 12px;
  line-height: 1;
}

.effect-card .tag,
.effect-card .difficulty {
  border-color: var(--line);
  background: var(--surface-soft);
  color: var(--muted);
  backdrop-filter: none;
}

html[data-theme="dark"] .tag,
html[data-theme="dark"] .tool-chip,
html[data-theme="dark"] .difficulty {
  background: rgba(255, 255, 255, 0.08);
}

.difficulty {
  border-color: rgba(0, 113, 227, 0.24);
  color: var(--accent);
}

.card-actions {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: flex-start;
  gap: 8px;
  padding: 0 14px 14px;
  pointer-events: auto;
}

.card-copy-button,
.card-showcase-button,
.card-favorite-button {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 11px;
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  pointer-events: auto;
  backdrop-filter: none;
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease, background 150ms ease, color 150ms ease;
}

html[data-theme="dark"] .card-copy-button,
html[data-theme="dark"] .card-showcase-button,
html[data-theme="dark"] .card-favorite-button {
  background: rgba(22, 22, 23, 0.72);
  color: #f5f5f7;
}

.card-copy-button {
  border-color: var(--accent);
  background: var(--accent);
  color: #ffffff;
}

.card-showcase-button {
  border-color: rgba(0, 113, 227, 0.28);
  background: rgba(0, 113, 227, 0.08);
  color: var(--accent);
}

html[data-theme="dark"] .card-copy-button {
  background: var(--accent);
  color: #ffffff;
}

.card-favorite-button.is-active {
  border-color: rgba(41, 151, 255, 0.34);
  background: rgba(41, 151, 255, 0.88);
  color: #ffffff;
}

.card-copy-button:hover,
.card-copy-button:focus-visible,
.card-showcase-button:hover,
.card-showcase-button:focus-visible,
.card-favorite-button:hover,
.card-favorite-button:focus-visible {
  border-color: var(--line-strong);
  box-shadow: 0 7px 18px rgba(0, 0, 0, 0.10);
  transform: translateY(-1px);
  outline: none;
}

.card-copy-button:active,
.card-showcase-button:active,
.card-favorite-button:active,
.showcase-like:active,
.mode-button:active,
.tab-button:active,
.showcase-tab:active,
.clear-filters:active,
.copy-button:active {
  transform: translateY(1px) scale(0.99);
}

.effect-dialog {
  width: min(980px, calc(100% - 28px));
  max-height: min(840px, calc(100vh - 28px));
  border: 0;
  border-radius: 8px;
  padding: 0;
  background: transparent;
}

.effect-dialog::backdrop {
  background: rgba(0, 0, 0, 0.46);
  backdrop-filter: blur(18px);
}

.dialog-panel {
  position: relative;
  max-height: min(840px, calc(100vh - 28px));
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.dialog-close {
  position: sticky;
  top: 12px;
  z-index: 2;
  float: right;
  width: 34px;
  height: 34px;
  margin: 12px 12px 0 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--field-bg);
  color: var(--muted);
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
  backdrop-filter: blur(16px);
}

.dialog-close:hover,
.dialog-close:focus-visible {
  color: var(--ink);
  outline: none;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(230px, 330px) minmax(0, 1fr);
  gap: 28px;
  padding: 28px;
}

.detail-visual {
  min-height: 420px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px var(--line);
}

.detail-visual .visual {
  height: 100%;
  min-height: 420px;
}

.detail-copy {
  min-width: 0;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.detail-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.detail-title-row h2 {
  margin-bottom: 10px;
  font-size: 34px;
  line-height: 1.12;
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.favorite-button,
.link-button {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 12px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font-size: 13px;
  white-space: nowrap;
}

.favorite-button.is-active {
  border-color: rgba(0, 113, 227, 0.34);
  background: rgba(0, 113, 227, 0.08);
  color: var(--accent);
}

.detail-copy p {
  color: var(--muted);
  line-height: 1.7;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 18px 0;
}

.info-box,
.steps-box,
.prompt-box {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}

.info-box {
  padding: 13px;
}

.info-box strong,
.steps-box strong,
.prompt-head strong {
  display: block;
  color: var(--ink);
  font-size: 13px;
}

.info-box strong {
  margin-bottom: 6px;
}

.info-box span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.steps-box {
  margin: 18px 0 6px;
  padding: 15px 16px;
}

.steps-box strong {
  margin-bottom: 10px;
}

.steps-box ol {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.prompt-box {
  margin-top: 12px;
  overflow: hidden;
}

.prompt-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
  padding: 11px 12px;
}

.copy-button {
  border: 1px solid var(--accent);
  border-radius: 999px;
  background: var(--accent);
  color: #ffffff;
  cursor: pointer;
  padding: 8px 12px;
  font-size: 13px;
  white-space: nowrap;
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease, background 150ms ease;
}

.copy-button:hover,
.copy-button:focus-visible {
  box-shadow: 0 8px 20px rgba(0, 113, 227, 0.18);
  outline: none;
}

.copy-button.secondary {
  border-color: var(--line);
  background: transparent;
  color: var(--ink);
}

.prompt-text {
  margin: 0;
  padding: 13px;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.75;
  white-space: pre-wrap;
  word-break: break-word;
}

.variant-box .prompt-head {
  border-bottom: 1px solid var(--line);
}

.variant-list {
  display: grid;
  max-height: 520px;
  overflow: auto;
}

.variant-item {
  display: grid;
  gap: 8px;
  border-bottom: 1px solid var(--line);
  padding: 12px;
}

.variant-item:last-child {
  border-bottom: 0;
}

.variant-item .prompt-text {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  padding: 11px;
  font-size: 13px;
}

.variant-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.variant-meta span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 8px;
  color: var(--muted);
  font-size: 12px;
}

.empty-state {
  display: grid;
  gap: 6px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  padding: 44px;
  color: var(--muted);
  text-align: center;
  background: var(--surface);
}

.empty-state strong {
  color: var(--ink);
}

.load-sentinel {
  display: grid;
  min-height: 52px;
  place-items: center;
  margin: 10px 0 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.58);
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  backdrop-filter: blur(14px);
}

.load-sentinel[hidden] {
  display: none !important;
}

html[data-theme="dark"] .load-sentinel {
  background: rgba(255, 255, 255, 0.07);
}

.faq-list {
  display: grid;
  gap: 10px;
}

.faq-list details {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-card);
}

.faq-list summary {
  cursor: pointer;
  padding: 18px 20px;
  color: var(--ink);
  font-size: 17px;
  font-weight: 700;
  list-style: none;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "+";
  float: right;
  color: var(--muted);
  font-weight: 500;
}

.faq-list details[open] summary::after {
  content: "−";
}

.faq-list p {
  margin: -6px 20px 20px;
  max-width: 780px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  z-index: 20;
  transform: translate(-50%, 18px);
  opacity: 0;
  pointer-events: none;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  padding: 10px 15px;
  font-size: 14px;
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.site-footer {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(420px, 0.8fr);
  justify-content: space-between;
  gap: 32px;
  margin-top: 72px;
  border-top: 1px solid var(--line);
  padding: 28px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.footer-brand strong {
  display: block;
  color: var(--ink);
  font-size: 18px;
}

.footer-brand > span {
  display: block;
  margin-top: 8px;
  max-width: 460px;
  font-size: 13px;
  line-height: 1.6;
}

.platform-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.platform-strip span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 9px;
  background: var(--surface);
  color: var(--muted);
}

.footer-columns {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.footer-columns div {
  display: grid;
  align-content: start;
  gap: 9px;
}

.footer-columns strong {
  color: var(--ink);
  font-size: 13px;
}

.site-footer a {
  color: inherit;
  text-decoration: none;
}

.site-footer a:hover,
.site-footer a:focus-visible {
  color: var(--ink);
  outline: none;
}

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

  .ambient-canvas {
    display: none;
  }

  .burst-layer {
    display: none;
  }

  .custom-cursor {
    display: none;
  }
}

@media (max-width: 980px) {
  .hero-section {
    grid-template-columns: 1fr;
    gap: 30px;
    min-height: auto;
    padding-top: 48px;
  }

  .hero-copy {
    justify-items: center;
    text-align: center;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-visual-card {
    min-height: auto;
  }

  .tabs-section {
    grid-template-columns: 1fr;
  }

  .featured-grid,
  .playbook-grid,
  .decision-grid,
  .lab-grid,
  .resource-grid,
  .effect-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  .effect-card,
  .card-open {
    min-height: 310px;
  }

  .card-title {
    font-size: 23px;
  }

  .card-scene {
    font-size: 13px;
    line-height: 1.5;
  }

  .formula-panel {
    grid-template-columns: 1fr;
  }

  .detail-layout {
    grid-template-columns: 1fr;
  }

  .detail-visual,
  .detail-visual .visual {
    min-height: 260px;
  }
}

@media (max-width: 680px) {
  .app-shell {
    width: min(100% - 24px, 1180px);
    padding-bottom: 44px;
  }

  .topbar {
    min-height: 50px;
    padding: 0 12px;
  }

  .topbar-links,
  .brand small,
  .topbar-meta span {
    display: none;
  }

  .hero-section {
    padding: 36px 0 30px;
  }

  h1 {
    font-size: 58px;
  }

  .hero-subtitle {
    font-size: 18px;
  }

  .hero-actions {
    width: 100%;
  }

  .primary-link,
  .secondary-link {
    min-height: 42px;
  }

  .search-box {
    width: 100%;
    text-align: left;
  }

  .showcase-main {
    min-height: 360px;
    padding: 22px;
  }

  .showcase-main strong {
    font-size: 30px;
  }

  .showcase-rail {
    grid-template-columns: 1fr;
  }

  .hero-metrics {
    grid-template-columns: 1fr;
  }

  .workflow-grid {
    grid-template-columns: 1fr;
  }

  .playbook-grid,
  .decision-grid,
  .lab-grid,
  .resource-grid {
    grid-template-columns: 1fr;
  }

  .decision-card {
    min-height: auto;
  }

  .formula-panel {
    margin-top: 42px;
    border-radius: 22px;
    padding: 20px;
  }

  .formula-panel h2 {
    font-size: 28px;
  }

  .formula-steps {
    grid-template-columns: 1fr;
  }

  .mini-preview {
    min-height: 96px;
  }

  .tabs-section {
    top: 50px;
    padding: 10px 12px;
  }

  .quick-search {
    min-height: 42px;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 6px;
    margin-top: 42px;
  }

  .section-heading h2 {
    font-size: 30px;
  }

  .section-heading span {
    text-align: left;
  }

  .featured-grid,
  .effect-grid {
    grid-template-columns: 1fr;
  }

  .effect-card {
    min-height: 300px;
    border-radius: 20px;
  }

  .card-open {
    min-height: 300px;
  }

  .card-title {
    font-size: 23px;
  }

  .card-body {
    padding: 50px 16px 16px;
  }

  .card-scene {
    border-radius: 16px;
    padding: 13px 14px;
    font-size: 14px;
  }

  .card-actions {
    top: 14px;
    right: 14px;
  }

  .card-copy-button,
  .card-showcase-button,
  .card-favorite-button {
    min-height: 38px;
    border-radius: 11px;
    padding: 0 12px;
    font-size: 13px;
  }

  .effect-dialog {
    width: calc(100% - 16px);
    max-height: calc(100vh - 16px);
  }

  .dialog-panel {
    max-height: calc(100vh - 16px);
  }

  .detail-layout {
    gap: 18px;
    padding: 18px;
  }

  .detail-title-row {
    flex-direction: column;
    gap: 6px;
  }

  .detail-title-row h2 {
    font-size: 27px;
  }

  .detail-actions {
    justify-content: flex-start;
  }

  .info-grid {
    grid-template-columns: 1fr;
  }

  .prompt-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .site-footer {
    grid-template-columns: 1fr;
  }

  .footer-columns {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .effect-grid {
    gap: 10px;
  }

  .effect-card {
    min-height: 0;
    border-radius: 8px;
  }

  .card-open {
    min-height: 0;
  }

  .card-body {
    padding: 13px 13px 9px;
  }

  .card-title {
    font-size: 18px;
  }

  .card-prompt {
    min-height: 108px;
    font-size: 13px;
  }

  .card-actions {
    position: relative;
    top: auto;
    right: auto;
    padding: 0 13px 13px;
  }

  .card-copy-button,
  .card-showcase-button,
  .card-favorite-button {
    min-height: 34px;
    border-radius: 8px;
    font-size: 12px;
  }
}
