/* Admin-only styles, layered on styles.css */
.admin-shell { display: grid; grid-template-columns: 244px 1fr; min-height: 100vh; }
.sidebar { background: var(--plum); color: #eaf0f6; padding: 0 0 30px; position: sticky; top: 0; align-self: start; height: 100vh; overflow-y: auto; }
.sidebar .brand { padding: 20px 20px 16px; border-bottom: 1px solid rgba(255,255,255,.12); }
.sidebar .brand .sb-wordmark { height: 30px; width: auto; display: block; margin-bottom: 12px; }
.sidebar .brand b { font-family: var(--serif); font-size: 18px; display: block; }
.sidebar .brand span { display: block; font-size: 12px; opacity: .7; margin-top: 2px; }
.navlink { display: flex; align-items: center; gap: 10px; padding: 11px 20px; color: #cdd8e2; text-decoration: none; font-size: 15px; font-weight: 500; border-left: 3px solid transparent; cursor: pointer; }
.navlink:hover { background: rgba(255,255,255,.06); }
.navlink.active { background: rgba(255,255,255,.1); border-left-color: var(--gold); color: #fff; }
.navlink .ico { width: 20px; text-align: center; opacity: .9; }
.nav-section { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; opacity: .5; padding: 18px 20px 6px; }
.whoami { margin: 14px 20px 0; padding: 12px; background: rgba(255,255,255,.07); border-radius: 10px; font-size: 13px; }
.whoami b { display: block; font-size: 14px; }
.role-tag { display: inline-block; margin-top: 6px; background: var(--gold); color: var(--plum); font-weight: 700; font-size: 11px; padding: 2px 8px; border-radius: 999px; }

.main { padding: 26px 32px 80px; max-width: 1000px; }
.page-title { font-size: 26px; margin: 0 0 4px; }
.page-sub { color: var(--muted); margin: 0 0 22px; }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px,1fr)); gap: 14px; margin-bottom: 26px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px; box-shadow: var(--shadow); }
.stat .n { font-size: 30px; font-weight: 600; font-family: var(--serif); color: var(--plum); }
.stat .l { color: var(--muted); font-size: 13px; }

table.rows { width: 100%; border-collapse: collapse; background: #fff; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); }
table.rows th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 12px 14px; border-bottom: 1px solid var(--line); }
table.rows td { padding: 12px 14px; border-bottom: 1px solid var(--line); font-size: 14.5px; vertical-align: top; }
table.rows tr:last-child td { border-bottom: none; }
.row-actions { display: flex; gap: 6px; flex-wrap: wrap; }
/* Churches panel (platform owner): keep the per-row status + switch controls on-screen. They wrap
   to the next line instead of running off the right edge, and align right on wide screens. */
#churchTable td:last-child { white-space: normal; }
#churchTable td:last-child .row-actions { justify-content: flex-end; align-items: center; }
#churchTable .church-status { flex: none; }

/* People & access roster: give the Role and Congregation dropdowns room so their option text is
   not clipped on desktop. */
#userTable td select { width: 100%; min-width: 168px; }

.review-card { display: grid; grid-template-columns: 130px 1fr; gap: 16px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 16px; box-shadow: var(--shadow); margin-bottom: 16px; }
.review-card img { width: 130px; height: 100px; object-fit: contain; background: #f2ede2; border-radius: 8px; }

.section { display: none; }
.section.active { display: block; }

.pill { font-size: 12px; padding: 2px 8px; border-radius: 999px; font-weight: 700; }
.composer textarea { min-height: 150px; font-size: 15px; }
.copied { color: var(--ok); font-weight: 600; font-size: 14px; }

/* "Copy artist submission link" bar: a prominent, brand-navy card so admins can grab the URL to
   share with artists. Wraps cleanly on phones. */
.submit-link-bar {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  background: linear-gradient(135deg, var(--plum), var(--plum-2)); color: #fff;
  border-radius: 12px; padding: 14px 18px; margin: 0 0 22px; box-shadow: var(--shadow);
}
.submit-link-bar .sl-label { font-size: 13px; opacity: .85; }
.submit-link-bar .sl-url { font-weight: 600; word-break: break-all; }
.submit-link-bar .sl-url a { color: var(--gold); text-decoration: none; }
.submit-link-bar .sl-copied { color: var(--gold); font-weight: 600; font-size: 14px; }
.locked { opacity: .55; }
.mobile-topbar { display: none; }

@media (max-width: 820px) {
  .admin-shell { grid-template-columns: 1fr; }
  .sidebar { position: static; height: auto; display: none; }
  .sidebar.open { display: block; }
  .mobile-topbar { display: flex; align-items: center; justify-content: space-between; background: var(--plum); color: #fff; padding: 12px 16px; position: sticky; top: 0; z-index: 5; }
  .main { padding: 18px 16px 70px; }
  .review-card { grid-template-columns: 1fr; }
  .review-card img { width: 100%; height: 160px; }
}

/* Sub-group heading inside a nav section (e.g. Exhibits > Set up / Manage, Organization > Library). */
.nav-subsection { font-size: 10.5px; text-transform: uppercase; letter-spacing: .6px; opacity: .5; padding: 8px 14px 2px 22px; }

/* PII masking: emails/phones hidden from casual view, revealed per cell with an eye. */
.pii { display: inline-flex; align-items: center; gap: 6px; }
.pii-dots { letter-spacing: 1.5px; color: var(--muted); }
.pii.on .pii-dots { letter-spacing: normal; color: inherit; }
.pii-eye { background: none; border: none; cursor: pointer; font-size: 13px; line-height: 1; padding: 0 2px; opacity: .5; }
.pii-eye:hover, .pii.on .pii-eye { opacity: 1; }
