:root {
  color-scheme: light;
  font-family: "Inter", "Aptos", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #24202b;
  background: #f7f6f9;
  --ink: #24202b;
  --muted: #625a6c;
  --line: #e8e4ed;
  --paper: #fff;
  --canvas: #f7f6f9;
  --night: #211b28;
  --violet: #624091;
  --violet-light: #eee3fb;
  --radius: 17px;
  --shadow: 0 2px 6px #30233c08;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 298px; font-size: 1rem; line-height: 1.5; }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
button, a, input, textarea, select { outline-offset: 3px; }
:focus-visible { outline: 2px solid #7149a7; }
button:disabled { opacity: .48; cursor: default; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(1.95rem, 3.2vw, 2.85rem); line-height: 1.08; letter-spacing: -.052em; font-weight: 760; }
h2 { font-size: 1.15rem; line-height: 1.25; letter-spacing: -.027em; }
h3 { font-size: 1rem; letter-spacing: -.015em; }
small, .small { font-size: .86rem; }
.muted { color: var(--muted); }
.number { white-space: nowrap; font-variant-numeric: tabular-nums; }
.sr-only, .trap, .skip-link:not(:focus) {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link:focus { position: fixed; top: 8px; left: 10px; background: white; z-index: 20; padding: 8px 14px; }
.loading { min-height: 80vh; display: grid; place-items: center; padding: 30px; text-align: center; color: var(--muted); }

.button {
  min-height: 43px; align-items: center; display: inline-flex; gap: .55rem; justify-content: center; border: 1px solid transparent;
  padding: .62rem .95rem; border-radius: 9px; font-size: .9rem; font-weight: 680; text-decoration: none; line-height: 1.2;
  cursor: pointer; white-space: nowrap; transition: background-color .16s, color .16s, border-color .16s, box-shadow .16s;
}
.button.primary { color: #fff; background: var(--violet); border-color: var(--violet); box-shadow: 0 3px 8px #62409127; }
.button.primary:hover:not(:disabled) { background: #4c2b76; border-color: #4c2b76; }
.button.secondary { background: #fff; color: #3a3047; border-color: #ded7e6; }
.button.secondary:hover:not(:disabled) { background: #f9f4ff; border-color: #b6a2cc; }
.button.quiet { color: #624091; background: #f5effa; }
.button.quiet:hover:not(:disabled) { background: #e9dcf4; }
.button.text-button { color: var(--violet); background: transparent; }
.button.text-button:hover { background: #eae2f4; }
.button.danger { color: #fff; background: #983a42; }
.button.danger:hover { background: #7c2630; }
.button.small-button { min-height: 34px; padding: .45rem .68rem; font-size: .84rem; }
.icon-button { background: transparent; color: inherit; border: 0; border-radius: 8px; min-width: 36px; min-height: 36px; display: grid; place-items: center; cursor: pointer; }
.icon-button:hover { background: #7d669523; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); min-width: 0; }
.square { min-width: 43px; width: 43px; height: 43px; display: inline-grid; place-items: center; border-radius: 12px; flex: none; }
.lilac { color: #684493; background: #f0e5fb; }
.peach { color: #9c4c34; background: #f9eae1; }
.mint { color: #28694b; background: #e3f3eb; }
.blue { color: #3f5689; background: #e8eefb; }
.eyebrow { font-size: .78rem; font-weight: 750; letter-spacing: .11em; }
.brand { display: inline-flex; flex: none; gap: .68rem; align-items: center; font-size: 1.28rem; font-weight: 760; letter-spacing: -.065em; text-decoration: none; line-height: 1.02; }
.brand img { flex: none; }
.brand-sub { display: block; font-size: .72rem; color: #77628c; font-weight: 660; letter-spacing: .045em; margin-top: .24rem; }

.public-header, .public-main, .public-footer { width: min(1200px, calc(100% - 64px)); margin-inline: auto; }
.public-header { min-height: 87px; display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.public-main { padding: .55rem 0 4.5rem; }
.landing-hero { position: relative; display: grid; grid-template-columns: 1.06fr .94fr; min-height: 490px; overflow: hidden; background: #efe7f8; border: 1px solid #e8dcf3; border-radius: 25px; }
.landing-copy { align-self: center; padding: clamp(26px, 5vw, 72px); }
.landing-copy .eyebrow { color: var(--violet); }
.landing-copy h1 { margin: .85rem 0 .95rem; font-size: clamp(2.8rem, 5.3vw, 4.9rem); line-height: .96; letter-spacing: -.071em; }
.landing-copy > p { font-size: clamp(1rem, 1.55vw, 1.18rem); color: #51425e; max-width: 39ch; }
.landing-copy > .button { margin-top: 1.42rem; }
.book-stage { align-self: stretch; position: relative; display: grid; align-content: center; justify-items: center; padding: 3.2rem 1rem 2rem; min-width: 0; background: radial-gradient(ellipse at 56% 40%, #f8f2ff 0, #e1cff1 57%, #caace1 100%); }
.book-glow { position: absolute; inset: 12% 9% 9%; border: 1px solid #fff9; border-radius: 50%; transform: rotate(-20deg); pointer-events: none; }
.book-cover { width: clamp(148px, 18vw, 239px); aspect-ratio: 814 / 1226; position: relative; transform: rotate(-8deg) translateX(4px); border-radius: 2px 7px 7px 3px; background: #983f42; box-shadow: 0 25px 38px #37132c66, 3px 3px 0 #7b2333; overflow: hidden; }
.book-cover img, .book-cover-fallback { position: absolute; inset: 0; width: 100%; height: 100%; }
.book-cover img { object-fit: cover; background: #983f42; }
.book-cover-fallback { display: grid; place-items: center; padding: 1.35rem; text-align: center; color: #fbe0c3; font-family: Georgia, serif; font-size: clamp(1.3rem, 2.7vw, 2.2rem); line-height: 1.02; background: radial-gradient(ellipse, #b45b56, #772d38); }
.book-caption { z-index: 1; position: relative; justify-self: end; margin: 1rem min(2vw, 1.5rem) 0 0; background: #fffc; padding: .55rem .8rem; border-radius: 9px; color: #43314c; box-shadow: 0 5px 16px #56346314; }
.book-caption strong, .book-caption span { display: block; }
.book-caption span { font-size: .81rem; color: #694884; }
.book-caption strong { font-size: .91rem; }
.demo-actions { margin-top: 1.75rem; color: var(--muted); font-size: .86rem; }
.demo-actions > div { display: flex; flex-wrap: wrap; gap: 7px; margin-top: .38rem; }
.demo-actions .button { min-height: 38px; }
.public-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.1rem; margin-top: 1.1rem; }
.public-steps article { padding: clamp(18px, 2.6vw, 35px); background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.public-steps svg { color: var(--violet); margin-bottom: .64rem; }
.public-steps p { margin-top: .45rem; color: var(--muted); }
.application-section { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(14px, 5vw, 75px); padding: 3.8rem 0 0; scroll-margin-top: 1rem; }
.application-section > div:first-child > p:last-child { max-width: 40ch; margin-top: 1rem; }
.application-section h1 { font-size: clamp(1.85rem, 3.4vw, 2.55rem); }
.application-form { padding: clamp(18px, 3vw, 28px); }
.button.tiktok-entry-button { justify-content: center; width: 100%; background: #19161d; border-color: #19161d; color: #fff; }
.button.tiktok-entry-button:hover { background: #3b2e44; border-color: #3b2e44; }
.tiktok-entry-divider { color: var(--muted); font-size: .86rem; text-align: center; }
.tiktok-verified { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; }
.application-success { display: grid; gap: .66rem; padding: 1rem 0; }
.public-footer { border-top: 1px solid var(--line); padding: 1.5rem 0 2rem; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem; }
.public-footer nav { display: flex; flex-wrap: wrap; gap: .55rem 1rem; }
.public-footer nav a, .application-form .checkbox a { color: var(--violet); }
.public-footer nav a { font-size: .91rem; }
.auth-layout { min-height: calc(86vh - 87px); display: grid; place-items: center; margin-inline: auto; width: min(490px, calc(100% - 32px)); padding: 1rem 0 3rem; }
.auth-card { width: 100%; padding: clamp(22px, 5vw, 40px); display: grid; gap: 1.2rem; }
.auth-card .demo-actions { margin: 0; border-top: 1px solid var(--line); padding-top: 1rem; }

.workspace { min-height: 100vh; display: grid; grid-template-columns: 226px minmax(0, 1fr); }
.sidebar { position: sticky; top: 0; min-width: 0; height: 100vh; display: flex; flex-direction: column; padding: 1.4rem 1rem .85rem; background: var(--night); color: #faf6ff; }
.sidebar .brand { margin: .12rem .45rem; }
.sidebar .brand-sub { color: #d7baff; }
.sidebar-main { margin-top: 2.4rem; }
.sidebar-label { font-size: .75rem; font-weight: 710; letter-spacing: .09em; color: #c4b5ce; margin: 0 0 .66rem .68rem; }
.sidebar nav { display: grid; gap: .24rem; }
.nav-link { position: relative; min-height: 43px; display: flex; gap: .68rem; align-items: center; padding: .56rem .67rem; text-decoration: none; border-radius: 9px; color: #e2d9e8; font-size: .93rem; font-weight: 550; }
.nav-link:hover { background: #fff1; }
.nav-link.active { background: #3f2a53; color: #f8eaff; font-weight: 720; }
.nav-link.active svg { color: #dec2ff; }
.nav-count { margin-left: auto; min-width: 23px; border-radius: 6px; padding: .12rem .24rem; text-align: center; color: #f5e8ff; background: #61457a; font-size: .76rem; }
.sidebar-foot { margin-top: auto; }
.demo-role { display: grid; gap: .15rem; margin: .7rem .18rem; padding: .6rem .65rem; border: 1px solid #584864; border-radius: 9px; }
.demo-role > span { color: #cfc0d8; font-size: .76rem; }
.role-switch { border: 0; padding: .24rem 0; text-align: left; color: #ead9f8; background: transparent; font-size: .86rem; font-weight: 650; cursor: pointer; }
.role-switch:hover { text-decoration: underline; }
.profile { display: flex; gap: .58rem; align-items: center; border-top: 1px solid #43354c; padding: .85rem .22rem .2rem; }
.profile > div, .person-row > div { flex: 1; min-width: 0; }
.profile strong, .profile small, .person-row strong:first-child, .person-row small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile strong { font-size: .85rem; }
.profile small { color: #c8b7d4; font-size: .75rem; }
.avatar { width: 34px; height: 34px; display: inline-grid; place-items: center; flex: none; border-radius: 10px; font-weight: 730; font-size: .79rem; color: #372346; background: #d7baff; }
.avatar.light { color: #654282; background: #efe5f7; }
.avatar.large { width: 45px; height: 45px; border-radius: 12px; font-size: .94rem; }
.workspace-main { min-width: 0; }
.workspace-top { height: 65px; display: flex; align-items: center; justify-content: space-between; gap: .9rem; padding: 0 clamp(16px, 3vw, 38px); border-bottom: 1px solid var(--line); background: #fff; font-size: .89rem; color: var(--muted); }
.workspace-top strong { color: var(--ink); font-weight: 680; }
.crumb-sep { margin: 0 .4rem; color: #917ea2; }
.top-right { display: flex; gap: .65rem; align-items: center; }
.mobile-logout { display: none; }
.workspace-date { white-space: nowrap; }
.workspace-body { width: min(1440px, 100%); margin-inline: auto; padding: clamp(18px, 3vw, 36px); display: grid; gap: 1.05rem; }
.page-title { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin: .06rem 0 .2rem; }
.page-actions { display: flex; gap: .45rem; flex-wrap: wrap; }
.subtitle { margin-top: .44rem; color: var(--muted); }
.hero-banner { position: relative; display: flex; justify-content: space-between; align-items: center; padding: 1.05rem 1.55rem 1.2rem; border-radius: var(--radius); overflow: hidden; background: radial-gradient(ellipse at 100% 12%, #71418a, transparent 53%), linear-gradient(98deg, #332242, #4d305f); color: #fff; min-height: 132px; }
.hero-banner .eyebrow { color: #e5c4ff; }
.hero-banner h2 { font-size: clamp(1.5rem, 3vw, 2.05rem); margin: .16rem 0 .17rem; }
.hero-banner p { color: #efe0fa; }
.hero-icon { flex: none; display: grid; place-items: center; width: 98px; height: 98px; margin-right: 1.4rem; border: 1px solid #fff4; border-radius: 27px; background: #e5bbff22; color: #f0d7ff; transform: rotate(-12deg); }
.hero-icon svg { transform: rotate(12deg); }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .9rem; }
.metric-grid.triple { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.metric { display: grid; align-content: start; padding: clamp(13px, 1.48vw, 21px); }
.metric .square { margin-bottom: .66rem; }
.metric-label { color: var(--muted); font-size: .89rem; font-weight: 630; }
.metric strong { display: block; margin-top: .18rem; font-size: clamp(1.28rem, 1.9vw, 1.96rem); line-height: 1.11; font-weight: 750; letter-spacing: -.055em; font-variant-numeric: tabular-nums; }
.metric p { color: var(--muted); font-size: .83rem; margin-top: .32rem; }
.dashboard-grid { display: grid; grid-template-columns: 1.55fr 1fr; gap: .95rem; }
.creator-grid { grid-template-columns: 1.4fr 1fr; }
.history, .side-card, .links-panel, .balances, .settings-card { padding: clamp(15px, 1.85vw, 24px); }
.section-top { display: flex; justify-content: space-between; align-items: flex-start; gap: .65rem; }
.section-top > div { min-width: 0; }
.section-top p { color: var(--muted); margin-top: .31rem; font-size: .88rem; }
.section-top > strong { white-space: nowrap; color: #593981; }
.chart { display: grid; grid-template-columns: repeat(14, minmax(0, 1fr)); gap: clamp(3px, .7vw, 10px); margin-top: 1.05rem; min-height: 154px; }
.bar-group { display: grid; grid-template-rows: 1fr auto; text-align: center; align-items: end; gap: .32rem; color: var(--muted); font-size: .76rem; }
.bar-space { position: relative; height: 100%; min-height: 122px; display: flex; align-items: flex-end; justify-content: center; border-bottom: 1px solid #e9e1ef; background: repeating-linear-gradient(to top, transparent 0, transparent 24%, #f1ecf5 24%, #f1ecf5 25%); }
.bar { height: var(--bar-height, 2%); width: min(85%, 28px); border-radius: 6px 6px 1px 1px; background: linear-gradient(180deg, #9770bd, #6d4897); }
.bar-group:hover .bar { background: #4d2a72; }
.side-card .section-top { margin-bottom: .38rem; }
.person-row { display: flex; align-items: center; gap: .62rem; min-height: 55px; border-top: 1px solid #f0edf3; padding: .54rem 0; }
.person-row:first-of-type { border-top: none; }
.person-row small { color: var(--muted); }
.person-row strong { font-size: .93rem; }
.balance-number { white-space: nowrap; }
.section-top + .person-row, .balances > .section-top { margin-bottom: .42rem; }
.table-card { padding: 0; overflow: hidden; }
.table-card > .section-top, .table-card > .filters, .table-card > .table-limit { padding: 1.1rem clamp(13px, 1.8vw, 23px); align-items: center; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th, td { padding: .72rem clamp(10px, 1.55vw, 21px); font-size: .89rem; vertical-align: middle; }
thead { color: #574e61; background: #f8f6fa; border-block: 1px solid #eeeaf1; }
th { font-weight: 650; white-space: nowrap; }
tbody tr + tr { border-top: 1px solid #f0edf3; }
tbody tr:hover { background: #fbf8fe; }
.table-caption { display: block; font-size: .78rem; color: var(--muted); margin-top: .1rem; }
.tag { display: inline-flex; align-items: center; font-size: .77rem; font-weight: 670; line-height: 1.25; border-radius: 6px; padding: .26rem .46rem; white-space: nowrap; }
.tag.green { color: #21593f; background: #e2f2e8; }
.tag.warm { color: #744820; background: #f8ecdc; }
.tag.red { color: #8d3641; background: #f8e7eb; }
.tag.purple { color: #604184; background: #efe5f8; }
.tag.soft { color: #585162; background: #efedf2; }
.empty { min-height: 138px; display: grid; place-items: center; align-content: center; text-align: center; gap: .3rem; color: var(--muted); padding: 1.5rem 1rem; }
.empty svg { color: #8561a4; }
.empty strong { color: var(--ink); }
.empty p { font-size: .9rem; }

.application-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .9rem; }
.application-item { padding: clamp(14px, 1.85vw, 22px); display: grid; align-content: start; gap: .55rem; }
.application-top { display: flex; justify-content: space-between; align-items: center; gap: .3rem; }
.application-item .section-top { margin-top: .25rem; align-items: center; }
.application-item small { color: var(--muted); }
.subtle-link { color: var(--violet); font-size: .91rem; text-decoration: underline; text-underline-offset: .2em; }
.note-preview { color: var(--muted); min-height: 3.2rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.handle { margin-top: -.3rem; font-size: .91rem; }
.creator-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: .4rem; border-block: 1px solid var(--line); margin: .34rem 0 .15rem; padding: .58rem 0; }
.creator-facts span { display: block; color: var(--muted); font-size: .8rem; }
.creator-facts strong { font-size: 1.05rem; }
.filters { display: flex; flex-wrap: wrap; align-items: end; gap: .65rem; }
.filters .search-label { flex: 1; min-width: 190px; max-width: 460px; }
.search-field { display: flex; align-items: center; gap: .35rem; border: 1px solid #dcd5e4; border-radius: 8px; background: white; padding-left: .72rem; color: #77628c; min-height: 43px; }
.search-field input { border: 0; min-height: 40px; outline-offset: -2px; padding-left: .2rem; }
.table-limit { color: var(--muted); font-size: .88rem; }
.links-panel .section-top { margin-bottom: .4rem; }
.links-view { width: min(670px, 100%); }
.copy-field { margin: .78rem 0; }
.copy-field > span { display: block; margin-bottom: .28rem; font-size: .86rem; font-weight: 690; }
.copy-field > div { display: flex; gap: .42rem; align-items: center; }
.copy-field input { background: #f9f7fb; min-width: 0; }
.settings-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: .92rem; align-items: start; }
.settings-card .form, .settings-card > .details { margin-top: .8rem; }
.settings-card .square { margin-bottom: .65rem; }
.settings-card > .muted { margin-top: .35rem; }
.row-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .42rem; margin-top: .65rem; }
.tiktok-sort { width: min(100%, 15.5rem); flex: none; }
.spark-table { min-width: 625px; }
.spark-table td:first-child { overflow-wrap: anywhere; min-width: 130px; }
.spark-table .row-actions { margin: 0; }
.tiktok-text-link { color: #5e3a8b; font-weight: 680; text-underline-offset: .2em; }
.tiktok-counters { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .55rem; margin: .85rem 0; }
.tiktok-counters > div { background: #f8f4fc; border-radius: 9px; padding: .58rem .55rem; min-width: 0; }
.tiktok-counters strong, .tiktok-counters small { display: block; overflow-wrap: anywhere; }
.tiktok-counters strong { font-size: 1.06rem; }
.tiktok-counters small { color: var(--muted); line-height: 1.3; }
.tiktok-audience-line { margin: .75rem 0; }
.tiktok-video-list { display: grid; gap: .55rem; margin-top: .55rem; }
[data-spark-code][hidden] { display: none; }
@media (max-width: 650px) {
  .table-card > .section-top:has(.tiktok-sort) { display: grid; }
}

.form { display: grid; gap: .85rem; }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .72rem; }
label { min-width: 0; display: grid; align-content: start; gap: .26rem; font-size: .9rem; font-weight: 640; }
input:not([type="checkbox"]), select, textarea { min-width: 0; width: 100%; min-height: 43px; font-size: .96rem; font-weight: 450; padding: .58rem .68rem; border: 1px solid #dcd5e4; border-radius: 8px; color: var(--ink); background: #fff; }
.password-field { display: grid; gap: .26rem; }
.password-control { position: relative; }
.password-control > input { padding-inline-end: 3.1rem; }
.password-toggle { position: absolute; inset-inline-end: .22rem; inset-block: .17rem; min-width: 40px; color: #6a557e; }
.password-rules { display: grid; gap: .25rem; margin: -.25rem 0 0; padding: 0; list-style: none; font-size: .85rem; color: var(--muted); }
.password-rules li { display: flex; align-items: center; gap: .48rem; }
.password-rules li::before { content: ''; width: .82rem; height: .82rem; flex: none; display: grid; place-items: center; border: 1px solid #a798b4; border-radius: 50%; }
.password-rules li.is-met { color: #21593f; }
.password-rules li.is-met::before { content: '✓'; border-color: #3c8760; background: #3c8760; color: white; font-size: .64rem; font-weight: 700; }
input[type="file"] { max-width: 100%; padding: .6rem; }
input[type="file"]::file-selector-button { color: #50336c; background: #f1e7fa; border: 0; padding: .35rem .7rem; border-radius: 5px; }
input::placeholder, textarea::placeholder { color: #786c83; }
textarea { resize: vertical; }
select { appearance: none; padding-right: 2rem; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='m1 1 5 5 5-5' stroke='%23624d75' fill='none' stroke-width='1.5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-size: 11px; background-position: right .72rem center; }
.form .button[type="submit"] { justify-self: start; }
.checkbox { display: flex; gap: .48rem; align-items: start; font-weight: 500; }
.checkbox input { min-width: 17px; min-height: 17px; margin: .14rem 0 0; accent-color: var(--violet); }
.optional { font-weight: 500; color: var(--muted); font-size: .78rem; }
.form-error { background: #fae9ec; color: #802c38; border-radius: 8px; padding: .5rem .7rem; font-size: .88rem; }
.callout { padding: .63rem .8rem; border: 1px solid #e4d7f0; border-radius: 8px; background: #f8f2ff; color: #584669; font-size: .9rem; overflow-wrap: anywhere; }
.details { display: grid; grid-template-columns: minmax(95px, 1fr) minmax(0, 1.55fr); column-gap: .6rem; row-gap: .36rem; margin: .25rem 0 .78rem; font-size: .92rem; }
.details dt { color: var(--muted); }
.details dd { margin: 0; font-weight: 630; overflow-wrap: anywhere; }
dialog { padding: 0; border: 1px solid #e3d9eb; border-radius: 17px; background: #fff; color: var(--ink); width: min(590px, calc(100% - 28px)); max-height: calc(100% - 36px); overflow: auto; box-shadow: 0 20px 70px #17101e43; }
dialog::backdrop { background: #211a2b80; }
.dialog-inner { padding: clamp(17px, 3vw, 25px); display: grid; gap: .8rem; }
.dialog-top { display: flex; gap: .75rem; align-items: center; justify-content: space-between; }
.dialog-top h2 { font-size: 1.4rem; }
.dialog-close { color: #554763; background: #f6f0fa; }
.dialog-actions { display: flex; flex-wrap: wrap; gap: .55rem; justify-content: flex-end; }
.payment-amount { display: flex; align-items: center; gap: .65rem; }
.payment-amount strong { font-size: 1.6rem; letter-spacing: -.045em; }
.payment-lines { max-height: 15rem; overflow: auto; border: 1px solid var(--line); border-radius: 8px; }
.notice { position: fixed; z-index: 12; bottom: 1.15rem; right: 1.15rem; max-width: min(440px, calc(100vw - 2.3rem)); border-radius: 10px; padding: .75rem .95rem; color: #fff; background: #2b5142; box-shadow: 0 6px 26px #160c1d2b; }
.notice.is-error { background: #84313c; }

@media (max-width: 1050px) {
  .workspace { grid-template-columns: 185px minmax(0, 1fr); }
  .sidebar { padding-inline: .7rem; }
  .workspace-body { padding-inline: 1.1rem; }
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .application-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .public-header, .public-main, .public-footer { width: calc(100% - 32px); }
  .landing-hero { min-height: 420px; }
  .public-steps { gap: .6rem; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .workspace-top { padding-inline: 1rem; }
  .workspace-date { display: none; }
}
@media (max-width: 650px) {
  .workspace { display: block; }
  .sidebar { position: static; height: auto; padding: .65rem .78rem .45rem; display: block; }
  .sidebar .brand { margin: 0 .24rem; }
  .sidebar .brand img { width: 32px; height: 32px; }
  .sidebar-label, .sidebar .profile, .sidebar .demo-role > span { display: none; }
  .sidebar-main { margin-top: .65rem; }
  .sidebar nav { display: flex; overflow: auto; gap: .25rem; padding-bottom: .2rem; }
  .nav-link { flex: none; min-height: 39px; padding: .4rem .59rem; gap: .3rem; font-size: .86rem; }
  .nav-link svg { width: 15px; height: 15px; }
  .nav-count { min-width: 18px; }
  .demo-role { position: absolute; top: .65rem; right: .74rem; margin: 0; padding: .19rem .45rem; }
  .role-switch { font-size: .78rem; }
  .workspace-top { height: 46px; font-size: .78rem; gap: .32rem; }
  .top-right { gap: .24rem; }
  .mobile-logout { display: grid; min-width: 27px; min-height: 30px; }
  .workspace-body { padding: .9rem .75rem 1.4rem; gap: .75rem; }
  .page-title { align-items: flex-start; flex-direction: column; gap: .55rem; }
  .hero-banner { min-height: 114px; padding: .8rem 1rem; }
  .hero-banner p { font-size: .9rem; }
  .hero-icon { width: 63px; height: 63px; margin: 0 .2rem 0 .3rem; border-radius: 19px; }
  .hero-icon svg { width: 37px; height: 37px; }
  .metric-grid { gap: .6rem; }
  .metric-grid.triple { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .metric .square { width: 35px; min-width: 35px; height: 35px; border-radius: 9px; }
  .metric-label { font-size: .83rem; }
  .metric p { font-size: .8rem; }
  .settings-grid { grid-template-columns: 1fr; }
  .history, .side-card, .links-panel, .balances { padding: .85rem; }
  th, td { padding: .58rem .68rem; }
  .public-header { min-height: 65px; }
  .landing-hero { grid-template-columns: 1fr; }
  .landing-copy { padding: 1.5rem 1.3rem 1.35rem; }
  .landing-copy h1 { max-width: 12ch; }
  .book-stage { padding: 1.95rem 1rem 1rem; }
  .book-cover { width: 142px; }
  .public-steps, .application-section { grid-template-columns: 1fr; }
  .application-section { padding-top: 2.45rem; }
  .public-main { padding-bottom: 2.8rem; }
  .public-footer { font-size: .85rem; }
}
@media (max-width: 430px) {
  .application-grid { grid-template-columns: 1fr; }
  .field-grid { grid-template-columns: 1fr; }
  .person-row { gap: .36rem; }
  .person-row strong { font-size: .87rem; }
  .balances .avatar { display: none; }
  .section-top > strong { font-size: .92rem; }
  .table-card > .section-top .button { white-space: normal; }
  .details { font-size: .88rem; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }
