/* Midnight Focus — calm dark theme for a screen-dimming utility */

:root {
  --bg-deep: #0a0e14;
  --bg-surface: #121820;
  --bg-elevated: #1a2230;
  --bg-card: #151c28;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);
  --text: #e8ecf2;
  --text-muted: #8b96a8;
  --text-dim: #5c6678;
  --accent: #e8b86d;
  --accent-hover: #f0c87e;
  --accent-glow: rgba(232, 184, 109, 0.25);
  --accent-soft: rgba(232, 184, 109, 0.12);
  --monitor-active: #2a6fdb;
  --monitor-glow: rgba(42, 111, 219, 0.15);
  --radius: 12px;
  --radius-lg: 20px;
  --font: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg-deep);
  -webkit-font-smoothing: antialiased;
}

.ambient-glow {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 80% 50% at 20% -10%, var(--monitor-glow), transparent 50%),
    radial-gradient(ellipse 60% 40% at 85% 20%, var(--accent-glow), transparent 45%),
    radial-gradient(ellipse 50% 30% at 50% 100%, rgba(26, 34, 48, 0.8), transparent);
}

.container {
  width: min(1120px, calc(100% - 2.5rem));
  margin-inline: auto;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
  background: rgba(10, 14, 20, 0.85);
  backdrop-filter: blur(12px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  font-size: 1.05rem;
}

.logo-icon {
  color: var(--accent);
}

.logo-text {
  line-height: 1.2;
}

.logo-sub {
  color: var(--text-muted);
  font-weight: 500;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.25rem;
  border-radius: 10px;
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}

.btn-primary {
  color: var(--bg-deep);
  background: var(--accent);
  box-shadow: 0 0 24px var(--accent-glow);
}

.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 28px var(--accent-glow);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

.btn-lg {
  padding: 0.85rem 1.5rem;
  font-size: 1rem;
}

.btn-ghost {
  color: var(--text-muted);
  background: transparent;
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  color: var(--text);
  border-color: var(--border-strong);
  background: rgba(255, 255, 255, 0.04);
}

.btn-donate {
  white-space: nowrap;
  background: linear-gradient(135deg, rgba(232, 184, 109, 0.18) 0%, rgba(232, 184, 109, 0.08) 100%);
  border-color: rgba(232, 184, 109, 0.35);
  color: var(--accent);
  box-shadow: 0 0 32px var(--accent-glow);
}

.btn-donate:not([aria-disabled="true"]):hover {
  background: linear-gradient(135deg, rgba(232, 184, 109, 0.28) 0%, rgba(232, 184, 109, 0.14) 100%);
  transform: translateY(-1px);
}

.btn-donate[aria-disabled="true"] {
  opacity: 0.85;
  cursor: default;
  pointer-events: none;
}

/* Download counter */

.download-counter {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.download-counter strong,
.download-counter .counter-value {
  color: var(--text);
  font-weight: 700;
}

.download-counter--header {
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
}

.download-counter--header svg {
  color: var(--accent);
  flex-shrink: 0;
}

.download-counter--hero {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.1rem;
  padding: 0.65rem 1rem;
  border-radius: 10px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
}

.download-counter--hero .counter-value {
  font-size: 1.35rem;
  line-height: 1.2;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.download-counter--hero .counter-label {
  font-size: 0.78rem;
  color: var(--text-dim);
}

[data-download-count][data-loading] {
  opacity: 0.5;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
}

/* Hero */

.hero {
  position: relative;
  z-index: 1;
  padding-block: 4.5rem 5rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.eyebrow {
  margin: 0 0 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

h1 {
  margin: 0 0 1.25rem;
  font-size: clamp(2.25rem, 5vw, 3.25rem);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.02em;
}

.text-glow {
  color: var(--accent);
  text-shadow: 0 0 40px var(--accent-glow);
}

.lead {
  margin: 0 0 2rem;
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 34ch;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
}

.file-note {
  font-size: 0.85rem;
  color: var(--text-dim);
}

/* Dual-monitor illustration */

.hero-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.desk-scene {
  display: flex;
  gap: 1.5rem;
  align-items: flex-end;
  padding: 2rem 2.5rem 1.5rem;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow:
    0 24px 48px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.monitor {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.monitor-bezel {
  padding: 0.45rem;
  background: linear-gradient(160deg, #2a3344 0%, #1a2030 100%);
  border-radius: 8px;
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.monitor-screen {
  width: 148px;
  height: 96px;
  border-radius: 4px;
  overflow: hidden;
  position: relative;
  background: linear-gradient(145deg, #1e3a5f 0%, #0f2440 100%);
}

.monitor--active .monitor-screen {
  box-shadow: inset 0 0 30px rgba(42, 111, 219, 0.3);
}

.fake-window {
  position: absolute;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.fake-window--1 {
  top: 10px;
  left: 10px;
  right: 24px;
  height: 38px;
}

.fake-window--2 {
  top: 54px;
  left: 10px;
  width: 60%;
  height: 28px;
  background: rgba(232, 184, 109, 0.15);
  border-color: rgba(232, 184, 109, 0.2);
}

.fake-taskbar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 14px;
  background: rgba(0, 0, 0, 0.45);
}

.monitor-screen--black {
  background: #050608;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.8);
}

.dimmed-hint {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.15);
}

.monitor-stand {
  width: 36px;
  height: 18px;
  background: linear-gradient(180deg, #2a3344, #1a2030);
  border-radius: 0 0 4px 4px;
  position: relative;
}

.monitor-stand::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 50%;
  transform: translateX(-50%);
  width: 56px;
  height: 4px;
  background: #1a2030;
  border-radius: 2px;
}

.monitor-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--monitor-active);
}

.monitor-label--dimmed {
  color: var(--text-dim);
}

.visual-caption {
  margin: 1rem 0 0;
  font-size: 0.85rem;
  color: var(--text-dim);
  text-align: center;
}

/* Benefits */

.benefits {
  position: relative;
  z-index: 1;
  padding-block: 4rem;
  background: var(--bg-surface);
  border-block: 1px solid var(--border);
}

.section-title {
  margin: 0 0 2.5rem;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  text-align: center;
  letter-spacing: -0.02em;
}

.benefit-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.benefit-card {
  padding: 1.75rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.2s;
}

.benefit-card:hover {
  border-color: var(--border-strong);
}

.benefit-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-bottom: 1rem;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent);
}

.benefit-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.1rem;
  font-weight: 600;
}

.benefit-card p {
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* Preview / screenshot */

.preview {
  position: relative;
  z-index: 1;
  padding-block: 5rem;
}

.preview-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.preview-copy .section-title {
  text-align: left;
  margin-bottom: 1rem;
}

.preview-copy > p {
  margin: 0 0 1.5rem;
  color: var(--text-muted);
}

.feature-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.feature-list li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.65rem;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.feature-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

kbd {
  display: inline-block;
  padding: 0.15em 0.45em;
  font-family: var(--mono);
  font-size: 0.82em;
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  border-radius: 5px;
  color: var(--text);
}

.screenshot-frame {
  margin: 0;
  padding: 0.75rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
}

.screenshot-frame img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
}

.screenshot-frame figcaption {
  margin-top: 0.75rem;
  font-size: 0.8rem;
  color: var(--text-dim);
  text-align: center;
}

/* Install steps */

.install {
  position: relative;
  z-index: 1;
  padding-block: 5rem;
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
}

.install-steps {
  margin: 0 0 2.5rem;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 1.25rem;
  max-width: 640px;
  margin-inline: auto;
}

.install-steps li {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  padding: 1.25rem 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.step-num {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 700;
  font-size: 0.95rem;
}

.install-steps strong {
  display: block;
  margin-bottom: 0.25rem;
  font-size: 1.05rem;
}

.install-steps p {
  margin: 0;
  font-size: 0.92rem;
  color: var(--text-muted);
}

.install-steps code {
  font-family: var(--mono);
  font-size: 0.88em;
  padding: 0.1em 0.35em;
  background: var(--bg-elevated);
  border-radius: 4px;
  color: var(--accent);
}

.install-cta {
  text-align: center;
}

/* Support banner */

.support-banner {
  position: relative;
  z-index: 1;
  padding-block: 0 4rem;
  margin-top: -1.5rem;
}

.support-banner-inner {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 1.5rem 2rem;
  align-items: center;
  padding: 1.75rem 2rem;
  background: linear-gradient(120deg, rgba(232, 184, 109, 0.14) 0%, var(--bg-card) 45%, var(--bg-elevated) 100%);
  border: 1px solid rgba(232, 184, 109, 0.28);
  border-radius: var(--radius-lg);
  box-shadow:
    0 20px 48px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.support-banner-glow {
  position: absolute;
  top: -40%;
  right: -10%;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, var(--accent-glow), transparent 70%);
  pointer-events: none;
}

.support-banner-icon {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: rgba(232, 184, 109, 0.2);
  color: var(--accent);
  flex-shrink: 0;
}

.support-banner-copy {
  position: relative;
}

.support-banner-eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.support-banner-copy h2 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.2rem, 2.5vw, 1.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.support-banner-copy > p {
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.55;
  max-width: 52ch;
}

.support-banner-action {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  flex-shrink: 0;
}

.donate-note {
  margin: 0.65rem 0 0;
  font-size: 0.75rem;
  color: var(--text-dim);
  max-width: 16ch;
}

/* Footer */

.site-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
  padding-block: 1.5rem;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.875rem;
  color: var(--text-dim);
}

.footer-inner > p a {
  color: var(--text-muted);
  text-decoration: none;
}

.footer-inner > p a:hover {
  color: var(--accent);
}

.footer-links {
  display: flex;
  gap: 1.25rem;
}

.footer-inner a {
  color: var(--text-muted);
  text-decoration: none;
}

.footer-inner a:hover {
  color: var(--accent);
}

/* Responsive */

@media (max-width: 900px) {
  .hero-grid,
  .preview-grid {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    order: -1;
  }

  .lead {
    max-width: none;
  }

  .benefit-grid {
    grid-template-columns: 1fr;
  }

  .preview-copy .section-title {
    text-align: center;
  }

  .desk-scene {
    padding: 1.5rem;
    gap: 1rem;
  }

  .monitor-screen {
    width: 120px;
    height: 78px;
  }

  .support-banner-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .support-banner-icon {
    margin-inline: auto;
  }

  .support-banner-copy > p {
    max-width: none;
  }

  .download-counter--header {
    display: none;
  }
}

@media (max-width: 600px) {
  .header-inner {
    flex-wrap: wrap;
    gap: 0.75rem;
  }

  .header-actions {
    width: 100%;
    justify-content: flex-end;
  }
}

@media (max-width: 480px) {
  .desk-scene {
    flex-direction: column;
    align-items: center;
  }

  .header-actions .btn-ghost {
    display: none;
  }

  .hero-meta {
    flex-direction: column;
    align-items: flex-start;
  }
}
