/* korFlow download page — dark mode only, no external requests. */

@font-face {
  font-family: 'Sora';
  src: url('./assets/Sora-normal-latin.woff2') format('woff2');
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'DM Sans';
  src: url('./assets/DMSans-normal-latin.woff2') format('woff2');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: dark;

  --void-navy: #0a0e1a;
  --station-dark: #0f1629;
  --console-surface: #161d30;
  --wire-border: #1e2640;

  --orbital-violet: #7c3aed;
  --orbital-violet-light: #a78bfa;
  --signal-cyan: #06b6d4;
  --signal-cyan-light: #22d3ee;

  --text-bright: #f1f5f9;
  --text-cloud: #94a3b8;
  --text-mist: #64748b;

  --font-heading: 'Sora', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --max-width: 640px;
  --side-gutter: 24px;
}

* {
  box-sizing: border-box;
}

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

body {
  background: var(--void-navy);
  color: var(--text-bright);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  min-height: 100vh;
  padding-inline: var(--side-gutter);
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

[hidden] {
  display: none !important;
}

a {
  color: var(--orbital-violet-light);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

:focus-visible {
  outline: 2px solid var(--signal-cyan);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- background: dot grid + radial glow ---------- */

.bg-grid {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    radial-gradient(ellipse 60% 40% at 50% 0%, rgba(124, 58, 237, 0.1), transparent 60%),
    radial-gradient(ellipse 50% 35% at 80% 15%, rgba(6, 182, 212, 0.05), transparent 60%),
    radial-gradient(circle, var(--wire-border) 1px, transparent 1px);
  background-size: auto, auto, 32px 32px;
  background-repeat: no-repeat, no-repeat, repeat;
  opacity: 0.9;
}

@media (prefers-reduced-motion: no-preference) {
  .bg-grid {
    animation: glow-pulse 8s ease-in-out infinite;
  }
}

@keyframes glow-pulse {
  0%,
  100% {
    opacity: 0.75;
  }
  50% {
    opacity: 1;
  }
}

/* ---------- layout shell ---------- */

.site-header,
main,
.site-footer {
  max-width: var(--max-width);
  margin-inline: auto;
}

.site-header {
  padding-block: 28px 8px;
}

.logo-link {
  display: inline-flex;
}

.logo {
  height: 32px;
  width: auto;
}

main {
  padding-block: 8px 48px;
}

/* ---------- hero ---------- */

.hero {
  text-align: center;
  padding-block: 32px 40px;
}

.hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(1.875rem, 6vw, 2.75rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}

.hero h1 .grad {
  background: linear-gradient(135deg, var(--orbital-violet) 0%, var(--signal-cyan-light) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: var(--text-cloud);
  margin: 0 0 32px;
}

.download-area {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  min-height: 118px;
  justify-content: center;
}

.download-status {
  color: var(--text-mist);
  font-size: 0.9375rem;
  margin: 0;
}

.empty-state {
  background: rgba(22, 29, 48, 0.5);
  border: 1px solid var(--wire-border);
  border-radius: 12px;
  padding: 24px 28px;
  max-width: 420px;
  margin: 0;
  color: var(--text-cloud);
  font-size: 0.9375rem;
}

.empty-state strong {
  color: var(--text-bright);
  display: block;
  font-family: var(--font-heading);
  font-size: 1.0625rem;
  margin-bottom: 6px;
}

.download-meta {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-mist);
  text-align: center;
}

.download-meta strong {
  color: var(--text-cloud);
  font-weight: 500;
}

.platform-note {
  margin: 18px auto 0;
  max-width: 420px;
  font-size: 0.875rem;
  color: var(--signal-cyan-light);
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid rgba(6, 182, 212, 0.15);
  border-radius: 8px;
  padding: 10px 16px;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  padding: 14px 28px;
  border-radius: 8px;
  min-height: 44px;
  cursor: pointer;
  border: none;
  transition: box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1), transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
    background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
}

.btn:hover {
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--orbital-violet) 0%, #6d28d9 100%);
  color: #ffffff;
}

.btn-primary:hover {
  box-shadow: 0 0 20px rgba(124, 58, 237, 0.35);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  background: transparent;
  color: var(--orbital-violet-light);
  border: 1px solid rgba(124, 58, 237, 0.25);
}

.btn-secondary:hover {
  background: rgba(124, 58, 237, 0.06);
  border-color: rgba(124, 58, 237, 0.4);
}

@media (prefers-reduced-motion: reduce) {
  .btn,
  .bg-grid,
  .step {
    transition: none !important;
    animation: none !important;
  }
}

/* ---------- steps ---------- */

.steps {
  background: var(--station-dark);
  border-radius: 20px;
  padding: 36px 28px;
  margin-top: 16px;
}

.steps h2 {
  font-family: var(--font-heading);
  font-size: 1.375rem;
  font-weight: 600;
  margin: 0 0 28px;
  text-align: center;
}

.steps-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.step {
  display: flex;
  gap: 18px;
  align-items: flex-start;
}

.step-visual {
  flex: 0 0 auto;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid rgba(6, 182, 212, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--signal-cyan);
}

.step-visual svg {
  width: 30px;
  height: 30px;
}

.step-body {
  flex: 1 1 auto;
}

.step-number {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--text-mist);
  margin-bottom: 4px;
}

.step-body h3 {
  font-family: var(--font-heading);
  font-size: 1.0625rem;
  font-weight: 600;
  margin: 0 0 6px;
}

.step-body p {
  margin: 0 0 8px;
  color: var(--text-cloud);
  font-size: 0.9375rem;
}

.step-body p:last-child {
  margin-bottom: 0;
}

.step-reassurance {
  color: var(--text-mist) !important;
  font-size: 0.875rem !important;
}

/* ---------- connect section ---------- */

.connect {
  margin-top: 24px;
}

.connect-card {
  background: rgba(22, 29, 48, 0.5);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(124, 58, 237, 0.18);
  border-radius: 12px;
  padding: 32px;
  text-align: center;
}

.connect-card h2 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0 0 12px;
}

.connect-instructions {
  color: var(--text-cloud);
  font-size: 0.9375rem;
  margin: 0 0 20px;
}

.connect-hint {
  margin: 14px 0 0;
  font-size: 0.875rem;
  color: var(--text-mist);
}

/* ---------- footer ---------- */

.site-footer {
  padding-block: 32px 40px;
  text-align: center;
  color: var(--text-mist);
  font-size: 0.875rem;
}

.site-footer p {
  margin: 0 0 8px;
}

.site-footer p:last-child {
  margin-bottom: 0;
}

/* ---------- responsive ---------- */

@media (max-width: 480px) {
  :root {
    --side-gutter: 16px;
  }

  .steps {
    padding: 28px 20px;
  }

  .connect-card {
    padding: 24px;
  }

  .step {
    gap: 14px;
  }

  .step-visual {
    width: 48px;
    height: 48px;
  }

  .step-visual svg {
    width: 26px;
    height: 26px;
  }
}
