@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;500;600;700&display=swap");

:root {
  --color-bg: #ffffff;
  --color-text: #000000;
  --color-text-strong: #111111;
  --color-line: #e5e5e5;
  --color-dark: #0b0b0b;
  --radius: 4px;
  --content-max: 1280px;
  --content-pad: clamp(20px, 4vw, 64px);
  --section-pad: clamp(56px, 10vw, 120px);
  --tracking-logo: 0.08em;
  --tracking-wide: 0.14em;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Montserrat", system-ui, -apple-system, sans-serif;
  font-weight: 400;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  letter-spacing: 0.01em;
}

main {
  min-height: 60vh;
}

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

a {
  color: inherit;
  text-decoration: none;
}

a:hover,
a:focus {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.container {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 var(--content-pad);
}

.section {
  padding: var(--section-pad) 0;
  border-top: 1px solid var(--color-line);
}

.section:first-of-type {
  border-top: 0;
}

.section--dark {
  background: var(--color-dark);
  color: #ffffff;
}

.section--dark a {
  color: #ffffff;
}

.site-header {
  border-bottom: 1px solid var(--color-line);
  background: var(--color-bg);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.6rem 0;
  gap: 2rem;
}

.header-actions {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
}

.nav-link {
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  font-size: 0.75rem;
  font-weight: 600;
}

.site-footer {
  border-top: 1px solid var(--color-line);
  padding: 2rem 0;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.85rem;
}

.footer-links {
  display: inline-flex;
  gap: 1rem;
  flex-wrap: wrap;
}

h1,
h2,
h3 {
  margin: 0 0 0.6em;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

h1 {
  font-size: clamp(2.9rem, 4.2vw + 1rem, 4.25rem);
  font-weight: 300;
}

h2 {
  font-size: clamp(2rem, 2.2vw + 1rem, 2.5rem);
  font-weight: 400;
}

h3 {
  font-size: clamp(1.5rem, 1.4vw + 1rem, 1.75rem);
  font-weight: 500;
}

p {
  margin: 0 0 1.2em;
  font-size: 1rem;
}

.lede {
  font-size: 1.125rem;
  max-width: 60ch;
}

.hero-subline {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0 0 0.6rem;
}

.muted {
  color: #4b4b4b;
}

.microtext {
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.principle {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #4b4b4b;
}

.is-hidden {
  display: none;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-text-strong);
}

.brand {
  text-transform: uppercase;
  letter-spacing: var(--tracking-logo);
  font-weight: 500;
  font-size: 0.85rem;
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
}

.brand-logo img {
  height: 24px;
  width: auto;
  display: block;
  filter: none;
}

.brand-name {
  text-transform: uppercase;
  letter-spacing: var(--tracking-logo);
  font-weight: 500;
  font-size: 0.85rem;
  color: var(--color-text);
}

.divider {
  height: 1px;
  background: var(--color-line);
  width: 100%;
  margin: 2rem 0;
}

.stack > * + * {
  margin-top: 1.2rem;
}

.hero {
  padding-top: clamp(72px, 10vw, 140px);
  padding-bottom: clamp(72px, 10vw, 140px);
}

.hero-grid {
  align-items: start;
  gap: clamp(32px, 6vw, 80px);
}

.grid {
  display: grid;
  gap: clamp(24px, 4vw, 48px);
}

.grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card {
  border: 1px solid var(--color-line);
  padding: clamp(20px, 3vw, 32px);
  background: var(--color-bg);
}

.card--dark {
  background: var(--color-dark);
  color: #ffffff;
  border-color: #111111;
}

.card-action {
  width: 100%;
  text-align: left;
  font: inherit;
  color: inherit;
  cursor: pointer;
  background: var(--color-bg);
}

.card-action:focus-visible {
  outline: 2px solid var(--color-text);
  outline-offset: 2px;
}

.chat-panel {
  padding: 0;
  display: grid;
  gap: 1.8rem;
  background: transparent;
  border: 0;
  justify-self: end;
  width: 100%;
  max-width: 520px;
  margin-top: clamp(120px, 12vw, 220px);
}

.chat-history {
  position: relative;
  height: clamp(240px, 28vw, 360px);
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  justify-content: flex-end;
  padding: 0.4rem 0.2rem 2.8rem;
  margin-bottom: 0.6rem;
  overflow-y: auto;
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: #d0d0d0 transparent;
}

.chat-history::before,
.chat-history::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 16px;
  pointer-events: none;
}

.chat-history::before {
  top: 0;
  background: linear-gradient(to bottom, #ffffff 0%, rgba(255, 255, 255, 0) 100%);
}

.chat-history::after {
  bottom: 0;
  background: linear-gradient(to top, #ffffff 0%, rgba(255, 255, 255, 0) 100%);
}

.chat-line {
  max-width: 80%;
  font-size: 1rem;
  letter-spacing: 0.01em;
}

.chat-text {
  white-space: pre-wrap;
}

.chat-assistant {
  align-self: flex-start;
  color: #2b2b2b;
}

.chat-user {
  align-self: flex-end;
  text-align: right;
}

.chat-user.is-draft .chat-text {
  color: #c3c3c3;
}

.chat-user.is-committed .chat-text {
  color: #111111;
}

.chat-user.is-draft:not(.is-visible) {
  display: none;
}

.cursor {
  display: inline-block;
  width: 8px;
  height: 1em;
  margin-left: 4px;
  background: #1e1e1e;
  animation: blink 1s steps(1, start) infinite;
}

.chat-input-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  position: relative;
  border: 1px solid var(--color-line);
  border-radius: 14px;
  padding: 0.95rem 1.3rem;
  background: #ffffff;
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.08),
    0 26px 70px rgba(0, 0, 0, 0.14);
  transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.32s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.32s ease;
}

.chat-icon {
  color: #9a9a9a;
  font-size: 1.1rem;
}

.chat-input-row input {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  border: 0;
  outline: none;
  background: transparent;
}

.chat-input-row textarea {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  border: 0;
  outline: none;
  background: transparent;
  resize: none;
  height: 24px;
  line-height: 1.5;
  overflow: hidden;
}

.chat-input-row:hover {
  transform: translateY(-7px);
  box-shadow:
    0 12px 32px rgba(0, 0, 0, 0.1),
    0 36px 84px rgba(0, 0, 0, 0.18);
}

.chat-input-row:focus-within {
  transform: translateY(-8px);
  box-shadow:
    0 14px 36px rgba(0, 0, 0, 0.12),
    0 40px 96px rgba(0, 0, 0, 0.2);
  border-color: #cecece;
}

.chat-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.chat-hint {
  font-size: 0.85rem;
  color: #8b8b8b;
}

.list-plain {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.6rem;
}

.steps {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 1rem;
}

.step {
  border: 1px solid var(--color-line);
  padding: 1rem 1.2rem;
}

.faq details {
  border-bottom: 1px solid var(--color-line);
  padding: 0.8rem 0;
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
}

.cta-block {
  margin-top: 2rem;
}

.button,
button,
input[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.9rem 1.6rem;
  border: 1px solid var(--color-text);
  background: var(--color-text);
  color: var(--color-bg);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: color 0.2s ease, background-color 0.2s ease,
    border-color 0.2s ease;
}

.button:hover,
.button:focus,
button:hover,
button:focus,
input[type="submit"]:hover,
input[type="submit"]:focus {
  background: transparent;
  color: var(--color-text);
}

.button--ghost {
  background: transparent;
  color: var(--color-text);
}

.button--ghost:hover,
.button--ghost:focus {
  background: var(--color-text);
  color: var(--color-bg);
}

.section--dark .button {
  background: #ffffff;
  color: #000000;
  border-color: #ffffff;
}

.section--dark .button:hover,
.section--dark .button:focus {
  background: transparent;
  color: #ffffff;
  border-color: #ffffff;
}

.reveal {
  opacity: 0;
  transform: translateY(12px);
  animation: reveal 0.6s ease forwards;
}

.reveal-delay-1 {
  animation-delay: 0.15s;
}

.reveal-delay-2 {
  animation-delay: 0.3s;
}

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

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

@media (max-width: 900px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }

  p {
    font-size: 1rem;
  }
}
