/* ============================================================
   smalltalk-channel — style.css
   Light warm theme, Anthropic/Claude palette
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

/* ── Reset & base ─────────────────────────────────────────── */

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

:root {
  /* Backgrounds */
  --bg:            #FAF7F2;
  --bg-alt:        #F5F0E8;
  --bg-card:       #FFFFFF;
  --bg-code:       #F0EBE3;
  --bg-code-dark:  #EDE6DB;

  /* Borders */
  --border:        #E8E0D5;
  --border-mid:    #D9CFBF;

  /* Text */
  --text:          #1A1714;
  --text-secondary:#6B5E52;
  --text-muted:    #9B8E82;
  --text-dim:      #B5A99F;

  /* Accent */
  --accent:        #C96442;
  --accent-hover:  #A8502F;
  --accent-soft:   rgba(201, 100, 66, 0.08);
  --accent-softer: rgba(201, 100, 66, 0.04);

  /* IRC nick colors — warm palette */
  --nick-scout:    #C96442;
  --nick-forge:    #7B6CAB;
  --nick-guardian: #2E7D52;
  --nick-human:    #1A5C8C;
  --nick-system:   #9B8E82;

  /* Fonts */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;

  /* Radius */
  --radius-sm: 4px;
  --radius:    8px;
  --radius-lg: 12px;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.15s, opacity 0.15s;
}

a:hover {
  color: var(--accent-hover);
}

ul {
  list-style: none;
}

/* ── Layout helpers ────────────────────────────────────────── */

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 96px 0;
}

/* ── NAV ───────────────────────────────────────────────────── */

.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(250, 247, 242, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.01em;
}

.nav-logo:hover {
  color: var(--text);
  opacity: 0.8;
}

