:root {
  color-scheme: dark;
  --bg: #0e0c0b;
  --bg-2: #15110f;
  --panel: rgba(30, 25, 22, .92);
  --panel-2: rgba(41, 33, 28, .88);
  --panel-3: #211b18;
  --border: rgba(255,255,255,.09);
  --border-strong: rgba(255,255,255,.16);
  --text: #fffaf6;
  --muted: #a99f98;
  --accent: #ff8a2a;
  --accent-2: #ffc15b;
  --accent-soft: rgba(255,138,42,.14);
  --purple: #8d72ff;
  --pink: #e7559b;
  --success: #55d68b;
  --danger: #ff6b6b;
  --warning: #f8c75e;
  --shadow: 0 24px 60px rgba(0,0,0,.28);
  --sidebar: 248px;
  --font-xs: 12px;
  --font-sm: 14px;
  --font-md: 16px;
  --font-lg: 18px;
  --font-xl: 24px;
  --font-2xl: 32px;
  --font-3xl: 48px;
}

* { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: var(--font-sm);
  line-height: 1.5;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body::before { content: ""; position: fixed; inset: 0; z-index: -2; background:
  radial-gradient(circle at 78% -5%, rgba(255,155,56,.18), transparent 34rem),
  radial-gradient(circle at 45% 105%, rgba(122,78,255,.10), transparent 32rem),
  linear-gradient(160deg, #100d0c, #0d0d0f 65%);
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button { color: inherit; }
img { max-width: 100%; }
code, .mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }

.app-shell { display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); }
.sidebar { position: fixed; inset: 0 auto 0 0; width: var(--sidebar); z-index: 30; display: flex; flex-direction: column; padding: 22px 16px; background: rgba(12,10,9,.86); border-right: 1px solid var(--border); backdrop-filter: blur(24px); }
.sidebar-brand { display: flex; gap: 12px; align-items: center; padding: 8px 10px 24px; }
.sidebar-brand img { width: 46px; height: 46px; object-fit: cover; border-radius: 50%; background: #fff; box-shadow: 0 8px 28px rgba(255,138,42,.14); }
.sidebar-brand strong, .sidebar-brand small { display: block; }
.sidebar-brand strong { font-size: 17px; letter-spacing: -.02em; }
.sidebar-brand small { color: var(--muted); margin-top: 2px; font-size: 12px; text-transform: uppercase; letter-spacing: .12em; }
.sidebar-nav { display: grid; gap: 6px; }
.sidebar-nav a { display: flex; align-items: center; gap: 12px; padding: 11px 13px; color: #cfc6c0; border-radius: 13px; font-size: 14px; font-weight: 700; transition: .18s ease; }
.sidebar-nav a:hover { background: rgba(255,255,255,.05); color: #fff; }
.sidebar-nav a.active { background: linear-gradient(120deg, rgba(255,138,42,.22), rgba(255,193,91,.10)); color: #fff; border: 1px solid rgba(255,138,42,.22); }
.nav-icon { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 8px; background: rgba(255,255,255,.045); font-size: 15px; }
.sidebar-footer { margin-top: auto; display: grid; justify-items: center; gap: 8px; color: #756b64; font-size: 12px; }
.sidebar-logo { width: 132px; padding: 6px; background: #fff; border-radius: 12px; opacity: .88; }

.workspace { grid-column: 2; min-width: 0; min-height: 100vh; }
.topbar { position: sticky; top: 0; z-index: 20; height: 78px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 34px; background: rgba(14,12,11,.72); border-bottom: 1px solid var(--border); backdrop-filter: blur(20px); }
.topbar-copy { display: grid; gap: 2px; }
.topbar-copy strong { font-size: 16px; }
.topbar-copy span { color: var(--muted); font-size: 12px; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.topbar-actions form { margin: 0; }
.avatar-button { width: 40px; height: 40px; border: 0; padding: 2px; border-radius: 50%; cursor: pointer; background: #fff; overflow: hidden; box-shadow: 0 8px 22px rgba(0,0,0,.25); }
.avatar-button img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.menu-toggle { display: none; border: 0; background: transparent; font-size: 22px; cursor: pointer; }

.page { width: min(1460px, calc(100% - 56px)); margin: 0 auto; padding: 34px 0 54px; }
.dashboard-hero, .page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.dashboard-hero h1, .page-heading h1 { margin: 7px 0 8px; font-size: clamp(32px, 4vw, 52px); line-height: 1; letter-spacing: -.045em; }
.dashboard-hero p, .page-heading p { margin: 0; color: var(--muted); }
.page-heading { align-items: flex-start; }
.page-heading.with-actions { align-items: flex-end; }
.eyebrow { color: var(--accent-2); text-transform: uppercase; letter-spacing: .14em; font-size: 12px; font-weight: 900; }
.back { display: block; margin-bottom: 16px; color: var(--muted); font-size: 13px; }
.server-pill { display: flex; gap: 10px; align-items: center; min-width: 240px; padding: 12px 14px; border: 1px solid var(--border); background: rgba(255,255,255,.035); border-radius: 15px; }
.server-pill strong, .server-pill small { display: block; }
.server-pill small { color: var(--muted); margin-top: 2px; font-size: 12px; }
.status-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--danger); box-shadow: 0 0 0 5px rgba(255,107,107,.08); }
.server-pill.online .status-dot { background: var(--success); box-shadow: 0 0 0 5px rgba(85,214,139,.09); }

.card, .metric-card { border: 1px solid var(--border); background: linear-gradient(180deg, rgba(255,255,255,.022), transparent), var(--panel); box-shadow: var(--shadow); border-radius: 20px; overflow: hidden; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 14px; margin-bottom: 16px; }
.metric-card { min-height: 138px; padding: 22px; display: flex; flex-direction: column; justify-content: flex-end; position: relative; }
.metric-card::after { content: ""; position: absolute; width: 110px; height: 110px; border-radius: 50%; top: -55px; right: -40px; background: rgba(255,255,255,.025); }
.metric-card.premium { background: linear-gradient(135deg, rgba(255,138,42,.34), rgba(255,193,91,.12) 55%, rgba(141,114,255,.13)), var(--panel); border-color: rgba(255,155,65,.25); }
.metric-label { color: #d7cec8; font-size: 12px; font-weight: 700; }
.metric-value { margin: 8px 0 5px; font-size: clamp(26px, 3vw, 38px); font-weight: 700; letter-spacing: -.04em; }
.metric-meta { color: var(--muted); font-size: 12px; }

.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(300px, .8fr); gap: 16px; margin-bottom: 16px; }
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding: 22px 24px; }
.card-head h2 { margin: 5px 0 0; font-size: 20px; }
.card-head p { margin: 5px 0 0; }
.card-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.card-actions form { margin: 0; }
.chip { color: #ffdaa2; border: 1px solid rgba(255,176,75,.18); background: rgba(255,143,42,.09); padding: 8px 10px; border-radius: 999px; font-size: 12px; font-weight: 800; }

.chart-card { min-height: 320px; }
.bar-chart { height: 220px; display: grid; grid-template-columns: repeat(6, 1fr); align-items: end; gap: 16px; padding: 8px 28px 24px; }
.bar-item { height: 100%; display: grid; grid-template-rows: 1fr auto; align-items: end; gap: 8px; text-align: center; color: var(--muted); }
.bar-track { height: 100%; min-height: 130px; display: flex; align-items: flex-end; justify-content: center; border-bottom: 1px solid var(--border); }
.bar-track span { display: block; width: min(42px, 68%); min-height: 5px; border-radius: 12px 12px 4px 4px; background: linear-gradient(180deg, var(--accent-2), var(--accent) 56%, #7c5cff); box-shadow: 0 8px 22px rgba(255,138,42,.15); }

.server-card { padding: 22px; }
.server-card-top { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.server-card-top img { width: 58px; height: 58px; border-radius: 50%; background: #fff; }
.server-card-top h2 { margin: 4px 0 0; }
.server-facts { display: grid; gap: 0; margin-bottom: 18px; }
.server-facts > div { display: flex; justify-content: space-between; gap: 20px; padding: 11px 0; border-top: 1px solid var(--border); font-size: 12px; }
.server-facts span { color: var(--muted); }
.server-facts strong { max-width: 190px; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.success-text { color: var(--success); }

.access-card { scroll-margin-top: 96px; }
.table-wrap { width: 100%; overflow-x: auto; }
.modern-table { width: 100%; min-width: 1120px; border-collapse: collapse; }
.modern-table th, .modern-table td { text-align: left; padding: 15px 18px; border-top: 1px solid var(--border); vertical-align: middle; font-size: 12px; }
.modern-table th { color: #7f7772; font-size: 12px; text-transform: uppercase; letter-spacing: .12em; font-weight: 800; }
.client-cell { display: flex; align-items: center; gap: 10px; min-width: 175px; }
.client-avatar { width: 36px; height: 36px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; background: linear-gradient(135deg, rgba(255,138,42,.95), rgba(135,90,255,.8)); font-weight: 900; }
.client-avatar.large { width: 52px; height: 52px; font-size: 19px; }
.client-cell small, td small { display: block; color: var(--muted); margin-top: 4px; }
.tags { display: flex; flex-wrap: wrap; gap: 5px; max-width: 260px; }
.tag { border: 1px solid var(--border); background: rgba(255,255,255,.035); border-radius: 999px; padding: 5px 8px; font-size: 12px; white-space: nowrap; }
.badge { display: inline-flex; align-items: center; padding: 6px 9px; border-radius: 999px; font-size: 12px; font-weight: 800; border: 1px solid var(--border); background: var(--panel-3); }
.badge.active { color: #8deab0; border-color: rgba(85,214,139,.24); background: rgba(85,214,139,.07); }
.badge.pending { color: #f7d27a; border-color: rgba(248,199,94,.24); background: rgba(248,199,94,.06); }
.badge.expired, .badge.revoked { color: #b4aaa4; }
.badge.error { color: #ff9b99; border-color: rgba(255,107,107,.25); }
.payment { font-size: 12px; font-weight: 800; }
.payment.paid { color: var(--success); }
.payment.pending { color: var(--warning); }
.payment.gift { color: #d2b8ff; }
.error-text { color: #ff9997; max-width: 180px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.row-actions { display: flex; gap: 5px; justify-content: flex-end; }
.row-actions form { margin: 0; }
.icon-action { width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid var(--border); background: rgba(255,255,255,.025); border-radius: 9px; cursor: pointer; }
.icon-action:hover { border-color: var(--border-strong); background: rgba(255,255,255,.055); }
.icon-action.danger { color: #ff8987; }

.service-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-width: 145px; }
.service-head small { margin: 0; }
.service-meter { height: 7px; margin: 7px 0 4px; overflow: hidden; border: 1px solid var(--border); border-radius: 999px; background: #0e0c0b; }
.service-meter span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }
.service-meter.large { height: 9px; margin: 12px 0 16px; }
.service-summary { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px; }
.service-summary > div { display: grid; gap: 5px; padding: 12px 14px; border: 1px solid var(--border); border-radius: 13px; background: rgba(255,255,255,.025); }

.button { appearance: none; border: 1px solid var(--border); border-radius: 11px; padding: 10px 14px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-weight: 800; font-size: 12px; transition: .16s ease; background: var(--panel-2); color: var(--text); }
.button:hover { transform: translateY(-1px); border-color: var(--border-strong); }
.button.primary { color: #1b1007; border-color: rgba(255,190,90,.45); background: linear-gradient(135deg, #ff8a2a, #ffc05b); box-shadow: 0 10px 28px rgba(255,138,42,.14); }
.button.secondary { background: rgba(255,255,255,.05); }
.button.soft { background: var(--accent-soft); color: #ffd6a3; border-color: rgba(255,138,42,.17); }
.button.ghost { background: transparent; }
.button.small { padding: 7px 10px; font-size: 12px; }
.button.wide { width: 100%; }
.button:disabled { opacity: .45; cursor: not-allowed; transform: none; }

.alert { border: 1px solid var(--border); border-radius: 14px; padding: 13px 15px; margin-bottom: 18px; background: var(--panel-2); font-size: 12px; overflow-wrap: anywhere; }
.alert.success { border-color: rgba(85,214,139,.3); color: #a7f2c3; background: rgba(85,214,139,.07); }
.alert.error { border-color: rgba(255,107,107,.3); color: #ffb0ae; background: rgba(255,107,107,.06); }
.alert.warning { border-color: rgba(248,199,94,.3); color: #f6d98f; background: rgba(248,199,94,.06); }

.form-layout { display: grid; grid-template-columns: minmax(0,1fr) 360px; gap: 16px; align-items: start; }
.form-main { display: grid; gap: 16px; }
.form-side { min-width: 0; }
.sticky-card { position: sticky; top: 96px; }
.form-section { padding: 22px; }
.section-title { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.section-title.compact-title { margin-bottom: 18px; }
.section-title h2 { margin: 0 0 3px; font-size: 18px; }
.section-title p { margin: 0; color: var(--muted); font-size: 12px; }
.section-number { width: 35px; height: 35px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 11px; background: var(--accent-soft); color: var(--accent-2); font-size: 12px; font-weight: 900; }
.form-grid { display: grid; gap: 14px; }
.form-grid.two { grid-template-columns: repeat(2, minmax(0,1fr)); }
label { display: grid; gap: 7px; font-size: 12px; font-weight: 800; color: #eee5df; }
label small { color: var(--muted); font-weight: 500; line-height: 1.4; }
input, select, textarea { width: 100%; border: 1px solid var(--border); border-radius: 11px; background: rgba(8,8,9,.6); color: var(--text); padding: 11px 12px; outline: none; }
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: rgba(255,138,42,.65); box-shadow: 0 0 0 3px rgba(255,138,42,.09); }
.money-input { display: grid; grid-template-columns: 38px 1fr; align-items: center; border: 1px solid var(--border); border-radius: 11px; background: rgba(8,8,9,.6); overflow: hidden; }
.money-input span { text-align: center; color: var(--accent-2); font-weight: 900; }
.money-input input { border: 0; border-left: 1px solid var(--border); border-radius: 0; background: transparent; }
.identity-card { display: flex; gap: 12px; align-items: center; padding: 14px; border-radius: 14px; background: rgba(255,255,255,.025); border: 1px solid var(--border); }
.identity-card h3, .identity-card p { margin: 0; }
.identity-card p { color: var(--muted); margin-top: 3px; font-size: 12px; }
.library-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 10px; }
.library-option, .checkline { display: flex; align-items: flex-start; gap: 10px; padding: 12px; border: 1px solid var(--border); border-radius: 13px; background: rgba(255,255,255,.018); cursor: pointer; }
.library-option:hover, .checkline:hover { border-color: var(--border-strong); }
.library-option input, .checkline input { width: auto; margin-top: 3px; accent-color: var(--accent); }
.library-icon { width: 30px; height: 30px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 9px; background: rgba(255,255,255,.045); }
.disabled-option { opacity: .72; cursor: default; }
.inline-check { margin-top: 16px; width: fit-content; }
.duration-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; max-width: 460px; }
.form-actions { display: flex; gap: 8px; justify-content: flex-end; }
.form-actions.vertical { display: grid; margin-top: 6px; }

.content-metrics { margin-bottom: 16px; }
.library-cards { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 14px; margin-bottom: 16px; }
.library-card { padding: 18px; display: flex; gap: 14px; }
.library-card-icon { width: 48px; height: 48px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 14px; background: linear-gradient(135deg, rgba(255,138,42,.18), rgba(141,114,255,.12)); font-size: 22px; }
.library-card-main { min-width: 0; flex: 1; }
.library-card-title { display: flex; justify-content: space-between; gap: 10px; }
.library-card-title h3 { margin: 4px 0 0; }
.library-numbers { display: flex; gap: 20px; padding: 18px 0; }
.library-numbers div { display: grid; gap: 2px; }
.library-numbers strong { font-size: 27px; letter-spacing: -.04em; }
.library-numbers span { color: var(--muted); font-size: 12px; }
.library-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-top: 12px; border-top: 1px solid var(--border); }
.library-card-foot small { color: var(--muted); }

.timeline-card { padding: 10px 22px; }
.timeline { display: grid; }
.timeline-item { display: grid; grid-template-columns: 18px 1fr; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--border); }
.timeline-item:last-child { border-bottom: 0; }
.timeline-dot { width: 10px; height: 10px; margin-top: 4px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 5px rgba(255,138,42,.08); }
.timeline-dot.access_created { background: var(--success); }
.timeline-dot.access_revoked, .timeline-dot.expiration { background: var(--danger); }
.timeline-dot.library_scan, .timeline-dot.content_snapshot { background: var(--purple); }
.timeline-title { display: flex; justify-content: space-between; gap: 18px; }
.timeline-title span { color: var(--muted); font-size: 12px; white-space: nowrap; }
.timeline-item small { color: var(--muted); margin-top: 4px; display: block; }

.empty { min-height: 300px; display: grid; place-items: center; align-content: center; text-align: center; padding: 36px; }
.empty img { width: 76px; height: 76px; border-radius: 50%; background: #fff; margin-bottom: 12px; }
.empty h3 { margin: 0 0 5px; }
.empty p { margin: 0 0 16px; }
.compact-empty { min-height: 180px; }
.compact { margin: 4px 0 0; }
.muted { color: var(--muted); }

.auth-shell { background: #0d0b0a; }
.auth-main { min-height: 100vh; display: grid; place-items: center; padding: 22px; }
.login-shell { width: min(1040px, 100%); min-height: 620px; display: grid; grid-template-columns: 1.1fr .9fr; border: 1px solid var(--border); border-radius: 28px; overflow: hidden; box-shadow: 0 40px 100px rgba(0,0,0,.42); }
.login-brand-panel { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; padding: 44px; background: linear-gradient(145deg, #2b1a11, #171114 55%, #18121d); }
.login-brand-panel::after { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 75% 18%, rgba(255,174,74,.32), transparent 35%), radial-gradient(circle at 8% 88%, rgba(141,114,255,.18), transparent 33%); }
.login-logo { position: relative; z-index: 2; width: 190px; padding: 12px; border-radius: 18px; background: rgba(255,255,255,.92); }
.login-brand-copy { position: relative; z-index: 2; max-width: 470px; }
.login-brand-copy h1 { margin: 8px 0 12px; font-size: clamp(42px, 6vw, 72px); line-height: .92; letter-spacing: -.055em; }
.login-brand-copy p { color: #c9beb6; line-height: 1.6; }
.login-card { display: flex; flex-direction: column; justify-content: center; padding: 52px; background: rgba(19,17,17,.96); }
.login-avatar { width: 72px; height: 72px; border-radius: 50%; background: #fff; margin-bottom: 22px; }
.login-card h2 { margin: 6px 0 8px; font-size: 28px; }
.login-card p { margin: 0 0 20px; }
.stack { display: grid; gap: 14px; }
.compact-alert { margin: 16px 0 0; }

@media (max-width: 1180px) {
  .metric-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .dashboard-grid { grid-template-columns: 1fr; }
  .library-cards { grid-template-columns: 1fr 1fr; }
  .form-layout { grid-template-columns: 1fr 320px; }
}

@media (max-width: 900px) {
  .app-shell { display: block; }
  .sidebar { transform: translateX(-105%); transition: transform .2s ease; box-shadow: 22px 0 50px rgba(0,0,0,.38); }
  .sidebar.open { transform: translateX(0); }
  .workspace { min-width: 0; }
  .menu-toggle { display: block; }
  .topbar { padding: 0 18px; }
  .page { width: min(100% - 28px, 1460px); padding-top: 24px; }
  .form-layout { grid-template-columns: 1fr; }
  .sticky-card { position: static; }
  .login-shell { grid-template-columns: 1fr; }
  .login-brand-panel { min-height: 350px; }
}

@media (max-width: 680px) {
  .metric-grid, .library-cards, .form-grid.two, .library-grid, .service-summary, .duration-row { grid-template-columns: 1fr; }
  .dashboard-hero, .page-heading, .page-heading.with-actions { align-items: flex-start; flex-direction: column; }
  .server-pill { width: 100%; }
  .bar-chart { gap: 8px; padding-inline: 14px; }
  .card-head { flex-direction: column; }
  .topbar-copy span, .topbar .soft { display: none; }
  .login-brand-panel, .login-card { padding: 30px; }
  .login-brand-panel { min-height: 310px; }
  .login-brand-copy h1 { font-size: 46px; }
}


/* --- Public Monkey TV landing + catalog --- */
.public-shell { background: #070707; }
.public-site { min-height: 100vh; background: #070707; color: #fff; overflow-x: hidden; }
.public-nav { position: absolute; inset: 0 0 auto 0; z-index: 50; min-height: 88px; display: flex; align-items: center; gap: 30px; padding: 16px clamp(20px, 5vw, 72px); background: linear-gradient(180deg, rgba(0,0,0,.78), transparent); }
.public-nav.compact-nav { position: sticky; top: 0; background: rgba(7,7,7,.88); border-bottom: 1px solid rgba(255,255,255,.08); backdrop-filter: blur(18px); }
.public-brand { display: inline-flex; margin-right: auto; }
.public-brand img { width: 150px; height: 52px; object-fit: contain; background: #fff; border-radius: 10px; padding: 4px 8px; }
.public-nav nav { display: flex; gap: 24px; }
.public-nav nav a { color: #ddd; font-size: 13px; font-weight: 700; }
.public-nav nav a:hover { color: #fff; }
.public-login { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.18); color: #fff; }
.public-flash { position: fixed; z-index: 80; top: 16px; left: 50%; transform: translateX(-50%); width: min(560px, calc(100% - 32px)); }

.public-hero { position: relative; min-height: 82vh; display: flex; align-items: flex-end; padding: 150px clamp(22px, 6vw, 92px) 90px; background:
  radial-gradient(circle at 78% 20%, rgba(255,139,42,.28), transparent 30rem),
  linear-gradient(115deg, #17100c, #090909 70%); }
.public-hero.has-backdrop { background-image:
  linear-gradient(90deg, rgba(0,0,0,.96) 0%, rgba(0,0,0,.74) 38%, rgba(0,0,0,.18) 72%, rgba(0,0,0,.48) 100%),
  linear-gradient(0deg, #070707 0%, transparent 35%),
  var(--hero-image); background-size: cover; background-position: center 22%; }
.public-hero-shade { position: absolute; inset: auto 0 0; height: 25%; background: linear-gradient(transparent, #070707); pointer-events: none; }
.public-hero-content { position: relative; z-index: 2; width: min(700px, 100%); }
.hero-logo { width: 190px; max-height: 86px; object-fit: contain; background: rgba(255,255,255,.94); border-radius: 12px; padding: 6px 10px; margin-bottom: 30px; }
.hero-kicker { display: block; color: #ffb05c; text-transform: uppercase; letter-spacing: .18em; font-size: 12px; font-weight: 900; }
.public-hero h1 { margin: 10px 0 12px; font-size: clamp(48px, 7vw, 96px); line-height: .92; letter-spacing: -.055em; text-wrap: balance; }
.public-hero p { max-width: 630px; margin: 16px 0 24px; color: #d2d0ce; font-size: clamp(14px, 1.6vw, 18px); line-height: 1.6; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 8px; color: #dedbd8; font-size: 12px; font-weight: 800; }
.hero-meta span { padding-right: 9px; border-right: 1px solid rgba(255,255,255,.25); }
.hero-meta span:last-child { border-right: 0; }
.hero-actions-public { display: flex; flex-wrap: wrap; gap: 10px; }
.button.big { padding: 13px 18px; font-size: 13px; border-radius: 12px; }
.button.glass { background: rgba(255,255,255,.13); border-color: rgba(255,255,255,.22); backdrop-filter: blur(8px); }
.public-stats { position: absolute; z-index: 3; right: clamp(22px, 6vw, 92px); bottom: 92px; display: flex; gap: 10px; }
.public-stats div { min-width: 110px; padding: 14px 16px; border: 1px solid rgba(255,255,255,.12); border-radius: 14px; background: rgba(0,0,0,.42); backdrop-filter: blur(10px); }
.public-stats strong, .public-stats span { display: block; }
.public-stats strong { font-size: 24px; }
.public-stats span { margin-top: 2px; color: #aaa; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; }

.public-section { padding: 32px clamp(22px, 5vw, 72px); }
.public-section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.public-section-head h2 { margin: 6px 0 0; font-size: clamp(26px, 3vw, 38px); letter-spacing: -.03em; }
.public-section-head > a { color: #bbb; font-size: 12px; }
.poster-row { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(150px, 13vw); gap: 10px; overflow-x: auto; overscroll-behavior-inline: contain; scrollbar-width: thin; padding-bottom: 10px; }
.poster-card { min-width: 0; }
.poster-image { position: relative; aspect-ratio: 2/3; overflow: hidden; border-radius: 10px; background: #171717; border: 1px solid rgba(255,255,255,.06); }
.poster-image img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .25s ease, filter .25s ease; }
.poster-card:hover .poster-image img, .catalog-card:hover .poster-image img { transform: scale(1.035); filter: brightness(1.08); }
.poster-type { position: absolute; left: 8px; bottom: 8px; padding: 5px 7px; border-radius: 6px; background: rgba(0,0,0,.72); font-size: 12px; font-weight: 900; text-transform: uppercase; letter-spacing: .08em; }
.poster-card h3 { margin: 8px 0 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.poster-card p { margin: 0; color: #8d8d8d; font-size: 12px; }
.poster-placeholder { height: 100%; display: grid; place-items: center; padding: 12px; color: #754b29; text-align: center; font-weight: 900; background: linear-gradient(145deg,#1b1714,#0f0f10); }

.public-benefits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; padding: 64px clamp(22px, 5vw, 72px); }
.public-benefits article { min-height: 210px; padding: 28px; border: 1px solid rgba(255,255,255,.08); border-radius: 18px; background: linear-gradient(145deg, rgba(255,139,42,.10), rgba(255,255,255,.025)); }
.public-benefits article > span { color: #ff9f46; font-size: 12px; font-weight: 900; }
.public-benefits h3 { margin: 34px 0 8px; font-size: 25px; }
.public-benefits p { margin: 0; color: #aaa; line-height: 1.6; font-size: 13px; }
.public-cta { margin: 30px clamp(22px, 5vw, 72px) 80px; padding: clamp(28px, 5vw, 58px); display: flex; align-items: center; justify-content: space-between; gap: 30px; border: 1px solid rgba(255,159,70,.18); border-radius: 24px; background: radial-gradient(circle at 85% 30%, rgba(255,139,42,.23), transparent 22rem), #15100d; }
.public-cta h2 { margin: 7px 0; font-size: clamp(30px, 4vw, 52px); letter-spacing: -.04em; }
.public-cta p { margin: 0; color: #aaa; }
.public-footer { display: flex; align-items: center; gap: 18px; padding: 28px clamp(22px, 5vw, 72px); border-top: 1px solid rgba(255,255,255,.08); color: #999; }
.public-footer img { width: 110px; padding: 5px 8px; border-radius: 8px; background: #fff; }
.public-footer div { display: grid; gap: 2px; margin-right: auto; }
.public-footer strong { color: #ddd; font-size: 12px; }
.public-footer span, .public-footer a { font-size: 12px; }
.public-empty { margin: 20px clamp(22px, 5vw, 72px); min-height: 270px; display: grid; place-items: center; align-content: center; text-align: center; border: 1px dashed rgba(255,255,255,.12); border-radius: 18px; color: #aaa; }
.public-empty img { width: 72px; height: 72px; border-radius: 50%; background: #fff; }
.public-empty h3 { margin: 12px 0 4px; color: #fff; }

.catalog-main { width: min(1500px, calc(100% - 48px)); margin: 0 auto; padding: 56px 0 80px; }
.catalog-heading { max-width: 900px; margin-bottom: 30px; }
.catalog-heading h1 { margin: 7px 0; font-size: clamp(42px, 6vw, 76px); letter-spacing: -.05em; }
.catalog-heading > p { color: #999; }
.catalog-tools { display: flex; align-items: center; gap: 12px; margin-top: 26px; }
.catalog-tools input { flex: 1; min-width: 0; background: #151515; border-color: rgba(255,255,255,.12); }
.catalog-filters { display: flex; gap: 6px; }
.filter-button { border: 1px solid rgba(255,255,255,.12); border-radius: 999px; padding: 10px 13px; background: #151515; color: #aaa; cursor: pointer; }
.filter-button.active { color: #1d1005; background: #ff9d42; border-color: #ffb260; }
.catalog-grid { display: grid; grid-template-columns: repeat(6, minmax(0,1fr)); gap: 18px 11px; }
.catalog-card { min-width: 0; }
.catalog-card-copy h3 { margin: 8px 0 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.catalog-card-copy p, .catalog-card-copy small { margin: 0; color: #888; font-size: 12px; }

.public-back { display: inline-block; margin-top: 18px; color: #aaa; font-size: 12px; }
.team-layout { display: grid; grid-template-columns: 360px minmax(0,1fr); gap: 16px; align-items: start; }
.staff-list { display: grid; }
.staff-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 15px 20px; border-top: 1px solid var(--border); }
.staff-row small { display: block; margin-top: 3px; color: var(--muted); }
.env-admin { background: rgba(255,138,42,.035); }

@media (max-width: 1100px) {
  .public-stats { position: static; margin-top: 34px; }
  .public-hero { display: block; padding-top: 160px; min-height: 760px; }
  .catalog-grid { grid-template-columns: repeat(4, minmax(0,1fr)); }
}

@media (max-width: 850px) {
  .public-nav nav { display: none; }
  .public-brand img { width: 118px; height: 45px; }
  .public-hero { min-height: 720px; padding: 140px 24px 64px; background-position: 62% center; }
  .public-hero.has-backdrop { background-image:
    linear-gradient(90deg, rgba(0,0,0,.90), rgba(0,0,0,.42)),
    linear-gradient(0deg, #070707 0%, transparent 52%),
    var(--hero-image); }
  .public-hero h1 { font-size: clamp(46px, 14vw, 72px); }
  .public-stats { display: grid; grid-template-columns: repeat(3, 1fr); }
  .public-stats div { min-width: 0; }
  .poster-row { grid-auto-columns: minmax(135px, 28vw); }
  .public-benefits { grid-template-columns: 1fr; }
  .public-cta { align-items: flex-start; flex-direction: column; }
  .catalog-grid { grid-template-columns: repeat(4, minmax(0,1fr)); }
  .team-layout { grid-template-columns: 1fr; }
}

@media (max-width: 580px) {
  .public-nav { min-height: 72px; padding: 12px 15px; }
  .public-login { padding: 8px 10px; font-size: 12px; }
  .public-hero { min-height: 680px; padding-inline: 18px; }
  .hero-logo { width: 140px; margin-bottom: 24px; }
  .public-stats { gap: 6px; }
  .public-stats div { padding: 10px; }
  .public-stats strong { font-size: 19px; }
  .public-section { padding-inline: 18px; }
  .poster-row { grid-auto-columns: 42vw; }
  .public-benefits { padding-inline: 18px; }
  .public-cta { margin-inline: 18px; }
  .public-footer { align-items: flex-start; flex-wrap: wrap; padding-inline: 18px; }
  .catalog-main { width: min(100% - 28px, 1500px); padding-top: 30px; }
  .catalog-tools { align-items: stretch; flex-direction: column; }
  .catalog-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap: 16px 8px; }
}


/* --- v0.4 streaming polish --- */
.clean-brand { align-items: center; gap: 10px; }
.clean-brand .brand-avatar { width: 38px; height: 38px; flex: 0 0 38px; display: grid; place-items: center; border-radius: 50%; overflow: hidden; border: 1px solid rgba(255,255,255,.16); background: #fff; box-shadow: 0 8px 28px rgba(0,0,0,.28); }
.clean-brand .brand-avatar img { width: 100%; height: 100%; object-fit: cover; padding: 0; background: transparent; border-radius: 0; }
.clean-brand .brand-copy { display: grid; line-height: 1.02; }
.clean-brand .brand-copy strong { font-size: 15px; letter-spacing: -.025em; }
.clean-brand .brand-copy small { margin-top: 3px; color: #9f9b98; font-size: 12px; text-transform: uppercase; letter-spacing: .19em; }

.public-nav { padding-top: 18px; padding-bottom: 18px; }
.public-nav::after { content: ""; position: absolute; left: clamp(20px, 5vw, 72px); right: clamp(20px, 5vw, 72px); bottom: 0; height: 1px; background: linear-gradient(90deg, transparent, rgba(255,255,255,.08), transparent); opacity: .8; }
.public-nav.compact-nav::after { display: none; }

.public-hero { min-height: 88vh; padding-bottom: 78px; }
.public-hero.has-backdrop { background-position: center 18%; }
.public-hero-vignette { position: absolute; inset: 0; pointer-events: none; background:
  radial-gradient(circle at 74% 42%, transparent 0 24%, rgba(0,0,0,.12) 50%, rgba(0,0,0,.45) 100%),
  linear-gradient(90deg, rgba(0,0,0,.18), transparent 46%); }
.public-hero-content { width: min(740px, 100%); }
.hero-brandline { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 24px; color: #e5e2df; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .16em; }
.hero-brand-dot { width: 8px; height: 8px; border-radius: 50%; background: linear-gradient(135deg, #ffb15b, #ff7f1f); box-shadow: 0 0 0 5px rgba(255,139,42,.10); }
.hero-kicker { color: #ffb666; }
.public-hero h1 { max-width: 900px; text-shadow: 0 8px 35px rgba(0,0,0,.42); }
.public-hero p { color: #d6d2cf; text-shadow: 0 2px 18px rgba(0,0,0,.46); }

.public-stats { gap: 8px; }
.public-stats div { min-width: 104px; padding: 12px 14px; border-radius: 12px; border-color: rgba(255,255,255,.10); background: rgba(8,8,8,.48); box-shadow: 0 12px 35px rgba(0,0,0,.14); }
.public-stats strong { font-size: 22px; letter-spacing: -.04em; }

.genre-strip { display: flex; align-items: center; gap: 8px; overflow-x: auto; padding: 20px clamp(22px, 5vw, 72px) 4px; scrollbar-width: none; }
.genre-strip::-webkit-scrollbar { display: none; }
.genre-label { color: #706c69; font-size: 12px; text-transform: uppercase; letter-spacing: .14em; font-weight: 900; margin-right: 4px; }
.genre-chip { flex: 0 0 auto; padding: 8px 11px; border: 1px solid rgba(255,255,255,.08); border-radius: 999px; background: rgba(255,255,255,.035); color: #b7b3b0; font-size: 12px; }

.content-shelf { position: relative; padding-top: 38px; padding-bottom: 34px; }
.content-shelf + .content-shelf { padding-top: 22px; }
.public-section-head { padding-right: 4px; }
.public-section-head h2 { margin-top: 4px; }
.public-section-head p { margin: 5px 0 0; color: #777; font-size: 12px; }

.carousel-shell { position: relative; margin-inline: calc(clamp(22px, 5vw, 72px) * -0.18); padding-inline: calc(clamp(22px, 5vw, 72px) * 0.18); }
.media-carousel { display: grid; grid-auto-flow: column; grid-auto-columns: clamp(150px, 11.4vw, 198px); gap: 14px; overflow-x: auto; overflow-y: hidden; scroll-behavior: smooth; scroll-snap-type: x proximity; overscroll-behavior-inline: contain; scrollbar-width: none; padding: 8px 4px 18px; }
.media-carousel::-webkit-scrollbar { display: none; }
.media-card { min-width: 0; scroll-snap-align: start; position: relative; transition: transform .22s ease, filter .22s ease; transform-origin: center center; }
.media-card:hover { transform: translateY(-7px) scale(1.025); z-index: 4; }
.media-card-poster { position: relative; aspect-ratio: 2/3; border-radius: 14px; overflow: hidden; background: #151515; border: 1px solid rgba(255,255,255,.08); box-shadow: 0 15px 35px rgba(0,0,0,.25); }
.media-card-poster::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(255,255,255,.025); pointer-events: none; }
.media-card-poster img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s ease, filter .35s ease; }
.media-card:hover .media-card-poster img { transform: scale(1.055); filter: saturate(1.07) brightness(.92); }
.media-card-gradient { position: absolute; inset: 34% 0 0; background: linear-gradient(transparent, rgba(0,0,0,.30) 28%, rgba(0,0,0,.94) 95%); }
.media-card-top { position: absolute; top: 10px; left: 10px; }
.media-card-top span { display: inline-flex; padding: 5px 7px; border-radius: 999px; color: #f2eeeb; background: rgba(8,8,8,.66); border: 1px solid rgba(255,255,255,.12); backdrop-filter: blur(8px); font-size: 12px; font-weight: 900; letter-spacing: .10em; }
.media-card-info { position: absolute; inset: auto 12px 12px; z-index: 2; transform: translateY(3px); transition: transform .22s ease; }
.media-card:hover .media-card-info { transform: translateY(0); }
.media-card-info h3 { margin: 0 0 5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #fff; font-size: 13px; line-height: 1.2; text-shadow: 0 2px 10px #000; }
.media-card-info p { margin: 0; color: #cbc7c4; font-size: 12px; }
.media-card-info small { display: block; margin-top: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #918c88; font-size: 12px; }

.carousel-arrow { position: absolute; top: 50%; z-index: 12; width: 43px; height: 66px; transform: translateY(-50%); border: 1px solid rgba(255,255,255,.09); border-radius: 12px; background: rgba(5,5,5,.74); color: #fff; display: grid; place-items: center; font-size: 34px; line-height: 1; cursor: pointer; opacity: 0; backdrop-filter: blur(10px); transition: opacity .18s ease, background .18s ease, transform .18s ease; box-shadow: 0 10px 30px rgba(0,0,0,.25); }
.carousel-shell:hover .carousel-arrow { opacity: 1; }
.carousel-arrow:hover { background: rgba(255,139,42,.90); color: #150b03; transform: translateY(-50%) scale(1.04); }
.carousel-arrow.prev { left: -6px; }
.carousel-arrow.next { right: -6px; }

.public-cta { overflow: hidden; position: relative; }
.public-cta::after { content: ""; position: absolute; width: 290px; height: 290px; right: -90px; top: -120px; border-radius: 50%; background: rgba(255,139,42,.10); filter: blur(2px); pointer-events: none; }
.cta-actions { position: relative; z-index: 2; display: flex; gap: 8px; flex-wrap: wrap; }
.public-footer { justify-content: space-between; }
.footer-brand { display: flex; align-items: center; gap: 11px; }
.footer-brand > div { margin-right: 0; }
.brand-avatar.small { width: 34px; height: 34px; flex: 0 0 34px; display: grid; place-items: center; overflow: hidden; border-radius: 50%; background: #fff; }
.brand-avatar.small img { width: 100%; height: 100%; object-fit: cover; padding: 0; background: transparent; border-radius: 0; }

.catalog-page .public-nav { padding-top: 12px; padding-bottom: 12px; }
.catalog-page .catalog-card .poster-image { border-radius: 12px; transition: transform .22s ease, box-shadow .22s ease; }
.catalog-page .catalog-card:hover .poster-image { transform: translateY(-5px); box-shadow: 0 17px 34px rgba(0,0,0,.30); }

@media (max-width: 850px) {
  .public-brand.clean-brand .brand-copy { display: grid; }
  .public-brand.clean-brand .brand-avatar { width: 34px; height: 34px; flex-basis: 34px; }
  .public-hero { padding-top: 132px; min-height: 760px; }
  .hero-brandline { margin-bottom: 18px; }
  .media-carousel { grid-auto-columns: clamp(142px, 29vw, 180px); gap: 11px; }
  .carousel-arrow { display: none; }
  .media-card:hover { transform: none; }
}

@media (max-width: 580px) {
  .public-nav .brand-copy strong { font-size: 13px; }
  .public-nav .brand-copy small { font-size: 12px; }
  .public-hero { min-height: 700px; padding-top: 118px; padding-bottom: 50px; }
  .public-hero h1 { font-size: clamp(44px, 14vw, 68px); }
  .public-hero p { font-size: 14px; line-height: 1.52; }
  .public-stats { margin-top: 28px; }
  .public-stats div { padding: 9px; }
  .genre-strip { padding-inline: 18px; }
  .content-shelf { padding-inline: 18px; }
  .media-carousel { grid-auto-columns: 44vw; gap: 9px; padding-bottom: 10px; }
  .media-card-poster { border-radius: 12px; }
  .media-card-info { inset: auto 10px 10px; }
  .public-section-head > a { display: none; }
  .public-cta { margin-bottom: 54px; }
  .cta-actions { width: 100%; }
  .cta-actions .button { flex: 1; }
}


/* --- v0.4.1 density + readability pass --- */
.public-site .eyebrow {
  font-size: 12px;
  letter-spacing: .13em;
}

.public-section {
  padding-top: 22px;
  padding-bottom: 22px;
}

.genre-strip {
  padding-top: 12px;
  padding-bottom: 2px;
}

.genre-label {
  font-size: 12px;
  color: #928b86;
}

.genre-chip {
  padding: 9px 13px;
  font-size: 12px;
  color: #d1cbc7;
}

.content-shelf {
  padding-top: 26px;
  padding-bottom: 22px;
}

.content-shelf + .content-shelf {
  padding-top: 12px;
}

.public-section-head {
  margin-bottom: 13px;
}

.public-section-head h2 {
  font-size: clamp(28px, 2.6vw, 40px);
  line-height: 1.06;
}

.public-section-head p {
  margin-top: 7px;
  color: #a19b97;
  font-size: 14px;
  line-height: 1.45;
}

.public-section-head > a {
  font-size: 13px;
  font-weight: 700;
  color: #d8d2ce;
}

.media-carousel {
  grid-auto-columns: clamp(172px, 12.2vw, 218px);
  gap: 13px;
  padding-top: 5px;
  padding-bottom: 10px;
}

.media-card-info {
  inset: auto 13px 13px;
}

.media-card-info h3 {
  margin-bottom: 6px;
  font-size: 15px;
  line-height: 1.18;
}

.media-card-info p {
  font-size: 12px;
  line-height: 1.3;
}

.media-card-info small {
  margin-top: 5px;
  font-size: 12px;
  color: #aaa39e;
}

.media-card-top span {
  padding: 5px 8px;
  font-size: 12px;
}

.public-benefits {
  gap: 14px;
  padding-top: 34px;
  padding-bottom: 34px;
}

.public-benefits article {
  min-height: 165px;
  padding: 24px;
}

.public-benefits article > span {
  font-size: 12px;
}

.public-benefits h3 {
  margin: 20px 0 8px;
  font-size: 24px;
}

.public-benefits p {
  font-size: 14px;
  line-height: 1.55;
}

.public-cta {
  margin-top: 10px;
  margin-bottom: 46px;
  padding-top: clamp(28px, 3.8vw, 44px);
  padding-bottom: clamp(28px, 3.8vw, 44px);
}

.public-cta p {
  font-size: 14px;
  line-height: 1.5;
}

.public-footer {
  padding-top: 22px;
  padding-bottom: 22px;
}

.public-footer strong {
  font-size: 13px;
}

.public-footer span,
.public-footer a {
  font-size: 12px;
}

/* Catalog page */
.catalog-main {
  width: min(1500px, calc(100% - 64px));
  padding-top: 30px;
  padding-bottom: 60px;
}

.catalog-heading {
  max-width: 980px;
  margin-bottom: 26px;
}

.catalog-breadcrumb {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 24px;
  color: #817a75;
  font-size: 13px;
}

.catalog-breadcrumb a {
  color: #d8d3cf;
  font-weight: 700;
}

.catalog-breadcrumb a:hover {
  color: #ffad59;
}

.catalog-breadcrumb span {
  color: #4d4946;
}

.catalog-breadcrumb strong {
  color: #ffad59;
  font-weight: 800;
}

.catalog-heading > .eyebrow {
  display: block;
  margin-bottom: 8px;
}

.catalog-heading h1 {
  margin: 0 0 10px;
  font-size: clamp(44px, 5.2vw, 72px);
  line-height: .98;
}

.catalog-heading > p {
  margin: 0;
  color: #b0aaa6;
  font-size: 15px;
}

.catalog-tools {
  margin-top: 22px;
}

.catalog-tools input {
  min-height: 46px;
  font-size: 14px;
}

.filter-button {
  padding: 11px 15px;
  font-size: 12px;
}

.catalog-grid {
  gap: 24px 13px;
}

.catalog-card-copy h3 {
  margin-top: 10px;
  margin-bottom: 4px;
  font-size: 15px;
  line-height: 1.2;
}

.catalog-card-copy p,
.catalog-card-copy small {
  font-size: 12px;
  line-height: 1.35;
}

@media (max-width: 850px) {
  .public-section {
    padding-top: 18px;
    padding-bottom: 18px;
  }

  .content-shelf {
    padding-top: 22px;
    padding-bottom: 18px;
  }

  .public-section-head h2 {
    font-size: 30px;
  }

  .public-section-head p {
    font-size: 13px;
  }

  .media-carousel {
    grid-auto-columns: clamp(160px, 31vw, 192px);
  }

  .public-benefits {
    padding-top: 26px;
    padding-bottom: 26px;
  }

  .catalog-main {
    width: min(100% - 32px, 1500px);
    padding-top: 24px;
  }

  .catalog-breadcrumb {
    margin-bottom: 18px;
  }
}

@media (max-width: 580px) {
  .public-site .eyebrow {
    font-size: 12px;
  }

  .genre-strip {
    padding-top: 10px;
  }

  .genre-label,
  .genre-chip {
    font-size: 12px;
  }

  .content-shelf {
    padding-top: 18px;
    padding-bottom: 15px;
  }

  .public-section-head {
    margin-bottom: 10px;
  }

  .public-section-head h2 {
    font-size: 27px;
  }

  .public-section-head p {
    font-size: 13px;
  }

  .media-carousel {
    grid-auto-columns: 46vw;
  }

  .media-card-info h3 {
    font-size: 14px;
  }

  .media-card-info p {
    font-size: 12px;
  }

  .media-card-info small {
    font-size: 12px;
  }

  .public-benefits {
    padding-top: 22px;
    padding-bottom: 22px;
  }

  .public-benefits article {
    min-height: 145px;
  }

  .catalog-main {
    width: min(100% - 24px, 1500px);
    padding-top: 20px;
  }

  .catalog-breadcrumb {
    font-size: 12px;
    margin-bottom: 16px;
  }

  .catalog-heading h1 {
    font-size: clamp(38px, 12vw, 52px);
  }

  .catalog-heading > p {
    font-size: 13px;
  }

  .catalog-grid {
    gap-top: 18px;
  }

  .catalog-card-copy h3 {
    font-size: 14px;
  }
}


/* --- v0.4.2 hero vertical spacing --- */
.public-hero {
  min-height: 72vh;
  align-items: center;
  padding-top: 108px;
  padding-bottom: 54px;
}

.public-hero-content {
  transform: translateY(-2vh);
}

.public-stats {
  bottom: 54px;
}

@media (max-width: 1100px) {
  .public-hero {
    min-height: 690px;
    padding-top: 118px;
    padding-bottom: 48px;
  }

  .public-hero-content {
    transform: none;
  }

  .public-stats {
    margin-top: 24px;
  }
}

@media (max-width: 850px) {
  .public-hero {
    min-height: 640px;
    padding-top: 104px;
    padding-bottom: 42px;
  }
}

@media (max-width: 580px) {
  .public-hero {
    min-height: 600px;
    padding-top: 92px;
    padding-bottom: 36px;
  }
}


/* --- v0.5 access module --- */
.metric-link {
  color: inherit;
  text-decoration: none;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}
.metric-link:hover {
  transform: translateY(-2px);
  border-color: rgba(255,138,42,.28);
  background: linear-gradient(180deg, rgba(255,138,42,.06), transparent), var(--panel);
}

.access-heading {
  align-items: flex-end;
}

.access-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 12px;
  margin-bottom: 14px;
}
.access-summary article {
  min-height: 88px;
  padding: 17px 19px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(255,138,42,.06), rgba(255,255,255,.018)), var(--panel);
}
.access-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.access-summary strong {
  font-size: 28px;
  line-height: 1;
  letter-spacing: -.04em;
}

.access-toolbar {
  margin-bottom: 14px;
  padding: 13px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  overflow: visible;
}
.access-search {
  flex: 1 1 420px;
  max-width: 650px;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 8px;
  padding-left: 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(8,8,9,.45);
}
.access-search > span {
  color: var(--muted);
  font-size: 20px;
}
.access-search input {
  border: 0;
  background: transparent;
  box-shadow: none;
  padding-left: 2px;
}
.access-search input:focus {
  box-shadow: none;
}
.access-filters {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.access-filter {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 9px 12px;
  background: rgba(255,255,255,.025);
  color: var(--muted);
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
}
.access-filter.active {
  color: #1d1005;
  border-color: rgba(255,177,85,.5);
  background: linear-gradient(135deg, #ff8a2a, #ffc15b);
}

.access-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 14px;
}
.access-client-card {
  min-width: 0;
  padding: 15px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 17px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,139,42,.07), transparent 12rem),
    linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.008)),
    var(--panel);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018), 0 14px 34px rgba(0,0,0,.16);
  cursor: pointer;
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease, background .16s ease;
}
.access-client-card:hover,
.access-client-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(255,157,68,.23);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,139,42,.10), transparent 12rem),
    linear-gradient(180deg, rgba(255,255,255,.025), rgba(255,255,255,.009)),
    var(--panel);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.025), 0 18px 42px rgba(0,0,0,.22);
  outline: none;
}
.access-card-top {
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 10px;
}
.access-avatar {
  width: 40px;
  height: 40px;
}
.access-card-identity {
  min-width: 0;
}
.access-card-eyebrow {
  display: block;
  margin-bottom: 3px;
  color: #8a817b;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .12em;
  line-height: 1;
}
.access-card-identity h3 {
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #f5efea;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -.01em;
}
.access-card-top .badge {
  min-height: 26px;
  padding: 0 9px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .07em;
}
.access-card-service {
  margin-top: 12px;
  padding: 11px 12px 10px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  background: rgba(0,0,0,.14);
}
.access-card-service > div:first-child {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
}
.access-card-service span {
  color: #918883;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
}
.access-card-service strong {
  color: #f0e9e4;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .035em;
  text-transform: uppercase;
}
.access-card-service .service-meter {
  margin: 8px 0 7px;
}
.access-service-footer {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}
.access-service-footer span {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .035em;
}
.access-empty {
  min-height: 340px;
}

/* Wide native dialog */
.access-dialog {
  width: min(1040px, calc(100vw - 36px));
  max-width: 1040px;
  max-height: min(88vh, 900px);
  padding: 0;
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 22px;
  background: #151210;
  color: var(--text);
  overflow: auto;
  box-shadow: 0 40px 110px rgba(0,0,0,.62);
}
.access-dialog::backdrop {
  background: rgba(0,0,0,.76);
  backdrop-filter: blur(9px);
}
.access-modal {
  padding: 24px;
  background:
    radial-gradient(circle at 90% 0%, rgba(255,139,42,.11), transparent 22rem),
    #151210;
}
.access-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}
.access-modal-person {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
}
.modal-avatar {
  width: 54px;
  height: 54px;
  flex: 0 0 54px;
  font-size: 20px;
}
.access-modal-person h2 {
  margin: 4px 0 4px;
  font-size: clamp(23px, 3vw, 32px);
  letter-spacing: -.035em;
}
.access-modal-person p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}
.access-modal-head-actions {
  display: flex;
  align-items: center;
  gap: 9px;
}
.dialog-close {
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255,255,255,.04);
  color: #fff;
  cursor: pointer;
  font-size: 23px;
}
.access-modal-service {
  margin: 18px 0;
  padding: 16px 18px;
  border: 1px solid rgba(255,139,42,.16);
  border-radius: 15px;
  background: linear-gradient(135deg, rgba(255,139,42,.09), rgba(255,255,255,.018));
}
.access-modal-service-copy {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}
.access-modal-service-copy > span {
  color: var(--accent-2);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .11em;
  font-weight: 700;
}
.access-modal-service-copy > strong {
  font-size: 18px;
}
.access-modal-service-copy > small {
  margin-left: auto;
  color: var(--muted);
  font-size: 12px;
}
.access-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 12px;
}
.access-detail-panel {
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: rgba(255,255,255,.018);
}
.access-detail-panel h3 {
  margin: 0 0 12px;
  font-size: 13px;
}
.access-detail-panel dl {
  margin: 0;
}
.access-detail-panel dl > div {
  display: grid;
  grid-template-columns: minmax(110px,.65fr) 1.35fr;
  gap: 12px;
  padding: 9px 0;
  border-top: 1px solid var(--border);
}
.access-detail-panel dt {
  color: var(--muted);
  font-size: 12px;
}
.access-detail-panel dd {
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
  text-align: right;
  font-size: 12px;
  font-weight: 700;
}
.modal-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 11px;
}
.whatsapp-button {
  margin-top: 12px;
  color: #9ff0b7;
  border-color: rgba(85,214,139,.23);
  background: rgba(85,214,139,.07);
}
.access-notes {
  margin-top: 12px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255,255,255,.018);
}
.access-notes > span {
  color: var(--accent-2);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .1em;
}
.access-notes p {
  margin: 7px 0 0;
  color: #c8c0bb;
  font-size: 12px;
  line-height: 1.55;
}
.access-modal-actions {
  margin-top: 18px;
  padding-top: 18px;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
  border-top: 1px solid var(--border);
}
.access-modal-actions form {
  margin: 0;
}
.client-edit-grid {
  margin-top: 14px;
}

.button.danger {
  color: #ffaaa8;
  border-color: rgba(255,107,107,.23);
  background: rgba(255,107,107,.07);
}

@media (max-width: 1180px) {
  .access-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 760px) {
  .access-heading {
    align-items: flex-start;
  }
  .access-summary {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
  .access-toolbar {
    align-items: stretch;
    flex-direction: column;
  }
  .access-search {
    max-width: none;
    flex-basis: auto;
  }
  .access-grid {
    grid-template-columns: 1fr;
  }
  .access-detail-grid {
    grid-template-columns: 1fr;
  }
  .access-modal {
    padding: 17px;
  }
  .access-modal-header {
    align-items: flex-start;
  }
  .access-modal-service-copy > small {
    width: 100%;
    margin-left: 0;
  }
  .access-modal-actions {
    justify-content: stretch;
  }
  .access-modal-actions > *,
  .access-modal-actions form,
  .access-modal-actions .button {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .access-summary {
    grid-template-columns: 1fr 1fr;
  }
  .access-summary article {
    min-height: 76px;
    padding: 14px;
  }
  .access-summary strong {
    font-size: 24px;
  }
  .access-client-card {
    padding: 15px;
  }
  .access-card-top {
    grid-template-columns: auto 1fr;
  }
  .access-card-top > .badge {
    grid-column: 1 / -1;
    justify-self: start;
  }
  .access-detail-panel dl > div {
    grid-template-columns: 1fr;
    gap: 3px;
  }
  .access-detail-panel dd {
    text-align: left;
  }
}


/* --- v0.6 navigation, readability & subscriptions --- */
html {
  text-rendering: optimizeLegibility;
}
body {
  font-size: 15px;
}

.top-segmented-nav,
.public-nav-pill {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 5px;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 999px;
  background: rgba(19,16,14,.72);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.04), 0 12px 32px rgba(0,0,0,.18);
  backdrop-filter: blur(18px);
}

.top-segmented-nav a,
.public-nav-pill a {
  padding: 9px 15px;
  border-radius: 999px;
  color: #c9c3bf;
  font-size: 13px;
  font-weight: 760;
  line-height: 1;
  white-space: nowrap;
  transition: background .16s ease, color .16s ease, box-shadow .16s ease;
}

.top-segmented-nav a:hover,
.public-nav-pill a:hover {
  color: #fff;
  background: rgba(255,255,255,.07);
}

.top-segmented-nav a.active {
  color: #1c130d;
  background: linear-gradient(180deg, #f7eee7, #d9d0ca);
  box-shadow: 0 4px 14px rgba(0,0,0,.22);
}

.public-nav-pill {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(20,14,10,.76);
}
.public-nav-pill a:first-child {
  color: #1b1109;
  background: linear-gradient(180deg, #ffe0bd, #ffb45f);
}

.topbar {
  height: 74px;
  gap: 18px;
}
.topbar-copy {
  min-width: 170px;
}
.topbar-copy strong {
  font-size: 17px;
  font-weight: 780;
}
.topbar-copy span {
  color: #aaa29c;
  font-size: 12px;
}
.topbar-actions .button {
  font-size: 13px;
}

.sidebar-nav a {
  font-size: 14px;
}
.sidebar-footer {
  font-size: 12px;
}

.page-heading p,
.dashboard-hero p {
  color: #b4aca6;
  font-size: 15px;
  line-height: 1.5;
}
.eyebrow {
  font-size: 12px;
}
.metric-label {
  font-size: 13px;
}
.metric-meta {
  color: #aaa29c;
  font-size: 12px;
}
.server-facts > div {
  font-size: 13px;
}
.chip,
.badge,
.tag {
  font-size: 12px;
}
.tag {
  padding: 6px 9px;
}
.badge {
  padding: 7px 10px;
}
.button {
  font-size: 13px;
}
label {
  font-size: 13px;
}
label small,
.section-title p {
  color: #aaa29c;
  font-size: 12px;
}
input,
select,
textarea {
  font-size: 14px;
}

/* Access cards: larger, crisper text */
.access-filter {
  padding: 11px 15px;
  font-size: 13px;
}
.access-card-identity h3 {
  font-size: 17px;
}
.access-card-identity p {
  color: #aaa39e;
  font-size: 12px;
}
.access-card-service span {
  font-size: 12px;
}
.access-card-service strong {
  font-size: 14px;
}
.access-card-bottom span {
  color: #aaa39e;
  font-size: 12px;
}
.access-card-bottom strong {
  font-size: 13px;
}
.access-card-contact {
  font-size: 12px;
}
.access-detail-panel h3 {
  font-size: 15px;
}
.access-detail-panel dt {
  color: #aaa39e;
  font-size: 12px;
}
.access-detail-panel dd {
  font-size: 13px;
}
.access-modal-person p,
.access-modal-service-copy > small {
  font-size: 13px;
}
.access-notes > span {
  font-size: 12px;
}
.access-notes p {
  font-size: 13px;
}

/* Plan picker inside access creation */
.plan-picker {
  margin-bottom: 18px;
  padding: 15px;
  border: 1px solid rgba(255,139,42,.18);
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(255,139,42,.08), rgba(255,255,255,.018));
}
.plan-picker select {
  min-height: 47px;
  font-weight: 700;
}
.plan-locked {
  border-color: rgba(255,139,42,.28);
  background: rgba(255,139,42,.055);
}

/* Admin subscription module */
.plans-heading {
  align-items: flex-end;
}
.plans-admin-layout {
  display: grid;
  grid-template-columns: 390px minmax(0,1fr);
  gap: 16px;
  align-items: start;
}
.plan-builder {
  position: sticky;
  top: 94px;
  padding: 22px;
  overflow: visible;
}
.plan-builder-form {
  display: grid;
  gap: 15px;
}
.plan-libraries-field {
  margin: 0;
  padding: 13px;
  border: 1px solid var(--border);
  border-radius: 14px;
}
.plan-libraries-field legend {
  padding: 0 7px;
  color: #d8d0ca;
  font-size: 12px;
  font-weight: 800;
}
.plan-library-options {
  display: grid;
  gap: 8px;
}
.plan-library-options .library-option {
  padding: 10px;
}
.plan-sync-option {
  margin: 0;
}
.plans-admin-list {
  min-width: 0;
}
.plans-list-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 14px;
  padding: 4px 2px;
}
.plans-list-head h2 {
  margin: 5px 0 0;
  font-size: 25px;
}
.plan-admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 13px;
}
.plan-admin-card {
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,139,42,.11), transparent 14rem),
    var(--panel);
  box-shadow: 0 18px 42px rgba(0,0,0,.16);
}
.plan-admin-card.inactive {
  opacity: .66;
}
.plan-admin-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.plan-admin-top h3 {
  margin: 5px 0 0;
  font-size: 21px;
}
.plan-description {
  min-height: 38px;
  margin: 13px 0;
  color: #aaa39e;
  font-size: 13px;
  line-height: 1.5;
}
.plan-admin-price {
  display: flex;
  align-items: baseline;
  gap: 9px;
  margin: 18px 0 14px;
}
.plan-admin-price strong {
  font-size: 29px;
  letter-spacing: -.04em;
}
.plan-admin-price span {
  color: var(--muted);
  font-size: 12px;
}
.plan-admin-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 29px;
}
.plan-admin-facts {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin: 17px 0 13px;
  padding-top: 13px;
  border-top: 1px solid var(--border);
  color: #aaa39e;
  font-size: 12px;
}

/* Public subscription cards */
.public-plans-section {
  padding-top: 44px;
  padding-bottom: 44px;
}
.public-plans-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 14px;
}
.public-plan-card {
  position: relative;
  min-height: 340px;
  padding: 26px;
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 21px;
  background:
    radial-gradient(circle at 90% 0%, rgba(255,139,42,.11), transparent 15rem),
    #151210;
  box-shadow: 0 24px 55px rgba(0,0,0,.18);
}
.public-plan-card.featured-plan {
  border-color: rgba(255,155,65,.33);
  background:
    radial-gradient(circle at 80% 0%, rgba(255,139,42,.23), transparent 17rem),
    linear-gradient(145deg, rgba(255,139,42,.08), transparent 45%),
    #18120e;
}
.plan-ribbon {
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 6px 9px;
  border-radius: 999px;
  color: #1d1007;
  background: #ffb25c;
  font-size: 12px;
  font-weight: 900;
}
.public-plan-head h3 {
  margin: 7px 0 8px;
  font-size: 27px;
  letter-spacing: -.035em;
}
.public-plan-head p {
  margin: 0;
  min-height: 42px;
  color: #aaa39e;
  font-size: 14px;
  line-height: 1.5;
}
.public-plan-price {
  margin: 25px 0 18px;
  display: grid;
  gap: 3px;
}
.public-plan-price strong {
  font-size: clamp(30px, 3vw, 42px);
  line-height: 1;
  letter-spacing: -.05em;
}
.public-plan-price span {
  color: #9f9893;
  font-size: 12px;
}
.public-plan-libraries {
  display: grid;
  gap: 9px;
  margin-bottom: 22px;
  color: #d3ceca;
  font-size: 13px;
}
.public-plan-card .button {
  margin-top: auto;
}

/* Public top nav Apple-TV-like pill */
.public-nav {
  align-items: center;
}
.public-nav nav.public-nav-pill {
  display: flex;
  gap: 4px;
}

/* Fallback readability in public content */
.public-site {
  -webkit-font-smoothing: antialiased;
}
.public-section-head p,
.public-benefits p,
.public-cta p,
.catalog-card-copy p,
.catalog-card-copy small {
  color: #aaa39e;
}

/* Responsive */
@media (max-width: 1250px) {
  .top-segmented-nav {
    display: none;
  }
  .plans-admin-layout {
    grid-template-columns: 340px minmax(0,1fr);
  }
}

@media (max-width: 980px) {
  .plans-admin-layout {
    grid-template-columns: 1fr;
  }
  .plan-builder {
    position: static;
  }
  .public-plans-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 850px) {
  .public-nav-pill {
    display: none !important;
  }
}

@media (max-width: 680px) {
  .plan-admin-grid,
  .public-plans-grid {
    grid-template-columns: 1fr;
  }
  .public-plan-card {
    min-height: 300px;
  }
}


/* --- v0.7 public nav icons + editable subscriptions --- */
.public-user-button {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 50%;
  background: rgba(20,18,17,.58);
  color: #f4efeb;
  box-shadow: 0 10px 28px rgba(0,0,0,.18);
  backdrop-filter: blur(14px);
  transition: transform .16s ease, background .16s ease, border-color .16s ease;
}
.public-user-button:hover {
  transform: translateY(-1px);
  background: rgba(255,255,255,.12);
  border-color: rgba(255,255,255,.28);
}
.public-user-button svg {
  width: 21px;
  height: 21px;
}

.public-nav-pill a:first-child {
  color: #c9c3bf;
  background: transparent;
}
.public-nav-pill a.active {
  color: #1b1109;
  background: linear-gradient(180deg, #ffe0bd, #ffb45f);
  box-shadow: 0 4px 14px rgba(0,0,0,.18);
}

.catalog-page .compact-nav {
  min-height: 76px;
}
.catalog-page .catalog-nav-pill {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

/* Subscription editor */
.plan-commerce-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.plan-commerce-grid > label:first-child {
  grid-column: 1 / -1;
}
.plan-admin-facts {
  flex-wrap: wrap;
}
.plan-admin-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.plan-admin-actions form,
.plan-admin-actions .button {
  width: 100%;
}

.plan-edit-dialog {
  width: min(760px, calc(100vw - 32px));
  max-width: 760px;
  max-height: min(90vh, 900px);
  padding: 0;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 22px;
  background: #151210;
  color: var(--text);
  overflow: auto;
  box-shadow: 0 40px 110px rgba(0,0,0,.62);
}
.plan-edit-dialog::backdrop {
  background: rgba(0,0,0,.76);
  backdrop-filter: blur(9px);
}
.plan-edit-modal {
  display: grid;
  gap: 16px;
  padding: 24px;
  background:
    radial-gradient(circle at 90% 0%, rgba(255,139,42,.11), transparent 20rem),
    #151210;
}
.plan-edit-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}
.plan-edit-header h2 {
  margin: 5px 0 0;
  font-size: 27px;
  letter-spacing: -.035em;
}
.edit-library-options {
  grid-template-columns: repeat(2, minmax(0,1fr));
}
.plan-edit-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding-top: 4px;
}
.public-plan-libraries span {
  line-height: 1.4;
}

/* Catalog public navigation remains usable on smaller screens */
@media (max-width: 850px) {
  .catalog-page .compact-nav {
    min-height: auto;
    flex-wrap: wrap;
    padding: 10px 15px 12px;
    gap: 9px;
  }
  .catalog-page .catalog-nav-pill {
    position: static;
    order: 3;
    width: 100%;
    display: flex !important;
    justify-content: flex-start;
    transform: none;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .catalog-page .catalog-nav-pill::-webkit-scrollbar {
    display: none;
  }
  .catalog-page .catalog-nav-pill a {
    flex: 0 0 auto;
  }
  .catalog-page .public-user-button {
    margin-left: auto;
  }
}

@media (max-width: 680px) {
  .plan-commerce-grid,
  .edit-library-options {
    grid-template-columns: 1fr;
  }
  .plan-commerce-grid > label:first-child {
    grid-column: auto;
  }
  .plan-edit-modal {
    padding: 17px;
  }
  .plan-edit-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
}


/* --- v0.7.1 full catalog search feedback --- */
.catalog-search-wrap {
  position: relative;
  flex: 1;
  min-width: 0;
}
.catalog-search-wrap input {
  width: 100%;
  padding-right: 92px;
}
.catalog-search-state {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #a9a19b;
  font-size: 12px;
  pointer-events: none;
}
.catalog-result-note {
  min-height: 18px;
  margin: 9px 0 0;
  color: #9f9893;
  font-size: 12px;
}
.catalog-no-results {
  grid-column: 1 / -1;
  min-height: 220px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  border: 1px dashed rgba(255,255,255,.12);
  border-radius: 18px;
  color: #928b86;
  text-align: center;
}
.catalog-no-results strong {
  color: #fff;
  font-size: 18px;
}
.catalog-no-results span {
  font-size: 13px;
}


/* --- v0.8 full-width admin shell --- */
body.app-shell {
  display: block;
  min-width: 0;
}

body.app-shell .sidebar {
  display: none !important;
}

.admin-workspace,
body.app-shell .workspace {
  width: 100%;
  min-width: 0;
  min-height: 100vh;
  grid-column: auto;
}

.admin-topbar {
  height: 76px;
  display: grid;
  grid-template-columns: minmax(190px, .8fr) auto minmax(260px, .9fr);
  align-items: center;
  gap: 20px;
  padding: 0 clamp(20px, 3vw, 46px);
  background: rgba(12,10,9,.88);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(22px);
}

.admin-topbar-brand {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
}

.admin-brand-avatar {
  width: 39px;
  height: 39px;
  flex: 0 0 39px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  background: #fff;
  border: 1px solid rgba(255,255,255,.15);
  box-shadow: 0 8px 24px rgba(0,0,0,.22);
}

.admin-brand-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.admin-brand-copy {
  min-width: 0;
  display: grid;
  line-height: 1.05;
}

.admin-brand-copy strong {
  font-size: 15px;
  letter-spacing: -.02em;
}

.admin-brand-copy small {
  margin-top: 4px;
  color: #8f8883;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.admin-main-nav {
  position: static;
  justify-self: center;
  max-width: min(760px, 54vw);
  overflow-x: auto;
  scrollbar-width: none;
}

.admin-main-nav::-webkit-scrollbar {
  display: none;
}

.admin-main-nav a {
  flex: 0 0 auto;
  padding-inline: 14px;
}

.admin-topbar-actions {
  justify-self: end;
  min-width: 0;
}

.admin-user-meta {
  min-width: 0;
  display: grid;
  gap: 2px;
  text-align: right;
}

.admin-user-meta strong {
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.admin-user-meta small {
  color: var(--muted);
  font-size: 12px;
}

.admin-site-link {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 11px;
  background: rgba(255,255,255,.035);
  color: #d9d1cb;
  font-size: 17px;
  transition: .16s ease;
}

.admin-site-link:hover {
  border-color: var(--border-strong);
  background: rgba(255,255,255,.07);
  color: #fff;
}

.admin-page,
body.app-shell .page {
  width: min(1720px, calc(100% - 56px));
  margin: 0 auto;
  padding: 30px 0 54px;
}

@media (max-width: 1380px) {
  .admin-topbar {
    grid-template-columns: auto minmax(0,1fr) auto;
    gap: 14px;
    padding-inline: 22px;
  }

  .admin-main-nav {
    max-width: 100%;
    justify-self: stretch;
  }

  .admin-user-meta {
    display: none;
  }

  .admin-new-access {
    padding-inline: 11px;
  }
}

@media (max-width: 1050px) {
  .admin-topbar {
    height: auto;
    min-height: 72px;
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "brand actions"
      "nav nav";
    gap: 8px 14px;
    padding: 10px 16px 12px;
  }

  .admin-topbar-brand {
    grid-area: brand;
  }

  .admin-main-nav {
    grid-area: nav;
    width: 100%;
    max-width: none;
    justify-self: stretch;
  }

  .admin-topbar-actions {
    grid-area: actions;
  }

  .admin-main-nav {
    display: flex !important;
  }

  .admin-page,
  body.app-shell .page {
    width: min(100% - 30px, 1720px);
    padding-top: 24px;
  }
}

@media (max-width: 640px) {
  .admin-topbar {
    padding-inline: 12px;
  }

  .admin-brand-copy small {
    display: none;
  }

  .admin-main-nav {
    padding: 4px;
    gap: 3px;
  }

  .admin-main-nav a {
    padding: 9px 12px;
    font-size: 12px;
  }

  .admin-new-access {
    width: 38px;
    height: 38px;
    padding: 0;
    overflow: hidden;
    color: transparent;
    position: relative;
  }

  .admin-new-access::after {
    content: "+";
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #ffd6a3;
    font-size: 20px;
    font-weight: 900;
  }

  .admin-site-link {
    display: none;
  }

  .avatar-button {
    width: 38px;
    height: 38px;
  }

  .admin-page,
  body.app-shell .page {
    width: min(100% - 22px, 1720px);
    padding-top: 20px;
  }
}


/* --- v0.9 Plex collections showcase --- */
.content-metrics {
  grid-template-columns: repeat(5, minmax(0,1fr));
}
.collections-metric {
  background:
    radial-gradient(circle at 100% 0%, rgba(141,114,255,.14), transparent 12rem),
    linear-gradient(180deg, rgba(255,255,255,.022), transparent),
    var(--panel);
}

/* Landing collection shelf */
.collection-showcase {
  padding-top: 30px;
  padding-bottom: 34px;
}
.collection-carousel-shell {
  position: relative;
}
.collection-carousel {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: clamp(300px, 29vw, 470px);
  gap: 14px;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x proximity;
  overscroll-behavior-inline: contain;
  scrollbar-width: none;
  padding: 5px 3px 12px;
}
.collection-carousel::-webkit-scrollbar {
  display: none;
}
.collection-card {
  min-width: 0;
  scroll-snap-align: start;
  color: #fff;
}
.collection-card-media,
.collection-grid-media {
  position: relative;
  aspect-ratio: 16 / 8.7;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 18px;
  background:
    radial-gradient(circle at 85% 10%, rgba(255,139,42,.16), transparent 14rem),
    #171412;
  box-shadow: 0 20px 45px rgba(0,0,0,.25);
  transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease;
}
.collection-card:hover .collection-card-media,
.collection-grid-card:hover .collection-grid-media {
  transform: translateY(-4px);
  border-color: rgba(255,169,80,.30);
  box-shadow: 0 28px 58px rgba(0,0,0,.32);
}
.collection-card-media img,
.collection-grid-media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform .4s ease, filter .4s ease;
}
.collection-card:hover img,
.collection-grid-card:hover img {
  transform: scale(1.035);
  filter: saturate(1.06) brightness(.92);
}
.collection-card-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0,0,0,.80) 0%, rgba(0,0,0,.33) 57%, rgba(0,0,0,.10)),
    linear-gradient(0deg, rgba(0,0,0,.88), transparent 63%);
}
.collection-type {
  position: absolute;
  top: 13px;
  left: 13px;
  z-index: 2;
  padding: 6px 9px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 999px;
  background: rgba(8,8,8,.52);
  color: #f3efec;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .10em;
  text-transform: uppercase;
  backdrop-filter: blur(9px);
}
.collection-card-copy {
  position: absolute;
  z-index: 2;
  left: 17px;
  right: 17px;
  bottom: 16px;
}
.collection-card-copy h3 {
  margin: 0 0 6px;
  font-size: clamp(20px, 2vw, 28px);
  line-height: 1;
  letter-spacing: -.035em;
  text-shadow: 0 3px 18px rgba(0,0,0,.5);
}
.collection-card-copy p {
  margin: 0;
  color: #c8c2bd;
  font-size: 12px;
}
.collection-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  padding: 22px;
  color: #ffb260;
  font-size: 16px;
  font-weight: 900;
  letter-spacing: .13em;
  text-align: center;
  background:
    radial-gradient(circle at 75% 20%, rgba(255,139,42,.20), transparent 13rem),
    linear-gradient(135deg, #251a14, #0e0e0f);
}
.collection-arrow {
  position: absolute;
  top: 50%;
  z-index: 9;
  width: 44px;
  height: 68px;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 13px;
  background: rgba(4,4,4,.74);
  color: #fff;
  font-size: 34px;
  cursor: pointer;
  opacity: 0;
  backdrop-filter: blur(10px);
  transition: opacity .18s ease, background .18s ease, transform .18s ease;
}
.collection-carousel-shell:hover .collection-arrow {
  opacity: 1;
}
.collection-arrow:hover {
  color: #1b1007;
  background: #ff9f46;
  transform: translateY(-50%) scale(1.03);
}
.collection-arrow.prev { left: -7px; }
.collection-arrow.next { right: -7px; }

/* All collections */
.collections-main {
  padding-top: 34px;
}
.collections-heading {
  max-width: 1040px;
}
.collection-tools {
  max-width: 960px;
}
.collections-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 15px;
}
.collection-grid-card {
  min-width: 0;
  color: inherit;
}
.collection-grid-media {
  aspect-ratio: 16 / 9;
}
.collection-grid-media .collection-card-copy h3 {
  font-size: clamp(18px, 1.65vw, 25px);
}

/* Collection detail */
.collection-detail-page .compact-nav {
  position: absolute;
}
.collection-detail-hero {
  position: relative;
  min-height: 500px;
  display: flex;
  align-items: flex-end;
  padding: 150px clamp(24px, 6vw, 90px) 64px;
  background:
    radial-gradient(circle at 75% 20%, rgba(255,139,42,.17), transparent 28rem),
    #12100f;
}
.collection-detail-hero.has-image {
  background-image:
    linear-gradient(90deg, rgba(0,0,0,.94) 0%, rgba(0,0,0,.61) 45%, rgba(0,0,0,.20) 75%, rgba(0,0,0,.52)),
    linear-gradient(0deg, #070707 0%, transparent 45%),
    var(--collection-hero);
  background-size: cover;
  background-position: center 25%;
}
.collection-detail-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, #070707 0%, transparent 38%);
  pointer-events: none;
}
.collection-detail-copy {
  position: relative;
  z-index: 2;
  width: min(770px, 100%);
}
.collection-back {
  display: inline-block;
  margin-bottom: 25px;
  color: #c1bbb6;
  font-size: 12px;
  font-weight: 700;
}
.collection-detail-copy h1 {
  margin: 8px 0 10px;
  font-size: clamp(46px, 7vw, 90px);
  line-height: .92;
  letter-spacing: -.055em;
  text-wrap: balance;
}
.collection-detail-count {
  margin: 0 0 14px;
  color: #ffb260;
  font-size: 14px;
  font-weight: 700;
}
.collection-detail-summary {
  max-width: 660px;
  margin: 0;
  color: #cbc5c0;
  font-size: 15px;
  line-height: 1.6;
}
.collection-items-section {
  padding-top: 26px;
}
.collection-items-grid {
  grid-template-columns: repeat(7, minmax(0,1fr));
}

@media (max-width: 1300px) {
  .content-metrics {
    grid-template-columns: repeat(3, minmax(0,1fr));
  }
  .collections-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
  .collection-items-grid {
    grid-template-columns: repeat(4, minmax(0,1fr));
  }
}

@media (max-width: 850px) {
  .collection-carousel {
    grid-auto-columns: minmax(300px, 72vw);
  }
  .collection-arrow {
    display: none;
  }
  .collection-card:hover .collection-card-media,
  .collection-grid-card:hover .collection-grid-media {
    transform: none;
  }
  .collections-grid {
    grid-template-columns: 1fr 1fr;
  }
  .collection-detail-hero {
    min-height: 440px;
    padding: 125px 22px 46px;
    background-position: 62% center;
  }
  .collection-items-grid {
    grid-template-columns: repeat(4, minmax(0,1fr));
  }
}

@media (max-width: 580px) {
  .content-metrics {
    grid-template-columns: 1fr 1fr;
  }
  .collection-showcase {
    padding-top: 22px;
    padding-bottom: 24px;
  }
  .collection-carousel {
    grid-auto-columns: 84vw;
    gap: 10px;
  }
  .collection-card-media {
    border-radius: 14px;
  }
  .collection-card-copy {
    left: 13px;
    right: 13px;
    bottom: 13px;
  }
  .collection-card-copy h3 {
    font-size: 21px;
  }
  .collections-grid {
    grid-template-columns: 1fr;
    gap: 11px;
  }
  .collection-detail-hero {
    min-height: 390px;
    padding-top: 112px;
  }
  .collection-detail-copy h1 {
    font-size: clamp(40px, 13vw, 58px);
  }
  .collection-detail-summary {
    font-size: 13px;
  }
  .collection-items-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}


/* --- v0.9.1 popular collections + in-page collection modal --- */
.collection-modal-trigger {
  width: 100%;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  font: inherit;
}

.collection-modal-trigger:focus-visible {
  outline: 2px solid rgba(255,167,79,.78);
  outline-offset: 4px;
  border-radius: 18px;
}

.collection-browser-dialog {
  width: min(1180px, calc(100vw - 34px));
  max-width: 1180px;
  max-height: min(90vh, 940px);
  padding: 0;
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 24px;
  background: #0d0d0e;
  color: #fff;
  overflow: hidden;
  box-shadow: 0 45px 130px rgba(0,0,0,.72);
}

.collection-browser-dialog::backdrop {
  background: rgba(0,0,0,.78);
  backdrop-filter: blur(10px);
}

.collection-browser-modal {
  position: relative;
  max-height: min(90vh, 940px);
  overflow-y: auto;
  scrollbar-width: thin;
  background: #0d0d0e;
}

.collection-modal-close {
  position: absolute;
  top: 17px;
  right: 17px;
  z-index: 20;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 50%;
  background: rgba(5,5,5,.70);
  color: #fff;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.collection-modal-close:hover {
  background: rgba(255,255,255,.13);
}

.collection-modal-hero {
  position: relative;
  min-height: 370px;
  display: flex;
  align-items: flex-end;
  padding: 82px 42px 34px;
  background:
    radial-gradient(circle at 78% 18%, rgba(255,139,42,.19), transparent 19rem),
    linear-gradient(145deg, #231711, #0c0c0d 70%);
}

.collection-modal-hero.has-image {
  background-image:
    linear-gradient(90deg, rgba(0,0,0,.93) 0%, rgba(0,0,0,.54) 48%, rgba(0,0,0,.16) 80%),
    linear-gradient(0deg, #0d0d0e 0%, transparent 44%),
    var(--collection-modal-image);
  background-size: cover;
  background-position: center 28%;
}

.collection-modal-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, #0d0d0e 0%, transparent 38%);
  pointer-events: none;
}

.collection-modal-copy {
  position: relative;
  z-index: 2;
  width: min(720px, 100%);
}

.collection-modal-copy h2 {
  margin: 7px 0 9px;
  font-size: clamp(38px, 5vw, 68px);
  line-height: .95;
  letter-spacing: -.05em;
  text-wrap: balance;
}

.collection-modal-count {
  margin: 0 0 12px;
  color: #ffad58;
  font-size: 14px;
  font-weight: 700;
}

.collection-modal-summary {
  max-width: 670px;
  margin: 0;
  color: #cec8c3;
  font-size: 14px;
  line-height: 1.58;
}

.collection-modal-body {
  padding: 22px 28px 32px;
}

.collection-modal-body-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 15px;
}

.collection-modal-body-head h3 {
  margin: 5px 0 0;
  font-size: 26px;
  letter-spacing: -.035em;
}

.collection-modal-loading {
  color: #9d9691;
  font-size: 12px;
}

.collection-modal-items {
  display: grid;
  grid-template-columns: repeat(6, minmax(0,1fr));
  gap: 18px 11px;
}

.collection-modal-item {
  min-width: 0;
}

.collection-modal-item .poster-image {
  border-radius: 11px;
}

.collection-modal-item h4 {
  margin: 8px 0 3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  line-height: 1.2;
}

.collection-modal-item p {
  margin: 0;
  color: #918a85;
  font-size: 12px;
  line-height: 1.35;
}

.collection-modal-skeleton,
.collection-modal-empty {
  grid-column: 1 / -1;
  min-height: 170px;
  display: grid;
  place-items: center;
  border: 1px dashed rgba(255,255,255,.11);
  border-radius: 15px;
  color: #9d9691;
  font-size: 13px;
  text-align: center;
}

@media (max-width: 1000px) {
  .collection-modal-items {
    grid-template-columns: repeat(5, minmax(0,1fr));
  }
}

@media (max-width: 760px) {
  .collection-browser-dialog {
    width: min(100vw - 18px, 1180px);
    max-height: 92vh;
    border-radius: 19px;
  }

  .collection-browser-modal {
    max-height: 92vh;
  }

  .collection-modal-hero {
    min-height: 330px;
    padding: 72px 22px 27px;
  }

  .collection-modal-copy h2 {
    font-size: clamp(34px, 10vw, 54px);
  }

  .collection-modal-summary {
    font-size: 13px;
  }

  .collection-modal-body {
    padding: 18px 18px 26px;
  }

  .collection-modal-items {
    grid-template-columns: repeat(4, minmax(0,1fr));
  }
}

@media (max-width: 520px) {
  .collection-modal-close {
    top: 12px;
    right: 12px;
    width: 38px;
    height: 38px;
  }

  .collection-modal-hero {
    min-height: 290px;
    padding: 64px 16px 22px;
  }

  .collection-modal-body {
    padding-inline: 13px;
  }

  .collection-modal-body-head h3 {
    font-size: 22px;
  }

  .collection-modal-items {
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: 15px 8px;
  }
}


/* --- v0.9.3 landing collection stats + in-place modal --- */
.public-stats .public-stat-link {
  min-width: 104px;
  padding: 12px 14px;
  display: block;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 12px;
  background: rgba(8,8,8,.48);
  color: inherit;
  box-shadow: 0 12px 35px rgba(0,0,0,.14);
  backdrop-filter: blur(10px);
  transition: transform .16s ease, border-color .16s ease, background .16s ease;
}

.public-stats .public-stat-link:hover {
  transform: translateY(-2px);
  border-color: rgba(255,169,80,.28);
  background: rgba(22,15,11,.65);
}

.public-stats .public-stat-link strong,
.public-stats .public-stat-link span {
  display: block;
}

.public-stats .public-stat-link strong {
  font-size: 22px;
  letter-spacing: -.04em;
}

.public-stats .public-stat-link span {
  margin-top: 2px;
  color: #aaa;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .1em;
}

.collection-showcase .collection-modal-trigger {
  appearance: none;
  -webkit-appearance: none;
}

@media (max-width: 1100px) {
  .public-stats {
    grid-template-columns: repeat(4, minmax(0,1fr));
  }
}

@media (max-width: 700px) {
  .public-stats {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 580px) {
  .public-stats .public-stat-link {
    min-width: 0;
    padding: 9px;
  }

  .public-stats .public-stat-link strong {
    font-size: 19px;
  }
}


/* --- v0.9.7 mobile public navigation --- */
.mobile-public-nav {
  display: none;
}

@media (max-width: 850px) {
  body.public-shell {
    padding-bottom: calc(76px + env(safe-area-inset-bottom));
  }

  .mobile-public-nav {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: calc(8px + env(safe-area-inset-bottom));
    z-index: 2147482500;
    height: 64px;
    display: grid;
    grid-template-columns: repeat(5, minmax(0,1fr));
    align-items: stretch;
    gap: 3px;
    padding: 5px;
    border: 1px solid rgba(255,255,255,.11);
    border-radius: 19px;
    background: rgba(14,12,11,.92);
    box-shadow: 0 18px 55px rgba(0,0,0,.48);
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
  }

  .mobile-public-nav a {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    border-radius: 14px;
    color: #8f8985;
    text-decoration: none;
    font-size: 12px;
    font-weight: 800;
    line-height: 1;
    transition: color .15s ease, background .15s ease, transform .15s ease;
  }

  .mobile-public-nav a svg {
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
  }

  .mobile-public-nav a.active {
    color: #1b1008;
    background: linear-gradient(180deg, #ffd19e, #ff9e43);
    box-shadow: 0 5px 16px rgba(255,139,42,.18);
  }

  .mobile-public-nav a:active {
    transform: scale(.96);
  }

  /* Bottom navigation replaces the desktop/tablet pill on mobile. */
  .public-nav-pill,
  .catalog-page .catalog-nav-pill {
    display: none !important;
  }

  /* Leave room for navigation when scrolling to landing anchors. */
  #catalogo,
  #colecciones,
  #planes,
  #como-funciona,
  #acceso {
    scroll-margin-top: 84px;
  }

  /* Keep the native Chatwoot launcher and window above the bottom nav. */
  .woot-widget-bubble,
  .woot--bubble-holder {
    bottom: calc(84px + env(safe-area-inset-bottom)) !important;
  }

  .woot-widget-holder {
    bottom: calc(82px + env(safe-area-inset-bottom)) !important;
    max-height: calc(100vh - 100px - env(safe-area-inset-bottom)) !important;
  }
}

@media (max-width: 430px) {
  .mobile-public-nav {
    left: 7px;
    right: 7px;
    bottom: calc(6px + env(safe-area-inset-bottom));
    height: 61px;
    border-radius: 17px;
  }

  .mobile-public-nav a {
    font-size: 12px;
  }

  .mobile-public-nav a svg {
    width: 19px;
    height: 19px;
  }
}


/* --- v0.9.9 branded Chatwoot launcher + plan CTA --- */
.monkey-support-launcher {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 2147482500;
  width: 62px;
  height: 62px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 18px 46px rgba(0,0,0,.38);
  cursor: pointer;
  transition: transform .16s ease, box-shadow .16s ease;
}

.monkey-support-launcher:hover {
  transform: translateY(-2px) scale(1.035);
  box-shadow: 0 24px 58px rgba(0,0,0,.46);
}

.monkey-support-avatar {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
}

.monkey-support-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.monkey-support-badge {
  position: absolute;
  right: -2px;
  bottom: -1px;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border: 3px solid #090909;
  border-radius: 50%;
  background: #ff982f;
  color: #1b0f06;
}

.monkey-support-badge svg {
  width: 13px;
  height: 13px;
}

.monkey-support-launcher.is-loading .monkey-support-badge {
  animation: monkey-support-pulse .9s infinite ease-in-out;
}

.monkey-support-launcher.is-ready::after {
  content: "";
  position: absolute;
  top: 3px;
  right: 3px;
  width: 10px;
  height: 10px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #28b866;
}

.plan-chat-button {
  cursor: pointer;
}

@keyframes monkey-support-pulse {
  0%,100% { transform: scale(.84); opacity: .55; }
  50% { transform: scale(1.12); opacity: 1; }
}

@media (max-width: 850px) {
  .monkey-support-launcher {
    right: 14px;
    bottom: calc(84px + env(safe-area-inset-bottom));
    width: 56px;
    height: 56px;
  }

  .monkey-support-avatar {
    width: 48px;
    height: 48px;
  }

  .monkey-support-badge {
    width: 22px;
    height: 22px;
  }
}


/* --- v0.10.0 live Plex sessions --- */
.sessions-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 24px;
}

.sessions-hero h1 {
  margin: 5px 0 8px;
  font-size: clamp(34px, 4.3vw, 58px);
  line-height: .95;
  letter-spacing: -.05em;
}

.sessions-hero p {
  max-width: 760px;
  margin: 0;
  color: #9f9994;
  font-size: 14px;
  line-height: 1.55;
}

.sessions-live-status {
  min-width: 240px;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 13px 15px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 15px;
  background: rgba(255,255,255,.035);
}

.sessions-live-status strong,
.sessions-live-status small {
  display: block;
}

.sessions-live-status strong {
  font-size: 13px;
}

.sessions-live-status small {
  margin-top: 3px;
  color: #817b77;
  font-size: 12px;
}

.sessions-live-dot {
  width: 10px;
  height: 10px;
  flex: 0 0 10px;
  border-radius: 50%;
  background: #2ecc71;
  box-shadow: 0 0 0 5px rgba(46,204,113,.10);
  animation: sessions-live-pulse 1.6s infinite ease-in-out;
}

@keyframes sessions-live-pulse {
  0%, 100% { box-shadow: 0 0 0 4px rgba(46,204,113,.08); }
  50% { box-shadow: 0 0 0 8px rgba(46,204,113,.02); }
}

.sessions-metrics {
  display: grid;
  grid-template-columns: repeat(5, minmax(0,1fr));
  gap: 11px;
  margin-bottom: 17px;
}

.sessions-metric {
  position: relative;
  min-width: 0;
  padding: 17px 18px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 17px;
  background: linear-gradient(145deg, rgba(255,255,255,.052), rgba(255,255,255,.018));
}

.sessions-metric::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: rgba(255,255,255,.12);
}

.sessions-metric.direct-play::before { background: #2ecc71; }
.sessions-metric.direct-stream::before { background: #63a9ff; }
.sessions-metric.transcode::before { background: #ff982f; }
.sessions-metric.bandwidth::before { background: #bb83ff; }

.sessions-metric > span,
.sessions-metric > small {
  display: block;
}

.sessions-metric > span {
  color: #908985;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.sessions-metric > strong {
  display: block;
  margin: 7px 0 5px;
  font-size: clamp(22px, 2vw, 31px);
  line-height: 1;
  letter-spacing: -.04em;
}

.sessions-metric > small {
  color: #716b67;
  font-size: 12px;
}

.sessions-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 12px;
  padding: 13px 15px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 14px;
  background: rgba(255,255,255,.02);
}

.sessions-toolbar > div {
  min-width: 0;
}

.sessions-toolbar strong,
.sessions-toolbar span {
  display: block;
}

.sessions-toolbar strong {
  font-size: 13px;
}

.sessions-toolbar span {
  margin-top: 2px;
  color: #7f7874;
  font-size: 12px;
}

.sessions-hidden {
  display: none !important;
}

.sessions-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 13px;
}

.session-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 20px;
  background:
    radial-gradient(circle at 95% 0%, rgba(255,145,47,.08), transparent 18rem),
    linear-gradient(145deg, rgba(255,255,255,.045), rgba(255,255,255,.015));
  box-shadow: 0 18px 48px rgba(0,0,0,.13);
}

.session-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 15px;
  border-bottom: 1px solid rgba(255,255,255,.065);
  background: rgba(0,0,0,.13);
}

.session-user {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.session-avatar {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 50%;
  background: #1b1816;
  color: #ffac59;
  font-size: 14px;
  font-weight: 900;
}

.session-user > div {
  min-width: 0;
}

.session-user strong,
.session-user small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.session-user strong {
  font-size: 13px;
}

.session-user small {
  max-width: 310px;
  margin-top: 2px;
  color: #77716d;
  font-size: 12px;
}

.session-head-badges {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 6px;
}

.session-state,
.session-mode {
  display: inline-flex;
  align-items: center;
  min-height: 27px;
  padding: 0 9px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.session-state {
  color: #aaa39e;
  background: rgba(255,255,255,.035);
}

.session-state.playing {
  color: #a9e9c2;
  border-color: rgba(46,204,113,.18);
  background: rgba(46,204,113,.08);
}

.session-state.paused {
  color: #e9c28f;
  border-color: rgba(255,170,75,.18);
  background: rgba(255,170,75,.07);
}

.session-mode.direct_play {
  color: #9ee9bd;
  border-color: rgba(46,204,113,.22);
  background: rgba(46,204,113,.085);
}

.session-mode.direct_stream {
  color: #a8ceff;
  border-color: rgba(99,169,255,.22);
  background: rgba(99,169,255,.085);
}

.session-mode.transcode {
  color: #ffc182;
  border-color: rgba(255,152,47,.24);
  background: rgba(255,152,47,.09);
}

.session-content {
  padding: 18px;
}

.session-title-block h2 {
  margin: 6px 0 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 23px;
  letter-spacing: -.035em;
}

.session-title-block p {
  min-height: 18px;
  margin: 0;
  overflow: hidden;
  color: #938c87;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.session-progress-wrap {
  margin-top: 18px;
}

.session-progress-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
  color: #77706c;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.session-progress {
  height: 5px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255,255,255,.07);
}

.session-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #ff8f2b, #ffc06f);
}

.session-facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 8px;
  margin-top: 15px;
}

.session-facts > div {
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(255,255,255,.055);
  border-radius: 11px;
  background: rgba(0,0,0,.12);
}

.session-facts span,
.session-facts strong {
  display: block;
}

.session-facts span {
  margin-bottom: 4px;
  color: #6f6965;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .07em;
  text-transform: uppercase;
}

.session-facts strong {
  overflow: hidden;
  color: #c9c3bf;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.session-technical {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
  color: #6e6864;
  font-size: 12px;
}

.session-technical span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.session-technical strong {
  flex: 0 0 auto;
  padding: 3px 6px;
  border-radius: 6px;
  background: rgba(255,152,47,.10);
  color: #ffac59;
  font-size: 12px;
}

.sessions-empty {
  grid-column: 1 / -1;
  min-height: 310px;
  display: grid;
  place-items: center;
  align-content: center;
  padding: 35px;
  border: 1px dashed rgba(255,255,255,.10);
  border-radius: 20px;
  background: rgba(255,255,255,.018);
  text-align: center;
}

.sessions-empty-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  margin-bottom: 14px;
  border-radius: 50%;
  background: rgba(255,152,47,.09);
  color: #ff9e43;
  font-size: 18px;
}

.sessions-empty h2 {
  margin: 0 0 7px;
  font-size: 22px;
}

.sessions-empty p {
  max-width: 470px;
  margin: 0;
  color: #7f7874;
  font-size: 12px;
  line-height: 1.5;
}

@media (max-width: 1250px) {
  .sessions-metrics {
    grid-template-columns: repeat(3, minmax(0,1fr));
  }

  .session-facts {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 900px) {
  .sessions-hero {
    align-items: stretch;
    flex-direction: column;
  }

  .sessions-live-status {
    min-width: 0;
  }

  .sessions-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  .sessions-metrics {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .sessions-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .sessions-toolbar .button {
    width: 100%;
  }

  .session-card-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .session-head-badges {
    width: 100%;
  }

  .session-head-badges > span {
    flex: 1 1 0;
    justify-content: center;
  }

  .session-title-block h2 {
    font-size: 20px;
  }
}

@media (max-width: 420px) {
  .sessions-metrics {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .sessions-metric {
    padding: 14px;
  }

  .sessions-metric.bandwidth {
    grid-column: 1 / -1;
  }

  .session-content {
    padding: 14px;
  }
}


/* --- v0.10.1 compact session cards for high concurrency --- */
.sessions-list {
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 10px;
}

.session-card {
  border-radius: 16px;
}

.session-card-head {
  gap: 9px;
  padding: 10px 11px;
}

.session-avatar {
  width: 31px;
  height: 31px;
  flex-basis: 31px;
  font-size: 12px;
}

.session-user strong {
  font-size: 12px;
}

.session-user small {
  max-width: 180px;
  font-size: 12px;
}

.session-head-badges {
  gap: 4px;
}

.session-state,
.session-mode {
  min-height: 22px;
  padding: 0 7px;
  font-size: 12px;
}

.session-content {
  padding: 11px 12px 12px;
}

.session-title-block h2 {
  margin: 4px 0 2px;
  font-size: 17px;
  line-height: 1.08;
}

.session-title-block p {
  min-height: 14px;
  font-size: 12px;
}

.session-title-block .eyebrow {
  font-size: 12px;
}

.session-progress-wrap {
  margin-top: 10px;
}

.session-progress-meta {
  margin-bottom: 4px;
  font-size: 12px;
}

.session-progress {
  height: 4px;
}

.session-facts {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  margin-top: 9px;
}

.session-facts > div {
  padding: 7px 8px;
  border-radius: 8px;
}

.session-facts span {
  margin-bottom: 2px;
  font-size: 12px;
}

.session-facts strong {
  font-size: 12px;
}

.session-technical {
  gap: 7px;
  margin-top: 7px;
  font-size: 12px;
}

.session-technical strong {
  padding: 2px 5px;
  font-size: 12px;
}

@media (max-width: 1180px) {
  .sessions-list {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  }
}

@media (max-width: 700px) {
  .sessions-list {
    grid-template-columns: 1fr;
  }

  .session-user small {
    max-width: 220px;
  }
}


/* --- v0.11.0 session customer intelligence + controls --- */
.sessions-ops-summary {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
  flex-wrap: wrap;
}

.sessions-ops-summary > span {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  min-height: 28px;
  padding: 0 9px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 999px;
  background: rgba(255,255,255,.025);
  color: #827b77;
  font-size: 12px;
  white-space: nowrap;
}

.sessions-ops-summary > span strong {
  color: #d8d1cc;
  font-size: 12px;
}

.sessions-ops-summary > span.warning strong {
  color: #ffc06f;
}

.sessions-ops-summary > span.danger strong {
  color: #ff7b72;
}

.session-card.has-expired-client {
  border-color: rgba(255,93,86,.24);
}

.session-card.has-over-limit {
  box-shadow: inset 0 0 0 1px rgba(255,152,47,.18), 0 18px 48px rgba(0,0,0,.13);
}

.session-client-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 9px;
  margin-top: 8px;
  padding: 8px 9px;
  border: 1px solid rgba(46,204,113,.12);
  border-radius: 9px;
  background: rgba(46,204,113,.035);
}

.session-client-strip.expiring {
  border-color: rgba(255,175,76,.18);
  background: rgba(255,152,47,.05);
}

.session-client-strip.expired,
.session-client-strip.over-limit {
  border-color: rgba(255,93,86,.22);
  background: rgba(255,93,86,.055);
}

.session-client-strip.unmatched {
  display: block;
  border-color: rgba(255,255,255,.07);
  background: rgba(255,255,255,.018);
}

.session-client-strip.unmatched > div {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.session-client-strip.unmatched small {
  display: block;
  margin-top: 3px;
  color: #716b67;
  font-size: 12px;
  line-height: 1.35;
}

.session-client-main {
  min-width: 0;
}

.session-client-main > span,
.session-client-main > strong,
.session-client-main > small {
  display: block;
}

.session-client-main > span,
.session-client-strip.unmatched span {
  margin-bottom: 2px;
  color: #6f6965;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
}

.session-client-main > strong,
.session-client-strip.unmatched strong {
  overflow: hidden;
  color: #d8d1cc;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.session-client-main > small {
  margin-top: 2px;
  overflow: hidden;
  color: #7d7672;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.session-client-service {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 4px;
}

.session-service-chip,
.session-device-chip {
  min-height: 23px;
  display: inline-flex;
  align-items: center;
  padding: 0 7px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 999px;
  color: #99918c;
  background: rgba(0,0,0,.15);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.session-service-chip.expiring {
  color: #ffc06f;
  border-color: rgba(255,175,76,.16);
}

.session-service-chip.expired,
.session-device-chip.over-limit {
  color: #ff8b84;
  border-color: rgba(255,93,86,.20);
  background: rgba(255,93,86,.05);
}

.session-actions {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 8px;
}

.session-action {
  min-width: 0;
  min-height: 28px;
  flex: 1 1 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 8px;
  background: rgba(255,255,255,.025);
  color: #b7b0ab;
  text-decoration: none;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

.session-action:hover {
  border-color: rgba(255,169,80,.20);
  background: rgba(255,169,80,.06);
  color: #fff;
}

.session-action.whatsapp {
  color: #8be0ac;
  border-color: rgba(46,204,113,.13);
}

.session-action.danger {
  color: #ff918b;
  border-color: rgba(255,93,86,.14);
}

.session-action.danger:hover {
  background: rgba(255,93,86,.08);
  border-color: rgba(255,93,86,.24);
}

.session-stop-dialog {
  width: min(560px, calc(100vw - 28px));
  max-width: 560px;
  padding: 0;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 20px;
  background: #11100f;
  color: #fff;
  box-shadow: 0 40px 110px rgba(0,0,0,.72);
}

.session-stop-dialog::backdrop {
  background: rgba(0,0,0,.76);
  backdrop-filter: blur(8px);
}

.session-stop-modal {
  padding: 22px;
}

.session-stop-modal > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.session-stop-modal h2 {
  margin: 5px 0 4px;
  font-size: 28px;
  letter-spacing: -.04em;
}

.session-stop-modal header p {
  margin: 0;
  color: #877f7a;
  font-size: 12px;
}

.session-stop-presets {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin: 18px 0 14px;
}

.session-stop-presets button {
  min-height: 31px;
  padding: 0 10px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 999px;
  background: rgba(255,255,255,.03);
  color: #aaa29d;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.session-stop-presets button:hover {
  color: #ffc06f;
  border-color: rgba(255,175,76,.18);
}

.session-stop-field {
  display: grid;
  gap: 7px;
}

.session-stop-field > span {
  color: #918984;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.session-stop-field textarea {
  width: 100%;
  resize: vertical;
  min-height: 96px;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 12px;
  outline: none;
  background: rgba(255,255,255,.025);
  color: #fff;
  font: inherit;
  font-size: 12px;
  line-height: 1.5;
}

.session-stop-field textarea:focus {
  border-color: rgba(255,152,47,.34);
}

.session-stop-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 16px;
}

@media (max-width: 780px) {
  .sessions-toolbar {
    align-items: stretch;
  }

  .sessions-ops-summary {
    justify-content: flex-start;
  }

  .sessions-ops-summary .button {
    flex: 1 1 100%;
  }
}

@media (max-width: 480px) {
  .session-client-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .session-client-service {
    width: 100%;
  }

  .session-client-service > span {
    flex: 1 1 0;
    justify-content: center;
  }

  .session-actions {
    flex-wrap: wrap;
  }

  .session-action {
    flex: 1 1 calc(50% - 5px);
  }

  .session-action.danger {
    flex-basis: 100%;
  }

  .session-stop-actions {
    flex-direction: column-reverse;
  }

  .session-stop-actions .button {
    width: 100%;
  }
}


/* --- v0.11.1 typography readability standard --- */
/* Project rule: never intentionally render UI copy below 12px. */
small,
.eyebrow,
.metric-meta,
.metric-label,
.chip,
.badge,
.tag,
.button,
label,
.alert {
  line-height: 1.4;
}

.eyebrow,
.metric-label,
.sessions-metric > span,
.session-facts span,
.session-client-main > span,
.session-client-strip.unmatched span {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .06em;
}

.button,
input,
select,
textarea {
  font-size: 14px;
}

.sessions-live-status small,
.sessions-metric > small,
.sessions-toolbar span,
.sessions-ops-summary > span,
.sessions-ops-summary > span strong {
  font-size: 12px;
}

.session-user strong {
  font-size: 14px;
  font-weight: 700;
}

.session-user small {
  font-size: 12px;
  line-height: 1.35;
}

.session-state,
.session-mode {
  min-height: 25px;
  font-size: 12px;
  font-weight: 700;
}

.session-title-block h2 {
  font-size: 18px;
  line-height: 1.2;
}

.session-title-block p {
  min-height: 17px;
  font-size: 13px;
  line-height: 1.35;
}

.session-progress-meta {
  font-size: 12px;
}

.session-facts strong {
  font-size: 13px;
  font-weight: 700;
}

.session-technical,
.session-technical span,
.session-technical strong {
  font-size: 12px;
}

.session-client-strip.unmatched small,
.session-client-main > small {
  font-size: 12px;
  line-height: 1.35;
}

.session-client-main > strong {
  font-size: 14px;
  font-weight: 700;
}

.session-service-chip,
.session-device-chip,
.session-action {
  font-size: 12px;
  font-weight: 700;
}

.session-stop-modal header p,
.session-stop-presets button,
.session-stop-field > span {
  font-size: 12px;
}

.mobile-public-nav a {
  font-size: 12px;
  font-weight: 700;
}

.public-nav .brand-copy small,
.admin-brand-copy small,
.admin-user-meta small {
  font-size: 12px;
}

@media (max-width: 700px) {
  body {
    font-size: 15px;
  }

  .session-user strong {
    font-size: 15px;
  }

  .session-title-block h2 {
    font-size: 18px;
  }

  .session-facts strong,
  .session-action,
  .session-service-chip,
  .session-device-chip {
    font-size: 13px;
  }
}


/* --- v0.11.2 wider session cards + site-wide readable copy --- */
/* Session cards: preserve density without forcing 12px text into a narrow column. */
.sessions-list {
  grid-template-columns: repeat(auto-fill, minmax(410px, 1fr));
  gap: 12px;
}

.session-card-head {
  padding: 12px 14px;
}

.session-content {
  padding: 14px;
}

.session-user small {
  max-width: 250px;
}

.session-facts {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

.session-facts > div {
  padding: 8px 9px;
}

.session-client-strip {
  padding: 10px 11px;
}

.session-actions {
  gap: 7px;
}

.session-action {
  min-height: 32px;
  padding-inline: 10px;
}

@media (max-width: 1500px) {
  .sessions-list {
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
  }

  .session-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .sessions-list {
    grid-template-columns: 1fr;
  }

  .session-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Public site readability: 12px is reserved for micro labels only. */
.public-site {
  font-size: 14px;
}

.public-nav nav a,
.public-login,
.public-section-head > a,
.hero-meta,
.button.big {
  font-size: 14px;
}

.hero-kicker,
.poster-type,
.public-benefits article > span,
.public-stats span,
.collection-card-type,
.catalog-card-type {
  font-size: 12px;
  font-weight: 700;
}

.public-hero p,
.public-section-head p,
.public-benefits p,
.public-cta p,
.collection-card-copy p,
.catalog-card-copy p,
.catalog-card-copy small,
.collection-modal-summary,
.collection-modal-count {
  font-size: 14px;
  line-height: 1.55;
}

.poster-card h3,
.media-card-info h3,
.catalog-card-copy h3,
.collection-modal-item h4 {
  font-size: 15px;
  line-height: 1.3;
}

.poster-card p,
.media-card-info p,
.media-card-info small,
.collection-modal-item p,
.public-footer span,
.public-footer a {
  font-size: 13px;
  line-height: 1.45;
}

/* Admin readability outside sessions. */
.admin-page,
.topbar,
.access-client-card,
.access-modal,
.card,
.metric-card {
  font-size: 14px;
}

.admin-main-nav a,
.admin-user-meta strong,
.access-card-bottom strong,
.access-detail-panel dd,
.server-facts > div,
.form-section input,
.form-section select,
.form-section textarea {
  font-size: 14px;
}

.admin-user-meta small,
.access-summary span,
.access-card-service span,
.access-card-bottom span,
.access-card-contact,
.access-detail-panel dt,
.access-modal-service-copy > small,
.access-notes p,
.section-title p,
label small {
  font-size: 12px;
  line-height: 1.45;
}

.access-client-card h3,
.access-modal h2,
.card-head h2,
.section-title h2 {
  text-rendering: geometricPrecision;
}

/* Keep compact navigation readable on phones. */
@media (max-width: 700px) {
  .public-site {
    font-size: 15px;
  }

  .public-nav nav a,
  .button.big {
    font-size: 14px;
  }

  .poster-card h3,
  .media-card-info h3,
  .catalog-card-copy h3 {
    font-size: 15px;
  }

  .poster-card p,
  .media-card-info p,
  .media-card-info small,
  .catalog-card-copy p,
  .catalog-card-copy small {
    font-size: 13px;
  }
}


/* --- v0.11.3 session technical facts: two per row --- */
.session-facts {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 7px;
}

.session-facts > div {
  min-height: 54px;
  padding: 9px 10px;
}

.session-facts strong {
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  line-height: 1.3;
}

@media (max-width: 520px) {
  .session-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}


/* --- v0.12.0 public tutorial center --- */
.public-help-preview {
  padding: 58px clamp(22px, 5vw, 72px);
}

.help-preview-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.help-preview-card {
  position: relative;
  min-height: 245px;
  display: flex;
  flex-direction: column;
  padding: 22px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 20px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.10), transparent 12rem),
    linear-gradient(145deg, rgba(255,255,255,.045), rgba(255,255,255,.015));
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.help-preview-card:hover {
  transform: translateY(-3px);
  border-color: rgba(255,159,70,.22);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.16), transparent 12rem),
    linear-gradient(145deg, rgba(255,255,255,.055), rgba(255,255,255,.018));
}

.help-preview-number {
  color: #ffb25c;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
}

.help-preview-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  margin: 22px 0 18px;
  border: 1px solid rgba(255,159,70,.18);
  border-radius: 14px;
  background: rgba(255,139,42,.08);
  color: #ffc176;
  font-size: 14px;
  font-weight: 800;
}

.help-preview-card h3 {
  margin: 0 0 8px;
  font-size: 20px;
  letter-spacing: -.02em;
}

.help-preview-card p {
  margin: 0 0 20px;
  color: #aaa29d;
  font-size: 14px;
  line-height: 1.55;
}

.help-preview-card strong {
  margin-top: auto;
  color: #ffd09b;
  font-size: 13px;
}

.help-main {
  width: min(1460px, calc(100% - 48px));
  margin: 0 auto;
  padding: 66px 0 90px;
}

.help-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, .72fr);
  gap: 24px;
  align-items: end;
  padding: 28px 0 40px;
}

.help-hero h1 {
  max-width: 900px;
  margin: 9px 0 15px;
  font-size: clamp(42px, 6vw, 78px);
  line-height: .98;
  letter-spacing: -.055em;
}

.help-hero > div:first-child > p {
  max-width: 780px;
  margin: 0;
  color: #aaa29d;
  font-size: 16px;
  line-height: 1.65;
}

.help-hero-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: start;
  padding: 20px;
  border: 1px solid rgba(255,159,70,.16);
  border-radius: 20px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,139,42,.16), transparent 14rem),
    rgba(255,255,255,.025);
}

.help-status-dot {
  width: 11px;
  height: 11px;
  margin-top: 5px;
  border-radius: 50%;
  background: #2ecc71;
  box-shadow: 0 0 0 5px rgba(46,204,113,.08);
}

.help-hero-card strong {
  display: block;
  font-size: 16px;
}

.help-hero-card p {
  margin: 5px 0 0;
  color: #99918c;
  font-size: 13px;
  line-height: 1.5;
}

.help-hero-card .button {
  grid-column: 1 / -1;
  width: 100%;
  margin-top: 6px;
}

.help-jump-nav {
  position: sticky;
  top: 82px;
  z-index: 15;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 24px;
  padding: 6px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 17px;
  background: rgba(10,10,10,.86);
  backdrop-filter: blur(18px);
}

.help-jump-nav a {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 42px;
  padding: 0 10px;
  border-radius: 12px;
  color: #aaa39e;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}

.help-jump-nav a:hover {
  color: #fff;
  background: rgba(255,159,70,.08);
}

.help-jump-nav span {
  color: #ffac59;
  font-size: 12px;
}

.help-tutorial {
  scroll-margin-top: 145px;
  margin-top: 16px;
  padding: 30px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 24px;
  background:
    radial-gradient(circle at 96% 0%, rgba(255,145,47,.06), transparent 22rem),
    rgba(255,255,255,.018);
}

.help-tutorial-head {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 24px;
}

.help-step-badge {
  width: 54px;
  height: 54px;
  flex: 0 0 54px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,159,70,.18);
  border-radius: 16px;
  background: rgba(255,139,42,.075);
  color: #ffb365;
  font-size: 16px;
  font-weight: 800;
}

.help-tutorial-head h2 {
  margin: 5px 0 7px;
  font-size: clamp(28px, 3vw, 38px);
  letter-spacing: -.035em;
}

.help-tutorial-head p {
  max-width: 860px;
  margin: 0;
  color: #9d9691;
  font-size: 14px;
  line-height: 1.6;
}

.help-device-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 10px;
}

.help-device-grid article,
.help-steps-grid article {
  min-width: 0;
  padding: 18px;
  border: 1px solid rgba(255,255,255,.065);
  border-radius: 16px;
  background: rgba(0,0,0,.12);
}

.help-device-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  margin-bottom: 15px;
  border-radius: 12px;
  background: rgba(255,159,70,.08);
  color: #ffc176;
  font-size: 13px;
  font-weight: 800;
}

.help-device-grid h3,
.help-steps-grid h3 {
  margin: 0 0 6px;
  font-size: 17px;
}

.help-device-grid p,
.help-steps-grid p {
  margin: 0;
  color: #aaa29d;
  font-size: 13px;
  line-height: 1.55;
}

.help-tip {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px 18px;
  align-items: baseline;
  margin-top: 14px;
  padding: 16px 18px;
  border: 1px solid rgba(255,193,91,.14);
  border-radius: 14px;
  background: rgba(255,159,70,.045);
}

.help-tip strong {
  color: #ffc176;
  font-size: 13px;
}

.help-tip p {
  margin: 0;
  color: #aaa29d;
  font-size: 13px;
  line-height: 1.5;
}

.help-tip.compact {
  display: block;
  margin-top: 16px;
}

.help-tip.compact p {
  margin-top: 4px;
}

.help-flow {
  max-width: 920px;
  display: grid;
  gap: 7px;
  margin: 0 auto;
}

.help-flow article {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 15px;
  align-items: center;
  padding: 15px 17px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 15px;
  background: rgba(0,0,0,.13);
}

.help-flow article > span {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255,159,70,.08);
  color: #ffb365;
  font-size: 14px;
  font-weight: 800;
}

.help-flow article.success {
  border-color: rgba(46,204,113,.16);
  background: rgba(46,204,113,.035);
}

.help-flow article.success > span {
  background: rgba(46,204,113,.09);
  color: #78dba0;
}

.help-flow h3 {
  margin: 0 0 3px;
  font-size: 16px;
}

.help-flow p {
  margin: 0;
  color: #aaa29d;
  font-size: 13px;
  line-height: 1.5;
}

.help-flow-arrow {
  color: #615b57;
  font-size: 18px;
  text-align: center;
}

.help-action-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 22px;
  padding: 22px;
  border: 1px solid rgba(255,159,70,.18);
  border-radius: 18px;
  background:
    radial-gradient(circle at 90% 50%, rgba(255,139,42,.14), transparent 18rem),
    #12100f;
}

.help-action-panel h3 {
  margin: 5px 0;
  font-size: 22px;
}

.help-action-panel p {
  margin: 0;
  color: #a59d98;
  font-size: 14px;
  line-height: 1.5;
}

.help-steps-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 10px;
}

.help-steps-grid article > span {
  display: block;
  margin-bottom: 28px;
  color: #ffad5a;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .1em;
}

.help-quality-layout {
  display: grid;
  grid-template-columns: minmax(320px, .85fr) minmax(0, 1.15fr);
  gap: 18px;
  align-items: start;
}

.help-quality-card {
  padding: 20px;
  border: 1px solid rgba(46,204,113,.15);
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(46,204,113,.055), rgba(255,255,255,.018));
}

.help-quality-card h3 {
  margin: 7px 0 16px;
  font-size: 21px;
}

.help-setting-row {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 11px 0;
  border-top: 1px solid rgba(255,255,255,.065);
  font-size: 13px;
}

.help-setting-row span {
  color: #8f8883;
}

.help-setting-row strong {
  text-align: right;
  color: #a9e9c2;
}

.help-quality-copy {
  padding: 8px 4px;
}

.help-quality-copy h3 {
  margin: 0 0 8px;
  font-size: 22px;
}

.help-quality-copy > p {
  margin: 0 0 12px;
  color: #aaa29d;
  font-size: 14px;
  line-height: 1.65;
}

.help-faq {
  display: grid;
  gap: 8px;
}

.help-faq details {
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 14px;
  background: rgba(0,0,0,.12);
  overflow: hidden;
}

.help-faq summary {
  position: relative;
  padding: 16px 48px 16px 17px;
  cursor: pointer;
  list-style: none;
  font-size: 14px;
  font-weight: 700;
}

.help-faq summary::-webkit-details-marker {
  display: none;
}

.help-faq summary::after {
  content: "+";
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: #ffb365;
  font-size: 20px;
}

.help-faq details[open] summary::after {
  content: "−";
}

.help-faq details > div {
  padding: 0 17px 17px;
}

.help-faq p {
  max-width: 900px;
  margin: 0;
  color: #a59d98;
  font-size: 13px;
  line-height: 1.6;
}

.help-final-cta {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin-top: 18px;
  padding: 26px;
  border: 1px solid rgba(255,159,70,.18);
  border-radius: 22px;
  background:
    radial-gradient(circle at 88% 40%, rgba(255,139,42,.18), transparent 19rem),
    #14100e;
}

.help-final-cta .brand-avatar {
  width: 58px;
  height: 58px;
}

.help-final-cta h2 {
  margin: 5px 0 6px;
  font-size: 28px;
  letter-spacing: -.03em;
}

.help-final-cta p {
  margin: 0;
  color: #aaa29d;
  font-size: 14px;
  line-height: 1.5;
}

@media (max-width: 1100px) {
  .help-preview-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .help-hero {
    grid-template-columns: 1fr;
  }

  .help-device-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .help-steps-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 850px) {
  .help-main {
    width: min(100% - 28px, 1460px);
    padding-top: 32px;
    padding-bottom: 105px;
  }

  .help-jump-nav {
    top: 10px;
    grid-template-columns: repeat(5, minmax(130px, 1fr));
    overflow-x: auto;
    justify-content: start;
    scrollbar-width: none;
  }

  .help-jump-nav::-webkit-scrollbar {
    display: none;
  }

  .help-tutorial {
    scroll-margin-top: 90px;
  }

  .help-quality-layout {
    grid-template-columns: 1fr;
  }

  .help-action-panel,
  .help-final-cta {
    align-items: stretch;
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .help-action-panel {
    display: flex;
  }

  .help-final-cta .button,
  .help-action-panel .button {
    width: 100%;
  }
}

@media (max-width: 620px) {
  .public-help-preview {
    padding-top: 36px;
    padding-bottom: 36px;
  }

  .help-preview-grid,
  .help-device-grid,
  .help-steps-grid {
    grid-template-columns: 1fr;
  }

  .help-preview-card {
    min-height: 0;
  }

  .help-tutorial {
    padding: 20px 16px;
    border-radius: 19px;
  }

  .help-tutorial-head {
    gap: 12px;
  }

  .help-step-badge {
    width: 46px;
    height: 46px;
    flex-basis: 46px;
  }

  .help-flow article {
    grid-template-columns: 42px 1fr;
    padding: 13px;
  }

  .help-tip {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .help-setting-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .help-setting-row strong {
    text-align: left;
  }
}


/* --- v0.12.1 public controls + dedicated plans page --- */
/* Public controls use uppercase labels with a lighter weight for sharper rendering. */
.public-nav-pill a,
.mobile-public-nav a,
.public-site .button,
.public-site a.button,
.public-site button.button,
.plan-chat-button {
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: .055em;
  text-rendering: geometricPrecision;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.public-nav-pill a {
  font-size: 13px;
}

.public-site .button,
.public-site a.button,
.public-site button.button {
  font-size: 13px;
}

.mobile-public-nav a {
  font-size: 12px;
  letter-spacing: .045em;
}

/* Dedicated plans page */
.public-plans-main {
  width: min(1480px, calc(100% - 48px));
  margin: 0 auto;
  padding: 62px 0 96px;
}

.public-plans-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, .65fr);
  gap: 24px;
  align-items: end;
  padding: 30px 0 42px;
}

.public-plans-hero-copy h1 {
  max-width: 920px;
  margin: 9px 0 15px;
  font-size: clamp(44px, 6.2vw, 82px);
  line-height: .97;
  letter-spacing: -.055em;
}

.public-plans-hero-copy p {
  max-width: 780px;
  margin: 0;
  color: #aaa29d;
  font-size: 16px;
  line-height: 1.65;
}

.public-plans-hero-note {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 14px;
  padding: 20px;
  border: 1px solid rgba(255,159,70,.16);
  border-radius: 20px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,139,42,.14), transparent 14rem),
    rgba(255,255,255,.025);
}

.public-plans-note-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(46,204,113,.08);
  color: #82dfa7;
  font-size: 16px;
  font-weight: 700;
}

.public-plans-hero-note strong {
  display: block;
  font-size: 16px;
}

.public-plans-hero-note p {
  margin: 5px 0 10px;
  color: #9d9691;
  font-size: 13px;
  line-height: 1.5;
}

.public-plans-hero-note a {
  color: #ffc176;
  font-size: 13px;
  font-weight: 600;
}

.public-plans-showcase {
  padding: 14px 0 24px;
}

.public-plans-intro {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 18px;
}

.public-plans-intro h2 {
  margin: 6px 0 7px;
  font-size: clamp(28px, 3.2vw, 42px);
  letter-spacing: -.035em;
}

.public-plans-intro p {
  max-width: 720px;
  margin: 0;
  color: #99918c;
  font-size: 14px;
  line-height: 1.55;
}

.dedicated-plans-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}

.dedicated-plan-card {
  min-height: 470px;
  display: flex;
  flex-direction: column;
  padding: 26px;
}

.dedicated-plan-card .public-plan-head h3 {
  font-size: 30px;
  line-height: 1.05;
}

.dedicated-plan-card .public-plan-head p {
  min-height: 44px;
  font-size: 14px;
  line-height: 1.5;
}

.dedicated-plan-card .public-plan-price {
  margin: 24px 0 18px;
}

.dedicated-plan-card .public-plan-price strong {
  font-size: clamp(30px, 3vw, 42px);
  letter-spacing: -.035em;
}

.dedicated-plan-card .public-plan-price span {
  font-size: 13px;
}

.plan-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 8px;
  margin-bottom: 18px;
}

.plan-detail-grid > div {
  display: grid;
  gap: 5px;
  padding: 12px 13px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  background: rgba(0,0,0,.12);
}

.plan-detail-grid span {
  color: #817a76;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .055em;
}

.plan-detail-grid strong {
  font-size: 14px;
}

.dedicated-plan-card .public-plan-libraries {
  margin-bottom: 22px;
}

.dedicated-plan-card .public-plan-libraries span {
  font-size: 14px;
  line-height: 1.45;
}

.dedicated-plan-card .plan-chat-button {
  min-height: 48px;
  margin-top: auto;
}

.public-plans-benefits {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 12px;
  padding: 34px 0;
}

.public-plans-benefits article {
  min-height: 190px;
  padding: 22px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 18px;
  background: rgba(255,255,255,.018);
}

.public-plans-benefit-icon {
  color: #ffb365;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
}

.public-plans-benefits h3 {
  margin: 32px 0 7px;
  font-size: 20px;
}

.public-plans-benefits p {
  margin: 0;
  color: #9d9691;
  font-size: 14px;
  line-height: 1.55;
}

.public-plans-final {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  margin-top: 12px;
  padding: 30px;
  border: 1px solid rgba(255,159,70,.17);
  border-radius: 24px;
  background:
    radial-gradient(circle at 88% 50%, rgba(255,139,42,.18), transparent 20rem),
    #15100d;
}

.public-plans-final h2 {
  margin: 6px 0;
  font-size: clamp(28px, 3vw, 40px);
  letter-spacing: -.04em;
}

.public-plans-final p {
  margin: 0;
  color: #aaa29d;
  font-size: 14px;
}

.public-plans-final-actions {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.public-plans-empty {
  display: grid;
  justify-items: center;
  min-height: 360px;
  padding: 42px;
  text-align: center;
  border: 1px dashed rgba(255,255,255,.10);
  border-radius: 22px;
  background: rgba(255,255,255,.015);
}

.public-plans-empty .brand-avatar {
  width: 64px;
  height: 64px;
  margin-bottom: 16px;
}

.public-plans-empty h2 {
  margin: 7px 0;
  font-size: 32px;
}

.public-plans-empty p {
  max-width: 560px;
  margin: 0 0 20px;
  color: #9d9691;
  font-size: 14px;
}

@media (max-width: 1050px) {
  .public-plans-hero {
    grid-template-columns: 1fr;
  }

  .public-plans-benefits {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .public-plans-main {
    width: min(100% - 28px, 1480px);
    padding-top: 32px;
    padding-bottom: 110px;
  }

  .public-plans-hero-copy h1 {
    font-size: clamp(38px, 13vw, 58px);
  }

  .dedicated-plans-grid,
  .public-plans-benefits {
    grid-template-columns: 1fr;
  }

  .dedicated-plan-card {
    min-height: 0;
    padding: 22px;
  }

  .public-plans-final {
    align-items: stretch;
    flex-direction: column;
  }

  .public-plans-final-actions {
    justify-content: stretch;
  }

  .public-plans-final-actions .button {
    width: 100%;
  }

  .public-nav-pill a,
  .public-site .button,
  .public-site a.button,
  .public-site button.button {
    font-size: 12px;
    font-weight: 600;
  }
}


/* --- v0.12.2 plans sales page --- */
.plans-sales-main {
  width: min(1480px, calc(100% - 48px));
  margin: 0 auto;
  padding: 64px 0 96px;
}

.plans-sales-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(340px, .65fr);
  gap: 26px;
  align-items: stretch;
  padding: 36px 0 26px;
}

.plans-sales-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 420px;
  padding: clamp(30px, 5vw, 64px);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 28px;
  background:
    radial-gradient(circle at 82% 24%, rgba(255,151,55,.20), transparent 24rem),
    linear-gradient(135deg, rgba(255,139,42,.08), rgba(255,255,255,.018) 55%),
    #0d0c0b;
}

.plans-sales-copy h1 {
  max-width: 850px;
  margin: 10px 0 16px;
  font-size: clamp(48px, 6vw, 84px);
  line-height: .94;
  letter-spacing: -.055em;
}

.plans-sales-copy > p {
  max-width: 760px;
  margin: 0;
  color: #b2aaa4;
  font-size: 16px;
  line-height: 1.65;
}

.plans-sales-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.plans-catalog-card {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 420px;
  padding: 30px;
  overflow: hidden;
  border: 1px solid rgba(255,159,70,.17);
  border-radius: 28px;
  background:
    radial-gradient(circle at 70% 16%, rgba(255,170,82,.26), transparent 14rem),
    linear-gradient(155deg, rgba(255,139,42,.16), rgba(255,255,255,.025) 55%),
    #17110d;
}

.plans-catalog-kicker {
  color: #ffc06f;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.plans-catalog-total {
  display: block;
  margin: 9px 0 11px;
  font-size: clamp(34px, 4vw, 54px);
  line-height: 1;
  letter-spacing: -.04em;
}

.plans-catalog-card p {
  margin: 0 0 16px;
  color: #b0a8a2;
  font-size: 14px;
  line-height: 1.55;
}

.plans-catalog-card a {
  color: #ffd09c;
  font-size: 13px;
  font-weight: 600;
}

.plans-catalog-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 12px;
  margin-bottom: 38px;
}

.plans-catalog-stats article {
  min-height: 138px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 20px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,.026), rgba(255,255,255,.012));
}

.plans-catalog-stats strong {
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1;
  letter-spacing: -.035em;
}

.plans-catalog-stats span {
  margin-top: 6px;
  color: #fff1e6;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .055em;
}

.plans-catalog-stats small {
  margin-top: 4px;
  color: #827b77;
  font-size: 12px;
}

.plans-sales-section {
  scroll-margin-top: 100px;
  padding: 22px 0 30px;
}

.plans-sales-section-head {
  margin-bottom: 20px;
}

.plans-sales-section-head h2 {
  max-width: 900px;
  margin: 6px 0 8px;
  font-size: clamp(32px, 4vw, 50px);
  line-height: 1;
  letter-spacing: -.04em;
}

.plans-sales-section-head p {
  max-width: 840px;
  margin: 0;
  color: #99918c;
  font-size: 14px;
  line-height: 1.6;
}

.plans-sales-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px,1fr));
  gap: 14px;
}

.plan-sales-card {
  position: relative;
  min-width: 0;
  min-height: 520px;
  display: flex;
  flex-direction: column;
  padding: 26px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 22px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.08), transparent 14rem),
    linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.012)),
    #100e0d;
}

.plan-sales-card.is-featured {
  border-color: rgba(255,156,61,.34);
  background:
    radial-gradient(circle at 90% 0%, rgba(255,167,77,.22), transparent 16rem),
    linear-gradient(180deg, rgba(255,139,42,.08), rgba(255,255,255,.016)),
    #17110d;
  box-shadow: 0 22px 70px rgba(255,121,31,.09);
}

.plan-sales-ribbon {
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 7px 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ff962f, #ffc768);
  color: #1f1106;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.plan-sales-label {
  color: #ffb05c;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.plan-sales-card-head h3 {
  margin: 8px 0 8px;
  font-size: 30px;
  line-height: 1;
  letter-spacing: -.035em;
}

.plan-sales-card-head p {
  min-height: 44px;
  margin: 0;
  color: #9d9691;
  font-size: 14px;
  line-height: 1.5;
}

.plan-sales-price {
  margin: 26px 0 20px;
}

.plan-sales-price strong,
.plan-sales-price span {
  display: block;
}

.plan-sales-price strong {
  font-size: clamp(34px, 3vw, 44px);
  line-height: 1;
  letter-spacing: -.045em;
}

.plan-sales-price span {
  margin-top: 7px;
  color: #847d79;
  font-size: 13px;
}

.plan-sales-specs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 8px;
  margin-bottom: 18px;
}

.plan-sales-specs > div {
  display: grid;
  gap: 5px;
  padding: 12px 13px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  background: rgba(0,0,0,.15);
}

.plan-sales-specs span,
.plan-sales-includes-title {
  color: #817a76;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .055em;
}

.plan-sales-specs strong {
  font-size: 14px;
}

.plan-sales-includes {
  padding-top: 3px;
}

.plan-sales-library-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 9px;
}

.plan-sales-library-list span {
  padding: 7px 9px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 999px;
  background: rgba(255,255,255,.025);
  color: #d4ccc7;
  font-size: 12px;
}

.plan-sales-perks {
  display: grid;
  gap: 7px;
  margin: 18px 0 22px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,.07);
}

.plan-sales-perks span {
  color: #bcb4ae;
  font-size: 13px;
  line-height: 1.4;
}

.plan-sales-card .plan-chat-button {
  min-height: 48px;
  margin-top: auto;
}

.plans-sales-value {
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  gap: 30px;
  align-items: center;
  margin-top: 34px;
  padding: 30px;
  border: 1px solid rgba(255,159,70,.15);
  border-radius: 24px;
  background:
    radial-gradient(circle at 86% 40%, rgba(255,139,42,.16), transparent 20rem),
    #14100e;
}

.plans-sales-value h2 {
  max-width: 800px;
  margin: 6px 0 8px;
  font-size: clamp(30px, 3.6vw, 48px);
  line-height: 1;
  letter-spacing: -.04em;
}

.plans-sales-value p {
  max-width: 760px;
  margin: 0;
  color: #a69e98;
  font-size: 14px;
  line-height: 1.55;
}

.plans-sales-value-stats {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.plans-sales-value-stats span {
  min-width: 145px;
  display: grid;
  gap: 3px;
  padding: 14px 16px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 15px;
  background: rgba(0,0,0,.18);
  color: #9b938e;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .05em;
}

.plans-sales-value-stats strong {
  color: #fff7f0;
  font-size: 24px;
  letter-spacing: -.03em;
}

.plans-sales-empty {
  display: grid;
  justify-items: center;
  min-height: 360px;
  padding: 42px;
  text-align: center;
  border: 1px dashed rgba(255,255,255,.10);
  border-radius: 22px;
  background: rgba(255,255,255,.015);
}

.plans-sales-empty .brand-avatar {
  width: 64px;
  height: 64px;
  margin-bottom: 16px;
}

.plans-sales-empty h2 {
  margin: 7px 0;
  font-size: 32px;
}

.plans-sales-empty p {
  max-width: 620px;
  margin: 0 0 20px;
  color: #9d9691;
  font-size: 14px;
}

@media (max-width: 1050px) {
  .plans-sales-hero,
  .plans-sales-value {
    grid-template-columns: 1fr;
  }

  .plans-catalog-stats {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .plans-sales-value-stats {
    justify-content: flex-start;
  }
}

@media (max-width: 720px) {
  .plans-sales-main {
    width: min(100% - 28px, 1480px);
    padding-top: 32px;
    padding-bottom: 110px;
  }

  .plans-sales-copy,
  .plans-catalog-card {
    min-height: 0;
    padding: 24px;
  }

  .plans-sales-copy h1 {
    font-size: clamp(40px, 13vw, 58px);
  }

  .plans-catalog-stats,
  .plans-sales-grid {
    grid-template-columns: 1fr;
  }

  .plan-sales-card {
    min-height: 0;
    padding: 22px;
  }

  .plans-sales-specs {
    grid-template-columns: 1fr 1fr;
  }

  .plans-sales-actions .button {
    width: 100%;
  }

  .plans-sales-value {
    padding: 22px;
  }

  .plans-sales-value-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .plans-sales-value-stats span {
    min-width: 0;
  }
}


/* --- v0.12.3 help center redesign --- */
.help-v2-main {
  width: min(1360px, calc(100% - 48px));
  margin: 0 auto;
  padding: 62px 0 96px;
}

.help-v2-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(330px, .65fr);
  gap: 20px;
  align-items: stretch;
  margin-bottom: 18px;
}

.help-v2-hero-copy {
  min-height: 390px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(30px, 5vw, 62px);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 28px;
  background:
    radial-gradient(circle at 78% 20%, rgba(255,151,55,.18), transparent 24rem),
    linear-gradient(135deg, rgba(255,139,42,.07), rgba(255,255,255,.015)),
    #0d0c0b;
}

.help-v2-hero-copy h1 {
  max-width: 850px;
  margin: 10px 0 16px;
  font-size: clamp(46px, 6vw, 76px);
  line-height: .96;
  letter-spacing: -.055em;
}

.help-v2-hero-copy > p {
  max-width: 760px;
  margin: 0;
  color: #b1a9a3;
  font-size: 16px;
  line-height: 1.65;
}

.help-v2-hero-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 26px;
}

.help-credentials-preview {
  min-height: 390px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 28px;
  border: 1px solid rgba(255,159,70,.20);
  border-radius: 28px;
  background:
    radial-gradient(circle at 80% 12%, rgba(255,172,84,.22), transparent 14rem),
    #17110d;
}

.help-credentials-kicker,
.help-v2-card-label {
  color: #ffb667;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.help-credentials-preview h2 {
  margin: 8px 0 7px;
  font-size: 28px;
  letter-spacing: -.035em;
}

.help-credentials-preview > p {
  margin: 0 0 18px;
  color: #a9a19b;
  font-size: 14px;
  line-height: 1.55;
}

.help-credential-row {
  display: grid;
  gap: 5px;
  padding: 13px 14px;
  margin-top: 7px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 13px;
  background: rgba(0,0,0,.18);
}

.help-credential-row span {
  color: #817a76;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .05em;
}

.help-credential-row strong {
  font-size: 15px;
  overflow-wrap: anywhere;
}

.help-credential-note {
  display: grid;
  gap: 3px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(255,255,255,.08);
}

.help-credential-note strong {
  color: #ffd19e;
  font-size: 13px;
}

.help-credential-note span {
  color: #8f8883;
  font-size: 13px;
  line-height: 1.45;
}

.help-v2-nav {
  position: sticky;
  top: 80px;
  z-index: 14;
  display: grid;
  grid-template-columns: repeat(6, minmax(0,1fr));
  gap: 5px;
  margin-bottom: 18px;
  padding: 6px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 16px;
  background: rgba(9,9,9,.88);
  backdrop-filter: blur(18px);
}

.help-v2-nav a {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 9px;
  border-radius: 11px;
  color: #a39b96;
  font-size: 12px;
  font-weight: 600;
  text-align: center;
}

.help-v2-nav a:hover {
  color: #fff;
  background: rgba(255,159,70,.08);
}

.help-v2-nav a span {
  color: #ffb05c;
  font-size: 12px;
}

.help-v2-section {
  scroll-margin-top: 142px;
  margin-top: 14px;
  padding: 30px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 24px;
  background:
    radial-gradient(circle at 96% 0%, rgba(255,145,47,.055), transparent 22rem),
    rgba(255,255,255,.015);
}

.help-v2-section-head {
  display: grid;
  grid-template-columns: 56px minmax(0,1fr);
  gap: 18px;
  align-items: start;
  margin-bottom: 24px;
}

.help-v2-number {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,159,70,.19);
  border-radius: 16px;
  background: rgba(255,139,42,.075);
  color: #ffb365;
  font-size: 16px;
  font-weight: 700;
}

.help-v2-section-head h2 {
  margin: 5px 0 7px;
  font-size: clamp(28px, 3vw, 38px);
  letter-spacing: -.035em;
}

.help-v2-section-head p {
  max-width: 850px;
  margin: 0;
  color: #9f9792;
  font-size: 14px;
  line-height: 1.6;
}

.help-v2-credentials-grid,
.help-v2-login-paths,
.help-v2-quality {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 14px;
}

.help-v2-login-card,
.help-v2-copy-card,
.help-v2-path,
.help-v2-quality-card,
.help-v2-quality-copy {
  padding: 22px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 18px;
  background: rgba(0,0,0,.14);
}

.help-v2-login-card {
  border-color: rgba(255,159,70,.14);
  background: linear-gradient(145deg, rgba(255,139,42,.055), rgba(0,0,0,.14));
}

.help-v2-login-field {
  display: grid;
  gap: 4px;
  margin-top: 11px;
  padding: 13px 14px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 12px;
  background: rgba(0,0,0,.17);
}

.help-v2-login-field span {
  color: #817a76;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .05em;
}

.help-v2-login-field strong {
  font-size: 15px;
}

.help-v2-login-card small {
  display: block;
  margin-top: 13px;
  color: #837c77;
  font-size: 12px;
  line-height: 1.45;
}

.help-v2-copy-card h3,
.help-v2-quality-copy h3 {
  margin: 0 0 9px;
  font-size: 22px;
  letter-spacing: -.025em;
}

.help-v2-copy-card > p,
.help-v2-quality-copy > p {
  margin: 0 0 12px;
  color: #aaa29d;
  font-size: 14px;
  line-height: 1.62;
}

.help-v2-warning {
  display: grid;
  gap: 4px;
  margin-top: 16px;
  padding: 14px;
  border: 1px solid rgba(255,175,76,.15);
  border-radius: 12px;
  background: rgba(255,139,42,.04);
}

.help-v2-warning strong {
  color: #ffc174;
  font-size: 13px;
}

.help-v2-warning span {
  color: #98908b;
  font-size: 13px;
  line-height: 1.45;
}

.help-v2-device-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 10px;
}

.help-v2-device-grid article {
  min-width: 0;
  display: grid;
  grid-template-columns: 44px minmax(0,1fr);
  gap: 13px;
  padding: 17px;
  border: 1px solid rgba(255,255,255,.065);
  border-radius: 16px;
  background: rgba(0,0,0,.12);
}

.help-v2-device-grid article > span {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255,159,70,.08);
  color: #ffc176;
  font-size: 12px;
  font-weight: 700;
}

.help-v2-device-grid h3 {
  margin: 1px 0 5px;
  font-size: 16px;
}

.help-v2-device-grid p {
  margin: 0;
  color: #99918c;
  font-size: 13px;
  line-height: 1.5;
}

.help-v2-path {
  min-height: 100%;
}

.help-v2-path.is-code {
  border-color: rgba(255,159,70,.15);
  background: linear-gradient(145deg, rgba(255,139,42,.045), rgba(0,0,0,.14));
}

.help-v2-path-head {
  display: grid;
  grid-template-columns: 42px minmax(0,1fr);
  gap: 12px;
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255,255,255,.07);
}

.help-v2-path-head > span {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255,159,70,.08);
  color: #ffb365;
  font-size: 15px;
  font-weight: 700;
}

.help-v2-path-head strong,
.help-v2-path-head small {
  display: block;
}

.help-v2-path-head strong {
  font-size: 16px;
}

.help-v2-path-head small {
  margin-top: 3px;
  color: #817a76;
  font-size: 12px;
}

.help-v2-path ol {
  list-style: none;
  display: grid;
  gap: 9px;
  margin: 16px 0 0;
  padding: 0;
}

.help-v2-path li {
  display: grid;
  grid-template-columns: 30px minmax(0,1fr);
  gap: 10px;
  align-items: start;
}

.help-v2-path li > span {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: rgba(255,255,255,.035);
  color: #ffb365;
  font-size: 12px;
  font-weight: 700;
}

.help-v2-path li p {
  margin: 4px 0 0;
  color: #aaa29d;
  font-size: 13px;
  line-height: 1.5;
}

.help-v2-support-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin-top: 16px;
  padding: 20px;
  border: 1px solid rgba(255,159,70,.18);
  border-radius: 17px;
  background:
    radial-gradient(circle at 90% 50%, rgba(255,139,42,.14), transparent 18rem),
    #12100f;
}

.help-v2-support-strip h3 {
  margin: 5px 0 5px;
  font-size: 20px;
}

.help-v2-support-strip p {
  margin: 0;
  color: #9d9691;
  font-size: 13px;
}

.help-v2-four-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 10px;
}

.help-v2-four-steps article {
  padding: 18px;
  border: 1px solid rgba(255,255,255,.065);
  border-radius: 16px;
  background: rgba(0,0,0,.12);
}

.help-v2-four-steps article > span {
  display: block;
  margin-bottom: 28px;
  color: #ffad5a;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
}

.help-v2-four-steps h3 {
  margin: 0 0 6px;
  font-size: 17px;
}

.help-v2-four-steps p {
  margin: 0;
  color: #99918c;
  font-size: 13px;
  line-height: 1.5;
}

.help-v2-quality-card {
  border-color: rgba(46,204,113,.14);
  background: linear-gradient(145deg, rgba(46,204,113,.045), rgba(0,0,0,.14));
}

.help-v2-quality-card h3 {
  margin: 7px 0 15px;
  font-size: 22px;
}

.help-v2-quality-card > div {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 11px 0;
  border-top: 1px solid rgba(255,255,255,.065);
  font-size: 13px;
}

.help-v2-quality-card > div span {
  color: #817a76;
}

.help-v2-quality-card > div strong {
  color: #9ce0b7;
  text-align: right;
}

.help-v2-faq {
  display: grid;
  gap: 8px;
}

.help-v2-faq details {
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 14px;
  background: rgba(0,0,0,.12);
  overflow: hidden;
}

.help-v2-faq summary {
  position: relative;
  padding: 16px 48px 16px 17px;
  cursor: pointer;
  list-style: none;
  font-size: 14px;
  font-weight: 600;
}

.help-v2-faq summary::-webkit-details-marker {
  display: none;
}

.help-v2-faq summary::after {
  content: "+";
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: #ffb365;
  font-size: 20px;
}

.help-v2-faq details[open] summary::after {
  content: "−";
}

.help-v2-faq details p {
  max-width: 900px;
  margin: 0;
  padding: 0 17px 17px;
  color: #9f9792;
  font-size: 13px;
  line-height: 1.6;
}

.help-v2-final {
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  gap: 18px;
  align-items: center;
  margin-top: 16px;
  padding: 24px;
  border: 1px solid rgba(255,159,70,.18);
  border-radius: 20px;
  background:
    radial-gradient(circle at 88% 40%, rgba(255,139,42,.18), transparent 19rem),
    #14100e;
}

.help-v2-final .brand-avatar {
  width: 58px;
  height: 58px;
}

.help-v2-final h2 {
  margin: 5px 0;
  font-size: 25px;
}

.help-v2-final p {
  margin: 0;
  color: #a29a95;
  font-size: 13px;
}

@media (max-width: 1050px) {
  .help-v2-hero,
  .help-v2-credentials-grid,
  .help-v2-login-paths,
  .help-v2-quality {
    grid-template-columns: 1fr;
  }

  .help-v2-device-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .help-v2-four-steps {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .help-v2-nav {
    grid-template-columns: repeat(6, minmax(130px,1fr));
    overflow-x: auto;
    scrollbar-width: none;
  }

  .help-v2-nav::-webkit-scrollbar {
    display: none;
  }
}

@media (max-width: 700px) {
  .help-v2-main {
    width: min(100% - 28px, 1360px);
    padding-top: 30px;
    padding-bottom: 110px;
  }

  .help-v2-hero-copy,
  .help-credentials-preview {
    min-height: 0;
    padding: 23px;
  }

  .help-v2-hero-copy h1 {
    font-size: clamp(38px, 13vw, 56px);
  }

  .help-v2-section {
    scroll-margin-top: 90px;
    padding: 20px 16px;
  }

  .help-v2-section-head {
    grid-template-columns: 46px minmax(0,1fr);
    gap: 12px;
  }

  .help-v2-number {
    width: 46px;
    height: 46px;
  }

  .help-v2-device-grid,
  .help-v2-four-steps {
    grid-template-columns: 1fr;
  }

  .help-v2-support-strip {
    align-items: stretch;
    flex-direction: column;
  }

  .help-v2-support-strip .button,
  .help-v2-hero-actions .button {
    width: 100%;
  }

  .help-v2-final {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .help-v2-final .button {
    width: 100%;
  }

  .help-v2-quality-card > div {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .help-v2-quality-card > div strong {
    text-align: left;
  }
}


/* --- v0.12.5 subscription management confirmation --- */
.plan-admin-actions {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.plans-admin-list dialog:not(.plan-edit-dialog) {
  width: min(520px, calc(100vw - 32px));
  max-width: 520px;
  padding: 0;
  border: 1px solid rgba(255,107,107,.22);
  border-radius: 22px;
  background: #151210;
  color: var(--text);
  box-shadow: 0 40px 110px rgba(0,0,0,.65);
}

.plans-admin-list dialog:not(.plan-edit-dialog)::backdrop {
  background: rgba(0,0,0,.78);
  backdrop-filter: blur(9px);
}

.plans-admin-list dialog:not(.plan-edit-dialog) form {
  display: grid;
  justify-items: center;
  padding: 28px;
  text-align: center;
  background:
    radial-gradient(circle at 50% 0%, rgba(255,107,107,.09), transparent 17rem),
    #151210;
}

.plans-admin-list dialog:not(.plan-edit-dialog) h2 {
  margin: 6px 0 9px;
  font-size: 28px;
  letter-spacing: -.035em;
}

.plans-admin-list dialog:not(.plan-edit-dialog) p {
  max-width: 440px;
  margin: 0;
  color: #aaa29d;
  font-size: 14px;
  line-height: 1.6;
}

.plans-admin-list dialog:not(.plan-edit-dialog) [class$="-summary"] {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 6px;
  margin: 20px 0;
}

.plans-admin-list dialog:not(.plan-edit-dialog) [class$="-summary"] span {
  padding: 10px 8px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 11px;
  background: rgba(0,0,0,.14);
  color: #c9c1bc;
  font-size: 12px;
}

.plans-admin-list dialog:not(.plan-edit-dialog) [class$="-actions"] {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

@media (max-width: 620px) {
  .plan-admin-actions {
    grid-template-columns: 1fr;
  }

  .plans-admin-list dialog:not(.plan-edit-dialog) [class$="-summary"] {
    grid-template-columns: 1fr;
  }
}


/* --- v0.12.7 cleaner subscription administration --- */
.plans-heading-clean {
  align-items: center;
  margin-bottom: 18px;
}

.plans-heading-clean p {
  max-width: 720px;
}

.plan-create-fab {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,159,70,.22);
  border-radius: 15px;
  background: linear-gradient(135deg, rgba(255,139,42,.18), rgba(255,193,91,.08));
  color: #ffc176;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(255,139,42,.08);
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.plan-create-fab:hover {
  transform: translateY(-2px);
  border-color: rgba(255,159,70,.38);
  background: linear-gradient(135deg, rgba(255,139,42,.26), rgba(255,193,91,.12));
}

.plan-create-fab svg {
  width: 22px;
  height: 22px;
}

.plans-admin-list-clean {
  width: 100%;
}

.plan-admin-grid-clean {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 14px;
}

.plan-admin-card-clean {
  min-height: 330px;
  display: flex;
  flex-direction: column;
  padding: 20px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.08), transparent 13rem),
    linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.012));
}

.plan-admin-card-clean.inactive {
  opacity: .68;
}

.plan-admin-card-clean .plan-admin-top {
  align-items: flex-start;
}

.plan-admin-card-clean .plan-admin-top h3 {
  margin-top: 5px;
  font-size: 23px;
  line-height: 1.05;
  letter-spacing: -.03em;
}

.plan-admin-card-clean .plan-description {
  min-height: 42px;
  margin: 10px 0 0;
  color: #9c948f;
  font-size: 13px;
  line-height: 1.5;
}

.plan-admin-price-clean {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 22px 0 16px;
}

.plan-admin-price-clean strong {
  font-size: 30px;
  line-height: 1;
  letter-spacing: -.04em;
}

.plan-admin-price-clean span {
  color: #857e79;
  font-size: 12px;
}

.plan-admin-quickfacts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 6px;
}

.plan-admin-quickfacts > div {
  min-width: 0;
  display: grid;
  gap: 4px;
  padding: 9px 10px;
  border: 1px solid rgba(255,255,255,.065);
  border-radius: 10px;
  background: rgba(0,0,0,.13);
}

.plan-admin-quickfacts span {
  color: #756f6b;
  font-size: 12px;
}

.plan-admin-quickfacts strong {
  overflow: hidden;
  color: #d8d1cc;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.plan-admin-tags-clean {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 14px;
}

.plan-admin-tags-clean .tag {
  font-size: 12px;
}

.plan-card-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
  margin-top: auto;
  padding-top: 17px;
  border-top: 1px solid rgba(255,255,255,.065);
}

.plan-card-toolbar form {
  margin: 0;
}

.plan-icon-button {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  background: rgba(255,255,255,.025);
  color: #a69e98;
  cursor: pointer;
  transition: border-color .18s ease, color .18s ease, background .18s ease, transform .18s ease;
}

.plan-icon-button:hover {
  transform: translateY(-1px);
  border-color: rgba(255,159,70,.20);
  background: rgba(255,159,70,.055);
  color: #fff;
}

.plan-icon-button svg {
  width: 17px;
  height: 17px;
}

.plan-icon-button.is-active {
  color: #88dca8;
  border-color: rgba(46,204,113,.14);
}

.plan-icon-button.is-muted {
  color: #ffb365;
  border-color: rgba(255,159,70,.15);
}

.plan-icon-button.danger {
  color: #ff918b;
  border-color: rgba(255,93,86,.15);
}

.plan-icon-button.danger:hover {
  color: #ffb0ab;
  border-color: rgba(255,93,86,.26);
  background: rgba(255,93,86,.07);
}

.plan-create-dialog {
  width: min(820px, calc(100vw - 32px));
  max-width: 820px;
}

.plan-create-modal {
  max-height: min(88vh, 920px);
  overflow: auto;
}

.plans-empty-clean {
  min-height: 260px;
}

@media (max-width: 900px) {
  .plan-admin-grid-clean {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 640px) {
  .plans-heading-clean {
    align-items: flex-start;
  }

  .plan-create-fab {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
  }

  .plan-admin-grid-clean {
    grid-template-columns: 1fr;
  }

  .plan-admin-quickfacts {
    grid-template-columns: 1fr 1fr;
  }

  .plan-card-toolbar {
    justify-content: flex-start;
  }
}


/* --- v0.12.8 compact admin shell actions --- */
.admin-action-icon,
.plan-create-fab {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255,159,70,.22);
  border-radius: 15px;
  background: linear-gradient(135deg, rgba(255,139,42,.18), rgba(255,193,91,.08));
  color: #ffc176;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(255,139,42,.08);
  transition: transform .18s ease, border-color .18s ease, background .18s ease, color .18s ease;
}

.admin-action-icon:hover,
.plan-create-fab:hover {
  transform: translateY(-2px);
  border-color: rgba(255,159,70,.38);
  background: linear-gradient(135deg, rgba(255,139,42,.26), rgba(255,193,91,.12));
  color: #ffe0b7;
}

.admin-action-icon:disabled {
  opacity: .45;
  cursor: wait;
  transform: none;
}

.admin-action-icon svg,
.plan-create-fab svg {
  width: 21px;
  height: 21px;
}

.admin-action-icon.compact {
  width: 38px;
  height: 38px;
  flex-basis: 38px;
  border-radius: 11px;
}

.admin-action-icon.compact svg {
  width: 17px;
  height: 17px;
}

.admin-inline-actions {
  display: flex;
  align-items: center;
  gap: 7px;
  flex: 0 0 auto;
}

.admin-inline-actions form {
  margin: 0;
}

/* Dashboard now starts directly with useful data. */
.server-card-copy {
  min-width: 0;
  flex: 1;
}

.server-card-top .admin-action-icon {
  margin-left: auto;
}

/* Accesses: filters and page actions live in the existing toolbar. */
.access-toolbar-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  flex-wrap: wrap;
}

.access-empty .admin-action-icon {
  margin-top: 4px;
}

/* Sessions: server identity and refresh live in the operational toolbar. */
.sessions-toolbar-live {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 11px;
}

.sessions-toolbar-live > div {
  min-width: 0;
}

.sessions-toolbar-live strong,
.sessions-toolbar-live span,
.sessions-toolbar-live small {
  display: block;
}

.sessions-toolbar-live small {
  margin-top: 2px;
  color: #69635f;
  font-size: 12px;
}

/* Content: actions become a sixth operational metric instead of a page hero. */
.content-metrics {
  grid-template-columns: repeat(6, minmax(0,1fr));
}

.content-actions-metric {
  justify-content: space-between;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.09), transparent 10rem),
    linear-gradient(180deg, rgba(255,255,255,.022), transparent),
    var(--panel);
}

.content-metric-actions {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 16px;
}

.content-metric-actions form {
  margin: 0;
}

.library-card-foot form {
  margin: 0;
}

/* Subscriptions: only the cards and the create control remain visible. */
.plans-compact-actions {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 12px;
}

.plans-admin-list-clean {
  padding-top: 0;
}

.plan-card-toolbar .plan-icon-button {
  width: 38px;
  height: 38px;
  border-color: rgba(255,159,70,.15);
  border-radius: 11px;
  background: linear-gradient(135deg, rgba(255,139,42,.10), rgba(255,193,91,.035));
  color: #d6b58e;
  box-shadow: 0 8px 18px rgba(0,0,0,.12);
}

.plan-card-toolbar .plan-icon-button:hover {
  border-color: rgba(255,159,70,.30);
  background: linear-gradient(135deg, rgba(255,139,42,.18), rgba(255,193,91,.07));
  color: #ffd09b;
}

.plan-card-toolbar .plan-icon-button.is-active {
  color: #95e0b2;
  border-color: rgba(46,204,113,.18);
  background: rgba(46,204,113,.055);
}

.plan-card-toolbar .plan-icon-button.danger {
  color: #ff918b;
  border-color: rgba(255,93,86,.18);
  background: rgba(255,93,86,.045);
}

/* Team: user creation follows the same modal + icon pattern as plans. */
.team-card-clean {
  overflow: visible;
}

.team-card-clean .card-head {
  align-items: center;
}

.team-create-dialog {
  width: min(620px, calc(100vw - 32px));
  max-width: 620px;
}

@media (max-width: 1200px) {
  .content-metrics {
    grid-template-columns: repeat(3, minmax(0,1fr));
  }

  .access-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .access-search {
    max-width: none;
    flex-basis: auto;
  }

  .access-toolbar-right {
    justify-content: space-between;
  }
}

@media (max-width: 720px) {
  .content-metrics {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .access-toolbar-right {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-inline-actions {
    width: 100%;
    justify-content: flex-end;
  }

  .sessions-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .sessions-ops-summary {
    justify-content: flex-start;
  }

  .plans-compact-actions {
    margin-bottom: 10px;
  }
}

@media (max-width: 520px) {
  .admin-action-icon {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
  }

  .admin-action-icon.compact {
    width: 38px;
    height: 38px;
    flex-basis: 38px;
  }

  .content-metrics {
    grid-template-columns: 1fr 1fr;
  }

  .content-metric-actions {
    flex-wrap: wrap;
  }
}


/* --- v0.12.9 sharper uppercase admin navigation --- */
.admin-main-nav a,
.access-filter,
.admin-new-access {
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: .055em;
  text-rendering: geometricPrecision;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.admin-main-nav a {
  font-size: 13px;
  line-height: 1;
}

.access-filter {
  font-size: 13px;
  line-height: 1;
}

.admin-new-access {
  font-size: 13px;
  line-height: 1;
}

.admin-main-nav a.active,
.access-filter.active,
.admin-new-access {
  font-weight: 600;
}

@media (max-width: 980px) {
  .admin-main-nav a {
    font-size: 12px;
    letter-spacing: .045em;
  }

  .access-filter,
  .admin-new-access {
    font-size: 12px;
  }
}


/* --- v0.13.0 temporary toast notifications + access creation modal --- */
.toast-stack {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 5000;
  width: min(560px, calc(100vw - 32px));
  transform: translateX(-50%);
  pointer-events: none;
}

.app-toast {
  min-height: 58px;
  display: grid;
  grid-template-columns: 34px minmax(0,1fr) 30px;
  align-items: center;
  gap: 11px;
  padding: 11px 12px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 16px;
  background:
    linear-gradient(145deg, rgba(255,255,255,.06), rgba(255,255,255,.025)),
    rgba(17,15,14,.96);
  box-shadow: 0 22px 70px rgba(0,0,0,.46);
  backdrop-filter: blur(18px);
  pointer-events: auto;
  animation: monkey-toast-in .26s ease both;
}

.app-toast.success {
  border-color: rgba(85,214,139,.26);
  background:
    radial-gradient(circle at 0 50%, rgba(85,214,139,.11), transparent 15rem),
    rgba(17,18,16,.96);
}

.app-toast.error {
  border-color: rgba(255,107,107,.28);
  background:
    radial-gradient(circle at 0 50%, rgba(255,107,107,.11), transparent 15rem),
    rgba(18,15,15,.96);
}

.app-toast.warning {
  border-color: rgba(248,199,94,.28);
  background:
    radial-gradient(circle at 0 50%, rgba(248,199,94,.10), transparent 15rem),
    rgba(18,17,14,.96);
}

.app-toast.info {
  border-color: rgba(99,169,255,.24);
}

.app-toast.is-leaving {
  animation: monkey-toast-out .22s ease both;
}

.app-toast-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,.09);
  background: rgba(255,255,255,.035);
  color: #d8d1cc;
  font-size: 14px;
  font-weight: 700;
}

.app-toast.success .app-toast-icon {
  color: #8deab0;
  border-color: rgba(85,214,139,.20);
  background: rgba(85,214,139,.08);
}

.app-toast.error .app-toast-icon {
  color: #ff9b99;
  border-color: rgba(255,107,107,.20);
  background: rgba(255,107,107,.08);
}

.app-toast.warning .app-toast-icon {
  color: #f7d27a;
  border-color: rgba(248,199,94,.20);
  background: rgba(248,199,94,.07);
}

.app-toast-message {
  min-width: 0;
  color: #e8e0da;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.45;
}

.app-toast-close {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #8f8782;
  cursor: pointer;
  font-size: 18px;
}

.app-toast-close:hover {
  color: #fff;
  background: rgba(255,255,255,.055);
}

@keyframes monkey-toast-in {
  from { opacity: 0; transform: translateY(18px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes monkey-toast-out {
  from { opacity: 1; transform: translateY(0) scale(1); }
  to { opacity: 0; transform: translateY(12px) scale(.985); }
}

/* New access stays inside /accesses instead of navigating to a form page. */
.access-create-dialog {
  width: min(1080px, calc(100vw - 34px));
  max-width: 1080px;
  max-height: min(92vh, 940px);
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(255,159,70,.18);
  border-radius: 24px;
  background: #12100f;
  color: var(--text);
  box-shadow: 0 42px 120px rgba(0,0,0,.68);
}

.access-create-dialog::backdrop {
  background: rgba(0,0,0,.80);
  backdrop-filter: blur(10px);
}

.access-create-modal {
  max-height: min(92vh, 940px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background:
    radial-gradient(circle at 88% 0%, rgba(255,145,47,.09), transparent 24rem),
    #12100f;
}

.access-create-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 24px 18px;
  border-bottom: 1px solid rgba(255,255,255,.07);
}

.access-create-header h2 {
  margin: 5px 0 6px;
  font-size: 28px;
  line-height: 1;
  letter-spacing: -.035em;
}

.access-create-header p {
  margin: 0;
  color: #918984;
  font-size: 13px;
  line-height: 1.5;
}

.access-create-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 12px;
  padding: 18px 20px;
  overflow-y: auto;
}

.access-create-panel {
  min-width: 0;
  align-self: start;
  padding: 17px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 16px;
  background: rgba(255,255,255,.018);
}

.access-create-section-title {
  display: grid;
  grid-template-columns: 34px minmax(0,1fr);
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
}

.access-create-section-title > span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,159,70,.17);
  border-radius: 10px;
  background: rgba(255,139,42,.07);
  color: #ffb365;
  font-size: 12px;
  font-weight: 700;
}

.access-create-section-title strong,
.access-create-section-title small {
  display: block;
}

.access-create-section-title strong {
  font-size: 15px;
}

.access-create-section-title small {
  margin-top: 2px;
  color: #817a76;
  font-size: 12px;
}

.access-create-panel > label,
.access-create-panel .form-grid > label {
  font-size: 13px;
  font-weight: 600;
}

.access-create-panel label > small {
  display: block;
  margin-top: 5px;
  color: #7f7873;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
}

.access-create-library-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 7px;
}

.access-create-library-grid .library-option {
  padding: 9px;
}

.access-create-sync {
  margin: 10px 0 0;
}

.access-create-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 14px 20px 18px;
  border-top: 1px solid rgba(255,255,255,.07);
  background: rgba(0,0,0,.14);
}

.access-create-actions .button {
  min-width: 138px;
}

@media (max-width: 820px) {
  .access-create-dialog {
    width: min(100vw - 20px, 1080px);
    max-height: 94vh;
  }

  .access-create-modal {
    max-height: 94vh;
  }

  .access-create-grid {
    grid-template-columns: 1fr;
    padding: 14px;
  }

  .access-create-header {
    padding: 18px 16px 15px;
  }

  .access-create-actions {
    padding: 12px 14px 14px;
  }
}

@media (max-width: 520px) {
  .toast-stack {
    bottom: 18px;
    width: calc(100vw - 20px);
  }

  .app-toast {
    grid-template-columns: 32px minmax(0,1fr) 28px;
    border-radius: 14px;
  }

  .access-create-library-grid,
  .access-create-panel .form-grid.two {
    grid-template-columns: 1fr;
  }

  .access-create-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .access-create-actions .button {
    min-width: 0;
  }
}


/* --- v0.13.1 refined admin forms --- */
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) label {
  gap: 8px;
  color: #ddd5cf;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .005em;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) label > small {
  color: #817a76;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.45;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) input:not([type="checkbox"]):not([type="radio"]),
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) select,
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) textarea {
  min-height: 46px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 13px;
  background: linear-gradient(180deg, rgba(12,11,10,.94), rgba(9,9,9,.94));
  color: #f3eee9;
  padding: 11px 13px;
  outline: none;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.35;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018);
  transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) textarea {
  min-height: 92px;
  resize: vertical;
  line-height: 1.55;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) input::placeholder,
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) textarea::placeholder {
  color: #69635f;
  opacity: 1;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) input:not([type="checkbox"]):not([type="radio"]):hover,
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) select:hover,
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) textarea:hover {
  border-color: rgba(255,255,255,.15);
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) input:not([type="checkbox"]):not([type="radio"]):focus,
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) select:focus,
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) textarea:focus {
  border-color: rgba(255,157,61,.55);
  background: #0d0c0b;
  box-shadow: 0 0 0 3px rgba(255,139,42,.08);
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 42px;
  cursor: pointer;
  background-image:
    linear-gradient(45deg, transparent 50%, #a59d97 50%),
    linear-gradient(135deg, #a59d97 50%, transparent 50%),
    linear-gradient(180deg, rgba(12,11,10,.94), rgba(9,9,9,.94));
  background-position:
    calc(100% - 19px) calc(50% - 2px),
    calc(100% - 14px) calc(50% - 2px),
    0 0;
  background-size: 5px 5px, 5px 5px, 100% 100%;
  background-repeat: no-repeat;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) select:focus {
  background-image:
    linear-gradient(45deg, transparent 50%, #ffb463 50%),
    linear-gradient(135deg, #ffb463 50%, transparent 50%),
    linear-gradient(180deg, #0d0c0b, #0d0c0b);
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) select option {
  background: #171412;
  color: #f4eee9;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  margin: 2px 0 0;
  border: 1px solid rgba(255,255,255,.20);
  border-radius: 5px;
  background: #0d0c0b;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, box-shadow .16s ease;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) input[type="checkbox"]:checked {
  border-color: #ff982f;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.2 8.3 6.5 11.3 12.8 4.8' fill='none' stroke='%23190e05' stroke-width='2.3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/13px 13px no-repeat,
    linear-gradient(135deg, #ff8c2d, #ffc260);
  box-shadow: 0 0 0 3px rgba(255,139,42,.07);
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) input[type="checkbox"]:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(255,139,42,.12);
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .library-option,
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .checkline {
  align-items: center;
  min-height: 54px;
  padding: 10px 12px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 13px;
  background: linear-gradient(180deg, rgba(255,255,255,.022), rgba(255,255,255,.012));
  transition: border-color .16s ease, background .16s ease, transform .16s ease;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .library-option:hover,
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .checkline:hover {
  transform: translateY(-1px);
  border-color: rgba(255,159,70,.18);
  background: rgba(255,139,42,.025);
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .library-option:has(input:checked),
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .checkline:has(input:checked) {
  border-color: rgba(255,159,70,.25);
  background: linear-gradient(135deg, rgba(255,139,42,.065), rgba(255,193,91,.025));
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .library-option strong,
:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .checkline strong {
  font-size: 13px;
  font-weight: 600;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .library-icon {
  width: 32px;
  height: 32px;
  border: 1px solid rgba(255,255,255,.055);
  border-radius: 9px;
  background: rgba(255,255,255,.035);
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .money-input {
  min-height: 46px;
  grid-template-columns: 42px 1fr;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 13px;
  background: linear-gradient(180deg, rgba(12,11,10,.94), rgba(9,9,9,.94));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018);
  transition: border-color .16s ease, box-shadow .16s ease;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .money-input:focus-within {
  border-color: rgba(255,157,61,.55);
  box-shadow: 0 0 0 3px rgba(255,139,42,.08);
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .money-input > span {
  color: #ffb365;
  font-size: 14px;
  font-weight: 600;
}

:where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) .money-input input {
  min-height: 44px;
  border: 0 !important;
  border-left: 1px solid rgba(255,255,255,.07) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.plan-edit-dialog,
.access-create-dialog,
.team-create-dialog {
  border-color: rgba(255,255,255,.10);
  background: #14110f;
  box-shadow: 0 38px 120px rgba(0,0,0,.72);
}

.plan-edit-modal,
.access-create-modal {
  background:
    radial-gradient(circle at 90% -5%, rgba(255,145,47,.075), transparent 22rem),
    #14110f;
}

.plan-edit-header,
.access-create-header {
  border-bottom-color: rgba(255,255,255,.065);
}

.dialog-close {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 11px;
  background: rgba(255,255,255,.025);
  color: #aaa29d;
  font-size: 20px;
  font-weight: 500;
  line-height: 1;
  transition: border-color .16s ease, background .16s ease, color .16s ease, transform .16s ease;
}

.dialog-close:hover {
  transform: rotate(3deg);
  border-color: rgba(255,159,70,.20);
  background: rgba(255,159,70,.05);
  color: #fff;
}

:where(.plan-edit-actions, .access-create-actions, .form-actions, .session-stop-actions) .button {
  min-height: 44px;
  border-radius: 12px;
  padding: 0 17px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .025em;
  box-shadow: none;
}

:where(.plan-edit-actions, .access-create-actions, .form-actions, .session-stop-actions) .button.primary {
  border-color: rgba(255,175,76,.34);
  background: linear-gradient(135deg, #ff922f, #ffba55);
  color: #1b1007;
  box-shadow: 0 10px 24px rgba(255,139,42,.10);
}

:where(.plan-edit-actions, .access-create-actions, .form-actions, .session-stop-actions) .button.primary:hover {
  border-color: rgba(255,194,96,.52);
  background: linear-gradient(135deg, #ff9b39, #ffc363);
}

:where(.plan-edit-actions, .access-create-actions, .form-actions, .session-stop-actions) .button.ghost,
:where(.plan-edit-actions, .access-create-actions, .form-actions, .session-stop-actions) .button.secondary {
  border-color: rgba(255,255,255,.09);
  background: rgba(255,255,255,.025);
  color: #d5cdc7;
}

:where(.plan-edit-actions, .access-create-actions, .form-actions, .session-stop-actions) .button.ghost:hover,
:where(.plan-edit-actions, .access-create-actions, .form-actions, .session-stop-actions) .button.secondary:hover {
  border-color: rgba(255,255,255,.16);
  background: rgba(255,255,255,.045);
  color: #fff;
}

.plan-libraries-field {
  padding: 12px;
  border-color: rgba(255,255,255,.075);
  border-radius: 15px;
  background: rgba(255,255,255,.012);
}

.plan-libraries-field legend {
  padding: 0 7px;
  color: #9f9791;
  font-size: 12px;
  font-weight: 600;
}

.plan-sync-option {
  min-height: 52px;
}

@media (max-width: 680px) {
  :where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) input:not([type="checkbox"]):not([type="radio"]),
  :where(.plan-edit-modal, .access-create-modal, .form-layout, .team-create-dialog) select {
    min-height: 44px;
  }

  :where(.plan-edit-actions, .access-create-actions, .form-actions, .session-stop-actions) .button {
    min-height: 44px;
  }
}


/* --- v0.14.0 service account inventory --- */
.accounts-overview {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.account-metric {
  min-height: 116px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 16px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 16px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.055), transparent 10rem),
    rgba(255,255,255,.016);
}

.account-metric > span {
  color: #8b837e;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .055em;
  text-transform: uppercase;
}

.account-metric strong {
  margin-top: 7px;
  font-size: 30px;
  line-height: 1;
  letter-spacing: -.04em;
}

.account-metric small {
  margin-top: 5px;
  color: #736c68;
  font-size: 12px;
}

.account-metric.demo {
  border-color: rgba(99,169,255,.12);
}

.account-metric.sale {
  border-color: rgba(255,159,70,.13);
}

.accounts-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  padding: 8px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 15px;
  background: rgba(255,255,255,.018);
}

.accounts-filters {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.account-filter {
  min-height: 36px;
  padding: 0 13px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 999px;
  background: rgba(255,255,255,.018);
  color: #8f8782;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .045em;
}

.account-filter:hover {
  border-color: rgba(255,159,70,.16);
  color: #d7cfc9;
}

.account-filter.active {
  border-color: rgba(255,159,70,.28);
  background: linear-gradient(135deg, #ff932f, #ffc060);
  color: #1a0f06;
}

.service-account-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 12px;
}

.service-account-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 17px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 17px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.06), transparent 12rem),
    linear-gradient(180deg, rgba(255,255,255,.022), rgba(255,255,255,.012));
}

.service-account-head {
  margin-bottom: 14px;
}

.service-account-identity {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 11px;
}

.service-account-avatar {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,159,70,.16);
  border-radius: 13px;
  background: linear-gradient(135deg, rgba(255,139,42,.14), rgba(141,114,255,.08));
  color: #ffc176;
  font-size: 16px;
  font-weight: 700;
}

.service-account-identity > div {
  min-width: 0;
}

.service-account-badges {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  margin-bottom: 5px;
}

.service-account-kind,
.service-account-status {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 7px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .035em;
}

.service-account-kind.sale {
  color: #ffc176;
  border: 1px solid rgba(255,159,70,.17);
  background: rgba(255,139,42,.055);
}

.service-account-kind.demo {
  color: #9bc8ff;
  border: 1px solid rgba(99,169,255,.17);
  background: rgba(99,169,255,.055);
}

.service-account-status.available {
  color: #91e3ae;
  border: 1px solid rgba(85,214,139,.16);
  background: rgba(85,214,139,.05);
}

.service-account-status.review {
  color: #f5d07e;
  border: 1px solid rgba(248,199,94,.16);
  background: rgba(248,199,94,.05);
}

.service-account-status.disabled {
  color: #9a938e;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.025);
}

.service-account-status.unrecoverable {
  color: #ff9b99;
  border: 1px solid rgba(255,107,107,.18);
  background: rgba(255,107,107,.055);
}

.service-account-status.assigned {
  color: #b7a7ff;
  border: 1px solid rgba(141,114,255,.17);
  background: rgba(141,114,255,.055);
}

.service-account-identity h3 {
  margin: 0;
  overflow: hidden;
  font-size: 17px;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.service-account-identity p {
  margin: 4px 0 0;
  overflow: hidden;
  color: #8b837e;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.service-account-credentials {
  display: grid;
  gap: 6px;
}

.service-account-credentials > div {
  min-width: 0;
  display: grid;
  grid-template-columns: 86px minmax(0,1fr);
  gap: 10px;
  align-items: center;
  min-height: 38px;
  padding: 8px 9px;
  border: 1px solid rgba(255,255,255,.055);
  border-radius: 10px;
  background: rgba(0,0,0,.13);
}

.service-account-credentials span {
  color: #756e6a;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .045em;
}

.service-account-credentials strong {
  min-width: 0;
  overflow-wrap: anywhere;
  color: #d8d1cc;
  font-size: 13px;
  font-weight: 600;
}

.service-account-password-row strong {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  letter-spacing: .04em;
}

.service-account-notes {
  margin: 10px 0 0;
  color: #8f8782;
  font-size: 13px;
  line-height: 1.5;
}

.service-account-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 14px;
}

.service-account-footer small {
  color: #68615d;
  font-size: 12px;
}

.service-account-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.service-account-actions .plan-icon-button {
  width: 36px;
  height: 36px;
}

.account-create-dialog,
.account-edit-dialog {
  width: min(680px, calc(100vw - 32px));
  max-width: 680px;
}

.accounts-bulk-dialog {
  width: min(760px, calc(100vw - 32px));
  max-width: 760px;
}

.accounts-bulk-textarea {
  min-height: 250px !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px !important;
  line-height: 1.55 !important;
}

.account-security-note {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border: 1px solid rgba(85,214,139,.12);
  border-radius: 12px;
  background: rgba(85,214,139,.035);
  color: #9ab8a5;
  font-size: 13px;
}

.account-security-note svg {
  width: 19px;
  height: 19px;
  flex: 0 0 19px;
  color: #7edda2;
}

@media (max-width: 1000px) {
  .accounts-overview {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 700px) {
  .accounts-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .accounts-toolbar .admin-inline-actions {
    justify-content: flex-end;
  }

  .service-account-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .accounts-overview {
    grid-template-columns: 1fr 1fr;
  }

  .account-metric {
    min-height: 102px;
    padding: 13px;
  }

  .service-account-credentials > div {
    grid-template-columns: 1fr;
    gap: 3px;
  }

  .service-account-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .service-account-actions {
    width: 100%;
    justify-content: flex-end;
  }
}


/* --- v0.14.1 polished accounts module --- */
.accounts-overview {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.account-metric {
  min-height: 126px;
  padding: 17px 18px;
  border-color: rgba(255,255,255,.075);
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.09), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018);
}

.account-metric-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.account-metric-top span,
.account-metric small {
  color: #827a75;
  font-size: 12px;
  font-style: normal;
  font-weight: 600;
  letter-spacing: .065em;
  text-transform: uppercase;
}

.account-metric-top i {
  color: #554f4b;
  font-size: 12px;
  font-style: normal;
  font-weight: 600;
}

.account-metric strong {
  margin-top: 18px;
  color: #f6efe9;
  font-size: 34px;
  font-weight: 600;
  letter-spacing: -.045em;
}

.account-metric small {
  margin-top: 6px;
  color: #68615d;
}

.account-metric.demo {
  background:
    radial-gradient(circle at 100% 0%, rgba(99,169,255,.11), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
}

.account-metric.sale {
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.12), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
}

.accounts-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  padding: 9px;
  border-color: rgba(255,255,255,.075);
  border-radius: 17px;
  background: linear-gradient(180deg, rgba(255,255,255,.024), rgba(255,255,255,.012));
}

.accounts-search {
  width: clamp(260px, 30vw, 390px);
  min-height: 42px;
  flex: 0 1 390px;
  display: grid;
  grid-template-columns: 22px minmax(0,1fr);
  gap: 8px;
  align-items: center;
  padding: 0 12px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  background: rgba(0,0,0,.16);
}

.accounts-search svg {
  width: 18px;
  height: 18px;
  color: #756e69;
}

.accounts-search input {
  width: 100%;
  min-width: 0;
  height: 40px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #ede6e0;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .035em;
}

.accounts-search input::placeholder {
  color: #5f5955;
}

.accounts-toolbar-row {
  min-width: 0;
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.accounts-filters {
  gap: 7px;
}

.account-filter {
  min-height: 38px;
  padding: 0 14px;
  border-color: rgba(255,255,255,.075);
  background: rgba(255,255,255,.018);
  color: #8d8580;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.account-filter.active {
  border-color: rgba(255,164,73,.38);
  background: linear-gradient(135deg, #ff932f, #ffc361);
  color: #1a0e05;
  box-shadow: 0 8px 22px rgba(255,139,42,.12);
}

.service-account-grid {
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 12px;
  align-items: start;
}

.service-account-card {
  min-height: 0;
  padding: 15px;
  border-color: rgba(255,255,255,.075);
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.075), transparent 13rem),
    linear-gradient(160deg, rgba(255,255,255,.026), rgba(255,255,255,.011));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018);
}

.service-account-card.demo {
  border-color: rgba(99,169,255,.18);
  background:
    radial-gradient(circle at 100% 0%, rgba(99,169,255,.13), transparent 13rem),
    linear-gradient(160deg, rgba(72,117,185,.055), rgba(255,255,255,.010));
  box-shadow:
    inset 3px 0 0 rgba(99,169,255,.42),
    inset 0 1px 0 rgba(255,255,255,.018);
}

.service-account-card.sale {
  border-color: rgba(255,159,70,.16);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.105), transparent 13rem),
    linear-gradient(160deg, rgba(145,80,27,.045), rgba(255,255,255,.010));
  box-shadow:
    inset 3px 0 0 rgba(255,159,70,.38),
    inset 0 1px 0 rgba(255,255,255,.018);
}

.service-account-card.demo:hover {
  border-color: rgba(99,169,255,.30);
}

.service-account-card.sale:hover {
  border-color: rgba(255,159,70,.27);
}

.service-account-head {
  margin-bottom: 10px;
}

.service-account-avatar {
  border-radius: 12px;
  font-weight: 600;
}

.service-account-kind,
.service-account-status {
  min-height: 23px;
  padding: 0 8px;
  font-size: 12px;
  font-weight: 600;
}

.service-account-identity h3 {
  font-size: 18px;
  font-weight: 600;
}

.service-account-credentials > div {
  min-height: 38px;
  padding: 7px 9px;
  border-color: rgba(255,255,255,.06);
  border-radius: 11px;
}

.service-account-footer {
  margin-top: 12px;
  padding-top: 11px;
  border-top: 1px solid rgba(255,255,255,.055);
}

.service-account-actions .plan-icon-button {
  width: 38px;
  height: 38px;
  border-color: rgba(255,159,70,.13);
  background: linear-gradient(135deg, rgba(255,139,42,.09), rgba(255,193,91,.025));
}

.accounts-empty-state {
  min-height: 270px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 9px;
  padding: 30px;
  border: 1px dashed rgba(255,255,255,.095);
  border-radius: 20px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255,145,47,.055), transparent 18rem),
    rgba(255,255,255,.012);
  text-align: center;
}

.accounts-empty-state img {
  width: 58px;
  height: 58px;
  object-fit: contain;
  margin-bottom: 4px;
}

.accounts-empty-state h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: .025em;
}

.accounts-empty-state p {
  max-width: 560px;
  margin: 0 0 8px;
  color: #918984;
  font-size: 13px;
  line-height: 1.55;
}

.account-create-dialog {
  width: min(720px, calc(100vw - 32px));
  max-width: 720px;
}

.account-create-dialog .plan-edit-modal,
.account-edit-dialog .plan-edit-modal,
.accounts-bulk-dialog .plan-edit-modal {
  padding: 0;
  overflow: hidden;
}

.account-create-dialog .plan-edit-header,
.account-edit-dialog .plan-edit-header,
.accounts-bulk-dialog .plan-edit-header {
  padding: 20px 22px 17px;
}

.account-create-dialog .plan-edit-header h2,
.account-edit-dialog .plan-edit-header h2,
.accounts-bulk-dialog .plan-edit-header h2 {
  font-size: 27px;
  font-weight: 600;
}

.account-create-dialog .plan-edit-modal > :not(.plan-edit-header):not(.plan-edit-actions),
.account-edit-dialog .plan-edit-modal > :not(.plan-edit-header):not(.plan-edit-actions),
.accounts-bulk-dialog .plan-edit-modal > :not(.plan-edit-header):not(.plan-edit-actions) {
  margin-left: 22px;
  margin-right: 22px;
}

.account-create-dialog .plan-edit-modal > .form-grid,
.account-edit-dialog .plan-edit-modal > .form-grid {
  margin-top: 16px;
}

.account-field-label {
  display: block;
  margin-bottom: 8px;
  color: #b0a7a1;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
}

.account-kind-picker {
  margin-top: 16px;
}

.account-kind-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 8px;
}

.account-kind-option {
  position: relative;
  display: block !important;
  cursor: pointer;
}

.account-kind-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.account-kind-option > span {
  min-height: 62px;
  display: grid;
  align-content: center;
  gap: 3px;
  padding: 11px 13px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 13px;
  background: linear-gradient(180deg, rgba(255,255,255,.022), rgba(255,255,255,.012));
  transition: border-color .16s ease, background .16s ease, box-shadow .16s ease, transform .16s ease;
}

.account-kind-option:hover > span {
  transform: translateY(-1px);
  border-color: rgba(255,159,70,.16);
}

.account-kind-option input:checked + span {
  border-color: rgba(255,159,70,.34);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.12), transparent 9rem),
    rgba(255,139,42,.04);
  box-shadow: 0 0 0 3px rgba(255,139,42,.055);
}

.account-kind-option strong {
  color: #f1e9e3;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .045em;
}

.account-kind-option small {
  color: #746d68;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .035em;
}

.account-create-dialog .form-grid.two {
  gap: 11px 12px;
}

.account-create-dialog label,
.account-edit-dialog label,
.accounts-bulk-dialog label {
  color: #b9b0aa;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .045em;
}

.account-password-input {
  position: relative;
  display: block;
}

.account-password-input input {
  width: 100%;
  padding-right: 48px !important;
}

.account-password-input button {
  position: absolute;
  top: 50%;
  right: 7px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  padding: 0;
  transform: translateY(-50%);
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 9px;
  background: rgba(255,255,255,.018);
  color: #847c77;
  cursor: pointer;
}

.account-password-input button:hover,
.account-password-input button.active {
  border-color: rgba(255,159,70,.20);
  background: rgba(255,139,42,.05);
  color: #ffc176;
}

.account-password-input button svg {
  width: 17px;
  height: 17px;
}

.account-security-note {
  min-height: 42px;
  margin-top: 13px !important;
  padding: 9px 11px;
  gap: 9px;
  border-color: rgba(85,214,139,.11);
  border-radius: 11px;
  color: #89a994;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .025em;
}

.account-security-icon {
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(85,214,139,.17);
  border-radius: 8px;
  background: rgba(85,214,139,.06);
  color: #85e1a7;
  font-size: 12px;
  font-weight: 700;
}

.account-security-note svg {
  width: 18px !important;
  height: 18px !important;
  max-width: 18px !important;
  max-height: 18px !important;
}

.account-create-dialog .plan-edit-actions,
.account-edit-dialog .plan-edit-actions,
.accounts-bulk-dialog .plan-edit-actions {
  margin-top: 17px;
  padding: 14px 22px 18px;
  border-top: 1px solid rgba(255,255,255,.065);
  background: rgba(0,0,0,.13);
}

.account-create-dialog .button,
.account-edit-dialog .button,
.accounts-bulk-dialog .button,
.plan-delete-dialog .button {
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .055em;
}

.accounts-bulk-dialog .account-kind-picker {
  margin-bottom: 14px;
}

.accounts-bulk-dialog .accounts-bulk-textarea {
  min-height: 220px !important;
}

@media (max-width: 980px) {
  .accounts-toolbar {
    flex-wrap: wrap;
  }

  .accounts-search {
    width: 100%;
    flex: 1 1 100%;
  }

  .accounts-toolbar-row {
    width: 100%;
  }
}

@media (max-width: 900px) {
  .accounts-overview {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .service-account-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px,1fr));
  }
}

@media (max-width: 640px) {
  .accounts-toolbar-row {
    align-items: stretch;
    flex-direction: column;
  }

  .accounts-filters {
    overflow-x: auto;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }

  .accounts-filters::-webkit-scrollbar {
    display: none;
  }

  .accounts-toolbar-row .admin-inline-actions {
    width: 100%;
    justify-content: flex-end;
  }

  .account-kind-options,
  .account-create-dialog .form-grid.two,
  .account-edit-dialog .form-grid.two {
    grid-template-columns: 1fr;
  }

  .account-create-dialog .plan-edit-modal > :not(.plan-edit-header):not(.plan-edit-actions),
  .account-edit-dialog .plan-edit-modal > :not(.plan-edit-header):not(.plan-edit-actions),
  .accounts-bulk-dialog .plan-edit-modal > :not(.plan-edit-header):not(.plan-edit-actions) {
    margin-left: 16px;
    margin-right: 16px;
  }

  .account-create-dialog .plan-edit-header,
  .account-edit-dialog .plan-edit-header,
  .accounts-bulk-dialog .plan-edit-header {
    padding: 18px 16px 15px;
  }

  .account-create-dialog .plan-edit-actions,
  .account-edit-dialog .plan-edit-actions,
  .accounts-bulk-dialog .plan-edit-actions {
    padding: 12px 16px 15px;
  }
}

@media (max-width: 520px) {
  .accounts-overview {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .account-metric {
    min-height: 112px;
    padding: 14px;
  }

  .account-metric strong {
    font-size: 29px;
  }

  .service-account-grid {
    grid-template-columns: 1fr;
  }
}


/* --- v0.15.0 sales-first access creation + assigned account display --- */
.access-sale-dialog {
  width: min(1180px, calc(100vw - 34px));
  max-width: 1180px;
}

.access-sale-modal {
  max-height: min(92vh, 980px);
}

.access-sale-header {
  padding-bottom: 16px;
}

.access-sale-body {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0,1fr) minmax(320px,.72fr);
  gap: 13px;
  padding: 18px 20px;
  overflow-y: auto;
}

.access-sale-step {
  min-width: 0;
  padding: 17px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 16px;
  background: rgba(255,255,255,.015);
}

.access-sale-step:nth-of-type(1) {
  grid-column: 1;
}

.access-sale-step:nth-of-type(2),
.access-sale-step:nth-of-type(3) {
  grid-column: 1;
}

.access-plan-picker {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px,1fr));
  gap: 8px;
}

.access-plan-option {
  position: relative;
  display: block;
  cursor: pointer;
}

.access-plan-option > input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.access-plan-option-card {
  min-height: 146px;
  display: flex;
  flex-direction: column;
  padding: 14px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 14px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.06), transparent 10rem),
    rgba(0,0,0,.13);
  transition: transform .16s ease, border-color .16s ease, background .16s ease, box-shadow .16s ease;
}

.access-plan-option:hover .access-plan-option-card {
  transform: translateY(-1px);
  border-color: rgba(255,159,70,.18);
}

.access-plan-option > input:checked + .access-plan-option-card {
  border-color: rgba(255,159,70,.35);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.14), transparent 10rem),
    rgba(255,139,42,.035);
  box-shadow: 0 0 0 3px rgba(255,139,42,.055);
}

.access-plan-option.is-unavailable {
  cursor: not-allowed;
  opacity: .42;
}

.access-plan-option-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.access-plan-option-top strong {
  overflow: hidden;
  color: #f2ebe5;
  font-size: 15px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-plan-option-top i {
  flex: 0 0 auto;
  padding: 4px 7px;
  border: 1px solid rgba(255,159,70,.16);
  border-radius: 999px;
  color: #ffbc70;
  font-size: 12px;
  font-style: normal;
  font-weight: 600;
  letter-spacing: .045em;
}

.access-plan-option-card > b {
  margin-top: 22px;
  color: #fff3e8;
  font-size: 23px;
  font-weight: 600;
  letter-spacing: -.035em;
}

.access-plan-option-card > small {
  margin-top: 5px;
  color: #817a76;
  font-size: 12px;
  line-height: 1.4;
}

.access-plan-option-card > em {
  margin-top: auto;
  padding-top: 9px;
  color: #86dca7;
  font-size: 12px;
  font-style: normal;
  font-weight: 600;
}

.access-plan-option.is-unavailable .access-plan-option-card > em {
  color: #ff918b;
}

.access-sale-summary {
  grid-column: 2;
  grid-row: 1 / span 3;
  align-self: start;
  position: sticky;
  top: 0;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  padding: 22px;
  border: 1px solid rgba(255,159,70,.18);
  border-radius: 18px;
  background:
    radial-gradient(circle at 90% 0%, rgba(255,151,55,.15), transparent 14rem),
    linear-gradient(180deg, rgba(255,139,42,.04), rgba(255,255,255,.015)),
    #14110f;
}

.access-sale-summary-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  margin: 18px 0 15px;
  border: 1px solid rgba(85,214,139,.17);
  border-radius: 13px;
  background: rgba(85,214,139,.055);
  color: #87e0a9;
}

.access-sale-summary-icon svg {
  width: 21px;
  height: 21px;
}

.access-sale-summary h3 {
  margin: 0 0 7px;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -.035em;
}

.access-sale-summary > p {
  margin: 0 0 18px;
  color: #9d9590;
  font-size: 13px;
  line-height: 1.55;
}

.access-sale-summary dl {
  display: grid;
  gap: 7px;
  margin: 0;
}

.access-sale-summary dl > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0;
  border-top: 1px solid rgba(255,255,255,.06);
}

.access-sale-summary dt {
  color: #756e69;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .055em;
}

.access-sale-summary dd {
  margin: 0;
  color: #ddd5cf;
  font-size: 13px;
  font-weight: 600;
  text-align: right;
}

.access-sale-auto-note {
  display: grid;
  grid-template-columns: 26px minmax(0,1fr);
  gap: 9px;
  align-items: start;
  margin-top: auto;
  padding-top: 18px;
}

.access-sale-auto-note > span {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(85,214,139,.16);
  border-radius: 8px;
  background: rgba(85,214,139,.05);
  color: #86dca7;
  font-size: 12px;
  font-weight: 700;
}

.access-sale-auto-note p {
  margin: 3px 0 0;
  color: #8f8782;
  font-size: 12px;
  line-height: 1.5;
}

.access-sale-actions {
  justify-content: flex-end;
}

.access-sale-actions .button {
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .055em;
}

/* Assigned inventory account appears directly in access cards and detail modal. */
.access-card-account {
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  gap: 8px;
  align-items: center;
  margin-top: 9px;
  padding: 8px 10px;
  border: 1px solid rgba(255,159,70,.10);
  border-radius: 11px;
  background: rgba(255,139,42,.025);
}

.access-card-account span {
  color: #766f6a;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .05em;
}

.access-card-account strong {
  min-width: 0;
  overflow: hidden;
  color: #d9d1cb;
  font-size: 13px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-card-account i {
  color: #ffb96c;
  font-size: 12px;
  font-style: normal;
  font-weight: 600;
}

/* Plex profile avatars for inventory and assigned accounts. */
.plex-profile-avatar,
.plex-service-avatar {
  display: block;
  padding: 0;
  object-fit: cover;
  object-position: center;
  overflow: hidden;
}

.plex-profile-avatar {
  border: 1px solid rgba(255,255,255,.10);
  background: #171311;
}

.plex-service-avatar {
  border-color: rgba(255,255,255,.10);
  background: #171311;
}

.account-avatar-fallback.sale {
  background: linear-gradient(135deg, rgba(255,139,42,.95), rgba(135,90,255,.80));
  color: #fff8f1;
}

.account-avatar-fallback.demo {
  border-color: rgba(99,169,255,.20);
  background: linear-gradient(135deg, rgba(71,144,255,.82), rgba(118,92,255,.72));
  color: #f3f8ff;
}

.access-card-account {
  grid-template-columns: 28px auto minmax(0,1fr) auto;
}

.access-card-account-avatar {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(255,159,70,.13);
  border-radius: 9px;
  background: rgba(255,139,42,.05);
}

.access-card-account-avatar.demo {
  border-color: rgba(99,169,255,.17);
  background: rgba(99,169,255,.05);
}

.access-card-account-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
}

.access-card-account-avatar span {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: #ffc176;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0;
}

.access-card-account-avatar.demo span {
  color: #9bc8ff;
}

.plex-profile-avatar[hidden],
.plex-service-avatar[hidden],
.account-avatar-fallback[hidden],
.access-card-account-avatar img[hidden],
.access-card-account-avatar span[hidden] {
  display: none !important;
}

.access-tv-link-form {
  display: grid;
  gap: 11px;
  margin-top: 12px;
  padding: 12px;
  border: 1px solid rgba(99,169,255,.13);
  border-radius: 12px;
  background: rgba(99,169,255,.035);
}

.access-tv-link-copy {
  display: grid;
  grid-template-columns: 30px minmax(0,1fr);
  align-items: start;
  gap: 10px;
}

.access-tv-link-icon {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(99,169,255,.18);
  border-radius: 9px;
  background: rgba(99,169,255,.06);
  color: #9bc8ff;
}

.access-tv-link-icon svg {
  width: 17px;
  height: 17px;
}

.access-tv-link-copy strong,
.access-tv-link-copy small {
  display: block;
}

.access-tv-link-copy strong {
  color: #dcecff;
  font-size: 12px;
  font-weight: 600;
}

.access-tv-link-copy small {
  margin-top: 3px;
  color: #8495a8;
  font-size: 12px;
  line-height: 1.45;
}

.access-tv-link-controls {
  display: grid;
  grid-template-columns: minmax(110px, .55fr) minmax(140px, 1fr);
  gap: 8px;
}

.access-tv-link-controls input {
  width: 100%;
  min-width: 0;
  height: 40px;
  padding: 0 12px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  outline: 0;
  background: rgba(0,0,0,.18);
  color: #f4f8ff;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: .18em;
  text-align: center;
  text-transform: uppercase;
}

.access-tv-link-controls input:focus {
  border-color: rgba(99,169,255,.30);
  box-shadow: 0 0 0 3px rgba(99,169,255,.055);
}

.access-tv-link-controls .button {
  min-height: 40px;
  margin: 0;
}

.access-tv-link-result {
  display: grid;
  grid-template-columns: 28px minmax(0,1fr);
  align-items: start;
  gap: 9px;
  margin-top: 10px;
  padding: 10px 11px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 11px;
}

.access-tv-link-result > span {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.access-tv-link-result strong,
.access-tv-link-result small {
  display: block;
}

.access-tv-link-result strong {
  font-size: 12px;
  font-weight: 700;
}

.access-tv-link-result small {
  margin-top: 2px;
  font-size: 12px;
  line-height: 1.45;
}

.access-tv-link-result.success {
  border-color: rgba(85,214,139,.14);
  background: rgba(85,214,139,.035);
}

.access-tv-link-result.success > span {
  background: rgba(85,214,139,.08);
  color: #91e3ae;
}

.access-tv-link-result.success strong {
  color: #b7ebc9;
}

.access-tv-link-result.success small {
  color: #87998d;
}

.access-tv-link-result.error {
  border-color: rgba(255,107,107,.14);
  background: rgba(255,107,107,.035);
}

.access-tv-link-result.error > span {
  background: rgba(255,107,107,.08);
  color: #ff9b99;
}

.access-tv-link-result.error strong {
  color: #ffc0be;
}

.access-tv-link-result.error small {
  color: #a18c8b;
}

@media (max-width: 560px) {
  .access-tv-link-controls {
    grid-template-columns: 1fr;
  }
}

.account-reuse-button {
  border-color: rgba(85,214,139,.18) !important;
  background: rgba(85,214,139,.055) !important;
  color: #8ee7af !important;
}

.account-reuse-button:hover {
  border-color: rgba(85,214,139,.30) !important;
  background: rgba(85,214,139,.10) !important;
  color: #b4f4ca !important;
}

.account-reuse-dialog {
  width: min(680px, calc(100vw - 32px));
  max-width: 680px;
}

.account-reuse-summary {
  min-height: 70px;
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 12px;
  margin-top: 16px !important;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 14px;
  background: rgba(255,255,255,.018);
}

.account-reuse-summary > div {
  min-width: 0;
}

.account-reuse-summary strong,
.account-reuse-summary small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-reuse-summary strong {
  color: #eee7e1;
  font-size: 14px;
}

.account-reuse-summary small {
  margin-top: 3px;
  color: #8e8681;
  font-size: 12px;
}

.account-reuse-note {
  display: grid;
  grid-template-columns: 28px minmax(0,1fr);
  align-items: start;
  gap: 10px;
  margin-top: 12px !important;
  padding: 11px 12px;
  border: 1px solid rgba(85,214,139,.12);
  border-radius: 12px;
  background: rgba(85,214,139,.035);
}

.account-reuse-note p {
  margin: 1px 0 0;
  color: #93a79a;
  font-size: 12px;
  line-height: 1.55;
}

.account-reuse-note strong {
  color: #b8dbc4;
  font-weight: 600;
}

.account-reuse-fields {
  margin-top: 14px !important;
}

.account-reuse-submit {
  border-color: rgba(85,214,139,.25) !important;
  background: linear-gradient(135deg, #68dc98, #96eeb8) !important;
  color: #0d1b13 !important;
}

.assigned-account-note.historical {
  border-color: rgba(248,199,94,.10);
  background: rgba(248,199,94,.025);
  color: #a99a76;
}

@media (max-width: 640px) {
  .account-reuse-summary {
    grid-template-columns: auto minmax(0,1fr);
  }

  .account-reuse-summary > .service-account-kind {
    grid-column: 2;
    justify-self: start;
  }

  .account-reuse-fields {
    grid-template-columns: 1fr !important;
  }
}

.access-detail-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.access-detail-title-row h3 {
  margin: 0;
}

.access-assigned-account {
  border-color: rgba(255,159,70,.12);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.075), transparent 11rem),
    rgba(255,255,255,.015);
}

.assigned-password-line {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
}

.assigned-password-line > strong {
  min-width: 0;
  overflow-wrap: anywhere;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
  font-weight: 600;
}

.credential-eye-button {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 9px;
  background: rgba(255,255,255,.02);
  color: #8e8681;
  cursor: pointer;
}

.credential-eye-button:hover {
  border-color: rgba(255,159,70,.18);
  background: rgba(255,139,42,.045);
  color: #ffc176;
}

.credential-eye-button svg {
  width: 16px;
  height: 16px;
}

.assigned-account-note {
  margin-top: 11px;
  padding: 10px 11px;
  border: 1px solid rgba(85,214,139,.10);
  border-radius: 10px;
  background: rgba(85,214,139,.03);
  color: #8da596;
  font-size: 12px;
  line-height: 1.45;
}

.access-modal-icon-actions {
  justify-content: flex-end;
  gap: 7px;
}

.access-modal-icon-actions form {
  margin: 0;
}

.danger-action-icon {
  color: #ff918b;
  border-color: rgba(255,93,86,.17);
  background: rgba(255,93,86,.04);
}

.danger-action-icon:hover {
  color: #ffb2ad;
  border-color: rgba(255,93,86,.27);
  background: rgba(255,93,86,.075);
}

.access-commercial-dialog {
  width: min(720px, calc(100vw - 32px));
  max-width: 720px;
}

.access-commercial-dialog .plan-edit-modal {
  padding: 0;
  overflow: hidden;
}

.access-commercial-dialog .plan-edit-header {
  padding: 20px 22px 17px;
}

.access-commercial-dialog .form-grid {
  margin: 17px 22px 0;
}

.access-commercial-dialog .plan-edit-actions {
  margin-top: 17px;
  padding: 14px 22px 18px;
  border-top: 1px solid rgba(255,255,255,.065);
  background: rgba(0,0,0,.13);
}

.access-commercial-dialog .button {
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .055em;
}

@media (max-width: 900px) {
  .access-sale-body {
    grid-template-columns: 1fr;
  }

  .access-sale-step,
  .access-sale-step:nth-of-type(1),
  .access-sale-step:nth-of-type(2),
  .access-sale-step:nth-of-type(3),
  .access-sale-summary {
    grid-column: 1;
  }

  .access-sale-summary {
    grid-row: auto;
    position: static;
    min-height: 0;
  }
}

@media (max-width: 620px) {
  .access-sale-body {
    padding: 13px;
  }

  .access-sale-step,
  .access-sale-summary {
    padding: 14px;
  }

  .access-plan-picker {
    grid-template-columns: 1fr;
  }

  .access-sale-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .access-sale-actions .button {
    min-width: 0;
  }

  .access-commercial-dialog .form-grid.two {
    grid-template-columns: 1fr;
  }

  .access-commercial-dialog .form-grid {
    margin-left: 16px;
    margin-right: 16px;
  }

  .access-commercial-dialog .plan-edit-header {
    padding: 18px 16px 15px;
  }

  .access-commercial-dialog .plan-edit-actions {
    padding: 12px 16px 15px;
  }
}


/* --- Compact access card final polish --- */
.access-card-account {
  display: grid;
  grid-template-columns: 28px minmax(0,1fr) auto;
  gap: 9px;
  align-items: center;
  margin-top: 9px;
  padding: 8px 10px;
  border: 1px solid rgba(255,159,70,.10);
  border-radius: 11px;
  background: linear-gradient(135deg, rgba(255,139,42,.035), rgba(255,255,255,.012));
}

.access-card-account-copy {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.access-card-account-copy span {
  color: #817873;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .12em;
  line-height: 1.1;
  text-transform: uppercase;
}

.access-card-account-copy strong {
  min-width: 0;
  overflow: hidden;
  color: #e3dbd5;
  font-size: 12px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-card-account i {
  padding: 4px 7px;
  border: 1px solid rgba(255,159,70,.14);
  border-radius: 999px;
  background: rgba(255,139,42,.045);
  color: #ffbd73;
  font-size: 9px;
  font-style: normal;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}


/* --- v0.15.1 access modal redesign --- */
.access-dialog {
  width: min(1220px, calc(100vw - 32px));
  max-width: 1220px;
  max-height: min(92vh, 940px);
  border-color: rgba(255,255,255,.11);
  border-radius: 20px;
  background: #12100f;
  overflow: auto;
  box-shadow: 0 38px 120px rgba(0,0,0,.68);
}

.access-modal {
  padding: 20px;
  background:
    radial-gradient(circle at 92% -10%, rgba(255,139,42,.10), transparent 26rem),
    linear-gradient(180deg, rgba(255,255,255,.012), transparent 16rem),
    #12100f;
}

.access-modal-header {
  align-items: center;
  padding-bottom: 16px;
  border-bottom-color: rgba(255,255,255,.065);
}

.access-modal-person {
  gap: 11px;
}

.access-modal-person .modal-avatar {
  width: 46px;
  height: 46px;
  flex-basis: 46px;
  border-radius: 13px;
}

.access-modal-person .eyebrow {
  color: #f1a84d;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.access-modal-person h2 {
  margin: 3px 0 2px;
  font-size: clamp(22px, 2.4vw, 29px);
  font-weight: 700;
  letter-spacing: -.03em;
}

.access-modal-person p {
  color: #8d847f;
  font-size: 13px;
}

.access-modal-head-actions .badge {
  min-height: 30px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.access-modal-service {
  margin: 14px 0;
  padding: 12px 14px 11px;
  border-color: rgba(255,159,70,.13);
  border-radius: 13px;
  background:
    linear-gradient(135deg, rgba(255,139,42,.055), rgba(255,255,255,.008)),
    rgba(0,0,0,.10);
}

.access-modal-service-copy {
  align-items: center;
  gap: 10px;
}

.access-modal-service-copy > span {
  color: #f4aa4f;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .11em;
}

.access-modal-service-copy > strong {
  color: #f5eee9;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .02em;
  text-transform: uppercase;
}

.access-modal-service-copy > small {
  color: #978e88;
  font-size: 12px;
}

.access-modal-service .service-meter.large {
  margin-top: 9px;
}

.access-detail-layout {
  display: grid;
  grid-template-columns: minmax(0,.88fr) minmax(430px,1.12fr);
  gap: 12px;
  align-items: start;
}

.access-detail-stack {
  display: grid;
  gap: 12px;
}

.access-detail-panel {
  padding: 14px;
  border-color: rgba(255,255,255,.07);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.018), rgba(255,255,255,.008)),
    rgba(20,17,15,.82);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.012);
}

.access-panel-heading,
.access-account-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 11px;
}

.access-panel-heading > div > span,
.access-account-title > div > span {
  display: block;
  margin-bottom: 3px;
  color: #837a74;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .10em;
  line-height: 1;
  text-transform: uppercase;
}

.access-panel-heading h3,
.access-account-title h3 {
  margin: 0;
  color: #f2ebe6;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -.01em;
}

.access-payment-pill {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
}

.access-payment-pill.paid {
  color: #91e3ae;
  border-color: rgba(85,214,139,.16);
  background: rgba(85,214,139,.045);
}

.access-payment-pill.pending {
  color: #f5d07e;
  border-color: rgba(248,199,94,.16);
  background: rgba(248,199,94,.045);
}

.access-payment-pill.gift {
  color: #c9baff;
  border-color: rgba(141,114,255,.16);
  background: rgba(141,114,255,.045);
}

.access-info-list,
.access-credential-list {
  display: grid;
  gap: 0;
  border-top: 1px solid rgba(255,255,255,.055);
}

.access-info-list > div,
.access-credential-list > div {
  min-height: 44px;
  display: grid;
  grid-template-columns: minmax(90px,.7fr) minmax(0,1.3fr);
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(255,255,255,.045);
}

.access-info-list span,
.access-credential-list > div > span {
  color: #8d847f;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.access-info-list strong,
.access-credential-list > div > strong,
.access-credential-list .assigned-password-line {
  min-width: 0;
  justify-self: end;
  color: #efe8e2;
  font-size: 13px;
  font-weight: 700;
  text-align: right;
  overflow-wrap: anywhere;
}

.access-secondary-action {
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-top: 11px;
  border: 1px solid rgba(85,214,139,.14);
  border-radius: 10px;
  background: rgba(85,214,139,.035);
  color: #9be5b4;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
  text-decoration: none;
}

.access-secondary-action:hover {
  border-color: rgba(85,214,139,.25);
  background: rgba(85,214,139,.065);
  color: #b9f0ca;
}

.access-commercial-summary {
  overflow: hidden;
}

.access-stat-grid {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 7px;
}

.access-stat-grid > div {
  min-width: 0;
  min-height: 64px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 9px 10px;
  border: 1px solid rgba(255,255,255,.055);
  border-radius: 10px;
  background: rgba(0,0,0,.10);
}

.access-stat-grid span,
.access-library-row > span {
  color: #827a75;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .10em;
  text-transform: uppercase;
}

.access-stat-grid strong {
  min-width: 0;
  overflow: hidden;
  color: #ede6e0;
  font-size: 13px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-library-row {
  display: grid;
  grid-template-columns: auto minmax(0,1fr);
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(255,255,255,.05);
}

.access-library-row > div {
  display: flex;
  justify-content: flex-end;
  gap: 5px;
  flex-wrap: wrap;
}

.access-library-row .tag {
  padding: 5px 8px;
  font-size: 12px;
}

.access-audit-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 9px;
  color: #6f6863;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.access-account-panel {
  position: relative;
  overflow: hidden;
  border-color: rgba(255,159,70,.13);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.09), transparent 17rem),
    linear-gradient(180deg, rgba(255,139,42,.025), rgba(255,255,255,.008)),
    rgba(20,17,15,.92);
}

.access-account-title {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.access-account-title .access-card-account-avatar {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 10px;
}

.access-account-heading .service-account-kind {
  min-height: 28px;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .07em;
}

.access-credential-list {
  border-top-color: rgba(255,159,70,.07);
}

.access-credential-list > div {
  min-height: 44px;
}

.access-share-actions {
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  gap: 8px;
  margin-top: 11px;
}

.access-share-button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 12px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 10px;
  background: rgba(255,255,255,.018);
  color: #d8d0ca;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .05em;
}

.access-share-button svg {
  width: 15px;
  height: 15px;
}

.access-share-button.primary {
  border-color: rgba(255,159,70,.18);
  background: rgba(255,139,42,.05);
  color: #ffc178;
}

.access-share-button.whatsapp {
  border-color: rgba(85,214,139,.17);
  background: rgba(85,214,139,.045);
  color: #9ce6b5;
}

.access-share-button:hover {
  transform: translateY(-1px);
  filter: brightness(1.08);
}

.access-share-button:disabled {
  opacity: .45;
  cursor: wait;
  transform: none;
}

.assigned-account-note {
  margin-top: 10px;
  padding: 9px 11px;
  border-radius: 9px;
  font-size: 12px;
}

.access-tv-card {
  margin-top: 10px;
  padding: 11px;
  border: 1px solid rgba(99,169,255,.12);
  border-radius: 11px;
  background: rgba(99,169,255,.025);
}

.access-tv-card-head {
  display: grid;
  grid-template-columns: 28px minmax(0,1fr);
  align-items: start;
  gap: 9px;
}

.access-tv-card-head strong,
.access-tv-card-head small {
  display: block;
}

.access-tv-card-head strong {
  color: #cfe4ff;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
}

.access-tv-card-head small {
  margin-top: 3px;
  color: #8c9eb0;
  font-size: 12px;
  line-height: 1.4;
}

.access-tv-card .access-tv-link-form {
  margin: 9px 0 0;
  padding: 0;
  border: 0;
  background: transparent;
}

.access-tv-card .access-tv-link-controls {
  grid-template-columns: 118px minmax(140px,1fr);
}

.access-tv-card .access-tv-link-controls input,
.access-tv-card .access-tv-link-controls .button {
  height: 36px;
  min-height: 36px;
}

.access-tv-card .access-tv-link-controls input {
  font-size: 14px;
}

.access-tv-card .access-tv-link-controls .button {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
}

.access-modal-actions.access-modal-icon-actions {
  margin-top: 13px;
  padding-top: 13px;
  border-top-color: rgba(255,255,255,.06);
}

.access-modal-icon-actions .admin-action-icon.compact {
  width: 36px;
  height: 36px;
  border-radius: 10px;
}

@media (max-width: 960px) {
  .access-dialog {
    width: min(820px, calc(100vw - 24px));
  }

  .access-detail-layout {
    grid-template-columns: 1fr;
  }

  .access-account-panel {
    grid-row: 1;
  }
}

@media (max-width: 620px) {
  .access-modal {
    padding: 14px;
  }

  .access-modal-header {
    align-items: flex-start;
  }

  .access-modal-person .modal-avatar {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
  }

  .access-stat-grid {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }

  .access-share-actions,
  .access-tv-card .access-tv-link-controls {
    grid-template-columns: 1fr;
  }

  .access-library-row {
    grid-template-columns: 1fr;
  }

  .access-library-row > div {
    justify-content: flex-start;
  }

  .access-audit-line {
    flex-direction: column;
    gap: 3px;
  }
}


/* --- v0.16 client CRM + international phones --- */
.country-code-input {
  font-variant-numeric: tabular-nums;
  letter-spacing: .03em;
}

.clients-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.clients-heading h1 {
  margin: 6px 0 5px;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1;
  letter-spacing: -.04em;
}

.clients-heading p {
  margin: 0;
  color: #a9a19b;
  font-size: 14px;
  line-height: 1.5;
}

.clients-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.clients-metrics article {
  min-width: 0;
  min-height: 106px;
  display: grid;
  align-content: end;
  gap: 5px;
  padding: 16px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 16px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,139,42,.055), transparent 10rem),
    linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.009)),
    var(--panel);
}

.clients-metrics article > span {
  color: #8b837d;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
}

.clients-metrics article > strong {
  min-width: 0;
  overflow: hidden;
  color: #f4ede8;
  font-size: 25px;
  font-weight: 750;
  letter-spacing: -.035em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.clients-metrics article > small {
  color: #8f8782;
  font-size: 12px;
}

.clients-metrics article.revenue {
  border-color: rgba(255,159,70,.14);
}

.clients-metrics article.revenue > strong {
  color: #ffc176;
  font-size: 19px;
}

.clients-toolbar {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding: 9px;
  border-radius: 15px;
}

.clients-search {
  min-width: min(420px, 42vw);
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 12px;
}

.clients-search > span {
  color: #8f8782;
  font-size: 18px;
}

.clients-search input {
  width: 100%;
  min-height: 38px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.clients-search input:focus {
  border: 0;
  box-shadow: none;
}

.clients-filters {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.client-filter {
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 999px;
  background: rgba(255,255,255,.018);
  color: #918984;
  cursor: pointer;
  font-size: 12px;
  font-weight: 750;
  letter-spacing: .045em;
}

.client-filter:hover {
  border-color: rgba(255,159,70,.17);
  color: #ddd5cf;
}

.client-filter.active {
  border-color: rgba(255,159,70,.27);
  background: linear-gradient(135deg, #ff932f, #ffc060);
  color: #1a1008;
}

.clients-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px,1fr));
  gap: 12px;
}

.client-crm-card {
  min-width: 0;
  padding: 16px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 17px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.055), transparent 12rem),
    linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.009)),
    var(--panel);
  box-shadow: 0 15px 36px rgba(0,0,0,.14);
}

.client-crm-head {
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 11px;
}

.client-crm-avatar {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,159,70,.17);
  border-radius: 13px;
  background: linear-gradient(135deg, rgba(255,139,42,.20), rgba(141,114,255,.10));
  color: #ffc176;
  font-size: 16px;
  font-weight: 800;
}

.client-crm-title {
  min-width: 0;
}

.client-crm-title > span {
  color: #817973;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .09em;
}

.client-crm-title h3 {
  margin: 2px 0 2px;
  overflow: hidden;
  color: #f2ebe5;
  font-size: 17px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-crm-title p {
  margin: 0;
  overflow: hidden;
  color: #918984;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-product-status {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .045em;
  white-space: nowrap;
}

.client-product-status.active {
  color: #91e3ae;
  border-color: rgba(85,214,139,.17);
  background: rgba(85,214,139,.05);
}

.client-product-status.inactive {
  color: #9a928d;
  background: rgba(255,255,255,.02);
}

.client-crm-contact {
  min-height: 46px;
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  align-items: center;
  gap: 10px;
  margin-top: 13px;
  padding: 9px 10px;
  border: 1px solid rgba(255,255,255,.055);
  border-radius: 11px;
  background: rgba(0,0,0,.10);
}

.client-crm-contact span,
.client-crm-stats span,
.client-active-label,
.client-crm-footer > span {
  color: #817973;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .065em;
}

.client-crm-contact strong {
  display: block;
  margin-top: 2px;
  color: #e3dcd6;
  font-size: 13px;
}

.client-crm-contact a {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(85,214,139,.15);
  border-radius: 9px;
  background: rgba(85,214,139,.04);
  color: #9be6b4;
  font-size: 15px;
  text-decoration: none;
}

.client-crm-stats {
  display: grid;
  grid-template-columns: 1.3fr .7fr .8fr;
  gap: 7px;
  margin-top: 9px;
}

.client-crm-stats > div {
  min-width: 0;
  min-height: 62px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 9px 10px;
  border: 1px solid rgba(255,255,255,.05);
  border-radius: 10px;
  background: rgba(0,0,0,.08);
}

.client-crm-stats strong {
  min-width: 0;
  overflow: hidden;
  color: #eee7e1;
  font-size: 13px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-active-products {
  margin-top: 11px;
  padding-top: 11px;
  border-top: 1px solid rgba(255,255,255,.055);
}

.client-active-label {
  display: block;
  margin-bottom: 6px;
  color: #f1a84d;
}

.client-active-product {
  min-height: 50px;
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border: 1px solid rgba(255,159,70,.09);
  border-radius: 10px;
  background: rgba(255,139,42,.025);
  text-decoration: none;
}

.client-active-product + .client-active-product {
  margin-top: 6px;
}

.client-active-product strong {
  display: block;
  color: #f0e8e2;
  font-size: 13px;
}

.client-active-product small {
  display: block;
  margin-top: 2px;
  color: #918983;
  font-size: 12px;
}

.client-active-product > span {
  color: #91e3ae;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .04em;
}

.client-more-products {
  display: block;
  margin-top: 7px;
  color: #8f8782;
  font-size: 12px;
}

.client-no-product {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 11px;
  padding: 10px;
  border: 1px dashed rgba(255,255,255,.075);
  border-radius: 10px;
  color: #8f8782;
}

.client-no-product > span {
  color: #706965;
  font-size: 20px;
}

.client-no-product p {
  margin: 0;
  font-size: 12px;
  line-height: 1.45;
}

.client-crm-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 11px;
  padding-top: 11px;
  border-top: 1px solid rgba(255,255,255,.055);
}

.client-crm-footer > span {
  color: #746d68;
}

.client-crm-footer a {
  color: #ffb96c;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.clients-empty {
  min-height: 300px;
}

@media (max-width: 1050px) {
  .clients-metrics {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
}

@media (max-width: 760px) {
  .clients-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .clients-search {
    min-width: 0;
    width: 100%;
  }

  .clients-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .clients-metrics {
    grid-template-columns: 1fr 1fr;
  }

  .clients-metrics article {
    min-height: 92px;
    padding: 13px;
  }

  .clients-metrics article > strong {
    font-size: 21px;
  }

  .client-crm-head {
    grid-template-columns: auto minmax(0,1fr);
  }

  .client-product-status {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .client-crm-stats {
    grid-template-columns: 1fr;
  }

  .client-crm-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}


/* --- v0.16.1 Plex automatic account test --- */
.plex-auto-test-button {
  border-color: rgba(108,183,255,.20) !important;
  background: rgba(108,183,255,.05) !important;
  color: #a8d6ff !important;
}

.plex-auto-test-button:hover {
  border-color: rgba(108,183,255,.34) !important;
  background: rgba(108,183,255,.09) !important;
  color: #d4ebff !important;
}

.plex-auto-test-dialog {
  width: min(760px, calc(100vw - 32px));
  max-width: 760px;
}

.plex-auto-test-identity {
  display: grid;
  grid-template-columns: .8fr 1.2fr 1fr;
  gap: 8px;
  margin-top: 16px;
}

.plex-auto-test-identity > div {
  min-width: 0;
  min-height: 68px;
  display: grid;
  align-content: center;
  gap: 5px;
  padding: 11px 12px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 11px;
  background: rgba(0,0,0,.12);
}

.plex-auto-test-identity span {
  color: #8b837d;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .07em;
}

.plex-auto-test-identity strong {
  min-width: 0;
  overflow: hidden;
  color: #f0e9e3;
  font-size: 13px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.plex-auto-test-settings {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 10px;
}

.plex-auto-test-setting {
  min-height: 76px;
  display: grid;
  grid-template-columns: 30px minmax(0,1fr);
  align-items: start;
  gap: 9px;
  padding: 11px;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 11px;
  background: rgba(255,255,255,.012);
}

.plex-auto-test-setting > span {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(108,183,255,.16);
  border-radius: 9px;
  background: rgba(108,183,255,.045);
  color: #a8d6ff;
  font-size: 12px;
  font-weight: 800;
}

.plex-auto-test-setting strong,
.plex-auto-test-setting small {
  display: block;
}

.plex-auto-test-setting strong {
  color: #e9e3de;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .035em;
}

.plex-auto-test-setting small {
  margin-top: 4px;
  color: #948c86;
  font-size: 12px;
  line-height: 1.45;
}

.plex-auto-test-note {
  margin-top: 10px;
  border-color: rgba(248,199,94,.13);
  background: rgba(248,199,94,.035);
  color: #b8a477;
}

.plex-auto-test-submit {
  border-color: rgba(108,183,255,.22) !important;
  background: linear-gradient(135deg, #75bfff, #a9d8ff) !important;
  color: #0b1721 !important;
}

.service-account-card.plex-auto-generated {
  border-color: rgba(108,183,255,.35);
  box-shadow:
    0 0 0 3px rgba(108,183,255,.055),
    0 18px 46px rgba(0,0,0,.25);
  animation: plex-auto-card-pulse 1.5s ease-out 1;
}

@keyframes plex-auto-card-pulse {
  0% {
    box-shadow:
      0 0 0 0 rgba(108,183,255,.22),
      0 18px 46px rgba(0,0,0,.25);
  }
  100% {
    box-shadow:
      0 0 0 10px rgba(108,183,255,0),
      0 18px 46px rgba(0,0,0,.25);
  }
}

@media (max-width: 700px) {
  .plex-auto-test-identity,
  .plex-auto-test-settings {
    grid-template-columns: 1fr;
  }
}


/* --- v0.16.2 Plex normalization --- */
.inline-action-form {
  display: inline-flex;
  margin: 0;
}

.plex-normalize-button {
  border-color: rgba(108,183,255,.20) !important;
  background: rgba(108,183,255,.045) !important;
  color: #a9d7ff !important;
}

.plex-normalize-button:hover {
  border-color: rgba(108,183,255,.34) !important;
  background: rgba(108,183,255,.09) !important;
  color: #d8eeff !important;
}


/* --- v0.16.15 clients aligned with accounts module --- */
.clients-metrics.accounts-overview {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.clients-metrics .account-metric {
  min-height: 126px;
  display: flex;
  flex-direction: column;
  align-content: initial;
  gap: 0;
  padding: 17px 18px;
  border-color: rgba(255,255,255,.075);
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.09), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018);
}

.clients-metrics .account-metric.sale {
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.12), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
}

.clients-metrics .account-metric > strong {
  margin-top: 18px;
  color: #f6efe9;
  font-size: 34px;
  font-weight: 600;
  letter-spacing: -.045em;
}

.clients-metrics .account-metric.revenue > strong {
  color: #ffc176;
  font-size: 26px;
}

.clients-metrics .account-metric > small {
  margin-top: 6px;
  color: #68615d;
  font-size: 12px;
}

.clients-toolbar {
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
  padding: 9px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 17px;
  background: linear-gradient(180deg, rgba(255,255,255,.024), rgba(255,255,255,.012));
}

.clients-search {
  width: clamp(300px, 34vw, 430px);
  min-width: 0;
  min-height: 42px;
  flex: 0 1 430px;
  display: grid;
  grid-template-columns: 22px minmax(0,1fr);
  gap: 8px;
  align-items: center;
  padding: 0 12px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  background: rgba(0,0,0,.16);
}

.clients-search svg {
  width: 18px;
  height: 18px;
  color: #756e69;
}

.clients-search input {
  width: 100%;
  min-width: 0;
  height: 40px;
  min-height: 40px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #ede6e0;
  box-shadow: none;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .035em;
}

.clients-search input::placeholder {
  color: #5f5955;
}

.clients-search input:focus {
  border: 0;
  outline: 0;
  box-shadow: none;
}

.clients-filters {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
  flex-wrap: wrap;
}

.client-filter {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 999px;
  background: rgba(255,255,255,.018);
  color: #8d8580;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.client-filter:hover {
  border-color: rgba(255,159,70,.16);
  color: #d7cfc9;
}

.client-filter.active {
  border-color: rgba(255,164,73,.38);
  background: linear-gradient(135deg, #ff932f, #ffc361);
  color: #1a0e05;
  box-shadow: 0 8px 22px rgba(255,139,42,.12);
}

.clients-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px,1fr));
  gap: 12px;
  align-items: start;
}

.client-crm-card {
  min-width: 0;
  min-height: 0;
  padding: 15px;
  border: 1px solid rgba(255,159,70,.16);
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.105), transparent 13rem),
    linear-gradient(160deg, rgba(145,80,27,.045), rgba(255,255,255,.010));
  box-shadow:
    inset 3px 0 0 rgba(255,159,70,.38),
    inset 0 1px 0 rgba(255,255,255,.018);
}

.client-crm-card.active {
  border-color: rgba(85,214,139,.16);
  background:
    radial-gradient(circle at 100% 0%, rgba(85,214,139,.075), transparent 13rem),
    linear-gradient(160deg, rgba(47,116,75,.035), rgba(255,255,255,.010));
  box-shadow:
    inset 3px 0 0 rgba(85,214,139,.34),
    inset 0 1px 0 rgba(255,255,255,.018);
}

.client-crm-card:hover {
  border-color: rgba(255,159,70,.27);
}

.client-crm-card.active:hover {
  border-color: rgba(85,214,139,.28);
}

.client-crm-head {
  gap: 10px;
}

.client-crm-avatar {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  font-weight: 700;
}

.client-crm-title > span,
.client-crm-contact span,
.client-crm-stats span,
.client-active-label,
.client-crm-footer > span {
  font-weight: 600;
  letter-spacing: .055em;
}

.client-crm-title h3 {
  margin: 2px 0;
  font-size: 17px;
  font-weight: 600;
}

.client-product-status {
  min-height: 23px;
  padding: 0 8px;
  font-size: 12px;
  font-weight: 600;
}

.client-crm-contact {
  min-height: 38px;
  margin-top: 10px;
  padding: 7px 9px;
  border-color: rgba(255,255,255,.06);
  border-radius: 11px;
  background: rgba(0,0,0,.13);
}

.client-crm-contact a {
  width: 30px;
  height: 30px;
  border-radius: 9px;
}

.client-crm-stats {
  grid-template-columns: 1.25fr .75fr .9fr;
  gap: 6px;
  margin-top: 6px;
}

.client-crm-stats > div {
  min-height: 54px;
  padding: 8px 9px;
  border-color: rgba(255,255,255,.055);
  border-radius: 10px;
  background: rgba(0,0,0,.10);
}

.client-active-products {
  margin-top: 10px;
  padding-top: 10px;
}

.client-active-product {
  min-height: 46px;
  padding: 7px 9px;
  border-radius: 10px;
  background: rgba(255,139,42,.025);
}

.client-no-product {
  min-height: 50px;
  margin-top: 10px;
  padding: 9px;
}

.client-crm-footer {
  margin-top: 10px;
  padding-top: 10px;
}

.clients-empty {
  min-height: 270px;
  border-radius: 20px;
}

@media (max-width: 1050px) {
  .clients-metrics.accounts-overview {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 920px) {
  .clients-toolbar {
    flex-wrap: wrap;
  }

  .clients-search {
    width: 100%;
    flex: 1 1 100%;
  }

  .clients-filters {
    width: 100%;
    justify-content: flex-start;
  }
}

@media (max-width: 640px) {
  .clients-filters {
    overflow-x: auto;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }

  .clients-filters::-webkit-scrollbar {
    display: none;
  }

  .clients-grid {
    grid-template-columns: 1fr;
  }

  .client-crm-stats {
    grid-template-columns: repeat(3, minmax(0,1fr));
  }
}

@media (max-width: 520px) {
  .clients-metrics.accounts-overview {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .clients-metrics .account-metric {
    min-height: 112px;
    padding: 14px;
  }

  .clients-metrics .account-metric > strong {
    font-size: 29px;
  }

  .clients-metrics .account-metric.revenue > strong {
    font-size: 21px;
  }

  .client-crm-head {
    grid-template-columns: auto minmax(0,1fr);
  }

  .client-product-status {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .client-crm-stats {
    grid-template-columns: 1fr;
  }

  .client-crm-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}


/* --- v0.16.17 manual account status refresh --- */
.account-status-refresh-button {
  border-color: rgba(85,214,139,.18) !important;
  background: rgba(85,214,139,.045) !important;
  color: #91e3ae !important;
}

.account-status-refresh-button:hover {
  border-color: rgba(85,214,139,.32) !important;
  background: rgba(85,214,139,.085) !important;
  color: #c4f2d4 !important;
}

.account-status-refresh-button.is-loading {
  cursor: wait;
  opacity: .72;
}

.account-status-refresh-button.is-loading svg {
  animation: account-status-refresh-spin .8s linear infinite;
}

@keyframes account-status-refresh-spin {
  to { transform: rotate(360deg); }
}


/* --- v0.16.18 clearer account toolbar actions --- */
.account-toolbar-actions {
  gap: 8px;
}

.account-toolbar-actions .inline-action-form {
  display: inline-flex;
}

.account-toolbar-action {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 13px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 11px;
  background: rgba(255,255,255,.02);
  color: #ddd6d0;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .055em;
  white-space: nowrap;
  box-shadow: 0 8px 20px rgba(0,0,0,.12);
  transition: transform .16s ease, border-color .16s ease, background .16s ease, color .16s ease;
}

.account-toolbar-action:hover {
  transform: translateY(-1px);
}

.account-toolbar-action:disabled {
  cursor: wait;
  opacity: .68;
  transform: none;
}

.account-toolbar-action svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}

.account-toolbar-action.account-status-refresh-button {
  border-color: rgba(85,214,139,.24) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.11), rgba(85,214,139,.045)) !important;
  color: #a8ecc0 !important;
}

.account-toolbar-action.account-status-refresh-button:hover {
  border-color: rgba(85,214,139,.42) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.17), rgba(85,214,139,.07)) !important;
  color: #d4f7df !important;
}

.account-toolbar-action.plex-auto-test-button {
  border-color: rgba(108,183,255,.28) !important;
  background: linear-gradient(135deg, rgba(108,183,255,.14), rgba(108,183,255,.055)) !important;
  color: #b8ddff !important;
}

.account-toolbar-action.plex-auto-test-button:hover {
  border-color: rgba(108,183,255,.46) !important;
  background: linear-gradient(135deg, rgba(108,183,255,.21), rgba(108,183,255,.085)) !important;
  color: #e0f1ff !important;
}

.account-status-refresh-button.is-loading svg {
  animation: account-status-refresh-spin .8s linear infinite;
}

@media (max-width: 760px) {
  .account-toolbar-actions {
    width: 100%;
    justify-content: flex-end;
  }
}

@media (max-width: 520px) {
  .account-toolbar-action {
    min-height: 38px;
    padding: 0 10px;
    font-size: 11px;
    gap: 6px;
  }
}


/* --- v0.16.19 Glide-style collapsible admin sidebar --- */
:root {
  --admin-sidebar-width: 264px;
  --admin-sidebar-collapsed-width: 78px;
}

body.app-shell {
  overflow-x: hidden;
}

.admin-layout-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: var(--admin-sidebar-width) minmax(0, 1fr);
  background: #0c0b0b;
  transition: grid-template-columns .22s ease;
}

.admin-layout-shell.sidebar-collapsed {
  grid-template-columns: var(--admin-sidebar-collapsed-width) minmax(0, 1fr);
}

.admin-sidebar {
  position: sticky;
  top: 0;
  z-index: 80;
  height: 100vh;
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 14px 12px 12px;
  overflow: hidden;
  border-right: 1px solid rgba(255,255,255,.075);
  background:
    radial-gradient(circle at 18% 0%, rgba(255,145,47,.08), transparent 17rem),
    linear-gradient(180deg, rgba(18,15,13,.98), rgba(11,10,10,.98));
  box-shadow: 18px 0 42px rgba(0,0,0,.15);
}

.admin-sidebar-head {
  position: relative;
  min-height: 58px;
  display: flex;
  align-items: center;
  padding: 0 5px 12px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.admin-sidebar-brand {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #f1ebe6;
  text-decoration: none;
}

.admin-sidebar-brand-avatar {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(255,159,70,.22);
  border-radius: 13px;
  background: #ffad3f;
  box-shadow: 0 10px 25px rgba(255,139,42,.09);
}

.admin-sidebar-brand-avatar img,
.admin-sidebar-user-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.admin-sidebar-brand-copy,
.admin-sidebar-user-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
  overflow: hidden;
  white-space: nowrap;
  transition: opacity .16s ease, width .2s ease, transform .2s ease;
}

.admin-sidebar-brand-copy strong {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -.02em;
}

.admin-sidebar-brand-copy small {
  color: #756e69;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.admin-sidebar-collapse {
  position: absolute;
  top: 18px;
  right: -25px;
  z-index: 4;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 9px;
  background: #171412;
  color: #a79f99;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(0,0,0,.28);
  transition: border-color .16s ease, color .16s ease, background .16s ease, transform .22s ease;
}

.admin-sidebar-collapse:hover {
  border-color: rgba(255,159,70,.26);
  background: #201913;
  color: #ffc176;
}

.admin-sidebar-collapse svg {
  width: 15px;
  height: 15px;
  transition: transform .22s ease;
}

.admin-side-nav {
  min-height: 0;
  display: grid;
  gap: 4px;
  margin-top: 12px;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: none;
}

.admin-side-nav::-webkit-scrollbar {
  display: none;
}

.admin-side-nav a,
.admin-side-secondary,
.admin-sidebar-logout button {
  min-width: 0;
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 0 11px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  color: #a9a19b;
  text-decoration: none;
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .045em;
  white-space: nowrap;
  transition: background .16s ease, border-color .16s ease, color .16s ease, transform .16s ease;
}

.admin-side-nav a:hover,
.admin-side-secondary:hover,
.admin-sidebar-logout button:hover {
  border-color: rgba(255,255,255,.055);
  background: rgba(255,255,255,.035);
  color: #eee7e1;
}

.admin-side-nav a.active {
  border-color: rgba(255,159,70,.20);
  background:
    linear-gradient(90deg, rgba(255,139,42,.15), rgba(255,139,42,.035));
  color: #ffc176;
  box-shadow: inset 3px 0 0 rgba(255,159,70,.60);
}

.admin-side-icon {
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: rgba(255,255,255,.025);
  color: currentColor;
}

.admin-side-icon svg {
  width: 18px;
  height: 18px;
}

.admin-side-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: opacity .14s ease, width .2s ease, transform .2s ease;
}

.admin-sidebar-bottom {
  display: grid;
  gap: 6px;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,.06);
}

.admin-side-secondary {
  width: 100%;
}

.admin-sidebar-user {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 50px;
  padding: 7px 9px;
  border: 1px solid rgba(255,255,255,.055);
  border-radius: 12px;
  background: rgba(255,255,255,.018);
}

.admin-sidebar-user-avatar {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  overflow: hidden;
  border-radius: 10px;
  background: #fff;
}

.admin-sidebar-user-copy strong,
.admin-sidebar-user-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-sidebar-user-copy strong {
  color: #e7dfd9;
  font-size: 12px;
  font-weight: 650;
}

.admin-sidebar-user-copy small {
  color: #756e69;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.admin-sidebar-logout,
.admin-sidebar-logout button {
  width: 100%;
  margin: 0;
}

.admin-sidebar-logout button {
  color: #8f8782;
}

.admin-shell-main {
  min-width: 0;
  min-height: 100vh;
}

.admin-topbar.admin-topbar-side {
  position: sticky;
  top: 0;
  z-index: 50;
  height: 64px;
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  grid-template-columns: none;
  grid-template-areas: none;
  gap: 16px;
  padding: 0 clamp(18px, 2.2vw, 34px);
  border-bottom: 1px solid rgba(255,255,255,.065);
  background: rgba(12,11,10,.86);
  backdrop-filter: blur(18px);
}

.admin-topbar-page {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.admin-topbar-page > div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.admin-topbar-page strong {
  overflow: hidden;
  color: #efe8e2;
  font-size: 15px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-topbar-page small {
  color: #6e6763;
  font-size: 10px;
  font-weight: 650;
  letter-spacing: .09em;
  white-space: nowrap;
}

.admin-mobile-menu {
  width: 38px;
  height: 38px;
  display: none;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  background: rgba(255,255,255,.025);
  color: #cfc7c1;
  cursor: pointer;
}

.admin-mobile-menu svg {
  width: 18px;
  height: 18px;
}

.admin-topbar-side .admin-topbar-actions {
  margin-left: auto;
  justify-self: auto;
}

.admin-topbar-side .admin-site-link {
  display: grid;
}

.admin-page,
body.app-shell .page {
  width: min(1720px, calc(100% - 48px));
  margin: 0 auto;
  padding: 26px 0 54px;
}

.admin-sidebar-backdrop {
  display: none;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar {
  padding-inline: 10px;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-brand-copy,
.admin-layout-shell.sidebar-collapsed .admin-sidebar-user-copy,
.admin-layout-shell.sidebar-collapsed .admin-side-label {
  width: 0;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-5px);
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-head {
  justify-content: center;
  padding-inline: 0;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-brand {
  justify-content: center;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-collapse {
  right: -24px;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-collapse svg {
  transform: rotate(180deg);
}

.admin-layout-shell.sidebar-collapsed .admin-side-nav a,
.admin-layout-shell.sidebar-collapsed .admin-side-secondary,
.admin-layout-shell.sidebar-collapsed .admin-sidebar-logout button {
  justify-content: center;
  gap: 0;
  padding-inline: 0;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-user {
  justify-content: center;
  padding-inline: 0;
}

.admin-layout-shell.sidebar-collapsed .admin-side-nav a.active {
  box-shadow: inset 0 0 0 1px rgba(255,159,70,.12);
}

@media (max-width: 1100px) and (min-width: 821px) {
  :root {
    --admin-sidebar-width: 238px;
  }

  .admin-topbar-page small {
    display: none;
  }
}

@media (max-width: 820px) {
  .admin-layout-shell,
  .admin-layout-shell.sidebar-collapsed {
    display: block;
  }

  .admin-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 130;
    width: min(280px, calc(100vw - 42px));
    height: 100dvh;
    transform: translateX(-102%);
    transition: transform .22s ease;
    box-shadow: 24px 0 65px rgba(0,0,0,.46);
  }

  .admin-layout-shell.sidebar-mobile-open .admin-sidebar {
    transform: translateX(0);
  }

  .admin-sidebar-collapse {
    right: 10px;
    top: 20px;
  }

  .admin-sidebar-collapse svg {
    transform: none !important;
  }

  .admin-layout-shell.sidebar-collapsed .admin-sidebar-brand-copy,
  .admin-layout-shell.sidebar-collapsed .admin-sidebar-user-copy,
  .admin-layout-shell.sidebar-collapsed .admin-side-label {
    width: auto;
    opacity: 1;
    pointer-events: auto;
    transform: none;
  }

  .admin-layout-shell.sidebar-collapsed .admin-side-nav a,
  .admin-layout-shell.sidebar-collapsed .admin-side-secondary,
  .admin-layout-shell.sidebar-collapsed .admin-sidebar-logout button {
    justify-content: flex-start;
    gap: 11px;
    padding-inline: 11px;
  }

  .admin-layout-shell.sidebar-collapsed .admin-sidebar-user {
    justify-content: flex-start;
    padding-inline: 9px;
  }

  .admin-sidebar-backdrop {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: block;
    border: 0;
    background: rgba(0,0,0,.58);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
  }

  .admin-layout-shell.sidebar-mobile-open .admin-sidebar-backdrop {
    opacity: 1;
    pointer-events: auto;
  }

  .admin-mobile-menu {
    display: grid;
  }

  .admin-topbar.admin-topbar-side {
    min-height: 62px;
    height: 62px;
    padding: 0 14px;
  }

  .admin-topbar-side .admin-site-link {
    display: none;
  }

  .admin-page,
  body.app-shell .page {
    width: min(100% - 28px, 1720px);
    padding-top: 20px;
  }
}

@media (max-width: 560px) {
  .admin-topbar-page small {
    display: none;
  }

  .admin-topbar-page strong {
    font-size: 14px;
  }

  .admin-topbar-side .admin-new-access {
    width: 38px;
    height: 38px;
    padding: 0;
    overflow: hidden;
    color: transparent;
    position: relative;
  }

  .admin-topbar-side .admin-new-access::after {
    content: "+";
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #ffd6a3;
    font-size: 20px;
    font-weight: 800;
  }

  .admin-page,
  body.app-shell .page {
    width: min(100% - 20px, 1720px);
  }
}


/* --- v0.16.20 sidebar proportions + collapse control polish --- */
:root {
  --admin-sidebar-width: 252px;
  --admin-sidebar-collapsed-width: 62px;
}

.admin-sidebar {
  overflow: visible;
  padding-left: 11px;
  padding-right: 11px;
}

.admin-sidebar-collapse {
  top: 20px;
  right: -16px;
  z-index: 120;
  width: 32px;
  height: 32px;
  border-color: rgba(255,159,70,.18);
  border-radius: 10px;
  background: #171412;
  color: #c1b8b1;
  box-shadow:
    0 8px 22px rgba(0,0,0,.38),
    0 0 0 4px rgba(12,11,10,.88);
}

.admin-sidebar-collapse:hover {
  border-color: rgba(255,159,70,.38);
  background: #241a13;
  color: #ffd09b;
}

.admin-sidebar-collapse svg {
  width: 17px;
  height: 17px;
}

.admin-side-icon {
  width: 30px;
  height: 30px;
  flex-basis: 30px;
}

.admin-side-icon svg {
  width: 19px;
  height: 19px;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar {
  padding-left: 7px;
  padding-right: 7px;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-head {
  min-height: 58px;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-brand-avatar {
  width: 38px;
  height: 38px;
  flex-basis: 38px;
  border-radius: 11px;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-collapse {
  right: -16px;
}

.admin-layout-shell.sidebar-collapsed .admin-side-nav {
  gap: 5px;
}

.admin-layout-shell.sidebar-collapsed .admin-side-nav a,
.admin-layout-shell.sidebar-collapsed .admin-side-secondary,
.admin-layout-shell.sidebar-collapsed .admin-sidebar-logout button {
  min-height: 46px;
  border-radius: 11px;
}

.admin-layout-shell.sidebar-collapsed .admin-side-icon {
  width: 36px;
  height: 36px;
  flex-basis: 36px;
  border-radius: 11px;
  background: rgba(255,255,255,.035);
}

.admin-layout-shell.sidebar-collapsed .admin-side-icon svg {
  width: 22px;
  height: 22px;
}

.admin-layout-shell.sidebar-collapsed .admin-side-nav a.active {
  border-color: rgba(255,159,70,.22);
  background: rgba(255,139,42,.10);
  box-shadow:
    inset 0 0 0 1px rgba(255,159,70,.06),
    0 8px 20px rgba(0,0,0,.12);
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-user {
  min-height: 46px;
  padding: 5px 0;
  border-color: transparent;
  background: transparent;
}

.admin-layout-shell.sidebar-collapsed .admin-sidebar-user-avatar {
  width: 36px;
  height: 36px;
  flex-basis: 36px;
}

@media (max-width: 1100px) and (min-width: 821px) {
  :root {
    --admin-sidebar-width: 236px;
  }
}

@media (max-width: 820px) {
  .admin-sidebar {
    overflow: hidden;
    padding-left: 12px;
    padding-right: 12px;
  }

  .admin-sidebar-collapse {
    right: 10px;
    box-shadow: 0 8px 20px rgba(0,0,0,.28);
  }
}


/* --- v0.16.21 keep sidebar toggle clear of the logo --- */
.admin-sidebar-collapse,
.admin-layout-shell.sidebar-collapsed .admin-sidebar-collapse {
  top: 68px;
  right: -16px;
}

@media (max-width: 820px) {
  .admin-sidebar-collapse,
  .admin-layout-shell.sidebar-collapsed .admin-sidebar-collapse {
    top: 20px;
    right: 10px;
  }
}


/* --- v0.16.22 accesses aligned with accounts module --- */
.access-overview {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.access-metric {
  min-height: 126px;
  display: flex;
  flex-direction: column;
  padding: 17px 18px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 18px;
  background:
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018);
}

.access-metric.active {
  border-color: rgba(85,214,139,.16);
  background:
    radial-gradient(circle at 100% 0%, rgba(85,214,139,.12), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
}

.access-metric.expired {
  border-color: rgba(255,107,107,.17);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,107,107,.12), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
}

.access-metric-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.access-metric-top span,
.access-metric small {
  color: #827a75;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .065em;
  text-transform: uppercase;
}

.access-metric-top i {
  color: #554f4b;
  font-size: 12px;
  font-style: normal;
  font-weight: 650;
}

.access-metric strong {
  margin-top: 17px;
  color: #f6efe9;
  font-size: 34px;
  font-weight: 600;
  letter-spacing: -.045em;
}

.access-metric.active strong {
  color: #a8ecc0;
}

.access-metric.expired strong {
  color: #ffaaa7;
}

.access-metric small {
  margin-top: 6px;
  color: #68615d;
  text-transform: none;
  letter-spacing: 0;
}

.access-toolbar.card {
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
  padding: 9px;
  border-color: rgba(255,255,255,.075);
  border-radius: 17px;
  background: linear-gradient(180deg, rgba(255,255,255,.024), rgba(255,255,255,.012));
}

.access-search {
  width: clamp(300px, 34vw, 430px);
  min-width: 0;
  min-height: 42px;
  flex: 0 1 430px;
  display: grid;
  grid-template-columns: 22px minmax(0,1fr);
  gap: 8px;
  align-items: center;
  padding: 0 12px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  background: rgba(0,0,0,.16);
}

.access-search > svg {
  width: 18px;
  height: 18px;
  color: #756e69;
}

.access-search input {
  width: 100%;
  min-width: 0;
  height: 40px;
  min-height: 40px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #ede6e0;
  box-shadow: none;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .03em;
}

.access-search input::placeholder {
  color: #5f5955;
}

.access-search input:focus {
  border: 0;
  outline: 0;
  box-shadow: none;
}

.access-toolbar-right {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  flex: 1 1 auto;
}

.access-filters {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
  flex-wrap: wrap;
}

.access-filter {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 999px;
  background: rgba(255,255,255,.018);
  color: #8d8580;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: .055em;
}

.access-filter:hover {
  border-color: rgba(255,159,70,.16);
  color: #d7cfc9;
}

.access-filter.active {
  border-color: rgba(255,164,73,.38);
  background: linear-gradient(135deg, #ff932f, #ffc361);
  color: #1a0e05;
  box-shadow: 0 8px 22px rgba(255,139,42,.12);
}

.access-filter.payment-filter:not(.active) {
  border-color: rgba(248,199,94,.14);
  color: #b8a477;
}

.access-toolbar-actions {
  gap: 8px;
}

.access-refresh-button {
  border-color: rgba(85,214,139,.24) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.11), rgba(85,214,139,.045)) !important;
  color: #a8ecc0 !important;
}

.access-refresh-button:hover {
  border-color: rgba(85,214,139,.42) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.17), rgba(85,214,139,.07)) !important;
  color: #d4f7df !important;
}

.access-create-button {
  border-color: rgba(108,183,255,.28) !important;
  background: linear-gradient(135deg, rgba(108,183,255,.14), rgba(108,183,255,.055)) !important;
  color: #b8ddff !important;
}

.access-create-button:hover {
  border-color: rgba(108,183,255,.46) !important;
  background: linear-gradient(135deg, rgba(108,183,255,.21), rgba(108,183,255,.085)) !important;
  color: #e0f1ff !important;
}

.access-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 12px;
  align-items: start;
}

.access-client-card {
  min-width: 0;
  min-height: 0;
  padding: 15px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 18px;
  background:
    linear-gradient(160deg, rgba(255,255,255,.026), rgba(255,255,255,.011));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.018),
    0 14px 35px rgba(0,0,0,.10);
  transition: transform .17s ease, border-color .17s ease, background .17s ease, box-shadow .17s ease;
}

.access-client-card:hover {
  transform: translateY(-2px);
}

.access-client-card.active {
  border-color: rgba(85,214,139,.18);
  background:
    radial-gradient(circle at 100% 0%, rgba(85,214,139,.10), transparent 13rem),
    linear-gradient(160deg, rgba(42,105,67,.035), rgba(255,255,255,.010));
  box-shadow:
    inset 3px 0 0 rgba(85,214,139,.40),
    inset 0 1px 0 rgba(255,255,255,.018),
    0 14px 35px rgba(0,0,0,.10);
}

.access-client-card.active:hover {
  border-color: rgba(85,214,139,.30);
}

.access-client-card.ended {
  border-color: rgba(255,107,107,.19);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,107,107,.105), transparent 13rem),
    linear-gradient(160deg, rgba(122,44,44,.038), rgba(255,255,255,.010));
  box-shadow:
    inset 3px 0 0 rgba(255,107,107,.42),
    inset 0 1px 0 rgba(255,255,255,.018),
    0 14px 35px rgba(0,0,0,.10);
}

.access-client-card.ended:hover {
  border-color: rgba(255,107,107,.31);
}

.access-client-card.pending,
.access-client-card.error {
  border-color: rgba(248,199,94,.16);
  background:
    radial-gradient(circle at 100% 0%, rgba(248,199,94,.09), transparent 13rem),
    linear-gradient(160deg, rgba(121,95,35,.035), rgba(255,255,255,.010));
  box-shadow:
    inset 3px 0 0 rgba(248,199,94,.32),
    inset 0 1px 0 rgba(255,255,255,.018),
    0 14px 35px rgba(0,0,0,.10);
}

.access-card-top {
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.access-card-identity {
  min-width: 0;
}

.access-card-identity h3 {
  margin: 2px 0 0;
  overflow: hidden;
  color: #f2ebe5;
  font-size: 17px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-card-eyebrow {
  color: #827a75;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
}

.access-card-badges {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 5px;
  flex-wrap: wrap;
}

.access-status-pill,
.access-payment-novelty {
  min-height: 23px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 999px;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: .045em;
  white-space: nowrap;
}

.access-status-pill.active {
  color: #8deab0;
  border-color: rgba(85,214,139,.22);
  background: rgba(85,214,139,.07);
}

.access-status-pill.ended {
  color: #ffaaa7;
  border-color: rgba(255,107,107,.22);
  background: rgba(255,107,107,.07);
}

.access-status-pill.pending,
.access-status-pill.error {
  color: #f7d27a;
  border-color: rgba(248,199,94,.22);
  background: rgba(248,199,94,.07);
}

.access-payment-novelty {
  color: #ffd681;
  border-color: rgba(255,190,62,.28);
  background:
    linear-gradient(135deg, rgba(255,178,48,.15), rgba(255,220,111,.06));
  box-shadow: 0 0 0 1px rgba(255,194,62,.025), 0 7px 18px rgba(151,93,0,.08);
}

.access-card-service {
  margin-top: 0;
  padding: 10px 11px;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 11px;
  background: rgba(0,0,0,.12);
}

.access-card-service > div:first-child {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.access-card-service > div:first-child span,
.access-card-account-copy span {
  color: #7f7772;
  font-size: 10px;
  font-weight: 650;
  letter-spacing: .06em;
}

.access-card-service > div:first-child strong {
  color: #ece4dd;
  font-size: 13px;
  font-weight: 650;
  text-align: right;
}

.access-client-card.active .service-meter > span {
  background: linear-gradient(90deg, #4fd487, #91e3ae);
}

.access-client-card.ended .service-meter > span {
  background: linear-gradient(90deg, #df5f5b, #ff9b97);
}

.access-client-card.pending .service-meter > span,
.access-client-card.error .service-meter > span {
  background: linear-gradient(90deg, #d5a13e, #f7d27a);
}

.access-service-footer {
  color: #887f7a;
  font-size: 11px;
}

.access-card-account {
  min-height: 44px;
  margin-top: 8px;
  padding: 7px 9px;
  border: 1px solid rgba(255,255,255,.055);
  border-radius: 10px;
  background: rgba(255,255,255,.013);
}

.access-card-account-copy strong {
  color: #ded6d0;
  font-size: 12px;
  font-weight: 650;
}

.access-card-account > i {
  font-size: 10px;
  font-style: normal;
  font-weight: 700;
  letter-spacing: .05em;
}

@media (max-width: 1220px) {
  .access-toolbar.card {
    flex-wrap: wrap;
  }

  .access-search {
    width: 100%;
    flex: 1 1 100%;
  }

  .access-toolbar-right {
    width: 100%;
    justify-content: space-between;
  }
}

@media (max-width: 760px) {
  .access-overview {
    grid-template-columns: 1fr 1fr;
  }

  .access-toolbar-right {
    align-items: stretch;
    flex-direction: column;
  }

  .access-filters {
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }

  .access-filters::-webkit-scrollbar {
    display: none;
  }

  .access-toolbar-actions {
    width: 100%;
    justify-content: flex-end;
  }
}

@media (max-width: 560px) {
  .access-overview {
    gap: 8px;
  }

  .access-metric {
    min-height: 112px;
    padding: 14px;
  }

  .access-metric strong {
    font-size: 29px;
  }

  .access-grid {
    grid-template-columns: 1fr;
  }

  .access-card-top {
    grid-template-columns: auto minmax(0,1fr);
  }

  .access-card-badges {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }

  .access-toolbar-action {
    min-height: 38px;
    padding: 0 10px;
    font-size: 11px;
  }
}


/* --- v0.16.23 reseller wallets + resale pricing --- */
.plan-admin-price.plan-admin-price-clean {
  display: grid;
  grid-template-columns: minmax(0,1fr) minmax(0,1fr) auto;
  align-items: end;
  gap: 10px;
}

.plan-admin-price.plan-admin-price-clean > div {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.plan-admin-price.plan-admin-price-clean small {
  color: #756e69;
  font-size: 9px;
  font-weight: 750;
  letter-spacing: .08em;
}

.plan-admin-price.plan-admin-price-clean > div > strong {
  font-size: 22px;
}

.plan-admin-price.plan-admin-price-clean .plan-reseller-price {
  padding-left: 10px;
  border-left: 1px solid rgba(255,255,255,.06);
}

.plan-admin-price.plan-admin-price-clean .plan-reseller-price strong {
  color: #8deab0;
}

.plan-price-grid.form-grid.three {
  grid-template-columns: 1fr 1fr minmax(160px,.7fr);
}

.plan-price-grid label > small {
  display: block;
  margin-top: 6px;
  color: #746d68;
  font-size: 10px;
  line-height: 1.4;
}

/* Reseller access creator */
.reseller-sale-wallet {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-top: 1px solid rgba(255,255,255,.055);
  border-bottom: 1px solid rgba(85,214,139,.12);
  background:
    linear-gradient(90deg, rgba(85,214,139,.065), rgba(85,214,139,.015));
}

.reseller-sale-wallet > div {
  min-width: 140px;
  display: grid;
  gap: 2px;
  padding-right: 14px;
  border-right: 1px solid rgba(255,255,255,.06);
}

.reseller-sale-wallet span {
  color: #77706b;
  font-size: 9px;
  font-weight: 750;
  letter-spacing: .08em;
}

.reseller-sale-wallet strong {
  color: #b9efcc;
  font-size: 14px;
  font-weight: 700;
}

.reseller-sale-wallet > a {
  justify-self: end;
  color: #9adfb5;
  text-decoration: none;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: .07em;
}

.reseller-sale-wallet > a:hover {
  color: #d2f7df;
}

.reseller-plan-prices {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin: 10px 0 4px;
}

.reseller-plan-prices > span {
  min-width: 0;
  display: grid;
  gap: 2px;
  padding: 7px 8px;
  border: 1px solid rgba(255,255,255,.055);
  border-radius: 9px;
  background: rgba(0,0,0,.11);
}

.reseller-plan-prices small {
  color: #756e69 !important;
  font-size: 8px !important;
  font-weight: 750;
  letter-spacing: .075em;
}

.reseller-plan-prices b {
  margin: 0 !important;
  color: #e9e1db;
  font-size: 14px !important;
}

.reseller-plan-prices .cost {
  border-color: rgba(85,214,139,.14);
  background: rgba(85,214,139,.035);
}

.reseller-plan-prices .cost b {
  color: #9be5b6;
}

.plan-blocked-reason {
  color: #e2a45e !important;
}

/* Team / reseller management */
.team-toolbar.card {
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
  padding: 16px 18px;
  border-color: rgba(255,255,255,.075);
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.08), transparent 13rem),
    linear-gradient(155deg, rgba(255,255,255,.026), rgba(255,255,255,.011));
}

.team-toolbar h2 {
  margin: 3px 0 4px;
  font-size: 18px;
}

.team-toolbar p {
  margin: 0;
  color: #79716c;
  font-size: 12px;
}

.team-create-button {
  border-color: rgba(108,183,255,.28) !important;
  background: linear-gradient(135deg, rgba(108,183,255,.14), rgba(108,183,255,.055)) !important;
  color: #b8ddff !important;
}

.staff-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px,1fr));
  gap: 12px;
  align-items: start;
}

.staff-card {
  min-width: 0;
  display: grid;
  gap: 12px;
  padding: 15px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 18px;
  background:
    linear-gradient(160deg, rgba(255,255,255,.026), rgba(255,255,255,.011));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018);
}

.staff-card.reseller {
  border-color: rgba(108,183,255,.16);
  background:
    radial-gradient(circle at 100% 0%, rgba(108,183,255,.095), transparent 13rem),
    linear-gradient(160deg, rgba(52,86,131,.035), rgba(255,255,255,.01));
  box-shadow:
    inset 3px 0 0 rgba(108,183,255,.34),
    inset 0 1px 0 rgba(255,255,255,.018);
}

.staff-card.admin-card,
.staff-card.admin {
  border-color: rgba(255,159,70,.14);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.08), transparent 13rem),
    linear-gradient(160deg, rgba(115,66,28,.03), rgba(255,255,255,.01));
}

.staff-card-head {
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 10px;
}

.staff-card-head > div {
  min-width: 0;
}

.staff-card-head h3 {
  margin: 2px 0;
  overflow: hidden;
  color: #f0e8e2;
  font-size: 16px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-card-head small {
  color: #77706b;
  font-size: 11px;
}

.staff-card-avatar {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 12px;
  background: rgba(255,255,255,.035);
  color: #ddd4ce;
  font-size: 14px;
  font-weight: 750;
}

.staff-card-avatar.reseller {
  border-color: rgba(108,183,255,.20);
  background: rgba(108,183,255,.08);
  color: #b9deff;
}

.staff-card-avatar.admin {
  border-color: rgba(255,159,70,.20);
  background: rgba(255,159,70,.08);
  color: #ffc37d;
}

.staff-admin-note {
  padding: 10px 11px;
  border: 1px solid rgba(255,255,255,.055);
  border-radius: 10px;
  background: rgba(0,0,0,.11);
  color: #817974;
  font-size: 11px;
}

.staff-wallet-balance {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 12px;
  border: 1px solid rgba(85,214,139,.14);
  border-radius: 11px;
  background: rgba(85,214,139,.035);
}

.staff-wallet-balance span,
.staff-wallet-stats span,
.wallet-admin-current span {
  color: #756e69;
  font-size: 9px;
  font-weight: 750;
  letter-spacing: .08em;
}

.staff-wallet-balance strong {
  color: #a8ecc0;
  font-size: 18px;
}

.staff-wallet-stats {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 6px;
}

.staff-wallet-stats > div {
  display: grid;
  gap: 4px;
  padding: 8px 9px;
  border: 1px solid rgba(255,255,255,.05);
  border-radius: 10px;
  background: rgba(0,0,0,.09);
}

.staff-wallet-stats strong {
  color: #ddd5cf;
  font-size: 12px;
}

.staff-topup-button {
  width: 100%;
  border-color: rgba(85,214,139,.20) !important;
  background: rgba(85,214,139,.055) !important;
  color: #a8ecc0 !important;
}

.wallet-admin-current {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  padding: 12px;
  border: 1px solid rgba(85,214,139,.14);
  border-radius: 11px;
  background: rgba(85,214,139,.035);
}

.wallet-admin-current strong {
  color: #a8ecc0;
  font-size: 18px;
}

.team-reseller-info {
  display: grid;
  gap: 7px;
  margin-top: 4px;
}

.team-reseller-info[hidden] {
  display: none;
}

.team-reseller-info > div {
  display: grid;
  gap: 3px;
  padding: 10px 11px;
  border: 1px solid rgba(108,183,255,.10);
  border-radius: 10px;
  background: rgba(108,183,255,.025);
}

.team-reseller-info strong {
  color: #b8ddff;
  font-size: 10px;
  letter-spacing: .065em;
}

.team-reseller-info small {
  color: #77706b;
  font-size: 10px;
  line-height: 1.45;
}

/* Wallet dashboard */
.wallet-overview {
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.wallet-metric {
  min-height: 132px;
  display: flex;
  flex-direction: column;
  padding: 17px 18px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 18px;
  background: linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018);
}

.wallet-metric.balance {
  border-color: rgba(85,214,139,.17);
  background:
    radial-gradient(circle at 100% 0%, rgba(85,214,139,.12), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
}

.wallet-metric.topups {
  border-color: rgba(108,183,255,.16);
  background:
    radial-gradient(circle at 100% 0%, rgba(108,183,255,.10), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
}

.wallet-metric.outflows {
  border-color: rgba(255,159,70,.15);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,159,70,.10), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
}

.wallet-metric.demos {
  border-color: rgba(175,139,255,.15);
  background:
    radial-gradient(circle at 100% 0%, rgba(175,139,255,.10), transparent 12rem),
    linear-gradient(155deg, rgba(255,255,255,.028), rgba(255,255,255,.012));
}

.wallet-metric-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wallet-metric-top span,
.wallet-metric small {
  color: #77706b;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: .075em;
}

.wallet-metric-top i {
  color: #524c48;
  font-size: 11px;
  font-style: normal;
}

.wallet-metric > strong {
  margin-top: 20px;
  color: #f1e9e3;
  font-size: 27px;
  font-weight: 650;
  letter-spacing: -.035em;
}

.wallet-metric.balance > strong { color: #a8ecc0; }
.wallet-metric.topups > strong { color: #b8ddff; }
.wallet-metric.outflows > strong { color: #ffc27b; }
.wallet-metric.demos > strong { color: #cbb5ff; }

.wallet-metric small {
  margin-top: 6px;
  letter-spacing: 0;
  line-height: 1.35;
}

.wallet-toolbar.card {
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 10px;
  padding: 14px 16px;
  border-color: rgba(255,255,255,.075);
  border-radius: 17px;
  background: linear-gradient(180deg, rgba(255,255,255,.024), rgba(255,255,255,.012));
}

.wallet-toolbar h2 {
  margin: 2px 0 3px;
  font-size: 17px;
}

.wallet-toolbar p {
  margin: 0;
  color: #77706b;
  font-size: 11px;
}

.wallet-recharge-button {
  border-color: rgba(85,214,139,.24) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.13), rgba(85,214,139,.05)) !important;
  color: #a8ecc0 !important;
}

.wallet-demo-alert {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-bottom: 14px;
  padding: 10px 12px;
  border: 1px solid rgba(108,183,255,.10);
  border-radius: 12px;
  background: rgba(108,183,255,.025);
}

.wallet-demo-alert.warning {
  border-color: rgba(248,199,94,.17);
  background: rgba(248,199,94,.035);
}

.wallet-demo-alert-icon {
  width: 31px;
  height: 31px;
  flex: 0 0 31px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: rgba(108,183,255,.09);
  color: #b8ddff;
  font-size: 11px;
  font-weight: 800;
}

.wallet-demo-alert.warning .wallet-demo-alert-icon {
  background: rgba(248,199,94,.09);
  color: #f7d27a;
}

.wallet-demo-alert > div {
  display: grid;
  gap: 2px;
}

.wallet-demo-alert strong {
  color: #dcd4ce;
  font-size: 10px;
  letter-spacing: .065em;
}

.wallet-demo-alert small {
  color: #766f6a;
  font-size: 10px;
}

.wallet-ledger {
  display: grid;
  gap: 7px;
}

.wallet-transaction {
  min-width: 0;
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 11px;
  padding: 11px 12px;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 12px;
  background: rgba(255,255,255,.015);
}

.wallet-transaction.credit {
  border-left: 3px solid rgba(85,214,139,.38);
}

.wallet-transaction.debit {
  border-left: 3px solid rgba(255,159,70,.38);
}

.wallet-transaction-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(255,255,255,.035);
  color: #bdb4ae;
  font-size: 17px;
}

.wallet-transaction.credit .wallet-transaction-icon {
  background: rgba(85,214,139,.065);
  color: #9be5b6;
}

.wallet-transaction.debit .wallet-transaction-icon {
  background: rgba(255,159,70,.065);
  color: #ffc27b;
}

.wallet-transaction-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.wallet-transaction-copy > div {
  display: flex;
  align-items: center;
  gap: 8px;
}

.wallet-transaction-copy strong {
  color: #ded6d0;
  font-size: 11px;
  letter-spacing: .05em;
}

.wallet-transaction-copy span,
.wallet-transaction-copy small {
  color: #706965;
  font-size: 10px;
}

.wallet-transaction-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wallet-transaction-amount {
  font-size: 13px;
  white-space: nowrap;
}

.wallet-transaction.credit .wallet-transaction-amount { color: #9be5b6; }
.wallet-transaction.debit .wallet-transaction-amount { color: #ffc27b; }

.wallet-empty {
  min-height: 220px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  text-align: center;
}

.wallet-empty-icon,
.wallet-gateway-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(108,183,255,.07);
  color: #b8ddff;
  font-size: 18px;
}

.wallet-empty h3 {
  margin: 3px 0 0;
}

.wallet-empty p {
  margin: 0;
  color: #756e69;
}

.wallet-gateway-preview {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 12px;
  border: 1px solid rgba(108,183,255,.12);
  border-radius: 12px;
  background: rgba(108,183,255,.03);
}

.wallet-gateway-preview > div {
  display: grid;
  gap: 4px;
}

.wallet-gateway-preview strong {
  color: #b8ddff;
  font-size: 11px;
  letter-spacing: .06em;
}

.wallet-gateway-preview p {
  margin: 0;
  color: #79716c;
  font-size: 11px;
  line-height: 1.5;
}

.wallet-recharge-balance {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
  padding: 11px 12px;
  border: 1px solid rgba(85,214,139,.12);
  border-radius: 11px;
  background: rgba(85,214,139,.03);
}

.wallet-recharge-balance span {
  color: #756e69;
  font-size: 9px;
  font-weight: 750;
  letter-spacing: .08em;
}

.wallet-recharge-balance strong {
  color: #a8ecc0;
  font-size: 18px;
}

@media (max-width: 1100px) {
  .wallet-overview {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }

  .plan-price-grid.form-grid.three {
    grid-template-columns: 1fr 1fr;
  }

  .plan-price-grid.form-grid.three > label:last-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 720px) {
  .reseller-sale-wallet {
    grid-template-columns: 1fr 1fr;
  }

  .reseller-sale-wallet > a {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .team-toolbar.card,
  .wallet-toolbar.card {
    align-items: flex-start;
    flex-direction: column;
  }

  .staff-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .wallet-overview {
    gap: 8px;
  }

  .wallet-metric {
    min-height: 115px;
    padding: 13px;
  }

  .wallet-metric > strong {
    margin-top: 15px;
    font-size: 21px;
  }

  .staff-wallet-stats {
    grid-template-columns: 1fr;
  }

  .wallet-transaction {
    grid-template-columns: auto minmax(0,1fr);
  }

  .wallet-transaction-amount {
    grid-column: 2;
  }

  .reseller-plan-prices {
    grid-template-columns: 1fr;
  }
}


/* --- v0.16.24 modern access sale modal --- */
.access-sale-dialog {
  width: min(1320px, calc(100vw - 28px));
  max-width: 1320px;
  max-height: min(94vh, 1020px);
  border-color: rgba(255,255,255,.115);
  border-radius: 26px;
  background: #11100f;
  box-shadow:
    0 44px 130px rgba(0,0,0,.76),
    0 0 0 1px rgba(255,159,70,.025);
}

.access-sale-dialog::backdrop {
  background: rgba(3,3,3,.84);
  backdrop-filter: blur(13px);
}

.access-sale-modal {
  max-height: min(94vh, 1020px);
  background:
    radial-gradient(circle at 9% 0%, rgba(108,183,255,.055), transparent 22rem),
    radial-gradient(circle at 88% 0%, rgba(255,145,47,.095), transparent 26rem),
    linear-gradient(180deg, #151210 0%, #11100f 100%);
}

.access-sale-header {
  min-height: 104px;
  align-items: center;
  padding: 20px 24px 18px;
  border-bottom-color: rgba(255,255,255,.065);
  background: rgba(255,255,255,.008);
}

.access-sale-heading {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 14px;
}

.access-sale-heading-icon {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(108,183,255,.22);
  border-radius: 14px;
  background:
    linear-gradient(145deg, rgba(108,183,255,.13), rgba(108,183,255,.045));
  color: #b8ddff;
  box-shadow: 0 11px 28px rgba(42,111,181,.10);
}

.access-sale-heading-icon svg {
  width: 23px;
  height: 23px;
}

.access-sale-heading-copy {
  min-width: 0;
}

.access-sale-header .eyebrow {
  color: #ffb35f;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .12em;
}

.access-sale-header h2 {
  margin: 4px 0 5px;
  color: #f6f1ed;
  font-size: 30px;
  font-weight: 650;
  line-height: 1;
  letter-spacing: -.04em;
}

.access-sale-header p {
  max-width: 760px;
  color: #8f8782;
  font-size: 12px;
}

.access-sale-header .dialog-close {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border-radius: 12px;
  background: rgba(255,255,255,.025);
}

.access-sale-header .dialog-close:hover {
  transform: translateY(-1px);
  border-color: rgba(255,107,107,.24);
  background: rgba(255,107,107,.055);
  color: #ffb3b0;
}

/* Compact reseller wallet strip, styled like the account action controls. */
.reseller-sale-wallet {
  min-height: 66px;
  grid-template-columns: minmax(190px,auto) minmax(170px,auto) 1fr;
  gap: 10px;
  padding: 9px 18px;
  border-top: 0;
  border-bottom: 1px solid rgba(85,214,139,.12);
  background:
    radial-gradient(circle at 3% 50%, rgba(85,214,139,.08), transparent 19rem),
    linear-gradient(90deg, rgba(85,214,139,.035), rgba(255,255,255,.008));
}

.reseller-sale-wallet > div {
  min-width: 0;
  padding-right: 0;
  border-right: 0;
}

.reseller-wallet-stat {
  min-height: 46px;
  display: grid !important;
  grid-template-columns: 34px minmax(0,1fr);
  align-items: center;
  gap: 9px !important;
  padding: 7px 11px !important;
  border: 1px solid rgba(255,255,255,.06) !important;
  border-radius: 12px;
  background: rgba(0,0,0,.11);
}

.reseller-wallet-stat.balance {
  border-color: rgba(85,214,139,.14) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.07), rgba(85,214,139,.025));
}

.reseller-wallet-stat.demos {
  border-color: rgba(108,183,255,.13) !important;
  background: linear-gradient(135deg, rgba(108,183,255,.06), rgba(108,183,255,.02));
}

.reseller-wallet-stat-icon {
  width: 34px;
  height: 34px;
  display: grid !important;
  place-items: center;
  border-radius: 10px;
  background: rgba(255,255,255,.035);
  color: #9d9691 !important;
}

.reseller-wallet-stat.balance .reseller-wallet-stat-icon {
  background: rgba(85,214,139,.075);
  color: #9be5b6 !important;
}

.reseller-wallet-stat.demos .reseller-wallet-stat-icon {
  background: rgba(108,183,255,.075);
  color: #b8ddff !important;
}

.reseller-wallet-stat-icon svg {
  width: 18px;
  height: 18px;
}

.reseller-wallet-stat-copy {
  min-width: 0;
  display: grid !important;
  gap: 2px;
}

.reseller-wallet-stat-copy > span {
  color: #716a66 !important;
  font-size: 8px !important;
  font-weight: 800 !important;
  letter-spacing: .09em !important;
}

.reseller-wallet-stat-copy strong {
  color: #e8e1dc;
  font-size: 14px;
  font-weight: 700;
}

.reseller-wallet-stat.balance strong {
  color: #a8ecc0;
}

.reseller-wallet-stat.demos strong {
  color: #c1e2ff;
}

.reseller-wallet-link {
  justify-self: end;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border: 1px solid rgba(85,214,139,.20);
  border-radius: 11px;
  background: linear-gradient(135deg, rgba(85,214,139,.105), rgba(85,214,139,.04));
  color: #a8ecc0 !important;
  box-shadow: 0 8px 20px rgba(0,0,0,.10);
  transition: transform .16s ease, border-color .16s ease, background .16s ease, color .16s ease;
}

.reseller-wallet-link:hover {
  transform: translateY(-1px);
  border-color: rgba(85,214,139,.38);
  background: linear-gradient(135deg, rgba(85,214,139,.16), rgba(85,214,139,.065));
  color: #d7f7e2 !important;
}

.reseller-wallet-link svg {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
}

.reseller-wallet-link > span {
  color: inherit !important;
  font-size: 10px !important;
  font-weight: 800 !important;
  letter-spacing: .065em !important;
}

.access-sale-body {
  grid-template-columns: minmax(0,1.55fr) minmax(360px,.72fr);
  gap: 15px;
  padding: 16px 18px 18px;
  scrollbar-gutter: stable;
}

.access-sale-step {
  position: relative;
  overflow: hidden;
  padding: 17px 18px 18px;
  border-color: rgba(255,255,255,.072);
  border-radius: 17px;
  background:
    linear-gradient(155deg, rgba(255,255,255,.022), rgba(255,255,255,.009));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.014);
}

.access-sale-step::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 2px;
  opacity: .82;
}

.access-sale-step.plan-step::before {
  background: linear-gradient(180deg, rgba(255,159,70,.9), rgba(255,159,70,0));
}

.access-sale-step.client-step::before {
  background: linear-gradient(180deg, rgba(108,183,255,.78), rgba(108,183,255,0));
}

.access-sale-step.payment-step::before {
  background: linear-gradient(180deg, rgba(85,214,139,.78), rgba(85,214,139,0));
}

.access-sale-step.plan-step {
  background:
    radial-gradient(circle at 100% 0%, rgba(255,145,47,.045), transparent 15rem),
    linear-gradient(155deg, rgba(255,255,255,.022), rgba(255,255,255,.009));
}

.access-sale-step.client-step {
  background:
    radial-gradient(circle at 100% 0%, rgba(108,183,255,.04), transparent 15rem),
    linear-gradient(155deg, rgba(255,255,255,.022), rgba(255,255,255,.009));
}

.access-sale-step.payment-step {
  background:
    radial-gradient(circle at 100% 0%, rgba(85,214,139,.035), transparent 15rem),
    linear-gradient(155deg, rgba(255,255,255,.022), rgba(255,255,255,.009));
}

.access-sale-step .access-create-section-title {
  margin-bottom: 15px;
}

.access-sale-step .access-create-section-title > span {
  width: 35px;
  height: 35px;
  border-radius: 11px;
  font-weight: 800;
}

.access-sale-step.plan-step .access-create-section-title > span {
  border-color: rgba(255,159,70,.24);
  background: rgba(255,139,42,.08);
  color: #ffba6b;
}

.access-sale-step.client-step .access-create-section-title > span {
  border-color: rgba(108,183,255,.22);
  background: rgba(108,183,255,.07);
  color: #b8ddff;
}

.access-sale-step.payment-step .access-create-section-title > span {
  border-color: rgba(85,214,139,.22);
  background: rgba(85,214,139,.07);
  color: #a8ecc0;
}

.access-sale-step .access-create-section-title strong {
  color: #e9e2dc;
  font-size: 13px;
  font-weight: 750;
  letter-spacing: .035em;
}

.access-sale-step .access-create-section-title small {
  color: #746d68;
  font-size: 10px;
  line-height: 1.4;
}

.access-plan-picker {
  grid-template-columns: repeat(auto-fit, minmax(205px,1fr));
  gap: 9px;
}

.access-plan-option-card {
  position: relative;
  min-height: 158px;
  padding: 13px;
  border-color: rgba(255,255,255,.072);
  border-radius: 14px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,255,255,.028), transparent 9rem),
    rgba(0,0,0,.14);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.012);
}

.access-plan-option-card::after {
  content: "✓";
  position: absolute;
  top: 10px;
  right: 10px;
  width: 23px;
  height: 23px;
  display: grid;
  place-items: center;
  border: 1px solid transparent;
  border-radius: 8px;
  color: transparent;
  font-size: 10px;
  font-weight: 900;
  transition: border-color .16s ease, background .16s ease, color .16s ease;
  pointer-events: none;
}

.access-plan-option-top {
  padding-right: 28px;
}

.access-plan-option-top strong {
  color: #eee7e1;
  font-size: 14px;
  font-weight: 700;
}

.access-plan-option-top i {
  min-height: 25px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border-color: rgba(255,159,70,.15);
  background: rgba(255,139,42,.03);
  color: #ffbd72;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .07em;
}

.access-plan-option.kind-demo .access-plan-option-top i {
  border-color: rgba(108,183,255,.18);
  background: rgba(108,183,255,.045);
  color: #b8ddff;
}

.access-plan-option:hover .access-plan-option-card {
  transform: translateY(-2px);
  border-color: rgba(255,159,70,.20);
  box-shadow: 0 12px 28px rgba(0,0,0,.16), inset 0 1px 0 rgba(255,255,255,.018);
}

.access-plan-option.kind-demo:hover .access-plan-option-card {
  border-color: rgba(108,183,255,.22);
}

.access-plan-option > input:checked + .access-plan-option-card {
  transform: translateY(-1px);
  border-color: rgba(255,159,70,.42);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.14), transparent 11rem),
    linear-gradient(145deg, rgba(255,139,42,.05), rgba(255,255,255,.01));
  box-shadow:
    0 0 0 3px rgba(255,139,42,.05),
    0 14px 34px rgba(0,0,0,.20);
}

.access-plan-option.kind-demo > input:checked + .access-plan-option-card {
  border-color: rgba(108,183,255,.40);
  background:
    radial-gradient(circle at 100% 0%, rgba(108,183,255,.14), transparent 11rem),
    linear-gradient(145deg, rgba(108,183,255,.045), rgba(255,255,255,.01));
  box-shadow:
    0 0 0 3px rgba(108,183,255,.045),
    0 14px 34px rgba(0,0,0,.20);
}

.access-plan-option > input:checked + .access-plan-option-card::after {
  border-color: rgba(255,159,70,.28);
  background: rgba(255,139,42,.09);
  color: #ffc37d;
}

.access-plan-option.kind-demo > input:checked + .access-plan-option-card::after {
  border-color: rgba(108,183,255,.28);
  background: rgba(108,183,255,.09);
  color: #c7e6ff;
}

.reseller-plan-prices {
  gap: 6px;
  margin: 11px 0 5px;
}

.reseller-plan-prices > span {
  min-height: 58px;
  align-content: center;
  padding: 7px 8px;
  border-radius: 10px;
  background: rgba(0,0,0,.14);
}

.reseller-plan-prices small {
  font-size: 7.5px !important;
}

.reseller-plan-prices b {
  color: #eee7e1;
  font-size: 13px !important;
  line-height: 1.25;
}

.reseller-plan-prices .cost {
  border-color: rgba(85,214,139,.15);
  background: linear-gradient(145deg, rgba(85,214,139,.055), rgba(85,214,139,.018));
}

.reseller-plan-prices .cost b {
  color: #9be5b6;
}

.access-plan-option-card > small {
  margin-top: 6px;
  color: #817a75;
  font-size: 10px;
}

.access-plan-option-card > em {
  padding-top: 10px;
  color: #80dca3;
  font-size: 10px;
  font-weight: 700;
}

.access-sale-step .form-grid {
  gap: 11px;
}

.access-sale-step .form-grid.two {
  grid-template-columns: repeat(2,minmax(0,1fr));
}

.access-sale-step label {
  color: #cfc7c1;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: .045em;
}

.access-sale-step label > small {
  margin-top: 2px;
  color: #6f6863;
  font-size: 9px;
}

.access-sale-step input:not([type="radio"]),
.access-sale-step select {
  min-height: 43px !important;
  border-radius: 11px !important;
  padding-top: 9px !important;
  padding-bottom: 9px !important;
  font-size: 12px !important;
}

.access-sale-step.client-step input:not([type="radio"]):focus {
  border-color: rgba(108,183,255,.44);
  box-shadow: 0 0 0 3px rgba(108,183,255,.07);
}

.access-sale-step.payment-step input:not([type="radio"]):focus,
.access-sale-step.payment-step select:focus {
  border-color: rgba(85,214,139,.38);
  box-shadow: 0 0 0 3px rgba(85,214,139,.06);
}

.access-sale-summary {
  top: 0;
  min-height: 100%;
  padding: 20px;
  overflow: hidden;
  border-color: rgba(255,159,70,.17);
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.13), transparent 15rem),
    radial-gradient(circle at 0% 100%, rgba(85,214,139,.045), transparent 15rem),
    linear-gradient(180deg, rgba(255,139,42,.035), rgba(255,255,255,.012)),
    #15120f;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018);
  transition: border-color .18s ease, background .18s ease;
}

.access-sale-summary.is-demo {
  border-color: rgba(108,183,255,.20);
  background:
    radial-gradient(circle at 100% 0%, rgba(108,183,255,.14), transparent 15rem),
    radial-gradient(circle at 0% 100%, rgba(85,214,139,.035), transparent 15rem),
    linear-gradient(180deg, rgba(108,183,255,.028), rgba(255,255,255,.012)),
    #141210;
}

.access-sale-summary .eyebrow {
  color: #ffb45f;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .10em;
}

.access-sale-summary.is-demo .eyebrow {
  color: #b8ddff;
}

.access-sale-summary-icon {
  width: 45px;
  height: 45px;
  margin: 15px 0 14px;
  border-radius: 13px;
  background: linear-gradient(145deg, rgba(85,214,139,.09), rgba(85,214,139,.035));
  box-shadow: 0 10px 25px rgba(21,97,54,.07);
}

.access-sale-summary.is-demo .access-sale-summary-icon {
  border-color: rgba(108,183,255,.18);
  background: linear-gradient(145deg, rgba(108,183,255,.10), rgba(108,183,255,.035));
  color: #b8ddff;
}

.access-sale-summary h3 {
  margin-bottom: 6px;
  color: #f3ece6;
  font-size: 25px;
  font-weight: 650;
}

.access-sale-summary > p {
  margin-bottom: 14px;
  color: #8e8681;
  font-size: 11px;
  line-height: 1.55;
}

.access-sale-summary dl {
  gap: 6px;
}

.access-sale-summary dl > div {
  min-height: 43px;
  padding: 8px 10px;
  border: 1px solid rgba(255,255,255,.052);
  border-radius: 10px;
  background: rgba(0,0,0,.105);
}

.access-sale-summary dl > div:first-child {
  border-color: rgba(255,159,70,.10);
  background: rgba(255,139,42,.025);
}

.access-sale-summary dl > div:nth-child(2) {
  border-color: rgba(85,214,139,.10);
  background: rgba(85,214,139,.022);
}

.access-sale-summary dt {
  color: #6f6863;
  font-size: 9px;
  font-weight: 750;
  letter-spacing: .07em;
}

.access-sale-summary dd {
  color: #ddd5cf;
  font-size: 11px;
  font-weight: 700;
}

.access-sale-summary #accessSaleResellerPrice {
  color: #9be5b6;
}

.access-sale-auto-note {
  grid-template-columns: 30px minmax(0,1fr);
  gap: 10px;
  margin-top: 14px;
  padding: 12px;
  border: 1px solid rgba(85,214,139,.095);
  border-radius: 12px;
  background: rgba(85,214,139,.026);
}

.access-sale-auto-note > span {
  width: 30px;
  height: 30px;
  border-radius: 9px;
}

.access-sale-auto-note p {
  margin: 1px 0 0;
  color: #847c77;
  font-size: 10px;
}

.access-sale-actions {
  position: relative;
  min-height: 66px;
  align-items: center;
  padding: 11px 18px 13px;
  border-top-color: rgba(255,255,255,.065);
  background: rgba(10,9,9,.90);
  backdrop-filter: blur(16px);
}

.access-sale-actions .button {
  min-height: 43px;
  border-radius: 11px;
  padding: 0 15px;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: .06em;
}

.access-sale-actions .button svg {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
}

.access-sale-actions .access-sale-cancel {
  min-width: 132px;
  border-color: rgba(255,255,255,.08);
  background: rgba(255,255,255,.02);
  color: #b9b1ab;
}

.access-sale-actions .access-sale-cancel:hover {
  border-color: rgba(255,107,107,.18);
  background: rgba(255,107,107,.045);
  color: #efc1bf;
}

.access-sale-actions .button.primary.access-sale-submit {
  min-width: 226px;
  border-color: rgba(108,183,255,.28);
  background: linear-gradient(135deg, rgba(108,183,255,.15), rgba(108,183,255,.06));
  color: #c2e3ff;
  box-shadow: 0 9px 24px rgba(27,83,139,.10);
}

.access-sale-actions .button.primary.access-sale-submit:hover {
  border-color: rgba(108,183,255,.46);
  background: linear-gradient(135deg, rgba(108,183,255,.22), rgba(108,183,255,.09));
  color: #e4f3ff;
  box-shadow: 0 11px 28px rgba(27,83,139,.14);
}

.access-sale-actions .button.primary.access-sale-submit:disabled {
  border-color: rgba(108,183,255,.13);
  background: rgba(108,183,255,.035);
  color: #708392;
  box-shadow: none;
}

/* Keep the wide desktop composition, then collapse cleanly on smaller screens. */
@media (max-width: 1100px) {
  .access-sale-dialog {
    width: min(1120px, calc(100vw - 22px));
  }

  .access-sale-body {
    grid-template-columns: minmax(0,1fr) minmax(320px,.72fr);
  }

  .access-plan-picker {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }

  .reseller-sale-wallet {
    grid-template-columns: 1fr 1fr auto;
  }
}

@media (max-width: 860px) {
  .access-sale-dialog,
  .access-sale-modal {
    max-height: 95vh;
  }

  .access-sale-header {
    min-height: 0;
    padding: 17px 16px 15px;
  }

  .access-sale-heading-icon {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
  }

  .access-sale-header h2 {
    font-size: 26px;
  }

  .reseller-sale-wallet {
    grid-template-columns: 1fr 1fr;
    padding: 9px 12px;
  }

  .reseller-wallet-link {
    grid-column: 1 / -1;
    width: 100%;
    justify-content: center;
  }

  .access-sale-body {
    grid-template-columns: 1fr;
    padding: 12px;
  }

  .access-sale-step,
  .access-sale-step:nth-of-type(1),
  .access-sale-step:nth-of-type(2),
  .access-sale-step:nth-of-type(3),
  .access-sale-summary {
    grid-column: 1;
    grid-row: auto;
  }

  .access-sale-summary {
    position: relative;
    min-height: 0;
  }

  .access-sale-auto-note {
    margin-top: 12px;
  }
}

@media (max-width: 600px) {
  .access-sale-dialog {
    width: calc(100vw - 12px);
    border-radius: 20px;
  }

  .access-sale-heading {
    gap: 10px;
  }

  .access-sale-heading-icon {
    display: none;
  }

  .access-sale-header p {
    font-size: 10px;
  }

  .reseller-sale-wallet {
    grid-template-columns: 1fr;
  }

  .reseller-wallet-link {
    grid-column: auto;
  }

  .access-plan-picker,
  .access-sale-step .form-grid.two {
    grid-template-columns: 1fr;
  }

  .access-sale-step {
    padding: 14px;
  }

  .access-sale-actions {
    display: grid;
    grid-template-columns: 1fr 1.35fr;
    padding: 10px 12px 12px;
  }

  .access-sale-actions .button,
  .access-sale-actions .access-sale-cancel,
  .access-sale-actions .button.primary.access-sale-submit {
    min-width: 0;
    width: 100%;
    padding: 0 10px;
  }

  .access-sale-actions .button span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}


/* --- v0.16.25 compact access header controls --- */
.access-sale-header {
  min-height: 82px;
  padding: 14px 18px;
  align-items: center;
  gap: 16px;
}

.access-sale-heading {
  flex: 0 0 auto;
  gap: 11px;
}

.access-sale-heading-icon {
  width: 42px;
  height: 42px;
  flex-basis: 42px;
  border-radius: 12px;
}

.access-sale-heading-icon svg {
  width: 20px;
  height: 20px;
}

.access-sale-header h2 {
  margin: 0;
  font-size: 27px;
  line-height: 1;
}

.access-sale-header-tools {
  min-width: 0;
  margin-left: auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
}

.access-sale-header-tools .reseller-sale-wallet {
  min-height: 0;
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 8px;
  padding: 0;
  border: 0;
  background: transparent;
}

.access-sale-header-tools .reseller-wallet-stat {
  min-width: 154px;
  min-height: 42px;
  grid-template-columns: 30px minmax(0,1fr);
  gap: 8px !important;
  padding: 5px 9px !important;
  border-radius: 11px;
  box-shadow: none;
}

.access-sale-header-tools .reseller-wallet-stat.demos {
  min-width: 136px;
}

.access-sale-header-tools .reseller-wallet-stat-icon {
  width: 30px;
  height: 30px;
  border-radius: 9px;
}

.access-sale-header-tools .reseller-wallet-stat-icon svg {
  width: 16px;
  height: 16px;
}

.access-sale-header-tools .reseller-wallet-stat-copy {
  gap: 1px;
}

.access-sale-header-tools .reseller-wallet-stat-copy > span {
  font-size: 7px !important;
  letter-spacing: .08em !important;
}

.access-sale-header-tools .reseller-wallet-stat-copy strong {
  font-size: 12px;
  line-height: 1.2;
}

.access-sale-header-tools .reseller-wallet-link {
  min-height: 42px;
  justify-self: auto;
  padding: 0 11px;
  border-radius: 11px;
  white-space: nowrap;
  box-shadow: none;
}

.access-sale-header-tools .reseller-wallet-link svg {
  width: 15px;
  height: 15px;
  flex-basis: 15px;
}

.access-sale-header-tools .reseller-wallet-link > span {
  font-size: 9px !important;
}

.access-sale-header-tools .dialog-close {
  margin-left: 2px;
}

@media (max-width: 1120px) {
  .access-sale-header {
    flex-wrap: wrap;
  }

  .access-sale-heading {
    margin-right: auto;
  }

  .access-sale-header-tools {
    flex: 1 1 auto;
  }

  .access-sale-header-tools .reseller-wallet-stat {
    min-width: 142px;
  }

  .access-sale-header-tools .reseller-wallet-stat.demos {
    min-width: 125px;
  }
}

@media (max-width: 900px) {
  .access-sale-header {
    align-items: flex-start;
  }

  .access-sale-header-tools {
    width: 100%;
    flex-basis: 100%;
    order: 2;
    justify-content: flex-start;
  }

  .access-sale-header-tools .reseller-sale-wallet {
    flex: 1 1 auto;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .access-sale-header-tools .reseller-sale-wallet::-webkit-scrollbar {
    display: none;
  }

  .access-sale-header-tools .dialog-close {
    position: absolute;
    top: 14px;
    right: 16px;
  }

  .access-sale-heading {
    padding-right: 54px;
  }
}

@media (max-width: 620px) {
  .access-sale-header {
    padding: 12px;
  }

  .access-sale-heading-icon {
    width: 38px;
    height: 38px;
    flex-basis: 38px;
  }

  .access-sale-header h2 {
    font-size: 24px;
  }

  .access-sale-header-tools {
    gap: 6px;
  }

  .access-sale-header-tools .reseller-wallet-stat {
    min-width: 132px;
  }

  .access-sale-header-tools .reseller-wallet-stat.demos {
    min-width: 112px;
  }

  .access-sale-header-tools .reseller-wallet-link {
    min-width: 42px;
    padding: 0 10px;
  }

  .access-sale-header-tools .reseller-wallet-link > span:nth-of-type(1) {
    display: none;
  }
}


/* --- v0.16.26 payment row + compact summary --- */
.access-sale-step.payment-step {
  grid-column: 1 / -1 !important;
  grid-row: 3;
}

.access-sale-step.payment-step .payment-grid {
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 12px;
  align-items: start;
}

.access-sale-summary {
  grid-row: 1 / span 2;
  min-height: 0;
  height: 100%;
  align-self: stretch;
  padding: 17px 18px;
}

.access-sale-summary .eyebrow {
  font-size: 8px;
}

.access-sale-summary-icon {
  width: 40px;
  height: 40px;
  margin: 10px 0 10px;
  border-radius: 11px;
}

.access-sale-summary-icon svg {
  width: 18px;
  height: 18px;
}

.access-sale-summary h3 {
  margin-bottom: 4px;
  font-size: 22px;
}

.access-sale-summary > p {
  margin-bottom: 10px;
  font-size: 10px;
  line-height: 1.45;
}

.access-sale-summary dl {
  gap: 4px;
}

.access-sale-summary dl > div {
  min-height: 34px;
  padding: 5px 8px;
  border-radius: 9px;
}

.access-sale-summary dt {
  font-size: 8px;
}

.access-sale-summary dd {
  font-size: 10px;
}

.access-sale-auto-note {
  grid-template-columns: 27px minmax(0,1fr);
  gap: 8px;
  margin-top: 9px;
  padding: 9px 10px;
  border-radius: 10px;
}

.access-sale-auto-note > span {
  width: 27px;
  height: 27px;
  border-radius: 8px;
}

.access-sale-auto-note p {
  font-size: 9px;
  line-height: 1.4;
}

@media (max-width: 860px) {
  .access-sale-step.payment-step,
  .access-sale-summary {
    grid-column: 1;
    grid-row: auto;
    height: auto;
  }

  .access-sale-step.payment-step .payment-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 620px) {
  .access-sale-step.payment-step .payment-grid {
    grid-template-columns: 1fr;
  }
}


/* --- v0.16.27 two-step access wizard --- */
.access-sale-progress {
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 8px 18px;
  border-bottom: 1px solid rgba(255,255,255,.06);
  background:
    linear-gradient(90deg, rgba(255,139,42,.025), rgba(108,183,255,.018), rgba(85,214,139,.018));
}

.access-sale-progress-item {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  opacity: .50;
  transition: opacity .18s ease, transform .18s ease;
}

.access-sale-progress-item.is-active,
.access-sale-progress-item.is-complete {
  opacity: 1;
}

.access-sale-progress-number {
  width: 31px;
  height: 31px;
  flex: 0 0 31px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.085);
  border-radius: 10px;
  background: rgba(255,255,255,.025);
  color: #8d8580;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .045em;
}

.access-sale-progress-item[data-access-progress="1"].is-active .access-sale-progress-number {
  border-color: rgba(255,159,70,.27);
  background: rgba(255,139,42,.075);
  color: #ffc176;
}

.access-sale-progress-item[data-access-progress="1"].is-complete .access-sale-progress-number {
  border-color: rgba(85,214,139,.24);
  background: rgba(85,214,139,.07);
  color: #9be5b6;
}

.access-sale-progress-item[data-access-progress="2"].is-active .access-sale-progress-number {
  border-color: rgba(108,183,255,.28);
  background: rgba(108,183,255,.08);
  color: #b8ddff;
}

.access-sale-progress-copy {
  min-width: 0;
  display: grid;
  gap: 1px;
}

.access-sale-progress-copy strong {
  color: #cfc7c1;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .065em;
  white-space: nowrap;
}

.access-sale-progress-copy small {
  color: #716a66;
  font-size: 8px;
  white-space: nowrap;
}

.access-sale-progress-item.is-active .access-sale-progress-copy strong {
  color: #f1e9e3;
}

.access-sale-progress-line {
  width: clamp(46px, 8vw, 100px);
  height: 1px;
  background: linear-gradient(90deg, rgba(255,159,70,.22), rgba(108,183,255,.22));
}

.access-sale-wizard-body {
  display: block;
  padding: 14px 18px 18px;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.access-sale-stage[hidden],
.access-sale-actions [hidden] {
  display: none !important;
}

.access-sale-stage {
  min-width: 0;
}

.access-sale-stage-plan {
  display: grid;
  grid-template-columns: minmax(0,1.55fr) minmax(350px,.72fr);
  gap: 15px;
  align-items: stretch;
}

.access-sale-stage-plan .plan-step,
.access-sale-stage-plan .access-sale-summary {
  grid-column: auto !important;
  grid-row: auto !important;
}

.access-sale-stage-plan .access-sale-summary {
  position: relative;
  top: auto;
  align-self: stretch;
  height: auto;
  min-height: 100%;
}

.access-sale-stage-details {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.access-sale-stage-details .client-step,
.access-sale-stage-details .payment-step {
  grid-column: auto !important;
  grid-row: auto !important;
}

.access-sale-stage-details .client-step .client-notes-field {
  grid-column: 1 / -1;
}

.access-sale-section-icon svg {
  width: 17px;
  height: 17px;
}

.access-sale-stage-details .payment-step .payment-grid {
  grid-template-columns: repeat(auto-fit, minmax(230px,1fr));
  gap: 12px;
}

.access-sale-stage-details .client-step,
.access-sale-stage-details .payment-step {
  padding: 19px;
}

.access-sale-stage-details .access-create-section-title {
  margin-bottom: 16px;
}

.access-sale-stage-details .client-step .form-grid {
  gap: 12px;
}

.access-sale-actions {
  display: flex;
  align-items: center;
}

.access-sale-actions .access-sale-next,
.access-sale-actions .access-sale-submit {
  margin-left: auto;
}

.access-sale-actions .access-sale-back {
  min-width: 120px;
  border-color: rgba(108,183,255,.17);
  background: rgba(108,183,255,.035);
  color: #a9d6ff;
}

.access-sale-actions .access-sale-back:hover {
  border-color: rgba(108,183,255,.32);
  background: rgba(108,183,255,.075);
  color: #d8edff;
}

.access-sale-actions .button.primary.access-sale-next {
  min-width: 170px;
  border-color: rgba(108,183,255,.28);
  background: linear-gradient(135deg, rgba(108,183,255,.16), rgba(108,183,255,.065));
  color: #c7e6ff;
  box-shadow: 0 9px 24px rgba(27,83,139,.10);
}

.access-sale-actions .button.primary.access-sale-next:hover {
  border-color: rgba(108,183,255,.46);
  background: linear-gradient(135deg, rgba(108,183,255,.23), rgba(108,183,255,.10));
  color: #eef8ff;
}

.access-sale-actions .button.primary.access-sale-next:disabled {
  border-color: rgba(108,183,255,.12);
  background: rgba(108,183,255,.03);
  color: #708392;
  box-shadow: none;
}

/* Step 2 gets more breathing room now that the summary is intentionally hidden. */
#access-create-dialog[data-step="2"] .access-sale-wizard-body {
  padding-top: 16px;
}

#access-create-dialog[data-step="2"] .access-sale-stage-details {
  animation: access-sale-step-in .18s ease both;
}

#access-create-dialog[data-step="1"] .access-sale-stage-plan {
  animation: access-sale-step-in .18s ease both;
}

@keyframes access-sale-step-in {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 980px) {
  .access-sale-stage-plan {
    grid-template-columns: minmax(0,1fr) minmax(310px,.72fr);
  }

  .access-sale-progress {
    justify-content: flex-start;
  }
}

@media (max-width: 860px) {
  .access-sale-progress {
    padding: 8px 12px;
  }

  .access-sale-stage-plan {
    grid-template-columns: 1fr;
  }

  .access-sale-stage-plan .access-sale-summary {
    min-height: 0;
  }

  .access-sale-stage-details .payment-step .payment-grid {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
}

@media (max-width: 620px) {
  .access-sale-progress {
    gap: 8px;
    overflow-x: auto;
    justify-content: flex-start;
    scrollbar-width: none;
  }

  .access-sale-progress::-webkit-scrollbar {
    display: none;
  }

  .access-sale-progress-copy small {
    display: none;
  }

  .access-sale-progress-line {
    width: 30px;
    flex: 0 0 30px;
  }

  .access-sale-wizard-body {
    padding: 10px 12px 14px;
  }

  .access-sale-stage-details .client-step,
  .access-sale-stage-details .payment-step {
    padding: 14px;
  }

  .access-sale-stage-details .client-step .form-grid.two,
  .access-sale-stage-details .payment-step .payment-grid {
    grid-template-columns: 1fr;
  }

  .access-sale-actions {
    display: grid;
    grid-template-columns: 1fr 1.35fr;
  }

  .access-sale-actions .access-sale-next,
  .access-sale-actions .access-sale-submit {
    margin-left: 0;
  }
}


/* --- v0.16.28 simplified two-step access flow --- */
/* Step 1 uses the available width: 2x2 plan cards on the left, assignment summary on the right. */
.access-sale-wizard-body {
  padding: 16px 18px 18px;
}

.access-sale-stage-plan {
  display: grid;
  grid-template-columns: minmax(0, 1.48fr) minmax(350px, .66fr);
  gap: 16px;
  align-items: stretch;
}

.access-sale-stage-plan .plan-step,
.access-sale-stage-plan .access-sale-summary {
  grid-column: auto !important;
  grid-row: auto !important;
}

.access-sale-stage-plan .plan-step {
  min-width: 0;
  height: 100%;
  padding: 18px;
}

.access-sale-stage-plan .access-plan-picker {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px;
}

.access-sale-stage-plan .access-plan-option-card {
  min-height: 166px;
}

.access-sale-stage-plan .access-sale-summary {
  position: relative;
  top: auto;
  align-self: stretch;
  height: 100%;
  min-height: 0;
  padding: 19px;
}

.access-sale-stage-plan .access-sale-summary-icon {
  margin: 11px 0 11px;
}

.access-sale-stage-plan .access-sale-summary > p {
  max-width: 34rem;
}

/* Step 2 is intentionally simple: customer data and payment side by side on desktop. */
.access-sale-stage-details {
  display: grid;
  grid-template-columns: minmax(0, 1.28fr) minmax(340px, .72fr);
  gap: 16px;
  align-items: stretch;
}

.access-sale-stage-details .access-sale-client-panel,
.access-sale-stage-details .access-sale-payment-panel {
  grid-column: auto !important;
  grid-row: auto !important;
  min-width: 0;
  height: 100%;
  padding: 20px;
}

.access-sale-stage-details .access-sale-client-panel {
  border-color: rgba(108,183,255,.10);
  background:
    radial-gradient(circle at 100% 0%, rgba(108,183,255,.045), transparent 15rem),
    linear-gradient(155deg, rgba(255,255,255,.022), rgba(255,255,255,.009));
}

.access-sale-stage-details .access-sale-payment-panel {
  border-color: rgba(85,214,139,.11);
  background:
    radial-gradient(circle at 100% 0%, rgba(85,214,139,.045), transparent 15rem),
    linear-gradient(155deg, rgba(255,255,255,.022), rgba(255,255,255,.009));
}

.access-sale-stage-details .access-sale-client-panel .form-grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 13px;
}

.access-sale-stage-details .access-sale-client-panel .client-notes-field {
  grid-column: 1 / -1;
}

.access-sale-stage-details .access-sale-payment-panel .payment-grid {
  grid-template-columns: 1fr;
  gap: 14px;
}

.access-sale-stage-details .access-sale-payment-panel .payment-grid > label {
  min-width: 0;
}

.access-sale-stage-details .access-create-section-title {
  margin-bottom: 17px;
}

/* Footer follows the wizard state: step 1 only Continue; step 2 only Back + Create. */
.access-sale-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 66px;
  padding: 11px 18px 13px;
}

.access-sale-actions .access-sale-next {
  margin-left: auto;
}

.access-sale-actions .access-sale-back {
  margin-right: auto;
  min-width: 122px;
  border-color: rgba(255,255,255,.09);
  background: rgba(255,255,255,.025);
  color: #c8c0ba;
}

.access-sale-actions .access-sale-back:hover {
  border-color: rgba(255,255,255,.16);
  background: rgba(255,255,255,.05);
  color: #fff;
}

.access-sale-actions .button.primary.access-sale-next {
  min-width: 172px;
  border-color: rgba(255,175,76,.34);
  background: linear-gradient(135deg, #ff922f, #ffba55);
  color: #1b1007;
  box-shadow: 0 10px 24px rgba(255,139,42,.10);
}

.access-sale-actions .button.primary.access-sale-next:hover {
  border-color: rgba(255,194,96,.52);
  background: linear-gradient(135deg, #ff9b39, #ffc363);
  color: #1b1007;
  box-shadow: 0 12px 28px rgba(255,139,42,.14);
}

.access-sale-actions .button.primary.access-sale-next:disabled {
  border-color: rgba(255,175,76,.14);
  background: rgba(255,139,42,.04);
  color: #806c58;
  box-shadow: none;
}

/* Final action keeps the blue visual language used by account creation. */
.access-sale-actions .button.primary.access-sale-submit {
  margin-left: auto;
  min-width: 232px;
  border-color: rgba(108,183,255,.30);
  background: linear-gradient(135deg, rgba(108,183,255,.16), rgba(108,183,255,.065));
  color: #c7e6ff;
  box-shadow: 0 9px 24px rgba(27,83,139,.10);
}

.access-sale-actions .button.primary.access-sale-submit:hover {
  border-color: rgba(108,183,255,.48);
  background: linear-gradient(135deg, rgba(108,183,255,.23), rgba(108,183,255,.10));
  color: #eff8ff;
  box-shadow: 0 11px 28px rgba(27,83,139,.14);
}

/* With the progress strip removed, the modal should feel lighter and avoid unnecessary scrolling. */
#access-create-dialog[data-step="1"] .access-sale-wizard-body,
#access-create-dialog[data-step="2"] .access-sale-wizard-body {
  padding-top: 16px;
}

@media (max-width: 1040px) {
  .access-sale-stage-plan {
    grid-template-columns: minmax(0, 1fr) minmax(320px, .66fr);
  }

  .access-sale-stage-details {
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr);
  }
}

@media (max-width: 880px) {
  .access-sale-stage-plan,
  .access-sale-stage-details {
    grid-template-columns: 1fr;
  }

  .access-sale-stage-plan .access-sale-summary {
    height: auto;
  }

  .access-sale-stage-details .access-sale-payment-panel .payment-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .access-sale-stage-plan .access-plan-picker {
    grid-template-columns: 1fr;
  }

  .access-sale-stage-details .access-sale-client-panel .form-grid.two {
    grid-template-columns: 1fr;
  }

  .access-sale-stage-details .access-sale-client-panel .client-notes-field {
    grid-column: auto;
  }

  .access-sale-stage-details .access-sale-payment-panel .payment-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .access-sale-wizard-body {
    padding: 10px 12px 14px;
  }

  .access-sale-stage-plan .plan-step,
  .access-sale-stage-plan .access-sale-summary,
  .access-sale-stage-details .access-sale-client-panel,
  .access-sale-stage-details .access-sale-payment-panel {
    padding: 14px;
  }

  .access-sale-actions {
    display: grid;
    grid-template-columns: 1fr 1.35fr;
    gap: 8px;
  }

  .access-sale-actions .access-sale-next {
    grid-column: 1 / -1;
    margin-left: 0;
    width: 100%;
  }

  .access-sale-actions .access-sale-back,
  .access-sale-actions .access-sale-submit {
    margin: 0;
    min-width: 0;
    width: 100%;
  }
}


/* --- v0.16.30 access modal typography alignment --- */
/* Match the established Monkey TV admin typography: readable labels, restrained microcopy, no 7-9px UI text. */
.access-sale-step .access-create-section-title strong {
  font-size: 13px;
  font-weight: 750;
  letter-spacing: .025em;
}

.access-sale-step .access-create-section-title small {
  font-size: 11px;
  line-height: 1.45;
}

.access-plan-option-top strong {
  font-size: 15px;
}

.access-plan-option-top i {
  font-size: 10px;
  letter-spacing: .055em;
}

.reseller-plan-prices small {
  font-size: 9.5px !important;
  line-height: 1.25;
}

.reseller-plan-prices b {
  font-size: 14px !important;
}

.access-plan-option-card > small {
  font-size: 11px;
  line-height: 1.4;
}

.access-plan-option-card > em {
  font-size: 11px;
  line-height: 1.35;
}

.access-sale-summary .eyebrow {
  font-size: 10px;
  letter-spacing: .085em;
}

.access-sale-summary h3 {
  font-size: 23px;
}

.access-sale-summary > p {
  font-size: 11px;
  line-height: 1.55;
}

.access-sale-summary dt {
  font-size: 9.5px;
  line-height: 1.25;
}

.access-sale-summary dd {
  font-size: 11.5px;
}

.access-sale-auto-note p {
  font-size: 10.5px;
  line-height: 1.45;
}

.access-sale-step label {
  font-size: 11px;
  letter-spacing: .035em;
}

.access-sale-step label > small {
  font-size: 10.5px;
  line-height: 1.45;
}

.access-sale-header-tools .reseller-wallet-stat-copy > span {
  font-size: 8.5px !important;
}

.access-sale-header-tools .reseller-wallet-stat-copy strong {
  font-size: 12.5px;
}

.access-sale-header-tools .reseller-wallet-link > span {
  font-size: 10px !important;
}

.access-sale-actions .button {
  font-size: 11px;
  letter-spacing: .05em;
}


/* --- v0.16.31 access sale step-two polish --- */
/* Step 2 follows the same readable hierarchy used throughout the current admin UI. */
.access-sale-stage-details .access-create-section-title strong {
  font-size: 14px;
  font-weight: 760;
  letter-spacing: .02em;
}

.access-sale-stage-details .access-create-section-title small {
  margin-top: 2px;
  color: #8d8580;
  font-size: 11.5px;
  line-height: 1.45;
}

.access-sale-stage-details label {
  color: #d7d0ca;
  font-size: 11.5px;
  font-weight: 740;
  letter-spacing: .03em;
}

.access-sale-stage-details label > small {
  margin-top: 5px;
  color: #847c77;
  font-size: 11px;
  line-height: 1.45;
}

.access-sale-stage-details input:not([type="radio"]):not([type="hidden"]),
.access-sale-stage-details select {
  min-height: 45px !important;
  padding-top: 10px !important;
  padding-bottom: 10px !important;
  font-size: 13px !important;
}

/* Editable COP amount: visually formatted as 25.900 COP while the hidden field submits 25900. */
.access-sale-price-input {
  min-height: 45px !important;
  grid-template-columns: minmax(0, 1fr) 62px !important;
  overflow: hidden;
}

.access-sale-price-input #resellerSalePriceDisplay {
  min-width: 0;
  padding-left: 13px !important;
  border-left: 0 !important;
  font-size: 14px !important;
  font-weight: 700;
  letter-spacing: .01em;
  color: #f0e9e4;
  text-align: left;
}

.access-sale-price-input #resellerSalePriceDisplay.is-readonly {
  color: #9d9691;
  cursor: default;
}

.access-sale-price-input .access-sale-currency {
  height: 100%;
  min-height: 43px;
  display: grid;
  place-items: center;
  border-left: 1px solid rgba(255,255,255,.07);
  color: #9be5b6 !important;
  background: rgba(85,214,139,.035);
  font-size: 11px !important;
  font-weight: 800 !important;
  letter-spacing: .06em;
}

.access-sale-stage-details .access-sale-payment-panel .payment-grid {
  gap: 16px;
}

.access-sale-stage-details .access-sale-payment-panel select {
  font-weight: 700;
}

.access-sale-stage-details .client-notes-field input {
  color: #d8d1cb;
}

/* Make the final action states unmistakable while a sale is being submitted. */
.access-sale-actions .access-sale-submit.is-loading {
  pointer-events: none;
  opacity: .72;
}

.access-sale-actions .access-sale-submit.is-loading svg {
  animation: access-submit-pulse 1s ease-in-out infinite alternate;
}

@keyframes access-submit-pulse {
  from { opacity: .45; }
  to { opacity: 1; }
}


/* --- v0.16.32 wallet movement cards --- */
/* Wallet copy follows the current admin hierarchy: labels are compact, supporting text stays readable. */
.wallet-metric-top span {
  font-size: 10px;
  font-weight: 780;
  letter-spacing: .075em;
}

.wallet-metric > strong {
  margin-top: 18px;
  font-size: 27px;
  font-weight: 680;
}

.wallet-metric small {
  margin-top: 7px;
  color: #8b837e;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0;
}

.wallet-toolbar.card {
  padding: 15px 17px;
  border-radius: 18px;
}

.wallet-toolbar .eyebrow {
  margin-bottom: 3px;
  font-size: 10px;
  letter-spacing: .085em;
}

.wallet-toolbar h2 {
  margin: 0 0 4px;
  font-size: 19px;
  font-weight: 720;
  letter-spacing: -.02em;
}

.wallet-toolbar p {
  color: #8b837e;
  font-size: 11.5px;
  line-height: 1.45;
}

.wallet-recharge-button {
  min-height: 41px;
  padding: 0 14px !important;
  border-radius: 12px !important;
}

/* Demo usage is information, not a large alert. */
.wallet-demo-alert {
  min-height: 58px;
  gap: 11px;
  margin-bottom: 14px;
  padding: 10px 13px;
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(108,183,255,.045), rgba(108,183,255,.015));
}

.wallet-demo-alert-icon {
  width: 34px;
  height: 34px;
  flex-basis: 34px;
  border-radius: 10px;
}

.wallet-demo-alert-icon svg {
  width: 17px;
  height: 17px;
}

.wallet-demo-alert-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.wallet-demo-alert-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
}

.wallet-demo-alert strong {
  color: #dfe9f2;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .065em;
}

.wallet-demo-alert-line > span {
  color: #b5ada7;
  font-size: 11px;
  font-weight: 650;
}

.wallet-demo-alert small {
  color: #817a75;
  font-size: 10.5px;
  line-height: 1.4;
}

/* Each movement is its own compact card. Two-column layout uses wide desktop space without stretching rows. */
.wallet-ledger {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 10px;
}

.wallet-transaction-card {
  position: relative;
  min-width: 0;
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  overflow: hidden;
  padding: 13px 15px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 16px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,255,255,.03), transparent 11rem),
    linear-gradient(160deg, rgba(255,255,255,.023), rgba(255,255,255,.009));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.018),
    0 8px 22px rgba(0,0,0,.08);
  transition:
    transform .16s ease,
    border-color .16s ease,
    background .16s ease,
    box-shadow .16s ease;
}

.wallet-transaction-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 2px;
}

.wallet-transaction-card.credit::before {
  background: linear-gradient(180deg, #55d68b, rgba(85,214,139,.1));
}

.wallet-transaction-card.debit::before {
  background: linear-gradient(180deg, #ff9f46, rgba(255,159,70,.1));
}

.wallet-transaction-card.credit {
  border-color: rgba(85,214,139,.10);
  background:
    radial-gradient(circle at 100% 0%, rgba(85,214,139,.055), transparent 12rem),
    linear-gradient(160deg, rgba(255,255,255,.022), rgba(255,255,255,.009));
}

.wallet-transaction-card.debit {
  border-color: rgba(255,159,70,.10);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,159,70,.055), transparent 12rem),
    linear-gradient(160deg, rgba(255,255,255,.022), rgba(255,255,255,.009));
}

.wallet-transaction-card:hover {
  transform: translateY(-1px);
  border-color: rgba(255,255,255,.13);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.025),
    0 12px 28px rgba(0,0,0,.13);
}

.wallet-transaction-main {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 11px;
}

.wallet-transaction-icon {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  border: 1px solid rgba(255,255,255,.05);
  background: rgba(255,255,255,.032);
}

.wallet-transaction-icon svg {
  width: 18px;
  height: 18px;
}

.wallet-transaction-card.credit .wallet-transaction-icon {
  border-color: rgba(85,214,139,.11);
  background: rgba(85,214,139,.07);
  color: #9be5b6;
}

.wallet-transaction-card.debit .wallet-transaction-icon {
  border-color: rgba(255,159,70,.11);
  background: rgba(255,159,70,.07);
  color: #ffc27b;
}

.wallet-transaction-copy {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.wallet-transaction-head {
  min-width: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
}

.wallet-transaction-kind {
  color: #b9b1ab;
  font-size: 9.5px;
  font-weight: 820;
  letter-spacing: .07em;
}

.wallet-transaction-head small {
  color: #716a66;
  font-size: 10px;
  font-weight: 500;
}

.wallet-transaction-copy > strong {
  min-width: 0;
  overflow: hidden;
  color: #e5ddd7;
  font-size: 12.5px;
  font-weight: 650;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wallet-transaction-amount {
  flex: 0 0 auto;
  font-size: 15px;
  font-weight: 760;
  letter-spacing: -.015em;
  white-space: nowrap;
}

.wallet-transaction-card.credit .wallet-transaction-amount {
  color: #8ce9ad;
}

.wallet-transaction-card.debit .wallet-transaction-amount {
  color: #ffba6b;
}

.wallet-empty.card {
  min-height: 150px;
  border-radius: 18px;
}

@media (max-width: 980px) {
  .wallet-ledger {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .wallet-toolbar.card {
    align-items: stretch;
    flex-direction: column;
  }

  .wallet-recharge-button {
    width: 100%;
    justify-content: center;
  }

  .wallet-demo-alert-line {
    display: grid;
    gap: 2px;
  }

  .wallet-transaction-card {
    min-height: 0;
    align-items: flex-start;
    flex-direction: column;
    gap: 9px;
  }

  .wallet-transaction-amount {
    padding-left: 49px;
    font-size: 14px;
  }

  .wallet-transaction-copy > strong {
    white-space: normal;
  }
}


/* --- v0.16.33 compact access detail modal --- */
/* The detail modal follows the same compact hierarchy as the two-step access creator. */
.access-dialog {
  width: min(1240px, calc(100vw - 28px));
  max-width: 1240px;
  max-height: min(94vh, 960px);
}

.access-modal {
  padding: 15px 18px 14px;
}

.access-modal-header.access-modal-header-compact {
  min-height: 48px;
  align-items: center;
  padding-bottom: 11px;
}

.access-modal-avatar-only {
  gap: 0;
}

.access-modal-avatar-only .modal-avatar {
  width: 38px;
  height: 38px;
  flex-basis: 38px;
  border-radius: 11px;
}

.access-modal-head-actions {
  gap: 8px;
}

.access-modal-head-actions .badge {
  min-height: 28px;
  padding: 0 10px;
  font-size: 10.5px;
}

.access-modal-header-compact .dialog-close {
  width: 36px;
  height: 36px;
  border-radius: 10px;
}

/* Service status becomes a compact horizontal strip. */
.access-modal-service {
  margin: 11px 0 12px;
  padding: 10px 13px 9px;
  border-radius: 13px;
}

.access-modal-service-copy {
  gap: 8px;
  flex-wrap: nowrap;
}

.access-modal-service-copy > span {
  flex: 0 0 auto;
  font-size: 10px;
  letter-spacing: .085em;
}

.access-modal-service-copy > strong {
  flex: 0 0 auto;
  font-size: 12.5px;
  letter-spacing: .02em;
}

.access-modal-service-copy > small {
  min-width: 0;
  margin-left: auto;
  overflow: hidden;
  font-size: 10.5px;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-modal-service .service-meter.large {
  height: 7px;
  margin-top: 8px;
}

/* Main row: client left, assigned Plex account right. Summary spans the bottom. */
.access-detail-layout.access-detail-layout-modern {
  display: grid;
  grid-template-columns: minmax(320px, .78fr) minmax(0, 1.22fr);
  gap: 11px;
  align-items: start;
}

.access-detail-layout-modern > .access-client-panel {
  grid-column: 1;
  grid-row: 1;
}

.access-detail-layout-modern > .access-account-panel {
  grid-column: 2;
  grid-row: 1;
}

.access-detail-layout-modern > .access-commercial-summary {
  grid-column: 1 / -1;
  grid-row: 2;
}

.access-detail-layout-modern .access-detail-panel {
  padding: 12px 13px;
  border-radius: 13px;
}

.access-detail-layout-modern .access-panel-heading,
.access-detail-layout-modern .access-account-heading {
  margin-bottom: 8px;
}

.access-detail-layout-modern .access-panel-heading > div > span,
.access-detail-layout-modern .access-account-title > div > span {
  margin-bottom: 3px;
  color: #837a74;
  font-size: 9.5px;
  letter-spacing: .085em;
}

.access-detail-layout-modern .access-panel-heading h3,
.access-detail-layout-modern .access-account-title h3 {
  font-size: 14px;
  font-weight: 720;
}

.access-detail-layout-modern .access-payment-pill,
.access-detail-layout-modern .service-account-kind {
  min-height: 26px;
  padding: 0 8px;
  font-size: 10px;
}

/* Client data: fewer pixels per row, same readability rule. */
.access-detail-layout-modern .access-info-list > div,
.access-detail-layout-modern .access-credential-list > div {
  min-height: 38px;
  grid-template-columns: minmax(92px, .68fr) minmax(0, 1.32fr);
  gap: 10px;
}

.access-detail-layout-modern .access-info-list span,
.access-detail-layout-modern .access-credential-list > div > span {
  font-size: 10px;
  letter-spacing: .055em;
}

.access-detail-layout-modern .access-info-list strong,
.access-detail-layout-modern .access-credential-list > div > strong,
.access-detail-layout-modern .access-credential-list .assigned-password-line {
  font-size: 12.5px;
}

.access-detail-layout-modern .access-secondary-action {
  min-height: 36px;
  margin-top: 8px;
  border-radius: 9px;
  font-size: 10.5px;
}

.access-detail-layout-modern .access-account-title {
  gap: 9px;
}

.access-detail-layout-modern .access-account-title .access-card-account-avatar {
  width: 31px;
  height: 31px;
  flex-basis: 31px;
  border-radius: 9px;
}

.access-detail-layout-modern .access-share-actions {
  gap: 7px;
  margin-top: 8px;
}

.access-detail-layout-modern .access-share-button {
  min-height: 37px;
  border-radius: 9px;
  font-size: 10.5px;
}

.access-detail-layout-modern .assigned-account-note {
  margin-top: 8px;
  padding: 8px 10px;
  font-size: 10.5px;
}

.access-detail-layout-modern .access-tv-card {
  margin-top: 8px;
  padding: 9px 10px;
  border-radius: 10px;
}

.access-detail-layout-modern .access-tv-card-head {
  grid-template-columns: 26px minmax(0,1fr);
  gap: 8px;
}

.access-detail-layout-modern .access-tv-card-head strong {
  font-size: 10.5px;
  letter-spacing: .045em;
}

.access-detail-layout-modern .access-tv-card-head small {
  margin-top: 2px;
  font-size: 10.5px;
  line-height: 1.35;
}

.access-detail-layout-modern .access-tv-card .access-tv-link-form {
  margin-top: 7px;
}

.access-detail-layout-modern .access-tv-card .access-tv-link-controls {
  grid-template-columns: 106px minmax(140px,1fr);
}

.access-detail-layout-modern .access-tv-card .access-tv-link-controls input,
.access-detail-layout-modern .access-tv-card .access-tv-link-controls .button {
  height: 34px;
  min-height: 34px;
}

/* Full-width horizontal summary. All statistic cards remain on one line on desktop. */
.access-commercial-summary {
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  gap: 9px 16px;
  overflow: hidden;
}

.access-commercial-summary > .access-panel-heading {
  grid-column: 1 / -1;
  margin-bottom: 0;
}

.access-commercial-summary .access-panel-heading > div {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.access-commercial-summary .access-panel-heading > div > span {
  margin: 0;
}

.access-commercial-summary .access-panel-heading h3 {
  font-size: 13px;
}

.access-commercial-summary .access-stat-grid {
  grid-column: 1 / -1;
  display: flex;
  gap: 7px;
  min-width: 0;
  overflow-x: auto;
  padding-bottom: 1px;
  scrollbar-width: none;
}

.access-commercial-summary .access-stat-grid::-webkit-scrollbar {
  display: none;
}

.access-commercial-summary .access-stat-grid > div {
  min-width: 128px;
  min-height: 55px;
  flex: 1 1 0;
  align-content: center;
  gap: 3px;
  padding: 8px 9px;
  border-radius: 9px;
}

.access-commercial-summary .access-stat-grid span {
  font-size: 9.5px;
  letter-spacing: .075em;
}

.access-commercial-summary .access-stat-grid strong {
  font-size: 12px;
  line-height: 1.3;
}

.access-commercial-summary .access-library-row {
  grid-column: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  margin: 0;
  padding: 8px 0 0;
}

.access-commercial-summary .access-library-row > span {
  flex: 0 0 auto;
  font-size: 9.5px;
  letter-spacing: .075em;
}

.access-commercial-summary .access-library-row > div {
  min-width: 0;
  justify-content: flex-start;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
}

.access-commercial-summary .access-library-row > div::-webkit-scrollbar {
  display: none;
}

.access-commercial-summary .access-library-row .tag {
  flex: 0 0 auto;
  padding: 4px 7px;
  font-size: 10px;
}

.access-commercial-summary .access-audit-line {
  grid-column: 2;
  align-self: end;
  justify-content: flex-end;
  gap: 9px;
  margin: 0;
  padding-top: 8px;
  font-size: 9.5px;
  letter-spacing: .035em;
  white-space: nowrap;
}

.access-modal-actions.access-modal-icon-actions {
  margin-top: 10px;
  padding-top: 10px;
}

.access-modal-icon-actions .admin-action-icon.compact {
  width: 34px;
  height: 34px;
}

/* Responsive collapse keeps the horizontal summary scrollable instead of turning it back into a tall grid. */
@media (max-width: 960px) {
  .access-detail-layout.access-detail-layout-modern {
    grid-template-columns: 1fr;
  }

  .access-detail-layout-modern > .access-client-panel,
  .access-detail-layout-modern > .access-account-panel,
  .access-detail-layout-modern > .access-commercial-summary {
    grid-column: 1;
    grid-row: auto;
  }

  .access-detail-layout-modern > .access-account-panel {
    grid-row: 1;
  }

  .access-detail-layout-modern > .access-client-panel {
    grid-row: 2;
  }

  .access-detail-layout-modern > .access-commercial-summary {
    grid-row: 3;
  }
}

@media (max-width: 700px) {
  .access-modal-service-copy {
    flex-wrap: wrap;
  }

  .access-modal-service-copy > small {
    width: 100%;
    margin-left: 0;
    white-space: normal;
  }

  .access-commercial-summary {
    grid-template-columns: 1fr;
  }

  .access-commercial-summary .access-library-row,
  .access-commercial-summary .access-audit-line {
    grid-column: 1;
  }

  .access-commercial-summary .access-audit-line {
    justify-content: flex-start;
    flex-wrap: wrap;
    white-space: normal;
  }
}

@media (max-width: 520px) {
  .access-modal {
    padding: 12px;
  }

  .access-modal-avatar-only .modal-avatar {
    width: 36px;
    height: 36px;
    flex-basis: 36px;
  }

  .access-detail-layout-modern .access-info-list > div,
  .access-detail-layout-modern .access-credential-list > div {
    grid-template-columns: 1fr;
    gap: 2px;
    padding: 7px 0;
  }

  .access-detail-layout-modern .access-info-list strong,
  .access-detail-layout-modern .access-credential-list > div > strong,
  .access-detail-layout-modern .access-credential-list .assigned-password-line {
    justify-self: start;
    text-align: left;
  }

  .access-detail-layout-modern .access-share-actions,
  .access-detail-layout-modern .access-tv-card .access-tv-link-controls {
    grid-template-columns: 1fr;
  }
}


/* --- v0.16.34 ownership and admin-income indicators --- */
/* Ownership must be obvious anywhere the admin can see mixed access sources. */
.access-owner-pill,
.session-owner-chip {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 0 8px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 780;
  letter-spacing: .035em;
  white-space: nowrap;
}

.access-owner-pill.admin,
.session-owner-chip.admin {
  color: #b8ddff;
  border-color: rgba(108,183,255,.20);
  background: rgba(108,183,255,.065);
}

.access-owner-pill.reseller,
.session-owner-chip.reseller {
  color: #d0baff;
  border-color: rgba(167,125,255,.22);
  background:
    linear-gradient(135deg, rgba(151,107,255,.11), rgba(151,107,255,.045));
}

.access-card-owner-name {
  display: block;
  margin-top: 3px;
  overflow: hidden;
  color: #a99abf;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-filter.owner-filter.mine {
  border-color: rgba(108,183,255,.15);
}

.access-filter.owner-filter.reseller {
  border-color: rgba(167,125,255,.15);
}

.access-filter.owner-filter.mine.active {
  border-color: rgba(108,183,255,.32);
  background: linear-gradient(135deg, rgba(108,183,255,.20), rgba(108,183,255,.08));
  color: #d9edff;
}

.access-filter.owner-filter.reseller.active {
  border-color: rgba(167,125,255,.32);
  background: linear-gradient(135deg, rgba(151,107,255,.20), rgba(151,107,255,.08));
  color: #e5d9ff;
}

.access-modal-head-actions .access-owner-pill {
  min-height: 28px;
  padding: 0 10px;
}

/* Session cards carry the same ownership language as access cards. */
.session-client-service {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
}

.session-owner-chip {
  min-height: 27px;
}

.sessions-metric > small span {
  color: #e6ded8;
  font-weight: 800;
}

@media (max-width: 560px) {
  .access-card-badges {
    gap: 6px;
  }

  .access-owner-pill,
  .session-owner-chip {
    font-size: 12px;
  }
}


/* --- v0.16.37 admin configuration module --- */
.settings-page {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.settings-nav-card,
.settings-panel,
.settings-card,
.settings-note-card {
  border: 1px solid rgba(255,255,255,.075);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.045), transparent 15rem),
    linear-gradient(155deg, rgba(255,255,255,.024), rgba(255,255,255,.009));
}

.settings-nav-card {
  position: sticky;
  top: 14px;
  padding: 16px;
  border-radius: 18px;
}

.settings-nav-head {
  padding: 2px 3px 14px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.settings-nav-head .eyebrow,
.settings-panel-head .eyebrow,
.settings-profile-preview .eyebrow {
  color: #ffb15e;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .07em;
}

.settings-nav-head h2,
.settings-panel-head h2 {
  margin: 4px 0 5px;
  color: #f3ece6;
  font-weight: 720;
  letter-spacing: -.025em;
}

.settings-nav-head h2 {
  font-size: 20px;
}

.settings-panel-head h2 {
  font-size: 24px;
}

.settings-nav-head p,
.settings-panel-head p,
.settings-card p,
.settings-form-section-head p,
.settings-profile-preview p,
.settings-note-card p {
  margin: 0;
  color: #8a827d;
  font-size: 12px;
  line-height: 1.5;
}

.settings-section-nav {
  display: grid;
  gap: 7px;
  padding-top: 12px;
}

.settings-section-button {
  width: 100%;
  min-height: 58px;
  display: grid;
  grid-template-columns: 36px minmax(0,1fr);
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  color: #bdb5af;
  text-align: left;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, color .16s ease, transform .16s ease;
}

.settings-section-button:hover {
  transform: translateX(1px);
  border-color: rgba(255,255,255,.07);
  background: rgba(255,255,255,.025);
}

.settings-section-button.active {
  border-color: rgba(108,183,255,.20);
  background:
    linear-gradient(135deg, rgba(108,183,255,.10), rgba(108,183,255,.035));
  color: #e6f3ff;
}

.settings-section-icon {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(108,183,255,.14);
  border-radius: 10px;
  background: rgba(108,183,255,.05);
  color: #acd7ff;
}

.settings-section-icon.security {
  border-color: rgba(85,214,139,.16);
  background: rgba(85,214,139,.05);
  color: #9be5b6;
}

.settings-section-icon svg {
  width: 18px;
  height: 18px;
}

.settings-section-button strong {
  display: block;
  margin-bottom: 2px;
  font-size: 13px;
  font-weight: 720;
}

.settings-section-button small {
  display: block;
  color: #77706b;
  font-size: 12px;
  line-height: 1.35;
}

.settings-section-button.active small {
  color: #9aabb9;
}

.settings-content {
  min-width: 0;
}

.settings-panel[hidden] {
  display: none !important;
}

.settings-panel {
  padding: 18px;
  border-radius: 20px;
}

.settings-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
  padding: 0 2px;
}

.settings-card {
  position: relative;
  padding: 16px;
  border-radius: 16px;
}

.settings-card + .settings-card,
.settings-card + .settings-note-card,
.settings-account-form .settings-card + .settings-card {
  margin-top: 12px;
}

.settings-card-copy {
  display: flex;
  align-items: center;
  gap: 13px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.settings-card-copy h3,
.settings-profile-preview h3,
.settings-form-section-head h3 {
  margin: 0 0 4px;
  color: #ebe4de;
  font-size: 15px;
  font-weight: 720;
}

.settings-card-icon {
  width: 50px;
  height: 50px;
  flex: 0 0 50px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(255,159,70,.16);
  border-radius: 13px;
  background: rgba(255,159,70,.05);
}

.settings-card-icon img {
  width: 30px;
  height: 30px;
  object-fit: contain;
}

.settings-upload-form {
  display: grid;
  grid-template-columns: minmax(260px,1fr) auto;
  align-items: center;
  gap: 10px 12px;
  padding-top: 14px;
}

.settings-file-picker {
  min-height: 62px;
  display: grid;
  grid-template-columns: 38px minmax(0,1fr);
  align-items: center;
  gap: 10px;
  padding: 9px 11px;
  border: 1px dashed rgba(108,183,255,.22);
  border-radius: 12px;
  background: rgba(108,183,255,.025);
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease;
}

.settings-file-picker:hover {
  border-color: rgba(108,183,255,.38);
  background: rgba(108,183,255,.05);
}

.settings-file-picker input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.settings-file-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(108,183,255,.08);
  color: #acd7ff;
}

.settings-file-icon svg {
  width: 19px;
  height: 19px;
}

.settings-file-picker strong {
  display: block;
  color: #ddd5cf;
  font-size: 13px;
  font-weight: 700;
}

.settings-file-picker small,
.settings-file-name {
  color: #7f7772;
  font-size: 12px;
  line-height: 1.4;
}

.settings-file-name {
  grid-column: 1;
  padding-left: 2px;
}

.settings-save-button {
  grid-column: 2;
  grid-row: 1 / span 2;
  min-height: 42px;
  padding: 0 14px;
}

.settings-save-button svg,
.settings-save-account svg {
  width: 17px;
  height: 17px;
}

.settings-inline-reset {
  display: flex;
  justify-content: flex-end;
  margin-top: 10px;
}

.settings-note-card {
  display: grid;
  grid-template-columns: 34px minmax(0,1fr);
  gap: 10px;
  margin-top: 12px;
  padding: 12px 14px;
  border-color: rgba(108,183,255,.10);
  border-radius: 14px;
  background: rgba(108,183,255,.025);
}

.settings-note-card > span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(108,183,255,.08);
  color: #b8ddff;
  font-size: 14px;
  font-weight: 800;
}

.settings-note-card strong {
  display: block;
  margin-bottom: 2px;
  color: #dfeaf3;
  font-size: 13px;
}

.settings-account-form {
  display: grid;
  gap: 12px;
}

.settings-account-form .settings-card + .settings-card {
  margin-top: 0;
}

.settings-profile-card {
  display: grid;
  grid-template-columns: minmax(250px,.8fr) minmax(300px,1.2fr);
  gap: 14px;
  align-items: center;
}

.settings-profile-preview {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
}

.settings-profile-avatar {
  width: 68px;
  height: 68px;
  flex: 0 0 68px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 18px;
  background: rgba(255,255,255,.025);
  box-shadow: 0 9px 24px rgba(0,0,0,.14);
}

.settings-profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.settings-profile-preview h3 {
  margin-top: 3px;
  font-size: 18px;
}

.settings-profile-card .settings-file-name {
  grid-column: 2;
  margin-top: -7px;
}

.settings-form-card {
  padding: 15px 16px 16px;
}

.settings-form-section-head {
  display: grid;
  grid-template-columns: 36px minmax(0,1fr);
  align-items: center;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.settings-form-grid {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 12px;
  padding-top: 13px;
}

.settings-form-grid.three {
  grid-template-columns: repeat(3,minmax(0,1fr));
}

.settings-form-grid label {
  min-width: 0;
  color: #cfc7c1;
  font-size: 12px;
  font-weight: 720;
  letter-spacing: .035em;
}

.settings-form-grid input {
  width: 100%;
  min-height: 44px;
  margin-top: 6px;
  padding: 9px 11px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 11px;
  outline: none;
  background: rgba(0,0,0,.18);
  color: #eee7e1;
  font-size: 13px;
}

.settings-form-grid input:focus {
  border-color: rgba(108,183,255,.36);
  box-shadow: 0 0 0 3px rgba(108,183,255,.055);
}

.settings-form-grid input[readonly] {
  color: #8e8781;
  background: rgba(255,255,255,.015);
}

.settings-form-grid label > small {
  display: block;
  margin-top: 5px;
  color: #77706b;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0;
}

.settings-form-actions {
  display: flex;
  justify-content: flex-end;
  padding-top: 2px;
}

.settings-save-account {
  min-height: 43px;
  padding: 0 15px;
}

.settings-remove-avatar {
  display: flex;
  justify-content: flex-end;
  margin-top: 10px;
}

@media (max-width: 1050px) {
  .settings-page {
    grid-template-columns: 210px minmax(0,1fr);
  }

  .settings-profile-card,
  .settings-form-grid.three {
    grid-template-columns: 1fr;
  }

  .settings-profile-card .settings-file-name {
    grid-column: 1;
    margin-top: -5px;
  }
}

@media (max-width: 760px) {
  .settings-page {
    grid-template-columns: 1fr;
  }

  .settings-nav-card {
    position: relative;
    top: auto;
  }

  .settings-section-nav {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }

  .settings-upload-form,
  .settings-form-grid {
    grid-template-columns: 1fr;
  }

  .settings-save-button {
    grid-column: 1;
    grid-row: auto;
    width: 100%;
  }

  .settings-file-name {
    grid-column: 1;
  }
}

@media (max-width: 520px) {
  .settings-panel,
  .settings-nav-card {
    padding: 13px;
    border-radius: 16px;
  }

  .settings-section-nav {
    grid-template-columns: 1fr;
  }

  .settings-profile-card {
    grid-template-columns: 1fr;
  }

  .settings-profile-preview {
    align-items: flex-start;
  }

  .settings-file-picker {
    grid-template-columns: 34px minmax(0,1fr);
  }

  .settings-form-actions,
  .settings-inline-reset,
  .settings-remove-avatar {
    justify-content: stretch;
  }

  .settings-form-actions .button,
  .settings-inline-reset .button,
  .settings-remove-avatar .button {
    width: 100%;
  }
}


/* --- v0.16.41 plans page vertical spacing --- */
/* Pull the plans hero closer to the navigation. The previous main + hero padding
   stacked to roughly 100px and created a visually empty band below the header. */
.public-plans-page .plans-sales-main {
  padding-top: 18px;
}

.public-plans-page .plans-sales-hero {
  padding-top: 10px;
  padding-bottom: 22px;
}

.public-plans-page .plans-sales-copy,
.public-plans-page .plans-catalog-card {
  min-height: 390px;
}

@media (max-width: 1050px) {
  .public-plans-page .plans-sales-main {
    padding-top: 14px;
  }

  .public-plans-page .plans-sales-hero {
    padding-top: 8px;
  }
}

@media (max-width: 720px) {
  .public-plans-page .plans-sales-main {
    padding-top: 10px;
  }

  .public-plans-page .plans-sales-hero {
    padding-top: 6px;
    gap: 14px;
  }
}


/* --- v0.16.42 help page vertical spacing --- */
/* Match the tighter vertical rhythm used on the plans page. */
.help-page .help-v2-main {
  padding-top: 18px;
}

.help-page .help-v2-hero {
  margin-top: 8px;
  margin-bottom: 16px;
}

.help-page .help-v2-hero-copy,
.help-page .help-credentials-preview {
  min-height: 365px;
}

@media (max-width: 1050px) {
  .help-page .help-v2-main {
    padding-top: 14px;
  }

  .help-page .help-v2-hero {
    margin-top: 6px;
  }
}

@media (max-width: 720px) {
  .help-page .help-v2-main {
    width: min(100% - 28px, 1360px);
    padding-top: 10px;
    padding-bottom: 110px;
  }

  .help-page .help-v2-hero {
    margin-top: 4px;
    gap: 14px;
  }

  .help-page .help-v2-hero-copy,
  .help-page .help-credentials-preview {
    min-height: 0;
    padding: 24px;
  }
}


/* --- v0.16.45 PWA install + push notifications --- */
.pwa-install-backdrop[hidden] {
  display: none !important;
}

.pwa-install-backdrop {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(0,0,0,.70);
  backdrop-filter: blur(9px);
  -webkit-backdrop-filter: blur(9px);
}

.pwa-install-modal {
  position: relative;
  width: min(510px, 100%);
  overflow: hidden;
  padding: 22px;
  border: 1px solid rgba(255,177,91,.20);
  border-radius: 24px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,139,45,.16), transparent 18rem),
    linear-gradient(155deg, #171310, #0d0c0c 72%);
  box-shadow: 0 30px 90px rgba(0,0,0,.50), inset 0 1px 0 rgba(255,255,255,.04);
}

.pwa-install-close {
  position: absolute;
  top: 13px;
  right: 13px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  background: rgba(255,255,255,.025);
  color: #9b938d;
  font-size: 21px;
  cursor: pointer;
}

.pwa-install-brand {
  display: flex;
  align-items: center;
  gap: 13px;
  padding-right: 38px;
}

.pwa-install-icon {
  width: 58px;
  height: 58px;
  flex: 0 0 58px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 17px;
  background: #fff;
}

.pwa-install-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.pwa-install-brand .eyebrow {
  display: block;
  margin-bottom: 3px;
  color: #ffad55;
  font-size: 10px;
  font-weight: 820;
  letter-spacing: .11em;
}

.pwa-install-brand h2 {
  margin: 0;
  color: #f7f1ec;
  font-size: 23px;
  font-weight: 780;
  letter-spacing: -.025em;
}

.pwa-install-copy {
  margin: 16px 0 13px;
  color: #a49b95;
  font-size: 13px;
  line-height: 1.55;
}

.pwa-install-benefits {
  display: grid;
  gap: 7px;
  padding: 12px 13px;
  border: 1px solid rgba(85,214,139,.10);
  border-radius: 13px;
  background: rgba(85,214,139,.025);
}

.pwa-install-benefits span {
  color: #c7beb8;
  font-size: 12px;
  line-height: 1.35;
}

.pwa-install-ios-help {
  display: grid;
  gap: 4px;
  margin-top: 11px;
  padding: 11px 12px;
  border: 1px solid rgba(108,183,255,.14);
  border-radius: 12px;
  background: rgba(108,183,255,.04);
}

.pwa-install-ios-help[hidden] {
  display: none !important;
}

.pwa-install-ios-help strong {
  color: #cce7ff;
  font-size: 12px;
}

.pwa-install-ios-help span {
  color: #8ea0ae;
  font-size: 11px;
  line-height: 1.45;
}

.pwa-install-actions {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 9px;
  margin-top: 14px;
}

.pwa-install-actions .button {
  min-height: 43px;
  border-radius: 12px;
  font-size: 10.5px;
  letter-spacing: .04em;
}

.pwa-notification-button {
  border-color: rgba(108,183,255,.19) !important;
  color: #cce7ff !important;
  background: rgba(108,183,255,.05) !important;
}

.pwa-install-later {
  width: 100%;
  margin-top: 9px;
  padding: 7px 0 2px;
  border: 0;
  background: transparent;
  color: #79716c;
  font-size: 11px;
  cursor: pointer;
}

.pwa-install-status {
  min-height: 16px;
  display: block;
  margin-top: 7px;
  color: #847c76;
  font-size: 10.5px;
  line-height: 1.4;
  text-align: center;
}

.pwa-install-status[data-kind="success"] { color: #8ce7ae; }
.pwa-install-status[data-kind="warning"] { color: #ffc178; }
.pwa-install-status[data-kind="error"] { color: #ff8f86; }
.pwa-install-status[data-kind="info"] { color: #a9d4fa; }

.settings-section-icon.notifications {
  border-color: rgba(167,125,255,.17);
  background: rgba(167,125,255,.055);
  color: #cdb8ff;
}

.settings-push-metrics {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.settings-push-metric {
  min-width: 0;
  padding: 14px 15px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 15px;
  background:
    radial-gradient(circle at 100% 0%, rgba(167,125,255,.07), transparent 12rem),
    rgba(255,255,255,.018);
}

.settings-push-metric > span {
  display: block;
  color: #837a75;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .08em;
}

.settings-push-metric > strong {
  display: block;
  margin-top: 7px;
  color: #f0e9e3;
  font-size: 24px;
  font-weight: 750;
}

.settings-push-metric > small {
  display: block;
  margin-top: 4px;
  color: #817974;
  font-size: 10.5px;
  line-height: 1.4;
}

.settings-push-compose {
  padding: 15px 16px 16px;
}

.settings-push-form {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 12px;
  padding-top: 13px;
}

.settings-push-form label {
  min-width: 0;
  color: #cfc7c1;
  font-size: 11px;
  font-weight: 740;
  letter-spacing: .035em;
}

.settings-push-form label:nth-of-type(2) {
  grid-column: 1 / -1;
}

.settings-push-form input,
.settings-push-form textarea {
  width: 100%;
  margin-top: 6px;
  padding: 10px 11px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 11px;
  outline: none;
  background: rgba(0,0,0,.18);
  color: #eee7e1;
  font: inherit;
  font-size: 13px;
  resize: vertical;
}

.settings-push-form input {
  min-height: 44px;
}

.settings-push-form textarea {
  min-height: 92px;
}

.settings-push-form input:focus,
.settings-push-form textarea:focus {
  border-color: rgba(167,125,255,.34);
  box-shadow: 0 0 0 3px rgba(167,125,255,.055);
}

.settings-push-form label > small {
  display: block;
  margin-top: 5px;
  color: #77706b;
  font-size: 10.5px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0;
}

.settings-push-preview {
  min-height: 70px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 11px;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 12px;
  background: rgba(255,255,255,.018);
}

.settings-push-preview-icon {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  overflow: hidden;
  border-radius: 12px;
  background: #fff;
}

.settings-push-preview-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.settings-push-preview span {
  display: block;
  color: #746d68;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .08em;
}

.settings-push-preview strong {
  display: block;
  margin-top: 2px;
  color: #e9e1dc;
  font-size: 13px;
}

.settings-push-preview small {
  display: block;
  margin-top: 2px;
  color: #817975;
  font-size: 10px;
  line-height: 1.35;
}

.settings-push-send {
  min-height: 44px;
  align-self: center;
}

.settings-push-send svg {
  width: 17px;
  height: 17px;
}

.settings-push-send:disabled {
  opacity: .45;
  cursor: not-allowed;
}

@media (max-width: 760px) {
  .pwa-install-backdrop {
    align-items: end;
    padding: 12px;
  }

  .pwa-install-modal {
    width: 100%;
    padding: 18px;
    border-radius: 22px;
  }

  .pwa-install-actions {
    grid-template-columns: 1fr;
  }

  .settings-push-form,
  .settings-push-metrics {
    grid-template-columns: 1fr;
  }

  .settings-push-form label:nth-of-type(2) {
    grid-column: 1;
  }
}


/* --- v0.16.46 mobile nav four-column distribution --- */
/* The mobile menu has four real destinations. An old five-column grid was
   reserving a phantom fifth slot and leaving the visible hole on the right. */
@media (max-width: 850px) {
  .mobile-public-nav {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 4px;
    padding: 5px;
  }

  .mobile-public-nav a {
    width: 100%;
    min-width: 0;
    padding: 0 4px;
  }
}

@media (max-width: 430px) {
  .mobile-public-nav {
    left: 8px;
    right: 8px;
    gap: 3px;
    padding: 5px;
  }
}


/* --- v0.16.47 direct WhatsApp support --- */
.monkey-support-launcher.whatsapp-direct .monkey-support-badge.whatsapp {
  border-color: #090909;
  background: #25d366;
  color: #07170d;
}

.monkey-support-launcher.whatsapp-direct.is-ready::after {
  display: none;
}

.settings-section-icon.whatsapp {
  border-color: rgba(37,211,102,.18);
  background: rgba(37,211,102,.055);
  color: #8ce7ae;
}

.settings-whatsapp-form {
  display: grid;
  grid-template-columns: minmax(260px,.8fr) minmax(320px,1.2fr);
  gap: 14px;
  align-items: end;
  padding-top: 14px;
}

.settings-whatsapp-form > label {
  min-width: 0;
  color: #cfc7c1;
  font-size: 11px;
  font-weight: 740;
  letter-spacing: .035em;
}

.settings-whatsapp-input {
  min-height: 46px;
  display: grid;
  grid-template-columns: 42px minmax(0,1fr);
  align-items: center;
  margin-top: 6px;
  border: 1px solid rgba(37,211,102,.16);
  border-radius: 11px;
  overflow: hidden;
  background: rgba(0,0,0,.18);
}

.settings-whatsapp-input > span {
  height: 100%;
  display: grid;
  place-items: center;
  border-right: 1px solid rgba(255,255,255,.06);
  color: #8ce7ae;
  font-size: 15px;
  font-weight: 800;
}

.settings-whatsapp-input input {
  width: 100%;
  height: 44px;
  padding: 0 11px;
  border: 0;
  outline: none;
  background: transparent;
  color: #eee7e1;
  font-size: 13px;
}

.settings-whatsapp-form label > small {
  display: block;
  margin-top: 6px;
  color: #77706b;
  font-size: 10.5px;
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: 0;
}

.settings-whatsapp-examples {
  display: grid;
  gap: 7px;
  padding: 11px 12px;
  border: 1px solid rgba(37,211,102,.10);
  border-radius: 12px;
  background: rgba(37,211,102,.025);
}

.settings-whatsapp-examples > span {
  color: #7c887f;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .08em;
}

.settings-whatsapp-examples > div {
  display: grid;
  grid-template-columns: minmax(130px,.45fr) minmax(0,1fr);
  gap: 9px;
  align-items: center;
  padding-top: 7px;
  border-top: 1px solid rgba(255,255,255,.045);
}

.settings-whatsapp-examples strong {
  color: #d7e9dc;
  font-size: 11px;
}

.settings-whatsapp-examples small {
  color: #7d817e;
  font-size: 10px;
  line-height: 1.35;
}

.settings-whatsapp-form .settings-save-account {
  grid-column: 1 / -1;
  justify-self: end;
}

@media (max-width: 760px) {
  .settings-whatsapp-form {
    grid-template-columns: 1fr;
  }

  .settings-whatsapp-form .settings-save-account {
    grid-column: 1;
    justify-self: stretch;
    width: 100%;
  }

  .settings-whatsapp-examples > div {
    grid-template-columns: 1fr;
    gap: 2px;
  }
}


/* --- v0.16.48 access management actions aligned with Accounts --- */
.access-modal-icon-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.access-modal-icon-actions form {
  display: inline-flex;
  margin: 0;
}

.access-modal-icon-actions .plan-icon-button.access-management-button {
  width: 38px;
  height: 38px;
  border-color: rgba(255,159,70,.13);
  background: linear-gradient(135deg, rgba(255,139,42,.09), rgba(255,193,91,.025));
}

.access-modal-icon-actions .plan-icon-button.access-management-button:hover {
  border-color: rgba(255,159,70,.24);
  background: linear-gradient(135deg, rgba(255,139,42,.14), rgba(255,193,91,.045));
}

.access-modal-icon-actions .plan-icon-button.access-management-button.danger {
  color: #ff918b;
  border-color: rgba(255,93,86,.17);
  background: rgba(255,93,86,.04);
}

.access-modal-icon-actions .plan-icon-button.access-management-button.danger:hover {
  color: #ffb2ad;
  border-color: rgba(255,93,86,.27);
  background: rgba(255,93,86,.075);
}


/* --- v0.16.49 polished access modal + labelled actions --- */
.access-dialog {
  border: 1px solid rgba(255,255,255,.085);
  border-radius: 22px;
  background:
    radial-gradient(circle at 88% 0%, rgba(255,145,47,.075), transparent 28rem),
    linear-gradient(155deg, #11100f, #0c0b0b 62%, #0a0909);
  box-shadow: 0 34px 90px rgba(0,0,0,.58);
}

.access-modal {
  padding: 18px 20px 17px;
}

.access-modal-header.access-modal-header-compact {
  min-height: 60px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255,255,255,.065);
}

.access-modal-identity {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.access-modal-identity .modal-avatar {
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  border-radius: 13px;
  box-shadow: 0 8px 24px rgba(0,0,0,.20);
}

.access-modal-identity-copy {
  min-width: 0;
}

.access-modal-identity-copy > span {
  display: block;
  margin-bottom: 3px;
  color: #9d928a;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .07em;
}

.access-modal-identity-copy h2 {
  margin: 0;
  overflow: hidden;
  color: #f5f1ee;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-modal-identity-copy p {
  margin: 4px 0 0;
  overflow: hidden;
  color: #8c827c;
  font-size: 12px;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-modal-head-actions {
  align-items: center;
  gap: 8px;
}

.access-modal-head-actions .badge,
.access-modal-head-actions .access-owner-pill {
  min-height: 30px;
  padding: 0 11px;
  font-size: 12px;
  font-weight: 700;
}

.access-modal-header-compact .dialog-close {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  border-color: rgba(255,255,255,.085);
  background: rgba(255,255,255,.025);
}

.access-modal-service {
  margin: 13px 0;
  padding: 12px 14px 11px;
  border: 1px solid rgba(255,151,55,.16);
  border-radius: 14px;
  background:
    linear-gradient(100deg, rgba(255,143,45,.065), rgba(255,190,85,.022)),
    rgba(255,255,255,.012);
}

.access-modal-service-copy > span {
  font-size: 12px;
}

.access-modal-service-copy > strong {
  font-size: 14px;
}

.access-modal-service-copy > small {
  font-size: 12px;
}

.access-detail-layout-modern .access-detail-panel {
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 15px;
  background:
    linear-gradient(155deg, rgba(255,255,255,.026), rgba(255,255,255,.009));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.018);
}

.access-detail-layout-modern .access-account-panel {
  border-color: rgba(255,151,55,.14);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,151,55,.055), transparent 15rem),
    linear-gradient(155deg, rgba(255,255,255,.024), rgba(255,255,255,.008));
}

.access-detail-layout-modern .access-panel-heading > div > span,
.access-detail-layout-modern .access-account-title > div > span,
.access-commercial-summary .access-stat-grid span,
.access-commercial-summary .access-library-row > span {
  font-size: 12px;
}

.access-detail-layout-modern .access-panel-heading h3,
.access-detail-layout-modern .access-account-title h3 {
  font-size: 15px;
  font-weight: 700;
}

.access-detail-layout-modern .access-info-list > div,
.access-detail-layout-modern .access-credential-list > div {
  min-height: 41px;
}

.access-detail-layout-modern .access-info-list span,
.access-detail-layout-modern .access-credential-list > div > span {
  font-size: 12px;
}

.access-detail-layout-modern .access-info-list strong,
.access-detail-layout-modern .access-credential-list > div > strong,
.access-detail-layout-modern .access-credential-list .assigned-password-line {
  font-size: 13px;
}

.access-detail-layout-modern .access-secondary-action,
.access-detail-layout-modern .access-share-button,
.access-detail-layout-modern .assigned-account-note,
.access-detail-layout-modern .access-tv-card-head strong,
.access-detail-layout-modern .access-tv-card-head small {
  font-size: 12px;
}

.access-detail-layout-modern .access-account-title .access-card-account-avatar {
  width: 36px;
  height: 36px;
  flex-basis: 36px;
  border-radius: 11px;
}

.access-commercial-summary .access-stat-grid > div {
  min-height: 60px;
  border: 1px solid rgba(255,255,255,.055);
  background: rgba(0,0,0,.10);
}

.access-commercial-summary .access-stat-grid strong {
  font-size: 13px;
}

.access-commercial-summary .access-library-row .tag,
.access-commercial-summary .access-audit-line {
  font-size: 12px;
}

.access-modal-actions.access-modal-toolbar-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,.06);
}

.access-modal-toolbar-actions form {
  display: inline-flex;
  margin: 0;
}

.access-modal-toolbar-actions .account-toolbar-action {
  min-height: 40px;
  padding: 0 13px;
}

.access-modal-edit-button {
  border-color: rgba(255,159,70,.25) !important;
  background: linear-gradient(135deg, rgba(255,139,42,.12), rgba(255,193,91,.04)) !important;
  color: #ffc078 !important;
}

.access-modal-edit-button:hover {
  border-color: rgba(255,159,70,.44) !important;
  background: linear-gradient(135deg, rgba(255,139,42,.18), rgba(255,193,91,.07)) !important;
  color: #ffe0b8 !important;
}

.access-modal-sync-button {
  border-color: rgba(85,214,139,.24) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.11), rgba(85,214,139,.045)) !important;
  color: #a8ecc0 !important;
}

.access-modal-sync-button:hover {
  border-color: rgba(85,214,139,.42) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.17), rgba(85,214,139,.07)) !important;
  color: #d4f7df !important;
}

.access-modal-revoke-button {
  border-color: rgba(255,93,86,.22) !important;
  background: linear-gradient(135deg, rgba(255,93,86,.10), rgba(255,93,86,.035)) !important;
  color: #ff9b95 !important;
}

.access-modal-revoke-button:hover {
  border-color: rgba(255,93,86,.40) !important;
  background: linear-gradient(135deg, rgba(255,93,86,.16), rgba(255,93,86,.06)) !important;
  color: #ffc0bc !important;
}

@media (max-width: 700px) {
  .access-modal {
    padding: 14px;
  }

  .access-modal-header.access-modal-header-compact {
    align-items: flex-start;
    gap: 10px;
  }

  .access-modal-identity .modal-avatar {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
  }

  .access-modal-identity-copy h2 {
    font-size: 16px;
  }

  .access-modal-head-actions .access-owner-pill {
    display: none;
  }

  .access-modal-actions.access-modal-toolbar-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .access-modal-toolbar-actions > *,
  .access-modal-toolbar-actions form,
  .access-modal-toolbar-actions .account-toolbar-action {
    width: 100%;
  }

  .access-modal-toolbar-actions .account-toolbar-action {
    justify-content: center;
  }

  .access-modal-toolbar-actions form:last-child {
    grid-column: 1 / -1;
  }
}


/* --- v0.16.50 client ownership + repeat-sale workflow --- */
.client-crm-title { min-width: 0; }

.client-creator-line {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  margin-top: 6px;
  padding: 4px 7px;
  border: 1px solid rgba(108,183,255,.16);
  border-radius: 999px;
  background: rgba(108,183,255,.045);
  color: #9fcfff;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .035em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-creator-line.reseller {
  border-color: rgba(167,125,255,.22);
  background: rgba(151,107,255,.07);
  color: #d1bcff;
}

.client-card-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-left: auto;
}

.client-crm-footer .client-card-actions a { white-space: nowrap; }
.client-crm-footer .client-view-access { color: #a8a09a; }

.client-crm-footer .client-new-access {
  color: #ffb253;
  font-weight: 800;
}

.client-crm-footer .client-new-access:hover { color: #ffd09a; }

.access-existing-client-panel {
  border-color: rgba(108,183,255,.13);
  background:
    radial-gradient(circle at 100% 0%, rgba(108,183,255,.055), transparent 14rem),
    rgba(255,255,255,.012);
}

.access-existing-client-card {
  display: grid;
  grid-template-columns: 44px minmax(0,1fr) auto;
  align-items: center;
  gap: 11px;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  background: rgba(0,0,0,.12);
}

.access-existing-client-avatar {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,159,70,.18);
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(255,139,42,.15), rgba(130,89,255,.08));
  color: #ffc179;
  font-size: 16px;
  font-weight: 800;
}

.access-existing-client-card > div { min-width: 0; }

.access-existing-client-card > div > strong,
.access-existing-client-card > div > small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-existing-client-card > div > strong {
  color: #f2ece8;
  font-size: 14px;
}

.access-existing-client-card > div > small {
  margin-top: 3px;
  color: #8f857e;
  font-size: 12px;
}

.access-existing-client-owner {
  padding: 5px 8px;
  border: 1px solid rgba(108,183,255,.17);
  border-radius: 999px;
  color: #a9d4ff;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.access-existing-client-owner.reseller {
  border-color: rgba(167,125,255,.22);
  background: rgba(151,107,255,.06);
  color: #d5c2ff;
}

.access-existing-client-notes {
  display: grid;
  gap: 7px;
  margin-top: 12px;
  color: #9b918a;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .05em;
}

@media (max-width: 700px) {
  .client-crm-footer {
    align-items: flex-start;
    gap: 8px;
  }

  .client-card-actions {
    width: 100%;
    justify-content: space-between;
    margin-left: 0;
  }

  .access-existing-client-card {
    grid-template-columns: 40px minmax(0,1fr);
  }

  .access-existing-client-owner {
    grid-column: 1 / -1;
    justify-self: start;
  }
}


/* --- v0.16.51 wallet recharge via admin WhatsApp --- */
.wallet-recharge-dialog {
  width: min(560px, calc(100vw - 28px));
}

.wallet-recharge-intro {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 12px;
  border: 1px solid rgba(85,214,139,.14);
  border-radius: 12px;
  background: rgba(85,214,139,.035);
}

.wallet-recharge-intro .wallet-gateway-icon {
  flex: 0 0 42px;
  background: rgba(85,214,139,.09);
  color: #a8ecc0;
}

.wallet-recharge-intro .wallet-gateway-icon svg {
  width: 21px;
  height: 21px;
}

.wallet-recharge-intro > div {
  display: grid;
  gap: 4px;
}

.wallet-recharge-intro strong {
  color: #b7edca;
  font-size: 12px;
  letter-spacing: .055em;
}

.wallet-recharge-intro p {
  margin: 0;
  color: #837a74;
  font-size: 12px;
  line-height: 1.5;
}

.wallet-recharge-amount-label {
  display: grid;
  gap: 7px;
  margin-top: 13px;
  color: #978d86;
  font-size: 12px;
  font-weight: 750;
  letter-spacing: .055em;
}

.wallet-recharge-amount-label > small {
  color: #746d68;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0;
}

.wallet-recharge-money {
  min-height: 48px;
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 0 13px;
  border: 1px solid rgba(85,214,139,.18);
  border-radius: 12px;
  background: rgba(0,0,0,.14);
}

.wallet-recharge-money:focus-within {
  border-color: rgba(85,214,139,.38);
  box-shadow: 0 0 0 3px rgba(85,214,139,.055);
}

.wallet-recharge-money > span {
  color: #9ddfb6;
  font-size: 13px;
  font-weight: 800;
}

.wallet-recharge-money input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #f4efeb;
  font-size: 20px;
  font-weight: 800;
}

.wallet-recharge-actions .wallet-recharge-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-color: rgba(85,214,139,.28);
  background: linear-gradient(135deg, rgba(85,214,139,.18), rgba(85,214,139,.08));
  color: #c8f5d8;
}

.wallet-recharge-actions .wallet-recharge-submit:hover {
  border-color: rgba(85,214,139,.45);
  background: linear-gradient(135deg, rgba(85,214,139,.24), rgba(85,214,139,.11));
}

.wallet-recharge-actions .wallet-recharge-submit svg {
  width: 17px;
  height: 17px;
}

@media (max-width: 560px) {
  .wallet-recharge-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .wallet-recharge-actions .button {
    width: 100%;
  }
}


/* --- v0.16.52 pending wallet topups --- */
.wallet-overview {
  grid-template-columns: repeat(3, minmax(0,1fr));
}

.wallet-transaction-card.pending {
  border-color: rgba(248,199,94,.18);
  background:
    radial-gradient(circle at 100% 0%, rgba(248,199,94,.055), transparent 14rem),
    rgba(255,255,255,.014);
}

.wallet-transaction-card.pending::before {
  background: rgba(248,199,94,.60);
}

.wallet-transaction-card.pending .wallet-transaction-icon {
  background: rgba(248,199,94,.08);
  color: #f7d27a;
}

.wallet-transaction-status {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 7px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .06em;
}

.wallet-transaction-status.pending {
  border: 1px solid rgba(248,199,94,.20);
  background: rgba(248,199,94,.07);
  color: #f7d27a;
}

.wallet-transaction-card.pending .wallet-transaction-amount {
  color: #f7d27a;
}

.wallet-pending-admin.card {
  margin-bottom: 14px;
  padding: 15px 16px;
  border-color: rgba(248,199,94,.14);
  background:
    radial-gradient(circle at 100% 0%, rgba(248,199,94,.045), transparent 20rem),
    linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.01));
}

.wallet-pending-admin-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 11px;
}

.wallet-pending-admin-head h2 {
  margin: 3px 0;
  font-size: 17px;
}

.wallet-pending-admin-head p {
  margin: 0;
  color: #80766f;
  font-size: 12px;
}

.wallet-pending-count {
  min-width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(248,199,94,.20);
  border-radius: 10px;
  background: rgba(248,199,94,.07);
  color: #f7d27a;
  font-size: 13px;
  font-weight: 800;
}

.wallet-pending-list {
  display: grid;
  gap: 8px;
}

.wallet-pending-item {
  display: grid;
  grid-template-columns: minmax(220px,1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 11px 12px;
  border: 1px solid rgba(255,255,255,.065);
  border-radius: 12px;
  background: rgba(0,0,0,.10);
}

.wallet-pending-identity {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.wallet-pending-identity > div {
  min-width: 0;
}

.wallet-pending-identity strong,
.wallet-pending-identity small {
  display: block;
}

.wallet-pending-identity strong {
  color: #ebe4df;
  font-size: 13px;
}

.wallet-pending-identity small {
  margin-top: 3px;
  color: #817872;
  font-size: 11px;
}

.wallet-pending-request {
  text-align: right;
}

.wallet-pending-request span {
  display: block;
  color: #8a8079;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: .06em;
}

.wallet-pending-request strong {
  display: block;
  margin-top: 3px;
  color: #f7d27a;
  font-size: 14px;
}

.wallet-validate-button {
  border-color: rgba(85,214,139,.25) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.13), rgba(85,214,139,.05)) !important;
  color: #b8efcb !important;
}

.wallet-validate-button:hover {
  border-color: rgba(85,214,139,.43) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.20), rgba(85,214,139,.08)) !important;
}

@media (max-width: 900px) {
  .wallet-overview {
    grid-template-columns: 1fr;
  }

  .wallet-pending-item {
    grid-template-columns: 1fr auto;
  }

  .wallet-pending-item form {
    grid-column: 1 / -1;
  }

  .wallet-pending-item form,
  .wallet-pending-item .wallet-validate-button {
    width: 100%;
  }

  .wallet-pending-item .wallet-validate-button {
    justify-content: center;
  }
}


/* --- v0.16.53 team readability + rejected topups --- */
.team-toolbar p,
.staff-card-head small,
.staff-admin-note,
.staff-wallet-balance span,
.staff-wallet-stats span,
.wallet-admin-current span,
.wallet-pending-admin-head p,
.wallet-pending-identity small,
.wallet-pending-request span,
.team-reseller-info small {
  font-size: 12px;
}

.staff-wallet-stats strong {
  font-size: 13px;
}

.wallet-pending-identity strong {
  font-size: 14px;
}

.wallet-pending-request strong {
  font-size: 15px;
}

.wallet-pending-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
}

.wallet-pending-actions form {
  display: inline-flex;
  margin: 0;
}

.wallet-reject-button {
  border-color: rgba(255,93,86,.23) !important;
  background: linear-gradient(135deg, rgba(255,93,86,.11), rgba(255,93,86,.04)) !important;
  color: #ffaaa5 !important;
}

.wallet-reject-button:hover {
  border-color: rgba(255,93,86,.42) !important;
  background: linear-gradient(135deg, rgba(255,93,86,.17), rgba(255,93,86,.07)) !important;
  color: #ffd0cd !important;
}

.wallet-transaction-card.rejected {
  border-color: rgba(255,93,86,.16);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,93,86,.04), transparent 14rem),
    rgba(255,255,255,.012);
}

.wallet-transaction-card.rejected::before {
  background: rgba(255,93,86,.48);
}

.wallet-transaction-card.rejected .wallet-transaction-icon,
.wallet-transaction-card.rejected .wallet-transaction-amount {
  color: #ffaaa5;
}

.wallet-transaction-card.rejected .wallet-transaction-icon {
  background: rgba(255,93,86,.07);
}

.wallet-transaction-status.rejected {
  border: 1px solid rgba(255,93,86,.19);
  background: rgba(255,93,86,.06);
  color: #ffaaa5;
}

@media (max-width: 900px) {
  .wallet-pending-actions {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .wallet-pending-actions form,
  .wallet-pending-actions .account-toolbar-action {
    width: 100%;
  }

  .wallet-pending-actions .account-toolbar-action {
    justify-content: center;
  }
}


/* --- v0.16.54 staff editing and access control --- */
.staff-card-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 7px;
}

.staff-card-actions form {
  display: flex;
  margin: 0;
}

.staff-card-actions .account-toolbar-action,
.staff-card-actions form .account-toolbar-action {
  width: 100%;
  justify-content: center;
}

.staff-edit-button {
  border-color: rgba(108,183,255,.22) !important;
  background: linear-gradient(135deg, rgba(108,183,255,.11), rgba(108,183,255,.04)) !important;
  color: #b9ddff !important;
}

.staff-edit-button:hover {
  border-color: rgba(108,183,255,.40) !important;
  background: linear-gradient(135deg, rgba(108,183,255,.17), rgba(108,183,255,.065)) !important;
}

.staff-disable-button {
  border-color: rgba(255,93,86,.20) !important;
  background: linear-gradient(135deg, rgba(255,93,86,.09), rgba(255,93,86,.035)) !important;
  color: #ffaaa5 !important;
}

.staff-disable-button:hover {
  border-color: rgba(255,93,86,.38) !important;
  background: linear-gradient(135deg, rgba(255,93,86,.15), rgba(255,93,86,.06)) !important;
}

.staff-enable-button {
  border-color: rgba(85,214,139,.23) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.11), rgba(85,214,139,.04)) !important;
  color: #b8efcb !important;
}

.staff-enable-button:hover {
  border-color: rgba(85,214,139,.41) !important;
  background: linear-gradient(135deg, rgba(85,214,139,.17), rgba(85,214,139,.07)) !important;
}

.staff-card.inactive,
.staff-card:has(.service-account-status.disabled) {
  opacity: .78;
}

.staff-card:has(.service-account-status.disabled) .staff-card-avatar {
  filter: grayscale(.45);
}

.staff-edit-dialog {
  width: min(620px, calc(100vw - 28px));
}

.staff-edit-security-note {
  display: grid;
  gap: 4px;
  margin-top: 4px;
  padding: 11px 12px;
  border: 1px solid rgba(248,199,94,.13);
  border-radius: 11px;
  background: rgba(248,199,94,.035);
}

.staff-edit-security-note strong {
  color: #e5c879;
  font-size: 12px;
  letter-spacing: .055em;
}

.staff-edit-security-note small {
  color: #8b8179;
  font-size: 12px;
  line-height: 1.45;
}

@media (max-width: 560px) {
  .staff-card-actions {
    grid-template-columns: 1fr;
  }
}


/* --- v0.16.55 reseller activity metrics --- */
.staff-activity-stats {
  display: grid;
  grid-template-columns: .8fr .8fr 1.7fr;
  gap: 6px;
}

.staff-activity-stats > div {
  min-width: 0;
  display: grid;
  gap: 4px;
  min-height: 58px;
  padding: 9px 10px;
  border: 1px solid rgba(108,183,255,.075);
  border-radius: 10px;
  background:
    linear-gradient(145deg, rgba(108,183,255,.026), rgba(0,0,0,.08));
}

.staff-activity-stats span {
  color: #7f7873;
  font-size: 12px;
  font-weight: 750;
  letter-spacing: .065em;
}

.staff-activity-stats strong {
  color: #dcd6d1;
  font-size: 13px;
  line-height: 1.25;
}

.staff-activity-stats .last-login strong {
  overflow: hidden;
  color: #a9d4ff;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 560px) {
  .staff-activity-stats {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .staff-activity-stats .last-login {
    grid-column: 1 / -1;
  }
}


/* --- v0.16.56 staff deletion + reseller self-edit --- */
.staff-card-actions {
  grid-template-columns: repeat(3, minmax(0,1fr));
}

.staff-delete-button {
  border-color: rgba(255,69,69,.28) !important;
  background: linear-gradient(135deg, rgba(255,69,69,.14), rgba(120,25,25,.07)) !important;
  color: #ff9c98 !important;
}

.staff-delete-button:hover {
  border-color: rgba(255,69,69,.50) !important;
  background: linear-gradient(135deg, rgba(255,69,69,.22), rgba(120,25,25,.10)) !important;
  color: #ffd0cd !important;
}

@media (max-width: 720px) {
  .staff-card-actions {
    grid-template-columns: 1fr;
  }
}


/* --- v0.16.57 client management permissions --- */
.staff-card-actions {
  grid-template-columns: repeat(2, minmax(0,1fr));
}

.client-card-actions {
  flex-wrap: wrap;
}

.client-card-actions form {
  display: inline-flex;
  margin: 0;
}

.client-manage-action {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 0 8px;
  border: 1px solid rgba(108,183,255,.18);
  border-radius: 8px;
  background: rgba(108,183,255,.045);
  color: #b9ddff;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.client-manage-action svg {
  width: 13px;
  height: 13px;
}

.client-manage-action.edit:hover {
  border-color: rgba(108,183,255,.36);
  background: rgba(108,183,255,.09);
}

.client-manage-action.delete {
  border-color: rgba(255,93,86,.20);
  background: rgba(255,93,86,.045);
  color: #ffaaa5;
}

.client-manage-action.delete:hover {
  border-color: rgba(255,93,86,.38);
  background: rgba(255,93,86,.09);
}

.client-edit-dialog {
  width: min(620px, calc(100vw - 28px));
}

.client-edit-note {
  display: grid;
  gap: 4px;
  margin-top: 4px;
  padding: 11px 12px;
  border: 1px solid rgba(108,183,255,.12);
  border-radius: 11px;
  background: rgba(108,183,255,.03);
}

.client-edit-note strong {
  color: #a9d4ff;
  font-size: 12px;
  letter-spacing: .055em;
}

.client-edit-note small {
  color: #887f78;
  font-size: 12px;
  line-height: 1.45;
}

@media (max-width: 720px) {
  .staff-card-actions {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .client-card-actions {
    width: 100%;
    justify-content: flex-start;
  }
}


/* --- v0.16.58 mobile operations nav + 3-step access wizard --- */
.admin-mobile-bottom-nav {
  display: none;
}

.admin-new-access-mobile {
  display: none;
}

.access-sale-progress-3 {
  display: grid;
  gap: 9px;
  padding: 11px 18px;
  border-bottom: 1px solid rgba(255,255,255,.06);
  background: rgba(255,255,255,.012);
}

.access-sale-progress-counter {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.access-sale-progress-counter strong {
  color: #ffc16f;
  font-size: 13px;
  font-weight: 850;
}

.access-sale-progress-counter span {
  color: #99908a;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
}

.access-sale-progress-track {
  height: 4px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255,255,255,.055);
}

.access-sale-progress-track > span {
  display: block;
  width: 33.333%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #ff9434, #ffc15d);
  transition: width .2s ease;
}

.access-sale-progress-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 7px;
}

.access-sale-progress-steps > span {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  color: #6f6964;
}

.access-sale-progress-steps i {
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 50%;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.access-sale-progress-steps b {
  overflow: hidden;
  font-size: 12px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-sale-progress-steps > span.active {
  color: #ffd18f;
}

.access-sale-progress-steps > span.active i {
  border-color: rgba(255,159,70,.38);
  background: rgba(255,159,70,.12);
  color: #ffc16f;
}

.access-sale-progress-steps > span.complete {
  color: #9adfb3;
}

.access-sale-progress-steps > span.complete i {
  border-color: rgba(85,214,139,.30);
  background: rgba(85,214,139,.09);
  color: #9fe1b6;
}

.access-sale-stage-client,
.access-sale-stage-payment {
  min-width: 0;
}

.access-sale-stage-client .access-sale-client-panel,
.access-sale-stage-payment .access-sale-payment-panel {
  min-width: 0;
  padding: 20px;
}

.access-sale-stage-client .access-sale-client-panel .form-grid.two {
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 13px;
}

.access-sale-stage-payment .access-sale-payment-panel .payment-grid {
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 13px;
}

.access-sale-stage-client.is-active,
.access-sale-stage-payment.is-active {
  animation: access-sale-step-in .18s ease both;
}

@media (max-width: 820px) {
  body.app-shell {
    padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px));
  }

  .admin-mobile-bottom-nav {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: max(8px, env(safe-area-inset-bottom, 8px));
    z-index: 115;
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    min-height: 62px;
    padding: 5px;
    border: 1px solid rgba(255,255,255,.09);
    border-radius: 17px;
    background: rgba(13,12,11,.94);
    box-shadow: 0 18px 44px rgba(0,0,0,.42);
    backdrop-filter: blur(18px);
  }

  .admin-mobile-bottom-nav a {
    min-width: 0;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 3px;
    padding: 5px 2px;
    border-radius: 12px;
    color: #817973;
    text-decoration: none;
    transition: background .16s ease, color .16s ease, transform .16s ease;
  }

  .admin-mobile-bottom-nav a svg {
    width: 21px;
    height: 21px;
  }

  .admin-mobile-bottom-nav a span {
    overflow: hidden;
    max-width: 100%;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .025em;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .admin-mobile-bottom-nav a.active {
    background: linear-gradient(145deg, rgba(255,145,48,.14), rgba(255,190,84,.05));
    color: #ffc078;
  }

  .admin-mobile-bottom-nav a:active {
    transform: scale(.96);
  }

  .admin-page,
  body.app-shell .page {
    padding-bottom: 28px;
  }
}

@media (max-width: 700px) {
  .admin-topbar.admin-topbar-side {
    padding-inline: 10px;
  }

  .admin-topbar-side .admin-new-access {
    width: auto;
    min-width: 92px;
    height: 38px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-color: rgba(255,159,70,.22);
    background: rgba(255,159,70,.075);
    color: #ffc078;
    font-size: 12px;
    font-weight: 850;
    letter-spacing: .02em;
  }

  .admin-topbar-side .admin-new-access::after {
    content: none;
  }

  .admin-new-access-desktop {
    display: none;
  }

  .admin-new-access-mobile {
    display: inline;
  }

  .access-create-dialog.access-sale-dialog {
    width: 100vw;
    max-width: 100vw;
    height: 100dvh;
    max-height: 100dvh;
    margin: 0;
    border: 0;
    border-radius: 0;
  }

  .access-create-modal.access-sale-modal {
    height: 100dvh;
    max-height: 100dvh;
    border-radius: 0;
  }

  .access-sale-header {
    min-height: 58px;
    padding: 9px 12px;
  }

  .access-sale-heading h2 {
    font-size: 17px;
  }

  .access-sale-header .reseller-sale-wallet {
    display: none;
  }

  .access-sale-progress-3 {
    padding: 9px 12px 8px;
  }

  .access-sale-wizard-body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 10px 10px 14px;
  }

  .access-sale-stage-plan {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .access-sale-stage-plan .access-sale-summary {
    display: none;
  }

  .access-sale-stage-plan .plan-step,
  .access-sale-stage-client .access-sale-client-panel,
  .access-sale-stage-payment .access-sale-payment-panel {
    padding: 13px;
    border-radius: 14px;
  }

  .access-sale-stage-plan .access-plan-picker {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .access-sale-stage-plan .access-plan-option-card {
    min-height: 0;
    padding: 12px;
  }

  .access-sale-stage-client .access-sale-client-panel .form-grid.two,
  .access-sale-stage-payment .access-sale-payment-panel .payment-grid {
    grid-template-columns: 1fr;
  }

  .access-sale-stage-client .client-notes-field {
    grid-column: auto;
  }

  .access-sale-actions {
    position: sticky;
    bottom: 0;
    z-index: 5;
    min-height: 66px;
    display: grid;
    grid-template-columns: minmax(0,.8fr) minmax(0,1.2fr);
    gap: 8px;
    padding: 9px 10px calc(9px + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid rgba(255,255,255,.07);
    background: rgba(13,12,11,.96);
    backdrop-filter: blur(16px);
  }

  .access-sale-actions .access-sale-next,
  .access-sale-actions .access-sale-submit {
    width: 100%;
    min-width: 0;
    margin: 0;
    grid-column: 2;
  }

  .access-sale-actions .access-sale-back {
    width: 100%;
    min-width: 0;
    margin: 0;
    grid-column: 1;
  }

  #access-create-dialog[data-step="1"] .access-sale-actions {
    grid-template-columns: 1fr;
  }

  #access-create-dialog[data-step="1"] .access-sale-next {
    grid-column: 1;
  }

  .access-sale-actions .button {
    min-height: 44px;
    font-size: 12px;
  }

  .access-sale-step .access-create-section-title strong,
  .access-sale-step label,
  .access-sale-step label > small,
  .access-sale-progress-counter span {
    font-size: 12px;
  }
}


/* --- v0.16.60 mobile access layout + adaptive bottom sheet --- */
@media (max-width: 820px) {
  body.app-shell,
  .admin-layout-shell,
  .admin-shell-main,
  .admin-page {
    max-width: 100%;
    overflow-x: hidden;
  }

  .access-toolbar.card,
  .access-toolbar-right,
  .access-filters,
  .access-toolbar-actions,
  .access-grid,
  .access-client-card {
    max-width: 100%;
    min-width: 0;
  }

  .access-toolbar.card {
    overflow: hidden;
  }

  .access-search {
    width: 100%;
    max-width: 100%;
    flex-basis: 100%;
  }

  .access-toolbar-right {
    width: 100%;
    align-items: stretch;
  }

  .access-filters {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: 7px;
    overflow: visible;
    flex-wrap: initial;
  }

  .access-filter {
    width: 100%;
    min-width: 0;
    min-height: 40px;
    padding: 0 8px;
    line-height: 1.15;
    white-space: normal;
    text-align: center;
  }

  .access-toolbar-actions {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: 8px;
  }

  .access-toolbar-actions form,
  .access-toolbar-actions .account-toolbar-action {
    width: 100%;
    min-width: 0;
  }

  .access-toolbar-actions .account-toolbar-action {
    justify-content: center;
    min-height: 42px;
    padding-inline: 8px;
    font-size: 12px;
  }

  .access-card-service > div:first-child,
  .access-card-account {
    min-width: 0;
  }

  .access-card-service > div:first-child strong,
  .access-card-account-copy,
  .access-card-account-copy strong {
    min-width: 0;
    overflow-wrap: anywhere;
  }
}

@media (max-width: 700px) {
  .admin-topbar-side .admin-new-access {
    border-color: rgba(108,183,255,.28);
    background: linear-gradient(135deg, rgba(108,183,255,.14), rgba(108,183,255,.055));
    color: #b8ddff;
    box-shadow: none;
  }

  .admin-topbar-side .admin-new-access:hover,
  .admin-topbar-side .admin-new-access:focus-visible {
    border-color: rgba(108,183,255,.46);
    background: linear-gradient(135deg, rgba(108,183,255,.21), rgba(108,183,255,.085));
    color: #e0f1ff;
  }

  .access-create-dialog.access-sale-dialog {
    position: fixed;
    inset: auto 0 0 0;
    width: 100%;
    max-width: 100%;
    height: auto;
    max-height: min(88dvh, 820px);
    margin: auto 0 0;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,.10);
    border-bottom: 0;
    border-radius: 22px 22px 0 0;
    box-shadow: 0 -24px 70px rgba(0,0,0,.62);
  }

  .access-create-dialog.access-sale-dialog[open] {
    animation: monkey-access-sheet-in .22s ease both;
  }

  .access-create-dialog.access-sale-dialog::backdrop {
    background: rgba(0,0,0,.68);
    backdrop-filter: blur(8px);
  }

  .access-create-modal.access-sale-modal {
    width: 100%;
    height: auto;
    max-height: min(88dvh, 820px);
    overflow: hidden;
    border-radius: 22px 22px 0 0;
  }

  .access-sale-header {
    flex: 0 0 auto;
    min-height: 54px;
    padding: 8px 12px;
  }

  .access-sale-progress-3 {
    flex: 0 0 auto;
  }

  .access-sale-wizard-body {
    min-height: 0;
    flex: 0 1 auto;
    max-height: calc(88dvh - 176px);
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: auto;
  }

  .access-sale-stage,
  .access-sale-step,
  .access-plan-picker,
  .access-plan-option,
  .access-plan-option-card,
  .access-existing-client-card,
  .access-sale-payment-panel,
  .access-sale-client-panel {
    max-width: 100%;
    min-width: 0;
  }

  .access-sale-actions {
    position: relative;
    flex: 0 0 auto;
    bottom: auto;
    padding-bottom: calc(9px + env(safe-area-inset-bottom, 0px));
  }
}

@media (max-width: 430px) {
  .access-toolbar.card {
    padding: 8px;
  }

  .access-filter {
    min-height: 42px;
    font-size: 12px;
  }

  .access-toolbar-actions {
    grid-template-columns: 1fr 1fr;
  }

  .access-sale-progress-steps {
    gap: 4px;
  }

  .access-sale-progress-steps > span {
    gap: 4px;
  }
}

@keyframes monkey-access-sheet-in {
  from {
    opacity: .84;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}


/* --- v0.16.61 coherent mobile login --- */
.login-public-back {
  min-height: 40px;
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 11px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 11px;
  background: rgba(255,255,255,.025);
  color: #c8c0ba;
  font-size: 12px;
  font-weight: 750;
  letter-spacing: .035em;
  text-decoration: none;
  transition: border-color .16s ease, background .16s ease, color .16s ease, transform .16s ease;
}

.login-public-back svg {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
}

.login-public-back:hover {
  transform: translateY(-1px);
  border-color: rgba(255,159,70,.20);
  background: rgba(255,159,70,.055);
  color: #ffd09a;
}

@media (max-width: 680px) {
  .auth-main {
    min-height: 100dvh;
    display: block;
    padding: 0;
    background:
      radial-gradient(circle at 90% 0%, rgba(255,145,47,.08), transparent 18rem),
      #0d0b0a;
  }

  .login-shell {
    width: 100%;
    min-height: 100dvh;
    display: block;
    border: 0;
    border-radius: 0;
    background: #0d0b0a;
    box-shadow: none;
  }

  .login-brand-panel {
    min-height: 0;
    display: grid;
    justify-content: stretch;
    gap: 18px;
    padding: 20px 20px 18px;
    border-bottom: 1px solid rgba(255,255,255,.065);
    background:
      radial-gradient(circle at 88% 0%, rgba(255,171,72,.18), transparent 16rem),
      radial-gradient(circle at 0% 100%, rgba(141,114,255,.10), transparent 18rem),
      linear-gradient(155deg, #21150f, #151014 70%, #17121c);
  }

  .login-brand-panel::after {
    opacity: .45;
  }

  .login-logo {
    width: 112px;
    padding: 8px;
    border-radius: 14px;
    box-shadow: 0 10px 28px rgba(0,0,0,.16);
  }

  .login-brand-copy {
    display: grid;
    gap: 0;
    max-width: none;
  }

  .login-brand-copy .eyebrow {
    font-size: 12px;
    letter-spacing: .075em;
  }

  .login-brand-copy h1 {
    margin: 6px 0 8px;
    max-width: 330px;
    font-size: clamp(32px, 9vw, 40px);
    line-height: .96;
    letter-spacing: -.045em;
  }

  .login-brand-copy p {
    max-width: 340px;
    margin: 0;
    color: #aaa19b;
    font-size: 13px;
    line-height: 1.5;
  }

  .login-public-back {
    margin-top: 15px;
    min-height: 42px;
    padding-inline: 12px;
    border-color: rgba(108,183,255,.18);
    background: rgba(108,183,255,.045);
    color: #b8ddff;
  }

  .login-card {
    justify-content: flex-start;
    padding: 22px 20px calc(26px + env(safe-area-inset-bottom, 0px));
    background:
      linear-gradient(180deg, rgba(255,255,255,.012), transparent 15rem),
      #100e0d;
  }

  .login-avatar {
    width: 52px;
    height: 52px;
    margin-bottom: 14px;
  }

  .login-card > .eyebrow {
    font-size: 12px;
    letter-spacing: .075em;
  }

  .login-card h2 {
    margin: 5px 0 6px;
    font-size: 25px;
    line-height: 1.05;
  }

  .login-card > p {
    margin: 0 0 16px;
    max-width: 360px;
    font-size: 13px;
    line-height: 1.5;
  }

  .login-card .stack {
    gap: 12px;
  }

  .login-card .stack label {
    font-size: 12px;
    font-weight: 750;
  }

  .login-card .stack input {
    min-height: 48px;
    margin-top: 6px;
    padding: 0 13px;
    border-radius: 12px;
    font-size: 14px;
  }

  .login-card .stack .button.primary {
    min-height: 48px;
    margin-top: 2px;
    border-radius: 12px;
    font-size: 13px;
  }

  .login-card .compact-alert {
    margin-top: 12px;
  }
}

@media (max-width: 380px) {
  .login-brand-panel {
    padding-inline: 16px;
  }

  .login-card {
    padding-inline: 16px;
  }

  .login-brand-copy h1 {
    font-size: 31px;
  }
}


/* --- v0.16.62 unified compact phone field --- */
.client-phone-field {
  min-width: 0;
}

.form-grid.two > .client-phone-field {
  grid-column: 1 / -1;
}

.client-phone-input {
  width: 100%;
  min-width: 0;
  min-height: 46px;
  display: grid;
  grid-template-columns: 76px 1px minmax(0,1fr);
  align-items: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 11px;
  background: rgba(8,8,9,.6);
  transition: border-color .16s ease, box-shadow .16s ease;
}

.client-phone-input:focus-within {
  border-color: rgba(108,183,255,.34);
  box-shadow: 0 0 0 3px rgba(108,183,255,.045);
}

.client-phone-input .country-code-input,
.client-phone-input .client-phone-number {
  width: 100%;
  min-width: 0;
  height: 44px;
  margin: 0;
  padding: 0 12px;
  border: 0;
  border-radius: 0;
  outline: 0;
  background: transparent;
  box-shadow: none;
}

.client-phone-input .country-code-input {
  padding-right: 7px;
  color: #d9d2cd;
  font-weight: 800;
  text-align: center;
}

.client-phone-input .client-phone-number {
  padding-left: 12px;
}

.client-phone-separator {
  width: 1px;
  height: 24px;
  background: rgba(255,255,255,.09);
}

.client-phone-field > small {
  margin-top: 6px;
}

@media (max-width: 700px) {
  .client-phone-input {
    grid-template-columns: 68px 1px minmax(0,1fr);
  }

  .client-phone-input .country-code-input {
    padding-inline: 6px;
    font-size: 13px;
  }

  .client-phone-input .client-phone-number {
    font-size: 14px;
  }
}


/* --- v0.16.64 Plex inventory explorer --- */
.content-inventory {
  margin-bottom: 16px;
  padding: 18px;
}

.content-inventory-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.content-inventory-head h2 {
  margin: 4px 0 4px;
}

.content-inventory-head p {
  margin: 0;
  color: #8f8781;
  font-size: 12px;
}

.content-inventory-sync-state {
  flex: 0 0 auto;
  display: grid;
  gap: 2px;
  text-align: right;
}

.content-inventory-sync-state span {
  color: #7e7670;
  font-size: 12px;
  font-weight: 750;
  letter-spacing: .07em;
}

.content-inventory-sync-state strong {
  color: #ffc16f;
  font-size: 14px;
}

.content-library-tabs {
  display: flex;
  gap: 8px;
  padding: 3px 0 12px;
  overflow-x: auto;
  scrollbar-width: none;
}

.content-library-tabs::-webkit-scrollbar {
  display: none;
}

.content-library-tab {
  min-width: 210px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 13px;
  background: rgba(255,255,255,.018);
  color: #d2cbc6;
  text-align: left;
  cursor: pointer;
}

.content-library-tab:hover {
  border-color: rgba(255,159,70,.20);
}

.content-library-tab.active {
  border-color: rgba(255,159,70,.30);
  background: linear-gradient(145deg, rgba(255,159,70,.10), rgba(255,159,70,.035));
  box-shadow: inset 3px 0 0 rgba(255,159,70,.55);
}

.content-library-tab-icon {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(255,159,70,.08);
  color: #ffb45f;
}

.content-library-tab-icon svg {
  width: 20px;
  height: 20px;
}

.content-library-tab > span:last-child {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.content-library-tab strong,
.content-library-tab small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-library-tab strong {
  color: #eee8e4;
  font-size: 13px;
}

.content-library-tab small {
  color: #817a75;
  font-size: 12px;
}

.content-inventory-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 1px 0 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,.055);
}

.content-inventory-search {
  width: min(520px, 100%);
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 11px;
  background: rgba(0,0,0,.12);
}

.content-inventory-search svg {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  color: #756e69;
}

.content-inventory-search input {
  width: 100%;
  min-width: 0;
  height: 40px;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: #ece6e1;
  font-size: 12px;
}

.content-inventory-status {
  display: grid;
  gap: 2px;
  text-align: right;
}

.content-inventory-status span {
  color: #817a74;
  font-size: 12px;
}

.content-inventory-status strong {
  color: #d9d2cd;
  font-size: 13px;
}

.content-inventory-grid {
  display: grid;
  grid-template-columns: repeat(8, minmax(0,1fr));
  gap: 14px 10px;
}

.content-inventory-card {
  min-width: 0;
  display: grid;
  gap: 7px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.content-inventory-poster {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 11px;
  background: #161413;
  box-shadow: 0 10px 25px rgba(0,0,0,.18);
}

.content-inventory-poster img,
.content-inventory-placeholder {
  width: 100%;
  height: 100%;
}

.content-inventory-poster img {
  display: block;
  object-fit: cover;
  transition: transform .22s ease, filter .22s ease;
}

.content-inventory-card:hover .content-inventory-poster img {
  transform: scale(1.035);
  filter: brightness(1.06);
}

.content-inventory-placeholder {
  display: grid;
  place-items: center;
  color: #5d5753;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .08em;
}

.content-inventory-poster i {
  position: absolute;
  left: 7px;
  bottom: 7px;
  padding: 4px 6px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 999px;
  background: rgba(5,5,5,.72);
  color: #f0e9e4;
  font-size: 10px;
  font-style: normal;
  font-weight: 850;
  letter-spacing: .05em;
  backdrop-filter: blur(6px);
}

.content-inventory-copy {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.content-inventory-copy strong,
.content-inventory-copy span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-inventory-copy strong {
  color: #e9e3df;
  font-size: 12px;
}

.content-inventory-copy span {
  color: #817a74;
  font-size: 12px;
}

.content-inventory-loading,
.content-inventory-empty {
  grid-column: 1 / -1;
  min-height: 180px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  border: 1px dashed rgba(255,255,255,.08);
  border-radius: 14px;
  color: #8d857f;
  text-align: center;
}

.content-inventory-empty strong,
.content-inventory-loading strong {
  color: #d9d2cd;
  font-size: 13px;
}

.content-inventory-empty span {
  max-width: 520px;
  color: #817a74;
  font-size: 12px;
}

.content-inventory-empty.error strong {
  color: #ffaaa5;
}

.content-loader {
  width: 24px;
  height: 24px;
  border: 2px solid rgba(255,255,255,.08);
  border-top-color: #ffad50;
  border-radius: 50%;
  animation: content-loader-spin .7s linear infinite;
}

.content-inventory-more {
  display: flex;
  justify-content: center;
  padding-top: 16px;
}

.content-detail-dialog {
  width: min(820px, calc(100vw - 28px));
  max-height: min(86dvh, 860px);
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 18px;
  background: #12100f;
  color: #eee8e4;
  box-shadow: 0 28px 90px rgba(0,0,0,.65);
}

.content-detail-dialog::backdrop {
  background: rgba(0,0,0,.72);
  backdrop-filter: blur(7px);
}

.content-detail-modal {
  max-height: min(86dvh, 860px);
  display: flex;
  flex-direction: column;
}

.content-detail-head {
  flex: 0 0 auto;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(255,255,255,.06);
  background: radial-gradient(circle at 100% 0%, rgba(255,159,70,.07), transparent 18rem);
}

.content-detail-head h2 {
  margin: 4px 0 3px;
}

.content-detail-head p {
  margin: 0;
  color: #857d77;
  font-size: 12px;
}

.content-detail-body {
  min-height: 0;
  overflow-y: auto;
  padding: 18px;
}

.content-detail-summary {
  margin-bottom: 14px;
  color: #b5ada7;
  font-size: 13px;
  line-height: 1.6;
}

.content-detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}

.content-detail-tags span {
  padding: 5px 8px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 999px;
  background: rgba(255,255,255,.025);
  color: #9f9791;
  font-size: 12px;
}

.content-detail-facts,
.content-show-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 8px;
  margin-bottom: 14px;
}

.content-detail-facts > div,
.content-show-summary > div {
  display: grid;
  gap: 3px;
  padding: 10px 11px;
  border: 1px solid rgba(255,255,255,.065);
  border-radius: 10px;
  background: rgba(255,255,255,.018);
}

.content-detail-facts span,
.content-show-summary span {
  color: #7f7771;
  font-size: 12px;
  font-weight: 750;
  letter-spacing: .05em;
}

.content-detail-facts strong,
.content-show-summary strong {
  color: #e5ddd8;
  font-size: 14px;
}

.content-detail-loading {
  min-height: 150px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  color: #908882;
}

.content-season-list {
  display: grid;
  gap: 8px;
}

.content-season {
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.065);
  border-radius: 11px;
  background: rgba(255,255,255,.014);
}

.content-season summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 12px;
  cursor: pointer;
  list-style: none;
}

.content-season summary::-webkit-details-marker {
  display: none;
}

.content-season summary > span {
  display: grid;
  gap: 2px;
}

.content-season summary strong {
  color: #e4ddd8;
  font-size: 13px;
}

.content-season summary small {
  color: #7f7872;
  font-size: 12px;
}

.content-season summary i {
  color: #a39b95;
  font-style: normal;
}

.content-episode-list {
  border-top: 1px solid rgba(255,255,255,.055);
}

.content-episode {
  display: grid;
  grid-template-columns: 72px minmax(0,1fr);
  gap: 10px;
  padding: 9px 12px;
  border-bottom: 1px solid rgba(255,255,255,.045);
}

.content-episode:last-child {
  border-bottom: 0;
}

.content-episode-code {
  color: #ffb562;
  font-size: 12px;
  font-weight: 800;
}

.content-episode > div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.content-episode strong {
  overflow: hidden;
  color: #dcd5d0;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-episode small {
  color: #766f6a;
  font-size: 12px;
}

@keyframes content-loader-spin {
  to { transform: rotate(360deg); }
}

@media (max-width: 1400px) {
  .content-inventory-grid {
    grid-template-columns: repeat(6, minmax(0,1fr));
  }
}

@media (max-width: 1050px) {
  .content-inventory-grid {
    grid-template-columns: repeat(4, minmax(0,1fr));
  }
}

@media (max-width: 700px) {
  .content-inventory {
    padding: 12px;
  }

  .content-inventory-head,
  .content-inventory-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .content-inventory-sync-state,
  .content-inventory-status {
    text-align: left;
  }

  .content-library-tab {
    min-width: 190px;
  }

  .content-inventory-grid {
    grid-template-columns: repeat(3, minmax(0,1fr));
    gap: 12px 8px;
  }

  .content-inventory-poster i {
    font-size: 10px;
  }

  .content-detail-dialog {
    width: 100%;
    max-width: 100%;
    max-height: 88dvh;
    margin: auto 0 0;
    border-bottom: 0;
    border-radius: 20px 20px 0 0;
  }

  .content-detail-modal {
    max-height: 88dvh;
  }
}

@media (max-width: 430px) {
  .content-inventory-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}


/* --- v0.16.65 inventory sync + safe detail actions --- */
.content-inventory-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.content-inventory-head-actions form {
  display: flex;
  margin: 0;
}

.content-inventory-sync-button {
  border-color: rgba(85,214,139,.20) !important;
  background: rgba(85,214,139,.055) !important;
  color: #a9ecc0 !important;
}

.content-inventory-sync-button:hover {
  border-color: rgba(85,214,139,.38) !important;
  background: rgba(85,214,139,.10) !important;
}

.content-inventory-poster i {
  font-size: 12px;
}

@media (max-width: 700px) {
  .content-inventory-head-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .content-inventory-head-actions form,
  .content-inventory-sync-button {
    width: 100%;
  }

  .content-inventory-sync-button {
    justify-content: center;
  }
}


/* --- v0.16.66 modern Content Center + streaming detail --- */
.content-center-hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  align-items: end;
  gap: 24px;
  margin-bottom: 14px;
  padding: 26px 28px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 20px;
  background:
    radial-gradient(circle at 82% 0%, rgba(255,150,51,.17), transparent 22rem),
    radial-gradient(circle at 10% 100%, rgba(122,92,255,.10), transparent 26rem),
    linear-gradient(140deg, #17120f, #0f0e0d 62%, #14110f);
}

.content-center-hero::after {
  content: "";
  position: absolute;
  width: 240px;
  height: 240px;
  right: -80px;
  top: -130px;
  border: 1px solid rgba(255,255,255,.04);
  border-radius: 50%;
  pointer-events: none;
}

.content-center-hero-copy {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.content-center-hero-copy h1 {
  margin: 6px 0 8px;
  color: #f7f2ee;
  font-size: clamp(30px, 3vw, 46px);
  line-height: 1;
  letter-spacing: -.045em;
}

.content-center-hero-copy > p {
  max-width: 690px;
  margin: 0;
  color: #aaa09a;
  font-size: 13px;
  line-height: 1.55;
}

.content-center-hero-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 16px;
}

.content-center-hero-pills span {
  padding: 7px 10px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 999px;
  background: rgba(255,255,255,.025);
  color: #8d847e;
  font-size: 12px;
}

.content-center-hero-pills strong {
  margin-right: 4px;
  color: #f4eee9;
}

.content-center-actions {
  position: relative;
  z-index: 1;
  min-width: 210px;
  display: grid;
  gap: 7px;
}

.content-center-actions form {
  display: flex;
  margin: 0;
}

.content-center-action {
  width: 100%;
  justify-content: flex-start;
}

.content-center-action.primary {
  border-color: rgba(255,159,70,.28) !important;
  background: linear-gradient(135deg, rgba(255,159,70,.14), rgba(255,159,70,.05)) !important;
  color: #ffc17b !important;
}

.content-overview-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0,1fr));
  gap: 9px;
  margin-bottom: 14px;
}

.content-overview-card {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 94px;
  padding: 14px 15px;
  border: 1px solid rgba(255,255,255,.065);
  border-radius: 15px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,255,255,.035), transparent 8rem),
    #151311;
}

.content-overview-card.featured {
  border-color: rgba(255,159,70,.19);
  background:
    radial-gradient(circle at 100% 0%, rgba(255,159,70,.10), transparent 9rem),
    linear-gradient(145deg, #1e1510, #151311);
}

.content-overview-icon {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 12px;
  background: rgba(255,255,255,.025);
  font-size: 18px;
}

.content-overview-card > div {
  min-width: 0;
  display: grid;
  gap: 1px;
}

.content-overview-card small {
  color: #918881;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
}

.content-overview-card strong {
  color: #f4eee9;
  font-size: 25px;
  line-height: 1.05;
}

.content-overview-card span:not(.content-overview-icon) {
  overflow: hidden;
  color: #756e68;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-libraries-panel,
.content-history-panel {
  margin-bottom: 14px;
  padding: 18px;
  border: 1px solid rgba(255,255,255,.065);
  border-radius: 18px;
  background: #151311;
}

.content-section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
}

.content-section-heading h2 {
  margin: 4px 0 3px;
  color: #eee8e4;
}

.content-section-heading p {
  margin: 0;
  color: #837b75;
  font-size: 12px;
}

.content-section-updated {
  color: #776f69;
  font-size: 12px;
}

.content-library-overview-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 10px;
}

.content-library-overview-card {
  position: relative;
  overflow: hidden;
  min-width: 0;
  padding: 15px;
  border: 1px solid rgba(255,255,255,.065);
  border-radius: 15px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,159,70,.07), transparent 12rem),
    rgba(255,255,255,.012);
}

.content-library-overview-card.show {
  background:
    radial-gradient(circle at 100% 0%, rgba(111,157,255,.07), transparent 12rem),
    rgba(255,255,255,.012);
}

.content-library-overview-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}

.content-library-overview-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255,159,70,.08);
  color: #ffb25b;
}

.content-library-overview-card.show .content-library-overview-icon {
  background: rgba(108,183,255,.08);
  color: #a8d6ff;
}

.content-library-overview-icon svg {
  width: 21px;
  height: 21px;
}

.content-library-overview-card h3 {
  margin: 4px 0 12px;
  color: #eee8e4;
  font-size: 18px;
}

.content-library-overview-numbers {
  min-height: 54px;
  display: flex;
  gap: 24px;
}

.content-library-overview-numbers > div {
  display: grid;
  gap: 2px;
}

.content-library-overview-numbers strong {
  color: #f4eee9;
  font-size: 25px;
}

.content-library-overview-numbers span {
  color: #807872;
  font-size: 12px;
}

.content-library-overview-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 13px;
  padding-top: 11px;
  border-top: 1px solid rgba(255,255,255,.05);
}

.content-library-overview-foot small {
  min-width: 0;
  overflow: hidden;
  color: #766f69;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-library-overview-foot > div {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 6px;
}

.content-library-overview-foot form {
  display: flex;
  margin: 0;
}

.content-library-open-button {
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid rgba(108,183,255,.18);
  border-radius: 9px;
  background: rgba(108,183,255,.045);
  color: #abd7ff;
  font: inherit;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.content-library-open-button:hover {
  border-color: rgba(108,183,255,.36);
  background: rgba(108,183,255,.09);
}

.content-inventory.card {
  overflow: hidden;
  padding: 20px;
  border-radius: 20px;
  background:
    radial-gradient(circle at 85% 0%, rgba(255,159,70,.045), transparent 22rem),
    #131210;
}

.content-inventory-grid {
  grid-template-columns: repeat(7, minmax(0,1fr));
  gap: 20px 12px;
}

.content-inventory-card {
  gap: 9px;
  transition: transform .18s ease;
}

.content-inventory-card:hover {
  transform: translateY(-4px);
}

.content-inventory-poster {
  border-radius: 13px;
  box-shadow: 0 14px 30px rgba(0,0,0,.28);
}

.content-inventory-poster::after {
  content: "";
  position: absolute;
  inset: 45% 0 0;
  background: linear-gradient(transparent, rgba(0,0,0,.16));
  pointer-events: none;
}

.content-inventory-copy strong {
  font-size: 13px;
}

.content-inventory-copy span {
  color: #8a817b;
}

.content-history-panel .content-section-heading {
  align-items: center;
  margin-bottom: 10px;
}

.content-history-panel .content-section-heading form {
  display: flex;
  margin: 0;
}

.content-history-save {
  border-color: rgba(108,183,255,.18) !important;
  background: rgba(108,183,255,.045) !important;
  color: #b2dcff !important;
}

.content-history-empty {
  min-height: 90px;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 13px 14px;
  border: 1px dashed rgba(255,255,255,.07);
  border-radius: 13px;
  background: rgba(255,255,255,.012);
}

.content-history-empty-icon {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: rgba(108,183,255,.06);
  color: #9fcfff;
}

.content-history-empty-icon svg {
  width: 20px;
  height: 20px;
}

.content-history-empty > div {
  display: grid;
  gap: 3px;
}

.content-history-empty strong {
  color: #ddd6d1;
  font-size: 13px;
}

.content-history-empty span {
  color: #817973;
  font-size: 12px;
}

/* Streaming-style media detail */
.content-detail-dialog {
  width: min(980px, calc(100vw - 34px));
  max-height: min(90dvh, 920px);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 22px;
  background: #0d0d0d;
}

.content-detail-dialog::backdrop {
  background: rgba(0,0,0,.82);
  backdrop-filter: blur(12px);
}

.stream-detail-shell {
  max-height: min(90dvh, 920px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #0d0d0d;
}

.stream-detail-hero {
  position: relative;
  flex: 0 0 clamp(260px, 36vw, 400px);
  overflow: hidden;
  background: #171310;
}

.stream-detail-backdrop,
.stream-detail-backdrop-fallback,
.stream-detail-hero-shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.stream-detail-backdrop {
  z-index: 0;
  object-fit: cover;
  opacity: 0;
  filter: saturate(.9) brightness(.72);
  transform: scale(1.015);
  transition: opacity .22s ease;
}

.stream-detail-backdrop.loaded {
  opacity: 1;
}

.stream-detail-backdrop-fallback {
  z-index: 0;
  background:
    radial-gradient(circle at 78% 18%, rgba(255,151,50,.20), transparent 18rem),
    radial-gradient(circle at 16% 60%, rgba(116,92,255,.10), transparent 24rem),
    #171310;
}

.stream-detail-hero-shade {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(8,8,8,.96) 0%, rgba(8,8,8,.64) 44%, rgba(8,8,8,.16) 78%, rgba(8,8,8,.42) 100%),
    linear-gradient(0deg, #0d0d0d 0%, rgba(13,13,13,.72) 15%, transparent 48%);
}

.stream-detail-close {
  position: absolute;
  z-index: 4;
  top: 14px;
  right: 14px;
  background: rgba(8,8,8,.58);
  backdrop-filter: blur(10px);
}

.stream-detail-hero-copy {
  position: absolute;
  z-index: 3;
  left: 34px;
  right: 34px;
  bottom: 38px;
  max-width: 700px;
}

.stream-detail-type {
  display: inline-flex;
  padding: 5px 8px;
  border: 1px solid rgba(255,159,70,.25);
  border-radius: 999px;
  background: rgba(255,159,70,.09);
  color: #ffc178;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: .08em;
}

.stream-detail-hero-copy h2 {
  max-width: 760px;
  margin: 10px 0 10px;
  color: #fff;
  font-size: clamp(32px, 5vw, 54px);
  line-height: .96;
  letter-spacing: -.05em;
  text-shadow: 0 6px 30px rgba(0,0,0,.65);
}

.stream-detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.stream-detail-meta span {
  padding: 6px 9px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 999px;
  background: rgba(10,10,10,.42);
  color: #ded8d4;
  font-size: 12px;
  backdrop-filter: blur(8px);
}

.stream-detail-content {
  min-height: 0;
  display: grid;
  grid-template-columns: 180px minmax(0,1fr);
  gap: 22px;
  overflow-y: auto;
  padding: 0 28px 28px;
}

.stream-detail-poster-wrap {
  position: relative;
  z-index: 4;
  width: 180px;
  aspect-ratio: 2/3;
  margin-top: -58px;
  overflow: hidden;
  align-self: start;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 15px;
  background: #171717;
  box-shadow: 0 18px 42px rgba(0,0,0,.48);
}

.stream-detail-poster,
.stream-detail-poster-placeholder {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.stream-detail-poster {
  z-index: 2;
  object-fit: cover;
  opacity: 0;
  transition: opacity .18s ease;
}

.stream-detail-poster.loaded {
  opacity: 1;
}

.stream-detail-poster-placeholder {
  z-index: 1;
  display: grid;
  place-items: center;
  color: #635b55;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: .08em;
}

.content-detail-body {
  padding: 22px 0 0;
  overflow: visible;
}

.stream-detail-intro {
  display: grid;
  gap: 14px;
}

.stream-detail-summary {
  max-width: 720px;
  color: #bcb5b0;
  font-size: 14px;
  line-height: 1.65;
}

.stream-detail-genres {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.stream-detail-genres span {
  padding: 6px 9px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 999px;
  background: rgba(255,255,255,.026);
  color: #9f9791;
  font-size: 12px;
}

.stream-detail-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,170px));
  gap: 8px;
}

.stream-detail-stats > div {
  display: grid;
  gap: 3px;
  padding: 10px 11px;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 11px;
  background: rgba(255,255,255,.018);
}

.stream-detail-stats span {
  color: #79716c;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
}

.stream-detail-stats strong {
  color: #eee8e4;
  font-size: 15px;
}

.stream-season-section {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,.06);
}

.stream-season-heading {
  margin-bottom: 10px;
}

.stream-season-heading h3 {
  margin: 4px 0 0;
  color: #eee8e4;
  font-size: 20px;
}

.content-season {
  border-radius: 13px;
  background: rgba(255,255,255,.018);
}

.content-season summary {
  padding: 13px 14px;
}

.content-episode {
  grid-template-columns: 74px minmax(0,1fr);
  padding: 11px 14px;
}

@media (max-width: 1400px) {
  .content-overview-grid {
    grid-template-columns: repeat(3, minmax(0,1fr));
  }

  .content-inventory-grid {
    grid-template-columns: repeat(6, minmax(0,1fr));
  }
}

@media (max-width: 1050px) {
  .content-center-hero {
    grid-template-columns: 1fr;
  }

  .content-center-actions {
    grid-template-columns: repeat(3, minmax(0,1fr));
  }

  .content-library-overview-grid {
    grid-template-columns: 1fr;
  }

  .content-inventory-grid {
    grid-template-columns: repeat(4, minmax(0,1fr));
  }
}

@media (max-width: 700px) {
  .content-center-hero {
    padding: 18px;
    border-radius: 16px;
  }

  .content-center-hero-copy h1 {
    font-size: 32px;
  }

  .content-center-actions {
    grid-template-columns: 1fr;
  }

  .content-overview-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .content-overview-card {
    min-height: 82px;
    padding: 11px;
  }

  .content-overview-icon {
    width: 36px;
    height: 36px;
    flex-basis: 36px;
  }

  .content-libraries-panel,
  .content-history-panel {
    padding: 13px;
  }

  .content-section-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .content-inventory-grid {
    grid-template-columns: repeat(3, minmax(0,1fr));
  }

  .content-detail-dialog {
    width: 100%;
    max-width: 100%;
    max-height: 92dvh;
    margin: auto 0 0;
    border-bottom: 0;
    border-radius: 22px 22px 0 0;
  }

  .stream-detail-shell {
    max-height: 92dvh;
  }

  .stream-detail-hero {
    flex-basis: 280px;
  }

  .stream-detail-hero-copy {
    left: 18px;
    right: 18px;
    bottom: 28px;
  }

  .stream-detail-hero-copy h2 {
    font-size: 34px;
  }

  .stream-detail-content {
    grid-template-columns: 112px minmax(0,1fr);
    gap: 14px;
    padding: 0 16px 22px;
  }

  .stream-detail-poster-wrap {
    width: 112px;
    margin-top: -36px;
    border-radius: 12px;
  }

  .content-detail-body {
    padding-top: 16px;
  }

  .stream-detail-summary {
    font-size: 13px;
  }
}

@media (max-width: 480px) {
  .content-overview-grid {
    grid-template-columns: 1fr 1fr;
  }

  .content-overview-card:last-child {
    grid-column: 1 / -1;
  }

  .content-inventory-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .stream-detail-hero {
    flex-basis: 250px;
  }

  .stream-detail-content {
    display: block;
    padding-top: 0;
  }

  .stream-detail-poster-wrap {
    width: 96px;
    margin: -32px 0 14px;
  }

  .stream-detail-stats {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}


/* --- v0.16.67 resilient Plex sync + adaptive media detail --- */
.content-detail-dialog {
  width: min(1180px, calc(100vw - 42px));
  max-height: min(94dvh, 980px);
  border-radius: 24px;
}

.stream-detail-shell {
  position: relative;
  max-height: min(94dvh, 980px);
}

.stream-detail-close {
  position: absolute;
  z-index: 20;
  top: 16px;
  right: 16px;
  background: rgba(8,8,8,.68);
  border-color: rgba(255,255,255,.14);
  backdrop-filter: blur(12px);
}

/* No horizontal artwork: do not reserve a fake hero. */
.stream-detail-hero {
  display: none;
}

.content-detail-dialog.has-backdrop .stream-detail-hero {
  display: block;
  flex: 0 0 clamp(320px, 34vw, 440px);
}

.stream-detail-content {
  min-height: 0;
  display: grid;
  grid-template-columns: 250px minmax(0,1fr);
  gap: 30px;
  overflow-y: auto;
  padding: 30px;
}

.content-detail-dialog.has-backdrop .stream-detail-content {
  grid-template-columns: 210px minmax(0,1fr);
  gap: 28px;
  padding: 0 32px 32px;
}

.stream-detail-poster-wrap {
  width: 250px;
  margin-top: 0;
  border-radius: 18px;
}

.content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
  width: 210px;
  margin-top: -72px;
}

.stream-detail-main {
  min-width: 0;
  align-self: start;
}

.stream-detail-inline-head {
  display: grid;
  gap: 10px;
  margin: 6px 0 22px;
  padding: 0 52px 20px 0;
  border-bottom: 1px solid rgba(255,255,255,.065);
}

.content-detail-dialog.has-backdrop .stream-detail-inline-head {
  display: none;
}

.stream-detail-inline-head h2 {
  max-width: 820px;
  margin: 0;
  color: #fff;
  font-size: clamp(34px, 4vw, 52px);
  line-height: .98;
  letter-spacing: -.05em;
}

.stream-detail-inline-head .stream-detail-type {
  width: fit-content;
}

.content-detail-body {
  padding: 0;
}

.content-detail-dialog.has-backdrop .content-detail-body {
  padding-top: 24px;
}

.stream-detail-summary {
  max-width: 820px;
  font-size: 15px;
  line-height: 1.7;
}

.stream-detail-genres {
  margin-top: -2px;
}

.stream-detail-stats {
  grid-template-columns: repeat(3, minmax(130px, 180px));
}

.stream-season-section {
  margin-top: 28px;
}

.content-season-list {
  gap: 10px;
}

.content-season {
  border-color: rgba(255,255,255,.075);
  background: rgba(255,255,255,.022);
}

.content-season summary {
  min-height: 58px;
  padding: 14px 16px;
}

.content-episode {
  grid-template-columns: 86px minmax(0,1fr);
  gap: 14px;
  min-height: 58px;
  padding: 12px 16px;
}

.content-episode-code {
  display: inline-flex;
  align-items: center;
  color: #ffc06f;
}

@media (max-width: 900px) {
  .content-detail-dialog {
    width: min(96vw, 1000px);
  }

  .stream-detail-content {
    grid-template-columns: 180px minmax(0,1fr);
    gap: 20px;
    padding: 22px;
  }

  .stream-detail-poster-wrap {
    width: 180px;
  }

  .content-detail-dialog.has-backdrop .stream-detail-content {
    grid-template-columns: 165px minmax(0,1fr);
    padding: 0 22px 24px;
  }

  .content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
    width: 165px;
    margin-top: -54px;
  }

  .stream-detail-stats {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

@media (max-width: 700px) {
  .content-detail-dialog {
    width: 100%;
    max-width: 100%;
    max-height: 94dvh;
    margin: auto 0 0;
    border-radius: 24px 24px 0 0;
  }

  .stream-detail-shell {
    max-height: 94dvh;
  }

  .content-detail-dialog.has-backdrop .stream-detail-hero {
    flex-basis: 265px;
  }

  .stream-detail-content,
  .content-detail-dialog.has-backdrop .stream-detail-content {
    grid-template-columns: 112px minmax(0,1fr);
    gap: 14px;
    padding: 18px 16px 24px;
  }

  .stream-detail-poster-wrap,
  .content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
    width: 112px;
    margin-top: 0;
    border-radius: 12px;
  }

  .content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
    margin-top: -38px;
  }

  .stream-detail-inline-head {
    gap: 7px;
    margin: 0 0 14px;
    padding: 0 34px 14px 0;
  }

  .stream-detail-inline-head h2 {
    font-size: 30px;
  }

  .stream-detail-summary {
    font-size: 13px;
    line-height: 1.6;
  }

  .content-detail-dialog.has-backdrop .content-detail-body {
    padding-top: 15px;
  }
}

@media (max-width: 480px) {
  .stream-detail-content,
  .content-detail-dialog.has-backdrop .stream-detail-content {
    display: block;
    padding: 16px;
  }

  .stream-detail-poster-wrap,
  .content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
    width: 104px;
    margin: 0 0 14px;
  }

  .content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
    margin-top: -34px;
  }

  .stream-detail-inline-head h2 {
    font-size: 29px;
  }

  .stream-detail-stats {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }
}

/* --- Póster pequeño: altura explícita, sin contraerse con el grid ---
   No cambia hero, backdrop, shell ni contenido del modal. */
.stream-detail-poster-wrap {
  position: relative;
  box-sizing: border-box;
  display: block;
  flex: none;
  align-self: start;
  width: 250px;
  height: 375px;
  min-height: 375px;
  aspect-ratio: auto;
  overflow: hidden;
  background: #0b0b0b;
}
.content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
  width: 210px;
  height: 315px;
  min-height: 315px;
  margin-top: 0;
}
.stream-detail-poster {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  object-position: center;
  background: #0b0b0b;
}
.stream-detail-poster-placeholder {
  position: absolute;
  inset: 0;
}
@media (max-width: 900px) {
  .stream-detail-poster-wrap {
    width: 180px;
    height: 270px;
    min-height: 270px;
  }
  .content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
    width: 165px;
    height: 248px;
    min-height: 248px;
  }
}
@media (max-width: 700px) {
  .stream-detail-poster-wrap,
  .content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
    width: 112px;
    height: 168px;
    min-height: 168px;
  }
}
@media (max-width: 480px) {
  .stream-detail-poster-wrap,
  .content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
    width: 104px;
    height: 156px;
    min-height: 156px;
  }
}

/* --- Modal multimedia compacto + navegación de temporadas --- */
.content-detail-dialog.has-backdrop .stream-detail-hero {
  flex-basis: clamp(245px, 25vw, 320px);
}
.content-detail-dialog.has-backdrop .stream-detail-hero-copy {
  bottom: 22px;
}
.content-detail-dialog.has-backdrop .stream-detail-content {
  padding-top: 16px;
}
.content-season-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin: 14px 0 16px;
}
.content-season-tab {
  appearance: none;
  cursor: pointer;
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 12px;
  background: #181818;
  color: #bdb8b5;
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  padding: 11px 16px;
  transition: background .15s, border-color .15s, color .15s;
}
.content-season-tab:hover,
.content-season-tab:focus-visible {
  color: #fff;
  border-color: rgba(255,184,99,.5);
}
.content-season-tab.active {
  color: #ffca8c;
  border-color: rgba(255,170,75,.55);
  background: rgba(255,147,49,.13);
}
.content-season-panel[hidden] {
  display: none !important;
}
.content-season-panel {
  min-width: 0;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 14px;
  overflow: hidden;
  background: rgba(255,255,255,.015);
}
.content-season-panel .content-episode-list {
  display: grid;
}
@media (max-width: 700px) {
  .content-detail-dialog.has-backdrop .stream-detail-hero {
    flex-basis: 220px;
  }
  .content-detail-dialog.has-backdrop .stream-detail-hero-copy {
    bottom: 18px;
  }
  .content-season-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 5px;
  }
  .content-season-tab {
    flex: 0 0 auto;
    padding: 10px 12px;
  }
}

/* Métricas bajo póster del detalle de series */
.stream-detail-aside { min-width:0; align-self:start; }
.stream-detail-aside .stream-detail-poster-wrap { max-width:100%; }
.stream-detail-poster-stats {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:6px;
  width:100%;
  max-width:250px;
  margin-top:12px;
}
.stream-detail-poster-stats[hidden] { display:none; }
.stream-detail-poster-stats > div {
  min-width:0;
  padding:12px 6px;
  text-align:center;
  border:1px solid rgba(255,255,255,.1);
  border-radius:12px;
  background:linear-gradient(140deg,#202020,#111);
}
.stream-detail-poster-stats span {
  display:block;
  color:#aaa;
  font-size:12px;
  font-weight:600;
}
.stream-detail-poster-stats strong {
  display:block;
  margin-top:5px;
  color:#fff;
  font-size:22px;
  font-weight:700;
}
@media (max-width:700px) {
  .stream-detail-poster-stats { grid-template-columns:1fr; gap:5px; margin-top:8px; }
  .stream-detail-poster-stats > div { padding:7px 5px; }
  .stream-detail-poster-stats strong { font-size:17px; margin-top:2px; }
}

/* Ficha multimedia: título y metadatos alineados con el póster y sinopsis */
.content-detail-dialog.has-backdrop .stream-detail-hero {
  flex-basis: clamp(110px, 13vw, 155px);
}
.content-detail-dialog.has-backdrop .stream-detail-hero-copy {
  display: none;
}
.content-detail-dialog.has-backdrop .stream-detail-inline-head {
  display: grid;
  gap: 9px;
  margin: 0 0 16px;
  padding: 0 38px 15px 0;
}
.content-detail-dialog.has-backdrop .stream-detail-inline-head h2 {
  font-size: clamp(27px, 3.3vw, 42px);
  line-height: 1.08;
}
.content-detail-dialog.has-backdrop .stream-detail-content {
  padding-top: 20px;
}
.content-detail-dialog.has-backdrop .content-detail-body {
  padding-top: 0;
}
@media (max-width: 700px) {
  .content-detail-dialog.has-backdrop .stream-detail-hero {
    flex-basis: 110px;
  }
  .content-detail-dialog.has-backdrop .stream-detail-inline-head {
    margin-bottom: 12px;
    padding-right: 0;
  }
  .content-detail-dialog.has-backdrop .stream-detail-inline-head h2 {
    font-size: 28px;
  }
}

/* Temporadas y episodios a ancho completo bajo la ficha */
.stream-detail-content {
  grid-template-rows: auto auto;
}
.stream-season-fullwidth {
  grid-column: 1 / -1;
  min-width: 0;
  padding-top: 0;
}
.stream-season-fullwidth[hidden] { display: none; }
.stream-season-fullwidth .stream-season-section {
  margin-top: 0;
  padding-top: 18px;
}
.stream-detail-poster-stats > div {
  padding-top: 7px;
  padding-bottom: 7px;
}
.stream-detail-poster-stats strong {
  font-size: 19px;
  margin-top: 2px;
}
@media (max-width: 480px) {
  .stream-season-fullwidth {
    clear: both;
    width: 100%;
    margin-top: 18px;
  }
}

/* Etiquetas compactas arriba a la derecha de la ficha */
.stream-detail-inline-head { position: relative; }
.stream-detail-inline-head .stream-detail-poster-stats {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  gap: 7px;
  width: auto;
  max-width: none;
  margin: 0;
}
.stream-detail-inline-head .stream-detail-poster-stats[hidden] { display: none; }
.stream-detail-inline-head .stream-detail-poster-stats > div {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 11px;
  border-radius: 999px;
  background: rgba(255,255,255,.055);
}
.stream-detail-inline-head .stream-detail-poster-stats span {
  font-size: 12px;
  color: #b5b0ad;
}
.stream-detail-inline-head .stream-detail-poster-stats strong {
  margin: 0;
  font-size: 15px;
  color: #fff;
}
.content-detail-dialog.has-backdrop .stream-detail-inline-head {
  padding-right: 0;
}
.content-detail-dialog.has-backdrop .stream-detail-inline-head h2 {
  padding-right: 0;
}
@media (min-width: 901px) {
  .content-detail-dialog.has-backdrop .stream-detail-inline-head {
    padding-right: 230px;
  }
}
@media (max-width: 900px) {
  .stream-detail-inline-head .stream-detail-poster-stats {
    position: static;
    flex-wrap: wrap;
    margin-top: 4px;
  }
}

/* Filas de episodios: lectura clara, separadores y jerarquía visual */
.stream-season-fullwidth .stream-season-section { padding-top: 14px; }
.stream-season-fullwidth .content-season-tabs { margin: 0 0 14px; }
.stream-season-fullwidth .content-season-panel {
  border-color: rgba(255,255,255,.085);
  border-radius: 16px;
  background: #101010;
}
.stream-season-fullwidth .content-episode {
  display: grid;
  grid-template-columns: 86px minmax(0,1fr);
  align-items: center;
  gap: 18px;
  min-height: 72px;
  padding: 14px 20px;
  border-bottom: 1px solid rgba(255,255,255,.065);
  background: transparent;
  transition: background-color .16s ease;
}
.stream-season-fullwidth .content-episode:last-child { border-bottom: 0; }
.stream-season-fullwidth .content-episode:hover { background: rgba(255,255,255,.045); }
.stream-season-fullwidth .content-episode-code {
  display: inline-flex;
  justify-content: center;
  width: fit-content;
  min-width: 67px;
  border-radius: 8px;
  padding: 7px 8px;
  background: rgba(255,165,68,.09);
  color: #ffc17d;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}
.stream-season-fullwidth .content-episode > div { min-width: 0; display: grid; gap: 5px; }
.stream-season-fullwidth .content-episode strong {
  display: block;
  color: #f0ece9;
  font-size: 14px;
  line-height: 1.4;
  font-weight: 650;
}
.stream-season-fullwidth .content-episode small {
  display: block;
  color: #96908c;
  font-size: 12px;
  line-height: 1.4;
}
@media (max-width: 700px) {
  .stream-season-fullwidth .content-episode {
    grid-template-columns: 68px minmax(0,1fr);
    gap: 10px;
    min-height: 65px;
    padding: 12px;
  }
  .stream-season-fullwidth .content-episode-code { min-width: 0; padding: 6px; }
}

/* v0.16.80: ficha multimedia unificada, más amplia en escritorio */
@media (min-width: 901px) {
  .content-detail-dialog {
    width: min(1380px, calc(100vw - 32px));
    max-width: calc(100vw - 32px);
    max-height: 96dvh;
  }
  .stream-detail-shell {
    max-height: 96dvh;
  }
  .content-detail-dialog.has-backdrop .stream-detail-content {
    grid-template-columns: 225px minmax(0, 1fr);
    gap: 28px;
    padding: 22px 36px 36px;
  }
  .content-detail-dialog.has-backdrop .stream-detail-poster-wrap {
    width: 225px;
    height: 338px;
    min-height: 338px;
  }
  .content-detail-dialog.has-backdrop .stream-detail-inline-head {
    padding-right: 280px;
  }
}
/* Las mismas etiquetas para series, anime y películas. */
.stream-detail-inline-head .stream-detail-poster-stats {
  align-items: flex-start;
}
.stream-detail-inline-head .stream-detail-poster-stats > div {
  white-space: nowrap;
}
@media (max-width: 900px) {
  .content-detail-dialog {
    max-height: 96dvh;
  }
  .stream-detail-shell {
    max-height: 96dvh;
  }
  .stream-detail-inline-head .stream-detail-poster-stats {
    position: static;
    max-width: 100%;
  }
}

/* Explorador: filtros y entrada a colecciones */
.content-library-sort-label { color:#948d87; font-size:12px; font-weight:700; letter-spacing:.04em; }
.content-library-sort {
  min-height:42px; max-width:235px; padding:0 12px;
  border:1px solid rgba(255,255,255,.13); border-radius:12px;
  color:#eee; background:#1b1a19; font-size:13px;
}
#contentCollectionBack {
  border:1px solid rgba(255,173,76,.3); border-radius:9px;
  padding:7px 10px; background:rgba(255,147,40,.10);
  color:#ffc17d; cursor:pointer; font-size:12px; font-weight:700;
}
#contentCollectionBack[hidden] { display:none; }
@media(max-width:700px) {
  .content-library-sort { max-width:100%; width:100%; }
  .content-library-sort-label { display:none; }
}

/* Controles seguros de archivo original de Plex */
.content-original-actions[hidden] { display:none; }
.content-original-actions { margin-top:18px; }
.original-action-row { display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.original-action-row button,.original-action-row a {
  display:inline-flex; align-items:center; justify-content:center; gap:5px;
  min-height:36px; padding:8px 12px; border:1px solid rgba(255,255,255,.14);
  border-radius:10px; background:rgba(255,255,255,.055); color:#eae7e3;
  font-size:12px; font-weight:700; line-height:1.2; text-decoration:none; cursor:pointer;
}
.original-action-row button:hover,.original-action-row a:hover {
  border-color:rgba(255,174,70,.45); background:rgba(255,174,70,.10); color:#ffd2a0;
}
.stream-season-fullwidth .content-episode {
  grid-template-columns:86px minmax(0,1fr) auto;
}
.content-episode-actions {
  display:flex !important; align-items:center; justify-content:flex-end;
  gap:7px; flex-wrap:wrap;
}
.content-episode-actions .modern-download {
  min-height:34px; padding:6px 9px; gap:6px; font-size:11px;
}
.content-episode-actions .modern-download svg {
  width:15px; height:15px; flex:none;
}
.content-app-link.copied {
  border-color:rgba(91,205,142,.55) !important;
  color:#a7efc2 !important;
}
.original-action-row.compact { flex-wrap:nowrap; gap:5px; }
.original-action-row.compact button,.original-action-row.compact a {
  padding:7px 9px; min-height:32px;
}
.content-original-player {
  width:min(1040px,96vw); max-width:96vw; max-height:94dvh; padding:14px;
  border:1px solid rgba(255,255,255,.16); border-radius:18px;
  color:#fff; background:#090909;
}
.content-original-player::backdrop { background:rgba(0,0,0,.9); }
.content-original-player > button { float:right; margin-bottom:10px; cursor:pointer; }
.content-original-player video { display:block; clear:both; width:100%; max-height:80dvh; background:#000; }
@media(max-width:700px) {
  .stream-season-fullwidth .content-episode { grid-template-columns:70px minmax(0,1fr); }
  .stream-season-fullwidth .content-episode .original-action-row { grid-column:1/-1; justify-content:flex-end; }
}

/* Archivo original: controles alineados al lenguaje visual Monkey TV */
.original-action-row { gap:10px; }
.original-action-row .original-download,
.original-action-row .original-info {
  display:inline-flex; align-items:center; justify-content:center; gap:9px;
  min-height:42px; padding:10px 17px; border-radius:12px;
  font-size:13px; font-weight:750; letter-spacing:0;
  white-space:nowrap; transition:background .15s,border-color .15s,color .15s;
}
.original-action-row .original-download {
  background:rgba(239,144,47,.15); border-color:rgba(255,169,73,.4);
  color:#ffcc96;
}
.original-action-row .original-info {
  background:#1b1b1b; border-color:rgba(255,255,255,.13);
  color:#e3dfdc;
}
.original-action-row svg {
  width:16px; height:16px; flex:none; fill:none; stroke:currentColor;
  stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round;
}
.original-action-row.compact { justify-content:flex-end; gap:7px; }
.original-action-row.compact .original-download,
.original-action-row.compact .original-info { min-height:35px; padding:8px 11px; font-size:12px; }
.content-original-info-dialog {
  width:min(500px,calc(100vw - 30px)); max-width:calc(100vw - 30px);
  padding:0; border:1px solid rgba(255,255,255,.15); border-radius:19px;
  background:#101010; color:#f5f2ee; box-shadow:0 24px 85px rgba(0,0,0,.7);
}
.content-original-info-dialog::backdrop { background:rgba(0,0,0,.74); backdrop-filter:blur(6px); }
.content-original-info-dialog header {
  display:flex; align-items:center; justify-content:space-between;
  padding:21px 24px; border-bottom:1px solid rgba(255,255,255,.08);
  font-size:17px;
}
.content-original-info-dialog header button {
  border:1px solid rgba(255,255,255,.12); background:#242424;
  color:#ddd; border-radius:10px; width:32px; height:32px; cursor:pointer;
}
.content-original-info-details { display:grid; gap:0; padding:10px 24px 23px; overflow-wrap:anywhere; }
.content-original-info-details > div {
  display:grid; gap:6px; padding:15px 0;
  border-bottom:1px solid rgba(255,255,255,.065);
}
.content-original-info-details > div:last-child { border-bottom:0; }
.content-original-info-details span { color:#96908a; font-size:12px; font-weight:700; }
.content-original-info-details strong { font-size:14px; line-height:1.5; font-weight:650; }
@media(max-width:700px) {
  .original-action-row.compact .original-download,
  .original-action-row.compact .original-info { flex:1; }
}

/* Content center: unified lightweight header instead of duplicated dashboards */
.content-compact-head {
  display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap;
  gap:18px; padding:20px 24px; margin-bottom:18px;
  border:1px solid rgba(255,255,255,.085); border-radius:18px;
  background:linear-gradient(120deg,rgba(255,157,55,.055),rgba(255,255,255,.015) 55%);
}
.content-compact-title { min-width:0; }
.content-compact-title h1 { margin:6px 0 4px; font-size:clamp(23px,2.3vw,31px); letter-spacing:-.035em; }
.content-compact-title p { margin:0; color:#99918c; font-size:13px; }
.content-compact-tools { display:flex; align-items:center; flex-wrap:wrap; gap:14px; }
.content-compact-totals { display:flex; flex-wrap:wrap; gap:7px; }
.content-compact-totals span {
  padding:9px 12px; border-radius:10px; background:rgba(255,255,255,.04);
  color:#a9a19b; font-size:12px; white-space:nowrap;
}
.content-compact-totals strong { color:#f6eee6; font-size:15px; margin-right:4px; }
.content-management-menu { position:relative; }
.content-management-menu > summary {
  display:flex; align-items:center; justify-content:center; gap:8px;
  min-height:38px; padding:9px 14px; list-style:none; cursor:pointer;
  color:#ffca8f; background:rgba(240,147,52,.095);
  border:1px solid rgba(255,168,77,.26); border-radius:11px; font-size:12px; font-weight:750;
}
.content-management-menu > summary::-webkit-details-marker { display:none; }
.content-management-panel {
  position:absolute; right:0; top:calc(100% + 8px); width:min(300px,calc(100vw - 50px));
  z-index:15; padding:9px; display:grid; gap:3px;
  border:1px solid rgba(255,255,255,.13); border-radius:13px;
  background:#1b1918; box-shadow:0 18px 45px rgba(0,0,0,.5);
}
.content-management-panel button {
  display:block; width:100%; text-align:left; border:0; border-radius:8px;
  padding:11px 12px; background:transparent; color:#e5dfd9; font:inherit;
  font-size:12px; cursor:pointer;
}
.content-management-panel button:hover { background:rgba(255,255,255,.07); }
.content-management-panel small { color:#91877f; padding:8px 12px 3px; font-size:11px; }
.content-inventory.card { margin-top:0; }
@media(max-width:800px) {
  .content-compact-head { padding:16px; align-items:flex-start; }
  .content-compact-tools { width:100%; }
  .content-compact-totals { flex:1; }
  .content-compact-totals span { padding:7px 9px; }
}
@media(max-width:480px) {
  .content-compact-tools { flex-direction:column; align-items:stretch; }
  .content-management-menu > summary { justify-content:space-between; }
  .content-management-panel { left:0; right:auto; }
}

/* Ficha de colección: misma composición streaming de series */
.content-collection-dialog .stream-detail-poster {
  object-fit:contain; object-position:center; opacity:1;
}
.content-collection-dialog .stream-detail-backdrop[hidden],
.content-collection-dialog .stream-detail-poster[hidden] {display:none;}
.content-collection-dialog .stream-detail-content {align-items:start;}
.content-collection-dialog .collection-detail-fullwidth {width:100%; padding-top:8px;}
.collection-detail-list {
  overflow:hidden; border:1px solid rgba(255,255,255,.09);
  border-radius:16px; background:rgba(255,255,255,.018);
}
.collection-movie-row {
  width:100%; display:grid; grid-template-columns:52px minmax(0,1fr) 28px;
  gap:16px; align-items:center; text-align:left; padding:11px 18px;
  color:#f2eeeb; background:transparent; border:0;
  border-bottom:1px solid rgba(255,255,255,.065); cursor:pointer;
  transition:background-color .16s ease;
}
.collection-movie-row:last-child {border-bottom:0;}
.collection-movie-row:hover,
.collection-movie-row:focus-visible {background:rgba(255,173,71,.07);}
.collection-movie-thumb {
  display:grid; place-items:center; width:52px; height:72px;
  overflow:hidden; border-radius:8px; background:#171717;
}
.collection-movie-thumb img {width:100%;height:100%;object-fit:contain;}
.collection-movie-placeholder {font-size:8px;color:#777;text-align:center;}
.collection-movie-copy {display:grid;gap:6px;min-width:0;}
.collection-movie-copy strong {font-size:14px;line-height:1.35;font-weight:700;}
.collection-movie-copy small {font-size:12px;color:#9d9791;}
.collection-movie-chevron {font-size:23px;color:#c89b65;text-align:center;}
.collection-detail-loading {padding:24px;color:#a49d96;font-size:13px;}
#collectionDetailMore {display:block; margin:16px auto 5px;}
#collectionDetailMore[hidden] {display:none;}
@media(max-width:700px) {
 .collection-movie-row {grid-template-columns:44px minmax(0,1fr) 20px;gap:11px;padding:9px 11px;}
 .collection-movie-thumb {width:44px;height:62px;}
 .content-collection-dialog .collection-detail-fullwidth {margin-top:12px;}
}

/* Colecciones: presentación tipo landing con tarjetas de películas */
.content-collection-dialog {width:min(1280px,calc(100vw - 28px));max-height:94dvh;}
.content-collection-dialog .stream-detail-shell {max-height:94dvh;overflow-y:auto;}
.collection-landing-hero {
  position:relative;display:flex;align-items:flex-end;
  min-height:clamp(280px,35vw,395px);overflow:hidden;background:#161113;
}
.collection-landing-backdrop {position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center;}
.collection-landing-backdrop[hidden] {display:none;}
.collection-landing-shade {
  position:absolute;inset:0;pointer-events:none;
  background:linear-gradient(0deg,#0d0d0d 0%,rgba(13,13,13,.7) 23%,rgba(13,13,13,.04) 88%),
    linear-gradient(90deg,rgba(13,13,13,.8),transparent 85%);
}
.collection-landing-copy {position:relative;z-index:1;padding:34px 42px 32px;max-width:850px;}
.collection-landing-copy h2 {font-size:clamp(32px,4vw,58px);line-height:1.06;letter-spacing:-.045em;margin:12px 0 7px;color:#fff;}
.collection-landing-copy > strong {display:block;color:#ffbd74;font-size:13px;margin-bottom:13px;}
.collection-landing-copy p {margin:0;max-width:760px;color:#d6ceca;font-size:14px;line-height:1.6;}
.collection-landing-content {padding:24px 30px 35px;}
.collection-landing-content h3 {font-size:23px;line-height:1.3;margin:9px 0 20px;color:#fff;letter-spacing:-.02em;}
.content-collection-dialog .collection-detail-list {
  display:grid;grid-template-columns:repeat(auto-fill,minmax(155px,1fr));
  gap:20px 14px;background:none;border:0;border-radius:0;overflow:visible;
}
.collection-film-card {appearance:none;display:flex;flex-direction:column;min-width:0;gap:6px;padding:0;
  text-align:left;border:0;background:none;color:#fff;cursor:pointer;}
.collection-film-poster {display:block;width:100%;aspect-ratio:2/3;overflow:hidden;
  border:1px solid rgba(255,255,255,.12);border-radius:12px;background:#1a1717;transition:transform .17s,border-color .17s;}
.collection-film-poster img {display:block;width:100%;height:100%;object-fit:contain;}
.collection-film-card:hover .collection-film-poster {transform:translateY(-3px);border-color:rgba(255,179,96,.55);}
.collection-film-card strong {font-size:13px;line-height:1.35;font-weight:700;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;width:100%;}
.collection-film-card small {font-size:12px;color:#99918f;}
@media(max-width:700px){
 .collection-landing-hero {min-height:265px;}
 .collection-landing-copy {padding:24px 20px;}
 .collection-landing-content {padding:20px 16px 28px;}
 .content-collection-dialog .collection-detail-list {grid-template-columns:repeat(2,minmax(0,1fr));gap:17px 12px;}
}

/* v0.16.89: fichas de películas y series con la misma estética de colecciones */
.content-media-landing .stream-detail-shell {overflow-y:auto;max-height:94dvh;}
.content-media-landing .collection-landing-hero {min-height:clamp(290px,35vw,435px);}
.content-media-landing .collection-landing-copy {max-width:920px;}
.content-media-landing .collection-landing-copy h2 {max-width:920px;}
.content-media-landing .collection-landing-copy .stream-detail-meta {
  display:flex; flex-wrap:wrap; gap:7px; margin:9px 0 14px;
}
.content-media-landing .collection-landing-copy .stream-detail-meta span {
  display:inline-flex; align-items:center; padding:6px 10px;
  color:#f0eae4; border:1px solid rgba(255,255,255,.19);
  border-radius:999px; background:rgba(10,10,10,.34); font-size:12px;
}
.content-media-landing .collection-landing-copy .stream-detail-poster-stats {
  position:static; display:flex; flex-wrap:wrap; gap:7px;
  width:auto; max-width:none; margin:0 0 14px;
}
.content-media-landing .collection-landing-copy .stream-detail-poster-stats[hidden] {display:none;}
.content-media-landing .collection-landing-copy .stream-detail-poster-stats > div {
  display:flex; align-items:center; gap:7px; padding:6px 11px;
  border-radius:999px; background:rgba(12,12,12,.48); border:1px solid rgba(255,255,255,.18);
}
.content-media-landing .collection-landing-copy .stream-detail-poster-stats span {
  display:inline; color:#c7bdb5; font-size:11px;
}
.content-media-landing .collection-landing-copy .stream-detail-poster-stats strong {
  display:inline; margin:0; font-size:13px; color:#fff;
}
.content-media-landing .content-media-main {padding-top:20px;}
.content-media-landing .content-media-aux:empty {display:none;}
.content-media-landing .stream-detail-intro {margin:0;}
.content-media-landing .content-original-actions {margin:16px 0 8px;}
.content-media-landing .stream-season-fullwidth {
  display:block; width:100%; grid-column:auto; padding:16px 0 0; margin:0;
}
.content-media-landing .stream-season-fullwidth[hidden] {display:none;}
.content-media-landing .content-season-panel {border:0;background:none;overflow:visible;}
.content-media-landing .content-episode-list {
  display:grid; grid-template-columns:repeat(auto-fill,minmax(280px,1fr)); gap:11px;
}
.content-media-landing .content-episode,
.content-media-landing .stream-season-fullwidth .content-episode {
  display:grid; grid-template-columns:auto minmax(0,1fr); gap:10px 13px;
  align-items:center; min-height:116px; padding:16px; border:1px solid rgba(255,255,255,.1);
  border-radius:13px; background:rgba(255,255,255,.032);
}
.content-media-landing .content-episode-code {
  align-self:start; background:rgba(248,156,59,.1); border-radius:8px;
}
.content-media-landing .content-episode > div {align-self:start;}
.content-media-landing .content-episode > div strong {white-space:normal;}
.content-media-landing .episode-download {
  grid-column:1/-1; display:inline-flex; justify-content:center; align-items:center; gap:8px;
  width:max-content; min-height:33px; padding:7px 13px;
  border:1px solid rgba(255,170,78,.4); border-radius:9px;
  background:rgba(239,144,47,.12); color:#ffca92; text-decoration:none;
  font-size:12px; font-weight:700;
}
.content-media-landing .episode-download:hover {background:rgba(239,144,47,.22);}
.content-media-landing .episode-download svg {
  width:15px;height:15px;fill:none;stroke:currentColor;stroke-width:1.8;
  stroke-linecap:round;stroke-linejoin:round;
}
@media(max-width:700px) {
 .content-media-landing .collection-landing-hero {min-height:310px;}
 .content-media-landing .content-episode-list {grid-template-columns:1fr;}
 .content-media-landing .content-season-tabs {flex-wrap:nowrap;}
}

/* Botón premium unificado de descarga de originales */
.modern-download,
.content-media-landing .episode-download.modern-download {
  display:inline-flex;align-items:center;justify-content:flex-start;gap:11px;
  width:max-content;max-width:100%;min-height:49px;padding:8px 15px 8px 9px;
  border:1px solid rgba(255,170,78,.34);border-radius:13px;
  background:linear-gradient(135deg,rgba(255,170,75,.18),rgba(140,74,26,.075));
  color:#ffdeb5;text-decoration:none;
  box-shadow:inset 0 1px rgba(255,255,255,.07),0 8px 22px rgba(0,0,0,.14);
  transition:transform .16s,border-color .16s,background .16s,box-shadow .16s;
}
.modern-download:hover,
.content-media-landing .episode-download.modern-download:hover {
  transform:translateY(-1px);border-color:rgba(255,186,105,.65);
  background:linear-gradient(135deg,rgba(255,170,75,.27),rgba(140,74,26,.12));
  box-shadow:inset 0 1px rgba(255,255,255,.09),0 11px 25px rgba(0,0,0,.22);
}
.modern-download:focus-visible {outline:2px solid #ffc78a;outline-offset:3px;}
.modern-download-icon {display:grid;place-items:center;flex:none;width:34px;height:34px;
  border-radius:10px;background:rgba(255,183,99,.12);}
.modern-download-icon svg {width:18px;height:18px;fill:none;stroke:currentColor;
  stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;}
.modern-download-copy {display:flex;flex-direction:column;align-items:flex-start;gap:2px;line-height:1.2;}
.modern-download-copy strong {font-size:13px;font-weight:750;color:#fff0dc;}
.modern-download-copy small {font-size:11px;color:#dfb88d;}
.content-media-landing .episode-download.modern-download {
  grid-column:1/-1;min-height:42px;padding:6px 13px 6px 7px;margin-top:4px;
}
.compact-download .modern-download-icon {width:29px;height:29px;border-radius:8px;}
.compact-download .modern-download-icon svg {width:16px;height:16px;}
.compact-download .modern-download-copy strong {font-size:12px;}
.compact-download .modern-download-copy small {font-size:10px;}
@media(max-width:700px) {
  .content-media-landing .episode-download.modern-download {width:100%;justify-content:center;}
}

/* Episodios: tres tarjetas por fila y acción fluida */
@media (min-width: 1100px) {
  .content-media-landing .content-episode-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (min-width: 701px) and (max-width: 1099px) {
  .content-media-landing .content-episode-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.content-media-landing .content-episode {
  min-width: 0;
}
.content-media-landing .episode-download.modern-download {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  justify-content: center;
  justify-self: stretch;
  margin-top: auto;
}
@media (max-width: 700px) {
  .content-media-landing .content-episode-list {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Descarga minimalista en toda la ficha multimedia */
.modern-download.minimal-download,
.content-media-landing .episode-download.modern-download.minimal-download {
  display:inline-flex; align-items:center; justify-content:center; gap:9px;
  min-height:42px; padding:10px 16px; border-radius:11px;
  border:1px solid rgba(255,171,79,.33);
  background:rgba(255,157,59,.095);
  box-shadow:none; color:#ffcf9d; text-decoration:none;
  font-size:13px; font-weight:700; line-height:1.2;
  transition:background .15s,border-color .15s,transform .15s;
}
.modern-download.minimal-download:hover,
.content-media-landing .episode-download.modern-download.minimal-download:hover {
  background:rgba(255,157,59,.17); border-color:rgba(255,180,93,.58);
  box-shadow:none; transform:translateY(-1px);
}
.modern-download.minimal-download svg {
  flex:none; width:17px; height:17px; fill:none; stroke:currentColor;
  stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round;
}
.content-media-landing .episode-download.modern-download.minimal-download {
  width:100%; max-width:100%; justify-self:stretch; margin-top:auto;
}
@media(max-width:700px){
  .modern-download.minimal-download {max-width:100%;}
}

/* Subscripciones de contenido: gestión separada de Plex y revendedores */
.content-access-panel{margin:0 0 19px;padding:22px;border:1px solid rgba(255,255,255,.085);border-radius:18px;background:#141211}
.content-access-plan-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:18px 0}
.content-access-plan{display:flex;flex-direction:column;gap:10px;border:1px solid rgba(255,255,255,.09);border-radius:13px;background:#1a1715;padding:16px}
.content-access-panel label{display:grid;gap:5px;color:#c9bcb4;font-size:12px;font-weight:700}
.content-access-panel input:not([type=checkbox]),.content-access-panel select{width:100%;min-width:0;padding:10px 11px;border:1px solid #3c332e;border-radius:9px;background:#100f0e;color:#f4e9e0;font:inherit}
.content-access-panel .content-access-check{display:flex;align-items:center;gap:8px}
.content-access-check input{accent-color:#ed9a45}
.content-access-panel button{padding:10px 14px;background:#302016;color:#ffd09c;border:1px solid #754827;border-radius:10px;cursor:pointer;font-weight:700}
.content-access-plan button{margin-top:auto}
.content-access-manage{margin:10px 0;border:1px solid #332d29;border-radius:12px;padding:14px}
.content-access-manage>summary{cursor:pointer;font-weight:750;color:#f4c49a}
.content-access-create{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:16px 0}
.content-access-create .content-access-check{align-self:end}
.content-access-users{max-height:480px;overflow:auto;margin-top:13px}
.content-access-users form{display:grid;grid-template-columns:minmax(180px,1fr) minmax(110px,180px) auto auto auto;gap:11px;align-items:center;padding:11px 0;border-bottom:1px solid #312b27}
.content-access-users small{display:block;color:#918780;margin-top:3px;font-size:11px}
@media(max-width:1050px){.content-access-plan-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.content-access-users form{grid-template-columns:1fr 1fr}}
@media(max-width:640px){.content-access-panel{padding:15px}.content-access-plan-grid,.content-access-create{grid-template-columns:1fr}.content-access-users form{grid-template-columns:1fr}}

/* Content Center v2: indicadores y acciones administrativas */
.content-compact-head{gap:18px}
.content-tools-v2{display:flex;align-items:center;gap:12px;min-width:0}
.content-totals-v2{display:flex;align-items:stretch;gap:8px;flex-wrap:wrap}
.content-totals-v2 .content-stat-chip{display:flex;flex-direction:column;justify-content:center;gap:4px;min-width:106px;padding:10px 14px;border:1px solid #36302c;border-radius:12px;background:linear-gradient(145deg,#211a16,#151312);box-sizing:border-box}
.content-totals-v2 .content-stat-label{font-size:10px;letter-spacing:.065em;font-weight:700;color:#b1a197}
.content-totals-v2 .content-stat-chip strong{font-size:20px;line-height:1.15;font-weight:800;color:#f8f5f3}
.content-management-v2{position:relative;flex-shrink:0}
.content-management-v2>summary{display:flex;gap:9px;align-items:center;justify-content:center;min-height:47px;padding:0 14px;border:1px solid #865222;border-radius:12px;background:#342114;color:#ffbd78;cursor:pointer;list-style:none;font-size:13px;font-weight:750}
.content-management-v2>summary::-webkit-details-marker{display:none}
.content-management-v2>summary svg{width:17px;height:17px}
.content-management-v2[open]>summary{background:#49301e;border-color:#cd8842}
.content-manage-chevron{font-size:17px;line-height:1;transition:transform .2s}
.content-management-v2[open] .content-manage-chevron{transform:rotate(180deg)}
.content-management-v2 .content-management-panel-v2{position:absolute;left:auto;right:0;top:calc(100% + 9px);width:min(340px,calc(100vw - 32px));max-height:min(67vh,570px);overflow-y:auto;box-sizing:border-box;padding:12px;background:#171413;border:1px solid #4b382a;border-radius:15px;z-index:100;box-shadow:0 22px 60px #000b}
.content-manage-heading{display:grid;gap:5px;padding:8px 10px 13px;border-bottom:1px solid #362c27}
.content-manage-heading strong{font-size:14px;color:#fff}
.content-manage-heading small{font-size:12px;color:#a99d95}
.content-manage-group-title{padding:13px 10px 6px;color:#efae6b;font-size:10px;font-weight:800;letter-spacing:.09em}
.content-management-v2 .content-management-panel-v2 form{margin:0}
.content-management-v2 .content-management-panel-v2 form button{display:flex;align-items:center;gap:12px;width:100%;border:0;border-radius:10px;padding:10px;background:transparent;color:#ece4dd;text-align:left;font-size:12px;font-weight:650;cursor:pointer;box-sizing:border-box}
.content-management-v2 .content-management-panel-v2 form button:hover{background:#32241b;color:#ffc58d}
.content-management-v2 .content-management-panel-v2 form button>span:last-child{display:grid;gap:3px;min-width:0}
.content-management-v2 .content-management-panel-v2 form button small{font-size:11px;font-weight:400;color:#a89b93}
.content-manage-symbol{flex:none;display:grid;place-items:center;width:32px;height:32px;border-radius:9px;border:1px solid #4d3627;background:#302117;color:#ffb873;font-size:19px}
.content-manage-updated{font-size:11px;color:#9e928b;padding:12px 10px 4px;margin-top:6px;border-top:1px solid #382f2a}
@media(max-width:1100px){.content-tools-v2{flex-wrap:wrap}.content-totals-v2{flex:1 1 auto}.content-totals-v2 .content-stat-chip{flex:1 1 100px}}
@media(max-width:620px){.content-tools-v2{display:grid;grid-template-columns:1fr}.content-totals-v2{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.content-totals-v2 .content-stat-chip{min-width:0}.content-management-v2>summary{justify-content:space-between}.content-management-v2 .content-management-panel-v2{width:100%;max-height:65dvh}}

/* Content hero v3 — encabezado premium de biblioteca administrativa */
.content-hero-v3{display:grid;grid-template-columns:minmax(300px,1fr) minmax(480px,.98fr);gap:28px;padding:27px;border:1px solid rgba(255,255,255,.085);border-radius:22px;background:radial-gradient(ellipse at 0% 0%,rgba(201,111,40,.12),transparent 56%),linear-gradient(130deg,#1b1512,#101010 75%);box-shadow:0 18px 42px #0002;position:relative;margin-bottom:22px}
.content-hero-main{display:flex;flex-direction:column;justify-content:center;min-width:0}
.content-hero-mark{display:flex;align-items:center;gap:9px;color:#ffb65f;letter-spacing:.095em;font-size:11px;font-weight:850}
.content-hero-mark-dot{width:7px;height:7px;background:#ff9f3b;border-radius:50%;box-shadow:0 0 0 5px #ff9f3b18}
.content-hero-main h1{font-size:clamp(29px,2.5vw,43px);letter-spacing:-.045em;line-height:1.09;font-weight:850;margin:16px 0 10px;color:#fcfafa}
.content-hero-main>p{max-width:490px;font-size:14px;line-height:1.65;color:#b8ada5;margin:0}
.content-hero-meta{display:flex;flex-wrap:wrap;gap:9px;margin-top:25px}
.content-meta-item{min-width:0;display:flex;align-items:center;gap:9px;padding:10px 12px;border:1px solid #392e27;border-radius:11px;background:#ffffff05}
.content-meta-item>span:last-child{display:grid;gap:5px}
.content-meta-item small{color:#a59890;font-size:10px;letter-spacing:.04em;font-weight:700}
.content-meta-item strong{font-size:12px;color:#f4eee9;font-weight:750;white-space:nowrap}
.content-meta-indicator{width:8px;height:8px;background:#4dd69b;border-radius:50%;flex:none}
.content-hero-side{display:grid;gap:12px;min-width:0;align-content:center}
.content-kpi-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px}
.content-kpi-card{display:flex;flex-direction:column;justify-content:space-between;min-width:0;min-height:91px;padding:13px;border:1px solid #38302c;border-radius:13px;background:linear-gradient(145deg,#28201b,#161413)}
.content-kpi-label{display:flex;align-items:center;justify-content:space-between;gap:4px;font-size:10px;color:#bcaaa0;font-weight:750;letter-spacing:.04em}
.content-kpi-glyph{font-size:15px;color:#c9874a;line-height:1}
.content-kpi-card>strong{font-size:clamp(21px,1.9vw,29px);font-weight:850;letter-spacing:-.04em;line-height:1.1;color:#fff;margin-top:13px}
.content-hero-actions{display:flex;align-items:stretch;flex-wrap:wrap;gap:8px}
.content-hero-actions form{margin:0;flex:1 1 100px}
.content-action-button{display:flex;align-items:center;justify-content:center;gap:7px;width:100%;min-height:41px;padding:9px 12px;box-sizing:border-box;border:1px solid #40342c;background:#1d1916;color:#eee2d9;border-radius:10px;font-size:12px;font-weight:750;white-space:nowrap;cursor:pointer}
.content-action-button:hover{border-color:#ad7645;background:#35271e;color:#ffce96}
.content-action-primary{border-color:#a86625;background:linear-gradient(140deg,#643b1b,#392315);color:#ffd19b}
.content-hero-manage{position:relative;flex:0 0 78px}
.content-hero-manage>summary{list-style:none}
.content-hero-manage>summary::-webkit-details-marker{display:none}
.content-hero-dropdown{position:absolute;top:calc(100% + 8px);right:0;width:260px;max-width:calc(100vw - 32px);max-height:310px;overflow-y:auto;padding:10px;background:#1c1714;border:1px solid #58402e;box-shadow:0 18px 45px #000a;border-radius:13px;z-index:65}
.content-hero-dropdown>strong{display:block;font-size:10px;color:#ffc17f;padding:7px 9px;letter-spacing:.06em}
.content-hero-dropdown form{margin:0}
.content-hero-dropdown form button{display:block;text-align:left;width:100%;border:0;background:transparent;color:#f0e8e1;font-size:12px;font-weight:650;border-radius:8px;padding:10px;cursor:pointer}
.content-hero-dropdown form button:hover{background:#412a1c;color:#ffc58c}
.content-hero-dropdown p{font-size:12px;color:#aa9b90;padding:8px}
@media(max-width:1250px){.content-hero-v3{grid-template-columns:1fr;gap:21px}.content-hero-meta{margin-top:15px}.content-kpi-grid{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:700px){.content-hero-v3{padding:17px;border-radius:17px}.content-hero-main h1{font-size:31px}.content-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.content-hero-actions form{flex:1 1 calc(50% - 8px)}.content-hero-manage{flex:1 1 calc(50% - 8px)}.content-hero-meta{gap:7px}.content-meta-item{flex:1 1 135px}}
@media(max-width:420px){.content-hero-actions{display:grid;grid-template-columns:1fr 1fr}.content-hero-manage{min-width:0}.content-hero-dropdown{right:0}.content-meta-item strong{white-space:normal}}

/* Biblioteca: variante compacta del hero aprobado */
.content-hero-v3{padding:19px 23px;gap:22px;margin-bottom:17px}
.content-hero-main h1{font-size:clamp(28px,2.2vw,38px);margin:10px 0 0}
.content-hero-meta{margin-top:16px;gap:7px}
.content-meta-item{padding:8px 10px}
.content-hero-side{gap:9px}
.content-kpi-card{min-height:76px;padding:10px 12px}
.content-kpi-card>strong{margin-top:9px;font-size:clamp(21px,1.7vw,27px)}
.content-action-button{min-height:38px;padding:7px 10px}
@media(max-width:700px){.content-hero-v3{padding:15px;gap:16px}.content-hero-main h1{font-size:29px}.content-hero-meta{margin-top:12px}}

/* Landing principal: planes y guía Plex integrados */
.plex-home-plans,.plex-home-guide{padding-top:56px;padding-bottom:36px;scroll-margin-top:90px}
.plex-home-section-head{display:flex;align-items:end;justify-content:space-between;gap:20px;margin-bottom:25px}
.plex-home-section-head h2{color:#fff;font-size:clamp(28px,3vw,44px);letter-spacing:-.045em;line-height:1.12;margin:10px 0}
.plex-home-section-head p{color:#b7aaa1;font-size:14px;line-height:1.65;max-width:720px;margin:0}
.plex-home-text-link{flex:none;color:#ffc27f;text-decoration:none;font-size:12px;font-weight:800;letter-spacing:.03em;border:1px solid #65452b;border-radius:10px;padding:13px}
.plex-home-plan-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,265px),1fr));gap:15px}
.plex-home-plan-card{display:flex;flex-direction:column;min-width:0;min-height:370px;padding:22px;border:1px solid #403129;border-radius:19px;background:linear-gradient(145deg,#201915,#0f0e0e)}
.plex-home-plan-card.is-featured{border-color:#bb783c;background:linear-gradient(145deg,#392419,#15100f 65%)}
.plex-home-plan-overline{display:flex;justify-content:space-between;gap:8px;font-size:10px;font-weight:800;color:#df995e;letter-spacing:.07em}
.plex-home-featured{color:#ffc78c;border:1px solid #a66a36;border-radius:20px;padding:4px 8px}
.plex-home-plan-card h3{font-size:21px;line-height:1.15;color:#fff;margin:22px 0 13px}
.plex-home-plan-price{font-size:clamp(23px,2.2vw,33px);font-weight:850;letter-spacing:-.04em;color:#fff;overflow-wrap:anywhere}
.plex-home-plan-period{font-size:12px;color:#ad9d93;margin:8px 0 18px}
.plex-home-plan-specs{display:grid;gap:7px;border-top:1px solid #403229;border-bottom:1px solid #403229;padding:14px 0;color:#e3d5cc;font-size:12px}
.plex-home-plan-libraries{display:flex;flex-wrap:wrap;gap:7px;padding:16px 0 22px;color:#d4c2b3;font-size:11px}
.plex-home-plan-libraries small{flex:0 0 100%;color:#b49e90;letter-spacing:.05em;font-weight:800}
.plex-home-plan-libraries>span{background:#ffffff08;border:1px solid #46352b;border-radius:20px;padding:6px 9px}
.plex-home-plan-card>.button{margin-top:auto;min-height:46px}
.plex-home-empty{padding:30px;border:1px solid #49382d;border-radius:16px;color:#bda99c}
.plex-home-steps{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
.plex-home-steps article{padding:22px;border:1px solid #403029;border-radius:17px;background:linear-gradient(150deg,#241b15,#111010);min-height:185px}
.plex-home-steps article>span{font-size:27px;color:#ffb66e;font-weight:850}
.plex-home-steps h3{font-size:17px;color:#fff;margin:15px 0 10px}
.plex-home-steps p{font-size:12px;line-height:1.65;color:#b8aaa0;margin:0}
.plex-home-help{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:21px 23px;border:1px solid #63452f;border-radius:14px;background:#2d201766;margin-top:16px}
.plex-home-help strong{font-size:15px;color:#f6e6d7}.plex-home-help p{margin:5px 0 0;color:#b6a79c;font-size:12px}
.plex-home-help>.button{white-space:nowrap}
@media(max-width:900px){.plex-home-steps{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:600px){.plex-home-plans,.plex-home-guide{padding-top:38px;padding-bottom:18px}.plex-home-section-head{display:block}.plex-home-text-link{display:inline-flex;margin-top:15px}.plex-home-steps{grid-template-columns:1fr}.plex-home-steps article{min-height:0}.plex-home-help{flex-direction:column;align-items:stretch}.plex-home-help>.button{justify-content:center}}
@media(max-width:700px){.mobile-public-nav{grid-template-columns:repeat(4,minmax(0,1fr))!important}.mobile-public-nav a span{font-size:10px}}

.plex-home-faq{margin-top:22px;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.plex-home-faq h3{grid-column:1/-1;color:#fff;font-size:21px;margin:3px 0 7px}
.plex-home-faq details{align-self:start;background:#181412;border:1px solid #463429;border-radius:13px;padding:0 15px}
.plex-home-faq summary{list-style:none;cursor:pointer;color:#f2dfcf;font-size:13px;font-weight:750;padding:16px 0}
.plex-home-faq summary::-webkit-details-marker{display:none}
.plex-home-faq summary::after{content:"+";float:right;color:#ffae68;font-size:18px;line-height:14px;margin-left:10px}
.plex-home-faq details[open] summary::after{content:"−"}
.plex-home-faq details p{font-size:12px;line-height:1.7;color:#baa99b;margin:0 0 16px}
@media(max-width:650px){.plex-home-faq{grid-template-columns:1fr}}

/* Colecciones públicas: mismo lenguaje de mosaico y ficha cinematográfica de Pro */
.collections-main .collections-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,225px),1fr));gap:19px}
.collections-main .collection-grid-card{min-width:0;background:transparent;border:0;padding:0;border-radius:0;color:#fff;text-align:left;box-shadow:none}
.collections-main .collection-grid-card:hover{transform:none}
.public-collection-poster-wall{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:repeat(2,minmax(0,1fr));aspect-ratio:1/1;position:relative;border-radius:14px;border:1px solid #40332e;overflow:hidden;background:#171312}
.public-collection-poster-wall img{width:100%;height:100%;object-fit:cover;object-position:center;min-width:0;min-height:0;display:block}
.public-collection-poster-wall img:only-of-type{grid-column:1/-1;grid-row:1/-1}
.public-collection-badge{position:absolute;left:9px;bottom:9px;padding:5px 9px;background:#171717df;border-radius:25px;color:#fff;font-size:11px;font-weight:850;letter-spacing:.015em}
.public-collection-caption{display:grid;gap:6px;padding:10px 0 2px}
.public-collection-caption strong{color:#fff;font-size:14px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}
.public-collection-caption small{color:#a9a09a;font-size:12px}
.collections-main .collection-grid-card:hover .public-collection-poster-wall{border-color:#c28243;box-shadow:0 8px 25px #0006}
#collectionModal .collection-browser-modal{max-width:min(1200px,95vw)}
#collectionModal .collection-modal-items{display:grid;grid-template-columns:repeat(auto-fill,minmax(130px,1fr));gap:14px}
#collectionModal .public-collection-film{border:0;background:transparent;text-align:left;color:#fff;cursor:pointer;min-width:0;padding:0;display:grid;gap:6px;align-content:start}
#collectionModal .public-collection-film .collection-film-poster{display:block;aspect-ratio:2/3;overflow:hidden;border:1px solid #39302b;border-radius:12px;background:#181513}
#collectionModal .public-collection-film img{display:block;width:100%;height:100%;object-fit:cover}
#collectionModal .public-collection-film strong{font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#collectionModal .public-collection-film small{font-size:11px;color:#a59c95}
#collectionModal .public-collection-film:hover .collection-film-poster{border-color:#eea45e}
.public-title-dialog{width:min(1130px,95vw);max-width:95vw;max-height:94dvh;padding:0;border:1px solid #37302d;border-radius:22px;background:#0e0d0d;color:#fff;overflow:auto}
.public-title-dialog::backdrop{background:#000d}
.public-title-dialog .stream-detail-shell{position:relative;background:#0e0d0d}
.public-title-dialog .collection-landing-hero{min-height:400px}
.public-title-dialog .collection-landing-backdrop{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.public-title-dialog .collection-landing-copy{position:relative;z-index:2;max-width:800px}
.public-title-dialog .public-title-meta{font-size:13px;color:#f8d2a1;font-weight:650;margin:13px 0}
.public-title-dialog .public-title-bottom{padding-top:12px;padding-bottom:30px}
.public-title-dialog .public-title-genres{font-size:12px;color:#ddaa78;margin-bottom:12px}
.public-title-dialog #publicTitleExtra{font-size:13px;font-weight:700}
.public-title-availability{border-top:1px solid #35302c;padding-top:17px;color:#aba099;font-size:12px;line-height:1.6}
@media(max-width:700px){.collections-main .collections-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.public-collection-caption strong{font-size:12px}.public-title-dialog .collection-landing-hero{min-height:360px}.public-title-dialog{width:calc(100vw - 15px);max-width:calc(100vw - 15px)}}


/* Fichas públicas: navegación cómoda, capas claras y controles táctiles */
#collectionModal,#publicTitleDialog{overscroll-behavior:contain}
#collectionModal .collection-browser-modal{width:min(1180px,100%);box-sizing:border-box}
#collectionModal .collection-modal-items{align-items:start}
#collectionModal .public-collection-film{width:100%}
#publicTitleDialog .stream-detail-close{z-index:8;position:sticky;top:12px;margin:12px 12px -54px auto;display:grid;place-items:center;width:42px;height:42px;background:#191615e8;border:1px solid #55453b;border-radius:12px;color:#fff}
#publicTitleDialog .collection-landing-copy{overflow-wrap:anywhere}
#publicTitleDialog .collection-landing-backdrop{object-position:center 27%}
@media(max-width:680px){
 #collectionModal{max-width:calc(100vw - 14px);width:calc(100vw - 14px);max-height:94dvh}
 #collectionModal .collection-modal-items{grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
 #collectionModal .collection-modal-body{padding:17px 13px 24px}
 #collectionModal .public-collection-film strong{font-size:11px}
 #publicTitleDialog .collection-landing-hero{min-height:380px}
 #publicTitleDialog .collection-landing-copy{padding:95px 20px 26px}
 #publicTitleDialog .collection-landing-copy h2{font-size:clamp(27px,8vw,41px)}
 #publicTitleDialog .public-title-bottom{padding:16px 20px 25px}
}
@media(max-width:380px){#collectionModal .collection-modal-items{grid-template-columns:repeat(2,minmax(0,1fr))}}

/* Colecciones públicas: pósters verticales 3:4, mosaicos sin huecos */
.collections-main .collections-grid{grid-template-columns:repeat(auto-fill,minmax(min(100%,190px),1fr));gap:18px}
.collections-main .public-collection-poster-wall{aspect-ratio:3/4;grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:repeat(2,minmax(0,1fr))}
.collections-main .public-collection-poster-wall.has-1{grid-template-columns:1fr;grid-template-rows:1fr}
.collections-main .public-collection-poster-wall.has-2{grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:1fr}
.collections-main .public-collection-poster-wall.has-3 img:nth-of-type(3){grid-column:1/-1}
.collections-main .public-collection-poster-wall img{width:100%;height:100%;object-fit:cover;object-position:center;min-height:0;min-width:0}
@media(max-width:700px){.collections-main .collections-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}}

/* Colecciones públicas con póster estándar vertical (2:3), sin mosaicos */
.collections-main .collections-grid{grid-template-columns:repeat(auto-fill,minmax(min(100%,185px),1fr));gap:18px}
.collections-main .public-collection-poster-wall{display:block;aspect-ratio:2/3;position:relative;overflow:hidden}
.collections-main .public-collection-poster-wall img,
.collections-main .public-collection-poster-wall img:only-of-type{display:block;width:100%;height:100%;object-fit:cover;object-position:center;grid-column:auto;grid-row:auto}
.collections-main .public-collection-poster-wall .collection-placeholder{display:grid;place-items:center;width:100%;height:100%}
@media(max-width:700px){.collections-main .collections-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}}

/* Tarjetas públicas clicables: conserva visual de póster y acceso por teclado */
.catalog-grid .catalog-card-open{display:block;width:100%;min-width:0;padding:0;border:0;background:transparent;text-align:left;color:inherit;font:inherit;cursor:pointer;border-radius:13px}
.catalog-grid .catalog-card-open:focus-visible{outline:2px solid #ffad5a;outline-offset:4px}
.catalog-grid .catalog-card-open:hover .poster-image{border-color:#ca874e;box-shadow:0 10px 30px #0007}
.catalog-grid .catalog-card-open .catalog-card-copy{text-align:left}

/* Client CRM: expanded layout and consistent administrative actions */
.clients-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 460px), 1fr));
  gap: 18px;
  align-items: stretch;
}
.client-crm-card {
  padding: 23px;
  border-radius: 22px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.client-crm-head { gap: 15px; align-items: center; }
.client-crm-avatar { width: 51px; height: 51px; border-radius: 15px; }
.client-crm-title h3 { font-size: 19px; }
.client-crm-contact { padding: 13px 15px; margin-top: 15px; border-radius: 13px; }
.client-crm-stats { gap: 10px; margin-top: 12px; grid-template-columns: 1.25fr .8fr 1fr; }
.client-crm-stats > div { padding: 14px; min-height: 77px; border-radius: 13px; }
.client-crm-stats strong { font-size: 17px; }
.client-active-products { margin-top: 17px; padding-top: 16px; }
.client-active-product {
  min-height: 78px; padding: 16px; border-radius: 14px;
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  border: 1px solid rgba(255,151,60,.16);
  cursor: pointer; text-decoration: none;
  transition: border-color .18s, background .18s, transform .18s;
}
.client-active-product:hover,
.client-active-product:focus-visible {
  border-color: rgba(255,165,75,.56);
  background: rgba(255,150,50,.085);
  transform: translateY(-1px);
  outline-offset: 2px;
}
.client-active-product small { display: block; line-height: 1.5; overflow-wrap: anywhere; }
.client-crm-footer {
  margin-top: auto; padding-top: 18px;
  display: flex; gap: 12px; align-items: center; justify-content: space-between;
  flex-wrap: wrap;
}
.client-card-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.client-manage-action,
.client-card-actions .button {
  min-height: 38px; border-radius: 11px; padding: 0 13px;
  display: inline-flex; align-items: center; justify-content: center;
  gap: 7px; font-size: 12px; font-weight: 800;
  transition: background .16s, border-color .16s, transform .16s;
}
.client-manage-action:hover { transform: translateY(-1px); }
.client-manage-action svg { width: 15px; height: 15px; }
@media (max-width: 640px) {
  .clients-grid { grid-template-columns: 1fr; gap: 12px; }
  .client-crm-card { padding: 16px; }
  .client-crm-stats > div { padding: 10px; min-height: 68px; }
  .client-crm-stats strong { font-size: 14px; }
  .client-crm-footer { align-items: stretch; }
  .client-card-actions { width: 100%; }
}

/* Client CRM grid: three cards on desktop, two on tablets, one on phones */
@media (min-width: 1200px) {
  .clients-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 720px) and (max-width: 1199px) {
  .clients-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 719px) {
  .clients-grid { grid-template-columns: minmax(0, 1fr); }
}
.client-crm-card { min-width: 0; }
.client-card-actions { gap: 7px; }
.client-crm-footer { gap: 9px; }

/* Client cards: no separator below active product; equal-width footer actions */
.client-crm-footer {
  border-top: 0 !important;
  padding-top: 12px;
  margin-top: auto;
  display: block;
}
.client-card-actions {
  display: flex;
  width: 100%;
  flex-wrap: nowrap;
  align-items: stretch;
  justify-content: center;
  gap: 8px;
}
.client-card-actions > form,
.client-card-actions > .client-manage-action {
  flex: 1 1 0;
  min-width: 0;
  margin: 0;
}
.client-card-actions > form { display: flex; }
.client-card-actions .client-manage-action {
  width: 100%;
  min-width: 0;
  padding: 0 7px;
  white-space: nowrap;
  text-align: center;
}
@media (max-width: 390px) {
  .client-card-actions { gap: 5px; }
  .client-card-actions .client-manage-action { font-size: 10px; padding: 0 4px; }
}

/* Equal compact client metrics */
.client-crm-stats { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)) !important; align-items:stretch; gap:9px; }
.client-crm-stats > div { min-width:0; min-height:70px; height:100%; padding:12px; display:flex; flex-direction:column; justify-content:center; gap:5px; }
.client-crm-stats > div > span { white-space:nowrap; }
.client-crm-stats > div > strong { overflow-wrap:anywhere; }
@media(max-width:390px){.client-crm-stats{gap:5px}.client-crm-stats>div{padding:9px 7px}.client-crm-stats>div>span{font-size:10px}.client-crm-stats>div>strong{font-size:12px}}

/* Admin/reseller running action feedback */
.admin-action-progress[hidden]{display:none!important}
.admin-action-progress{position:fixed;right:20px;bottom:24px;z-index:10020;display:flex;align-items:center;gap:11px;max-width:min(390px,calc(100vw - 32px));padding:13px 18px;border:1px solid rgba(255,175,83,.26);border-radius:14px;background:#221b15;box-shadow:0 15px 42px #0009;color:#f7d5a8;font-size:13px;font-weight:700}
.admin-action-spinner{display:inline-block;flex:none;width:15px;height:15px;border:2px solid currentColor;border-top-color:transparent;border-radius:50%;animation:monkey-action-spin .75s linear infinite}
.admin-button-running{opacity:.78;cursor:wait!important;pointer-events:none;display:inline-flex;align-items:center;justify-content:center;gap:8px}
@keyframes monkey-action-spin{to{transform:rotate(360deg)}}
@media(max-width:700px){.admin-action-progress{left:14px;right:14px;bottom:calc(75px + env(safe-area-inset-bottom));max-width:none}}

/* Homepage hero: buttons and catalogue statistics share a baseline on desktop.
   Shorter hero bottom removes the dead space before Cartelera. */
@media (min-width: 1101px) {
  body.public-shell .public-hero {
    min-height: clamp(555px, 71vh, 740px);
    padding-bottom: 44px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    column-gap: 28px;
  }
  body.public-shell .public-hero-content {
    transform: none;
    flex: 1 1 auto;
    min-width: 0;
  }
  body.public-shell .public-stats {
    position: relative;
    inset: auto;
    right: auto;
    bottom: auto;
    margin: 0 0 0 auto;
    flex: 0 0 auto;
    align-self: flex-end;
  }
}

/* Inventory account cards: status pill and full-width action controls */
.service-account-card .inventory-plex-status-row{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;padding:12px 0;border-top:1px solid rgba(255,255,255,.065)}
.inventory-plex-status{display:inline-flex;align-items:center;gap:8px;padding:8px 11px;border-radius:10px;font-size:11px;line-height:1.2;font-weight:800;letter-spacing:.025em}
.inventory-plex-status svg{width:15px;height:15px;flex:none}
.inventory-plex-status.ready{color:#8af3bb;background:rgba(37,158,94,.10);border:1px solid rgba(51,183,111,.28)}
.inventory-plex-status.pending{color:#ffc382;background:rgba(204,128,42,.10);border:1px solid rgba(204,128,42,.26)}
.service-account-card .service-account-footer{padding-top:12px}
.service-account-card .service-account-actions{display:flex;width:100%;gap:8px;align-items:stretch}
.service-account-card .inventory-account-action{display:inline-flex;align-items:center;justify-content:center;flex:1 1 0;min-width:0;width:auto;height:39px;gap:7px;padding:8px 7px;border:1px solid rgba(255,170,77,.25);border-radius:10px;background:rgba(255,150,58,.06);color:#e8c69e;font-size:11px;font-weight:800;white-space:nowrap}
.service-account-card .inventory-account-action svg{width:15px;height:15px;flex:none}
.service-account-card .inventory-account-action:hover{background:rgba(255,162,70,.16);border-color:rgba(255,170,77,.52)}
.service-account-card .inventory-account-action span{overflow:hidden;text-overflow:ellipsis}
@media(max-width:420px){.service-account-card .inventory-account-action{font-size:10px;padding:7px 4px;gap:5px}}


/* --- Renewal modal visual refinement --- */
.renewal-modal-header {
  padding: 23px 26px 20px !important;
  align-items: flex-start;
  background: linear-gradient(115deg, rgba(255,153,47,.10), rgba(255,153,47,0) 68%);
}
.renewal-modal-header .eyebrow {
  color: #ffb34f;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .12em;
}
.renewal-modal-header h2 {
  margin: 7px 0 5px !important;
  font-size: clamp(25px, 3vw, 30px) !important;
  line-height: 1.12;
}
.renewal-customer {
  color: #f4eee8;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 5px;
}
.renewal-account {
  display: inline-block;
  color: #b9aaa0;
  font-size: 12px;
}
.renewal-plan-field {
  margin: 18px 22px 0;
}
.renewal-plan-field select {
  margin-top: 8px;
  min-height: 52px;
  font-weight: 650;
}
.renewal-wallet-note {
  display: flex;
  align-items: flex-start;
  gap: 13px;
  margin: 18px 22px 2px;
  padding: 15px 17px;
  border: 1px solid rgba(255,174,66,.48);
  border-left: 4px solid #ffad42;
  border-radius: 13px;
  color: #fff1d9;
  background: linear-gradient(105deg, rgba(255,166,55,.17), rgba(255,166,55,.07));
  box-shadow: 0 8px 24px rgba(0,0,0,.16), inset 0 1px rgba(255,255,255,.035);
}
.renewal-wallet-icon {
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  color: #1d1307;
  background: linear-gradient(135deg,#ffd17c,#ff9e2f);
  font-size: 17px;
  font-weight: 900;
}
.renewal-wallet-note > div { min-width: 0; }
.renewal-wallet-title {
  display: block;
  margin-bottom: 4px;
  color: #ffd08a;
  font-size: 13px;
  font-weight: 800;
}
.renewal-wallet-note p {
  margin: 0;
  color: #f0dfc8;
  font-size: 13px;
  line-height: 1.5;
}
.renewal-wallet-amount {
  display: inline-block;
  padding: 2px 8px;
  margin: 0 2px;
  border-radius: 7px;
  color: #171006;
  background: #ffc36b;
  font-size: 15px;
  font-weight: 900;
  white-space: nowrap;
}
.renewal-info-note {
  display: grid;
  gap: 4px;
  margin: 0 22px 3px;
  padding: 12px 15px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 11px;
  background: rgba(255,255,255,.025);
}
.renewal-info-note strong {
  color: #d9c7b8;
  font-size: 12px;
}
.renewal-info-note span {
  color: #b7aaa0;
  font-size: 12px;
  line-height: 1.5;
}
@media (max-width: 620px) {
  .renewal-modal-header { padding: 18px 16px 15px !important; }
  .renewal-plan-field, .renewal-wallet-note, .renewal-info-note {
    margin-left: 16px;
    margin-right: 16px;
  }
  .renewal-wallet-note { padding: 13px; }
}

dialog[id^="access-renew-"] .plan-edit-modal { gap: 15px; }
dialog[id^="access-renew-"] .form-grid { margin-top: 3px; }
dialog[id^="access-renew-"] .plan-edit-actions { margin-top: 2px; }

/* Renewal plan selector: neutral dark surface, readable selected plan */
dialog[id^="access-renew-"] .renewal-plan-field select {
  appearance: none;
  -webkit-appearance: none;
  color: #f4eee8 !important;
  background-color: #100f0e !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23b9aaa0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 16px center !important;
  padding-right: 44px !important;
  border: 1px solid rgba(255,255,255,.13) !important;
  box-shadow: none !important;
}
dialog[id^="access-renew-"] .renewal-plan-field select:focus {
  border-color: rgba(255,255,255,.24) !important;
  background-color: #100f0e !important;
  box-shadow: 0 0 0 3px rgba(255,255,255,.035) !important;
}
dialog[id^="access-renew-"] .renewal-plan-field select option {
  color: #f4eee8;
  background: #171412;
}
