/* FJ_CLAUDE_BLOG_STYLE */
:root {
  color-scheme: light;
  --paper: #f5f4ed;
  --ink: #141413;
  --muted: #6f685e;
  --line: #ded8c9;
  --card: #fffaf0;
  --accent: #c96442;
  --accent-dark: #98422a;
  --soft: #eadfcd;
  --shadow: 0 24px 70px rgba(94, 63, 43, 0.14);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: radial-gradient(circle at top left, rgba(201, 100, 66, 0.13), transparent 34rem), var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

h1, h2, h3 {
  font-family: Georgia, "Times New Roman", serif;
  letter-spacing: -0.03em;
  line-height: 1.08;
  margin: 0;
}

button, input, textarea, select { font: inherit; }
button, .pill {
  border: 0;
  background: var(--accent);
  color: white;
  border-radius: 999px;
  padding: 0.8rem 1.1rem;
  cursor: pointer;
  font-weight: 760;
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(201, 100, 66, 0.25);
}
button:hover, .pill:hover { background: var(--accent-dark); }
button:disabled { opacity: 0.55; cursor: not-allowed; }
.secondary, .ghost-button, .pill.ghost {
  background: #fff7e8;
  color: var(--accent-dark);
  border: 1px solid var(--line);
  box-shadow: none;
}
.ghost-button { color: var(--muted); }

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1rem clamp(1rem, 4vw, 3rem);
  background: rgba(245, 244, 237, 0.9);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(222, 216, 201, 0.8);
}
.brand { color: var(--ink); font-weight: 900; text-decoration: none; }
nav { display: flex; gap: 0.85rem; flex-wrap: wrap; }
nav a { color: var(--muted); text-decoration: none; font-size: 0.94rem; }
nav a:hover { color: var(--accent-dark); }

.shell {
  width: min(1180px, calc(100% - 2rem));
  margin: 2rem auto 5rem;
}
.card {
  background: color-mix(in srgb, var(--card) 92%, white);
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: clamp(1.2rem, 3vw, 2rem);
  box-shadow: var(--shadow);
}
.hero {
  padding: clamp(2rem, 7vw, 5rem);
  margin-bottom: 1.25rem;
}
.eyebrow { color: var(--accent-dark); text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.76rem; font-weight: 800; }
.hero h1 { font-size: clamp(2.35rem, 7vw, 5.8rem); max-width: 1000px; }
.lead { font-size: clamp(1.05rem, 2vw, 1.35rem); max-width: 860px; color: var(--muted); }
.hero-actions, .button-row { display: flex; gap: 0.8rem; flex-wrap: wrap; align-items: center; }
.status-line, .hint { color: var(--muted); font-size: 0.95rem; }

.grid.two {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1.25rem;
  margin-bottom: 1.25rem;
}
.section-heading { display: flex; align-items: flex-start; gap: 1rem; margin-bottom: 1.1rem; }
.step {
  display: grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-weight: 900;
  flex: 0 0 auto;
}
.section-heading p { margin: 0.35rem 0 0; color: var(--muted); }
.stack { display: grid; gap: 0.95rem; }
label { display: grid; gap: 0.35rem; color: var(--muted); font-weight: 700; }
input, textarea, select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0.82rem 0.9rem;
  background: #fffdf8;
  color: var(--ink);
  outline: none;
}
input:focus, textarea:focus, select:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(201, 100, 66, 0.12); }

.workflow-list { padding-left: 1.2rem; color: var(--muted); }
.workflow-list li { margin: 0.65rem 0; }
.onboarding-card, .novel-card, .state-card { margin-top: 1.25rem; }
.onboarding-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}
.question-card {
  border: 1px solid var(--line);
  background: #fffdf8;
  border-radius: 20px;
  padding: 1rem;
}
.question-card h3 { font-size: 1.05rem; margin-bottom: 0.7rem; }
.question-meta { color: var(--accent-dark); font-size: 0.78rem; font-weight: 900; letter-spacing: 0.04em; }

.reader-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
  gap: 1.25rem;
}
.novel-output {
  min-height: 32rem;
  max-height: 72vh;
  overflow: auto;
  border-radius: 24px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #fffdf8, #f9efe0);
  padding: clamp(1.1rem, 3vw, 2rem);
  white-space: pre-wrap;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.08rem;
}
.novel-output h3 { color: var(--accent-dark); margin-bottom: 1rem; }
.generated-chapter { border-top: 1px dashed var(--line); margin-top: 1.25rem; padding-top: 1.25rem; }
.streaming-cursor::after { content: '▌'; color: var(--accent); animation: blink 0.9s infinite; }
@keyframes blink { 50% { opacity: 0; } }
.control-panel { display: grid; align-content: start; gap: 1rem; }
fieldset {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1rem;
  display: grid;
  gap: 0.55rem;
}
legend { color: var(--accent-dark); font-weight: 900; }
fieldset label { display: flex; align-items: center; gap: 0.5rem; font-weight: 650; }
fieldset input { width: auto; }
pre {
  white-space: pre-wrap;
  background: #201c18;
  color: #fff7e8;
  border-radius: 20px;
  padding: 1rem;
  overflow: auto;
}

@media (max-width: 860px) {
  .grid.two, .reader-layout, .onboarding-grid { grid-template-columns: 1fr; }
  .topbar { align-items: flex-start; flex-direction: column; }
}
