/* Dashboard pieces on top of app.css: metric cards, charts, editor, dialogs, toasts. */

.nav-link.as-button { border: 0; background: none; font: inherit; font-size: var(--fs-md); font-weight: 500; cursor: pointer; width: 100%; text-align: left; color: var(--ink-2); }
.switcher { width: 100%; margin: -8px 0 14px; }
.sidebar form { margin: 0; }

#toasts { position: fixed; right: 20px; bottom: 20px; display: flex; flex-direction: column; gap: 10px; z-index: 50; max-width: min(420px, calc(100vw - 32px)); }
.toast { padding: 12px 16px; border-radius: var(--r); background: var(--ink); color: var(--bg); font-weight: 500; box-shadow: var(--shadow-lg); }
.toast-danger { background: var(--danger); color: #FFFFFF; }

.alert { padding: 12px 16px; border-radius: var(--r); font-weight: 500; border: 1px solid transparent; }
.alert-danger { background: var(--danger-soft); color: var(--danger-ink); }
.alert-ok { background: var(--success-soft); color: var(--success-ink); }
.alert-info { background: var(--cobalt-soft); color: var(--cobalt-soft-ink); }

.auth { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px 16px; background: var(--surface-3); }
.auth .card { width: 100%; max-width: 420px; display: flex; flex-direction: column; gap: 16px; padding: 28px; box-shadow: var(--shadow-raised); }
.auth .brand { padding: 0; }
.code-input { font-size: 26px; letter-spacing: 10px; text-align: center; font-weight: 700; min-height: 54px; }

.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 8px; }
.toolbar .input { max-width: 320px; }
.pager { display: flex; gap: 8px; align-items: center; justify-content: flex-end; padding-top: 12px; }

dialog { border: 1px solid var(--line); border-radius: var(--r-xl); padding: 0; background: var(--surface); color: var(--ink); width: min(480px, calc(100vw - 32px)); box-shadow: var(--shadow-lg); }
dialog::backdrop { background: rgba(10, 10, 12, .5); backdrop-filter: blur(2px); }
dialog .card { box-shadow: none; border: 0; display: flex; flex-direction: column; gap: 14px; padding: 24px; }

/* ---------- Metric cards (overview) ---------- */
.metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 1280px) { .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .metrics { grid-template-columns: 1fr; } }
/* Number cards: a title, one big number, one line of context, and two figures in a quiet footer. */
.metric { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px 20px; display: flex; flex-direction: column; gap: 4px; }
.metric-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.metric-head h2 { font-size: var(--fs); font-weight: 500; color: var(--muted); letter-spacing: 0; }
.tile { width: 30px; height: 30px; border-radius: var(--r-sm); background: var(--surface-2); color: var(--ink-2); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.tile svg { width: 15px; height: 15px; }
.metric .v { font-size: 30px; font-weight: 700; letter-spacing: -0.03em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.metric .v .of { font-size: var(--fs-md); font-weight: 500; color: var(--muted); margin-left: 3px; letter-spacing: 0; }
.metric-note { font-size: var(--fs-sm); color: var(--muted); height: 22px; display: flex; align-items: center; }
.metric-foot { display: flex; justify-content: space-between; gap: 8px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line-soft); font-size: var(--fs-sm); color: var(--muted); }
.metric-foot strong { color: var(--ink); font-weight: 600; }
.delta { font-weight: 600; margin-right: 4px; }
.delta.up { color: var(--success-ink); }
.delta.down { color: var(--danger-ink); }
.axis { display: flex; justify-content: space-between; font-size: var(--fs-sm); color: var(--muted); margin-top: 6px; }
.split-row { display: flex; justify-content: space-between; font-size: var(--fs-sm); }
.split-row strong { font-weight: 600; }
.split-row span:last-child { color: var(--muted); }

.progress { height: 8px; border-radius: var(--pill); background: var(--surface-2); overflow: hidden; }
.progress > span { display: block; height: 100%; border-radius: var(--pill); background: var(--cobalt); }
.split-bar { display: flex; height: 18px; border-radius: var(--pill); overflow: hidden; background: var(--surface-2); }
.split-bar > span { height: 100%; background-image: repeating-linear-gradient(-45deg, rgba(255,255,255,.22) 0 6px, transparent 6px 12px); }
.legend { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.legend li { display: flex; align-items: center; gap: 10px; font-size: var(--fs-md); }
.legend li strong { margin-left: auto; font-weight: 600; font-variant-numeric: tabular-nums; }
.swatch { width: 12px; height: 12px; border-radius: 3px; flex-shrink: 0; }

.bars { display: flex; align-items: flex-end; gap: 6px; height: 44px; }
.bars > span { flex: 1; min-height: 6px; border-radius: 4px; background: var(--c-blue-soft); }
.bars > span.now { background: var(--c-blue); }

.panels { display: grid; grid-template-columns: minmax(0, 2.4fr) minmax(300px, 1fr); gap: 16px; }
@media (max-width: 1100px) { .panels { grid-template-columns: 1fr; } }
.panel-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.panel-head h2 { font-size: var(--fs-lg); }
.panel-head .actions { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.chart-key { display: flex; gap: 16px; font-size: var(--fs-sm); color: var(--muted); }
.chart-key span { display: inline-flex; align-items: center; gap: 6px; }
.chart-key i { width: 14px; height: 3px; border-radius: 2px; display: inline-block; }
.chart-key i.dashed { background: repeating-linear-gradient(90deg, var(--c-blue) 0 4px, transparent 4px 7px); }
svg.chart-svg { display: block; width: 100%; height: auto; overflow: visible; }
svg.chart-svg text { font: 500 12px var(--font); fill: var(--muted); }
.donut-wrap { position: relative; width: min(240px, 100%); margin: 8px auto 4px; }
.donut-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.donut-center .v { font-size: 36px; font-weight: 700; letter-spacing: -0.03em; line-height: 1; }
.donut-center span:last-child { color: var(--muted); font-size: var(--fs-md); margin-top: 6px; }

/* ---------- Editor ---------- */
.editor { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 420px); gap: 16px; align-items: start; }
.editor .textarea.body { min-height: 420px; font: 400 14px/1.65 ui-monospace, SFMono-Regular, Menlo, monospace; }
.editor-side { display: flex; flex-direction: column; gap: 16px; position: sticky; top: 20px; }
.preview-frame { width: 100%; height: 460px; border: 1px solid var(--line); border-radius: var(--r); background: #F5F6FA; }
.checks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.checks li { display: flex; gap: 10px; align-items: flex-start; font-size: var(--fs-sm); }
.checks svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px; }
.checks .ok svg { color: var(--success-ink); }
.checks .bad svg { color: var(--danger-ink); }
.checks .warn svg { color: var(--yellow-ink); }
.saved { font-size: var(--fs-xs); color: var(--muted); font-weight: 500; }
@media (max-width: 1080px) { .editor { grid-template-columns: 1fr; } .editor-side { position: static; } }

.timeline { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.timeline li { display: flex; gap: 10px; font-size: var(--fs-sm); }
.timeline svg { width: 16px; height: 16px; flex-shrink: 0; color: var(--muted); margin-top: 2px; }
.dropzone { border: 1.5px dashed var(--line); border-radius: var(--r-lg); padding: 32px; text-align: center; display: flex; flex-direction: column; gap: 10px; align-items: center; background: var(--surface-3); }
.key-reveal { font: 500 13px ui-monospace, Menlo, monospace; word-break: break-all; padding: 12px 14px; border-radius: var(--r-sm); background: var(--surface-2); border: 1px solid var(--line); }
.htmx-request .spinner-hide { opacity: .5; }
.hint svg, .alert svg { width: 14px; height: 14px; vertical-align: -2px; }
.badge svg { width: 12px; height: 12px; }
.seg-label { display: inline-flex; align-items: center; gap: 8px; padding: 0 14px; min-height: 36px; color: var(--ink-2); font-weight: 500; border-right: 1px solid var(--line); }
.seg-label + a { border-left: 0; }
.seg a { text-decoration: none; }
.metric-note .badge { padding: 1px 8px; line-height: 20px; }

/* ---------- Lists with status pills (domains) ---------- */
.tile-lg { width: 40px; height: 40px; border-radius: var(--r); }
.tile-lg svg { width: 20px; height: 20px; }
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-weight: 500; font-size: var(--fs-sm); width: max-content; }
.back:hover { color: var(--ink); }
.back svg { width: 15px; height: 15px; }
.search { position: relative; flex: 1; display: block; }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--muted); }
.search .input { padding-left: 36px; max-width: none; }
.card.flush { padding: 0; overflow: hidden; }
.card.flush .table th { padding: 12px 20px; background: var(--surface-3); }
.card.flush .table td { padding: 16px 20px; }
.table-rows tr.clickable { cursor: pointer; }
.pill { display: inline-flex; align-items: center; gap: 7px; padding: 3px 10px; border: 1px solid var(--line); border-radius: var(--pill); background: var(--surface); font-size: var(--fs-sm); font-weight: 500; white-space: nowrap; color: var(--ink-2); }
.pill .dot { width: 7px; height: 7px; }
.pill-ok .dot { color: var(--success); }
.pill-wait .dot { color: var(--c-orange); }
.pill-bad .dot { color: var(--danger); }
.pill-none .dot { color: var(--subtle); }
.danger-text { color: var(--danger-ink); }
h1 .pill { font-size: var(--fs-sm); letter-spacing: 0; }

