/* ORRANET Creator Studio: modern redesign. Class names unchanged. */
:root {
  --brand-dark: #075e54;
  --brand: #128c7e;
  --brand-bright: #25d366;
  --brand-bright-hover: #1fb856;
  --brand-tint: #e8f5f2;
  --bg: #f5f7f5;
  --surface: #ffffff;
  --text-dark: #0d1b19;
  --text-muted: #647571;
  --border: #e4e9e6;
  --border-strong: #d0d8d4;
  --error: #d1453b;
  --success: #1fb856;
  --radius-card: 16px;
  --radius-field: 12px;
  --shadow-sm: 0 1px 2px rgba(13, 27, 25, .05);
  --shadow-md: 0 1px 2px rgba(13, 27, 25, .04), 0 12px 32px -8px rgba(13, 27, 25, .10);
  --ring: 0 0 0 4px rgba(37, 211, 102, .22);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { max-width: 100%; overflow-x: hidden; -webkit-text-size-adjust: 100%; }
img { max-width: 100%; }
button, input, select, textarea { font-family: inherit; }
body { margin: 0; max-width: 100%; overflow-x: hidden; overflow-x: clip; background: var(--bg); color: var(--text-dark);
  font-family: var(--font); font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
h1, h2, p, li, td, th, label, .hint { overflow-wrap: anywhere; }
h1, h2 { margin: 0; line-height: 1.2; color: var(--text-dark); }
h1 { font-size: 1.75rem; font-weight: 800; letter-spacing: -0.025em; }
h2 { font-size: 1.05rem; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0 0 12px; }
a { color: var(--brand-dark); text-underline-offset: 3px; }
.muted { color: var(--text-muted); }
:focus-visible { outline: 3px solid var(--brand-bright); outline-offset: 2px; border-radius: 6px; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 28px;
  border: 1.5px solid transparent; border-radius: 999px; font: inherit; font-weight: 700; text-decoration: none; cursor: pointer;
  transition: background .15s, border-color .15s, transform .1s, box-shadow .15s; }
.btn:active { transform: scale(.985); }
.btn-primary { background: var(--brand-bright); color: #04352f; box-shadow: 0 6px 16px -6px rgba(37, 211, 102, .65); }
.btn-primary:hover { background: var(--brand-bright-hover); box-shadow: 0 8px 20px -6px rgba(37, 211, 102, .75); }
.btn-outline { background: var(--surface); color: var(--brand-dark); border-color: var(--border-strong); }
.btn-outline:hover { border-color: var(--brand); background: var(--brand-tint); }
.btn-block { width: 100%; }
.btn-onDark { background: transparent; color: #fff; border-color: rgba(255,255,255,.35); }
.btn-onDark:hover { border-color: #fff; background: rgba(255,255,255,.08); }
.btn-link { background: none; border: 0; padding: 0; font: inherit; color: var(--brand-dark); font-weight: 600; text-decoration: none; cursor: pointer; }
.btn-link:hover { text-decoration: underline; }

/* ---------- forms ---------- */
.field { margin-bottom: 18px; }
.field label { display: block; margin-bottom: 7px; font-weight: 600; font-size: 14px; }
.field .hint { margin: 7px 0 0; font-size: 13px; color: var(--text-muted); }
.field .hint.ok { color: var(--brand-dark); }
.field .hint.bad { color: var(--error); }
.input { width: 100%; min-height: 50px; padding: 11px 16px; border: 1.5px solid var(--border); border-radius: var(--radius-field);
  background: var(--surface); color: var(--text-dark); font: inherit; font-size: 16px; transition: border-color .15s, box-shadow .15s; }
.input::placeholder { color: #9aa8a4; }
.input:hover { border-color: var(--border-strong); }
textarea.input { min-height: 140px; resize: vertical; line-height: 1.5; }
.input:focus { outline: none; border-color: var(--brand); box-shadow: var(--ring); }
.input-group { display: flex; align-items: stretch; }
.input-group .prefix { display: flex; align-items: center; padding: 0 14px; border: 1.5px solid var(--border); border-right: 0;
  border-radius: var(--radius-field) 0 0 var(--radius-field); background: var(--bg); color: var(--text-muted); white-space: nowrap; }
.input-group .input { flex: 1; min-width: 0; border-radius: 0 var(--radius-field) var(--radius-field) 0; }
.pw { position: relative; }
.pw .input { padding-right: 76px; }
.pw .pw-toggle { position: absolute; right: 8px; top: 8px; min-height: 34px; padding: 0 12px; border: 0; border-radius: 8px; background: var(--brand-tint);
  color: var(--brand-dark); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.pw .pw-toggle:hover { background: #d7ede8; }
.check { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 20px; font-size: 14px; color: var(--text-muted); }
.check input { margin-top: 2px; flex: 0 0 auto; width: 20px; height: 20px; accent-color: var(--brand); }
.code-input { text-align: center; font-size: 1.6rem; letter-spacing: 0.4em; font-weight: 700; }

/* ---------- alerts ---------- */
.alert { margin-bottom: 16px; padding: 13px 16px; border-radius: var(--radius-field); border: 1px solid; font-size: 14px; }
.alert-error { background: #fdf2f1; border-color: #f4d3cf; color: #8f2a22; }
.alert-success { background: #effbf3; border-color: #c6ebd6; color: #115c33; }
.alert-info { background: var(--brand-tint); border-color: #c9e3de; color: var(--brand-dark); }

/* ---------- auth pages ---------- */
.auth-wrap { min-height: 100vh; display: flex; flex-direction: column; align-items: center; padding: 32px 16px 48px;
  background:
    radial-gradient(600px 320px at 85% -5%, rgba(37, 211, 102, .16), transparent 70%),
    radial-gradient(520px 300px at 0% 0%, rgba(18, 140, 126, .12), transparent 70%),
    var(--bg); }
.auth-logo { margin-bottom: 24px; font-size: 1.2rem; font-weight: 800; color: var(--brand-dark); text-decoration: none; letter-spacing: -0.01em; }
.auth-logo span { color: var(--brand); }
.auth-card { width: 100%; max-width: 440px; padding: 32px 28px; background: var(--surface); border: 1px solid var(--border);
  border-radius: 24px; box-shadow: var(--shadow-md); }
.auth-card h1 { margin-bottom: 8px; }
.auth-card > .muted { margin-bottom: 24px; }
.auth-links { margin: 18px 0 0; text-align: center; font-size: 14px; }
.auth-foot { margin: 22px 0 0; padding-top: 20px; border-top: 1px solid var(--border); text-align: center; font-size: 14px; color: var(--text-muted); }
.auth-foot a { font-weight: 700; }
.auth-eyebrow { display: inline-block; margin-bottom: 14px; padding: 5px 12px; border-radius: 999px; background: var(--brand-tint);
  color: var(--brand-dark); font-size: 12px; font-weight: 700; letter-spacing: .02em; }
.auth-perks { display: flex; flex-wrap: wrap; gap: 8px 16px; margin: 0 0 24px; padding: 0; list-style: none; font-size: 13px; color: var(--text-muted); }
.auth-perks li::before { content: "\2713"; margin-right: 6px; color: var(--brand); font-weight: 800; }
.stack > * + * { margin-top: 12px; }

/* ---------- studio shell ---------- */
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: max(12px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) 12px max(16px, env(safe-area-inset-left));
  background: rgba(255,255,255,.88); -webkit-backdrop-filter: saturate(1.4) blur(12px); backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--border); color: var(--text-dark); }
.topbar .logo { font-weight: 800; letter-spacing: -0.01em; color: var(--brand-dark); text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.topbar .logo span { padding: 2px 9px; border-radius: 999px; background: var(--brand-bright); color: #04352f; font-size: 12px; letter-spacing: .02em; }
.topbar .who { display: flex; align-items: center; gap: 12px; font-size: 14px; }
.topbar .who .name { max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.topbar .btn-link { min-height: 36px; padding: 0 14px; border: 1px solid var(--border-strong); border-radius: 999px; color: var(--text-dark); font-size: 13px; }
.topbar .btn-link:hover { background: var(--bg); text-decoration: none; }
.shell { display: block; }
.nav { display: flex; gap: 6px; overflow-x: auto; padding: 10px 12px; background: var(--surface); border-bottom: 1px solid var(--border); scrollbar-width: none; }
.nav::-webkit-scrollbar { display: none; }
.nav a, .nav .soon { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 16px; border-radius: 999px;
  color: var(--text-muted); text-decoration: none; font-weight: 600; white-space: nowrap; transition: background .15s, color .15s; }
.nav a:hover { background: var(--bg); color: var(--text-dark); }
.nav a[aria-current="page"] { background: var(--brand-tint); color: var(--brand-dark); }
.nav .soon { color: #9aa8a4; font-weight: 500; }
.nav .soon small { padding: 1px 8px; border-radius: 999px; background: var(--bg); border: 1px solid var(--border); font-size: 11px; }
.content { max-width: 940px; margin: 0 auto; padding: 24px 16px 56px; }
.page-head { margin-bottom: 24px; }
.page-head p { margin: 6px 0 0; }
.section { margin-top: 32px; }
.section > h2 { margin-bottom: 12px; }

/* the one bold element: the shareable link */
.link-hero { position: relative; overflow: hidden; padding: 28px 24px; border-radius: 24px; color: #fff;
  background: var(--brand-dark); }
.link-hero-url { margin: 0 0 8px; font-size: clamp(1.25rem, 5.4vw, 2rem); font-weight: 800; letter-spacing: -0.02em; word-break: break-all; line-height: 1.15; }
.link-hero-url b { color: var(--brand-bright); font-weight: 800; }
.link-hero-note { margin: 0 0 20px; max-width: 52ch; color: rgba(255,255,255,.82); font-size: 14px; }
.link-hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* ledger: money as rows, not tiles */
.ledger { margin: 0; padding: 0; list-style: none; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-card); box-shadow: var(--shadow-sm); }
.ledger li { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding: 16px 20px; }
.ledger li + li { border-top: 1px solid var(--border); }
.ledger .what small { display: block; color: var(--text-muted); font-size: 13px; font-weight: 400; }
.ledger .what { font-weight: 600; }
.ledger .amt { font-weight: 800; font-size: 1.1rem; white-space: nowrap; letter-spacing: -0.01em; }
.ledger .amt.key { color: var(--brand-dark); font-size: 1.4rem; }

.rows { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-card); box-shadow: var(--shadow-sm); }
.rows .row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 20px; }
.rows .row + .row { border-top: 1px solid var(--border); }
.rows .row .n { font-weight: 800; }
.empty { padding: 28px 20px; background: var(--surface); border: 1.5px dashed var(--border-strong); border-radius: var(--radius-card); color: var(--text-muted); text-align: center; }
.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-card); box-shadow: var(--shadow-sm); }
table.t { width: 100%; border-collapse: collapse; font-size: 14px; }
table.t th, table.t td { padding: 13px 18px; text-align: left; white-space: nowrap; }
table.t th { color: var(--text-muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; border-bottom: 1px solid var(--border); background: #fafbfa; }
table.t tr + tr td { border-top: 1px solid var(--border); }

@media (min-width: 900px) {
  .shell { display: grid; grid-template-columns: 236px 1fr; min-height: calc(100vh - 62px); }
  .nav { flex-direction: column; overflow: visible; gap: 4px; padding: 20px 14px; border-bottom: 0; border-right: 1px solid var(--border); }
  .nav a, .nav .soon { border-radius: var(--radius-field); width: 100%; justify-content: space-between; }
  .content { padding: 36px 32px 72px; width: 100%; }
  .topbar .who .name { max-width: 240px; }
}

/* ---------- products ---------- */
.visually-hidden { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); border: 0; white-space: nowrap; }
.small { font-size: 13px; }
.back { display: inline-block; margin-bottom: 8px; font-size: 14px; font-weight: 600; text-decoration: none; }
.back:hover { text-decoration: underline; }
.page-head-row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 14px; }
.page-head-row > div { flex: 1 1 240px; min-width: 0; }
.section-action { margin: 14px 0 0; }
.badge { display: inline-block; padding: 3px 11px; border-radius: 999px; border: 1px solid var(--border); background: var(--bg); color: var(--text-muted); font-size: 12px; font-weight: 700; white-space: nowrap; }
.badge-published, .badge-paid { background: #effbf3; border-color: #c6ebd6; color: #115c33; }
.badge-requested, .badge-processing { background: #fff8e6; border-color: #f0dca4; color: #7a5b00; }
.badge-failed, .badge-rejected, .badge-suspended { background: #fdf2f1; border-color: #f4d3cf; color: #8f2a22; }
.rows a.row { color: inherit; text-decoration: none; min-height: 54px; transition: background .15s; }
.rows a.row:hover { background: var(--bg); }

.product-list { overflow: hidden; }
.product-row { display: flex; align-items: center; gap: 14px; padding: 14px 16px; color: inherit; text-decoration: none; min-height: 76px; transition: background .15s; }
.product-row + .product-row { border-top: 1px solid var(--border); }
.product-row:hover { background: var(--bg); }
.product-row .thumb { flex: 0 0 56px; width: 56px; height: 56px; display: flex; align-items: center; justify-content: center; overflow: hidden;
  border-radius: 14px; background: var(--brand-tint); color: var(--brand-dark); font-weight: 800; font-size: 1.2rem; }
.product-row .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.product-row .info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.product-row .info strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.product-row .meta { color: var(--text-muted); font-size: 13px; }

.form-stack { display: block; }
.panel { margin-bottom: 18px; padding: 24px 22px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-card); box-shadow: var(--shadow-sm); }
.panel > h2 { margin-bottom: 16px; }
.panel .field:last-child { margin-bottom: 0; }
.fee-box { margin-top: 14px; padding: 14px 16px; border-radius: var(--radius-field); background: var(--bg); border: 1px solid var(--border); font-size: 14px; }
.fee-box:empty { display: none; }
.fee-box dl { margin: 0; }
.fee-box .fee-row { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; }
.fee-box .fee-row.total { margin-top: 6px; padding-top: 10px; border-top: 1px solid var(--border); font-weight: 800; color: var(--brand-dark); font-size: 1.05rem; }
.fee-box .fee-note { margin: 8px 0 0; font-size: 13px; color: var(--text-muted); }
.cover-current { display: flex; align-items: flex-end; gap: 14px; margin-bottom: 14px; }
.cover-current img, .cover-preview { display: block; max-width: 200px; max-height: 160px; border-radius: var(--radius-field); border: 1px solid var(--border); object-fit: cover; }
.cover-preview { margin-top: 10px; }
.file-list { margin: 0 0 16px; padding: 0; list-style: none; border: 1px solid var(--border); border-radius: var(--radius-field); overflow: hidden; }
.file-list li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 14px; padding: 13px 16px; }
.file-list li + li { border-top: 1px solid var(--border); }
.file-name { flex: 1 1 180px; min-width: 0; font-weight: 600; }
.file-name small { display: block; font-weight: 400; color: var(--text-muted); }
.file-actions { display: flex; gap: 18px; align-items: center; min-height: 44px; }
.danger { color: var(--error); }
.danger-zone { margin: 4px 0 18px; }
.btn-link { min-height: 44px; }
.topbar .btn-link { min-height: 36px; }
input[type="file"].input { padding: 11px; height: auto; }
input[type="file"].input::file-selector-button { margin-right: 12px; padding: 7px 14px; border: 0; border-radius: 999px; background: var(--brand-tint); color: var(--brand-dark); font: inherit; font-weight: 700; cursor: pointer; }

/* Save bar stays within thumb reach on phones */
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 -16px 14px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: rgba(245,247,245,.92); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-top: 1px solid var(--border); position: sticky; bottom: 0; z-index: 5; }
.actions .btn { flex: 1 1 140px; }

/* ---------- courses ---------- */
.module { margin-bottom: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-card); overflow: hidden; box-shadow: var(--shadow-sm); }
.module-head { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 14px 16px; background: #fafbfa; border-bottom: 1px solid var(--border); }
.module-head form.rename { flex: 1 1 200px; display: flex; gap: 8px; min-width: 0; }
.module-head form.rename .input { min-height: 42px; font-weight: 700; }
.lesson-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; padding: 12px 16px; }
.lesson-row + .lesson-row { border-top: 1px solid var(--border); }
.lesson-row .l-main { flex: 1 1 200px; min-width: 0; }
.lesson-row .l-main a { font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.lesson-row .l-main a:hover { text-decoration: underline; }
.lesson-row .l-meta { display: block; font-size: 13px; color: var(--text-muted); }
.row-tools { display: flex; align-items: center; gap: 2px; margin-left: auto; }
.row-tools form { margin: 0; }
.icon-btn { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; border: 0; background: none; border-radius: 10px;
  color: var(--brand-dark); font: inherit; font-weight: 700; cursor: pointer; text-decoration: none; }
.icon-btn:hover { background: var(--brand-tint); }
.icon-btn[disabled] { opacity: .3; cursor: default; }
.icon-btn.danger { color: var(--error); }
.icon-btn.danger:hover { background: #fdf2f1; }
.module-add { padding: 12px 16px; border-top: 1px solid var(--border); }
.add-module-form { display: flex; flex-wrap: wrap; gap: 10px; }
.add-module-form .input { flex: 1 1 220px; }
.type-toggle { display: flex; gap: 10px; margin-bottom: 16px; }
.type-toggle label { flex: 1; display: flex; align-items: center; gap: 10px; padding: 13px 16px; border: 1.5px solid var(--border); border-radius: var(--radius-field);
  background: var(--surface); font-weight: 600; cursor: pointer; transition: border-color .15s, background .15s; }
.type-toggle label:hover { border-color: var(--border-strong); }
.type-toggle label:has(input:checked) { border-color: var(--brand); background: var(--brand-tint); }
.type-toggle input { accent-color: var(--brand); width: 18px; height: 18px; }
.video-frame { position: relative; width: 100%; aspect-ratio: 16 / 9; margin-top: 12px; border-radius: var(--radius-field); overflow: hidden; background: #000; }
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.is-hidden { display: none !important; }

/* ---------- office: services + availability ---------- */
.day-card { margin-bottom: 10px; padding: 12px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-card); box-shadow: var(--shadow-sm); }
.day-card .day-head { display: flex; align-items: center; gap: 12px; min-height: 44px; font-weight: 700; }
.day-card .day-head input { width: 20px; height: 20px; accent-color: var(--brand); }
.day-card .ranges { display: none; margin-top: 6px; }
.day-card.is-open { border-color: #c9e3de; }
.day-card.is-open .ranges { display: block; }
.range-row { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.range-row .input { min-width: 0; flex: 1; }
.range-row span { color: var(--text-muted); }
.range-label { font-size: 13px; color: var(--text-muted); margin: 8px 0 0; }
.off-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; }
.off-row + .off-row { border-top: 1px solid var(--border); }
.off-row .o-text { min-width: 0; overflow-wrap: anywhere; }
.off-row small { display: block; color: var(--text-muted); }
.add-off { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.add-off .input { flex: 1 1 150px; }
.notice-box { margin-bottom: 16px; padding: 13px 16px; border-radius: var(--radius-field); background: #fff8e6; border: 1px solid #f0dca4; color: #7a5b00; font-size: 14px; }
.two-col { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 14px; }
@media (min-width: 560px) { .two-col { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- payouts ---------- */
.payout-box { margin-top: 14px; padding: 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-card); box-shadow: var(--shadow-sm); }
.payout-box .dest { margin: 0 0 14px; }
.payout-box .dest strong { overflow-wrap: anywhere; }
.payout-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 20px; }
.payout-row + .payout-row { border-top: 1px solid var(--border); }
.payout-row .p-main { min-width: 0; }
.payout-row .p-main strong { display: block; }
.payout-row .p-main span { color: var(--text-muted); font-size: 13px; }

/* ---------- settings ---------- */
.avatar-edit { display: flex; gap: 18px; align-items: flex-start; margin-bottom: 18px; }
.avatar-edit .avatar { flex: 0 0 76px; width: 76px; height: 76px; border-radius: 50%; overflow: hidden; display: flex; align-items: center; justify-content: center;
  background: var(--brand-tint); color: var(--brand-dark); font-size: 1.8rem; font-weight: 800; box-shadow: 0 0 0 4px var(--surface), 0 0 0 5px var(--border); }
.avatar-edit .avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.avatar-fields { flex: 1; min-width: 0; }
.avatar-fields label { display: block; margin-bottom: 6px; font-weight: 600; }
.static-value { margin: 0; padding: 12px 16px; border: 1.5px solid var(--border); border-radius: var(--radius-field); background: var(--bg); overflow-wrap: anywhere; }
.status-card { margin-bottom: 16px; padding: 16px 18px; border: 1px solid var(--border); border-radius: var(--radius-field); background: var(--bg); }
.status-card.is-direct { background: #effbf3; border-color: #c6ebd6; }
.status-title { margin: 0 0 2px; font-weight: 700; overflow-wrap: anywhere; }
.status-line { margin: 8px 0 0; font-size: 14px; }
.confirm-box { margin-bottom: 16px; padding: 16px 18px; border: 2px solid var(--brand-bright); border-radius: var(--radius-field); background: #f3fcf6; }
.confirm-box p { margin: 0; }
.actions-inline { display: flex; flex-wrap: wrap; gap: 10px; }
.actions-inline .btn { flex: 1 1 160px; }
select.input { appearance: auto; }
@media (max-width: 380px) {
  .avatar-edit { flex-direction: column; }
  .content { padding-left: 12px; padding-right: 12px; }
  .panel { padding: 18px 14px; }
  .auth-card { padding: 26px 20px; border-radius: 20px; }
  .link-hero { padding: 22px 18px; }
  .link-hero-actions .btn { flex: 1 1 100%; }
  .actions { margin-left: -12px; margin-right: -12px; padding-left: 12px; padding-right: 12px; }
}
@media (min-width: 900px) {
  .actions { position: static; margin: 0 0 14px; padding: 0; background: none; border: 0; -webkit-backdrop-filter: none; backdrop-filter: none; }
  .actions .btn { flex: 0 0 auto; min-width: 160px; }
}
/* ---------- brand logo ---------- */
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--brand-dark); }
.brand-mark { position: relative; flex: 0 0 auto; width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px;
  background: var(--brand-dark); }
.brand-mark svg { width: 22px; height: 22px; display: block; }
.brand-name { font-size: 1.35rem; font-weight: 800; letter-spacing: -0.04em; line-height: 1; color: var(--brand-dark); }
.brand-name em { margin-left: 6px; font-style: normal; font-weight: 500; letter-spacing: -0.02em; color: var(--brand); }
.auth-brand { margin-bottom: 28px; }
.topbar .brand-mark { width: 32px; height: 32px; border-radius: 10px; }
.topbar .brand-mark svg { width: 19px; height: 19px; }
.topbar .brand-name { font-size: 1.15rem; }
/* ---------- dashboard ---------- */
.link-hero-label { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 14px; padding: 5px 12px; border-radius: 999px;
  background: rgba(255,255,255,.12); font-size: 12px; font-weight: 700; letter-spacing: .03em; }
.link-hero-label::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--brand-bright); box-shadow: 0 0 0 3px rgba(37,211,102,.25); }
.ledger li:first-child { padding: 24px 20px; align-items: center; border-radius: var(--radius-card) var(--radius-card) 0 0;
  background: #f3fbf6; }
.ledger li:first-child .amt.key { font-size: clamp(1.7rem, 7vw, 2.2rem); letter-spacing: -0.03em; }
.rows .row-label { display: inline-flex; align-items: center; gap: 12px; min-width: 0; font-weight: 600; }
.rows .row-icon { flex: 0 0 38px; width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; background: var(--brand-tint); color: var(--brand-dark); }
.rows .row-icon svg { width: 19px; height: 19px; }
.rows .row .n { min-width: 34px; padding: 3px 11px; border-radius: 999px; background: var(--bg); border: 1px solid var(--border); text-align: center; font-size: 14px; }
.section-action { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.badge-settled_direct, .badge-eligible { background: #effbf3; border-color: #c6ebd6; color: #115c33; }
.badge-held { background: #fff8e6; border-color: #f0dca4; color: #7a5b00; }
.badge-refunded { background: #fdf2f1; border-color: #f4d3cf; color: #8f2a22; }
@media (max-width: 380px) { .section-action .btn { flex: 1 1 100%; } }
/* ---------- mobile menu + icon buttons ---------- */
.topbar { min-height: 62px; }
.nav-toggle { position: absolute; opacity: 0; pointer-events: none; width: 1px; height: 1px; }
.icon-out, .menu-btn { flex: 0 0 auto; width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; padding: 0;
  border: 1px solid var(--border-strong); border-radius: 999px; background: var(--surface); color: var(--text-dark); cursor: pointer; transition: background .15s, border-color .15s; }
.icon-out:hover, .menu-btn:hover { background: var(--bg); border-color: var(--brand); }
.icon-out svg, .menu-btn svg { width: 20px; height: 20px; display: block; }
.menu-btn .ico-close { display: none; }
.nav-toggle:checked ~ .topbar .menu-btn .ico-open { display: none; }
.nav-toggle:checked ~ .topbar .menu-btn .ico-close { display: block; }
.nav-toggle:focus-visible ~ .topbar .menu-btn { outline: 3px solid var(--brand-bright); outline-offset: 2px; }
.topbar .who { gap: 8px; }
@media (max-width: 899px) {
  .topbar .who .name { display: none; }
  .nav { display: none; position: fixed; top: 62px; left: 0; right: 0; z-index: 19; flex-direction: column; gap: 4px; padding: 12px;
    max-height: calc(100vh - 62px); overflow-y: auto; background: var(--surface); border-bottom: 1px solid var(--border); box-shadow: 0 18px 30px -14px rgba(13, 27, 25, .25); }
  .nav-toggle:checked ~ .shell .nav { display: flex; }
  .nav a, .nav .soon { width: 100%; justify-content: space-between; min-height: 48px; border-radius: var(--radius-field); font-size: 15px; }
}
@media (min-width: 900px) {
  .menu-btn { display: none; }
  .nav { display: flex; position: static; box-shadow: none; max-height: none; }
  .topbar .who { gap: 14px; }
}
/* ---------- portfolio (manage) ---------- */
.pf-forms { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 18px; }
.pf-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; margin-top: 18px; }
.pf-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-card); box-shadow: var(--shadow-sm); overflow: hidden; }
.pf-thumb { position: relative; aspect-ratio: 4 / 3; display: flex; align-items: center; justify-content: center; background: var(--brand-tint); color: var(--brand-dark); font-weight: 800; }
.pf-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pf-kind { position: absolute; left: 10px; top: 10px; padding: 3px 11px; border-radius: 999px; background: rgba(13, 27, 25, .72); color: #fff; font-size: 12px; font-weight: 700; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.pf-body { padding: 14px; }
.pf-body .input { min-height: 44px; margin-bottom: 10px; font-size: 15px; }
.pf-tools { display: flex; align-items: center; gap: 2px; margin-top: 6px; }
.pf-tools form { margin: 0; }
.spacer { flex: 1; }
@media (min-width: 560px) { .pf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 760px) { .pf-forms { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 900px) { .pf-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; animation: none !important; } }

/* ---------- customers ---------- */
.search-form { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }
.search-form .input { flex: 1 1 220px; min-width: 0; }
