/* Page layer on top of industry.css. Tokens and helpers come from the
   handoff canvas (design/handoff, its <style>: .lt/.dk, .k, .pk, .num,
   .paper); layout follows homepage 2a. Take colours, fonts and spacing from
   the tokens; don't hard-code what they carry. */

@font-face { font-family: "Barlow"; font-style: normal; font-weight: 400; font-display: swap; src: url(fonts/barlow-400.woff2) format("woff2"); }
@font-face { font-family: "Barlow"; font-style: normal; font-weight: 500; font-display: swap; src: url(fonts/barlow-500.woff2) format("woff2"); }
@font-face { font-family: "Barlow"; font-style: normal; font-weight: 700; font-display: swap; src: url(fonts/barlow-700.woff2) format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-style: normal; font-weight: 400; font-display: swap; src: url(fonts/barlow-condensed-400.woff2) format("woff2"); }
@font-face { font-family: "Barlow Condensed"; font-style: normal; font-weight: 600; font-display: swap; src: url(fonts/barlow-condensed-600.woff2) format("woff2"); }

/* — theme tokens (canvas .lt / .dk) — */
:root {
  color-scheme: light dark;
  --color-divider: rgba(29,31,32,.16);
  --ink55: rgba(29,31,32,.6);
  --ink70: rgba(29,31,32,.72);
  --ink08: rgba(29,31,32,.08);
  --paper: #ffffff;
}
@media (prefers-color-scheme: dark) {
  :root {
    --color-bg: #1b1d20; --color-surface: #25282c; --color-text: #e8e9eb;
    --color-accent: #94bce3; --color-accent-600: #b5d9fd; --color-accent-700: #b5d9fd;
    --color-accent-800: #d6ebff; --color-accent-900: #eef6ff; --color-accent-100: #2c455d;
    --color-neutral-100: #2b2b2d; --color-neutral-800: #d4d4d7;
    --color-divider: rgba(232,233,235,.2);
    --ink55: rgba(232,233,235,.62); --ink70: rgba(232,233,235,.78); --ink08: rgba(232,233,235,.08);
    --shadow-sm: 0 1px 2px rgba(0,0,0,.5); --shadow-md: 0 3px 10px rgba(0,0,0,.55); --shadow-lg: 0 12px 32px rgba(0,0,0,.65);
  }
}
html { background: var(--color-bg); }
body { background: var(--color-bg); color: var(--color-text); line-height: 1.5; }
a { color: var(--color-accent-700); }
a:hover { color: var(--color-accent-900); }
input::placeholder, textarea::placeholder { color: var(--ink55); opacity: 1; }

