/* Canonical stylesheet entrypoint: loaded from /index.html via <link rel="stylesheet" href="/styles.css">. */

:root {
  --fg: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --line-strong: #cbd5e1;
  --bg: #ffffff;
  --soft: #f8fafc;
  --dark: #0f172a;

  --accent: #3b82f6;
  --accent-strong: #2563eb;
  --accent-soft: #eff6ff;

  --gradient-start: #0f172a;
  --gradient-end: #1e293b;
  --focus-ring: #0f172a;
  --focus-ring-on-dark: #f8fafc;

  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06), 0 6px 16px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 10px 28px rgba(15, 23, 42, 0.1), 0 2px 6px rgba(15, 23, 42, 0.06);
  --shadow-lg: 0 14px 36px rgba(15, 23, 42, 0.14), 0 4px 10px rgba(15, 23, 42, 0.08);

  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 16px;

  --hero-pad-top: 128px;
  --hero-pad-bottom: 56px;
  --section-pad-top: 64px;
  --nav-cta-min-height: 44px;
  --nav-cta-pad-x: 24px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--fg);
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

a:focus-visible,
.btn:focus-visible,
.nav-cta:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 3px;
}

.btn-primary:focus-visible,
.btn-outline:focus-visible,
.nav-cta:focus-visible {
  outline-color: var(--focus-ring-on-dark);
}

section {
  scroll-margin-top: 92px;
}

/* Navigation */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.91));
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(148, 163, 184, 0.28);
  box-shadow: var(--shadow-sm);
  z-index: 100;
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.logo {
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-mark {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 6px 16px rgba(15, 23, 42, 0.18);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  max-width: 740px;
  flex-wrap: nowrap;
}

.nav-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  padding: 10px 0;
  position: relative;
  transition: color 0.2s ease;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent-strong));
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.2s ease;
  opacity: 0.9;
}

.nav-links a:hover {
  color: var(--fg);
}

.nav-links a:hover::after,
.nav-links a:focus-visible::after {
  transform: scaleX(1);
}

.nav-links a.nav-cta::after {
  display: none;
}

.nav-cta {
  display: inline-flex;
  align-self: center;
  align-items: center;
  justify-content: center;
  min-height: var(--nav-cta-min-height);
  padding: 0 22px;
  background: var(--dark);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  min-width: 104px;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.14);
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.nav-cta:hover {
  background: #1e293b;
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.18);
}

.nav-cta:active {
  transform: translateY(0);
}

/* Hero */
.hero {
  padding: var(--hero-pad-top) 24px var(--hero-pad-bottom);
  text-align: center;
  background-image: linear-gradient(180deg, var(--soft) 0%, var(--bg) 100%),
    radial-gradient(circle at 1px 1px, rgba(15, 23, 42, 0.06) 1px, transparent 0);
  background-size: 100% 100%, 24px 24px;
}

.hero-inner {
  max-width: 900px;
  margin: 0 auto;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px 6px 8px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 100px;
  box-shadow: var(--shadow-sm);
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 24px;
}

.badge-dot {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
}

