body {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(720px 360px at 8% 4%, rgba(35, 199, 244, 0.08), transparent 62%),
    linear-gradient(180deg, #f8fafc 0%, #edf2f7 100%);
}

.site-topbar.home-topbar.account-topbar {
  background: rgba(5, 10, 18, 0.94);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
}

.account-main {
  flex: 1;
  width: min(1440px, calc(100vw - 2rem));
  margin: 0 auto;
  padding: 5.75rem 0 clamp(3rem, 6vw, 5rem);
}

.account-loading {
  margin: clamp(2rem, 10vh, 6rem) auto;
  color: var(--slate);
  text-align: center;
  font-size: 0.95rem;
}

.account-loading.hidden { display: none; }

.account-panel {
  width: min(620px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.15rem;
  align-items: start;
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.account-panel.is-dashboard {
  width: 100%;
  grid-template-columns: 1fr;
}

.account-panel.is-dashboard .account-hero {
  display: none;
}

.account-hero {
  color: var(--ink);
  padding: 0 0 0.35rem;
  display: grid;
  justify-items: center;
  text-align: center;
}

.account-hero h1 {
  margin: 0;
  font-family: "Manrope", Arial, sans-serif;
  font-size: clamp(1.9rem, 5vw, 2.8rem);
  font-weight: 700;
  letter-spacing: -0.055em;
  line-height: 1;
}

.account-card {
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #ffffff;
  padding: clamp(1.25rem, 3vw, 1.75rem);
  display: grid;
  gap: 1rem;
  align-content: start;
  box-shadow: 0 20px 55px rgba(7, 16, 26, 0.07);
}

.account-dashboard {
  gap: clamp(1rem, 2.4vw, 1.5rem);
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.account-client-preview-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1rem;
  color: #123a33;
  background: #e5f3ef;
  border: 1px solid rgba(18, 90, 78, 0.18);
  border-radius: 14px;
}

.account-client-preview-banner.hidden { display: none; }
.account-client-preview-banner strong,
.account-client-preview-banner span { display: block; }
.account-client-preview-banner span { margin-top: 0.2rem; color: #4d6863; font-size: 0.82rem; }
.account-client-preview-banner .btn { flex: 0 0 auto; }

body.is-client-dashboard-preview .account-settings-button,
body.is-client-dashboard-preview .account-notification-button { display: none !important; }

body.is-client-dashboard-preview .app-card [aria-disabled="true"] {
  opacity: 0.68;
  cursor: not-allowed;
}

.account-card h2,
.app-card h3 {
  margin: 0;
  font-family: "Fraunces", "Times New Roman", serif;
}

.dashboard-head {
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.account-overview {
  padding: 0.35rem 0 1.15rem;
  border-bottom: 1px solid rgba(15, 22, 32, 0.1);
}

.account-identity {
  min-width: min(100%, 360px);
}

.dashboard-head h2 {
  margin: 0.2rem 0;
  font-size: clamp(1.55rem, 3vw, 2.2rem);
}

.dashboard-head p {
  margin: 0;
  color: var(--slate);
}

.account-overview-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.dashboard-view-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0.25rem;
  border: 1px solid rgba(15, 22, 32, 0.12);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 14px 34px rgba(15, 22, 32, 0.07);
}

.dashboard-view-toggle.hidden {
  display: none;
}

.dashboard-view-toggle button {
  min-height: 36px;
  padding: 0.48rem 0.9rem;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--slate);
  cursor: pointer;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 900;
}

.dashboard-view-toggle button:hover,
.dashboard-view-toggle button:focus-visible {
  color: var(--ink);
  outline: none;
}

.dashboard-view-toggle button.is-active {
  color: #ffffff;
  background: #123a33;
  box-shadow: 0 8px 20px rgba(18, 58, 51, 0.2);
}

.account-settings-button {
  min-height: 44px;
  border: 1px solid rgba(15, 22, 32, 0.12);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.78);
  color: var(--ink);
  cursor: pointer;
  font-weight: 900;
  padding: 0.65rem 1rem;
  box-shadow: 0 14px 34px rgba(15, 22, 32, 0.08);
}

.account-notification-button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 0.5rem;
  padding: 0.58rem 1rem;
  border: 1px solid rgba(15, 22, 32, 0.12);
  border-radius: 4px;
  color: var(--ink);
  background: #fff;
  font-size: 0.86rem;
  font-weight: 900;
  text-decoration: none;
}

.account-notification-button:hover,
.account-notification-button:focus-visible {
  border-color: rgba(15, 22, 32, 0.3);
  outline: none;
}

.account-notification-count {
  display: inline-grid;
  min-width: 1.55rem;
  height: 1.55rem;
  place-items: center;
  padding: 0 0.3rem;
  border-radius: 999px;
  color: #fff;
  background: #c0392b;
  font-size: 0.7rem;
  line-height: 1;
}

.account-settings-button:hover,
.account-settings-button:focus-visible {
  border-color: rgba(15, 118, 110, 0.35);
  outline: none;
}

.dashboard-views {
  display: grid;
}

.dashboard-apps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.8rem;
  align-items: start;
}