/* ---------- Editor: the email's header, like a mail client's ---------- */
.envelope { padding: 4px 20px; }
.env-row { display: flex; align-items: center; gap: 14px; min-height: 52px; border-bottom: 1px solid var(--line-soft); }
.env-row:last-child { border-bottom: 0; }
.env-label { flex: 0 0 64px; font-size: var(--fs-sm); color: var(--muted); font-weight: 500; }
.env-input { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--ink); font: 400 var(--fs-md) var(--font); padding: 8px 0; outline: none; }
.env-input:focus-visible { box-shadow: inset 0 -2px 0 var(--cobalt); border-radius: 0; }
select.env-input { cursor: pointer; padding-right: 8px; }
.env-subject { font-weight: 600; }
.env-from { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.env-name { flex: 0 1 150px; font-weight: 600; }
.env-address { flex: 1 1 320px; min-width: 0; display: inline-flex; align-items: center; gap: 2px; padding: 3px 4px 3px 10px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface-3); }
.env-address .env-input { font-size: var(--fs); padding: 5px 0; }
.env-local { flex: 0 1 170px; min-width: 60px; text-align: right; }
.env-local[readonly] { color: var(--muted); }
.env-at { color: var(--muted); font-weight: 500; }
.env-domain { flex: 1 1 auto; }
.env-hint { display: inline-flex; align-items: center; gap: 4px; font-size: var(--fs-sm); white-space: nowrap; }
.env-hint svg { width: 14px; height: 14px; }
.sender-avatar { background: var(--cobalt); color: #FFFFFF; border: 0; border-radius: 50%; }
.inbox-row { display: flex; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface-3); }
.inbox-text { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.inbox-top { display: flex; justify-content: space-between; gap: 8px; font-size: var(--fs); }
.inbox-top .muted { font-size: var(--fs-xs); }
.inbox-subject { font-weight: 600; font-size: var(--fs); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inbox-preview { color: var(--muted); font-size: var(--fs-sm); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 640px) { .env-row { flex-wrap: wrap; gap: 4px; padding: 8px 0; } .env-label { flex-basis: 100%; } }

/* Plans: the billing page and the public pricing page */
.plan-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 960px) { .plan-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .plan-grid { grid-template-columns: 1fr; } }
.plan { gap: 12px; }
.plan-featured { border-color: var(--cobalt); box-shadow: 0 0 0 1px var(--cobalt); }
.plan-head { justify-content: space-between; gap: 8px; }
.plan-head h2 { font-size: var(--fs-lg); }
.plan-volume { font-weight: 600; font-size: var(--fs-lg); margin: 0; }
.plan-volume .muted { font-weight: 400; font-size: var(--fs-sm); }
.plan-price { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; margin: 0; }
.plan-amount { font-size: 32px; font-weight: 800; letter-spacing: -0.02em; }
.plan .btn { margin-top: auto; justify-content: center; }
.btn-cta { box-shadow: 0 8px 22px color-mix(in srgb, var(--cobalt) 38%, transparent); }
.btn-cta:hover { background: var(--cobalt-hover); box-shadow: 0 10px 26px color-mix(in srgb, var(--cobalt) 48%, transparent); }
.btn-cta svg { width: 16px; height: 16px; }
.btn-dark:hover { opacity: 0.88; }
.pricing { max-width: 1040px; margin: 0 auto; padding: 24px 16px 48px; display: flex; flex-direction: column; gap: 28px; }
.pricing-head { display: flex; align-items: center; justify-content: space-between; }
.pricing-head .brand { padding: 0; }
.pricing-hero { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 14px; padding: 24px 0 8px; }
.pricing-hero h1 { font-size: clamp(28px, 5vw, 44px); letter-spacing: -0.03em; margin: 0; }
.pricing-hero .sub { max-width: 560px; margin: 0; }
.pricing-foot { text-align: center; font-size: var(--fs-sm); }

/* Emails: the activity log and one email's page */
.t-clip { max-width: 360px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.facts { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 10px 20px; margin: 0; font-size: var(--fs); }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; overflow-wrap: anywhere; }
.timeline li.done { justify-content: space-between; padding-left: 16px; position: relative; }
.timeline li.done::before { content: ""; position: absolute; left: 0; top: 6px; width: 8px; height: 8px; border-radius: 999px; background: var(--success); }
.timeline li.bad::before { background: var(--danger); }
pre.code { margin: 0; padding: 16px; border-radius: var(--r); background: var(--surface-2); border: 1px solid var(--line); overflow-x: auto; font: 500 13px/1.6 ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px 16px; }
.check { display: flex; align-items: center; gap: 8px; font-size: var(--fs); cursor: pointer; }

/* Bulk selection: a checkbox column and a bar that floats at the bottom while rows are ticked */
.check-col { width: 44px; padding-right: 0 !important; }
.check-col label { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; margin: -8px 0 -8px -8px; border-radius: var(--r-xs); cursor: pointer; }
.check-col label:hover { background: var(--surface-2); }
/* Drawn by hand, so it's the same in every browser: a quiet outline, cobalt when ticked, a dash for "some" */
.check-col input { appearance: none; -webkit-appearance: none; margin: 0; display: grid; place-content: center; width: 18px; height: 18px; border: 1.5px solid color-mix(in srgb, var(--muted) 55%, transparent); border-radius: 5px; background: var(--surface); cursor: pointer; transition: background .12s, border-color .12s, box-shadow .12s; }
.check-col input::before { content: ""; width: 10px; height: 10px; background: #fff; transform: scale(0); transition: transform .12s ease-out; clip-path: polygon(14% 44%, 0 65%, 40% 100%, 100% 23%, 86% 9%, 39% 70%); }
.check-col label:hover input { border-color: var(--cobalt); }
.check-col input:checked, .check-col input:indeterminate { background: var(--cobalt); border-color: var(--cobalt); }
.check-col input:checked::before { transform: scale(1); }
.check-col input:indeterminate::before { transform: scale(1); height: 2px; clip-path: none; border-radius: 1px; }
.check-col input:focus { outline: none; }
.check-col input:focus-visible { outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--cobalt) 35%, transparent); }
.table tbody tr:has(.check-col input:checked) { background: color-mix(in srgb, var(--cobalt-soft) 70%, transparent); }
.table tbody tr:has(.check-col input:checked):hover { background: var(--cobalt-soft); }
.bulk-bar { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 40; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: center; max-width: calc(100vw - 32px); padding: 8px 8px 8px 16px; border-radius: var(--r-lg); background: var(--tile); color: var(--on-tile); box-shadow: var(--shadow-lg); }
.bulk-bar[hidden] { display: none; }
.bulk-count { font-weight: 600; font-size: var(--fs); margin-right: 6px; white-space: nowrap; }
.bulk-bar .btn-ghost { background: transparent; color: var(--on-tile); border-color: rgba(255, 255, 255, 0.22); }
.bulk-bar .btn-ghost:hover { background: rgba(255, 255, 255, 0.1); }
.bulk-tag { width: 140px; min-height: 32px; padding: 0 10px; background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.22); color: var(--on-tile); }
.bulk-tag::placeholder { color: rgba(255, 255, 255, 0.55); }

