@import url("https://fonts.googleapis.com/css2?family=Bangers&display=swap");

:root {
  --bg: #171717;
  --bg-soft: #1f1f1f;
  --bg-elevated: #262626;
  --line: #3d3d3d;
  --line-strong: #5a5a5a;
  --text: #f5f5f5;
  --text-muted: #c8c8c8;
  --accent: #e66100;
  --accent-strong: #c64600;
  --ok: #2ec27e;
  --sponsor: #bf3989;
}

:root[data-theme="light"] {
  --bg: #f5f4f2;
  --bg-soft: #ffffff;
  --bg-elevated: #f0eeec;
  --line: #d5d2cf;
  --line-strong: #bcb7b3;
  --text: #1f1f1f;
  --text-muted: #5e5c64;
}

* {
  box-sizing: border-box;
}

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

body {
  background: linear-gradient(180deg, var(--bg) 0%, color-mix(in oklab, var(--bg) 92%, #000 8%) 100%);
  color: var(--text);
  font-family: Cantarell, "Noto Sans", "Segoe UI", sans-serif;
  color-scheme: dark;
}

:root[data-theme="light"] body {
  color-scheme: light;
}

a {
  color: inherit;
}

.page-shell {
  width: min(1120px, calc(100% - 2.2rem));
  margin: 1rem auto 1.4rem;
}

.window-bar {
  position: sticky;
  top: 0.6rem;
  z-index: 40;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.64rem 0.82rem;
  border: 1px solid var(--line);
  background: color-mix(in oklab, var(--bg-elevated) 93%, transparent 7%);
  backdrop-filter: blur(6px);
  transition:
    transform 220ms ease,
    box-shadow 260ms ease,
    border-color 220ms ease,
    background-color 220ms ease;
}

.window-bar.scrolled {
  transform: translateY(4px);
  border-color: var(--line-strong);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.35);
  background: color-mix(in oklab, var(--bg-elevated) 85%, #000 15%);
}

:root[data-theme="light"] .window-bar.scrolled {
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.14);
  background: color-mix(in oklab, var(--bg-elevated) 90%, white 10%);
}

.window-title {
  display: inline-flex;
  align-items: center;
  gap: 0.58rem;
  text-decoration: none;
  color: var(--text);
  white-space: nowrap;
}

.app-icon {
  width: 20px;
  height: 20px;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 0.28rem;
  flex-wrap: wrap;
}

.top-nav a,
.top-nav .theme-toggle {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.91rem;
  padding: 0.32rem 0.54rem;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  font-family: inherit;
  transition: color 140ms ease, border-color 140ms ease, transform 160ms ease;
}

.top-nav a .ext-indicator {
  display: inline-block;
  margin-left: 0.15rem;
  font-size: 0.72em;
  line-height: 1;
  opacity: 0.76;
  transform: translateY(-0.08em);
}

.top-nav a.active,
.top-nav a:hover,
.top-nav .theme-toggle:hover {
  color: var(--text);
  border-color: var(--line);
}

.top-nav a:hover .ext-indicator {
  opacity: 1;
}

.top-nav a:active,
.top-nav .theme-toggle:active {
  transform: translateY(1px);
}

.top-nav .theme-toggle {
  width: 2.05rem;
  height: 2.05rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.top-nav .theme-toggle svg {
  width: 1rem;
  height: 1rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.1;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.top-nav .theme-toggle .icon-sun {
  display: none;
}

:root[data-theme="light"] .top-nav .theme-toggle .icon-moon {
  display: none;
}

:root[data-theme="light"] .top-nav .theme-toggle .icon-sun {
  display: block;
}

main {
  margin-top: 1.7rem;
  display: grid;
  gap: 1.8rem;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem;
  padding: 0.25rem 0 1.05rem;
  border-bottom: 1px solid var(--line-strong);
}

.hero-downloads {
  grid-template-columns: minmax(0, 1fr);
}

.hero-main {
  min-width: 0;
}

.kicker {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0.36rem 0 0;
  font-size: clamp(1.52rem, 2.6vw, 2.45rem);
  line-height: 1.14;
}

.hero-copy {
  margin: 0.72rem 0 0;
  color: var(--text-muted);
  max-width: 78ch;
  line-height: 1.45;
}

.inline-note {
  margin: 0.62rem 0 0;
  color: color-mix(in oklab, var(--text-muted) 88%, var(--accent) 12%);
  font-size: 0.91rem;
}

.hero-actions {
  margin-top: 0.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.56rem;
}

.hero-pumpkin {
  width: clamp(86px, 9vw, 128px);
  height: auto;
  animation: heroFloat 5.5s ease-in-out infinite;
}

@keyframes heroFloat {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  background: var(--bg-elevated);
  color: var(--text);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 600;
  padding: 0.56rem 0.88rem;
  transition:
    background-color 150ms ease,
    border-color 150ms ease,
    transform 170ms ease;
}

.btn:hover {
  background: color-mix(in oklab, var(--bg-elevated) 84%, white 16%);
  border-color: var(--line-strong);
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn-accent {
  background: var(--accent);
  border-color: color-mix(in oklab, var(--accent) 70%, white 30%);
  color: #fff;
}

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

.btn-sponsor {
  border-color: color-mix(in oklab, var(--sponsor) 45%, var(--line) 55%);
  color: var(--sponsor);
}

.btn-sponsor::before {
  content: "\2665";
  margin-right: 0.38rem;
}

.section-block,
.card-section {
  padding: 0.44rem 0 1.08rem;
  border-bottom: 1px solid var(--line);
}

.section-head h2 {
  margin: 0;
  font-size: clamp(1.1rem, 1.7vw, 1.35rem);
}

.section-head p {
  margin: 0.24rem 0 0;
  color: var(--text-muted);
}

.issue-banner {
  border: 2px solid color-mix(in oklab, var(--accent) 58%, var(--line) 42%);
  background: color-mix(in oklab, var(--bg-soft) 84%, var(--accent) 16%);
}

.issue-banner a {
  display: flex;
  flex-direction: column;
  gap: 0.24rem;
  padding: 1.05rem 1.18rem;
  text-decoration: none;
}

.issue-banner strong {
  font-size: clamp(1.28rem, 2.2vw, 1.6rem);
  line-height: 1.08;
}

.issue-banner span {
  color: var(--text-muted);
}

.feature-list {
  margin: 0.9rem 0 0;
  padding: 0;
  list-style: none;
}

.feature-list li {
  position: relative;
  padding: 1.04rem 0 0.94rem 1rem;
  border-top: 1px dashed color-mix(in oklab, var(--line) 70%, transparent 30%);
}

.feature-list li:first-child {
  border-top: 0;
}

.feature-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.4rem;
  width: 0.42rem;
  height: 0.42rem;
  background: var(--accent);
}

.feature-list h3 {
  margin: 0;
  font-size: 1rem;
}

.feature-list p {
  margin: 0.34rem 0 0;
  color: var(--text-muted);
  line-height: 1.42;
}

.feature-list-compact li {
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
}

.plain-copy {
  margin: 0.62rem 0 0;
  color: var(--text-muted);
  line-height: 1.45;
}

.plain-copy a,
.helper-text a {
  color: var(--text);
}

.screenshots-showcase {
  overflow: visible;
  border-bottom: 0;
  padding-bottom: 0.35rem;
}

.screenshot-grid {
  margin-top: 1.55rem;
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
  align-items: center;
}

.screenshot-item {
  margin: 0;
  position: relative;
  width: min(1120px, 100%);
}

.screenshot-item:nth-child(odd) {
  align-self: center;
  transform: none;
}

.screenshot-item:nth-child(even) {
  align-self: center;
  transform: none;
}

.screenshot-title {
  margin: 0 0 2.6rem;
  font-family: "Bangers", "Comic Sans MS", cursive;
  font-size: clamp(2rem, 4.2vw, 3.5rem);
  letter-spacing: 0.04em;
  line-height: 0.95;
  text-transform: uppercase;
  color: color-mix(in oklab, var(--accent) 74%, var(--text) 26%);
}

.section-block.no-divider {
  border-bottom: 0;
}

.downloads-page .hero-downloads {
  border-bottom-color: color-mix(in oklab, var(--accent) 62%, var(--line-strong) 38%);
}

.downloads-card {
  padding: 1rem 1rem 1.18rem;
  border: 1px solid color-mix(in oklab, var(--accent) 36%, var(--line) 64%);
  border-left: 3px solid color-mix(in oklab, var(--accent) 62%, var(--line) 38%);
  background: transparent;
}

.downloads-card .section-head h2 {
  color: color-mix(in oklab, var(--accent) 64%, var(--text) 36%);
}

.downloads-card .platform-card {
  border-top-color: color-mix(in oklab, var(--accent) 50%, var(--line-strong) 50%);
}

.downloads-card .command-box {
  border-color: color-mix(in oklab, var(--accent) 38%, var(--line-strong) 62%);
}

.screenshot-visual {
  position: relative;
}

.screenshot-visual::before,
.screenshot-visual::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.screenshot-visual::before {
  left: -0.6rem;
  top: -0.6rem;
  width: 54px;
  height: 18px;
  border-top: 3px solid color-mix(in oklab, var(--accent) 78%, var(--line) 22%);
  border-left: 3px solid color-mix(in oklab, var(--accent) 78%, var(--line) 22%);
  transform: none;
}

.screenshot-visual::after {
  right: -0.62rem;
  bottom: -0.62rem;
  width: 58px;
  height: 20px;
  border-right: 3px solid color-mix(in oklab, var(--accent) 72%, var(--line) 28%);
  border-bottom: 3px solid color-mix(in oklab, var(--accent) 72%, var(--line) 28%);
  transform: none;
}

.screenshot-item img {
  display: block;
  width: 100%;
  height: auto;
  border: 0;
  box-shadow: none;
  transition: transform 260ms ease;
}

.screenshot-item:hover {
  z-index: 2;
}

.screenshot-item:hover img {
  transform: scale(1.01);
}

.command-grid {
  margin-top: 0.92rem;
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.command-box {
  margin: 0;
  border: 1px solid #2e2e2e;
  background: #0f0f0f;
  color: #f3f3f3;
  padding: 0.65rem 0.72rem;
  overflow-x: auto;
  flex: 1 1 auto;
  min-width: 0;
}

.command-box code {
  font-family: "JetBrains Mono", "Cascadia Code", "Fira Code", "SFMono-Regular", Consolas, monospace;
  font-size: 0.9rem;
  white-space: nowrap;
  color: #f3f3f3;
}

.platform-grid {
  margin-top: 0.9rem;
  display: grid;
  gap: 0.95rem;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.command-row {
  margin-top: 0.6rem;
  display: flex;
  align-items: stretch;
  gap: 0.52rem;
}

.copy-btn {
  border: 1px solid var(--line);
  background: var(--bg-elevated);
  color: var(--text);
  font-family: inherit;
  font-size: 0.86rem;
  font-weight: 600;
  padding: 0 0.78rem;
  min-width: 76px;
  cursor: pointer;
  transition: background-color 140ms ease, border-color 140ms ease;
}

.copy-btn:hover {
  border-color: var(--line-strong);
  background: color-mix(in oklab, var(--bg-elevated) 84%, white 16%);
}

.copy-btn.copied {
  border-color: color-mix(in oklab, var(--ok) 60%, var(--line) 40%);
  color: var(--ok);
}

.platform-card {
  padding: 0.82rem 0;
  border-top: 2px solid var(--line-strong);
}

.platform-card h3 {
  margin: 0;
}

.platform-copy {
  margin: 0.4rem 0 0.58rem;
  color: var(--text-muted);
}

.download-option-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.66rem;
  padding: 0.62rem 0;
  border-top: 1px solid var(--line);
}

.option-label {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
}

.option-label strong {
  font-size: 0.95rem;
}

.option-label small {
  color: var(--text-muted);
  font-size: 0.82rem;
  word-break: break-word;
}

.inline-actions {
  margin-top: 0.56rem;
  display: flex;
  gap: 0.48rem;
  flex-wrap: wrap;
}

.accent-rule {
  border-bottom-color: color-mix(in oklab, var(--accent) 60%, var(--line) 40%);
}

.pumpkin-actions {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  flex-wrap: wrap;
}

.pumpkin-logo {
  width: 74px;
  height: auto;
}

.pumpkin-actions-buttons {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.site-footer {
  margin-top: 2rem;
}

.minimal-footer {
  border-top: 1px solid var(--line-strong);
  padding-top: 0.72rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
}

.minimal-footer p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.minimal-footer p a {
  color: var(--text);
}

.footer-github {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  color: var(--text);
  text-decoration: none;
  opacity: 0.86;
  transition: opacity 140ms ease, transform 160ms ease;
}

.footer-github svg {
  width: 1.1rem;
  height: 1.1rem;
  fill: currentColor;
}

.footer-github:hover {
  opacity: 1;
  transform: translateY(-1px);
}

.reveal {
  opacity: 0;
  transform: translateY(16px);
  filter: blur(2px);
  transition:
    opacity 420ms ease,
    transform 420ms ease,
    filter 420ms ease;
  transition-delay: var(--reveal-delay, 0ms);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
  filter: none;
}

@media (max-width: 1000px) {
  .page-shell {
    width: min(1040px, calc(100% - 1.4rem));
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-pumpkin {
    width: 90px;
  }

  .screenshot-item,
  .screenshot-item:nth-child(odd),
  .screenshot-item:nth-child(even) {
    width: min(980px, 100%);
    transform: none;
    align-self: stretch;
  }

  .screenshot-visual::before,
  .screenshot-visual::after {
    display: none;
  }
}

@media (max-width: 760px) {
  .page-shell {
    width: calc(100% - 1rem);
    margin-top: 0.62rem;
  }

  .window-bar {
    top: 0.28rem;
    padding: 0.54rem 0.62rem;
  }

  .top-nav a,
  .top-nav .theme-toggle {
    font-size: 0.88rem;
    padding: 0.28rem 0.46rem;
  }

  .top-nav .theme-toggle {
    width: 1.92rem;
    height: 1.92rem;
  }

  .section-block,
  .card-section {
    padding-bottom: 0.72rem;
  }

  .command-grid,
  .platform-grid {
    grid-template-columns: 1fr;
  }

  .download-option-row {
    flex-direction: column;
    align-items: flex-start;
  }

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

  .command-row .copy-btn {
    width: 100%;
    min-height: 2.2rem;
  }

  .download-option-row .btn {
    width: 100%;
  }

  .minimal-footer {
    flex-direction: row;
    align-items: center;
  }
}