/* — canvas helpers — */
.k { font-family: var(--font-heading); font-weight: 600; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--color-accent-700); }
.pk { font-family: var(--font-heading); font-weight: 600; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--pm); }
.num { font-feature-settings: "tnum" 1; text-align: right; white-space: nowrap; }
.paper { --pt: #1d1f20; --pm: rgba(29,31,32,.6); --pd: rgba(29,31,32,.16); background: #fff; color: var(--pt); font-family: var(--font-body); font-feature-settings: "tnum" 1; position: relative; }
.paper .corner { color: rgba(29,31,32,.5); }
@keyframes op-pulse { 0%, 100% { opacity: .35 } 50% { opacity: 1 } }
[hidden] { display: none !important; }
.muted { color: var(--ink55); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: absolute; left: 16px; top: -48px; z-index: 10; padding: 8px 12px; background: var(--color-bg); border: 1px solid var(--color-divider); }
.skip-link:focus-visible { top: 8px; }

/* — wordmark (2a): "onepage" Barlow + "invoice" Barlow Condensed — */
.wm { font-size: 22px; line-height: 1; display: inline-flex; align-items: baseline; color: var(--color-text); }
.wm-a { font-family: var(--font-body); font-weight: 400; letter-spacing: -.01em; }
.wm-b { font-family: var(--font-heading); font-weight: 600; color: var(--color-accent-700); }

/* — buttons on links — */
a.btn:hover { text-decoration: none; }
.btn-primary:hover, .btn-primary:active { color: var(--color-bg); }
.btn-lg { min-height: 48px; font-size: 16px; padding-inline: 22px; }
.btn-md { min-height: 44px; padding-inline: 16px; }
.link-strong { color: var(--color-accent-700); }

/* — layout — */
.wrap { max-width: 1280px; margin-inline: auto; padding-inline: 48px; }
.section { padding-bottom: 72px; }
.section h2 { font-size: 32px; margin: 0; }

.site-header { border-bottom: 1px solid var(--color-divider); }
.site-header__in { height: 60px; display: flex; align-items: center; gap: 22px; }
.site-header__brand { margin-right: auto; text-decoration: none; }
.site-nav { display: flex; align-items: center; gap: 22px; }
.site-nav__link, .site-nav__acct { color: var(--ink70); }

.hero { padding-top: 72px; padding-bottom: 56px; display: grid; grid-template-columns: 480px minmax(0, 1fr); gap: 56px; align-items: center; }
.hero__copy { display: flex; flex-direction: column; gap: 22px; }
.hero__title { font-size: 76px; line-height: .95; margin: 0; text-transform: uppercase; letter-spacing: .01em; }
.hero__lede { font-size: 18px; line-height: 1.5; margin: 0; color: var(--ink70); max-width: 420px; }
.hero__actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.hero__note { font-size: 13px; color: var(--ink55); margin: 0; }
.hero__art { width: 100%; max-width: 640px; justify-self: end; box-shadow: var(--shadow-lg); background: var(--color-bg); }

/* Illustrations are drawn at their design size and scaled to fit (site.js
   sets --s from the box width; the defaults match the desktop layout). */
.scaled { position: relative; overflow: hidden; width: 100%; --s: .5; }
.scaled__stage { position: absolute; top: 0; left: 0; transform: scale(var(--s)); transform-origin: 0 0; pointer-events: none; }
.editor-mock { display: flex; flex-direction: column; background: var(--color-bg); color: var(--color-text); font-size: 15px; }
.template .scaled { --s: .4474; }

.features { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-bottom: -8px; }
.feature { padding: 26px 28px; display: flex; flex-direction: column; gap: 10px; }
.feature + .feature { border-left: 1px solid var(--color-divider); }
.feature__title { font-size: 26px; line-height: 1.1; letter-spacing: 0; margin: 0; }
.feature__body { font-size: 14px; color: var(--ink70); margin: 0; }

.section__head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px 16px; flex-wrap: wrap; margin-bottom: 22px; }
.section__head p { font-size: 14px; margin: 0; }
.templates { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
.template { display: flex; flex-direction: column; gap: 10px; margin: 0; }
.template__sheet { box-shadow: var(--shadow-md); overflow: hidden; }
.template figcaption { font-size: 14px; margin: 0; color: var(--color-text); }

.pricing { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
.pricing h2 { margin-bottom: 8px; }
.pricing__text { font-size: 16px; color: var(--ink70); margin: 0; max-width: 460px; }
.cta { padding: 22px 24px; display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.cta__title { font-family: var(--font-heading); font-weight: 600; font-size: 24px; line-height: 1.1; margin: 0; }
.cta__sub { font-size: 14px; margin: 0; }

.notice { padding-block: 96px; display: grid; place-items: center; min-height: calc(100svh - 160px); }
.notice__plate { max-width: 560px; padding: 30px 28px 26px; display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.notice__plate p { margin: 0; }
.notice__title { font-size: 40px; margin: 0; }

.site-footer { border-top: 1px solid var(--color-divider); }
.site-footer__in { padding-block: 20px; display: flex; justify-content: space-between; align-items: center; gap: 12px 22px; flex-wrap: wrap; font-size: 13px; color: var(--ink55); }
.site-footer__brand { text-decoration: none; }
.site-footer__brand .wm { font-size: 16px; }
.site-footer__links { display: flex; gap: 22px; flex-wrap: wrap; }
.site-footer__links a { color: var(--ink55); text-decoration: none; }
.site-footer__links a:hover { color: var(--color-text); }

/* — responsive — */
@media (max-width: 1100px) {
  .hero { grid-template-columns: minmax(0, 1fr); }
  .hero__art { max-width: none; justify-self: stretch; }
}
@media (max-width: 900px) {
  .features { grid-template-columns: minmax(0, 1fr); }
  .feature + .feature { border-left: 0; border-top: 1px solid var(--color-divider); }
  .templates { grid-template-columns: minmax(0, 1fr); max-width: 420px; }
  .pricing { grid-template-columns: minmax(0, 1fr); gap: 28px; }
}
@media (max-width: 700px) {
  .wrap { padding-inline: 16px; }
  .site-nav__link { display: none; }
  .site-nav { gap: 6px; }
  .site-nav__cta.is-signed-in { display: none; } /* the list has its own New invoice */
  .hero { padding-top: 40px; gap: 40px; }
  .hero__title { font-size: 56px; }
  .section { padding-bottom: 56px; }
  .feature { padding: 22px 20px; }
  .notice { padding-block: 56px; }
  .notice__title { font-size: 32px; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; }
}

/* ══ Editor (design 1e; phones follow 1f/1g: Edit / Preview tabs) ══ */
.icon { display: inline-block; vertical-align: -3px; flex: none; }
.input.num { text-align: right; }
.editor { display: flex; flex-direction: column; height: 100dvh; }
.ed-top { min-height: 56px; border-bottom: 1px solid var(--color-divider); display: flex; align-items: center; gap: 14px 18px; padding: 0 20px; flex: none; flex-wrap: wrap; }
.ed-top__brand { margin-right: auto; text-decoration: none; }
.ed-top__brand .wm { font-size: 20px; }
.seg-opt.is-soon { opacity: .45; cursor: not-allowed; }
.ed-select { position: relative; display: inline-flex; align-items: center; }
.ed-select select { appearance: none; -webkit-appearance: none; padding-right: 28px; font-family: var(--font-heading); }
.ed-select::after { content: ""; position: absolute; right: 12px; top: 50%; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-70%) rotate(45deg); pointer-events: none; }
.ed-top__accent select { padding-left: 32px; }
.ed-swatch { position: absolute; left: 11px; width: 14px; height: 14px; pointer-events: none; background: var(--color-accent); }
/* Fixed widths: the controls to the left must not move as the text changes. */
.ed-status { font-size: 12px; color: var(--ink55); display: inline-flex; align-items: center; gap: 6px; width: 180px; flex: none; white-space: nowrap; overflow: hidden; }
.ed-status__text { overflow: hidden; text-overflow: ellipsis; }
.ed-status[data-kind="problem"], .ed-status[data-kind="offline"] { color: var(--color-text); }
.field-warn { display: flex; gap: 6px; align-items: flex-start; font-size: 12px; color: var(--color-text); margin-top: 6px; }
.field-warn .icon { flex: none; margin-top: 1px; color: var(--color-accent-700); }
.ed-autosave { font-size: 12px; color: var(--ink55); white-space: nowrap; width: 84px; flex: none; overflow: hidden; text-overflow: ellipsis; }
.ed-autosave[data-kind="error"], .ed-autosave[data-kind="invalid"] { color: var(--color-text); }
.ed-status .pulse { width: 6px; height: 6px; background: var(--color-accent); animation: op-pulse 1.2s ease-in-out infinite; }
.ed-tabs { display: none; }

.ed-body { flex: 1; min-height: 0; display: grid; grid-template-columns: 232px minmax(0, 1fr) 400px; }
.ed-rail { padding: 24px 0 0; border-right: 1px solid var(--color-divider); display: flex; flex-direction: column; font-size: 14px; overflow: auto; }
.ed-rail__title { padding: 0 20px 10px; }
.ed-rail__item { display: flex; align-items: center; gap: 10px; padding: 9px 20px 9px 17px; border-left: 3px solid transparent; color: var(--ink70); text-decoration: none; }
.ed-rail__item:hover { color: var(--color-text); background: var(--ink08); }
.ed-rail__item.is-active { border-left-color: var(--color-accent); background: var(--ink08); color: var(--color-text); font-weight: 500; }
.ed-rail__item .num { font-size: 11px; color: var(--ink55); width: 16px; text-align: left; }
.ed-rail__state { margin-left: auto; font-family: var(--font-heading); font-weight: 600; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--color-text); }
.ed-rail__state.is-ok { color: var(--color-accent-700); }
.ed-rail__foot { margin-top: auto; padding: 16px 20px; font-size: 12px; color: var(--ink55); border-top: 1px solid var(--color-divider); }
.ed-rail__foot p { margin: 0 0 6px; }
.ed-reset { font-size: 13px; padding-inline: 0; }

.ed-stage { overflow: auto; padding: 30px 24px; display: flex; flex-direction: column; align-items: center; gap: 14px;
  background-color: var(--color-surface);
  background-image: linear-gradient(var(--ink08) 1px, transparent 1px), linear-gradient(90deg, var(--ink08) 1px, transparent 1px);
  background-size: 24px 24px; }
.ed-sheet { width: min(100%, calc((100dvh - 56px - 110px) * 0.7727)); flex: none; background: #fff; box-shadow: var(--shadow-lg); }
.ed-sheet.is-a4 { width: min(100%, calc((100dvh - 56px - 110px) * 0.707)); }
.ed-sheet svg { display: block; width: 100%; height: auto; }
.ed-sheet .scaled__stage { pointer-events: auto; }
.ed-stage__note { font-size: 12px; color: var(--ink55); margin: 0; }
.ed-share { width: min(100%, 560px); flex: none; padding: 16px 18px; display: flex; flex-direction: column; gap: 10px; background: var(--color-bg); }
.ed-share__head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.ed-share__exp { font-size: 12px; }
.ed-share__row { display: flex; gap: 8px; align-items: center; }
.ed-share__link { flex: 1; min-width: 0; padding: 7px 10px; border: 1px solid var(--color-divider); font-size: 14px; font-feature-settings: "tnum" 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ed-share__note { font-size: 13px; color: var(--ink70); margin: 0; }
.ed-share__more { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.ed-share__more .btn { font-size: 13px; padding-inline: 0; }

.ed-form { overflow: auto; padding: 24px 28px 64px; display: flex; flex-direction: column; gap: 28px; }
.ed-sec { scroll-margin-top: 16px; }
.ed-prof { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: -2px 0 14px; }
.ed-prof .btn { font-size: 13px; }
.ed-prof__msg { font-size: 12px; }
.ed-sec__head { padding-bottom: 8px; border-bottom: 1px solid var(--color-divider); margin-bottom: 12px; }
.ed-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.ed-span { grid-column: 1 / -1; }
.ed-form textarea.input { min-height: 60px; }
.field-error { font-size: 12px; margin-top: 5px; display: flex; gap: 5px; align-items: flex-start; color: var(--color-text); }
.field.has-error > .input, .field.has-error > .blueprint { border-color: var(--color-text); }
.ed-online { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--color-divider); }
.ed-online__note { font-size: 12px; margin: 4px 0 0; }
.ed-check { display: flex; gap: 10px; align-items: flex-start; margin-top: 12px; font-size: 14px; cursor: pointer; }
.ed-check input { width: 18px; height: 18px; margin: 2px 0 0; flex: none; accent-color: var(--color-accent); }
.ed-check .muted { font-size: 12px; }
.ed-check + .ed-check { margin-top: 12px; }
.ed-hint { font-size: 12px; color: var(--ink55); margin: 10px 0 0; }
.ed-noscript { font-size: 14px; }

.ed-logo { display: flex; align-items: center; gap: 12px; padding: 10px 12px; min-height: 56px; }
.ed-logo__mark { width: 36px; height: 36px; border: 1px dashed var(--color-divider); display: grid; place-items: center; color: var(--ink55); flex: none; overflow: hidden; }
.ed-logo__mark img { max-width: 100%; max-height: 100%; }
.ed-sig__mark { width: 72px; }
.ed-logo__text { font-size: 13px; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.ed-logo__text .muted { font-size: 12px; }
.ed-logo__pick { cursor: pointer; font-size: 13px; }
.ed-logo__pick:focus-within { outline: 2px solid var(--color-accent); outline-offset: 2px; }

.ed-items { display: flex; flex-direction: column; gap: 12px; }
.ed-item { padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.ed-item__nums { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr) 36px; gap: 8px; align-items: end; }
.ed-item__nums .field > label, .ed-item__label { display: block; font-size: 12px; margin-bottom: 5px; color: var(--ink70); }
.ed-item__nums .field-error { grid-column: 1 / -1; }
.ed-item__amount { display: flex; flex-direction: column; align-items: flex-end; font-size: 14px; }
.ed-item__amount .num { min-height: 36px; display: flex; align-items: center; }
.ed-items__foot { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-top: 12px; flex-wrap: wrap; }
.ed-totals { width: 220px; font-size: 14px; display: flex; flex-direction: column; gap: 4px; }
.ed-totals__row { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 4px 8px; }
.ed-totals__row > label { margin: 0; font-size: 14px; }
.ed-tax { width: 64px; min-height: 30px; padding: 3px 8px; }
.ed-totals__due { display: flex; justify-content: space-between; border-top: 1px solid var(--color-text); padding-top: 8px; margin-top: 4px; font-family: var(--font-heading); font-weight: 600; font-size: 18px; }
.ed-bottom { display: none; }

@media (max-width: 1180px) {
  .ed-body { grid-template-columns: minmax(0, 1fr) 380px; }
  .ed-rail { display: none; }
}
@media (max-width: 820px) {
  .app { height: auto; }
  .editor { height: auto; min-height: 100dvh; }
  .ed-top { padding: 10px 16px; }
  .ed-top__tpl, .ed-download span { display: none; }
  .ed-status { order: 10; width: 100%; min-width: 0; }
  .ed-tabs { display: block; padding: 12px 16px 0; }
  .ed-tabs .seg { display: flex; }
  .ed-tabs .seg-opt { flex: 1; justify-content: center; min-height: 44px; }
  .ed-body { display: block; }
  .editor[data-view="edit"] .ed-stage, .editor[data-view="preview"] .ed-form { display: none; }
  .ed-stage { padding: 20px 16px 96px; }
  .ed-sheet, .ed-sheet.is-a4 { width: 100%; }
  .ed-form { overflow: visible; padding: 22px 16px 104px; }
  .ed-grid { grid-template-columns: minmax(0, 1fr); }
  .ed-bottom { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 5; justify-content: space-between; align-items: center; padding: 12px 16px; background: var(--color-bg); border-top: 1px solid var(--color-divider); }
  .ed-bottom__label { font-size: 11px; color: var(--ink55); }
  .ed-bottom__due { font-family: var(--font-heading); font-weight: 600; font-size: 20px; text-align: left; }
  .ed-bottom__toggle { min-height: 44px; }
}

/* ══ Share page (design 1q phones, 2g desktop) ══ */
.hosted { max-width: 980px; margin: 0 auto; padding: 40px 24px 48px; display: grid; grid-template-columns: minmax(0, 1fr) 360px; grid-template-areas: "from side" "body side"; gap: 22px 48px; align-items: start; }
.hosted__from { grid-area: from; font-size: 14px; margin: 0; }
.hosted__side { grid-area: side; position: sticky; top: 40px; display: flex; flex-direction: column; gap: 14px; }
.hosted__body { grid-area: body; display: flex; flex-direction: column; gap: 22px; font-size: 14px; }
.hosted__plate { padding: 22px 20px 18px; display: flex; flex-direction: column; gap: 14px; }
.hosted__plate-head { display: flex; justify-content: space-between; align-items: center; font-size: 13px; }
.hosted__amount { text-align: left; font-family: var(--font-heading); font-weight: 600; font-size: 56px; line-height: .95; }
.hosted__actions { display: flex; gap: 8px; flex-wrap: wrap; }
.hosted__actions .btn { flex: 1; }
.hosted__qr { padding: 14px 18px; display: flex; gap: 14px; align-items: center; font-size: 13px; line-height: 1.45; }
.hosted__qr svg { flex: none; }
.hosted__made { font-size: 11px; color: var(--ink55); text-align: center; margin: 0; }
.hosted__made a { color: inherit; }
.hosted__parties { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; line-height: 1.5; }
.hosted__parties .muted { font-size: 13px; }
.hosted__parties .k, .hosted__dates .k { margin-bottom: 4px; }
.hosted__name { font-weight: 500; }
.hosted__dates { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; font-size: 13px; }
.hosted__items-head { display: flex; justify-content: space-between; padding-bottom: 8px; border-bottom: 1px solid var(--color-text); }
.hosted__item { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--color-divider); }
.hosted__detail { font-size: 12px; }
.hosted__totals { display: flex; flex-direction: column; gap: 4px; padding-top: 10px; font-size: 13px; }
.hosted__totals > div { display: flex; justify-content: space-between; }
.hosted__due { font-family: var(--font-heading); font-weight: 600; font-size: 18px; padding-top: 8px; margin-top: 4px; border-top: 1px solid var(--color-text); }
.hosted__pay { font-size: 13px; line-height: 1.55; }
.hosted__pay .k { margin-bottom: 4px; }
.hosted__pay p { margin: 8px 0 0; }
@media (max-width: 820px) {
  .hosted { grid-template-columns: minmax(0, 1fr); grid-template-areas: "from" "side" "body"; padding: 16px 16px 32px; gap: 18px; }
  .hosted__side { position: static; }
  .hosted__qr { display: none; }
  .hosted__amount { font-size: 48px; }
}

/* ══ Content pages (privacy, terms, API docs) ══ */
.prose { max-width: 760px; padding-block: 56px 72px; font-size: 16px; line-height: 1.6; }
.prose h1 { font-size: 48px; margin: 6px 0 4px; }
.prose h2 { font-size: 26px; margin: 40px 0 10px; }
.prose h3 { font-size: 19px; margin: 24px 0 6px; }
.prose p, .prose ul, .prose ol { margin: 0 0 14px; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li { margin-bottom: 6px; }
.prose code { font: 14px/1.4 ui-monospace, Menlo, monospace; background: var(--ink08); padding: 1px 4px; }
.prose pre { font: 13px/1.5 ui-monospace, Menlo, monospace; background: var(--color-surface); border: 1px solid var(--color-divider); padding: 14px 16px; overflow-x: auto; margin: 0 0 16px; }
.prose pre code { background: none; padding: 0; }
.prose table { border-collapse: collapse; width: 100%; margin: 0 0 16px; font-size: 14px; }
.prose th, .prose td { text-align: left; padding: 6px 8px; border-bottom: 1px solid var(--color-divider); vertical-align: top; }
@media (max-width: 700px) { .prose { padding-block: 32px 48px; } .prose h1 { font-size: 38px; } }

/* ══ Sign-in and account (designs 1ad, 1ae) ══ */
.auth { min-height: 100dvh; display: grid; place-items: center; padding: 24px 16px; }
.auth__card { width: min(400px, 100%); padding: 30px 28px 26px; display: flex; flex-direction: column; gap: 16px; }
.auth__brand { text-decoration: none; }
.auth__brand .wm { font-size: 19px; }
.auth__title { font-size: 28px; margin: 0; }
.auth__lede { font-size: 14px; color: var(--ink70); margin: 0; }
.auth__lede strong { color: var(--color-text); }
.auth__card .input { min-height: 44px; }
.auth__card .btn-md { min-height: 44px; }
.auth__wide { width: 100%; }
.auth__foot { font-size: 12px; color: var(--ink55); margin: 0; }
.auth__note { padding: 12px 14px; font-size: 13px; display: flex; gap: 10px; align-items: center; color: var(--ink70); }
.auth__inline { font: inherit; color: var(--color-accent-700); text-decoration: underline; background: none; border: 0; padding: 0; cursor: pointer; }
.auth__other { align-self: flex-start; color: var(--ink70); }
.auth__soon { font-size: 13px; color: var(--ink70); margin: 0; padding: 12px 14px; border: 1px dashed var(--color-divider); }
.auth__row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.ed-top__account { color: var(--color-accent-700); }

.auth__link { padding: 12px 14px; display: block; text-decoration: none; color: var(--color-text); font-size: 14px; }
.auth__link:hover { background: var(--ink08); }
.auth__link .muted { font-size: 13px; }
/* OAuth consent and connected apps: same card, a short list, and a row per app */
.auth__list { padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }
.auth__app { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.auth__app:hover { background: none; }

/* ══ Sender profile (design 1x) ══ */
.prof { padding-block: 36px 64px; display: flex; flex-direction: column; gap: 22px; max-width: 1136px; }
.prof__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.prof__title { font-size: 36px; margin: 0; }
.prof__sub { font-size: 14px; margin: 0; }
.prof__actions { display: flex; align-items: center; gap: 14px; }
.prof__saved { font-size: 13px; color: var(--color-accent-700); display: inline-flex; gap: 6px; align-items: center; }
.prof__alert { margin: 0; font-size: 14px; display: flex; gap: 6px; align-items: center; }
.prof__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px; }
.prof__col { display: flex; flex-direction: column; gap: 26px; }
.prof__k { padding-bottom: 8px; border-bottom: 1px solid var(--color-divider); margin-bottom: 14px; }
.prof textarea.input { min-height: 72px; }
.prof__tpls { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.prof__tpl { padding: 10px; display: flex; flex-direction: column; gap: 8px; cursor: pointer; }
.prof__tpl:has(input:checked) { border-color: var(--color-accent); }
.prof__tpl .radio { font-size: 13px; }
.prof__thumb { height: 84px; background: #fff; border: 1px solid var(--color-divider); padding: 8px; display: flex; flex-direction: column; gap: 4px; }
.prof__thumb i { display: block; height: 3px; background: #e7e7ea; }
.prof__thumb--classic i:nth-child(1) { width: 12px; height: 12px; background: none; border: 1px solid var(--color-accent); }
.prof__thumb--classic i:nth-child(2) { height: 2px; background: var(--color-accent); margin-top: 4px; }
.prof__thumb--classic i:nth-child(3) { width: 70%; } .prof__thumb--classic i:nth-child(4) { width: 60%; }
.prof__thumb--classic i:nth-child(5) { margin-top: auto; height: 8px; width: 40%; align-self: flex-end; background: var(--color-accent); }
.prof__thumb--minimal i:nth-child(1) { width: 28px; background: #d4d4d7; }
.prof__thumb--minimal i:nth-child(2), .prof__thumb--minimal i:nth-child(3), .prof__thumb--minimal i:nth-child(4) { height: 1px; margin-top: 6px; }
.prof__thumb--minimal i:nth-child(5) { margin-top: auto; height: 6px; width: 30%; align-self: flex-end; background: var(--color-accent); }
.prof__thumb--bold { padding: 0; }
.prof__thumb--bold i:nth-child(1) { height: 30px; background: var(--color-accent); }
.prof__thumb--bold i:nth-child(2) { width: 70%; margin: 6px 8px 0; } .prof__thumb--bold i:nth-child(3) { width: 60%; margin: 0 8px; }
.prof__thumb--bold i:nth-child(4) { display: none; }
.prof__thumb--bold i:nth-child(5) { height: 10px; width: 40%; align-self: flex-end; margin: 4px 8px 0 0; background: var(--color-text); }
.prof__accents { display: flex; gap: 10px; align-items: center; margin-top: 12px; font-size: 13px; }
.prof__swatch { position: relative; cursor: pointer; }
.prof__swatch input { position: absolute; opacity: 0; width: 0; height: 0; }
.prof__swatch span:first-of-type { display: block; width: 22px; height: 22px; }
.prof__swatch input:checked + span { outline: 2px solid var(--color-text); outline-offset: 2px; }
.prof__swatch input:focus-visible + span { outline: 2px solid var(--color-accent); outline-offset: 2px; }
@media (max-width: 900px) { .prof__grid { grid-template-columns: minmax(0, 1fr); } .prof__tpls { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 700px) { .prof .ed-grid { grid-template-columns: minmax(0, 1fr); } .prof__title { font-size: 30px; } }

/* ══ Invoice list (designs 1w desktop, 1y phones) ══ */
.inv { padding-block: 36px 64px; display: flex; flex-direction: column; gap: 22px; max-width: 1136px; }
.inv__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.inv__title { font-size: 36px; margin: 0; }
.inv__sums { display: flex; gap: 32px; margin: 0; font-size: 13px; color: var(--ink55); flex-wrap: wrap; }
.inv__sums div { display: flex; gap: 8px; align-items: baseline; }
.inv__sums dd { margin: 0; color: var(--color-text); font-family: var(--font-heading); font-weight: 600; font-size: 18px; text-align: left; }
.inv__tools { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.inv__search { position: relative; display: flex; align-items: center; width: min(320px, 100%); }
.inv__search .icon { position: absolute; left: 10px; color: var(--ink55); }
.inv__search .input { padding-left: 34px; }
.inv__filters .seg-opt { text-decoration: none; color: inherit; }
.inv__filters .seg-opt.is-on { background: var(--color-accent); color: var(--color-bg); }
.inv__count { font-size: 13px; margin-left: auto; }
.inv__table td { vertical-align: middle; }
.inv__table a { color: inherit; text-decoration: none; }
.inv__table a:hover { color: var(--color-accent-700); }
.inv__no, .inv__date { text-align: left; }
.inv__client a { font-weight: 500; }
.inv__meta { display: none; }
.inv__overdue { background: var(--color-text); color: var(--color-bg); }
.inv__void .inv__no, .inv__void .inv__client > a, .inv__void .inv__amount { text-decoration: line-through; color: var(--color-neutral-600); }
.inv__draft { border: 1px dashed var(--color-neutral-500); color: var(--color-neutral-700); background: transparent; }
.inv__actions { white-space: nowrap; text-align: right; }
.inv__actions form { display: inline; }
.inv__actions .btn { font-size: 13px; padding-inline: 6px; color: var(--ink70); }
.inv__del { color: var(--ink55); }
.inv__empty { padding: 28px; display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.inv__empty p { margin: 0; }
@media (max-width: 820px) {
  .inv__table thead { display: none; }
  .inv__table, .inv__table tbody, .inv__table tr { display: block; }
  .inv__table tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; padding: 12px 0; border-bottom: 1px solid var(--color-divider); }
  .inv__table td { border: 0; padding: 0; }
  .inv__no, .inv__date { display: none; }
  .inv__client { grid-column: 1; }
  .inv__meta { display: block; font-size: 12px; color: var(--ink55); }
  .inv__amount { grid-column: 2; grid-row: 1; }
  .inv__table td:nth-child(6) { grid-column: 2; text-align: right; }
  .inv__actions { grid-column: 1 / -1; text-align: left; }
  .inv__count { margin-left: 0; }
  .inv__new { width: 100%; }
}

/* ══ Clients ══ */
.inv__titlebar { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.book-tabs .seg-opt { text-decoration: none; color: inherit; }
.book-tabs .seg-opt.is-on { background: var(--color-accent); color: var(--color-bg); }
.cl__grid { display: flex; flex-direction: column; gap: 24px; }
.cl__add { order: -1; padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.cl__add[hidden]:target { display: flex !important; } /* works without JS too */
.cl__actions { display: flex; gap: 8px; align-items: center; }
.cl__addhead { display: flex; justify-content: space-between; align-items: center; }
.cl__fields { display: grid; grid-template-columns: 1fr 1fr 1.4fr; gap: 16px; align-items: start; }
.cl__fields .field { width: 100%; }
@media (max-width: 760px) { .cl__fields { grid-template-columns: 1fr; } }
.cl__addr { font-size: 13px; max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cl__email { font-size: 13px; }
.cl__table .inv__client { min-width: 170px; }
.cl__last { white-space: nowrap; font-size: 13px; }
.cl__edit { width: min(520px, 100%); }
.cl__edit .field { width: 100%; }
.cl__note { font-size: 13px; }
@media (max-width: 820px) {
  .cl__email, .cl__addr, .cl__count, .cl__last { display: none; }
  .cl__table tr { grid-template-columns: minmax(0, 1fr); }
}