.dashboard-section {
  display: grid;
  gap: 0.85rem;
  align-content: start;
}

.dashboard-apps > .dashboard-section + .dashboard-section {
  padding-top: 1.5rem;
  border-top: 1px solid rgba(15, 22, 32, 0.1);
}

.dashboard-section-head {
  min-height: 3.1rem;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.8rem;
}

.dashboard-section-head h3 {
  margin: 0;
  font-size: 1rem;
}

.dashboard-section-head p {
  margin: 0;
  color: var(--slate);
  font-size: 0.94rem;
}

.app-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
  align-items: stretch;
}

.dashboard-apps .app-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.dashboard-empty-state {
  margin: 0;
  padding: 1rem 1.1rem;
  color: var(--slate);
  border: 1px dashed rgba(15, 22, 32, 0.16);
  border-radius: var(--radius-md);
  background: #fbfcfd;
}

.admin-app-section {
  width: 100%;
}

.admin-app-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.7rem;
}

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

.admin-quick-access-head {
  align-items: end;
  margin-bottom: 0.15rem;
}

.admin-all-tools-link {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 0.55rem 0.85rem;
  font-size: 0.76rem;
}

.admin-app-card {
  min-height: 168px;
  gap: 0.72rem;
  padding: 0.9rem;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 8px 24px rgba(15, 22, 32, 0.035);
}

body[data-admin-role="sales_rep"] .admin-app-card:not([data-sales-leads-card]),
body[data-admin-role="sales_rep"] .admin-product-section-head,
body[data-admin-role="sales_rep"] .admin-all-tools-link {
  display: none !important;
}

.admin-app-card .auth-kicker {
  font-size: 0.66rem;
}

.admin-app-card h3 {
  font-size: 1.05rem;
  line-height: 1.15;
}

.admin-app-card p:not(.auth-kicker) {
  margin-top: 0.3rem;
  font-size: 0.78rem;
  line-height: 1.45;
}

.admin-app-card > .btn {
  width: max-content;
  max-width: 100%;
  min-height: 34px;
  padding: 0.45rem 0.72rem;
  font-size: 0.72rem;
}

.admin-app-card > .btn.block {
  width: max-content;
}

.admin-product-section-head {
  margin-top: 1.1rem;
  padding-top: 1.1rem;
  border-top: 1px solid rgba(15, 22, 32, 0.1);
}

.notification-page {
  width: min(1440px, calc(100vw - 2rem));
}

.notification-admin-shell {
  gap: 1.35rem;
}

.notification-page-head {
  border: 1px solid rgba(15, 22, 32, 0.08);
  border-radius: var(--radius-md);
  background:
    radial-gradient(460px 190px at 0% 0%, rgba(23, 111, 102, 0.12), transparent 60%),
    linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  padding: clamp(1rem, 2.4vw, 1.35rem);
}

.notification-page-head h1 {
  margin: 0.15rem 0 0.35rem;
  font-family: "Fraunces", "Times New Roman", serif;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  line-height: 1;
}

.notification-page-head p:not(.auth-kicker) {
  margin: 0;
  color: var(--slate);
}

.notification-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.82fr) minmax(420px, 1.18fr);
  gap: 1rem;
  align-items: start;
}

.notification-compose,
.notification-recipients {
  border: 1px solid rgba(15, 22, 32, 0.08);
  border-radius: var(--radius-md);
  background: #fbfcfd;
  padding: clamp(1rem, 2vw, 1.15rem);
}

.notification-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  flex-wrap: wrap;
}

.notification-toolbar h3 {
  margin: 0;
}

.notification-toolbar .field-note {
  margin: 0.25rem 0 0;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.notification-summary {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  flex-wrap: wrap;
  padding: 0.8rem 0.9rem;
  border: 1px solid rgba(15, 22, 32, 0.08);
  border-radius: 14px;
  background: #f7fafc;
  color: var(--slate);
}

.notification-summary strong {
  color: var(--ink);
}

.notification-recipient-shell {
  max-height: 420px;
  overflow: auto;
}

.notification-recipient-shell input[type="checkbox"] {
  width: 1.05rem;
  height: 1.05rem;
}

#notification-review-modal .settings-modal-dialog {
  --modal-width: 720px;
}

.notification-review-meta {
  display: grid;
  gap: 0.45rem;
  padding: 0.85rem;
  border: 1px solid rgba(15, 22, 32, 0.08);
  border-radius: 14px;
  background: #f7fafc;
}

.notification-review-meta p {
  margin: 0;
  color: var(--slate);
}

.notification-email-preview {
  border: 1px solid rgba(15, 22, 32, 0.1);
  border-radius: 16px;
  background: #f5f7fb;
  padding: 0.9rem;
}

.notification-preview-frame {
  max-width: 620px;
  margin: 0 auto;
  padding: 1.2rem;
  border: 1px solid rgba(15, 22, 32, 0.08);
  border-radius: 14px;
  background: #ffffff;
  color: var(--ink);
}

