/* VibeCording LP — self-contained styles (no external fonts / CDN) */

/* ---------- Design tokens (light default) ---------- */
:root {
  --bg: #f7f7fb;
  --bg-alt: #eef0f7;
  --surface: #ffffff;
  --surface-2: #f2f3f9;
  --border: #e2e4ee;
  --text: #1c1d28;
  --text-muted: #565a6f;
  --accent: #6d5cff;
  --accent-2: #a855f7;
  --accent-strong: #5a49e6;
  --accent-contrast: #ffffff;
  --code-bg: #1e2030;
  --code-text: #e6e7f2;
  --code-border: #2c2f45;
  --shadow: 0 1px 2px rgba(24, 26, 48, 0.06), 0 8px 24px rgba(24, 26, 48, 0.07);
  --shadow-hover: 0 4px 10px rgba(24, 26, 48, 0.10), 0 16px 40px rgba(24, 26, 48, 0.12);
  --radius: 14px;
  --radius-sm: 9px;
  --maxw: 1080px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Sans",
    "Hiragino Kaku Gothic ProN", "Noto Sans JP", Meiryo, system-ui, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
    "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e0f18;
    --bg-alt: #141622;
    --surface: #191b28;
    --surface-2: #202333;
    --border: #2a2d40;
    --text: #edeef5;
    --text-muted: #a2a6bd;
    --accent: #8b7bff;
    --accent-2: #c084fc;
    --accent-strong: #a394ff;
    --accent-contrast: #14121f;
    --code-bg: #10121c;
    --code-text: #e6e7f2;
    --code-border: #262a3e;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 10px 30px rgba(0, 0, 0, 0.35);
    --shadow-hover: 0 6px 16px rgba(0, 0, 0, 0.45), 0 20px 50px rgba(0, 0, 0, 0.45);
  }
}

/* Respect explicit theme toggles if a host stamps data-theme */
:root[data-theme="dark"] {
  --bg: #0e0f18;
  --bg-alt: #141622;
  --surface: #191b28;
  --surface-2: #202333;
  --border: #2a2d40;
  --text: #edeef5;
  --text-muted: #a2a6bd;
  --accent: #8b7bff;
  --accent-2: #c084fc;
  --accent-strong: #a394ff;
  --accent-contrast: #14121f;
  --code-bg: #10121c;
  --code-text: #e6e7f2;
  --code-border: #262a3e;
}
:root[data-theme="light"] {
  --bg: #f7f7fb;
  --bg-alt: #eef0f7;
  --surface: #ffffff;
  --surface-2: #f2f3f9;
  --border: #e2e4ee;
  --text: #1c1d28;
  --text-muted: #565a6f;
  --accent: #6d5cff;
  --accent-2: #a855f7;
  --accent-strong: #5a49e6;
  --accent-contrast: #ffffff;
  --code-bg: #1e2030;
  --code-text: #e6e7f2;
  --code-border: #2c2f45;
}

/* ---------- Base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    transition: none !important;
  }
}

a {
  color: var(--accent);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

code {
  font-family: var(--mono);
  font-size: 0.9em;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 0.08em 0.4em;
}

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 20px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: var(--accent-contrast);
  padding: 10px 16px;
  border-radius: 0 0 8px 0;
  z-index: 100;
}
.skip-link:focus {
  left: 0;
}

/* Visible focus for keyboard users */
a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 6px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 62px;
  gap: 16px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
}
.brand:hover {
  text-decoration: none;
}
.brand-mark {
  display: inline-flex;
}
.brand-name {
  font-size: 1.12rem;
  letter-spacing: 0.2px;
}
.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
}
.site-nav a {
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 500;
}
.site-nav a:hover {
  color: var(--text);
  text-decoration: none;
}
.nav-cta {
  padding: 7px 15px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text) !important;
  background: var(--surface);
}
.nav-cta:hover {
  border-color: var(--accent);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(64px, 12vw, 128px) 0 clamp(56px, 9vw, 100px);
  background:
    radial-gradient(1100px 480px at 50% -12%, color-mix(in srgb, var(--accent) 26%, transparent), transparent 70%),
    var(--bg);
}
.hero-inner {
  text-align: center;
  max-width: 800px;
}
.eyebrow {
  display: inline-block;
  margin: 0 0 18px;
  padding: 6px 14px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.4px;
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  border-radius: 999px;
}
.hero h1 {
  margin: 0 0 20px;
  font-size: clamp(2.1rem, 6vw, 3.6rem);
  line-height: 1.18;
  letter-spacing: -0.02em;
  font-weight: 800;
}
.hero-sub {
  margin: 0 auto 30px;
  max-width: 640px;
  font-size: clamp(1.02rem, 2.4vw, 1.2rem);
  color: var(--text-muted);
}
.hero-sub code {
  color: var(--text);
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
  margin-bottom: 20px;
}
.hero-meta {
  margin: 0;
  font-size: 0.86rem;
  color: var(--text-muted);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.18s ease, background 0.18s ease,
    border-color 0.18s ease;
}
.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
}
.btn-primary {
  color: var(--accent-contrast);
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: var(--shadow);
}
.btn-primary:hover {
  box-shadow: var(--shadow-hover);
}
.btn-ghost {
  color: var(--text);
  background: var(--surface);
  border-color: var(--border);
}
.btn-ghost:hover {
  border-color: var(--accent);
}
.btn-icon {
  flex: none;
}

