:root {
  --bg: #ffffff;
  --bg-alt: #fafafa;
  --text: #18181b;
  --muted: #71717a;
  --border: #e4e4e7;
  --accent: #d97757; /* Claude warm terracotta */
  --accent-hover: #c4633f;
  --radius: 14px;
  --maxw: 1080px;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 8px 24px rgba(0, 0, 0, 0.06);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.logo {
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}
.logo span { color: var(--accent); }
.nav { display: flex; gap: 28px; }
.nav a { color: var(--muted); font-size: 0.95rem; transition: color 0.15s; }
.nav a:hover { color: var(--text); }

/* Hero */
.hero {
  padding: 48px 0 44px;
  text-align: center;
}
.badge {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--accent);
  background: rgba(217, 119, 87, 0.1);
  padding: 6px 14px;
  border-radius: 999px;
  margin: 0 0 24px;
}
.hero h1 {
  font-size: clamp(2.1rem, 5vw, 3.4rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin: 0 0 20px;
  font-weight: 700;
}
.lead {
  max-width: 620px;
  margin: 0 auto 28px;
  font-size: 1.15rem;
  color: var(--muted);
}

/* Sections */
.section { padding: 56px 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-title {
  text-align: center;
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}
.section-sub { text-align: center; color: var(--muted); margin: 0 0 36px; }

/* Plans */
.plans {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: stretch;
}
.plan {
  position: relative;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  background: var(--bg);
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}
.plan:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.plan-featured {
  border-color: var(--accent);
  box-shadow: var(--shadow);
}
.plan-tag {
  position: absolute;
  top: -12px;
  left: 28px;
  background: var(--accent);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  margin: 0;
}
.plan-name { font-size: 1.25rem; margin: 0 0 8px; font-weight: 600; }
.plan-price { margin: 0; font-weight: 700; font-size: 1.1rem; color: var(--muted); }
.plan-price .amount { font-size: 2.6rem; color: var(--text); letter-spacing: -0.02em; }
.plan-period { color: var(--muted); font-size: 0.9rem; margin: 4px 0 24px; }
.plan-features {
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  flex: 1;
}
.plan-features li {
  padding: 8px 0 8px 26px;
  position: relative;
  font-size: 0.95rem;
  border-top: 1px solid var(--border);
}
.plan-features li:first-child { border-top: none; }
.plan-features li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}

/* Buttons */
.btn {
  display: inline-block;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 10px;
  padding: 12px 22px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  text-align: center;
}
.btn-lg { padding: 14px 32px; font-size: 1.05rem; }
.btn-block { width: 100%; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); }
.btn-outline { background: transparent; color: var(--text); border-color: var(--border); }
.btn-outline:hover { border-color: var(--accent); color: var(--accent); }

/* How it works */
.how-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 40px;
}
.how-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
}
.how-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(217, 119, 87, 0.1);
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 16px;
}
.how-card h3 { margin: 0 0 8px; font-size: 1.1rem; }
.how-card p { margin: 0; color: var(--muted); font-size: 0.95rem; }
.notice {
  background: var(--bg);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 10px;
  padding: 20px 24px;
  color: var(--muted);
  font-size: 0.95rem;
}
.notice strong { color: var(--text); }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-note { color: var(--muted); font-size: 0.9rem; margin: 0; }

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(24, 24, 27, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 50;
  animation: fade 0.15s ease;
}
.modal-overlay[hidden] { display: none; }
.modal {
  position: relative;
  background: var(--bg);
  border-radius: var(--radius);
  padding: 36px 32px 32px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow);
  animation: pop 0.18s ease;
}
.modal-close {
  position: absolute;
  top: 14px;
  right: 16px;
  background: none;
  border: none;
  font-size: 1.6rem;
  line-height: 1;
  color: var(--muted);
  cursor: pointer;
}
.modal-close:hover { color: var(--text); }
.modal-title { margin: 0 0 6px; font-size: 1.4rem; letter-spacing: -0.02em; }
.modal-plan { color: var(--muted); margin: 0 0 24px; font-size: 0.95rem; }
.modal-text { color: var(--muted); margin: 0 0 24px; }

.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 6px;
}
.field input {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.field input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(217, 119, 87, 0.15);
}
.field input.invalid { border-color: #dc2626; }
.field-error {
  color: #dc2626;
  font-size: 0.82rem;
  margin: 6px 0 0;
  min-height: 1px;
}

.success-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 20px;
  border-radius: 50%;
  background: rgba(217, 119, 87, 0.12);
  color: var(--accent);
  font-size: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
#success-view { text-align: center; }

@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(0.98); } to { opacity: 1; transform: none; } }

/* Hero trust line */
.hero-trust {
  margin: 18px 0 0;
  font-size: 0.85rem;
  color: var(--muted);
}

/* Narrow container (FAQ) */
.container-narrow { max-width: 760px; }

/* FAQ */
.faq-item {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0 20px;
  margin-bottom: 12px;
  background: var(--bg);
  transition: border-color 0.15s;
}
.faq-item[open] { border-color: var(--accent); }
.faq-item summary {
  cursor: pointer;
  list-style: none;
  padding: 16px 28px 16px 0;
  font-weight: 600;
  position: relative;
  outline: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 2px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--accent);
}
.faq-item[open] summary::after { content: "\2212"; }
.faq-item p {
  margin: 0;
  padding: 12px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}
.faq-item p:last-child { padding-bottom: 18px; }
.code-block {
  margin: 10px 0 0;
  padding: 12px 14px;
  background: #18181b;
  color: #f4f4f5;
  border-radius: 8px;
  overflow-x: auto;
  font-size: 0.85rem;
  line-height: 1.5;
}
.code-block code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  white-space: pre;
}
.faq-item :not(pre) > code {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 1px 5px;
  font-size: 0.85em;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

/* Support bubble */
.support-bubble {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 40;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: none;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(217, 119, 87, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, transform 0.15s, box-shadow 0.15s;
}
.support-bubble:hover { background: var(--accent-hover); transform: translateY(-2px); }
.support-bubble svg { display: block; }
.support-icon-x { display: none; }
.support-bubble[aria-expanded="true"] .support-icon-chat { display: none; }
.support-bubble[aria-expanded="true"] .support-icon-x { display: block; }

.support-panel {
  position: fixed;
  right: 24px;
  bottom: 92px;
  z-index: 40;
  width: 340px;
  max-width: calc(100vw - 32px);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px 22px 22px;
  animation: pop 0.18s ease;
}
.support-panel[hidden] { display: none; }
.support-panel-close {
  position: absolute;
  top: 10px;
  right: 12px;
  background: none;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--muted);
  cursor: pointer;
}
.support-panel-close:hover { color: var(--text); }
.support-title { margin: 0 0 6px; font-size: 1.15rem; letter-spacing: -0.02em; }
.support-sub { margin: 0 0 18px; color: var(--muted); font-size: 0.9rem; }
.support-panel .field textarea {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg);
  resize: vertical;
  min-height: 76px;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.support-panel .field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(217, 119, 87, 0.15);
}
.support-panel .field textarea.invalid { border-color: #dc2626; }
#support-success-view { text-align: center; }

/* Responsive */
@media (max-width: 860px) {
  .plans, .how-grid { grid-template-columns: 1fr; }
  .nav { display: none; }
  .hero { padding: 64px 0 56px; }
  .section { padding: 56px 0; }
}

@media (max-width: 480px) {
  .support-bubble { right: 16px; bottom: 16px; }
  .support-panel {
    right: 16px;
    left: 16px;
    bottom: 84px;
    width: auto;
    max-width: none;
  }
}