h1 {
  font-size: clamp(34px, 5vw, 56px);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

.hero-sub {
  font-size: clamp(17px, 2.1vw, 20px);
  color: var(--muted);
  max-width: 66ch;
  margin: 0 auto 32px;
  line-height: 1.75;
}

.hero-footnote {
  font-size: 13px;
  color: var(--muted);
  opacity: 0.8;
  max-width: 68ch;
  margin: 18px auto 0;
  line-height: 1.65;
}

.hero-ctas {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 24px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  font-size: 15px;
  font-weight: 600;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-strong);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-secondary {
  background: #fff;
  border-color: var(--line);
  color: var(--fg);
}

.btn-secondary:hover {
  border-color: var(--line-strong);
  background: var(--soft);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

/* Shared terminal / code-block styles */
.terminal {
  max-width: 760px;
  margin: 0 auto;
  text-align: left;
  background: linear-gradient(180deg, #0b1220 0%, #0b1220 72%, #111c31 100%);
  border: 1px solid rgba(148, 163, 184, 0.32);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.terminal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 15px;
  background: rgba(15, 23, 42, 0.5);
  border-bottom: 1px solid rgba(226, 232, 240, 0.16);
}

.code-header {
  display: flex;
  gap: 6px;
}

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

.code-dot:nth-child(1) {
  background: #ef4444;
}

.code-dot:nth-child(2) {
  background: #eab308;
}

.code-dot:nth-child(3) {
  background: #22c55e;
}

.terminal-title {
  font-size: 12px;
  color: rgba(226, 232, 240, 0.78);
  font-weight: 500;
}

.terminal pre {
  margin: 0;
  padding: 18px 20px 20px;
  font-size: 13px;
  line-height: 1.7;
  color: #e2e8f0;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(148, 163, 184, 0.45) transparent;
  -webkit-overflow-scrolling: touch;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

.terminal pre::-webkit-scrollbar {
  height: 8px;
}

.terminal pre::-webkit-scrollbar-track {
  background: transparent;
}

.terminal pre::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.45);
  border-radius: 999px;
}

/* Terminal syntax classes (used in both blocks) */
.t-comment {
  color: rgba(148, 163, 184, 0.75);
}

.t-cmd {
  color: #93c5fd;
}

.t-flag {
  color: #a5b4fc;
}

.t-path {
  color: #4ade80;
}

.t-prompt {
  color: rgba(226, 232, 240, 0.7);
}

/* Sections */
.section {
  padding: var(--section-pad-top) 24px 96px;
  max-width: 1100px;
  margin: 0 auto;
}

#features {
  border-top: 1px solid rgba(148, 163, 184, 0.24);
}

.section-header {
  text-align: center;
  margin-bottom: 56px;
}

.section-title {
  font-size: clamp(28px, 4vw, 38px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

.section-desc {
  font-size: 17px;
  color: var(--muted);
  max-width: 68ch;
  margin: 0 auto;
  line-height: 1.75;
}

/* Features grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 22px;
}

.feature-card {
  background: linear-gradient(180deg, #ffffff 0%, #ffffff 70%, #fbfdff 100%);
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: var(--radius-md);
  padding: 26px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05), 0 7px 18px rgba(15, 23, 42, 0.04);
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease, background-color 0.25s ease;
}

.feature-card:hover {
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.09), 0 4px 10px rgba(59, 130, 246, 0.08);
  border-color: rgba(59, 130, 246, 0.45);
  transform: translateY(-2px);
}

.feature-card:active {
  transform: translateY(-1px);
}

.feature-card:focus-within {
  border-color: rgba(59, 130, 246, 0.65);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.09), 0 4px 10px rgba(59, 130, 246, 0.08);
}

.feature-icon {
  width: 44px;
  height: 44px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: var(--fg);
}

.feature-icon svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
}

.feature-card h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.68;
}

/* Product Section */
.product-section {
  background: var(--soft);
  padding: 96px 24px;
}

.product-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.product-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 52px;
  align-items: center;
}

.product-content h2 {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.product-content > p {
  font-size: 16px;
  color: var(--muted);
  margin-bottom: 24px;
  line-height: 1.75;
  max-width: 64ch;
}

.product-list {
  list-style: none;
}

.product-list li {
  display: flex;
  gap: 12px;
  margin-bottom: 14px;
  font-size: 15px;
  color: var(--fg);
  line-height: 1.55;
}

.check-icon {
  width: 20px;
  height: 20px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
}

.check-icon svg {
  width: 12px;
  height: 12px;
  stroke: currentColor;
}

/* Specs */
.specs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  margin-top: 36px;
}

.spec-item {
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.spec-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 4px;
}

.spec-label {
  font-size: 12px;
  color: var(--muted);
}

/* CTA */
.cta-section {
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
  padding: 78px 24px;
  text-align: center;
  color: #fff;
}

.cta-inner {
  max-width: 600px;
  margin: 0 auto;
}

.cta-section h2 {
  font-size: clamp(24px, 4vw, 32px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.cta-section p {
  font-size: 16px;
  line-height: 1.75;
  opacity: 0.88;
  margin-bottom: 30px;
}

.cta-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-white {
  background: #fff;
  color: var(--dark);
}

.btn-white:hover {
  background: #f1f5f9;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-outline {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  box-shadow: none;
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.5);
  transform: translateY(-1px);
}

/* Footer */
footer {
  background: var(--soft);
  padding: 44px 24px;
  border-top: 1px solid var(--line);
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 32px;
}

.footer-brand {
  max-width: 320px;
}

.footer-brand .logo {
  margin-bottom: 10px;
}

.footer-brand p {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.65;
}

.footer-links {
  display: flex;
  gap: 48px;
  flex-wrap: wrap;
}

.footer-col h4 {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 14px;
  color: var(--fg);
}

.footer-col a {
  display: block;
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 10px;
  transition: color 0.2s ease;
}

.footer-col a:hover {
  color: var(--fg);
}

.footer-bottom {
  max-width: 1100px;
  margin: 32px auto 0;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
  color: var(--muted);
}

/* Mid-width polish */
@media (max-width: 900px) {
  :root {
    --nav-cta-pad-x: 20px;
  }

  .nav-inner {
    padding: 0 18px;
    height: 66px;
  }

  .nav-links {
    gap: 18px;
    max-width: 560px;
  }

  .nav-links a {
    font-size: 13px;
  }

  .section,
  .product-section {
    padding-top: 72px;
    padding-bottom: 84px;
  }

  .section-header {
    margin-bottom: 48px;
  }
}

@media (max-width: 768px) {
  .product-grid {
    grid-template-columns: 1fr;
  }

  .terminal {
    border-radius: var(--radius-md);
  }
}

/* Mobile: keep GitHub + Contact visible */
@media (max-width: 640px) {
  :root {
    --hero-pad-top: 112px;
    --hero-pad-bottom: 48px;
    --section-pad-top: 56px;
    --nav-cta-pad-x: 18px;
  }

  .nav-links a {
    display: none;
  }

  .nav-links a.nav-github {
    display: inline-block;
  }

  .nav-links a.nav-cta {
    display: inline-flex;
  }

  h1 {
    font-size: clamp(32px, 10vw, 44px);
  }

  .hero-sub,
  .section-desc {
    font-size: 16px;
  }
}

/* Entrance animation */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-inner > * {
  animation: fadeUp 0.6s ease-out both;
}

.hero-inner > *:nth-child(1) {
  animation-delay: 0.05s;
}

.hero-inner > *:nth-child(2) {
  animation-delay: 0.12s;
}

.hero-inner > *:nth-child(3) {
  animation-delay: 0.19s;
}

.hero-inner > *:nth-child(4) {
  animation-delay: 0.26s;
}

.hero-inner > *:nth-child(5) {
  animation-delay: 0.33s;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  a,
  .feature-card,
  .btn,
  .nav-links a,
  .nav-links a::after,
  .nav-cta,
  .footer-col a {
    transition: none;
  }

  .btn:hover,
  .feature-card:hover,
  .feature-card:active,
  .nav-cta:hover,
  .btn-white:hover,
  .btn-outline:hover,
  .btn-primary:hover,
  .btn-secondary:hover {
    transform: none;
  }

  .hero-inner > * {
    animation: none;
  }
}