/* Upgrade prompts: the sidebar card (no plan yet) and the banner on Overview and Campaigns */
.upsell { position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 3px; padding: 12px 14px; border-radius: var(--r); background: var(--cobalt); color: var(--on-cobalt); box-shadow: 0 8px 22px color-mix(in srgb, var(--cobalt) 35%, transparent); transition: transform .15s, box-shadow .15s; }
.upsell::after { content: ""; position: absolute; right: -24px; top: -24px; width: 84px; height: 84px; border-radius: 50%; background: rgba(255, 255, 255, 0.12); }
.upsell:hover { transform: translateY(-1px); box-shadow: 0 12px 28px color-mix(in srgb, var(--cobalt) 45%, transparent); }
.upsell strong { font-size: var(--fs); font-weight: 700; letter-spacing: -0.01em; }
.upsell-tag { align-self: flex-start; margin-bottom: 4px; padding: 2px 8px; border-radius: var(--pill); background: var(--yellow); color: #3D2E00; font-size: 10px; font-weight: 700; letter-spacing: 0.02em; text-transform: uppercase; }
.upsell-sub { color: var(--on-cobalt-muted); font-size: var(--fs-xs); }
.upsell-cta { margin-top: 6px; display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-sm); font-weight: 700; }
.upsell-cta svg { width: 14px; height: 14px; transition: transform .15s; }
.upsell:hover .upsell-cta svg { transform: translateX(3px); }

.upgrade { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 18px 22px; padding: 18px 22px; border: 1px solid color-mix(in srgb, var(--cobalt) 35%, var(--line)); border-radius: var(--r-xl); background: var(--cobalt-soft); }
.upgrade-icon { width: 44px; height: 44px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; background: var(--cobalt); color: var(--on-cobalt); box-shadow: 0 6px 16px color-mix(in srgb, var(--cobalt) 35%, transparent); }
.upgrade-icon svg { width: 22px; height: 22px; fill: currentColor; stroke: none; }
.upgrade-text h2 { margin: 0 0 4px; font-size: var(--fs-lg); color: var(--ink); letter-spacing: -0.02em; }
.upgrade-text p { margin: 0; color: var(--ink-2); font-size: var(--fs); line-height: 1.5; }
.upgrade-offer { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; white-space: nowrap; }
.upgrade-price { color: var(--muted); font-size: var(--fs-sm); }
.upgrade-price b { color: var(--ink); font-size: 28px; font-weight: 800; letter-spacing: -0.03em; }
.upgrade-note { color: var(--cobalt-soft-ink); font-size: var(--fs-xs); font-weight: 600; }
.upgrade-actions { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.upgrade-actions .btn svg { width: 16px; height: 16px; }
.upgrade-link { color: var(--muted); font-size: var(--fs-xs); }
.upgrade-link:hover { color: var(--ink); }
.upgrade-warn { background: var(--yellow-soft); border-color: color-mix(in srgb, var(--c-orange) 40%, var(--line)); }
.upgrade-warn .upgrade-icon { background: var(--c-orange); box-shadow: none; }
@media (max-width: 1100px) { .upgrade { grid-template-columns: auto minmax(0, 1fr); } .upgrade-offer { align-items: flex-start; } .upgrade-actions { align-items: flex-start; flex-direction: row; } }

/* Admin panel */
.admin-badge { display: inline-flex; align-items: center; padding: 1px 7px; border-radius: var(--pill); background: var(--danger-soft); color: var(--danger-ink); font-size: 10px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.admin-app .brand { gap: 8px; }
.count-hot { margin-left: auto; min-width: 18px; padding: 0 6px; border-radius: var(--pill); background: var(--danger); color: #FFFFFF !important; font-weight: 700 !important; text-align: center; }
.admin-log { list-style: none; margin: 0; padding: 0 20px 16px; display: flex; flex-direction: column; }
.admin-log li { padding: 10px 0; border-top: 1px solid var(--line-soft); font-size: var(--fs-sm); }
.admin-log li:first-child { border-top: 0; }
.admin-log b { text-transform: capitalize; }
.danger-zone { border: 1px solid color-mix(in srgb, var(--danger) 30%, var(--line)); border-radius: var(--r); padding: 10px 14px; }
.danger-zone summary { cursor: pointer; color: var(--danger-ink); font-weight: 600; font-size: var(--fs-sm); }
.danger-zone[open] summary { margin-bottom: 10px; }
.plan-form-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 900px) { .plan-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.setting-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 320px); gap: 20px; align-items: start; padding: 14px 0; border-bottom: 1px solid var(--line-soft); }
.setting-row:last-of-type { border-bottom: 0; }
.setting-row .hint { margin: 2px 0 0; }
@media (max-width: 700px) { .setting-row { grid-template-columns: 1fr; gap: 8px; } }
a.alert { text-decoration: none; }

/* Settings: each section is a label on the left and its card on the right; one column on phones */
.settings { display: flex; flex-direction: column; gap: 28px; max-width: 960px; }
.settings-row { display: grid; grid-template-columns: minmax(0, 240px) minmax(0, 1fr); gap: 24px; align-items: start; }
.settings-label h2 { font-size: var(--fs-lg); }
.settings-label p { margin-top: 4px; color: var(--muted); font-size: var(--fs-sm); }
.settings-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; margin: 0; }
.settings-facts dt { color: var(--muted); font-size: var(--fs-sm); margin-bottom: 4px; }
.settings-facts dd { margin: 0; font-weight: 600; }
.settings-team { list-style: none; margin: 0; padding: 0; }
.settings-team li { display: flex; align-items: center; gap: 12px; padding: 14px 20px; border-bottom: 1px solid var(--line-soft); }
.settings-team li:last-child { border-bottom: 0; }
.settings-team-who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.settings-team-who .muted { font-size: var(--fs-sm); font-weight: 400; }
.settings-danger { border-color: color-mix(in srgb, var(--danger-ink) 30%, var(--line)); }
.input[readonly] { background: var(--surface-2); color: var(--muted); }
@media (max-width: 760px) { .settings-row { grid-template-columns: 1fr; gap: 10px; } }

/* Campaigns list: status counts, filters on the right, and rates with a small bar */
.seg-count { margin-left: 2px; color: var(--muted); font-size: var(--fs-xs); font-variant-numeric: tabular-nums; }
.toolbar-end { margin-left: auto; display: flex; gap: 8px; }
.select-sm { min-height: 34px; padding-top: 0; padding-bottom: 0; font-size: var(--fs-sm); width: auto; }
.rate { display: inline-grid; grid-template-columns: auto 56px; align-items: center; gap: 2px 10px; }
.rate-v { font-weight: 600; }
.rate-bar { height: 4px; border-radius: var(--pill); background: var(--line); overflow: hidden; }
.rate-bar > span { display: block; height: 100%; background: var(--cobalt); border-radius: var(--pill); }
.rate-n { grid-column: 1 / -1; color: var(--muted); font-size: var(--fs-xs); }

