@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

* { font-family: Inter, ui-sans-serif, system-ui, sans-serif; }
.form-input { width: 100%; border-radius: 0.5rem; border: 1px solid rgb(226 232 240); background: white; padding: 0.625rem 0.75rem; color: rgb(15 23 42); outline: none; }
.dark .form-input { border-color: rgb(51 65 85); background: rgb(15 23 42); color: rgb(226 232 240); }
.form-input:focus { border-color: var(--brand-primary, rgb(15 23 42)); box-shadow: 0 0 0 2px color-mix(in srgb, var(--brand-primary, rgb(15 23 42)) 18%, transparent); }
.dark .form-input:focus { border-color: var(--brand-primary, rgb(226 232 240)); box-shadow: 0 0 0 2px color-mix(in srgb, var(--brand-primary, rgb(226 232 240)) 22%, transparent); }
.search-select { position: relative; }
.search-select-control { position: relative; }
.search-select-input { padding-right: 2.5rem; }
.search-select-toggle,
.search-select-clear {
  position: absolute;
  top: 50%;
  display: inline-flex;
  height: 1.75rem;
  width: 1.75rem;
  transform: translateY(-50%);
  align-items: center;
  justify-content: center;
  border-radius: .375rem;
  color: rgb(100 116 139);
  transition: background .15s ease, color .15s ease;
}
.search-select-toggle { right: .35rem; pointer-events: none; }
.search-select-clear { right: .35rem; }
.search-select-clear:hover { background: rgb(241 245 249); color: rgb(15 23 42); }
.dark .search-select-clear:hover { background: rgb(30 41 59); color: rgb(241 245 249); }
.search-select-dropdown {
  position: absolute;
  z-index: 40;
  top: calc(100% + .35rem);
  left: 0;
  right: 0;
  max-height: 18rem;
  overflow-y: auto;
  border: 1px solid rgb(226 232 240);
  border-radius: .625rem;
  background: white;
  box-shadow: 0 12px 32px rgb(15 23 42 / 10%);
}
.dark .search-select-dropdown { border-color: rgb(51 65 85); background: rgb(15 23 42); box-shadow: 0 12px 32px rgb(0 0 0 / 35%); }
.search-select-group-title {
  position: sticky;
  top: 0;
  z-index: 1;
  border-bottom: 1px solid rgb(241 245 249);
  background: rgb(248 250 252);
  padding: .5rem .75rem;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgb(100 116 139);
}
.dark .search-select-group-title { border-color: rgb(30 41 59); background: rgb(15 23 42); color: rgb(148 163 184); }
.search-select-option {
  display: block;
  width: 100%;
  border: 0;
  background: transparent;
  padding: .7rem .75rem;
  text-align: left;
  color: rgb(15 23 42);
  transition: background .15s ease;
}
.dark .search-select-option { color: rgb(226 232 240); }
.search-select-option:hover,
.search-select-option.is-highlighted { background: rgb(241 245 249); }
.dark .search-select-option:hover,
.dark .search-select-option.is-highlighted { background: rgb(30 41 59); }
.search-select-option.is-selected { background: color-mix(in srgb, var(--brand-primary, rgb(15 23 42)) 10%, white); }
.search-select-option-title { display: block; font-size: .875rem; font-weight: 600; }
.search-select-option-meta { display: block; margin-top: .15rem; font-size: .75rem; color: rgb(100 116 139); }
.search-select-empty { padding: 1rem; text-align: center; font-size: .875rem; color: rgb(100 116 139); }
.dashboard-tabs {
  display: flex;
  flex-wrap: nowrap;
  gap: .25rem;
  border-bottom: 1px solid rgb(226 232 240);
  padding-bottom: .25rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.dashboard-tabs::-webkit-scrollbar { display: none; }
@media (min-width: 640px) {
  .dashboard-tabs {
    flex-wrap: wrap;
    gap: .5rem;
    overflow-x: visible;
  }
}
.dark .dashboard-tabs { border-color: rgb(51 65 85); }
.dashboard-tab {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  padding: .625rem .75rem;
  font-size: .8125rem;
  font-weight: 600;
  color: rgb(100 116 139);
  white-space: nowrap;
  flex-shrink: 0;
  transition: color .15s ease, border-color .15s ease;
}
@media (min-width: 640px) {
  .dashboard-tab {
    padding: .625rem .875rem;
    font-size: .875rem;
  }
}
.dashboard-tab:hover { color: rgb(15 23 42); }
.dark .dashboard-tab:hover { color: rgb(241 245 249); }
.dashboard-tab.is-active {
  border-bottom-color: var(--brand-primary, rgb(15 23 42));
  color: rgb(15 23 42);
}
.dark .dashboard-tab.is-active { color: rgb(241 245 249); }
.input-error { border-color: rgb(239 68 68) !important; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; border-radius: .5rem; padding: .6rem .9rem; font-weight: 600; transition: .15s; border: 1px solid transparent; }
.btn-primary,
.btn.btn-primary,
button.btn-primary { background-color: var(--brand-primary, rgb(15 23 42)) !important; border-color: var(--brand-primary, rgb(15 23 42)) !important; color: #fff !important; }
.btn-primary:hover,
.btn.btn-primary:hover,
button.btn-primary:hover { filter: brightness(1.12); }
.dark .btn-primary,
.dark .btn.btn-primary,
.dark button.btn-primary { background-color: var(--brand-primary, rgb(15 23 42)) !important; border-color: var(--brand-primary, rgb(15 23 42)) !important; color: #fff !important; }
.btn-outline { border: 1px solid rgb(226 232 240); background: white; color: rgb(15 23 42); }
.dark .btn-outline { border-color: rgb(51 65 85); background: rgb(15 23 42); color: rgb(226 232 240); }
.card { border: 1px solid rgb(226 232 240); background: white; border-radius: .5rem; }
.dark .card { border-color: rgb(51 65 85); background: rgb(15 23 42); }
.badge { border-radius: 999px; padding: .15rem .55rem; font-size: .75rem; font-weight: 600; }
.permission-toggle-track { display: block; width: 2.5rem; height: 1.4rem; border-radius: 999px; background: rgb(203 213 225); padding: .15rem; transition: .15s; }
.permission-toggle-thumb { display: block; width: 1.1rem; height: 1.1rem; border-radius: 999px; background: white; box-shadow: 0 1px 2px rgb(15 23 42 / 25%); transition: transform .15s; }
.permission-toggle input:checked + .permission-toggle-track { background: var(--brand-primary, rgb(15 23 42)); }
.permission-toggle input:checked + .permission-toggle-track .permission-toggle-thumb { transform: translateX(1.1rem); }
.permission-toggle input:focus-visible + .permission-toggle-track { outline: 2px solid var(--brand-primary, rgb(15 23 42)); outline-offset: 2px; }
#appSidebar { transform: translateX(-100%); }
body.sidebar-open #appSidebar { transform: translateX(0); }
#appNavbar, #appMain { margin-left: 0; }
@media (min-width: 1024px) {
  body.sidebar-open #appNavbar,
  body.sidebar-open #appMain { margin-left: 16rem; }
}
body.sidebar-ready #appSidebar,
body.sidebar-ready #appNavbar,
body.sidebar-ready #appMain { transition: transform .2s ease, margin-left .2s ease; }
.sidebar-section-title { padding: 0 .75rem; font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: rgb(148 163 184); }
.dark .sidebar-section-title { color: rgb(100 116 139); }
.sidebar-link { display: flex; align-items: center; gap: .75rem; border-radius: .625rem; padding: .625rem .75rem; font-size: .875rem; font-weight: 500; color: rgb(71 85 105); transition: background .15s ease, color .15s ease; }
.dark .sidebar-link { color: rgb(148 163 184); }
.sidebar-link:hover { background: rgb(241 245 249); color: rgb(15 23 42); }
.dark .sidebar-link:hover { background: rgb(15 23 42); color: rgb(241 245 249); }
.sidebar-link.is-active { background: var(--brand-primary, rgb(15 23 42)); color: #fff; box-shadow: 0 1px 2px color-mix(in srgb, var(--brand-primary, rgb(15 23 42)) 35%, transparent); }
.dark .sidebar-link.is-active { background: var(--brand-primary, rgb(241 245 249)); color: #fff; }
.sidebar-link-icon { width: 1.125rem; height: 1.125rem; flex-shrink: 0; }
.sidebar-nav {
  scrollbar-width: thin;
  scrollbar-color: rgb(203 213 225) transparent;
}
.dark .sidebar-nav { scrollbar-color: rgb(51 65 85) transparent; }
.sidebar-nav::-webkit-scrollbar { width: 5px; }
.sidebar-nav::-webkit-scrollbar-track { background: transparent; margin: .25rem 0; }
.sidebar-nav::-webkit-scrollbar-thumb {
  background: rgb(226 232 240);
  border-radius: 999px;
  border: 1px solid transparent;
  background-clip: padding-box;
}
.sidebar-nav::-webkit-scrollbar-thumb:hover { background: rgb(203 213 225); }
.dark .sidebar-nav::-webkit-scrollbar-thumb { background: rgb(51 65 85); }
.dark .sidebar-nav::-webkit-scrollbar-thumb:hover { background: rgb(71 85 105); }
.sidebar-footer {
  background: linear-gradient(180deg, rgb(255 255 255 / 0) 0%, rgb(248 250 252 / 95) 28%, rgb(248 250 252) 100%);
}
.dark .sidebar-footer {
  background: linear-gradient(180deg, rgb(2 6 23 / 0) 0%, rgb(15 23 42 / 95) 28%, rgb(15 23 42) 100%);
}
.sidebar-logout {
  display: flex;
  width: 100%;
  align-items: center;
  gap: .75rem;
  border-radius: .625rem;
  border: 1px solid rgb(226 232 240);
  background: white;
  padding: .625rem .75rem;
  font-size: .875rem;
  font-weight: 500;
  color: rgb(71 85 105);
  box-shadow: 0 1px 2px rgb(15 23 42 / 4%);
  transition: background .15s ease, border-color .15s ease, color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.sidebar-logout:hover {
  border-color: rgb(254 202 202);
  background: rgb(255 251 251);
  color: rgb(185 28 28);
  box-shadow: 0 4px 12px rgb(239 68 68 / 8%);
}
.sidebar-logout:active { transform: translateY(1px); }
.dark .sidebar-logout {
  border-color: rgb(51 65 85);
  background: rgb(15 23 42);
  color: rgb(203 213 225);
  box-shadow: none;
}
.dark .sidebar-logout:hover {
  border-color: rgb(127 29 29);
  background: rgb(30 20 20);
  color: rgb(252 165 165);
  box-shadow: 0 4px 12px rgb(0 0 0 / 20%);
}
.sidebar-logout-icon {
  display: inline-flex;
  height: 2rem;
  width: 2rem;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  border-radius: .5rem;
  background: rgb(241 245 249);
  color: rgb(100 116 139);
  transition: background .15s ease, color .15s ease;
}
.sidebar-logout:hover .sidebar-logout-icon {
  background: rgb(254 226 226);
  color: rgb(220 38 38);
}
.dark .sidebar-logout-icon { background: rgb(30 41 59); color: rgb(148 163 184); }
.dark .sidebar-logout:hover .sidebar-logout-icon {
  background: rgb(69 10 10);
  color: rgb(252 165 165);
}
.sidebar-logout-label { line-height: 1.2; }

.segment-option {
  border-radius: .375rem;
  padding: .5rem .75rem;
  font-size: .875rem;
  font-weight: 600;
  color: rgb(71 85 105);
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.dark .segment-option { color: rgb(203 213 225); }
.segment-option.is-active {
  background-color: var(--brand-primary, rgb(15 23 42)) !important;
  color: #fff !important;
}

.brand-step {
  border-radius: .5rem;
  border: 1px solid rgb(226 232 240);
  padding: .5rem .75rem;
  font-size: .875rem;
  font-weight: 600;
  color: rgb(100 116 139);
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.dark .brand-step { border-color: rgb(51 65 85); color: rgb(148 163 184); }
.brand-step.is-active {
  background-color: var(--brand-primary, rgb(15 23 42)) !important;
  border-color: var(--brand-primary, rgb(15 23 42)) !important;
  color: #fff !important;
}

.login-page {
  min-height: 100vh;
  background: #fff;
  color: rgb(15 23 42);
  --login-glow-base: #111a2f;
}

.login-page.login-page--tenant {
  --login-glow-base: var(--brand-primary);
}

.login-shell {
  display: flex;
  min-height: 100vh;
}

.login-hero {
  display: none;
}

.login-form-area {
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  padding: 2.5rem 1.5rem;
}

.login-panels-stage {
  overflow: hidden;
  opacity: 1;
  transform: translateX(0);
  transition: opacity .32s ease, transform .32s ease;
}

.login-panels-stage--leave-left {
  opacity: 0;
  transform: translateX(-24px);
}

.login-panels-stage--leave-right {
  opacity: 0;
  transform: translateX(24px);
}

.login-panels-stage--enter-right {
  opacity: 0;
  transform: translateX(24px);
}

.login-panels-stage--enter-left {
  opacity: 0;
  transform: translateX(-24px);
}

@media (prefers-reduced-motion: reduce) {
  .login-panels-stage {
    transition: none;
  }

  .login-panels-stage--leave-left,
  .login-panels-stage--leave-right,
  .login-panels-stage--enter-right,
  .login-panels-stage--enter-left {
    opacity: 1;
    transform: none;
  }
}

.login-hero-panel {
  position: relative;
  isolation: isolate;
  display: flex;
  width: 100%;
  flex: 1;
  height: 100%;
  min-height: calc(100vh - 0.5rem);
  overflow: hidden;
  border-radius: 1rem;
  border: 1px solid rgb(255 255 255 / 55%);
  background: #e8eef5;
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 70%),
    0 16px 40px rgb(15 23 42 / 8%);
}

.login-hero-glow {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  border-radius: inherit;
  background: linear-gradient(155deg, #f8fafc 0%, #e2e8f0 100%);
}

.login-hero-blob {
  position: absolute;
  border-radius: 999px;
  filter: blur(64px);
  opacity: .95;
  will-change: transform;
  animation: login-blob-drift 22s ease-in-out infinite;
}

.login-hero-blob--1 {
  top: -12%;
  left: -20%;
  width: 44rem;
  height: 44rem;
  background: color-mix(in srgb, var(--login-glow-base) 92%, #000 8%);
  animation-duration: 19s;
}

.login-hero-blob--2 {
  top: 28%;
  right: -24%;
  width: 38rem;
  height: 38rem;
  background: color-mix(in srgb, var(--login-glow-base) 78%, #fff 22%);
  animation-duration: 26s;
  animation-delay: -5s;
}

.login-hero-blob--3 {
  left: 10%;
  bottom: -22%;
  width: 36rem;
  height: 36rem;
  background: color-mix(in srgb, var(--login-glow-base) 58%, #fff 42%);
  animation-duration: 23s;
  animation-delay: -10s;
}

.login-hero-blob--4 {
  top: 52%;
  left: 34%;
  width: 30rem;
  height: 30rem;
  background: color-mix(in srgb, var(--login-glow-base) 38%, #fff 62%);
  animation-duration: 21s;
  animation-delay: -14s;
}

.login-hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  width: 100%;
  height: 100%;
  min-height: inherit;
  flex: 1;
  flex-direction: column;
  justify-content: space-between;
  padding: 2.25rem;
  border-radius: inherit;
  background: linear-gradient(
    145deg,
    rgb(255 255 255 / 28%) 0%,
    rgb(255 255 255 / 12%) 100%
  );
  backdrop-filter: blur(36px) saturate(165%);
  -webkit-backdrop-filter: blur(36px) saturate(165%);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 72%);
}

@keyframes login-blob-drift {
  0%, 100% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  25% {
    transform: translate3d(14%, -10%, 0) scale(1.14);
  }
  50% {
    transform: translate3d(-8%, 12%, 0) scale(.9);
  }
  75% {
    transform: translate3d(10%, 16%, 0) scale(1.08);
  }
}

.login-hero-brand,
.login-hero-tagline {
  position: relative;
  z-index: 1;
}

.login-hero-logo {
  display: block;
  max-height: 5rem;
  max-width: min(380px, 82%);
  width: auto;
  height: auto;
  object-fit: contain;
  object-position: left center;
}

.login-hero-tagline {
  max-width: 20rem;
  font-size: clamp(1.75rem, 2.4vw, 2.35rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.03em;
  color: rgb(15 23 42);
}

.login-form-wrap {
  width: 100%;
  max-width: 24rem;
  margin: 0 auto;
}

.register-form-wrap {
  max-width: 28rem;
}

.login-mobile-brand {
  display: flex;
  justify-content: center;
  margin-bottom: 2rem;
}

.login-panel-header {
  margin-bottom: 1.5rem;
}

.login-form-fields {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.login-forgot-actions {
  margin-top: .35rem;
  text-align: center;
}

.login-title {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -.03em;
  color: rgb(15 23 42);
}

.login-subtitle {
  margin-top: .35rem;
  font-size: .95rem;
  color: rgb(100 116 139);
}

.login-field {
  display: block;
  margin-bottom: .45rem;
  font-size: .875rem;
  font-weight: 500;
  color: rgb(51 65 85);
}

.login-input {
  width: 100%;
  border-radius: .75rem;
  border: 1px solid transparent;
  background: rgb(243 244 246);
  padding: .8rem 1rem;
  color: rgb(15 23 42);
  outline: none;
  transition: border-color .15s ease, background-color .15s ease, box-shadow .15s ease;
}

.login-input:focus {
  border-color: color-mix(in srgb, var(--brand-primary, rgb(15 23 42)) 28%, rgb(226 232 240));
  background: #fff;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand-primary, rgb(15 23 42)) 12%, transparent);
}

.login-input:-webkit-autofill,
.login-input:-webkit-autofill:hover {
  -webkit-box-shadow: 0 0 0 1000px rgb(243 244 246) inset;
  -webkit-text-fill-color: rgb(15 23 42);
  caret-color: rgb(15 23 42);
  transition: background-color 99999s ease-out;
}

.login-input:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px #fff inset;
  -webkit-text-fill-color: rgb(15 23 42);
}

.login-input.input-error {
  border-color: rgb(252 165 165);
  background: rgb(254 242 242);
}

.login-password-wrap {
  position: relative;
}

.login-password-wrap .login-input {
  padding-right: 2.75rem;
}

.login-password-toggle {
  position: absolute;
  top: 50%;
  right: .75rem;
  display: inline-flex;
  transform: translateY(-50%);
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  padding: .25rem;
  color: rgb(148 163 184);
  cursor: pointer;
  transition: color .15s ease;
}

.login-password-toggle:hover {
  color: rgb(71 85 105);
}

.password-field-wrap {
  position: relative;
}

.password-field-wrap .form-input {
  padding-right: 2.75rem;
}

.password-field-toggle {
  position: absolute;
  top: 50%;
  right: .75rem;
  display: inline-flex;
  transform: translateY(-50%);
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  padding: .25rem;
  color: rgb(148 163 184);
  cursor: pointer;
  transition: color .15s ease;
}

.password-field-toggle:hover {
  color: rgb(71 85 105);
}

.external-links-table-wrap thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: rgb(241 245 249);
}

.dark .external-links-table-wrap thead th {
  background: rgb(15 23 42);
}

.profile-page {
  padding-bottom: 1rem;
}

.profile-identity {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding: 1.5rem;
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--brand-primary, rgb(15 23 42)) 8%, white) 0%, white 100%);
}

.dark .profile-identity {
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--brand-primary, rgb(226 232 240)) 10%, rgb(15 23 42)) 0%, rgb(15 23 42) 100%);
}

@media (min-width: 640px) {
  .profile-identity {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.profile-identity-main {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-width: 0;
}

.profile-identity-copy {
  min-width: 0;
}

.profile-identity-copy h2,
.profile-identity-copy p {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 4.5rem;
  height: 4.5rem;
  flex-shrink: 0;
  border-radius: 1rem;
  background: var(--brand-primary, rgb(15 23 42));
  color: #fff;
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: .04em;
}

.profile-section-header {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
}

.profile-section-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  flex-shrink: 0;
  border-radius: .625rem;
  background: color-mix(in srgb, var(--brand-primary, rgb(15 23 42)) 10%, white);
  color: var(--brand-primary, rgb(15 23 42));
}

.dark .profile-section-icon {
  background: color-mix(in srgb, var(--brand-primary, rgb(226 232 240)) 12%, rgb(15 23 42));
  color: var(--brand-primary, rgb(226 232 240));
}

.profile-info-grid {
  display: grid;
  gap: .75rem;
}

@media (min-width: 768px) {
  .profile-info-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.profile-info-item {
  display: flex;
  gap: .75rem;
  min-width: 0;
  border: 1px solid rgb(226 232 240);
  border-radius: .75rem;
  padding: 1rem;
  background: rgb(248 250 252);
}

.dark .profile-info-item {
  border-color: rgb(51 65 85);
  background: rgb(15 23 42);
}

.profile-info-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  flex-shrink: 0;
  border-radius: .625rem;
  background: white;
  color: rgb(71 85 105);
}

.dark .profile-info-icon {
  background: rgb(30 41 59);
  color: rgb(203 213 225);
}

.profile-info-label {
  font-size: .75rem;
  font-weight: 600;
  color: rgb(100 116 139);
}

.profile-info-value {
  margin-top: .25rem;
  font-size: .95rem;
  font-weight: 600;
  color: rgb(15 23 42);
  word-break: break-word;
}

.dark .profile-info-value {
  color: rgb(241 245 249);
}

.profile-access-grid {
  display: grid;
  gap: .75rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.profile-access-card {
  border: 1px solid rgb(226 232 240);
  border-radius: .75rem;
  padding: 1rem;
  background: white;
}

.dark .profile-access-card {
  border-color: rgb(51 65 85);
  background: rgb(15 23 42);
}

.profile-access-card--highlight {
  grid-column: 1 / -1;
  background: rgb(248 250 252);
}

.dark .profile-access-card--highlight {
  background: rgb(30 41 59);
}

.settings-page {
  padding-bottom: 1rem;
}

.settings-layout {
  display: grid;
  gap: 1.5rem;
  align-items: start;
}

@media (min-width: 1280px) {
  .settings-layout {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  }
}

.settings-side {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.settings-section-header {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
}

.settings-section-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  flex-shrink: 0;
  border-radius: .625rem;
  background: color-mix(in srgb, var(--brand-primary, rgb(15 23 42)) 10%, white);
  color: var(--brand-primary, rgb(15 23 42));
}

.dark .settings-section-icon {
  background: color-mix(in srgb, var(--brand-primary, rgb(226 232 240)) 12%, rgb(15 23 42));
  color: var(--brand-primary, rgb(226 232 240));
}

.settings-group + .settings-group {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgb(241 245 249);
}

.dark .settings-group + .settings-group {
  border-top-color: rgb(30 41 59);
}

.settings-group-title {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgb(100 116 139);
}

.settings-field-grid {
  display: grid;
  gap: 1rem;
}

.settings-field-grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.settings-field {
  display: block;
}

.settings-field--compact {
  max-width: 10rem;
}

.settings-field-label {
  display: block;
  margin-bottom: .4rem;
  font-size: .875rem;
  font-weight: 500;
  color: rgb(51 65 85);
}

.dark .settings-field-label {
  color: rgb(203 213 225);
}

.settings-field-hint {
  display: block;
  margin-top: .35rem;
  font-size: .75rem;
  line-height: 1.4;
  color: rgb(100 116 139);
}

.settings-toggle {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  border-radius: 9999px;
  border: 1px solid rgb(226 232 240);
  background: rgb(248 250 252);
  padding: .35rem .75rem;
  font-size: .8125rem;
  font-weight: 600;
  color: rgb(51 65 85);
  white-space: nowrap;
}

.dark .settings-toggle {
  border-color: rgb(51 65 85);
  background: rgb(30 41 59);
  color: rgb(226 232 240);
}

.settings-smtp-server {
  display: grid;
  gap: 1rem;
  grid-template-columns: minmax(0, 1fr);
}

@media (min-width: 640px) {
  .settings-smtp-server {
    grid-template-columns: minmax(0, 1fr) 5.5rem 8.5rem;
  }
}

.settings-note {
  border-radius: .625rem;
  border: 1px dashed rgb(226 232 240);
  background: rgb(248 250 252);
  padding: .75rem .9rem;
  font-size: .75rem;
  line-height: 1.45;
  color: rgb(100 116 139);
}

.dark .settings-note {
  border-color: rgb(51 65 85);
  background: rgb(30 41 59);
  color: rgb(148 163 184);
}

.settings-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  position: sticky;
  bottom: 1rem;
  z-index: 20;
}

.settings-actions .btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
}

@media (max-width: 639px) {
  .settings-field-grid--2 {
    grid-template-columns: minmax(0, 1fr);
  }
}

.login-error {
  border-radius: .75rem;
  border: 1px solid rgb(254 202 202);
  background: rgb(254 242 242);
  padding: .75rem 1rem;
  font-size: .875rem;
  color: rgb(185 28 28);
}

.login-success {
  border-radius: .75rem;
  border: 1px solid rgb(167 243 208);
  background: rgb(236 253 245);
  padding: .75rem 1rem;
  font-size: .875rem;
  color: rgb(4 120 87);
}

.login-forgot-link {
  border: 0;
  background: transparent;
  padding: 0;
  font-size: .82rem;
  font-weight: 600;
  color: var(--brand-primary, rgb(15 23 42));
  cursor: pointer;
  text-decoration: none;
}

.login-forgot-link:hover {
  color: color-mix(in srgb, var(--brand-primary, rgb(15 23 42)) 85%, black);
  text-decoration: underline;
}

.login-submit {
  width: 100%;
  border-radius: .75rem;
  border: 1px solid var(--brand-primary, rgb(15 23 42));
  background: var(--brand-primary, rgb(15 23 42));
  padding: .85rem 1rem;
  font-size: .95rem;
  font-weight: 600;
  color: #fff;
  transition: filter .15s ease, transform .15s ease;
}

.login-submit:hover:not(:disabled) {
  filter: brightness(1.08);
}

.login-submit:active:not(:disabled) {
  transform: scale(.99);
}

.login-submit:disabled {
  cursor: not-allowed;
  opacity: .7;
}

.login-footer {
  margin-top: 2.5rem;
  text-align: center;
  font-size: .8rem;
  color: rgb(148 163 184);
}

@media (min-width: 1024px) {
  .login-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .login-hero {
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding: 0.25rem 0.625rem 0.25rem 0.25rem;
  }

  .login-mobile-brand {
    display: none;
  }

  .login-form-area {
    width: auto;
    flex: initial;
    min-width: 0;
    padding: 2.5rem 3rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .login-hero-blob {
    animation: none;
  }
}

.project-status-page {
  min-height: 100vh;
}

.project-status-shell {
  min-height: 100vh;
  padding: 1.5rem 1rem 2rem;
}

.project-status-container {
  margin: 0 auto;
  max-width: 72rem;
}

.project-status-card {
  border: 1px solid rgb(226 232 240);
  border-radius: 1rem;
  background: white;
  box-shadow: 0 1px 2px rgb(15 23 42 / 4%);
}

.project-status-hero {
  position: relative;
  overflow: hidden;
  border-radius: 1.25rem;
  background: var(--brand-primary, rgb(47 91 255));
  color: white;
  box-shadow: 0 12px 32px color-mix(in srgb, var(--brand-primary, rgb(47 91 255)) 28%, transparent);
}

.project-status-hero-glow {
  display: none;
}

.project-status-hero-inner {
  position: relative;
  padding: 1.75rem;
}

.project-status-eyebrow {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: rgb(255 255 255 / 75%);
}

.project-status-brand-logo {
  width: 3.5rem;
  height: 3.5rem;
  flex-shrink: 0;
  border-radius: .875rem;
  border: 1px solid rgb(255 255 255 / 20%);
  background: rgb(255 255 255 / 12%);
  object-fit: contain;
  padding: .4rem;
}

.project-status-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: rgb(255 255 255 / 14%);
  padding: .45rem .8rem;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  backdrop-filter: blur(8px);
}

.project-status-kpi-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (min-width: 1024px) {
  .project-status-kpi-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.project-status-kpi {
  padding: 1.25rem;
}

.project-status-kpi-label,
.project-status-meta-label,
.project-status-section-title {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgb(100 116 139);
}

.project-status-kpi-value,
.project-status-meta-value {
  font-size: 1.125rem;
  font-weight: 700;
  color: rgb(15 23 42);
}

.project-status-pill {
  display: inline-flex;
  border-radius: 999px;
  background: color-mix(in srgb, var(--brand-primary, rgb(47 91 255)) 12%, white);
  padding: .35rem .75rem;
  font-size: .82rem;
  font-weight: 700;
  color: var(--brand-primary, rgb(47 91 255));
}

.project-status-progress-track {
  height: .65rem;
  overflow: hidden;
  border-radius: 999px;
  background: rgb(226 232 240);
}

.project-status-progress-track--sm {
  height: .45rem;
}

.project-status-progress-bar {
  height: 100%;
  border-radius: 999px;
  background: var(--brand-primary, rgb(47 91 255));
  transition: width .45s ease;
}

.project-status-chip {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  border-radius: 999px;
  padding: .35rem .7rem;
  font-size: .75rem;
  font-weight: 600;
}

.project-status-chip--pending { background: rgb(254 243 199); color: rgb(146 64 14); }
.project-status-chip--started { background: rgb(219 234 254); color: rgb(29 78 216); }
.project-status-chip--completed { background: rgb(209 250 229); color: rgb(4 120 87); }
.project-status-chip--overdue { background: rgb(255 228 230); color: rgb(190 18 60); }

.project-status-counter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 3rem;
  border-radius: 999px;
  background: rgb(241 245 249);
  padding: .35rem .75rem;
  font-size: .82rem;
  font-weight: 700;
  color: rgb(51 65 85);
}

.project-status-task-card {
  cursor: pointer;
  border: 1px solid rgb(226 232 240);
  border-radius: 1rem;
  background: white;
  padding: 1rem 1.1rem;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.project-status-task-card:hover {
  border-color: color-mix(in srgb, var(--brand-primary, rgb(47 91 255)) 35%, rgb(226 232 240));
  box-shadow: 0 10px 24px rgb(15 23 42 / 6%);
  transform: translateY(-1px);
}

.project-status-task-meta {
  display: flex;
  flex-direction: column;
  gap: .2rem;
}

.project-status-quick-stat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border-radius: .75rem;
  border: 1px solid rgb(241 245 249);
  background: rgb(248 250 252);
  padding: .8rem .95rem;
  font-size: .875rem;
  color: rgb(100 116 139);
}

.project-status-quick-stat strong {
  font-size: 1rem;
  color: rgb(15 23 42);
}

.project-status-empty {
  border: 1px dashed rgb(203 213 225);
  border-radius: 1rem;
  padding: 2rem;
  text-align: center;
}

.project-status-step,
.project-status-flow-step,
.project-status-document,
.project-status-comment {
  display: flex;
  gap: .75rem;
  border: 1px solid rgb(226 232 240);
  border-radius: .85rem;
  padding: .8rem .9rem;
  background: white;
}

.project-status-step.is-done {
  background: rgb(240 253 244);
}

.project-status-step-check,
.project-status-flow-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.6rem;
  height: 1.6rem;
  flex-shrink: 0;
  border-radius: 999px;
  background: rgb(241 245 249);
  font-size: .72rem;
  font-weight: 700;
  color: rgb(71 85 105);
}

.project-status-step.is-done .project-status-step-check {
  background: rgb(16 185 129);
  color: white;
}

.project-status-flow-index {
  background: color-mix(in srgb, var(--brand-primary, rgb(47 91 255)) 12%, white);
  color: var(--brand-primary, rgb(47 91 255));
}

.project-status-timeline {
  position: relative;
  padding-left: 1rem;
}

.project-status-timeline::before {
  content: '';
  position: absolute;
  top: .4rem;
  bottom: .4rem;
  left: .28rem;
  width: 2px;
  background: rgb(226 232 240);
}

.project-status-timeline-item {
  position: relative;
  padding: 0 0 1rem 1rem;
}

.project-status-timeline-dot {
  position: absolute;
  left: -.15rem;
  top: .35rem;
  width: .65rem;
  height: .65rem;
  border-radius: 999px;
  background: var(--brand-primary, rgb(47 91 255));
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand-primary, rgb(47 91 255)) 15%, white);
}

.project-status-modal {
  max-height: calc(100vh - 2rem);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.project-status-modal #publicTaskContent {
  overflow-y: auto;
  max-height: calc(100vh - 12rem);
}

.logs-summary-grid {
  display: grid;
  gap: .75rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (min-width: 768px) {
  .logs-summary-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

.logs-summary-card {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
  padding: 1rem;
  border: 1px solid rgb(226 232 240);
  border-radius: 1rem;
  background: white;
}

.dark .logs-summary-card {
  border-color: rgb(30 41 59);
  background: rgb(2 6 23);
}

.logs-summary-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: .75rem;
  flex-shrink: 0;
}

.logs-summary-icon svg {
  width: 1rem;
  height: 1rem;
}

.logs-summary-value {
  display: block;
  margin-top: .15rem;
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.1;
}

.logs-filter-grid {
  display: grid;
  gap: .75rem;
}

@media (min-width: 1024px) {
  .logs-filter-grid {
    grid-template-columns: 1.4fr repeat(4, minmax(0, 1fr)) auto;
    align-items: end;
  }
}

.logs-filter-field label {
  display: block;
  margin-bottom: .35rem;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: rgb(100 116 139);
}

.logs-filter-actions {
  display: flex;
  gap: .5rem;
}

.logs-timeline {
  padding: .5rem 0 1rem;
}

.logs-timeline-group + .logs-timeline-group {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgb(241 245 249);
}

.dark .logs-timeline-group + .logs-timeline-group {
  border-top-color: rgb(30 41 59);
}

.logs-timeline-group-title {
  margin-bottom: .75rem;
  padding: 0 1rem;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgb(100 116 139);
}

.logs-entry {
  display: flex;
  width: 100%;
  gap: .85rem;
  padding: .85rem 1rem;
  border: 0;
  border-bottom: 1px solid rgb(241 245 249);
  background: transparent;
  text-align: left;
  transition: background-color .15s ease;
}

.dark .logs-entry {
  border-bottom-color: rgb(30 41 59);
}

.logs-entry:hover,
.logs-entry:focus-visible {
  background: rgb(248 250 252);
  outline: none;
}

.dark .logs-entry:hover,
.dark .logs-entry:focus-visible {
  background: rgb(15 23 42);
}

.logs-entry-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.35rem;
  height: 2.35rem;
  border-radius: .8rem;
  flex-shrink: 0;
}

.logs-entry-icon svg {
  width: 1rem;
  height: 1rem;
}

.logs-entry-body {
  min-width: 0;
  flex: 1;
}

.logs-entry-title {
  font-size: .92rem;
  font-weight: 600;
  color: rgb(15 23 42);
}

.dark .logs-entry-title {
  color: rgb(248 250 252);
}

.logs-entry-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .35rem .55rem;
  margin-top: .3rem;
  font-size: .78rem;
  color: rgb(100 116 139);
}

.logs-entry-time {
  flex-shrink: 0;
  align-self: flex-start;
  margin-left: auto;
  padding-left: .75rem;
  font-size: .75rem;
  font-weight: 500;
  color: rgb(100 116 139);
  white-space: nowrap;
}

.logs-detail-grid {
  display: grid;
  gap: .75rem;
}

@media (min-width: 640px) {
  .logs-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.logs-detail-item {
  border: 1px solid rgb(226 232 240);
  border-radius: .85rem;
  padding: .85rem;
}

.dark .logs-detail-item {
  border-color: rgb(30 41 59);
}

.logs-detail-item.is-wide {
  grid-column: 1 / -1;
}
