/* Business dashboard and admin (Blazor). Builds on site.css. */
main.biz { max-width: 980px; }

.biz-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; font-size: .95rem; }
.biz-nav a { color: rgb(255 255 255 / .85); text-decoration: none; padding: 2px 0; font-weight: 600; }
.biz-nav a:hover { color: var(--sun); }
.biz-nav a.active { color: #fff; box-shadow: inset 0 -3px 0 var(--sun); }
.inline { display: inline; margin: 0; }
.linkish { background: none; border: 0; padding: 0; color: var(--muted); font: inherit; cursor: pointer; text-decoration: underline; }
.top .linkish { color: rgb(255 255 255 / .7); }

.form { display: flex; flex-direction: column; gap: 10px; }
.form label { display: flex; flex-direction: column; gap: 4px; font-weight: 600; }
.form input:not([type=radio]):not([type=checkbox]), .form textarea, .form select, .row input {
  font: inherit; font-weight: 400; padding: 10px 12px; border: 2px solid var(--line); border-radius: 10px;
  background: var(--card); color: var(--text); width: 100%;
}
.form input:focus, .form textarea:focus, .form select:focus, .row input:focus { outline: none; border-color: var(--brand); }
.form .btn { align-self: flex-start; }
.form .btn-big { align-self: stretch; }
.row input { font-family: inherit; text-transform: none; letter-spacing: normal; }

.slug-input { display: flex; align-items: center; gap: 2px; border: 2px solid var(--line); border-radius: 10px; padding-left: 12px; background: var(--card); }
.slug-input input { border: 0 !important; padding-left: 0 !important; }
.ok { color: #2e7d32; }

.banner { background: #fff4e5; border: 1px solid #ffd8a8; color: #7a3e00; padding: 12px 14px; border-radius: 10px; }
.banner.ok { background: #ebfbee; border-color: #b2f2bb; color: #1b5e20; }
.banner.warn { background: #fff0f0; border-color: #ffc9c9; color: var(--danger); }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 16px 0; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; display: flex; flex-direction: column; }
.stat .num { font-size: 1.8rem; font-weight: 700; color: var(--brand-dark); line-height: 1.1; }
.stat span:last-child { color: var(--muted); font-size: .875rem; }

.title-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.title-row h1, .title-row h2 { margin: 0; }
.row.between { justify-content: space-between; align-items: center; flex-wrap: wrap; }
.row.center { align-items: center; }
.grow { flex: 1; min-width: 0; }

.flyer-list { list-style: none; padding: 0; margin: 0; }
.flyer-row { display: flex; gap: 14px; align-items: flex-start; }
.flyer-row img { border-radius: 8px; flex: none; }
.flyer-row p { margin: 4px 0; }
.thumb-gone { width: 80px; height: 100px; border-radius: 8px; background: var(--line); color: var(--muted); display: grid; place-items: center; font-size: .75rem; flex: none; }

.status { display: inline-block; padding: 1px 10px; border-radius: 99px; font-size: .75rem; font-weight: 600; background: var(--line); color: var(--text); }
.status-sent { background: #d3f9d8; color: #1b5e20; }
.status-scheduled, .status-sending { background: #d0ebff; color: #0b4a8b; }
.status-pendingapproval { background: #fff3bf; color: #7a5b00; }
.status-rejected { background: #ffe3e3; color: var(--danger); }

.new-flyer { display: grid; gap: 16px; }
@media (min-width: 900px) { .new-flyer { grid-template-columns: 1fr 360px; align-items: start; } .preview { position: sticky; top: 72px; } }
.file-pick { cursor: pointer; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.when { border: 0; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.when legend { font-weight: 600; margin-bottom: 4px; }
.radio { flex-direction: row !important; align-items: center; font-weight: 400 !important; gap: 8px !important; }
.flyer-placeholder { aspect-ratio: 4 / 5; display: grid; place-items: center; color: var(--muted); background: var(--line); }

.notif { display: grid; grid-template-columns: 20px 1fr auto; gap: 10px; align-items: start; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 12px; margin-bottom: 12px; box-shadow: 0 2px 8px rgb(0 0 0 / .08); }
.notif p { margin: 2px 0 0; font-size: .9rem; color: var(--muted); }
.notif-img { width: 56px; height: 56px; object-fit: cover; border-radius: 8px; }

.link-url { font-family: ui-monospace, Consolas, monospace; font-size: .9rem; word-break: break-all; background: var(--bg); padding: 8px 10px; border-radius: 8px; }
.link-actions { display: flex; flex-wrap: wrap; gap: 8px; }

#blazor-error-ui { position: fixed; bottom: 0; left: 0; right: 0; padding: 12px 16px; background: #fff3bf; color: #5c4400; z-index: 20; }
#blazor-error-ui:not([hidden]) { display: block; }

@media (max-width: 520px) { .stats { grid-template-columns: 1fr 1fr; } .top { flex-wrap: wrap; } }

.tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line); margin: 12px 0 16px; flex-wrap: wrap; }
.tabs button { background: none; border: 0; padding: 8px 12px; font: inherit; color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; }
.tabs button.active { color: var(--brand-dark); border-bottom-color: var(--brand); font-weight: 600; }
.admin-table { width: 100%; border-collapse: collapse; margin-top: 12px; font-size: .95rem; }
.admin-table th, .admin-table td { text-align: left; padding: 8px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.admin-table select { font: inherit; padding: 4px; }
@media (max-width: 700px) { .admin-table { display: block; overflow-x: auto; } }

.help-toc { display: flex; flex-wrap: wrap; gap: 6px 16px; }
main.biz section[id] { scroll-margin-top: 16px; }
main.biz ol, main.biz ul { padding-left: 1.3em; }
main.biz li { margin: 4px 0; }