/* Campaign report */
.stats-5 { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.report-card { display: flex; flex-direction: column; gap: 16px; }
.report-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.report-kicker { color: var(--muted); font-size: var(--fs-sm); margin-bottom: 2px; }
.report-head h2 { font-size: var(--fs-lg); letter-spacing: -0.01em; }
.report-foot { color: var(--muted); font-size: var(--fs-sm); }
.chart-legend { display: flex; gap: 14px; color: var(--muted); font-size: var(--fs-sm); }
.chart-legend span { display: inline-flex; align-items: center; gap: 6px; }
.key { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.key-opens { background: color-mix(in srgb, var(--cobalt) 28%, var(--surface-2)); }
.key-clicks, .key-top { background: var(--cobalt); }
.chart { display: grid; grid-template-columns: auto 1fr; gap: 10px; }
.chart-y { display: flex; flex-direction: column; justify-content: space-between; height: 200px; color: var(--muted); font-size: var(--fs-xs); text-align: right; font-variant-numeric: tabular-nums; transform: translateY(-6px); }
.chart-plot { position: relative; height: 200px; margin-bottom: 26px; }
.chart-plot svg { display: block; width: 100%; height: 100%; overflow: visible; }
.chart-plot .grid { stroke: var(--line); stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
.bar-opens { fill: color-mix(in srgb, var(--cobalt) 28%, var(--surface-2)); }
.bar-opens.bar-peak { fill: color-mix(in srgb, var(--cobalt) 45%, var(--surface-2)); }
.bar-clicks { fill: var(--cobalt); pointer-events: none; }
.chart-plot rect:hover { opacity: .8; }
.chart-peak { position: absolute; transform: translate(-50%, -4px); font-size: var(--fs-xs); font-weight: 600; color: var(--ink); pointer-events: none; }
.chart-x { position: absolute; left: 0; right: 0; top: calc(100% + 8px); height: 16px; color: var(--muted); font-size: var(--fs-xs); }
.chart-x span { position: absolute; white-space: nowrap; }
.chart-x span + span { transform: translateX(-50%); }
.report-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
@media (max-width: 960px) { .report-grid { grid-template-columns: 1fr; } }
.card-pad { padding-left: 20px; padding-right: 20px; }
.card.flush > .card-head { padding-top: 16px; margin-bottom: 8px; }
.card.flush > .hint { padding-bottom: 16px; margin: 0; }
.link-list { list-style: none; margin: 0; padding: 0 20px; display: flex; flex-direction: column; gap: 14px; }
.link-row { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 6px; font-size: var(--fs); }
.link-url { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink); }
.link-url:hover { color: var(--cobalt); }
.link-n { color: var(--muted); white-space: nowrap; }
.link-n b { color: var(--ink); font-weight: 600; }
.link-list + .hint { margin-top: 14px !important; }
.card.flush .table-tight th, .card.flush .table-tight td { padding: 10px 14px; }
.card.flush .table-tight th:first-child, .card.flush .table-tight td:first-child { padding-left: 20px; }
.link-list .meter { display: block; height: 5px; }
.inbox { display: flex; align-items: center; gap: 10px; }
.inbox > span:last-child { display: flex; flex-direction: column; }
.inbox-dot { width: 26px; height: 26px; border-radius: 8px; display: inline-grid; place-content: center; font-size: 12px; font-weight: 700; color: #fff; background: #71717A; flex-shrink: 0; }
.inbox-gmail { background: #EA4335; }
.inbox-outlook { background: #0F6CBD; }
.inbox-icloud { background: #3B9BF5; }
.inbox-yahoo { background: #6001D2; }
.inbox-proton { background: #6D4AFF; }
.share { display: inline-flex; align-items: center; gap: 8px; }
.meter-sm { width: 56px; height: 4px; }
.clickmap-frame { height: 560px; }
.filter-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.filter-chip span { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 0 12px; border-radius: var(--pill); border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); font-size: var(--fs-sm); cursor: pointer; transition: background .12s, border-color .12s; }
.filter-chip span:hover { border-color: var(--cobalt); }
.filter-chip b { font-weight: 600; color: var(--muted); }
.filter-chip input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--surface); }
.filter-chip input:checked + span b { color: inherit; opacity: .7; }
.filter-chip input:focus-visible + span { box-shadow: 0 0 0 3px color-mix(in srgb, var(--cobalt) 35%, transparent); }
.card.flush > .toolbar { padding-bottom: 8px; }
.card.flush > .toolbar .input { margin-left: auto; }
.card.flush > .pager { padding-bottom: 16px; }
.card.flush > p.muted { padding-bottom: 20px; }

/* Notifications: a bell beside the logo, and a drawer from the right */
.brand-row { display: flex; align-items: center; justify-content: space-between; padding-right: 2px; }
.brand-row .brand { padding-bottom: 0; }
.brand-row { padding-bottom: 14px; }
.bell { position: relative; }
.bell-dot { position: absolute; top: 1px; right: 0; min-width: 16px; height: 16px; padding: 0 4px; border-radius: var(--pill); background: var(--danger-ink); color: #fff; font-size: 10px; font-weight: 700; line-height: 16px; text-align: center; box-shadow: 0 0 0 2px var(--sidebar); }
dialog.drawer { margin: 0 0 0 auto; height: 100vh; max-height: 100vh; width: min(400px, 100vw); border-radius: 0; border-width: 0 0 0 1px; display: none; flex-direction: column; }
dialog.drawer[open] { display: flex; animation: drawer-in .18s ease-out; }
@keyframes drawer-in { from { transform: translateX(24px); opacity: 0; } }
.drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.drawer-head h2 { font-size: var(--fs-lg); }
#notifications-list { overflow-y: auto; flex: 1; }
.drawer-empty { padding: 32px 20px; }
.notif-list { list-style: none; margin: 0; padding: 8px; }
.notif a { display: flex; gap: 12px; padding: 12px; border-radius: var(--r); color: var(--ink); }
.notif a:hover { background: var(--surface-2); }
.notif-new a { background: color-mix(in srgb, var(--cobalt-soft) 60%, transparent); }
.notif-icon { width: 32px; height: 32px; flex-shrink: 0; border-radius: 10px; display: grid; place-content: center; background: var(--surface-2); color: var(--ink-2); }
.notif-icon svg { width: 16px; height: 16px; }
.notif-campaign_sent { background: var(--success-soft); color: var(--success-ink); }
.notif-campaign_paused, .notif-domain_broken { background: var(--danger-soft); color: var(--danger-ink); }
.notif-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; font-size: var(--fs); }
.notif-text span { color: var(--ink-2); font-size: var(--fs-sm); }
.notif-text time { color: var(--muted); font-size: var(--fs-xs); }

/* Audience: segments as tabs, filters as removable pills */
.segment-tabs { display: flex; gap: 4px; flex-wrap: wrap; border-bottom: 1px solid var(--line); margin-bottom: -4px; }
.segment-tabs a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; margin-bottom: -1px; border-bottom: 2px solid transparent; color: var(--muted); font-weight: 500; font-size: var(--fs); }
.segment-tabs a:hover { color: var(--ink); }
.segment-tabs a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--cobalt); }
.segment-tabs .num { font-size: var(--fs-xs); color: var(--muted); background: var(--surface-2); padding: 1px 7px; border-radius: var(--pill); }
.filter-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 4px 0 10px; }
.filter-pill { display: inline-flex; align-items: center; gap: 6px; min-height: 30px; padding: 0 8px 0 12px; border-radius: var(--pill); background: var(--cobalt-soft); color: var(--cobalt-soft-ink); font-size: var(--fs-sm); font-weight: 500; }
.filter-pill svg { width: 13px; height: 13px; opacity: .6; }
.filter-pill:hover svg { opacity: 1; }
.add-filter { position: relative; }
.add-filter summary { list-style: none; }
.add-filter summary::-webkit-details-marker { display: none; }
.add-filter-panel { position: absolute; top: calc(100% + 6px); left: 0; z-index: 20; width: 300px; display: flex; flex-direction: column; gap: 10px; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); }
.add-filter-panel input[hidden] { display: none; }
.filter-bar-end { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; }
.tag-chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 4px 2px 10px; border-radius: var(--r-sm); background: var(--surface-2); }
.tag-chip code { font-size: var(--fs-sm); }
.tag-chip .icon-btn { width: 26px; height: 26px; }
.input-inline { min-height: 34px; max-width: 240px; background: transparent; border-color: transparent; font-weight: 600; }
.input-inline:hover, .input-inline:focus { border-color: var(--line); background: var(--surface); }
.restore-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-top: 16px; padding-bottom: 16px; border-top: 1px solid var(--line); }