/* ---------- Sections ---------- */
.section {
  padding: clamp(56px, 9vw, 96px) 0;
}
.section-alt {
  background: var(--bg-alt);
  border-block: 1px solid var(--border);
}
.section-title {
  margin: 0 0 12px;
  text-align: center;
  font-size: clamp(1.6rem, 4vw, 2.3rem);
  font-weight: 800;
  letter-spacing: -0.01em;
}
.section-lead {
  margin: 0 auto 44px;
  max-width: 620px;
  text-align: center;
  color: var(--text-muted);
  font-size: 1.02rem;
}

/* ---------- Cards ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* ---------- Features ---------- */
.feature-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.feature-card {
  padding: 28px 26px;
}
.feature-card h3 {
  margin: 16px 0 8px;
  font-size: 1.18rem;
  font-weight: 700;
}
.feature-card p {
  margin: 0;
  color: var(--text-muted);
}
.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 13%, transparent);
}

/* ---------- Steps ---------- */
.steps {
  list-style: none;
  margin: 0 0 30px;
  padding: 0;
  display: grid;
  gap: 18px;
}
.step-card {
  padding: 22px 24px;
}
.step-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}
.step-num {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  font-weight: 700;
  color: var(--accent-contrast);
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
}
.step-head h3 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 700;
}
.step-note {
  margin: 12px 0 0;
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ---------- Code block ---------- */
.code-block {
  position: relative;
  display: flex;
  align-items: stretch;
  background: var(--code-bg);
  border: 1px solid var(--code-border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.code-block pre {
  margin: 0;
  padding: 14px 96px 14px 16px;
  overflow-x: auto;
  flex: 1;
}
.code-block code {
  background: none;
  border: none;
  padding: 0;
  color: var(--code-text);
  font-size: 0.9rem;
  white-space: pre;
}
.copy-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 6px 12px;
  font-family: var(--font);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--code-text);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 7px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.copy-btn:hover {
  background: rgba(255, 255, 255, 0.16);
}
.copy-btn.copied {
  color: #0e0f18;
  background: #7ee787;
  border-color: #7ee787;
}

.install-oneliner {
  max-width: 760px;
  margin-inline: auto;
}
.oneliner-label {
  margin: 0 0 10px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
}

/* ---------- Tools ---------- */
.tool-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.tool-card {
  padding: 28px 24px;
  text-align: center;
}
.tool-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  margin-bottom: 14px;
  border-radius: 14px;
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 13%, transparent);
}
.tool-card h3 {
  margin: 0 0 8px;
  font-size: 1.16rem;
  font-weight: 700;
}
.tool-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.96rem;
}

/* ---------- CTA band ---------- */
.cta-band {
  text-align: center;
}
.cta-inner {
  max-width: 680px;
  padding: clamp(36px, 6vw, 56px) 28px;
  border-radius: 22px;
  background:
    radial-gradient(700px 300px at 50% -30%, color-mix(in srgb, var(--accent) 30%, transparent), transparent 70%),
    var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.cta-inner h2 {
  margin: 0 0 10px;
  font-size: clamp(1.5rem, 4vw, 2.1rem);
  font-weight: 800;
}
.cta-inner p {
  margin: 0 0 24px;
  color: var(--text-muted);
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 44px 0 28px;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  justify-content: space-between;
  align-items: flex-start;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}
.footer-brand .brand-name {
  font-size: 1.1rem;
  font-weight: 700;
}
.footer-tagline {
  margin: 6px 0 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}
.footer-nav a {
  color: var(--text-muted);
  font-size: 0.94rem;
}
.footer-nav a:hover {
  color: var(--text);
}
.footer-bottom {
  padding-top: 20px;
}
.footer-bottom p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.86rem;
}

/* ---------- Responsive ---------- */
@media (max-width: 720px) {
  .feature-grid {
    grid-template-columns: 1fr;
  }
  .tool-grid {
    grid-template-columns: 1fr;
  }
  .site-nav {
    gap: 14px;
  }
  .site-nav a:not(.nav-cta) {
    display: none;
  }
}

@media (max-width: 420px) {
  .btn {
    width: 100%;
    justify-content: center;
  }
  .code-block pre {
    padding-right: 16px;
    padding-top: 44px;
  }
}
