/* ──────────────────────────────────────────────────────────────
   Corners, for every page (2026-09-17).

   The landing (8.1, 8.2) left the fully square edge for four radius steps
   with nothing between them: chips and small controls, buttons and inputs,
   cards, large panels. This sheet carries the same four steps to the rest
   of the site. It is loaded last by all three shells (base_app after the
   scale, base_masthead and auth/base after the page's own sheets), so it
   wins on equal specificity and nothing else had to be rewritten. Remove
   the three <link>s and every page is square again.

   Chrome draws the corners as squircles (corner-shape), whose curvature
   starts gradually, so a 16px corner reads firmer than a circular 16px.
   Browsers without it ignore the declaration and get plain radii at about
   sixty percent, which look the same. corner-shape is written next to each
   radius, never on *: set on everything it would turn the avatars and the
   status dots into squircles too.

   Rules of the system, as on the landing:
   - No pills. A chip is a small rectangle with small corners.
   - A shape inside another, with a gap, takes the outer radius less the gap.
   - A thick rule down one side of a box bends badly round a corner. Boxes
     that had one get a hairline all round and the footer's gold tick on the
     top edge, lined up with their text.
   - Full-width bands, table rows and rules stay square. So do thin gauges.
   ────────────────────────────────────────────────────────────── */

:root{--r-xs:4px; --r-btn:7px; --r-md:9px; --r-lg:13px}
@supports (corner-shape: squircle){
  :root{--r-xs:7px; --r-btn:12px; --r-md:16px; --r-lg:24px}
}
/* The app's older tokens, all zero since the redesign, and the lift radius
   the scale gave its panels, point at the steps. */
:root{--radius-sm:var(--r-xs); --radius-md:var(--r-btn); --radius-lg:var(--r-md); --radius-xl:var(--r-lg)}
.app-main{--lift-r:var(--r-md)}

/* ── 1. chips and small controls ───────────────────────────── */
.up-key,.deck-tag,.kad-p,.pr-chip,.offer-tag,.s-badge,.find-kbd,.navbtn,
.bd-n,.flow-former,.flow-full,.net-cur,.rfil,.flow-hops button,.fin-year,
.bt-b,.sr-pages a,.sr-pages span,.st-seg button,.fd-seg button,.bill-sw,
.kad-more,.hero-eg a,.gchip rect,
.filter-select,.filter-input,.filter-date,.filter-number,.btn-text,
.network-hop-selector select,.network-btn,.network-settings-panel select,
.network-legend-float,.connection-item{border-radius:var(--r-xs);corner-shape:squircle}
.bill-sw{overflow:hidden}
.app-main .bill-sw button{border-radius:0}

/* ── 2. buttons and inputs ─────────────────────────────────── */
.nav .cta,.cta,.chip,.up-btn,.unlock,.action-btn,.company-tab,.btn-secondary,.btn-ink,.btn-primary,
.btn-danger,.btn-success,.auth-btn,.s-btn,.fd-more,.v7-btn,.ug-b,.find-go,.free-cta-btn,.view-profile-btn,
.stat-box,.financial-section,.financials-chart-box,.extraction-banner,
.form-input,.s-input,.kad-q,.gate-in,.ug-in,.find-box,.ask-in,
.auth-alert,.s-msg{border-radius:var(--r-btn);corner-shape:squircle}
.app-main .btn-ink,.app-main .btn-secondary{border-radius:var(--r-btn)}
select.form-input{border-radius:var(--r-btn)}
/* the hero-sized search boxes are cards */
.hero-find .find-box{border-radius:var(--r-md)}

/* ── 3. cards ──────────────────────────────────────────────── */
.rows,.regs,.kv,.data-card,.tool,.s-card,.sheet,.finhero,.grid2,.rel,.checks,.kpigrid,.evlist,.more,
.deck-card,.kad-main,.up-banner,.lawnote,.sr-note,.pr-free,.unlock-strip,.bd-arch,.sertab-wrap,
.offer,.s-table-wrap,.ds-options,.ds-confirm-panel,.find-menu,.navmenu,.frag,.rec,.v7-sheet,.uc7-i,.v7-cta,
.filters-panel,.free-cta-banner,.network-entities-card,.financial-year-card,.financial-year-skeleton,
.financials-charts-section,.ovcols .blk,.network-graph,.dv-list{border-radius:var(--r-md);corner-shape:squircle}
/* a card whose children are square and coloured clips them to its own curve */
.rows,.regs,.kv,.sheet,.finhero,.grid2,.rel,.checks,.kpigrid,.evlist,.s-table-wrap,.ds-options,
.find-menu,.navmenu,.frag,.rec,.v7-sheet,.dv-list{overflow:hidden}