/* Contact profile */
.profile-head { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.profile-avatar { width: 64px; height: 64px; border-radius: 18px; font-size: 24px; background: var(--cobalt-soft); color: var(--cobalt-soft-ink); border: 0; }
.profile-who { flex: 1; min-width: 200px; }
.profile-who h1 { font-size: 26px; letter-spacing: -0.02em; }
.profile-email { display: flex; align-items: center; gap: 4px; color: var(--muted); }
.profile-email .icon-btn { width: 28px; height: 28px; }
.profile-head .actions { display: flex; align-items: center; gap: 8px; }
.profile-stats { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.main details.menu { position: relative; }
.main details.menu > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; }
.main details.menu > summary::-webkit-details-marker { display: none; }
.main details.menu > summary svg { width: 16px; height: 16px; }
.main .menu-panel { position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; min-width: 220px; padding: 8px; display: flex; flex-direction: column; gap: 4px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); }
.status-panel { width: 280px; gap: 8px !important; padding: 12px !important; }
.radio-row { display: flex; gap: 10px; align-items: flex-start; padding: 8px; border-radius: var(--r-sm); cursor: pointer; }
.radio-row:hover { background: var(--surface-2); }
.radio-row input { margin-top: 3px; accent-color: var(--cobalt); }
.radio-row > span { display: flex; flex-direction: column; font-size: var(--fs); }
.radio-row .muted { font-size: var(--fs-sm); }
.menu-item { text-align: left; padding: 9px 12px; border: 0; border-radius: var(--r-sm); background: transparent; color: var(--ink); font: 500 var(--fs) var(--font); cursor: pointer; }
.menu-item:hover { background: var(--surface-2); }
.menu-item.danger { color: var(--danger-ink); }
.tabs { display: flex; flex-direction: column; gap: 12px; }
.tab-list { display: flex; gap: 4px; border-bottom: 1px solid var(--line); }
.tab-list [role="tab"] { display: inline-flex; align-items: center; gap: 8px; padding: 10px 12px; margin-bottom: -1px; border: 0; border-bottom: 2px solid transparent; background: none; color: var(--muted); font: 500 var(--fs) var(--font); cursor: pointer; }
.tab-list [role="tab"] svg { width: 16px; height: 16px; }
.tab-list [role="tab"][aria-selected="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.activity { list-style: none; margin: 0; padding: 8px 20px; }
.activity li { position: relative; display: flex; align-items: center; gap: 14px; padding: 12px 0; }
.activity li:not(:last-child)::before { content: ""; position: absolute; left: 15px; top: 44px; bottom: -12px; width: 1px; background: var(--line); }
.activity-icon { width: 32px; height: 32px; flex-shrink: 0; border-radius: 50%; display: grid; place-content: center; background: var(--surface-2); color: var(--muted); }
.activity-icon svg { width: 15px; height: 15px; }
.activity-ok { background: var(--success-soft); color: var(--success-ink); }
.activity-bad { background: var(--danger-soft); color: var(--danger-ink); }
.activity-text { flex: 1; min-width: 0; display: flex; flex-direction: column; font-size: var(--fs); }
.activity-text a { color: var(--ink); }
.activity-text a:hover b { color: var(--cobalt); }
.activity time { color: var(--muted); font-size: var(--fs-sm); white-space: nowrap; }
.about-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px 24px; margin: 0; }
.about-list dt { color: var(--muted); font-size: var(--fs-sm); margin-bottom: 4px; }
.about-list dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }
.dialog-head { display: flex; align-items: center; justify-content: space-between; }
.field-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.add-field-link { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px dashed var(--line); border-radius: var(--r-sm); background: none; color: var(--muted); font: 500 var(--fs-sm) var(--font); cursor: pointer; }
.add-field-link:hover { color: var(--ink); border-color: var(--muted); }
.add-field-link svg { width: 14px; height: 14px; }
dialog form.card { max-height: calc(100vh - 64px); overflow-y: auto; }