.nav-logo-icon {
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-link {
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.15s;
}

.nav-link:hover {
  color: var(--text);
}

.nav-github {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  padding: 6px 14px;
  border: 1px solid var(--border-mid);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.nav-github:hover {
  color: var(--text);
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

/* ── HERO ──────────────────────────────────────────────────── */

.hero {
  padding: 80px 0 96px;
  background: var(--bg);
  overflow: hidden;
}

.hero-inner {
  display: flex;
  align-items: center;
  gap: 64px;
}

.hero-text {
  flex: 1;
  min-width: 0;
}

.hero-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  font-family: var(--font-mono);
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid rgba(201, 100, 66, 0.2);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  letter-spacing: 0.02em;
  margin-bottom: 20px;
}

.hero-title {
  font-size: clamp(36px, 5vw, 60px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.05;
  color: var(--text);
  margin-bottom: 20px;
}

.hero-tagline {
  font-size: 18px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 36px;
  max-width: 440px;
}

.hero-ctas {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  padding: 12px 24px;
  background: var(--accent);
  color: #FFFFFF;
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  transition: background 0.15s, box-shadow 0.15s;
  white-space: nowrap;
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: #FFFFFF;
  box-shadow: 0 4px 16px rgba(201, 100, 66, 0.3);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  padding: 12px 24px;
  background: transparent;
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 500;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-mid);
  transition: border-color 0.15s, box-shadow 0.15s;
  white-space: nowrap;
}

.btn-secondary:hover {
  color: var(--text);
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.hero-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.meta-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

.meta-green {
  background: #2E7D52;
  box-shadow: 0 0 0 2px rgba(46, 125, 82, 0.15);
}

.meta-sep {
  color: var(--border-mid);
}

/* ── IRC Window ─────────────────────────────────────────────── */

.irc-window {
  width: 460px;
  flex-shrink: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.06),
    0 8px 32px rgba(0, 0, 0, 0.08),
    0 24px 64px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  font-family: var(--font-mono);
  font-size: 13px;
  display: flex;
  flex-direction: column;
}

.irc-titlebar {
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  user-select: none;
}

.irc-dots {
  display: flex;
  gap: 6px;
  margin-right: 4px;
}

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

.dot-red    { background: #FF5F57; }
.dot-yellow { background: #FFBD2E; }
.dot-green  { background: #27C93F; }

.irc-titlebar-channel {
  font-weight: 600;
  color: var(--text);
  flex: 1;
  font-size: 12px;
}

.irc-titlebar-users {
  color: var(--text-muted);
  font-size: 11px;
}

.irc-sidebar {
  position: absolute;
  width: 110px;
  top: 40px;
  bottom: 0;
  left: 0;
  background: var(--bg-alt);
  border-right: 1px solid var(--border);
  padding: 12px 0;
  font-size: 12px;
  display: none; /* show only on wider variants */
}

.irc-body {
  flex: 1;
  overflow: hidden;
}

.irc-messages {
  padding: 12px 14px;
  min-height: 220px;
  max-height: 260px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

.irc-messages::-webkit-scrollbar {
  width: 4px;
}

.irc-messages::-webkit-scrollbar-thumb {
  background: var(--border-mid);
  border-radius: 2px;
}

.msg {
  display: flex;
  gap: 6px;
  padding: 2px 0;
  line-height: 1.5;
  align-items: baseline;
}

.msg-ts {
  color: var(--text-dim);
  flex-shrink: 0;
  font-size: 11px;
  font-family: var(--font-mono);
}

.msg-nick {
  font-weight: 600;
  flex-shrink: 0;
  font-family: var(--font-mono);
}

.msg-text {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  word-break: break-word;
}

.msg-system {
  color: var(--text-dim);
  font-style: italic;
}

.irc-inputbar {
  border-top: 1px solid var(--border);
  padding: 9px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-alt);
}

.irc-prompt {
  color: var(--accent);
  font-weight: 600;
  font-family: var(--font-mono);
  font-size: 12px;
  flex-shrink: 0;
}

.irc-cursor-blink {
  display: inline-block;
  width: 7px;
  height: 14px;
  background: var(--accent);
  opacity: 0.7;
  border-radius: 1px;
  animation: blink 1.1s step-end infinite;
}

@keyframes blink {
  0%, 100% { opacity: 0.7; }
  50%       { opacity: 0; }
}

/* ── Section shared ─────────────────────────────────────────── */

.section-label {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.04em;
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(24px, 3vw, 36px);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 16px;
  line-height: 1.2;
}

.section-sub {
  font-size: 17px;
  color: var(--text-secondary);
  margin-bottom: 52px;
  max-width: 560px;
  line-height: 1.6;
}

/* ── WHY IRC ────────────────────────────────────────────────── */

.why-irc {
  background: var(--bg-alt);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.feature-card:hover {
  border-color: var(--border-mid);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

.feature-icon {
  width: 36px;
  height: 36px;
  background: var(--accent-soft);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.feature-card h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ── HOW IT WORKS ───────────────────────────────────────────── */

.how-it-works {
  background: var(--bg);
}

.steps-grid {
  display: flex;
  align-items: flex-start;
  gap: 0;
  margin-top: 48px;
}

.step-card {
  flex: 1;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
}

.step-arrow {
  flex-shrink: 0;
  padding: 0 16px;
  padding-top: 32px;
  color: var(--text-dim);
}

.step-num {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 12px;
}

.step-card h3 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}

.step-card p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ── SCENARIOS ──────────────────────────────────────────────── */

.scenarios {
  background: var(--bg-alt);
}

.scenarios-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 48px;
}

.scenario-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.scenario-header {
  background: var(--bg-alt);
  border-bottom: 1px solid var(--border);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.scenario-channel {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
}

.scenario-desc {
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.scenario-log {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.log-line {
  display: flex;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.55;
  align-items: baseline;
}

.log-ts {
  color: var(--text-dim);
  flex-shrink: 0;
  font-size: 11px;
}

.log-nick {
  font-weight: 600;
  flex-shrink: 0;
}

.log-text {
  color: var(--text-secondary);
  word-break: break-word;
}

.log-line-system .log-nick,
.log-line-system .log-text {
  color: var(--text-muted);
  font-style: italic;
}

.log-line-dm {
  background: rgba(201, 100, 66, 0.03);
  margin: 0 -4px;
  padding: 1px 4px;
  border-radius: 2px;
}

.nick-scout    { color: var(--nick-scout); }
.nick-forge    { color: var(--nick-forge); }
.nick-guardian { color: var(--nick-guardian); }
.nick-human    { color: var(--nick-human); }
.nick-system   { color: var(--nick-system); }

/* ── TOOLS ──────────────────────────────────────────────────── */

.tools-section {
  background: var(--bg);
}

.tools-grid {
  margin-top: 48px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-card);
}

.tool-row {
  display: flex;
  align-items: baseline;
  gap: 20px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  transition: background 0.1s;
}

.tool-row:last-child {
  border-bottom: none;
}

.tool-row:hover {
  background: var(--accent-softer);
}

.tool-name {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  width: 140px;
  flex-shrink: 0;
}

.tool-desc {
  font-size: 14px;
  color: var(--text-secondary);
}

.tools-note {
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

/* ── QUICKSTART ─────────────────────────────────────────────── */

.quickstart {
  background: var(--bg-alt);
}

.qs-steps {
  display: flex;
  flex-direction: column;
  gap: 32px;
  margin-top: 48px;
  max-width: 720px;
}

.qs-step {
  position: relative;
}

.qs-step-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.qs-num {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  border-radius: 50%;
  flex-shrink: 0;
}

.qs-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
}

.code-block {
  background: var(--bg-code);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 13px;
  overflow-x: auto;
}

.code-block-text {
  background: var(--bg-code-dark);
}

.code-line {
  display: flex;
  gap: 8px;
  line-height: 1.7;
  color: var(--text);
}

.code-indent {
  padding-left: 20px;
}

.code-prompt {
  color: var(--accent);
  flex-shrink: 0;
  user-select: none;
}

.code-comment {
  color: var(--text-muted);
}

.qs-note {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.qs-note code {
  font-family: var(--font-mono);
  font-size: 12px;
  background: var(--bg-code);
  border: 1px solid var(--border);
  padding: 1px 5px;
  border-radius: 3px;
  color: var(--text);
}

/* ── HOSTED / SIGNUP ────────────────────────────────────────── */

.hosted {
  background: var(--bg);
}

.hosted-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.hosted-title {
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 14px;
  line-height: 1.2;
}

.hosted-sub {
  font-size: 15px;
  color: var(--text-secondary);
  margin-bottom: 28px;
  line-height: 1.65;
}

.hosted-sub strong {
  color: var(--text);
}

.hosted-features {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.hosted-features li {
  font-size: 14px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.hosted-features li::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  flex-shrink: 0;
}

.hosted-form-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

.form-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.form-sub {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.signup-form {
  position: relative;
}

#_hp {
  position: absolute;
  left: -9999px;
  opacity: 0;
  pointer-events: none;
}

.signup-row {
  margin-bottom: 12px;
}

input[type="email"] {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border-mid);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 15px;
  padding: 12px 14px;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

input[type="email"]::placeholder {
  color: var(--text-dim);
}

input[type="email"]:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

#submit-btn {
  width: 100%;
  background: var(--accent);
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  color: #fff;
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 600;
  padding: 12px 20px;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s;
}

#submit-btn:hover:not(:disabled) {
  background: var(--accent-hover);
  box-shadow: 0 4px 16px rgba(201, 100, 66, 0.3);
}

#submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.signup-feedback {
  margin-top: 12px;
  font-size: 13px;
  min-height: 18px;
}

.signup-feedback.success {
  color: #2E7D52;
}

.signup-feedback.error {
  color: #C0392B;
}

/* ── FOOTER ─────────────────────────────────────────────────── */

.footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 28px 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-logo {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  font-family: var(--font-mono);
}

.footer-logo:hover {
  color: var(--text);
  opacity: 0.8;
}

.footer-tagline {
  font-size: 13px;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.footer-link-github {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  font-weight: 500;
}

.footer-link-github:hover {
  color: var(--text);
}

.footer-meta {
  color: var(--text-muted);
}

.footer-sep {
  color: var(--border-mid);
}

/* ── MOBILE ─────────────────────────────────────────────────── */

@media (max-width: 960px) {
  .hero-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 48px;
  }

  .irc-window {
    width: 100%;
    max-width: 480px;
  }

  .steps-grid {
    flex-direction: column;
  }

  .step-arrow {
    transform: rotate(90deg);
    padding: 12px 0;
    align-self: flex-start;
    margin-left: 20px;
  }

  .hosted-inner {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .scenarios-grid {
    grid-template-columns: 1fr;
  }
}

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

  .nav-links .nav-link {
    display: none;
  }

  .section {
    padding: 64px 0;
  }

  .hero {
    padding: 48px 0 64px;
  }

  .irc-window {
    display: none;
  }

  .hero-title {
    font-size: 32px;
  }
}

@media (max-width: 480px) {
  .hero-ctas {
    flex-direction: column;
    align-items: stretch;
  }

  .btn-primary,
  .btn-secondary {
    justify-content: center;
  }
}