.notification-preview-head {
  text-align: center;
}

.notification-preview-head .settings-modal-kicker {
  margin-left: auto;
  margin-right: auto;
}

.notification-preview-frame h2 {
  margin: 0 0 0.8rem;
  font-family: "Fraunces", "Times New Roman", serif;
  font-size: clamp(1.35rem, 3vw, 1.9rem);
  line-height: 1.15;
}

.notification-preview-head .field-note {
  margin-left: auto;
  margin-right: auto;
}

.notification-preview-message {
  color: var(--slate);
  line-height: 1.65;
}

.notification-actions {
  justify-content: flex-end;
}

.app-card {
  border: 1px solid rgba(15, 22, 32, 0.1);
  border-radius: var(--radius-md);
  padding: clamp(0.95rem, 1.8vw, 1.15rem);
  background: #fbfcfd;
  display: grid;
  gap: 0.8rem;
  min-height: 188px;
  align-content: space-between;
}

.app-card.is-connected {
  border-color: rgba(15, 118, 110, 0.24);
  background: linear-gradient(180deg, rgba(236, 253, 250, 0.64), #fbfcfd 48%);
  box-shadow: 0 12px 30px rgba(15, 118, 110, 0.055);
}

.app-card.is-available {
  min-height: 168px;
  border-color: rgba(82, 97, 115, 0.1);
  background: rgba(251, 252, 253, 0.76);
}

.app-access-badge {
  display: inline-flex;
  width: max-content;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.7rem;
  padding: 0.28rem 0.5rem;
  color: #526173;
  border: 1px solid rgba(82, 97, 115, 0.16);
  border-radius: 999px;
  background: #f4f6f8;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
}

.app-card.is-connected .app-access-badge {
  color: #0f766e;
  border-color: rgba(15, 118, 110, 0.18);
  background: rgba(204, 251, 241, 0.74);
}

.app-card.is-connected .app-access-badge::before {
  width: 6px;
  height: 6px;
  content: "";
  border-radius: 50%;
  background: #0f9f8f;
}

.app-card.is-pending {
  border-color: rgba(180, 118, 20, 0.28);
  background: linear-gradient(180deg, rgba(255, 247, 224, 0.8), #fbfcfd 52%);
  box-shadow: none;
}

.app-card.is-pending .app-access-badge {
  color: #8a5a0a;
  border-color: rgba(180, 118, 20, 0.2);
  background: rgba(254, 243, 199, 0.8);
}

.app-card.is-pending .app-access-badge::before {
  background: #d18b17;
}

.app-card.is-action-required {
  border-color: rgba(176, 50, 50, 0.28);
  background: linear-gradient(180deg, rgba(254, 242, 242, 0.84), #fbfcfd 52%);
  box-shadow: none;
}

.app-card.is-action-required .app-access-badge {
  color: #a52f2f;
  border-color: rgba(176, 50, 50, 0.2);
  background: rgba(254, 226, 226, 0.82);
}

.app-card.is-action-required .app-access-badge::before {
  background: #c23a3a;
}

.account-dashboard .auth-kicker,
.app-card .auth-kicker {
  color: #0f766e;
}

.app-card p:not(.auth-kicker) {
  margin: 0.4rem 0 0;
  color: var(--slate);
}

.app-card.is-connected > .btn,
.app-card.is-pending > .btn,
.app-card.is-action-required > .btn {
  border-color: #123a33;
  color: #ffffff;
  background: #123a33;
}

.app-card.is-connected > .btn:hover,
.app-card.is-connected > .btn:focus-visible,
.app-card.is-pending > .btn:hover,
.app-card.is-pending > .btn:focus-visible,
.app-card.is-action-required > .btn:hover,
.app-card.is-action-required > .btn:focus-visible {
  border-color: #0d2f29;
  color: #ffffff;
  background: #0d2f29;
}

.app-card.is-available .auth-kicker {
  color: #607084;
}

.app-card.is-available > .btn.block {
  width: max-content;
  max-width: 100%;
  min-height: 40px;
  padding: 0.58rem 0.9rem;
}

.settings-disclosure {
  border: 1px solid rgba(15, 22, 32, 0.09);
  border-radius: var(--radius-md);
  background: #fbfcfd;
  padding: 0;
  overflow: hidden;
}

.settings-disclosure summary {
  color: var(--ink);
  cursor: pointer;
  font-weight: 800;
  list-style: none;
  padding: 0.9rem 1rem;
}

.settings-disclosure summary::-webkit-details-marker {
  display: none;
}

.settings-disclosure summary::after {
  content: "Open";
  float: right;
  color: var(--slate);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.settings-disclosure[open] summary::after {
  content: "Close";
}

.settings-disclosure summary:focus-visible {
  outline: 2px solid rgba(23, 111, 102, 0.35);
  outline-offset: -2px;
}

.settings-disclosure[open] summary {
  border-bottom: 1px solid rgba(15, 22, 32, 0.07);
}

.settings-form {
  padding: 1rem;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.settings-help {
  margin: 0;
  color: var(--slate);
  font-size: 0.92rem;
  line-height: 1.55;
}

.settings-link-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1rem;
  color: var(--ink);
  background: #fbfcfd;
  border: 1px solid rgba(15, 22, 32, 0.09);
  border-radius: var(--radius-md);
  text-decoration: none;
}

.settings-link-card[hidden] { display: none; }

.settings-link-card strong,
.settings-link-card small { display: block; }
.settings-link-card small { margin-top: 0.2rem; color: var(--slate); font-size: 0.78rem; }
.settings-link-card > span:last-child { color: var(--slate); font-size: 0.72rem; font-weight: 900; letter-spacing: 0.08em; text-transform: uppercase; }
.settings-link-card:hover,
.settings-link-card:focus-visible { border-color: rgba(23, 111, 102, 0.35); outline: none; }

.account-sms-consent {
  display: grid;
  grid-template-columns: 1rem 1fr;
  gap: 0.65rem;
  align-items: start;
  padding: 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.84);
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.5;
  cursor: pointer;
}

.account-sms-consent input {
  width: 1rem;
  height: 1rem;
  margin: 0.18rem 0 0;
  accent-color: #23d0ac;
}

.account-sms-disclosure {
  padding: 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.66);
  background: rgba(0, 0, 0, 0.12);
  font-size: 0.78rem;
  line-height: 1.5;
}

.account-sms-state,
.account-pin-state {
  width: fit-content;
  margin: 0;
  padding: 0.35rem 0.6rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.68);
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.74rem;
  font-weight: 800;
}

.account-sms-state.is-active,
.account-pin-state.is-active {
  border-color: rgba(35, 208, 172, 0.3);
  color: #a7f3d0;
  background: rgba(35, 208, 172, 0.1);
}

.account-sms-disclosure p {
  margin: 0;
}

.account-sms-disclosure p + p {
  margin-top: 0.55rem;
}

.account-sms-disclosure a {
  color: #9eeeff;
  font-weight: 800;
}

.account-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(3, 7, 12, 0.64);
  backdrop-filter: blur(14px);
}