/* ---------- Block editor ---------- */
.doc { padding: 36px 28px 48px 64px; }
.block-editor { min-height: 360px; display: flex; flex-direction: column; gap: 2px; font-size: 17px; line-height: 1.65; color: var(--ink); cursor: text; }
.block-editor .blocks { display: flex; flex-direction: column; gap: 2px; }
.block { position: relative; border-radius: var(--r-sm); }
.block.is-dragging { opacity: .35; }
.block.drop-before { box-shadow: 0 -3px 0 var(--cobalt); }
.block.drop-after { box-shadow: 0 3px 0 var(--cobalt); }
.b-gutter { position: absolute; left: -54px; top: 4px; display: flex; gap: 2px; opacity: 0; transition: opacity .12s; }
.block:hover > .b-gutter, .block:focus-within > .b-gutter { opacity: 1; }
.b-gutter button { width: 24px; height: 26px; display: grid; place-content: center; border: 0; border-radius: 6px; background: none; color: var(--muted); cursor: pointer; }
.b-gutter button:hover { background: var(--surface-2); color: var(--ink); }
.b-gutter svg { width: 16px; height: 16px; }
.b-handle { cursor: grab !important; }
.b-body { min-width: 0; }
.b-edit { outline: none; margin: 0; padding: 3px 2px; min-height: 1.65em; overflow-wrap: anywhere; }
.b-edit:empty::before, .b-btn:empty::before { content: attr(data-placeholder); color: var(--muted); opacity: .7; pointer-events: none; }
.block-text .b-edit:empty:not(:focus)::before { content: ""; }
.block-editor.is-empty .block-text:first-child .b-edit:empty::before, .b-section .block-text:only-child .b-edit:empty::before, .b-box .block-text:only-child .b-edit:empty::before { content: attr(data-placeholder); }
.block-editor h1.b-edit { font-size: 30px; line-height: 1.2; letter-spacing: -0.02em; margin-top: 14px; }
.block-editor h2.b-edit { font-size: 23px; line-height: 1.25; letter-spacing: -0.015em; margin-top: 12px; }
.block-editor h3.b-edit { font-size: 19px; line-height: 1.3; margin-top: 8px; }
.block-editor blockquote.b-edit { border-left: 3px solid var(--cobalt); padding-left: 16px; color: var(--ink-2); }
.block-editor ul.b-edit, .block-editor ol.b-edit { padding-left: 26px; }
.block-editor a { color: var(--cobalt); text-decoration: underline; text-underline-offset: 2px; }
.block-editor hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }
.block-editor hr:focus { outline: 2px solid var(--cobalt); outline-offset: 6px; }
.mtag { display: inline-block; padding: 0 6px; margin: 0 1px; border-radius: 6px; background: var(--surface-2); color: var(--ink); font: 500 .92em/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; cursor: pointer; user-select: all; }
.mtag:hover { background: var(--cobalt-soft); color: var(--cobalt-soft-ink); }
.b-image { display: flex; flex-direction: column; gap: 6px; margin: 8px 0; }
.b-image img { max-width: 100%; border-radius: 12px; display: block; }
.b-caption { border: 0; background: transparent; color: var(--muted); font: 400 var(--fs-sm) var(--font); padding: 2px; outline: none; }
.b-caption:focus { color: var(--ink); box-shadow: inset 0 -1px 0 var(--line); }
.b-image-empty { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 22px 18px; border: 1px dashed var(--line); border-radius: var(--r); color: var(--muted); text-align: center; transition: background .15s, border-color .15s; }
.b-image-empty > svg { width: 22px; height: 22px; }
.b-image-empty.drag { border-color: var(--cobalt); background: var(--cobalt-soft); }
.b-image-url { display: flex; gap: 6px; width: 100%; max-width: 420px; }
.b-image-url .input { flex: 1; min-width: 0; }
.b-upload { cursor: pointer; }
.b-button { display: flex; margin: 14px 0; }
.b-button.align-left { justify-content: flex-start; }
.b-button.align-center { justify-content: center; }
.b-button.align-right { justify-content: flex-end; }
.b-btn { display: inline-block; min-width: 80px; padding: 13px 26px; border-radius: 12px; background: #2440F5; color: #fff; font-weight: 700; font-size: 16px; text-align: center; outline: none; }
.b-btn:focus { box-shadow: 0 0 0 3px color-mix(in srgb, var(--cobalt) 30%, transparent); }
.b-btn:empty::before { color: rgba(255, 255, 255, .7); opacity: 1; }
.b-box { margin: 10px 0; padding: 14px 18px 14px 22px; border-radius: 14px; background: color-mix(in srgb, var(--cobalt-soft) 55%, var(--surface)); }
.b-box-label { font-size: var(--fs-xs); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 4px; }
.b-section { margin: 12px 0; padding: 12px 18px 16px 22px; border: 1.5px dashed var(--line); border-radius: 16px; }
.b-section-head { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 8px -4px; padding: 4px 6px 4px 10px; border-radius: var(--pill); background: var(--surface-2); font-size: var(--fs-sm); color: var(--ink-2); }
.b-section-head svg { width: 15px; height: 15px; }
.b-select { border: 0; background: transparent; color: var(--ink); font: 600 var(--fs-sm) var(--font); cursor: pointer; padding: 2px; max-width: 220px; }
.b-section .b-gutter, .b-box .b-gutter { left: -50px; }
.b-html { margin: 10px 0; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--surface); }
.b-html-head { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: var(--fs-sm); }
.b-html-head svg { width: 15px; height: 15px; }
.b-code { width: 100%; border: 0; resize: vertical; padding: 14px; background: transparent; color: var(--ink); font: 400 13.5px/1.6 ui-monospace, SFMono-Regular, Menlo, monospace; outline: none; }
.b-html-foot { margin: 0; padding: 9px 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: var(--fs-xs); }
.lint { position: absolute; right: -22px; top: 12px; width: 9px; height: 9px; border-radius: 50%; cursor: help; }
.lint-warn { background: #F59E0B; }
.lint-bad { background: var(--danger-ink); }
.lint:hover::after, .lint:focus::after { content: attr(data-tip); position: absolute; right: 18px; top: -10px; width: 260px; padding: 10px 12px; border-radius: 10px; background: #111114; color: #fff; font-size: 12.5px; line-height: 1.45; white-space: pre-line; z-index: 20; box-shadow: var(--shadow-lg); }
.doc { position: relative; }
.kbd-grip { letter-spacing: -2px; font-weight: 700; }
kbd { padding: 1px 6px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 6px; background: var(--surface); font: 600 .85em ui-monospace, monospace; }

/* The / menu, the {{ menu, a chip's fallback */
.slash-menu { position: absolute; z-index: 60; width: 340px; padding: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-lg); font-size: var(--fs); }
.slash-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; }
.slash-item { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 4px; border: 0; border-radius: 12px; background: none; color: var(--ink-2); font: 500 12.5px var(--font); cursor: pointer; }
.slash-icon { width: 38px; height: 38px; display: grid; place-content: center; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.slash-icon svg { width: 18px; height: 18px; }
.slash-icon-dashed { border-style: dashed; }
.slash-item:hover, .slash-item.is-active, .slash-section:hover, .slash-section.is-active, .field-row:hover, .field-row.is-active { background: var(--surface-2); }
.slash-group { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line); }
.slash-title { margin: 2px 4px 6px; color: var(--muted); font-size: var(--fs-sm); font-weight: 500; }
.slash-section { width: 100%; display: flex; align-items: center; gap: 12px; padding: 8px; border: 1.5px dashed var(--line); border-radius: 12px; background: none; text-align: left; cursor: pointer; color: var(--ink); }
.slash-section > span:last-child { display: flex; flex-direction: column; font-size: var(--fs); }
.slash-section .muted { font-size: var(--fs-sm); }
.slash-fields { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.slash-fields .slash-title { margin: 0 4px 0 2px; }
.field-chip { display: inline-flex; align-items: center; gap: 4px; padding: 5px 10px; border: 0; border-radius: 8px; background: var(--surface-2); color: var(--ink); font: 500 var(--fs-sm) var(--font); cursor: pointer; }
.field-chip:hover, .field-chip.is-active { background: var(--cobalt-soft); color: var(--cobalt-soft-ink); }
.field-chip-add { background: none; border: 1px dashed var(--line); color: var(--muted); }
.field-chip svg { width: 13px; height: 13px; }
.slash-empty { margin: 8px; }
.field-menu { width: 280px; }
.field-row { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 10px; border: 0; border-radius: 10px; background: none; color: var(--ink); font: 500 var(--fs) var(--font); cursor: pointer; text-align: left; }
.field-row code { color: var(--muted); font-size: 12px; }
.field-row-add { justify-content: flex-start; color: var(--muted); }
.field-row-add svg { width: 14px; height: 14px; }
.chip-pop { width: 280px; display: flex; flex-direction: column; gap: 10px; }

/* The block toolbar */
.b-toolbar { position: absolute; z-index: 50; display: flex; align-items: center; gap: 2px; padding: 4px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); }
.b-toolbar[hidden] { display: none; }
.b-toolbar .input { min-height: 32px; width: 240px; }
.b-tool { min-width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 0 6px; border: 0; border-radius: 9px; background: none; color: var(--ink-2); cursor: pointer; font: 500 var(--fs-sm) var(--font); }
.b-tool:hover { background: var(--surface-2); color: var(--ink); }
.b-tool.is-on { background: var(--surface-2); color: var(--ink); }
.b-tool svg { width: 16px; height: 16px; }
.b-tool-wide { padding: 0 10px; color: var(--muted); }
.b-sep { width: 1px; height: 18px; margin: 0 4px; background: var(--line); }

