:root {
  color: #17231d;
  background: #f4f6f2;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  --ink: #17231d;
  --muted: #5c6a62;
  --paper: #ffffff;
  --brand: #145c3a;
  --brand-strong: #0c472c;
  --line: #dce3dd;
  --warning-bg: #fff5d9;
  --warning-line: #d8a21b;
  --radius: 18px;
}

.entry-nav { display:flex; flex-wrap:wrap; gap:.4rem 1.2rem; margin-bottom:1.5rem; }
.entry-nav a { display:inline-flex; align-items:center; min-height:44px; font-weight:700; }
.entry-hero { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:clamp(1.5rem,4vw,4rem); align-items:center; padding-block:1rem 2rem; }
.entry-hero .hero { background:none; border:0; box-shadow:none; padding:1rem 0; }
.entry-hero h1 { font-size:clamp(2.8rem,5.8vw,4.6rem); max-width:17ch; line-height:1.04; letter-spacing:-.065em; }
.entry-hero h1 span { color:var(--brand); }
.entry-preview { position:relative; min-width:0; padding:1rem .5rem .5rem; }
.entry-preview::before { content:''; position:absolute; inset:8% -2% 6%; background:radial-gradient(ellipse at 80% 30%,#bbcfb9 0,transparent 65%),radial-gradient(ellipse at 15% 75%,#e5c9a3 0,transparent 65%); filter:blur(20px); z-index:-1; }
.conversation-window { position:relative; border:1px solid #fff; border-radius:26px; background:#e9e6df; box-shadow:0 28px 60px -18px #21392e55,0 4px 12px #273e2912,inset 0 0 0 5px #ffffff66; overflow:hidden; transform:rotate(1deg); }
.conversation-heading { display:flex; align-items:center; gap:.75rem; padding:1rem 1.1rem; background:#ffffffed; border-bottom:1px solid #d5dace; }
.conversation-heading > div { min-width:0; }
.conversation-heading strong { font-size:.94rem; display:block; }
.conversation-heading div > span { display:block; color:#697267; font-size:.69rem; margin-top:.2rem; }
.conversation-avatar { display:grid; place-items:center; width:38px; height:38px; flex-shrink:0; border-radius:13px; color:#fff; background:linear-gradient(135deg,#447d60,#193f2b); box-shadow:0 2px 5px #17392330; font-weight:700; }
.conversation-demo { margin-left:auto; font-size:.65rem; font-weight:700; color:#556752; background:#eff3e9; border:1px solid #dbe3d3; border-radius:6px; padding:.25rem .45rem; }
.conversation-body { display:flex; flex-direction:column; gap:.85rem; padding:1rem 1.05rem 1.1rem; background-image:radial-gradient(#65745f12 .8px,transparent .8px); background-size:13px 13px; }
.conversation-channel { align-self:center; display:flex; align-items:center; gap:.3rem; color:#5e695b; font-size:.64rem; font-weight:650; text-align:center; }
.conversation-private { margin-top:.5rem; padding:.3rem .65rem; background:#d7dfd39e; border-radius:20px; }
.entry-message { position:relative; align-self:flex-start; width:80%; border-radius:4px 17px 17px 17px; background:#fff; padding:.8rem .85rem; box-shadow:0 2px 3px #313c2817; margin:0; }
.entry-message::before { content:''; position:absolute; left:-7px; top:0; width:13px; height:13px; background:inherit; clip-path:polygon(0 0,100% 0,100% 100%); }
.entry-message p { margin:.35rem 0 0; font-size:.87rem; line-height:1.5; }
.message-author { display:block; font-size:.65rem; font-weight:750; color:#52644d; letter-spacing:.02em; }
.message-attachment { margin:.55rem -.35rem .55rem; border-radius:10px; overflow:hidden; position:relative; }
.message-attachment img { display:block; width:100%; height:auto; aspect-ratio:1.9; object-fit:cover; }
.message-attachment > span { position:absolute; left:.45rem; bottom:.45rem; padding:.15rem .3rem; background:#fffdf4db; border-radius:4px; color:#554e41; font-size:.52rem; }
.message-measures { display:flex; gap:.4rem; margin-top:.6rem; }
.message-measures span { border:1px solid #e0e6dc; border-radius:5px; padding:.15rem .4rem; font-size:.66rem; color:#465640; background:#f4f7f1; }
.entry-message-pro { align-self:flex-end; width:80%; background:linear-gradient(130deg,#1d7651,#13523a); color:#fff; border-radius:17px 4px 17px 17px; margin:0; box-shadow:0 3px 6px #153e2826; }
.entry-message-pro::before { left:auto; right:-7px; background:#13523a; clip-path:polygon(0 0,100% 0,0 100%); }
.entry-message-pro .message-author { color:#dbefdf; }
.entry-message-assistant { background:#fbfcf8; }
.message-document { display:flex; align-items:center; gap:.6rem; padding:.7rem; background:#eef2e8; border:1px solid #dce4d4; border-radius:10px; margin-top:.75rem; }
.document-icon { display:grid; place-items:center; position:relative; flex-shrink:0; width:33px; height:41px; font-size:.56rem; font-weight:800; background:#fff; color:#ab593d; border-radius:3px; box-shadow:0 1px 3px #39482b20; }
.document-icon::after { content:''; position:absolute; top:0; right:0; border:5px solid transparent; border-right-color:#e5eadc; border-top-color:#e5eadc; }
.message-document strong { display:block; font-size:.72rem; }
.message-document div > span { display:block; margin-top:.2rem; font-size:.63rem; color:#64705c; }
.conversation-outcome { display:flex; align-items:center; justify-content:center; gap:.45rem; margin-top:.3rem; }
.conversation-outcome > span { border-radius:50%; background:#315c42; color:#fff; font-size:.6rem; padding:.15rem .3rem; }
.conversation-outcome p { margin:0; font-size:.7rem; color:#43573c; }
.preview-disclaimer { margin:1.1rem .7rem 0; font-size:.7rem; line-height:1.5; color:#596653; text-align:center; }
.entry-section { margin-top:3rem; scroll-margin-top:1rem; }
.entry-section h2 { max-width:34ch; font-size:clamp(1.65rem,4vw,2.4rem); letter-spacing:-.035em; }
.entry-steps { list-style:none; display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:1rem; padding:0; }
.entry-steps li { position:relative; padding:1.25rem; background:linear-gradient(155deg,#fff,#f8faf5); border:1px solid var(--line); border-radius:22px; box-shadow:0 12px 24px -18px #183d3040; }
.step-art { display:block; width:100%; height:116px; margin-bottom:1.25rem; overflow:visible; }
.entry-steps li:nth-child(2) { background:linear-gradient(155deg,#fffaf0,#f3ebdb); }
.entry-steps li:nth-child(3) { background:linear-gradient(155deg,#eef5ed,#e1ebe0); }
.entry-steps li:nth-child(4) { background:linear-gradient(155deg,#f4f5ff,#eaeefa); }
.entry-steps h3 { margin-top:1rem; font-size:1.3rem; }
.entry-start { background:#e7eee3; border-radius:18px; padding:clamp(1.3rem,4vw,2.5rem); }
.entry-faq details { background:white; border:1px solid var(--line); border-radius:14px; padding:.75rem 1.2rem; }
.entry-faq summary::after { content:'+'; margin-left:auto; padding-left:1rem; }
.entry-faq details[open] summary::after { content:'−'; }
.entry-faq p { margin-bottom:.3rem; }
.entry-guide .card { scroll-margin-top:1rem; }
.guide-list { padding-left:1.3rem; line-height:1.65; }
.guide-list li + li { margin-top:.7rem; }
.entry-actions form { margin:0; }
.entry-actions .button { width:100%; }
@media (max-width:850px) { .entry-hero { grid-template-columns:1fr; } .entry-hero .hero { max-width:none; } .entry-steps { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media (max-width:480px) { .entry-steps { grid-template-columns:1fr; } .entry-preview { padding:.5rem .15rem; } .conversation-window { transform:none; } .entry-hero h1 { font-size:2.9rem; } .entry-hero { gap:1rem; } }

.onboarding-shell { max-width: 64rem; margin-inline: auto; }
.onboarding-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); gap: 1rem; }
.onboarding-banner { padding: 1.25rem; margin-bottom: 1.5rem; border: 1px solid #b8cfbc; border-radius: 18px; background: #eaf3e9; }
.onboarding-banner .button { width: fit-content; }
.onboarding-nav { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; margin-bottom: 1.5rem; }
.onboarding-nav .back-link, a.back-link { display: inline-flex; align-items: center; min-height: 44px; }
.auth-provider .button { width: 100%; }
.auth-provider .button:disabled { cursor: not-allowed; }
.auth-separator { display: flex; align-items: center; gap: .75rem; color: var(--muted); font-size: .85rem; }
.auth-separator::before, .auth-separator::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.fixture-inbox { border: 1px dashed #9baf9e; border-radius: 14px; padding: 1rem; background: #f3f6ee; }
.access-code { display: block; font-size: 1.8rem; font-weight: 800; letter-spacing: .15em; color: var(--brand-strong); }
.email-example { overflow-wrap: anywhere; }

.workspace-heading { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:1.25rem; }
.workspace-heading h1 { margin-block:.5rem; }
.overview-strip { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); border:1px solid var(--line); border-radius:18px; background:#fff; }
.overview-strip > a { display:grid; gap:.2rem; padding:1.2rem; min-height:80px; color:var(--ink); text-decoration:none; }
.overview-strip > a:first-child { border-radius:17px 0 0 17px; }
.overview-strip > a:last-child { border-radius:0 17px 17px 0; }
.overview-strip > a:hover { background:#e8eee8; }
.overview-strip > a[aria-current="page"] { background:var(--brand); color:white; }
.overview-strip > a[aria-current="page"] span { text-decoration:underline; text-underline-offset:.25em; font-weight:700; }
.overview-strip > a:focus-visible { outline:3px solid var(--brand); outline-offset:3px; position:relative; z-index:1; }
.overview-strip strong { font-size:1.8rem; letter-spacing:-.05em; }
.overview-strip span, .small { font-size:.82rem; }
.overview-strip > a + a { border-left:1px solid var(--line); }
.dashboard-results-heading { gap:.25rem; }
.dashboard-results-heading h2, .dashboard-results-heading p { margin:0; }
.dialogue { border-top:1px solid var(--line); padding-top:1.5rem; margin-top:1.5rem; }
.dialogue-history { display:flex; flex-direction:column; gap:1rem; padding:1rem; border:1px solid #dce1d6; border-radius:20px; background-color:#e9e6df; background-image:radial-gradient(#65745f18 .8px,transparent .8px); background-size:13px 13px; }
.dialogue-history:empty { display:none; }
.bubble { position:relative; width:fit-content; max-width:84%; min-width:0; padding:.9rem 1rem; border-radius:18px; overflow-wrap:anywhere; box-shadow:0 2px 4px #233e2717; }
.bubble p { margin:.35rem 0 0; }
.bubble::before { content:''; position:absolute; top:0; width:10px; height:12px; background:inherit; }
.bubble-pro { align-self:flex-end; background:#145c3a; color:#fff; border-top-right-radius:3px; }
.bubble-pro::before { right:-6px; clip-path:polygon(0 0,100% 0,0 100%); }
.bubble-product { align-self:flex-start; background:#fff; border-top-left-radius:3px; }
.bubble-product::before { left:-6px; clip-path:polygon(0 0,100% 0,100% 100%); }
.bubble-author { font-size:.72rem; font-weight:800; text-transform:uppercase; letter-spacing:.05em; color:var(--muted); }
.bubble-pro .bubble-author { color:#d8eee0; }
.rate-list { margin-top:1rem; }
.opening-editor { min-width:0; border:1px solid var(--line); border-radius:18px; padding:clamp(.75rem,3vw,1.3rem); background:#fafbf8; }
.opening-editor h2 { font-size:1.35rem; }
.opening-editor [data-opening-title]:focus { outline:2px solid var(--brand); outline-offset:4px; }
.field-error { color:#8b3026; font-size:.9rem; margin:0; }
.field-error:empty { display:none; }
.rate-list small { display:block; color:var(--muted); }
summary { cursor:pointer; min-height:44px; display:flex; align-items:center; font-weight:700; }
.pagination { display:flex; align-items:center; justify-content:center; gap:1rem; }
.schedule-options { border:0; padding:0; margin:0; min-width:0; }
.schedule-options legend { padding:0 0 1rem; font-weight:700; }
.schedule-choice { display:flex; align-items:center; gap:1rem; cursor:pointer; }
.schedule-choice input { width:24px; height:24px; flex:0 0 24px; }
.schedule-choice:has(input:checked) { border-color:#165a40; background:#e4f2e9; box-shadow:0 0 0 2px #165a40; }
.quote-lines strong { white-space:nowrap; }
.summary-list dd, h1, h2, p { overflow-wrap:anywhere; }
.button-secondary:hover, .button-secondary:focus-visible { color:white; }
@media (max-width:420px) { .site-header { flex-wrap:wrap; } .overview-strip > a { padding:.85rem; } }

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 100% 0, #dcebdd 0, transparent 32rem),
    #f4f6f2;
}

a {
  color: var(--brand);
}

.site-header {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: max(1rem, env(safe-area-inset-top)) 1rem 0;
}

.brand {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 0.5rem;
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
}

.brand span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.25rem 0.55rem;
  color: var(--muted);
  background: rgb(255 255 255 / 70%);
  font-size: 0.75rem;
}

.page-shell {
  width: min(100% - 2rem, 72rem);
  margin: 0 auto;
  padding: 2rem 0 max(3rem, env(safe-area-inset-bottom));
}

.account-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.account-actions form {
  margin: 0;
}

.link-button,
.back-link {
  min-height: 44px;
  border: 0;
  background: transparent;
  color: var(--brand);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.stack > * {
  margin-block: 0;
}

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

.hero {
  max-width: 44rem;
  padding: clamp(1.5rem, 5vw, 3.5rem);
  border: 1px solid rgb(255 255 255 / 80%);
  border-radius: var(--radius);
  background: rgb(255 255 255 / 88%);
  box-shadow: 0 1.5rem 4rem rgb(31 67 46 / 10%);
}

.eyebrow {
  color: var(--brand);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1 {
  max-width: 18ch;
  font-size: clamp(2.2rem, 12vw, 4.8rem);
  line-height: 0.98;
  letter-spacing: -0.055em;
}

h2,
h3 {
  margin: 0;
  line-height: 1.15;
}

.page-title {
  max-width: 22ch;
  font-size: clamp(2rem, 8vw, 3.5rem);
}

p {
  line-height: 1.55;
}

.notice {
  padding: 1rem;
  border-left: 4px solid var(--warning-line);
  border-radius: 10px;
  background: var(--warning-bg);
  font-weight: 650;
}

.notice.subtle {
  border-left-color: var(--line);
  background: #f5f7f5;
  font-weight: 500;
}

.section {
  margin-top: 3rem;
}

.card-grid {
  display: grid;
  gap: 1rem;
}

.card,
.narrow-card,
.action-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 1rem 3rem rgb(31 67 46 / 7%);
}

.card,
.action-panel {
  padding: 1.25rem;
}

.narrow-card {
  width: min(100%, 38rem);
  margin-inline: auto;
  padding: clamp(1.25rem, 5vw, 2.5rem);
}

.card-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.status-chip {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  border-radius: 999px;
  padding: 0.25rem 0.7rem;
  background: #e7f2e9;
  color: var(--brand-strong);
  font-size: 0.78rem;
  font-weight: 800;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--brand);
  border-radius: 12px;
  padding: 0.75rem 1rem;
  background: var(--brand);
  color: white;
  font: inherit;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  touch-action: manipulation;
}

.button:hover,
.button:focus-visible {
  background: var(--brand-strong);
}

.button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.button-secondary {
  background: white;
  color: var(--brand);
}

.form-stack {
  display: grid;
  gap: 1.15rem;
}

.field {
  display: grid;
  gap: 0.4rem;
}

label {
  font-weight: 750;
}

input,
select,
textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid #aebbb2;
  border-radius: 10px;
  padding: 0.7rem 0.8rem;
  background: white;
  color: var(--ink);
  font: inherit;
  font-size: 16px;
}

/* WebKit's native control can overflow by the option's intrinsic text width
   despite a fitting border box. Style the closed control; keep its native picker. */
select {
  appearance: none;
  -webkit-appearance: none;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  padding-right: 2.5rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='m1 1 5 5 5-5' fill='none' stroke='%2317231d' stroke-width='2'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right .9rem center;
}

input:focus,
select:focus,
textarea:focus,
button:focus-visible,
a:focus-visible {
  outline: 3px solid #68a982;
  outline-offset: 2px;
}

.check-row {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 0.75rem;
  align-items: start;
  min-height: 48px;
  cursor: pointer;
}

.check-row input {
  width: 24px;
  min-height: 24px;
  margin: 0;
}

.errorlist {
  margin: 0;
  padding: 0;
  color: #a22121;
  list-style: none;
}

.messages {
  width: min(100%, 48rem);
  margin: 0 auto 1rem;
}

.message,
.success-panel,
.error-panel {
  border-radius: 12px;
  padding: 1rem;
  background: #e7f2e9;
}

.error-panel {
  background: #fdeaea;
  color: #7c1616;
}

.muted {
  color: var(--muted);
}

.credentials {
  overflow-wrap: anywhere;
}

.credentials code,
.hash-box code {
  display: block;
  overflow-wrap: anywhere;
  color: var(--muted);
}

.copy-field {
  display: grid;
  gap: 0.65rem;
}

.copy-field input {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.copy-field .button {
  white-space: nowrap;
}

.copy-status:empty {
  display: none;
}

.step-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--muted);
  font-weight: 700;
}

.step-dot,
.success-mark {
  display: inline-flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--brand);
  color: white;
}

.success-mark {
  width: 52px;
  height: 52px;
  font-size: 1.6rem;
}

.summary-list {
  display: grid;
  gap: 0.75rem;
  margin: 0;
}

.summary-list div,
.quote-lines > div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.65rem;
}

.summary-list dt {
  color: var(--muted);
}

.summary-list dd {
  margin: 0;
  font-weight: 750;
  text-align: right;
}

.summary-list.compact {
  font-size: 0.92rem;
}

.split-layout {
  display: grid;
  gap: 1rem;
}

.quote-lines {
  display: grid;
  gap: 0.75rem;
}

.quote-lines .total-row {
  border-bottom: 0;
  padding-top: 0.5rem;
  font-size: 1.2rem;
}

.hash-box {
  border-radius: 10px;
  padding: 0.75rem;
  background: #f3f5f3;
  font-size: 0.78rem;
}

.action-panel form p {
  margin: 0;
}

.action-panel form input[type="hidden"] {
  display: none;
}

.acceptance {
  border-top: 1px solid var(--line);
  padding-top: 1.25rem;
}

.empty-state {
  border: 1px dashed #aebbb2;
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
}

@media (min-width: 48rem) {
  .site-header {
    padding-inline: 2rem;
  }

  .page-shell {
    padding-top: 4rem;
  }

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

  .split-layout {
    grid-template-columns: minmax(0, 1.45fr) minmax(18rem, 0.75fr);
    align-items: start;
  }

  .copy-field {
    grid-template-columns: minmax(0, 1fr) auto;
  }
}
/* Private request photos and touch-friendly selection. */
.photo-picker { min-width: 0; border: 1px solid #d9e1df; border-radius: 16px; padding: 16px; }
.photo-picker legend { font-weight: 700; padding: 0 6px; }
.photo-picker input[type=file] { max-width: 100%; min-height: 48px; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; }
.photo-grid figure { margin: 0; min-width: 0; }
.photo-grid img { display: block; width: 100%; height: 180px; object-fit: contain; background: #eef2f0; border-radius: 12px; }
.photo-grid figcaption { overflow-wrap: anywhere; font-size: 13px; margin: 8px 0; }
.photo-grid button { min-height: 44px; width: 100%; }
[data-upload-progress] progress { display: block; width: 100%; height: 24px; }
[hidden] { display: none !important; }