/* ── 4. large panels ───────────────────────────────────────── */
.auth-card,.gate,.ug,.flowmodal,.research-modal,.network-container,.graph{border-radius:var(--r-lg);corner-shape:squircle}
.network-container,.flowmodal{overflow:hidden}
/* The diagram keeps its sideways scroll on a phone (pollock.css), so it is
   not clipped; its caption takes the inner curve instead. */
.graph .gcap{border-radius:0 0 calc(var(--r-lg) - 1px) calc(var(--r-lg) - 1px);corner-shape:squircle}
.app-main .graph{border-radius:var(--r-lg)}
@media(max-width:640px){
  .auth-card,.gate,.ug,.network-container,.graph,.app-main .graph{border-radius:var(--r-md)}
  .graph .gcap{border-radius:0 0 calc(var(--r-md) - 1px) calc(var(--r-md) - 1px)}
}

/* One stack of sections is one card: only its outer corners turn. */
.app-main .ksec{border-radius:0}
.app-main .ksec:first-of-type{border-top-left-radius:var(--r-md);border-top-right-radius:var(--r-md);corner-shape:squircle}
.app-main .ksec:last-of-type{border-bottom-left-radius:var(--r-md);border-bottom-right-radius:var(--r-md);corner-shape:squircle}
#act-groups,#hist-groups{border-radius:var(--r-md);corner-shape:squircle}

/* ── thin gauges stay nearly square ────────────────────────── */
.dv-bar{border-radius:2px;overflow:hidden}
.yr-b,.fy-col i{border-radius:2px 2px 0 0}

/* ── the tick, where a thick rule used to be ───────────────── */
.up-banner,.lawnote,.deck-card,.sr-note,.kad-main,.unlock-strip,.ds-confirm-panel,.auth-card,.gate,.ug,
.app-main .pr-free{position:relative}
.up-banner,.lawnote,.deck-card,.sr-note,.unlock-strip,.app-main .pr-free{border-left:1px solid var(--line-2)}
.kad-main,.auth-card,.gate,.ug,.app-main .gate{border-top:1px solid var(--line-2)}
.ds-confirm-panel{border-top:1px solid var(--gold)}
.gate,.ug,.app-main .gate{border:1px solid var(--line-2)}
.up-banner::before,.lawnote::before,.deck-card::before,.sr-note::before,.kad-main::before,.unlock-strip::before,
.ds-confirm-panel::before,.auth-card::before,.gate::before,.ug::before,.app-main .pr-free::before{
  content:"";position:absolute;top:-1px;left:clamp(18px,2.4vw,26px);width:24px;height:2px;background:var(--gold)}
.unlock-strip::before{background:var(--sage)}
.auth-card::before,.gate::before,.ug::before{left:26px}
/* status boxes: the colour all round, at a hairline */
.auth-alert,.s-msg{border-left-width:1px}
/* the capital cell of the figures strip: the tick, not a bar */
.fh-cap,.fh-cap.fh-cap{border-top:0;border-left:0;position:relative}
.fh-cap::before{content:"";position:absolute;top:0;left:18px;width:24px;height:2px;background:var(--gold)}
@media(min-width:620px){.fh-cap{border-left:0}}

/* ── rules elsewhere that name a radius with more weight than the lists
      above, brought to the same steps ─────────────────────────── */
.band .action-btn,.band .action-btn.secondary,
.app-main .offer .btn-primary,.app-main .offer .btn-secondary,.app-main .offer .btn-ink,
.app-main .gate-act .btn-secondary,.app-main .gate-act .btn-ink,
.research-modal-cancel,.research-modal-create,.research-modal-field input,.research-modal-field textarea,
.s-select,.settings-tab,.wl-note-in,.sort-btn{border-radius:var(--r-btn);corner-shape:squircle}
.settings-tab{border-radius:var(--r-btn) var(--r-btn) 0 0}
.app-main .bill-sw,.st-tabs,.ss-tabs,.ss-nfil,.ss-chip,.ss-eg button,.wl-x,.st-sec-c,.ps-cap,.afm-bad,
.status-pill,.kad-code,.chip-badge,.truncation-notice,.graph-stats,.hop-divider-count{border-radius:var(--r-xs);corner-shape:squircle}
.ss-chip button{border-radius:calc(var(--r-xs) - 2px)}
/* the «most chosen» flag hangs from the offer's top edge: square above */
.app-main .offer-tag{border-radius:0 0 var(--r-xs) var(--r-xs);corner-shape:squircle}
.app-main .offer{overflow:visible}
/* the stats page's figures: one card of cells */
.st-kpis{border-radius:var(--r-md);corner-shape:squircle;overflow:hidden}
.st-bar-t,.year-bar-track{border-radius:2px;overflow:hidden}

/* A box inside a card is part of the card: no curve of its own, no tick. */
.ovcols .blk .kad-main,.data-card .kad-main{border-radius:0;border-left:0;border-right:0}
.ovcols .blk .kad-main::before,.data-card .kad-main::before{content:none}