.account-modal-backdrop.hidden {
  display: none;
}

.account-modal {
  width: min(560px, 100%);
  max-height: calc(100svh - 2rem);
  overflow-y: auto;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 22px;
  background:
    radial-gradient(460px 240px at 16% 0%, rgba(22, 185, 237, 0.2), transparent 62%),
    linear-gradient(145deg, #0b1219 0%, #060b12 100%);
  color: #fff;
  box-shadow: 0 34px 90px rgba(0, 0, 0, 0.42);
  padding: 1.1rem;
}

.account-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.35rem 0.35rem 1rem;
}

.account-modal-kicker {
  margin: 0 0 0.25rem;
  color: #9eeeff;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.account-modal h2 {
  margin: 0;
  font-family: "Fraunces", "Times New Roman", serif;
  font-size: 1.7rem;
  line-height: 1.05;
}

.account-modal-close {
  min-height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  cursor: pointer;
  font-weight: 800;
  padding: 0.45rem 0.75rem;
}

.account-modal-page,
.account-detail-grid {
  display: grid;
  gap: 0.9rem;
}

.account-detail {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 0.85rem;
  background: rgba(255, 255, 255, 0.06);
}

.account-detail-label {
  margin: 0 0 0.2rem;
  color: #9eeeff;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.account-detail-value {
  margin: 0;
  color: #fff;
  font-weight: 800;
}

.account-modal .settings-disclosure {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}

.account-modal .settings-disclosure summary {
  color: #fff;
}

.account-modal .settings-disclosure summary::after {
  color: rgba(255, 255, 255, 0.68);
}

.account-modal .settings-disclosure[open] summary {
  border-bottom-color: rgba(255, 255, 255, 0.1);
}

.account-modal .field label {
  color: #9eeeff;
}

.account-modal-status {
  margin: 0;
}

.account-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.7rem;
}

.account-status {
  grid-column: 1;
  margin: 0;
}

.account-panel.is-dashboard .account-status {
  grid-column: 1;
}

@media (max-width: 860px) {
  .account-panel {
    grid-template-columns: 1fr;
  }

  .dashboard-apps {
    grid-template-columns: 1fr;
  }

  .dashboard-apps .app-grid {
    grid-template-columns: 1fr;
  }

  .admin-app-grid {
    grid-template-columns: 1fr;
  }

  .admin-quick-access-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .notification-layout,
  .grid-2 {
    grid-template-columns: 1fr;
  }

  .account-status {
    grid-column: auto;
  }
}