/* Preview: desktop inbox, or a phone */
.preview-dialog { width: min(1100px, calc(100vw - 32px)); height: calc(100vh - 48px); max-height: none; padding: 0; display: none; flex-direction: column; background: var(--surface-3); }
.preview-dialog[open] { display: flex; }
.preview-top { display: flex; align-items: center; gap: 16px; padding: 12px 16px; border-bottom: 1px solid var(--line); background: var(--surface); flex-wrap: wrap; }
.preview-top .icon-btn { margin-left: auto; }
.preview-as { display: flex; align-items: center; gap: 8px; }
.preview-as .label { margin: 0; white-space: nowrap; }
.preview-as .select { max-width: 320px; }
.preview-stage { flex: 1; overflow: auto; padding: 24px; }
.preview-stage[data-stage="desktop"] .pv-mobile, .preview-stage[data-stage="mobile"] .pv-desktop { display: none; }
.pv-desktop { max-width: 820px; margin: 0 auto; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.pv-mailhead { padding: 20px 24px 14px; border-bottom: 1px solid var(--line); }
.pv-mailhead h2 { font-size: 20px; margin-bottom: 12px; }
.pv-from { display: flex; gap: 12px; align-items: center; font-size: var(--fs); }
.pv-frame { width: 100%; height: 70vh; border: 0; display: block; background: #F5F6FA; }
.pv-mobile { display: flex; justify-content: center; }
.phone { width: 390px; padding: 14px; border-radius: 58px; background: #111114; box-shadow: 0 30px 60px rgba(0, 0, 0, .25), inset 0 0 0 2px #2a2a2e; }
.phone-screen { height: 780px; border-radius: 44px; overflow: hidden; background: #fff; color: #111; display: flex; flex-direction: column; }
.phone-status { position: relative; display: flex; align-items: center; justify-content: space-between; padding: 14px 28px 6px 34px; font-size: 15px; }
.phone-island { position: absolute; left: 50%; top: 10px; width: 112px; height: 32px; transform: translateX(-50%); border-radius: 20px; background: #000; }
.phone-icons { display: inline-flex; gap: 5px; align-items: center; }
.phone-icons i { display: inline-block; background: #111; border-radius: 2px; }
.phone-icons .sig { width: 17px; height: 11px; clip-path: polygon(0 100%, 25% 100%, 25% 70%, 37% 70%, 37% 100%, 50% 100%, 50% 40%, 62% 40%, 62% 100%, 75% 100%, 75% 10%, 87% 10%, 87% 100%, 100% 100%, 100% 0, 0 0); }
.phone-icons .wifi { width: 15px; height: 11px; border-radius: 50% 50% 0 0; clip-path: polygon(50% 100%, 0 20%, 100% 20%); }
.phone-icons .batt { width: 24px; height: 11px; border-radius: 3px; background: #34C759; box-shadow: 0 0 0 1px #111 inset; }
.phone-toolbar { display: flex; align-items: center; gap: 22px; padding: 8px 20px; color: #444; }
.phone-toolbar span { flex: 1; }
.phone-toolbar svg { width: 20px; height: 20px; }
.phone-subject { display: flex; align-items: flex-start; gap: 8px; padding: 6px 20px 10px; }
.phone-subject h3 { font-size: 21px; font-weight: 400; line-height: 1.3; color: #111; }
.phone-chip { margin-top: 5px; padding: 1px 6px; border-radius: 4px; background: #eee; color: #555; font-size: 12px; white-space: nowrap; }
.phone-sender { display: flex; gap: 10px; align-items: center; padding: 4px 20px 10px; font-size: 14px; color: #111; }
.phone-sender .muted { color: #666; }
.phone-frame { flex: 1; width: 100%; border: 0; background: #fff; }
.pv-note { text-align: center; margin-top: 14px; }
@media (max-width: 720px) { .doc { padding: 24px 18px 32px 40px; } .b-gutter { left: -36px; } .b-gutter .b-add { display: none; } .phone { transform: scale(.85); transform-origin: top center; } }
.past-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; max-height: 50vh; overflow-y: auto; }
.past-list button { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); color: var(--ink); text-align: left; cursor: pointer; }
.past-list button:hover { border-color: var(--cobalt); }
.past-list button > span { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.past-list b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.past-list .muted { font-size: var(--fs-sm); }
.past-list svg { width: 16px; height: 16px; color: var(--muted); flex-shrink: 0; }

/* Website: the controls on the left, the real site in a browser frame on the right */
.site-builder { display: grid; grid-template-columns: minmax(340px, 440px) 1fr; gap: 20px; align-items: start; }
.site-controls .card-title, .card-title { font-size: var(--fs-lg); }
.url-row { display: flex; align-items: center; gap: 6px; min-width: 0; }
.url-chip { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 8px 12px; border-radius: var(--r-sm); background: var(--surface-2); font-size: var(--fs-sm); }
.theme-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.theme-card { display: flex; flex-direction: column; gap: 2px; padding: 8px; border: 1px solid var(--line); border-radius: var(--r); cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.theme-card:hover { border-color: var(--muted); }
.theme-card:has(:checked) { border-color: var(--cobalt); box-shadow: 0 0 0 3px var(--cobalt-soft); }
.theme-card:has(:focus-visible) { outline: 2px solid var(--cobalt); outline-offset: 2px; }
.theme-swatch { position: relative; display: block; height: 78px; overflow: hidden; margin-bottom: 6px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08); }
.ts-bar { position: absolute; inset: 0 0 auto 0; height: 14px; }
.ts-title { position: absolute; left: 10px; right: 10px; top: 20px; font-weight: 800; font-size: 20px; line-height: 1; }
.ts-lines { position: absolute; left: 10px; top: 46px; display: flex; flex-direction: column; gap: 4px; width: 58%; }
.ts-lines i { display: block; height: 4px; border-radius: 2px; opacity: .45; }
.ts-lines i + i { width: 70%; }
.ts-btn { position: absolute; right: 10px; bottom: 10px; width: 28px; height: 12px; border-radius: 6px; }
.theme-name { font-weight: 600; font-size: var(--fs-sm); }
.theme-blurb { font-size: var(--fs-xs); color: var(--muted); line-height: 1.35; }
.color-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.color-input { width: 40px; height: 32px; padding: 0; border: 1px solid var(--line); border-radius: var(--r-sm); background: none; cursor: pointer; }
.color-input::-webkit-color-swatch-wrapper { padding: 3px; }
.color-input::-webkit-color-swatch { border: 0; border-radius: 5px; }
.swatch { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--surface); box-shadow: 0 0 0 1px var(--line); cursor: pointer; padding: 0; }
.swatch[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--ink); }
.hint-warn { color: var(--yellow-ink); display: flex; gap: 6px; align-items: flex-start; }
.hint-warn svg { width: 14px; height: 14px; flex-shrink: 0; margin-top: 2px; }
.font-picks { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.font-pick span { display: block; text-align: center; padding: 9px 6px; border: 1px solid var(--line); border-radius: var(--r-sm); cursor: pointer; font-size: var(--fs); }
.font-pick:hover span { border-color: var(--muted); }
.font-pick :checked + span { border-color: var(--cobalt); background: var(--cobalt-soft); color: var(--cobalt-soft-ink); font-weight: 600; }
.font-pick :focus-visible + span { outline: 2px solid var(--cobalt); outline-offset: 2px; }
.logo-row { display: flex; gap: 14px; align-items: flex-start; }
.logo-box { width: 64px; height: 64px; border-radius: var(--r); border: 1px dashed var(--line); display: flex; align-items: center; justify-content: center; color: var(--muted); flex-shrink: 0; overflow: hidden; background: var(--surface-3); }
.logo-box img { max-width: 100%; max-height: 100%; object-fit: contain; }
.file-btn { cursor: pointer; }
.domain-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.domain-steps li { display: flex; gap: 12px; align-items: flex-start; color: var(--muted); }
.domain-steps li > div { min-width: 0; flex: 1; }
.domain-steps li strong { color: var(--ink); }
.domain-steps .step-n { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--line); display: inline-flex; align-items: center; justify-content: center; font-size: var(--fs-xs); font-weight: 600; flex-shrink: 0; }
.domain-steps .now .step-n { border-color: var(--cobalt); color: var(--cobalt); }
.domain-steps .done .step-n { background: var(--cobalt); border-color: var(--cobalt); color: #fff; }
.dns-table { margin-top: 8px; font-size: var(--fs-sm); }
.dns-table td { vertical-align: middle; padding: 6px 8px; }
.dns-table code { word-break: break-all; }
.site-preview { position: sticky; top: 16px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.site-preview .preview-top { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.browser { border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: var(--surface); box-shadow: var(--shadow); margin: 0 auto; width: 100%; transition: width .2s; }
.browser[data-device="mobile"] { width: 390px; max-width: 100%; border-radius: 36px; border-width: 10px; border-color: #111114; }
.browser-bar { display: flex; align-items: center; gap: 6px; padding: 10px 12px; border-bottom: 1px solid var(--line); background: var(--surface-3); }
.browser-bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--line); }
.browser[data-device="mobile"] .browser-bar i { display: none; }
.browser-url { flex: 1; margin-left: 8px; padding: 4px 10px; border-radius: 999px; background: var(--surface); font-size: var(--fs-xs); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: center; }
.site-frame { display: block; width: 100%; height: calc(100vh - 170px); min-height: 560px; border: 0; background: #fff; }
.browser[data-device="mobile"] .site-frame { height: 720px; }
@media (max-width: 1100px) {
  .site-builder { grid-template-columns: 1fr; }
  .site-preview { position: static; }
  .site-frame { height: 640px; }
}
/* The editor: a web-only issue has no sender or recipients to pick; its preview can be the web page */
.envelope:has(select[name="channel"] option[value="web"]:checked) .env-mail { display: none; }
.preview-web { flex: 1; display: flex; padding: 16px 24px 24px; min-height: 0; }
.preview-web[hidden] { display: none; }
.preview-web .site-frame { flex: 1; height: auto; min-height: 0; border: 1px solid var(--line); border-radius: var(--r-lg); }
.web-card { display: flex; align-items: center; gap: 14px; padding: 14px 18px; flex-wrap: wrap; }
.web-card-icon { width: 36px; height: 36px; border-radius: 50%; background: var(--cobalt-soft); color: var(--cobalt-soft-ink); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.web-card-icon svg { width: 18px; height: 18px; }

/* ⌘K */
.cmd-open { display: flex; align-items: center; gap: 8px; width: 100%; margin: 4px 0 10px; padding: 7px 10px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); color: var(--muted); font: 500 var(--fs-sm) var(--font); cursor: pointer; text-align: left; }
.cmd-open:hover { border-color: var(--muted); color: var(--ink); }
.cmd-open svg { width: 15px; height: 15px; flex-shrink: 0; }
.cmd-open span { flex: 1; }
.cmd-open .kbd { padding: 0 6px; }
.cmd { width: min(640px, calc(100vw - 32px)); max-height: min(560px, calc(100vh - 120px)); margin: 12vh auto auto; padding: 0; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); color: var(--ink); box-shadow: 0 24px 60px rgba(0, 0, 0, .22); overflow: hidden; }
.cmd[open] { display: flex; flex-direction: column; }
.cmd::backdrop { background: rgba(10, 10, 20, .35); backdrop-filter: blur(2px); }
.cmd-search { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.cmd-search svg { width: 18px; height: 18px; color: var(--muted); flex-shrink: 0; }
.cmd-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font: 500 var(--fs-md) var(--font); }
.cmd-results { overflow-y: auto; padding: 6px; flex: 1; min-height: 120px; }
.cmd-group + .cmd-group { margin-top: 4px; }
.cmd-group-title { padding: 8px 10px 4px; font-size: var(--fs-xs); font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.cmd-item { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: var(--r-sm); color: var(--ink); text-decoration: none; font-size: var(--fs); }
.cmd-item[aria-selected="true"] { background: var(--cobalt-soft); color: var(--cobalt-soft-ink); }
.cmd-icon { width: 28px; height: 28px; border-radius: 8px; background: var(--surface-2); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--muted); }
.cmd-item[aria-selected="true"] .cmd-icon { background: var(--surface); color: var(--cobalt); }
.cmd-icon svg { width: 15px; height: 15px; }
.cmd-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmd-hint { font-size: var(--fs-xs); color: var(--muted); flex-shrink: 0; }
.cmd-empty { padding: 28px 16px; text-align: center; color: var(--muted); }
.cmd-foot { display: flex; gap: 14px; align-items: center; padding: 8px 14px; border-top: 1px solid var(--line); font-size: var(--fs-xs); color: var(--muted); }
.cmd-foot .kbd { padding: 0 5px; margin-right: 3px; }
.cmd-foot .link { margin-left: auto; }

/* Help center */
.help-hero { text-align: center; padding: 28px 0 24px; }
.help-hero h1 { font-size: var(--fs-2xl, 30px); letter-spacing: -0.02em; margin-bottom: 16px; }
.help-search { display: flex; align-items: center; gap: 10px; max-width: 580px; margin: 0 auto; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); box-shadow: var(--shadow); }
.help-search:focus-within { border-color: var(--cobalt); box-shadow: 0 0 0 3px var(--cobalt-soft); }
.help-search svg { width: 18px; height: 18px; color: var(--muted); }
.help-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; padding: 13px 0; font: 500 var(--fs-md) var(--font); color: var(--ink); }
.help-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.help-group h2 { font-size: var(--fs-md); margin-bottom: 10px; }
.help-group ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.help-group a { color: var(--ink-2); text-decoration: none; }
.help-group a:hover { color: var(--cobalt); text-decoration: underline; }
.help-contact { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; background: var(--surface-3); }
.help-found { list-style: none; margin: 0 auto; padding: 0; max-width: 720px; display: flex; flex-direction: column; gap: 8px; }
.help-found a { display: flex; flex-direction: column; gap: 3px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); color: var(--ink); text-decoration: none; }
.help-found a:hover { border-color: var(--cobalt); }
.help-cat { font-size: var(--fs-xs); font-weight: 600; color: var(--cobalt); text-transform: uppercase; letter-spacing: .05em; }
.help-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 18px; align-items: start; }
.help-article { padding: 28px 32px; }
.help-article h1 { font-size: var(--fs-xl); letter-spacing: -0.02em; margin: 4px 0 6px; }
.help-summary { color: var(--muted); font-size: var(--fs-md); margin-bottom: 18px; }
.help-body { line-height: 1.65; color: var(--ink-2); }
.help-body p, .help-body ul, .help-body ol { margin: 0 0 14px; }
.help-body li { margin: 4px 0; }
.help-body a { color: var(--cobalt); }
.help-body code { background: var(--surface-2); padding: 1px 5px; border-radius: 5px; font-size: .92em; }
.help-body h3 { font-size: var(--fs-md); color: var(--ink); margin: 22px 0 8px; }
.help-body pre { margin: 0 0 14px; padding: 14px 16px; border-radius: var(--r); background: var(--surface-2); border: 1px solid var(--line); overflow-x: auto; line-height: 1.6; }
.help-body pre code { background: none; padding: 0; font-size: 13px; white-space: pre; }
@media (max-width: 900px) { .help-layout { grid-template-columns: 1fr; } .help-article { padding: 20px; } }

/* What's new */
.whats-new { width: min(460px, calc(100vw - 32px)); padding: 22px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); color: var(--ink); box-shadow: 0 24px 60px rgba(0, 0, 0, .22); }
.whats-new::backdrop { background: rgba(10, 10, 20, .3); }
.whats-new h2 { font-size: var(--fs-lg); margin: 10px 0 6px; }
.wn-head { display: flex; justify-content: space-between; align-items: center; }
.wn-tag { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; background: var(--cobalt-soft); color: var(--cobalt-soft-ink); font-size: var(--fs-xs); font-weight: 600; }
.wn-tag svg { width: 13px; height: 13px; }
.wn-more { margin: 12px 0 0; padding: 12px 0 0 18px; border-top: 1px solid var(--line-soft); color: var(--muted); font-size: var(--fs-sm); display: flex; flex-direction: column; gap: 4px; }
.wn-more strong { color: var(--ink-2); font-weight: 500; }
.wn-actions { display: flex; gap: 8px; margin-top: 18px; flex-wrap: wrap; }
.changes { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; max-width: 720px; }
.change time { font-size: var(--fs-xs); color: var(--muted); font-weight: 600; }
.change h2 { font-size: var(--fs-lg); margin: 4px 0 6px; }
.change p { color: var(--ink-2); margin-bottom: 10px; line-height: 1.6; }

/* Two kinds of plan: a section each, on the Plans page, the pricing page and the homepage */
.billing-tabs { margin: 4px 0 8px; }
.billing-kind, .pricing-kind { display: flex; flex-direction: column; gap: 16px; scroll-margin-top: 16px; }
.billing-kind + .billing-kind, .pricing-kind + .pricing-kind { margin-top: 28px; padding-top: 28px; border-top: 1px solid var(--line); }
.billing-kind-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.billing-kind-head h2, .pricing-kind-head h2 { font-size: var(--fs-xl); letter-spacing: -0.02em; }
.billing-kind-head p, .pricing-kind-head p { max-width: 620px; margin-top: 4px; }
.billing-now { min-width: 240px; }
.pricing-kind { margin-top: 28px; }
.pricing-jump { display: flex; gap: 8px; }
.pricing-jump a { padding: 6px 14px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink-2); text-decoration: none; font-size: var(--fs-sm); font-weight: 500; }
.pricing-jump a:hover { border-color: var(--cobalt); color: var(--cobalt); }
.plans-kind-title { font-size: var(--fs-lg); margin: 22px 0 10px; display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.plans-kind-title .muted { font-size: var(--fs); font-weight: 500; }
.admin-group-title { font-size: var(--fs-md); margin: 18px 0 2px; }
/* The sidebar's offer without a plan: one compact row */
.sidebar-foot .upsell { flex-direction: row; align-items: center; gap: 10px; padding: 9px 12px; }
.upsell-icon { width: 28px; height: 28px; border-radius: 8px; background: rgba(255, 255, 255, 0.16); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.upsell-icon svg { width: 15px; height: 15px; }
.upsell-text { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.upsell-text span { color: var(--on-cobalt-muted); font-size: var(--fs-xs); }
.sidebar-foot .upsell > svg { width: 15px; height: 15px; flex-shrink: 0; transition: transform .15s; }
.sidebar-foot .upsell:hover > svg { transform: translateX(3px); }
.plan-rate { margin: -6px 0 0; font-size: var(--fs-xs); font-weight: 600; color: var(--success-ink); }

/* Short laptop screens (after app.css and the ⌘K button's rules, so these win): the same sidebar, a little tighter, so it fits without scrolling down to about 720px. */
@media (min-width: 901px) and (max-height: 820px) {
  .sidebar { padding-top: 12px; }
  .brand { padding-bottom: 6px; }
  .cmd-open { margin: 2px 0 6px; padding: 5px 10px; }
  .nav-link { min-height: 27px; }
  .nav-section { padding: 2px 10px; }
  .nav-group + .nav-group { margin-top: 4px; }
  .plan-meters { gap: 6px; padding: 7px 10px; }
  .user-card { padding-top: 6px; }
}
