:root {
  --ink: #0e493b;
  --deep: #1d5848;
  --lime: #80ad3f;
  --pale: #e5efd1;
  --paper: #f7f6ee;
  --card: #fffef8;
  --line: #ccd6c6;
  --orange: #dc7542;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--paper);
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: radial-gradient(circle at 80% 4%, #eef2df 0, transparent 28rem), var(--paper); }
a { color: inherit; }
button, input { font: inherit; }
button { color: inherit; }
.site-header { height: 68px; min-height: 0; padding: 0 16px; display: flex; align-items: center; justify-content: space-between; gap: 10px; border-bottom: 1px solid #d9ddcf; background: #f5f4edeb; backdrop-filter: blur(16px); position: sticky; top: 0; z-index: 20; }
nav { display: flex; align-items: center; gap: 8px; }
nav > a { color: #173d31; text-decoration: none; font-size: 13px; font-weight: 700; }
.site-header .outline { min-height: 44px; padding: 9px 12px; border: 1px solid #cbd3c4; border-radius: 999px; color: #173d31; font-size: 12px; font-weight: 700; white-space: nowrap; }
.primary, .outline, .text-button { border: 0; border-radius: 999px; padding: .95rem 1.35rem; font-weight: 850; text-decoration: none; cursor: pointer; }
.primary { background: var(--deep); color: white; }
.outline { background: transparent; border: 1.5px solid var(--lime); }
.text-button { background: transparent; text-decoration: underline; text-underline-offset: .35em; }
.full { width: 100%; display: flex; justify-content: space-between; }
main { margin: 0 auto; padding: clamp(3rem, 7vw, 7rem) 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.hero { margin-bottom: clamp(4rem, 8vw, 7rem); display: flex; align-items: flex-start; justify-content: space-between; gap: 2rem; }
.hero-copy { max-width: 850px; }
.guest-auth-link { flex: 0 0 auto; }
.eyebrow { font-size: .83rem; letter-spacing: .2em; font-weight: 900; margin: 0 0 1rem; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(3rem, 8vw, 6.8rem); line-height: .91; letter-spacing: -.065em; margin-bottom: 1.8rem; }
h2 { font-size: clamp(2.2rem, 5vw, 4.1rem); line-height: .96; letter-spacing: -.05em; margin-bottom: 1rem; }
h3 { font-size: 1.8rem; margin-bottom: 1rem; }
.hero-copy > p:last-child, .section-heading > p { color: #60736c; font-size: clamp(1.05rem, 2vw, 1.35rem); line-height: 1.55; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 3rem; margin-bottom: 2rem; }
.section-heading > p { width: min(31rem, 48%); margin-bottom: .35rem; }
.bundle-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.2rem; }
.bundle-card, .plan-card, .settings-card, .auth-card, .checkout-view, .messenger { border: 1px solid var(--line); background: var(--card); border-radius: 2rem; }
.bundle-card { position: relative; padding: clamp(1.8rem, 4vw, 3rem); min-height: 27rem; display: flex; flex-direction: column; overflow: hidden; }
.bundle-card .flag { align-self: flex-start; font-size: .75rem; font-weight: 900; letter-spacing: .15em; border: 1px solid currentColor; border-radius: 999px; padding: .45rem .7rem; margin-bottom: 2rem; }
.bundle-card h3 { font-size: clamp(2rem, 4vw, 3.4rem); letter-spacing: -.05em; margin-bottom: .8rem; }
.price { font-size: clamp(3rem, 7vw, 5.8rem); font-weight: 900; letter-spacing: -.07em; line-height: 1; margin-bottom: 1rem; }
.price small { font-size: 1rem; letter-spacing: 0; }
.bundle-card .description { max-width: 31rem; line-height: 1.55; color: #60736c; }
.bundle-features, .checkout-product-features { margin: 1rem 0 1.5rem; padding-left: 1.2rem; display: grid; gap: .45rem; font-weight: 800; line-height: 1.4; }
.bundle-features:empty, .checkout-product-features:empty { display: none; }
.bundle-card button { margin-top: auto; width: 100%; border: 0; border-radius: 999px; padding: 1.15rem 1.35rem; font-weight: 900; cursor: pointer; display: flex; justify-content: space-between; }
.bundle-card button { background: var(--orange); color: white; }
.bundle-card.active-plan button:disabled { opacity: 1; cursor: default; background: transparent; color: inherit; border: 1px solid currentColor; }
.fineprint { color: #77877f; font-size: .85rem; margin: 1.2rem .5rem 0; }
.plans-paused { padding: 1.1rem 1.25rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--card); color: #667870; font-weight: 750; }
.notice { position: sticky; top: 1rem; z-index: 5; background: var(--pale); border: 1px solid var(--lime); border-radius: 1rem; padding: 1rem 1.2rem; font-weight: 750; }
.notice.error { background: #fff0e8; border-color: var(--orange); color: #8b351b; }
.auth-card { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 8vw, 8rem); padding: clamp(2rem, 6vw, 5rem); }
.auth-copy p:last-child, #account-email { color: #667870; line-height: 1.55; }
form { display: grid; gap: 1.15rem; }
label { display: grid; gap: .45rem; font-weight: 800; }
input { width: 100%; border: 1.5px solid var(--line); background: white; border-radius: .9rem; padding: .95rem 1rem; color: var(--ink); }
input:focus { outline: 3px solid #dce9c1; border-color: var(--lime); }
.password-field { position: relative; display: block; }
.password-field input { padding-right: 3.4rem; }
.password-field .password-toggle { position: absolute; top: 50%; right: .55rem; box-sizing: border-box; flex: 0 0 2.45rem; width: 2.45rem; min-width: 2.45rem; max-width: 2.45rem; height: 2.45rem; min-height: 2.45rem; max-height: 2.45rem; aspect-ratio: 1; margin: 0; padding: 0; transform: translateY(-50%); display: grid; place-items: center; border: 0; border-radius: 50%; background: transparent; color: #60736c; line-height: 1; -webkit-appearance: none; appearance: none; }
.password-field .password-toggle:hover { background: #eef2e7; }
.password-field .password-toggle:focus-visible { outline: 3px solid #dce9c1; }
.password-toggle svg { width: 1.3rem; height: 1.3rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.password-toggle[aria-pressed="true"]::after { content: ''; position: absolute; width: 1.55rem; height: 2px; border-radius: 2px; background: currentColor; transform: rotate(-45deg); }
.form-links { text-align: center; line-height: 1.8; }
.account-top, .checkout-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 2rem; margin-bottom: 2rem; }
.account-top > div { min-width: 0; }
.messenger { margin-bottom: 1.2rem; }
.messenger-heading { margin-bottom: 1.4rem; }
.messenger-heading h3 { margin-bottom: 1rem; }
.messenger-shell { min-height: 600px; height: min(68vh, 720px); display: grid; grid-template-columns: minmax(300px, .72fr) minmax(0, 1.28fr); overflow: hidden; border: 1px solid var(--line); border-radius: 1.4rem; background: var(--card); }
.conversation-sidebar { min-width: 0; overflow-y: auto; border-right: 1px solid var(--line); background: #fffef9; }
.conversation-list { display: grid; align-content: start; }
.conversation-empty { padding: 3rem 1.6rem; color: #60736c; line-height: 1.6; text-align: center; }
.conversation-item { width: 100%; min-width: 0; padding: 16px; display: grid; grid-template-columns: 68px minmax(0, 1fr); gap: 13px; border: 0; border-bottom: 1px solid var(--line); border-left: 4px solid transparent; background: transparent; color: var(--ink); text-align: left; cursor: pointer; }
.conversation-item:hover { background: #f3f4ea; }
.conversation-item.active { border-left-color: var(--brand-accent, #69983b); background: #eef3e7; }
.conversation-thumb { width: 68px; height: 68px; border-radius: 14px; object-fit: cover; background: #e5e9df; }
.conversation-copy { min-width: 0; display: grid; align-content: center; gap: 4px; }
.conversation-meta { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.conversation-meta strong, .conversation-title, .conversation-preview { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.conversation-meta strong { font-size: 15px; }
.conversation-meta time { flex: 0 0 auto; color: #708077; font-size: 11px; }
.conversation-title { font-size: 13px; font-weight: 850; }
.conversation-preview { color: #60736c; font-size: 13px; }
.chat-panel { min-width: 0; min-height: 0; background: #efeee8; }
.chat-empty { height: 100%; padding: 2rem; display: grid; place-content: center; justify-items: center; color: #667970; text-align: center; }
.chat-empty > span { width: 58px; height: 58px; margin-bottom: 1rem; display: grid; place-items: center; border-radius: 50%; background: var(--pale); color: var(--deep); font-size: 1.8rem; }
.chat-empty h3 { color: var(--ink); }
.chat-empty p { max-width: 28rem; line-height: 1.6; }
.chat-active { height: 100%; min-height: 0; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.chat-header { min-width: 0; min-height: 86px; padding: 12px 16px; display: flex; align-items: center; gap: 13px; border-bottom: 1px solid var(--line); background: var(--card); }
.chat-listing-image { flex: 0 0 auto; width: 58px; height: 58px; border-radius: 13px; overflow: hidden; background: #e5e9df; }
.chat-listing-image img { width: 100%; height: 100%; display: block; object-fit: cover; }
.chat-header > div { min-width: 0; }
.chat-header p { margin: 0 0 4px; color: #687970; font-size: 12px; font-weight: 750; }
.chat-header #chat-listing-link { display: block; overflow: hidden; color: var(--deep); font-size: 16px; font-weight: 900; text-overflow: ellipsis; white-space: nowrap; }
.chat-header a[aria-disabled="true"] { pointer-events: none; color: #748079; }
.message-thread { min-height: 0; padding: 22px; display: flex; flex-direction: column; gap: 5px; overflow-y: auto; overscroll-behavior: contain; }
.message-row { max-width: min(78%, 560px); display: grid; gap: 4px; align-self: flex-start; }
.message-row.own { align-self: flex-end; justify-items: end; }
.message-bubble { margin: 0; padding: 11px 14px; border-radius: 18px 18px 18px 5px; background: #fff; color: #173d31; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; }
.message-row.own .message-bubble { border-radius: 18px 18px 5px 18px; background: var(--brand-accent, #69983b); color: #0e291f; }
.message-row time { color: #667970; font-size: 11px; }
.message-composer { margin: 0 14px 14px; padding: 8px; display: grid; grid-template-columns: minmax(0, 1fr) 48px; align-items: end; gap: 8px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.message-composer textarea { width: 100%; max-height: 130px; min-height: 48px; padding: 12px; resize: none; border: 0; outline: 0; background: transparent; color: var(--ink); font: inherit; line-height: 1.45; }
.message-composer button { width: 48px; height: 48px; padding: 0; display: grid; place-items: center; border: 0; border-radius: 50%; background: var(--brand-accent, #69983b); color: #0e291f; font-size: 1.4rem; font-weight: 900; cursor: pointer; }
.message-composer button:disabled { cursor: wait; opacity: .55; }
.account-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 1.2rem; }
.account-settings-grid { grid-template-columns: 1fr; margin-top: 1.2rem; }
.plan-card, .settings-card, .messenger { padding: clamp(1.8rem, 4vw, 3rem); }
.address-card { grid-column: 1 / -1; }
.profile-card { grid-column: 1 / -1; }
.profile-form { margin-top: 1.4rem; }
.security-card { padding: 0; overflow: hidden; }
.security-summary { min-height: 7rem; padding: clamp(1.8rem, 4vw, 3rem); display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; cursor: pointer; list-style: none; }
.security-summary::-webkit-details-marker { display: none; }
.security-summary span { min-width: 0; display: grid; gap: .55rem; }
.security-summary small { color: #647d64; font-size: .83rem; letter-spacing: .2em; font-weight: 900; }
.security-summary strong { font-size: 1.8rem; line-height: 1.1; }
.security-summary i { flex: 0 0 auto; color: var(--lime); font-size: 2rem; font-style: normal; line-height: 1; transition: transform .2s ease; }
.security-card[open] .security-summary i { transform: rotate(45deg); }
.security-summary:focus-visible { outline: 3px solid #dce9c1; outline-offset: -3px; }
.security-content { padding: 0 clamp(1.8rem, 4vw, 3rem) clamp(1.8rem, 4vw, 3rem); border-top: 1px solid var(--line); }
.security-content > h3 { margin-top: clamp(1.8rem, 4vw, 3rem); }
.tile-intro { max-width: 760px; color: #60736c; line-height: 1.6; }
.address-form { display: grid; grid-template-columns: minmax(0, .45fr) minmax(0, 1fr); gap: 1rem; margin-top: 1.4rem; }
.address-form .wide { grid-column: 1 / -1; }
.address-form button { justify-self: start; }
.autosave-field { display: block; }
.autosave-field input { padding-right: 3.6rem; }
.plan-card { color: white; background: var(--deep); border-color: var(--deep); }
.quota { font-size: clamp(3rem, 7vw, 5.8rem); font-weight: 900; line-height: 1; letter-spacing: -.07em; margin: 2rem 0 .6rem; }
.quota-label { color: #d8e4dc; }
.quota-sequence + .quota-sequence{margin-top:1.6rem;padding-top:1.6rem;border-top:1px solid rgba(255,255,255,.24)}
.quota-sequence.paid .quota{font-size:clamp(2.2rem,5vw,4rem);margin-top:1rem}
.plan-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
#account-bundles { margin-top: 1.2rem; }
.plan-actions button, .settings-card button { border: 1px solid currentColor; border-radius: 999px; padding: .8rem 1.1rem; background: transparent; font-weight: 850; cursor: pointer; }
.checkout-view { padding: clamp(1.5rem, 5vw, 4rem); }
.test-badge { display: inline-block; padding: .55rem .8rem; margin-bottom: 1.5rem; border-radius: 999px; background: #fff4ba; color: #624d00; font-size: .72rem; font-weight: 900; letter-spacing: .12em; }
.checkout-layout { display: grid; grid-template-columns: minmax(0, .75fr) minmax(0, 1.25fr); gap: clamp(1.5rem, 4vw, 3rem); align-items: start; }
.checkout-summary, .payment-panel { border: 1px solid var(--line); border-radius: 1.5rem; padding: clamp(1.3rem, 3vw, 2rem); }
.checkout-summary { background: #f0f2e7; }
.checkout-product-features { color: #60736c; }
.checkout-total { display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; margin: 2rem 0 1.25rem; padding-top: 1.25rem; border-top: 1px solid var(--line); }
.checkout-total strong { font-size: 1.7rem; }
.promotion { border-top: 1px solid var(--line); padding-top: 1rem; }
.promotion summary { cursor: pointer; font-weight: 850; list-style-position: inside; }
.promotion-form { padding-top: 1rem; }
.promotion-row { display: grid; grid-template-columns: 1fr auto; gap: .6rem; }
.promotion-row button { border: 0; border-radius: .9rem; padding: 0 1rem; background: var(--deep); color: white; font-weight: 850; }
#promotion-message, .checkout-message { min-height: 1.35em; margin: .7rem 0 0; color: #60736c; font-size: .85rem; line-height: 1.5; }
.payment-panel h3 { margin-bottom: 1.5rem; }
.checkout-divider { display: flex; align-items: center; gap: .9rem; margin: 1.25rem 0; color: #697a72; font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .12em; }
.checkout-divider::before, .checkout-divider::after { content: ''; height: 1px; flex: 1; background: var(--line); }
.payment-note { margin: 1.2rem 0; color: #697a72; font-size: .82rem; line-height: 1.55; }
#confirm-payment { margin-top: 1rem; border: 0; }

.modal-open { overflow: hidden; overscroll-behavior: none; }
.setup-dialog { width: 100%; max-width: none; max-height: 92dvh; margin: auto 0 0; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; scrollbar-width: none; border: 0; border-radius: 24px 24px 0 0; padding: 0; color: #173d31; background: #f9f8f2; box-shadow: 0 -20px 80px #142c2540; line-height: 1.55; }
.setup-dialog::-webkit-scrollbar { display: none; width: 0; height: 0; }
.setup-dialog::backdrop { background: #173d3180; backdrop-filter: blur(4px); }
.dialog-head { position: sticky; top: 0; z-index: 2; padding: 20px; display: flex; align-items: flex-start; justify-content: space-between; background: #f9f8f2; border-bottom: 1px solid #d9ddcf; }
.dialog-head span { font-size: 11px; line-height: normal; letter-spacing: 1.5px; color: #6f846d; }
.dialog-head h2 { margin: 7px 0 0; font-size: 28px; line-height: 1.15; letter-spacing: -1px; }
.dialog-head button { box-sizing: border-box; flex: 0 0 46px; width: 46px; min-width: 46px; max-width: 46px; height: 46px; min-height: 46px; max-height: 46px; aspect-ratio: 1; padding: 0; border: 1px solid #ccd3c7; border-radius: 50%; background: transparent; color: #173d31; display: grid; place-items: center; line-height: 1; -webkit-appearance: none; appearance: none; }
.dialog-head button svg { width: 21px; height: 21px; display: block; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.dialog-content { padding: 20px; overflow: visible; }
.dialog-intro { margin: 0 0 20px; color: #68796f; font-size: 15px; line-height: 1.65; }
.setup-grid { display: grid; gap: 8px; }
.method { min-height: 76px; border: 1px solid #d2d8cb; border-radius: 13px; padding: 13px; display: flex; align-items: center; gap: 11px; font-weight: 400; }
.method input { width: auto; flex: 0 0 auto; margin: 3px 3px 0 5px; padding: 0; border: 0; border-radius: 0; }
.method:has(input:checked) { border-color: #638c47; background: #edf3e3; }
.method span { display: flex; flex-direction: column; gap: 3px; }
.method b { font-size: 15px; }
.method small { color: #768378; font-size: 13px; font-weight: 400; line-height: 1.4; }
.method i { margin-left: auto; font-style: normal; }
.method-panel { margin-top: 12px; padding: 16px; border-radius: 13px; background: #ebeade; }
.method-panel > label { display: block; margin-bottom: 9px; font-size: 13px; font-weight: 800; }
.input-row { display: grid; gap: 8px; }
.input-row input { min-width: 0; min-height: 50px; padding: 0 13px; border: 1px solid #cbd2c6; border-radius: 10px; background: #fff; color: #173d31; }
.method-panel button { min-height: 50px; padding: 0 15px; border: 0; border-radius: 10px; background: #214d3e; color: white; font-size: 14px; font-weight: 800; }
.method-panel .text-button { min-height: 44px; padding: 12px 0 0; background: transparent; color: #607168; font-size: 12px; }
.method-panel a { text-decoration: underline; }
.provider-status { margin: 13px 0 0; color: #365d4e; font-size: 12px; font-weight: 750; line-height: 1.5; }
.provider-status.connected::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 7px; border-radius: 50%; background: #71a747; }
.budget-warning { margin: 12px 0 0; padding: 11px 12px; border: 1px solid #e2aaa5; border-radius: 9px; background: #fff1ef; color: #8d302a; font-size: 11px; font-weight: 700; line-height: 1.45; }
.method.budget-exhausted { border-color: #d59791; background: #fff3f1; }
.method.budget-exhausted small { color: #9b4038; font-weight: 750; }
.form-message { min-height: 1.3em; margin: 12px 0 0; color: #53743f; font-size: 13px; line-height: 1.5; }
.form-message.error { color: #a63f35; }
.device-code-copy { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.device-code-copy strong { display: inline-block; padding: 11px 14px; border-radius: 8px; background: white; font-size: 20px; letter-spacing: 2px; }
footer { padding: 26px 16px; border-top: 1px solid #d9ddcf; display: flex; align-items: center; justify-content: space-between; gap: 18px; background: #f5f4ed; color: #687970; }
footer p { max-width: 150px; margin: 0; color: #77837a; font-size: 11px; line-height: 1.55; text-align: right; }
footer p a { text-decoration: underline; text-underline-offset: .2em; }
[hidden] { display: none !important; }
button:disabled { opacity: .55; cursor: wait; }
@media (max-width: 760px) {
  main { padding-top: 3rem; }
  .hero { margin-bottom: 4rem; flex-direction: column-reverse; gap: 1.5rem; }
  .section-heading, .checkout-heading { align-items: flex-start; flex-direction: column; gap: .8rem; }
  .messenger-shell { height: auto; min-height: 0; grid-template-columns: 1fr; border-radius: 1.1rem; }
  .conversation-sidebar { max-height: 300px; border-right: 0; border-bottom: 1px solid var(--line); }
  .chat-panel { min-height: 520px; }
  .message-row { max-width: 88%; }
  .section-heading > p { width: auto; }
  .bundle-grid, .account-grid, .auth-card, .checkout-layout { grid-template-columns: 1fr; }
  .address-form { grid-template-columns: 1fr; }
  .address-form .wide { grid-column: auto; }
  .auth-card { gap: 2rem; }
  .setup-grid, .input-row { grid-template-columns: 1fr; }
}
@media (min-width: 520px) {
  .site-header, footer { padding-left: 28px; padding-right: 28px; }
  .setup-dialog { width: min(620px, calc(100% - 32px)); margin: auto; border-radius: 24px; }
  .setup-grid { grid-template-columns: 1fr 1fr; }
  .input-row { grid-template-columns: 1fr auto; }
  .method-panel .input-row button { min-width: 120px; }
}
@media (min-width: 820px) {
  .site-header { height: 78px; padding-left: 40px; padding-right: 40px; }
  footer { padding: 34px 40px; }
  footer p { max-width: none; font-size: 12px; }
}
@media (min-width: 1200px) {
  .setup-dialog { max-width: 650px; }
}

/* 16px prevents focus-triggered viewport zoom while keeping pinch zoom available. */
input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
select,
textarea {
  font-size: 16px !important;
}