@media (min-width: 861px) and (max-width: 1120px) {
  .admin-app-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  body {
    background:
      radial-gradient(520px 280px at 8% 3%, rgba(35, 199, 244, 0.08), transparent 62%),
      linear-gradient(180deg, #f8fafc 0%, #edf2f7 100%);
  }

  .account-main {
    width: min(100vw - 1rem, 1180px);
    padding-top: 5rem;
  }

  .account-card {
    border-radius: 12px;
  }

  .account-client-preview-banner {
    align-items: stretch;
    flex-direction: column;
  }

  .account-overview-actions {
    width: 100%;
    gap: 0.5rem;
  }

  .account-overview-actions.has-admin-tools {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .account-overview-actions.has-admin-tools .dashboard-view-toggle {
    grid-column: 1 / -1;
    width: 100%;
  }

  .dashboard-view-toggle button {
    flex: 1;
  }

  .account-overview-actions.has-admin-tools .account-notification-button,
  .account-overview-actions.has-admin-tools .account-settings-button {
    width: 100%;
    justify-content: center;
  }

  .app-card {
    min-height: 0;
  }

  .app-card.is-available > .btn.block {
    width: 100%;
  }
}
.field-optional {
  color: var(--slate);
  font-size: 0.72em;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
}

#signup-referral-status.is-valid {
  color: #08745f;
  font-weight: 700;
}

#signup-referral-status.is-error {
  color: #a43a1a;
  font-weight: 700;
}

.dashboard-organization-picker { padding: 24px 0; border-bottom: 1px solid #dce2e6; }
.dashboard-organization-picker label { display: block; font-weight: 700; margin-bottom: 8px; }
.dashboard-organization-picker select { width: 100%; max-width: 480px; min-height: 48px; padding: 10px 14px; border: 1px solid #cdd5dc; border-radius: 8px; background: white; color: #131922; font: inherit; }
.dashboard-organization-picker p { margin: 10px 0 0; color: #647080; }

.dashboard-apps[hidden] { display: none !important; }

.account-product-title { display:flex; align-items:center; gap:.75rem; }
.account-product-title h3 { min-width:0; }
.account-product-icon { display:block; width:56px; height:56px; flex:0 0 56px; object-fit:contain; }

#google-signin-button,
#microsoft-signin-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: #fff;
}

#google-signin-button img,
#microsoft-signin-button svg {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  object-fit: contain;
}

#social-onboarding-fields .field + .field {
  margin-top: 16px;
}

