:root {
  color-scheme: dark;
  --bg: #080d17;
  --panel: #111827;
  --panel-soft: #0d1524;
  --line: #27324a;
  --muted: #8997af;
  --text: #edf2ff;
  --green: #4ee0a1;
  --sidebar: 282px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}

* { box-sizing: border-box; }
html { min-width: 320px; }
body { margin: 0; min-height: 100vh; background: radial-gradient(circle at 82% 0%, #17233b 0, var(--bg) 42%); }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button, a, summary { -webkit-tap-highlight-color: transparent; }

.topbar {
  height: 68px;
  padding: 0 clamp(18px, 3.6vw, 54px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #202a3e;
  background: #0a101bf2;
  backdrop-filter: blur(18px);
  position: sticky;
  top: 0;
  z-index: 30;
}
.topbar-start { display: flex; align-items: center; gap: 14px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 850; letter-spacing: -.015em; }
.brand-logo { width: 40px; height: 40px; display: grid; flex: 0 0 auto; place-items: center; overflow: hidden; border: 1px solid #303a4d; border-radius: 12px; background: #fff; box-shadow: 0 7px 22px #0005; }
.brand-logo img { width: 100%; height: 100%; display: block; object-fit: cover; }
.brand-name { font-size: 17px; line-height: 1; }
.compact-brand { font-size: 14px; }
.public-actions { display: flex; align-items: center; gap: 12px; }
.header-login { min-height: 38px; display: inline-flex; align-items: center; justify-content: center; padding: 9px 18px; border: 1px solid var(--green); border-radius: 10px; color: #04150e; background: var(--green); font-size: 13px; font-weight: 850; box-shadow: 0 8px 26px #4ee0a11f; }
.header-login:hover { transform: translateY(-1px); box-shadow: 0 10px 30px #4ee0a136; }
.theme-switch { display: flex; align-items: center; gap: 3px; padding: 4px; border: 1px solid var(--line); border-radius: 11px; background: #101827; }
.theme-switch button { width: 30px; min-height: 28px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 7px; color: #77869e; background: transparent; font-size: 14px; }
.theme-switch button:hover { color: var(--text); background: #1a273d; }
.theme-switch button.active { color: #04150e; background: var(--green); }
.menu-toggle { width: 42px; height: 42px; display: grid; place-content: center; gap: 4px; padding: 0; border: 1px solid var(--line); border-radius: 12px; background: #101827; }
.menu-toggle span { width: 17px; height: 2px; border-radius: 2px; background: #c7d1e2; transition: transform .2s ease; }
.language-switch { display: flex; align-items: center; gap: 5px; padding: 4px; border: 1px solid var(--line); border-radius: 11px; background: #101827; }
.language-switch a { min-width: 36px; padding: 7px 8px; border-radius: 7px; color: #7f8ba1; font-size: 12px; font-weight: 800; line-height: 1; text-align: center; }
.language-switch a:hover { color: var(--text); }
.language-switch a.active { color: #04150e; background: var(--green); }

.sidebar {
  position: fixed;
  top: 68px;
  bottom: 0;
  left: 0;
  z-index: 25;
  width: var(--sidebar);
  padding: 24px 18px 18px;
  display: flex;
  flex-direction: column;
  border-right: 1px solid #202a3e;
  background: #0a101bf7;
  box-shadow: 18px 0 50px #0002;
  transition: transform .24s ease;
}
.profile-card div { min-width: 0; display: grid; gap: 2px; }
.profile-card small { color: #74829b; font-size: 11px; }
.sidebar-nav { display: grid; gap: 5px; padding-top: 0; }
.sidebar-link { min-height: 46px; display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: 9px; padding: 10px 12px; border-radius: 12px; color: #aeb9cd; font-size: 14px; font-weight: 700; cursor: pointer; list-style: none; }
.sidebar-link::-webkit-details-marker { display: none; }
.sidebar-link:hover, .sidebar-link.active { color: var(--text); background: #172238; }
.sidebar-link.active { box-shadow: inset 3px 0 var(--green); }
.nav-icon { color: #65748d; font-size: 18px; text-align: center; }
.sidebar-link.active .nav-icon { color: var(--green); }
.tree-arrow { color: #63718a; transition: transform .2s ease; }
.nav-tree[open] .tree-arrow { transform: rotate(180deg); }
.tree-children { display: grid; gap: 3px; margin: 3px 0 8px 40px; padding-left: 13px; border-left: 1px solid #2c3850; }
.tree-children a { padding: 9px 10px; border-radius: 9px; color: #8290a8; font-size: 13px; line-height: 1.25; }
.tree-children a:hover, .tree-children a.active { color: var(--green); background: #111d2f; }
.sidebar-bottom { margin-top: auto; display: grid; gap: 10px; padding-top: 18px; border-top: 1px solid #202a3e; }
.profile-card { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 9px; border: 1px solid transparent; border-radius: 12px; background: #101827; }
.profile-card:hover, .profile-card.active { border-color: #31405a; background: #152037; }
.profile-card strong { overflow: hidden; color: #bdc8da; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.profile-avatar { flex: 0 0 auto; width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid #38506a; border-radius: 50%; color: var(--green); background: #172238; font-size: 13px; font-weight: 900; }
.profile-photo { display: block; object-fit: cover; }
.profile-arrow { color: #697991; font-size: 20px; }
.sidebar-bottom form { margin: 0; }
.logout-button { width: 100%; display: flex; align-items: center; gap: 10px; border: 1px solid #4a2935; background: #21131a; color: #ff9daf; }
.sidebar-backdrop { display: none; position: fixed; inset: 68px 0 0; z-index: 20; border: 0; border-radius: 0; background: #02050bb3; }
.sidebar-collapsed .sidebar { transform: translateX(-100%); }
.sidebar-collapsed .page.with-sidebar { margin-left: clamp(20px, 4vw, 60px); }

.page { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 50px 0 80px; }
.page.with-sidebar { width: auto; max-width: 1280px; margin: 0 clamp(22px, 4vw, 64px) 0 calc(var(--sidebar) + clamp(22px, 4vw, 64px)); transition: margin-left .24s ease; }
.auth-page { min-height: calc(100vh - 68px); display: grid; place-items: center; padding-top: 36px; }
.auth-card { width: min(900px, 100%); display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; padding: 46px; border: 1px solid var(--line); border-radius: 28px; background: #111827e6; box-shadow: 0 30px 90px #0008; }
.auth-card.compact { width: min(760px, 100%); }
.auth-copy h1, .hero h1, .heading-row h1, .report-heading h1, .placeholder-page h1 { margin: 7px 0 14px; font-size: clamp(34px, 4.7vw, 58px); line-height: 1.02; letter-spacing: -.035em; }
.auth-copy p, .hero p, .report-heading p, .placeholder-page p { color: #9faec6; line-height: 1.6; }
.eyebrow { margin: 0; color: var(--green) !important; font-size: 12px; font-weight: 850; letter-spacing: .15em; text-transform: uppercase; }
.stack { display: flex; flex-direction: column; gap: 18px; justify-content: center; }
.stack label small { color: #74829a; font-size: 11px; font-weight: 500; line-height: 1.45; }
.auth-secondary { min-height: 44px; display: flex; align-items: center; justify-content: center; border: 1px solid #35415a; border-radius: 12px; color: #c4cee0; background: #111a2b; font-size: 13px; font-weight: 800; text-align: center; }
.auth-secondary:hover { border-color: var(--green); color: var(--green); background: #132238; }
.registration-card { width: min(980px, 100%); }
.registration-name-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
label { display: grid; gap: 8px; color: #bfcae0; font-size: 13px; font-weight: 750; }
input, select, textarea { width: 100%; min-height: 46px; border: 1px solid #35415a; border-radius: 12px; padding: 12px 14px; background: #0b1220; color: var(--text); outline: none; }
textarea { resize: vertical; line-height: 1.55; }
input:focus, select:focus, textarea:focus { border-color: var(--green); box-shadow: 0 0 0 3px #4ee0a126; }
button { min-height: 42px; border: 1px solid #35415a; border-radius: 12px; padding: 11px 16px; background: #182238; color: var(--text); cursor: pointer; }
.primary { border-color: #3fe09a; background: #3fe09a; color: #04150e; font-weight: 850; }
.flash { margin-bottom: 18px; padding: 13px 16px; border: 1px solid #38445c; border-radius: 12px; background: #182238; }
.flash.error { border-color: #7c3343; background: #2a151d; color: #ffb5c3; }
.flash.success { border-color: #2c7454; background: #11291f; color: #8cf0bd; }

.landing-page { width: min(1320px, calc(100% - 40px)); padding-top: 34px; }
.landing-hero { min-height: calc(100vh - 136px); display: grid; grid-template-columns: minmax(0, 1fr) minmax(380px, .9fr); align-items: center; gap: clamp(36px, 7vw, 100px); padding: clamp(36px, 6vw, 82px); overflow: hidden; position: relative; border: 1px solid var(--line); border-radius: 34px; background: linear-gradient(135deg, #111b2d 0%, #0b1321 65%, #101d27 100%); box-shadow: 0 35px 100px #0006; }
.landing-copy { position: relative; z-index: 2; }
.landing-copy h1 { max-width: 760px; margin: 12px 0 22px; font-size: clamp(46px, 6vw, 82px); line-height: .98; letter-spacing: -.055em; }
.landing-copy > p:not(.eyebrow) { max-width: 650px; margin: 0; color: #a6b3c8; font-size: clamp(16px, 1.7vw, 21px); line-height: 1.6; }
.landing-features { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 30px; }
.landing-features span { padding: 9px 13px; border: 1px solid #30405a; border-radius: 999px; color: #9cabc1; background: #0b1422b8; font-size: 12px; font-weight: 750; }
.landing-visual { min-height: 500px; position: relative; display: grid; place-items: center; }
.landing-visual img { width: min(100%, 560px); position: relative; z-index: 2; aspect-ratio: 4 / 3; border: 1px solid #34425b; border-radius: 30px; object-fit: cover; transform: rotate(2deg); box-shadow: 0 30px 90px #0009; }
.visual-glow { width: 76%; aspect-ratio: 1; position: absolute; border-radius: 50%; background: #4ee0a12e; filter: blur(65px); }
.visual-caption { position: absolute; right: 4%; bottom: 5%; z-index: 3; padding: 12px 16px; border: 1px solid #3d8065; border-radius: 13px; color: #a9f2d0; background: #0d2119e8; font-size: 12px; font-weight: 850; box-shadow: 0 16px 35px #0006; }

.hero { display: grid; grid-template-columns: 1fr 380px; gap: 46px; align-items: center; padding: 34px; border: 1px solid var(--line); border-radius: 28px; background: #111827d9; }
.hero img { width: 100%; aspect-ratio: 16/11; object-fit: cover; border-radius: 20px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 20px; }
.stats-grid article { padding: 24px; border: 1px solid var(--line); border-radius: 18px; background: #111827b5; }
.stats-grid span, .stats-grid small { display: block; color: #8492ab; }
.stats-grid strong { display: block; margin: 10px 0; font-size: 36px; }

.heading-row { display: flex; justify-content: space-between; align-items: end; margin-bottom: 28px; }
.badge, .outline-badge, .data-pending { padding: 8px 12px; border-radius: 999px; color: #9fb0ca; font-size: 12px; font-weight: 800; white-space: nowrap; }
.badge { background: #1a273d; }
.outline-badge { border: 1px solid #2b7457; color: #7ce7b6; background: #10251d; }
.demo-badge { border-color: #745929; color: #ffd17f; background: #2b2111; }
.panel { padding: 26px; border: 1px solid var(--line); border-radius: 20px; background: #111827d9; }
.panel h2 { margin-top: 0; }
.invite-panel { margin-bottom: 20px; border-color: #365b52; background: linear-gradient(135deg, #101d20, #111827 72%); }
.invite-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.invite-heading h2 { margin: 6px 0 0; font-size: 24px; }
.invite-description { max-width: 760px; margin: 14px 0 20px; color: #8f9db4; font-size: 13px; line-height: 1.55; }
.invite-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 14px; }
.copy-field { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.copy-field input { min-width: 0; color: #d9fbea; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-weight: 800; letter-spacing: .06em; }
.copy-field button { min-width: 104px; }
.invite-footer { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 16px; padding-top: 16px; border-top: 1px solid #294039; }
.invite-footer > span { max-width: 720px; color: #78879d; font-size: 12px; line-height: 1.5; }
.invite-footer form { flex: 0 0 auto; margin: 0; }
.create-grid { display: grid; grid-template-columns: 1.2fr 1fr .7fr auto; gap: 14px; align-items: end; }
.hint, .meta { color: #7f8ba1; font-size: 13px; }
.user-list { display: grid; gap: 12px; margin-top: 22px; }
.user-card { padding: 20px; border: 1px solid var(--line); border-radius: 18px; background: #111827b5; }
.user-card.disabled { opacity: .6; }
.user-main, .user-actions, .inline-form { display: flex; align-items: center; gap: 12px; }
.user-main { justify-content: space-between; margin-bottom: 16px; }
.user-actions { flex-wrap: wrap; }
.inline-form { flex: 1; }
.inline-form input { min-width: 240px; }
.status-dot { width: 10px; height: 10px; border-radius: 50%; }
.status-dot.on { background: #3fe09a; box-shadow: 0 0 16px #3fe09a; }
.status-dot.off { background: #ff637d; }
.danger { border-color: #773043; color: #ff9daf; background: #26131a; }
.success-button { border-color: #2c7454; color: #8cf0bd; background: #11291f; }

.report-heading { display: flex; align-items: end; justify-content: space-between; gap: 28px; margin-bottom: 28px; }
.report-heading > div { max-width: 790px; }
.report-heading p { margin-bottom: 0; }
.report-filter { padding: 30px; background: linear-gradient(135deg, #111a2b, #0e1625); }
.section-heading, .results-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.section-heading > div, .results-heading > div { display: flex; align-items: center; gap: 12px; }
.section-heading h2, .results-heading h2 { margin: 0; font-size: 20px; }
.section-heading p, .results-heading > span { margin: 0; color: #78869e; font-size: 13px; }
.step-number { color: var(--green); font-size: 12px; font-weight: 900; letter-spacing: .08em; }
.report-filter-grid { display: grid; grid-template-columns: 1.1fr 1.1fr .8fr .8fr auto; gap: 12px; align-items: end; }
.report-submit { min-height: 46px; padding-inline: 20px; }
.empty-state { min-height: 180px; display: flex; align-items: center; justify-content: center; gap: 20px; margin-top: 20px; padding: 36px; border: 1px dashed #31405a; border-radius: 20px; background: #0e1625a6; }
.empty-state h2 { margin: 0 0 7px; font-size: 20px; }
.empty-state p { margin: 0; color: #7f8da5; line-height: 1.5; }
.empty-icon { width: 48px; height: 48px; display: grid; flex: 0 0 auto; place-items: center; border: 1px solid #2e7256; border-radius: 50%; color: var(--green); background: #10251d; font-size: 20px; font-weight: 900; }
.warning-state .empty-icon { border-color: #78552a; color: #ffc56d; background: #2a2012; }
.results-heading { margin-top: 34px; }
.report-results { display: grid; gap: 20px; }
.article-report { overflow: hidden; border: 1px solid var(--line); border-radius: 24px; background: #0f1726e8; box-shadow: 0 20px 60px #0003; }
.article-report-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 24px 28px; border-bottom: 1px solid var(--line); background: #121d30; }
.article-report-header span { color: #7f8da5; font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.article-report-header h2 { margin: 5px 0 0; font-size: 27px; }
.article-report-header .data-pending { border: 1px solid #755b2c; color: #ffc66d; background: #2a2113; letter-spacing: 0; text-transform: none; }
.article-report-header .demo-status { border-color: #755b2c; color: #ffc66d; background: #2a2113; }
.report-block { padding: 26px 28px; border-bottom: 1px solid #212c40; }
.block-title { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.block-title span { color: var(--green); font-size: 11px; font-weight: 900; }
.block-title h3 { margin: 0; font-size: 15px; }
.marketplace-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.marketplace-grid > div { display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 10px; padding: 15px; border: 1px solid #263149; border-radius: 14px; background: #0b1321; }
.marketplace-grid p { margin: 0; color: #aab5c8; font-size: 13px; }
.marketplace-grid strong { font-size: 20px; }
.marketplace-mark { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 9px; font-size: 12px; font-weight: 900; }
.marketplace-mark.wb { color: #fff; background: linear-gradient(135deg, #ae37ff, #f22c8a); }
.marketplace-mark.ozon { color: #fff; background: #175cff; }
.marketplace-mark.ym { color: #111; background: #ffdc37; }
.finance-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; overflow: hidden; border: 1px solid #263149; border-radius: 14px; background: #263149; }
.finance-list > div { min-height: 60px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 14px 16px; background: #0b1321; }
.finance-list span { color: #93a0b6; font-size: 13px; line-height: 1.35; }
.finance-list strong { flex: 0 0 auto; font-size: 18px; }
.finance-list .result-row { grid-column: 1 / -1; background: #11281f; }
.finance-list .result-row span, .finance-list .result-row strong { color: #7ce7b6; font-weight: 850; }
.finance-list .result-row.negative { background: #2b151d; }
.finance-list .result-row.negative span, .finance-list .result-row.negative strong { color: #ff9daf; }
.data-note { margin: 0; padding: 18px 28px; color: #708098; background: #0a111e; font-size: 12px; line-height: 1.55; }

.profile-heading { display: flex; align-items: end; justify-content: space-between; gap: 28px; margin-bottom: 28px; }
.profile-heading h1 { margin: 7px 0 12px; font-size: clamp(38px, 5vw, 62px); letter-spacing: -.045em; line-height: 1; }
.profile-heading p:not(.eyebrow) { max-width: 700px; margin: 0; color: #8f9db4; line-height: 1.6; }
.profile-layout { display: grid; grid-template-columns: 310px minmax(0, 1fr); gap: 20px; align-items: start; }
.photo-panel { position: sticky; top: 92px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.profile-photo-large { width: 154px; height: 154px; min-height: 154px; position: relative; display: grid; place-items: center; overflow: hidden; padding: 0; border: 2px solid #3c8768; border-radius: 50%; color: var(--green); background: radial-gradient(circle at 35% 30%, #263951, #111b2b); font-size: 48px; font-weight: 900; box-shadow: 0 20px 55px #0006, 0 0 0 8px #172238; cursor: pointer; transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease; }
.profile-photo-large:hover { border-color: var(--green); transform: translateY(-2px); box-shadow: 0 24px 60px #0007, 0 0 0 8px #1d2d45; }
.profile-photo-large:focus-visible { outline: 3px solid var(--green); outline-offset: 9px; }
.profile-photo-large img { width: 100%; height: 100%; object-fit: cover; }
.photo-edit-overlay { min-height: 34px; position: absolute; right: 0; bottom: 0; left: 0; display: flex; align-items: center; justify-content: center; padding: 8px 10px 10px; color: #fff; background: linear-gradient(transparent, #050a12e8 48%); font-size: 11px; font-weight: 850; letter-spacing: .02em; opacity: .82; transition: opacity .2s ease; }
.profile-photo-large:hover .photo-edit-overlay,
.profile-photo-large:focus-visible .photo-edit-overlay { opacity: 1; }
.photo-panel h2 { max-width: 100%; margin: 24px 0 5px; overflow: hidden; font-size: 20px; text-overflow: ellipsis; }
.photo-panel > p { max-width: 100%; margin: 0 0 20px; overflow: hidden; color: #77869e; font-size: 12px; text-overflow: ellipsis; }
.photo-panel > small { margin-top: 10px; color: #6f7d94; font-size: 11px; line-height: 1.45; }
.visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden !important; clip: rect(0 0 0 0) !important; clip-path: inset(50%) !important; white-space: nowrap !important; }
.photo-upload { width: 100%; min-height: 43px; display: flex; align-items: center; justify-content: center; border: 1px solid #36506a; border-radius: 11px; color: #b9c5d8; background: #152138; cursor: pointer; }
.photo-upload:hover { border-color: var(--green); color: var(--green); }
.selected-photo-name { width: 100%; margin-top: 9px; overflow: hidden; color: #77869e; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.profile-fields { padding: 30px; }
.profile-section-heading { margin-bottom: 22px; }
.profile-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.bio-field { margin-top: 18px; }
.profile-actions { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 22px; padding-top: 20px; border-top: 1px solid #263149; }
.profile-actions > span { color: #6f7e96; font-size: 12px; }
.profile-actions .primary { min-width: 180px; }

.crop-modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 18px; }
.crop-modal[hidden] { display: none; }
.crop-backdrop { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; border-radius: 0; background: #02050bd9; backdrop-filter: blur(8px); }
.crop-dialog { width: min(760px, 100%); max-height: calc(100vh - 36px); position: relative; z-index: 1; overflow: auto; padding: 28px; border: 1px solid #34415a; border-radius: 24px; background: #111827; box-shadow: 0 35px 120px #000b; }
.crop-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.crop-header h2 { margin: 6px 0 0; font-size: 28px; }
.crop-close { width: 42px; height: 42px; padding: 0; border-radius: 50%; font-size: 24px; }
.crop-description { margin: 12px 0 20px; color: #8c9ab1; font-size: 13px; line-height: 1.55; }
.crop-stage { width: min(420px, 100%); aspect-ratio: 1; position: relative; overflow: hidden; margin: 0 auto; border: 1px solid #42506a; border-radius: 50%; background: #070c14; box-shadow: 0 0 0 10px #172238, 0 25px 65px #0008; cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; }
.crop-stage:focus-visible { outline: 3px solid var(--green); outline-offset: 13px; }
.crop-stage.dragging { cursor: grabbing; }
.crop-stage::after { content: ""; position: absolute; inset: 11%; border: 1px dashed #ffffff99; border-radius: 50%; pointer-events: none; }
.crop-stage canvas { width: 100%; height: 100%; display: block; }
.crop-hint { margin: 24px auto 10px; color: #8c9ab1; font-size: 13px; text-align: center; }
.crop-zoom-control { width: min(420px, 100%); display: grid; grid-template-columns: 24px 1fr 24px; align-items: center; gap: 10px; margin: 0 auto; color: #8c9ab1; font-size: 22px; font-weight: 700; }
.crop-zoom-control span { text-align: center; }
.crop-zoom-control input[type="range"] { min-height: 28px; padding: 0; border: 0; box-shadow: none; accent-color: var(--green); }
.crop-actions { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 22px; padding-top: 20px; border-top: 1px solid #29364d; }
.crop-actions > div { display: flex; gap: 10px; }
body.crop-open { overflow: hidden; }

.placeholder-page { min-height: 520px; position: relative; display: flex; flex-direction: column; align-items: flex-start; justify-content: center; overflow: hidden; padding: clamp(34px, 6vw, 76px); border: 1px solid var(--line); border-radius: 28px; background: linear-gradient(135deg, #121c2d, #0c1422); }
.placeholder-page > p:not(.eyebrow) { max-width: 660px; margin-top: 0; font-size: 17px; }
.placeholder-index { position: absolute; top: 25px; right: 34px; color: #18243a; font-size: clamp(90px, 16vw, 190px); font-weight: 950; line-height: 1; }
.camera-lens { width: 110px; height: 110px; position: absolute; right: 8%; top: 50%; display: grid; place-items: center; transform: translateY(-50%); border: 17px solid #18253a; border-radius: 50%; box-shadow: 0 0 0 28px #101a2b, 0 0 100px #4ee0a118; }
.camera-lens i { width: 25px; height: 25px; border-radius: 50%; background: var(--green); box-shadow: 0 0 35px var(--green); }
.error-card { align-items: center; }
.error-back { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; border-radius: 12px; padding: 12px 18px; text-align: center; }

@media (max-width: 1180px) {
  .report-filter-grid { grid-template-columns: repeat(2, 1fr); }
  .report-submit { grid-column: 1 / -1; }
  .marketplace-grid { grid-template-columns: 1fr; }
  .create-grid { grid-template-columns: repeat(2, 1fr); }
  .profile-layout { grid-template-columns: 260px minmax(0, 1fr); }
}

@media (max-width: 900px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar-open .sidebar { transform: translateX(0); }
  .sidebar-open .sidebar-backdrop { display: block; }
  .page.with-sidebar, .sidebar-collapsed .page.with-sidebar { width: min(100% - 32px, 1180px); margin: 0 auto; }
  .auth-card, .hero { grid-template-columns: 1fr; }
  .hero img { order: -1; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .identity { display: none; }
  .camera-lens { opacity: .35; }
  .profile-layout { grid-template-columns: 1fr; }
  .photo-panel { position: static; }
  .landing-hero { min-height: auto; grid-template-columns: 1fr; }
  .landing-visual { min-height: 360px; order: -1; }
  .landing-visual img { width: min(100%, 500px); }
}

@media (max-width: 620px) {
  .topbar { padding: 0 12px; }
  .topbar > .brand .brand-name { display: none; }
  .public-actions { gap: 7px; }
  .theme-switch { gap: 2px; }
  .theme-switch button { width: 27px; }
  .header-login { padding-inline: 12px; font-size: 12px; }
  .compact-brand .brand-name { max-width: 105px; overflow: hidden; font-size: 14px; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }
  .brand-logo { width: 36px; height: 36px; border-radius: 10px; }
  .language-switch a { min-width: 30px; padding-inline: 5px; }
  .page, .page.with-sidebar { width: min(100% - 24px, 1180px); padding-top: 24px; }
  .auth-card { padding: 26px; gap: 28px; }
  .stats-grid, .report-filter-grid, .finance-list { grid-template-columns: 1fr; }
  .report-heading, .section-heading, .results-heading, .heading-row { align-items: flex-start; flex-direction: column; }
  .profile-heading { align-items: flex-start; flex-direction: column; }
  .report-filter { padding: 20px; }
  .report-submit, .finance-list .result-row { grid-column: 1; }
  .empty-state { align-items: flex-start; padding: 24px; }
  .article-report-header { align-items: flex-start; padding: 20px; }
  .report-block { padding: 22px 20px; }
  .data-note { padding: 16px 20px; }
  .marketplace-grid > div { grid-template-columns: 34px 1fr auto; }
  .create-grid { grid-template-columns: 1fr; }
  .inline-form { width: 100%; flex-wrap: wrap; }
  .inline-form input { min-width: 100%; }
  .placeholder-page { min-height: 470px; padding: 28px; }
  .placeholder-index { top: 18px; right: 18px; font-size: 88px; }
  .camera-lens { right: -20px; top: 22%; transform: none; }
  .profile-grid { grid-template-columns: 1fr; }
  .registration-name-grid, .invite-grid { grid-template-columns: 1fr; }
  .invite-heading, .invite-footer { align-items: flex-start; flex-direction: column; }
  .invite-footer form, .invite-footer button { width: 100%; }
  .copy-field button { min-width: 92px; }
  .profile-fields { padding: 22px; }
  .profile-actions { align-items: stretch; flex-direction: column; }
  .profile-actions .primary { width: 100%; }
  .crop-dialog { padding: 20px; border-radius: 20px; }
  .crop-hint { margin-top: 20px; }
  .crop-actions { align-items: stretch; flex-direction: column; }
  .crop-actions > div { display: grid; grid-template-columns: 1fr 1fr; }
  .crop-actions button { width: 100%; }
  .landing-page { width: min(100% - 16px, 1180px); padding-top: 8px; }
  .landing-hero { gap: 28px; padding: 26px; border-radius: 24px; }
  .landing-copy h1 { font-size: clamp(40px, 13vw, 58px); }
  .landing-visual { min-height: 260px; }
  .landing-visual img { border-radius: 20px; }
  .visual-caption { right: -4px; bottom: 1%; }
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: #f3f6fa;
  --panel: #ffffff;
  --panel-soft: #eef2f7;
  --line: #d9e1ea;
  --muted: #66758c;
  --text: #172033;
  --green: #19ad70;
  background: var(--bg);
}
html[data-theme="light"] body { background: radial-gradient(circle at 82% 0%, #dce9f5 0, #f4f7fb 42%); }
html[data-theme="light"] .topbar { border-color: #dce3ec; background: #fffffff2; box-shadow: 0 8px 30px #32445b0a; }
html[data-theme="light"] .menu-toggle,
html[data-theme="light"] .language-switch,
html[data-theme="light"] .theme-switch { border-color: #d7e0ea; background: #f4f7fb; }
html[data-theme="light"] .menu-toggle span { background: #536176; }
html[data-theme="light"] .language-switch a,
html[data-theme="light"] .theme-switch button { color: #68778e; }
html[data-theme="light"] .language-switch a:hover,
html[data-theme="light"] .theme-switch button:hover { color: #182236; background: #e6edf4; }
html[data-theme="light"] .language-switch a.active,
html[data-theme="light"] .theme-switch button.active { color: #ffffff; background: #159b64; }
html[data-theme="light"] .header-login { color: #ffffff; background: #159b64; }
html[data-theme="light"] .brand-logo { border-color: #d4dde7; box-shadow: 0 7px 20px #34465b1a; }
html[data-theme="light"] .auth-secondary { border-color: #ccd6e2; color: #405069; background: #f2f6fa; }
html[data-theme="light"] .auth-secondary:hover { border-color: #159b64; color: #12885a; background: #eaf5f0; }
html[data-theme="light"] .stack label small { color: #77859a; }

html[data-theme="light"] .sidebar { border-color: #dce3ec; background: #fffffff7; box-shadow: 18px 0 50px #35465b0a; }
html[data-theme="light"] .sidebar-bottom { border-color: #e0e6ee; }
html[data-theme="light"] .profile-card small { color: #77859a; }
html[data-theme="light"] .sidebar-link { color: #5b687c; }
html[data-theme="light"] .sidebar-link:hover,
html[data-theme="light"] .sidebar-link.active { color: #172033; background: #edf3f8; }
html[data-theme="light"] .nav-icon,
html[data-theme="light"] .tree-arrow { color: #8290a3; }
html[data-theme="light"] .tree-children { border-color: #d8e0e9; }
html[data-theme="light"] .tree-children a { color: #68778b; }
html[data-theme="light"] .tree-children a:hover,
html[data-theme="light"] .tree-children a.active { color: #12885a; background: #eaf5f0; }
html[data-theme="light"] .profile-card { background: #f2f6fa; }
html[data-theme="light"] .profile-card:hover,
html[data-theme="light"] .profile-card.active { border-color: #cfd9e5; background: #e9eff6; }
html[data-theme="light"] .profile-card strong { color: #344055; }
html[data-theme="light"] .profile-avatar { border-color: #afd8c5; color: #12885a; background: #e4f5ed; }
html[data-theme="light"] .logout-button { border-color: #efcbd3; color: #c73b58; background: #fff2f5; }

html[data-theme="light"] .auth-card,
html[data-theme="light"] .hero,
html[data-theme="light"] .panel,
html[data-theme="light"] .stats-grid article,
html[data-theme="light"] .user-card { border-color: #d9e1ea; background: #ffffffed; box-shadow: 0 24px 70px #34465d12; }
html[data-theme="light"] .invite-panel { border-color: #b8d8ca; background: linear-gradient(135deg, #f0faf5, #ffffff 72%); }
html[data-theme="light"] .invite-description,
html[data-theme="light"] .invite-footer > span { color: #68788d; }
html[data-theme="light"] .copy-field input { color: #176746; background: #f8fbf9; }
html[data-theme="light"] .invite-footer { border-color: #d2e5dc; }
html[data-theme="light"] .auth-copy p,
html[data-theme="light"] .hero p,
html[data-theme="light"] .report-heading p,
html[data-theme="light"] .placeholder-page p { color: #68778d; }
html[data-theme="light"] label { color: #4b596e; }
html[data-theme="light"] input,
html[data-theme="light"] select,
html[data-theme="light"] textarea { border-color: #ccd6e2; color: #172033; background: #f8fafc; }
html[data-theme="light"] input:focus,
html[data-theme="light"] select:focus,
html[data-theme="light"] textarea:focus { border-color: #20a972; box-shadow: 0 0 0 3px #20a9721f; }
html[data-theme="light"] button { border-color: #ccd6e2; color: #263247; background: #f1f5f9; }
html[data-theme="light"] .primary { border-color: #159b64; color: #ffffff; background: #159b64; }
html[data-theme="light"] .flash { border-color: #ccd7e4; color: #354258; background: #eef3f8; }
html[data-theme="light"] .flash.error { border-color: #efbdc8; color: #b52c49; background: #fff0f3; }
html[data-theme="light"] .flash.success { border-color: #a7dbc4; color: #14764e; background: #eaf8f1; }

html[data-theme="light"] .landing-hero { border-color: #d5dee8; background: linear-gradient(135deg, #ffffff 0%, #f2f7fb 65%, #eaf5f0 100%); box-shadow: 0 35px 100px #38506d18; }
html[data-theme="light"] .landing-copy > p:not(.eyebrow) { color: #5f6e84; }
html[data-theme="light"] .landing-features span { border-color: #d2dce7; color: #5c6a7e; background: #ffffffb8; }
html[data-theme="light"] .landing-visual img { border-color: #cbd6e2; box-shadow: 0 30px 80px #32486026; }
html[data-theme="light"] .visual-caption { border-color: #92ceb2; color: #14724c; background: #e8f7efed; }
html[data-theme="light"] .visual-glow { background: #3cc68b24; }

html[data-theme="light"] .badge { color: #5f6f85; background: #edf2f7; }
html[data-theme="light"] .outline-badge { border-color: #9fd5bd; color: #15764f; background: #eaf7f1; }
html[data-theme="light"] .demo-badge { border-color: #e0c68f; color: #8a6017; background: #fff8e8; }
html[data-theme="light"] .hint,
html[data-theme="light"] .meta,
html[data-theme="light"] .stats-grid span,
html[data-theme="light"] .stats-grid small { color: #718097; }
html[data-theme="light"] .danger { border-color: #edbcc7; color: #b62d4a; background: #fff0f3; }
html[data-theme="light"] .success-button { border-color: #a9d9c3; color: #14754d; background: #eaf7f1; }

html[data-theme="light"] .report-filter { border-color: #d7e0e9; background: linear-gradient(135deg, #ffffff, #f1f5f9); }
html[data-theme="light"] .section-heading p,
html[data-theme="light"] .results-heading > span,
html[data-theme="light"] .empty-state p { color: #6d7c91; }
html[data-theme="light"] .empty-state { border-color: #cbd6e2; background: #f8fafccf; }
html[data-theme="light"] .article-report { border-color: #d8e1ea; background: #ffffffed; box-shadow: 0 20px 60px #34465a12; }
html[data-theme="light"] .article-report-header { border-color: #d8e1ea; background: #f2f6fa; }
html[data-theme="light"] .article-report-header span { color: #718096; }
html[data-theme="light"] .report-block { border-color: #dbe3ec; }
html[data-theme="light"] .marketplace-grid > div,
html[data-theme="light"] .finance-list > div { border-color: #d8e0e9; background: #f8fafc; }
html[data-theme="light"] .marketplace-grid p,
html[data-theme="light"] .finance-list span { color: #5f6e83; }
html[data-theme="light"] .finance-list { border-color: #d8e0e9; background: #d8e0e9; }
html[data-theme="light"] .finance-list .result-row { background: #e9f7f0; }
html[data-theme="light"] .finance-list .result-row.negative { background: #fff0f3; }
html[data-theme="light"] .data-note { color: #66758a; background: #f3f6f9; }

html[data-theme="light"] .placeholder-page { border-color: #d7e0ea; background: linear-gradient(135deg, #ffffff, #eef4f8); }
html[data-theme="light"] .placeholder-index { color: #e4ebf2; }
html[data-theme="light"] .camera-lens { border-color: #dce6ee; box-shadow: 0 0 0 28px #edf3f7, 0 0 80px #27ae751f; }
html[data-theme="light"] .profile-heading p:not(.eyebrow) { color: #66758a; }
html[data-theme="light"] .profile-photo-large { color: #12885a; background: radial-gradient(circle at 35% 30%, #eff6f2, #dce8e2); box-shadow: 0 20px 55px #34465c1a, 0 0 0 8px #edf3f7; }
html[data-theme="light"] .profile-photo-large:hover { border-color: #159b64; box-shadow: 0 24px 55px #34465c24, 0 0 0 8px #e3ece8; }
html[data-theme="light"] .photo-panel > p,
html[data-theme="light"] .photo-panel > small,
html[data-theme="light"] .selected-photo-name,
html[data-theme="light"] .profile-actions > span { color: #718096; }
html[data-theme="light"] .photo-upload { border-color: #bfd0dc; color: #425169; background: #eef3f8; }
html[data-theme="light"] .profile-actions { border-color: #dbe3ec; }

html[data-theme="light"] .crop-backdrop { background: #d8e0e9d9; }
html[data-theme="light"] .crop-dialog { border-color: #cbd6e2; background: #ffffff; box-shadow: 0 35px 100px #34465b35; }
html[data-theme="light"] .crop-description { color: #65748a; }
html[data-theme="light"] .crop-stage { border-color: #aebdcc; background: #e6edf3; box-shadow: 0 0 0 10px #edf2f6, 0 25px 55px #34465b24; }
html[data-theme="light"] .crop-hint,
html[data-theme="light"] .crop-zoom-control { color: #65748a; }
html[data-theme="light"] .crop-actions { border-color: #d9e1ea; }