.admin-quick-controls { display:flex; align-items:center; flex-wrap:wrap; gap:0.5rem; margin:0.9rem 0; }
.admin-quick-controls button, .admin-quick-pin { font:inherit; font-size:0.78rem; font-weight:700; border:1px solid #dce3e5; border-radius:8px; background:#fff; color:#52616c; cursor:pointer; min-height:38px; padding:0.45rem 0.8rem; }
.admin-quick-controls button.is-active { background:#123a33; border-color:#123a33; color:#fff; }
.admin-quick-controls span { font-size:0.78rem; color:var(--slate); margin-left:0.3rem; }
.admin-quick-title { display:flex; align-items:center; gap:0.65rem; margin-top:0.25rem; }
.admin-quick-title h3 { flex:1; margin:0; }
.admin-quick-title .navigation-icon { display:inline-flex; flex:0 0 36px; width:36px; height:36px; align-items:center; justify-content:center; color:#173f46; }
.admin-quick-title .navigation-icon img, .admin-quick-title .navigation-icon svg { width:36px; height:36px; }
.admin-quick-pin { flex:0 0 auto; padding:0.35rem 0.55rem; min-height:36px; font-size:0.7rem; }
.admin-quick-pin[aria-pressed="true"] { color:#123a33; background:#e2f0ec; border-color:#b8d8ce; }
.admin-quick-pin:focus-visible, .admin-quick-controls button:focus-visible { outline:2px solid #168d9b; outline-offset:3px; }
@media (max-width:680px) { .admin-quick-controls button, .admin-quick-pin { min-height:44px; } }

#admin-quick-access-grid { gap:0.55rem; }
#admin-quick-access-grid .admin-quick-card { display:flex; flex-direction:row; align-items:center; min-height:76px; padding:0.55rem 0.65rem; gap:0.45rem; border-radius:10px; }
.admin-quick-open { display:flex; align-items:center; gap:0.75rem; flex:1; min-width:0; align-self:stretch; text-decoration:none; color:var(--ink,#111923); padding:0.3rem; border-radius:6px; }
.admin-quick-open .navigation-icon { display:inline-flex; align-items:center; flex:0 0 28px; width:28px; height:28px; color:#173f46; }
.admin-quick-open .navigation-icon img, .admin-quick-open .navigation-icon svg { width:28px; height:28px; }
.admin-quick-text { min-width:0; }
.admin-quick-text h3 { font-family:Manrope,sans-serif; font-size:0.88rem; line-height:1.35; margin:0; }
.admin-quick-category { display:block; margin-top:0.18rem; font-size:0.68rem; color:var(--slate); }
#admin-quick-access-grid .admin-quick-pin { display:inline-flex; align-items:center; justify-content:center; width:36px; height:36px; min-height:36px; padding:0; background:transparent; border-color:transparent; }
.admin-quick-pin svg { width:18px; height:18px; }
#admin-quick-access-grid .admin-quick-pin[aria-pressed="true"] { background:#e2f0ec; border-color:#b8d8ce; }
.admin-quick-pin[aria-pressed="true"] svg { fill:currentColor; }
.admin-quick-open:hover { background:#edf5f3; }
.admin-quick-open:focus-visible { outline:2px solid #168d9b; outline-offset:2px; }
@media(min-width:1100px) { #admin-quick-access-grid { grid-template-columns:repeat(4,minmax(0,1fr)); } }
@media(max-width:680px) { #admin-quick-access-grid .admin-quick-pin { width:44px; height:44px; min-height:44px; } }

/* Keep dashboard navigation compact on both desktop and mobile. */
.account-overview { justify-content:flex-end; padding-bottom:1rem; }
.account-overview-actions, .account-overview-actions.has-admin-tools { display:flex; flex-wrap:nowrap; align-items:center; width:100%; gap:0.5rem; }
.account-overview-actions .dashboard-view-toggle { margin-right:auto; width:auto; min-width:0; border-radius:10px; box-shadow:none; }
.account-overview-actions .dashboard-view-toggle button { border-radius:7px; box-shadow:none; }
.account-overview-actions .account-notification-button, .account-overview-actions .account-settings-button,
.account-overview-actions.has-admin-tools .account-notification-button, .account-overview-actions.has-admin-tools .account-settings-button { display:inline-flex; position:relative; align-items:center; justify-content:center; flex:0 0 44px; width:44px; height:44px; padding:0; border-radius:10px; box-shadow:none; }
.account-notification-button.hidden { display:none; }
.account-notification-count { position:absolute; top:-5px; right:-5px; }
.account-notification-count.hidden { display:none; }
.admin-quick-toolbar { display:flex; align-items:center; justify-content:space-between; gap:1rem; margin-bottom:1rem; }
.admin-quick-toolbar .admin-quick-controls { display:inline-flex; flex-wrap:nowrap; gap:3px; margin:0; padding:3px; background:#e8eeed; border-radius:10px; }
.admin-quick-toolbar .admin-quick-controls button { min-height:38px; padding:0.45rem 0.85rem; border:0; background:transparent; border-radius:7px; }
.admin-quick-toolbar .admin-quick-controls button.is-active { background:#123a33; color:white; }
.admin-quick-toolbar .admin-all-tools-link { display:inline-flex; align-items:center; gap:0.4rem; min-height:44px; padding:0.4rem 0.65rem; border-radius:8px; color:#173f46; font-size:0.82rem; font-weight:700; text-decoration:none; white-space:nowrap; }
.admin-all-tools-link:hover { background:#e8eeed; }
.admin-all-tools-link:focus-visible, .account-overview-actions button:focus-visible, .account-overview-actions a:focus-visible { outline:2px solid #168d9b; outline-offset:3px; }
.dashboard-screen-reader { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; border:0; }
@media(max-width:680px) { .account-overview-actions .dashboard-view-toggle { flex:1; } .account-overview-actions .dashboard-view-toggle button { padding:0.45rem 0.6rem; min-height:44px; } .admin-quick-toolbar { gap:0.4rem; } .admin-quick-toolbar .admin-quick-controls button { min-height:44px; padding:0.45rem 0.7rem; } }

/* Account-specific content lives in the client portal's workspace frame. */
body:has(.account-panel.is-dashboard) {
  --portal-heading-font: "Fraunces";
  --portal-deep: #070c12;
  --portal-ink: #0b1016;
  --portal-muted: #667184;
  background: var(--client-workspace-surface);
}
.account-main:has(.account-panel.is-dashboard) {
  width: 100%;
  padding: 0;
}
.account-dashboard { gap: 0; }
.account-panel.is-dashboard .account-overview,
body:has(.account-panel.is-dashboard) > .n3xra-footer,
.account-topbar.client-portal-topbar :is(.desktop-nav, [data-site-menu-toggle]) { display: none; }
.account-topbar.client-portal-topbar .account-overview-actions { width: auto; }
.account-topbar.client-portal-topbar .account-overview-actions > :is(button,a) {
  background: transparent;
  color: white;
  border: 0;
}
.account-topbar.client-portal-topbar .account-overview-actions > .hidden { display: none; }
.account-dashboard .dashboard-views { min-width: 0; height: calc(100svh - 76px); }
.account-workspace-content, .account-dashboard #admin-app-section {
  padding: clamp(1rem, 2vw, 2rem);
  background: white;
}
.account-workspace-content > section + section {
  border-top: 1px solid var(--client-workspace-border);
  margin-top: 2rem;
  padding-top: 1.5rem;
}
.account-dashboard .website-organization-panel-head .portal-kicker {
  margin: 0;
  font: 800 .8rem/1.5 Manrope, sans-serif;
  color: var(--portal-muted);
  letter-spacing: .06em;
  text-transform: uppercase;
}
.account-dashboard .dashboard-organization-picker { margin: 0; width: 100%; }
.account-dashboard .dashboard-organization-picker[hidden] { display: none; }
#account-workspace-links :is(button,a) {
  display: flex;
  align-items: center;
  gap: .75rem;
  width: 100%;
  min-height: 44px;
  padding: .67rem .75rem;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--portal-muted);
  font: 700 .8rem/1.4 Manrope, sans-serif;
  text-align: left;
  cursor: pointer;
}
#account-workspace-links :is(button,a):hover,
#account-workspace-links :is(.is-active, [aria-current="page"]) { background: #deefec; color: var(--portal-ink); }
#account-workspace-links img { width: 20px; height: 20px; object-fit: contain; }
#account-workspace-links :is(a,button).hidden,
#account-workspace-links .account-workspace-tabs.hidden { display: none; }
@media (min-width: 801px) {
  .account-dashboard .is-sidebar-collapsed #account-workspace-links :is(button,a) {
    justify-content: center;
    gap: 0;
    padding-inline: 0;
    font-size: 0;
  }
}
@media (max-width: 800px) {
  .account-dashboard .dashboard-views { height: auto; }
  .account-dashboard .website-organization-panel-head { display: flex; justify-content: space-between; align-items: center; }
  .account-topbar.client-portal-topbar #account-nav-link { display: inline-flex; }
}

.account-dashboard .client-workspace-scroll-region:has(#personal-home:not(.hidden)) { display: flex; flex-direction: column; }
#personal-home { flex: 1; min-height: 65svh; background: white; }
#personal-home .workspace-greeting img { width: 84px; height: 84px; object-fit: contain; }
#personal-home.hidden, #personal-settings-view.hidden, #personal-product-view.hidden { display: none; }
.account-dashboard .client-workspace-scroll-region:has(:is(#personal-settings-view,#personal-product-view):not(.hidden)) { padding: 0; }
:is(#personal-settings-view,#personal-product-view), :is(#personal-settings-view,#personal-product-view) iframe { width: 100%; height: 100%; min-height: 75svh; border: 0; background: white; }
:is(#personal-settings-view,#personal-product-view) iframe { display: block; }

@media(max-width: 800px) {
}

#workspace-app-shortcuts { display: contents; }
#workspace-app-shortcuts .account-product-icon { flex: 0 0 20px; margin: 0; }
#connected-apps-section[hidden] { display: none; }

.account-dashboard .client-workspace-scroll-region:has(#personal-admin-tool:not([hidden])) { padding: 0; }
#personal-admin-tool:not([hidden]) { display: flex; flex-direction: column; height: 100%; min-height: 70svh; background: white; }
#personal-admin-tool iframe { display: block; width: 100%; flex: 1; border: 0; min-height: 0; }
/* While the admin page loads, the shared loading mark sits where the frame will appear (set in personal-dashboard.ts). */
#personal-admin-tool:not([hidden]) { position: relative; }
/* The loading mark shares the frame's grid cell, so it covers exactly where the page will appear. */
#personal-admin-tool > iframe, #personal-admin-tool > .admin-tool-loading { grid-column: -2 / -1; grid-row: -2 / -1; }
#personal-admin-tool > .admin-tool-loading { position: relative; z-index: 2; display: grid; place-content: center; margin: 0; background: white; }
@media (max-width: 800px) {
  #personal-admin-tool:not([hidden]) { height: 80svh; }
}

/* The workspace owns the tool menu. Only the content frame navigates. */
#personal-admin-tool:not([hidden]) {
  display: grid;
  grid-template-columns: 252px minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
  min-height: 0;
  overflow: hidden;
}
#personal-admin-tool iframe { height: 100%; min-width: 0; }
#admin-menu-toggle { display: none; }
#dashboard-admin-menu {
  display: grid; align-content: start; gap: .16rem; min-height: 0; overflow-y: auto;
  overscroll-behavior: contain; padding: 1.35rem 1rem 2rem; background: white;
  border-right: 1px solid #dae2e6; color: #647189; font-family: Manrope, sans-serif;
}
#dashboard-admin-menu a {
  display: flex; align-items: center; gap: .7rem; padding: .66rem .85rem;
  border-radius: 4px; color: inherit; font-size: .9rem; font-weight: 700; text-decoration: none;
}
#dashboard-admin-menu a:is(:hover, :focus-visible, .is-current) { background: #deefec; color: #164f48; }
#dashboard-admin-menu .portal-nav-label { margin: .35rem .85rem 0; color: #087fa8; font-size: .68rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
#dashboard-admin-menu .portal-nav-divider { height: 1px; margin: .45rem .3rem; background: #dae2e6; }
#dashboard-admin-menu .admin-nav-child { padding-left: 1.2rem; font-size: .82rem; }
#dashboard-admin-menu .admin-inbox-nav-badge:not([hidden]) { margin-left: auto; background: #164f48; color: white; border-radius: 1em; padding: .1em .5em; }
@media (min-width: 801px) and (max-width: 900px) {
  #personal-admin-tool:not([hidden]) { position: relative; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
  #admin-menu-toggle { display: block; justify-self: start; margin: .4rem .75rem; padding: .45rem .7rem; font: inherit; }
  #dashboard-admin-menu { position: absolute; z-index: 3; inset: 2.8rem auto 0 0; width: min(252px, 100%); }
  #admin-menu-toggle[aria-expanded="false"] + #dashboard-admin-menu { display: none; }
}

#personal-admin-tool:has(> #personal-admin-website:not([hidden])) {
  grid-template-columns: 252px clamp(230px, 17vw, 300px) minmax(0, 1fr);
}
#personal-admin-website { min-width: 0; min-height: 0; overflow: auto; --website-admin-border: #d9e1e5; --portal-muted: #647189; --portal-ink: #17252d; font-family: Manrope, sans-serif; }

.account-dashboard .client-workspace-scroll-region:has(#admin-app-section:not(.hidden)) {
  padding:0;
  background:white;
}
.account-dashboard #admin-app-section:not(.hidden) {
  width:100%;
  max-width:none;
  min-height:100%;
  margin:0;
  padding:clamp(.75rem,1.5vw,1.5rem);
  box-sizing:border-box;
}
#personal-product-view:not(.hidden) { display:grid; grid-template: minmax(0,1fr) / minmax(0,1fr); }
#personal-product-view > :is(.workspace-app-frame,.workspace-app-loading) { grid-area:1 / 1; min-height:0; }
#personal-product-view > .workspace-app-loading:not([hidden]) { display:grid; place-content:center; }

/* Size the dashboard from the actual header, including wrapped mobile controls. */
html:has(.account-panel.is-dashboard),
body:has(.account-panel.is-dashboard) { overflow: hidden; }
body:has(.account-panel.is-dashboard) { height: 100dvh; min-height: 0; margin: 0; }
body:has(.account-panel.is-dashboard) > .account-topbar { flex: 0 0 auto; }
.account-main:has(.account-panel.is-dashboard) { flex: 1 1 0; min-height: 0; overflow: hidden; }
.account-main .account-panel.is-dashboard { position: relative; display: flex; height: 100%; min-height: 0; gap: 0; align-items: stretch; }
.account-dashboard:not(.hidden) { display: flex; flex: 1 1 0; flex-direction: column; min-height: 0; min-width: 0; overflow: hidden; }
.account-dashboard .dashboard-views { display: block; flex: 1 1 0; height: auto; min-height: 0; overflow: hidden; }
.account-dashboard .client-workspace-scroll-region { min-height: 0; overflow: auto; overscroll-behavior: contain; }
.account-panel.is-dashboard .account-status:empty { display: none; }
.account-panel.is-dashboard .account-status:not(:empty) {
  position: absolute;
  z-index: 10;
  inset: auto 1rem 1rem auto;
  max-width: min(30rem, calc(100% - 2rem));
  padding: .75rem 1rem;
  background: white;
  border: 1px solid #d5dde5;
  border-radius: .5rem;
}
@media (max-width: 800px) {
  .account-dashboard .client-workspace-frame { height: 100%; overflow: hidden; }
  .account-dashboard .client-workspace-context-layout { display: grid; grid-template: auto minmax(0, 1fr) / minmax(0, 1fr); height: 100%; overflow: hidden; }
  .account-dashboard .client-workspace-content-column { display: flex; overflow: hidden; }
  .account-dashboard .client-workspace-organization-panel { max-height: 40dvh; overflow: auto; }
  .account-dashboard :is(#personal-settings-view,#personal-product-view),
  .account-dashboard :is(#personal-settings-view,#personal-product-view) iframe { min-height: 0; }
}

/* The sign-in card starts with the Sign in / Create account choice; the heading stays for screen readers. */
.auth-heading-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Inside the N3XRA app (html[data-native-app], set by the app): the sign-in page is the app, not the website,
   so the website's own header and footer are hidden. The signed-in dashboard header stays. */
html[data-native-app] .account-topbar.home-topbar,
html[data-native-app] .n3xra-footer { display: none !important; }

/* Site Manager's Site editor "Full width" (set from the Site Manager page): the admin menu and the organization
   workspace panel collapse to their icons so the editor and the site get the whole width. */
@media (min-width: 901px) {
  #personal-admin-tool.is-studio-focus:not([hidden]) { grid-template-columns: 64px minmax(0, 1fr); }
  #personal-admin-tool.is-studio-focus:has(> #personal-admin-website:not([hidden])) { grid-template-columns: 64px 64px minmax(0, 1fr); }
  #personal-admin-tool.is-studio-focus #dashboard-admin-menu { padding-inline: .5rem; }
  #personal-admin-tool.is-studio-focus #dashboard-admin-menu a { justify-content: center; gap: 0; padding-inline: 0; font-size: 0; }
  #personal-admin-tool.is-studio-focus #dashboard-admin-menu :is(.portal-nav-label, .admin-nav-child, .admin-inbox-nav-badge) { display: none; }
}
