:root {
  --ls-navy: #0b1f3a;
  --ls-blue: #2f80ed;
  --ls-teal: #00c2a8;
  --ls-light: #e6eaf0;
  --ls-white: #ffffff;
  --ls-ink: #102641;
  --ls-muted: #5c6f86;
  --ls-surface: #f4f8fc;
  --ls-panel: rgba(255, 255, 255, 0.96);
  --ls-line: rgba(11, 31, 58, 0.1);
  --ls-shadow: 0 20px 60px rgba(11, 31, 58, 0.12);
  --ls-radius-lg: 28px;
  --ls-radius-md: 18px;
  --ls-radius-sm: 12px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Avenir Next", "Segoe UI", "Helvetica Neue", sans-serif;
  background:
    radial-gradient(circle at top right, rgba(47, 128, 237, 0.18), transparent 28%),
    linear-gradient(180deg, #edf4fb 0%, #f7fbff 48%, #eef8f6 100%);
  color: var(--ls-ink);
}

a {
  color: var(--ls-blue);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.portal-header {
  padding: 1.4rem 1.6rem 1.2rem;
  color: white;
  background:
    radial-gradient(circle at top right, rgba(0, 194, 168, 0.22), transparent 28%),
    linear-gradient(135deg, var(--ls-navy), #15315e 58%, #0c4567);
  box-shadow: 0 16px 48px rgba(11, 31, 58, 0.2);
}

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

.portal-brand {
  display: grid;
  gap: 0.5rem;
}

.portal-brand__logo {
  width: min(280px, 100%);
  height: auto;
}

.portal-brand__tagline {
  margin: 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.96rem;
  font-weight: 600;
}

.portal-brand__summary {
  margin: 0;
  color: rgba(255, 255, 255, 0.74);
  max-width: 860px;
}

.portal-nav {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 0.85rem;
}

.portal-nav a {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  font-weight: 700;
  padding: 0.5rem 0.8rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.portal-nav a:hover {
  text-decoration: none;
  background: rgba(255, 255, 255, 0.14);
}

.portal-user {
  display: grid;
  gap: 0.25rem;
  justify-items: end;
}

.portal-user__actions {
  margin-top: 0.65rem;
}

.portal-user__name {
  font-weight: 700;
}

.portal-user__role {
  color: rgba(255, 255, 255, 0.74);
}

.portal-signout {
  background: rgba(255, 255, 255, 0.12);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow: none;
}

.portal-signout:hover {
  background: rgba(255, 255, 255, 0.18);
}

main {
  max-width: 1160px;
  margin: 0 auto;
  padding: 1.5rem;
}

.card {
  background: var(--ls-panel);
  border-radius: var(--ls-radius-lg);
  box-shadow: var(--ls-shadow);
  border: 1px solid rgba(255, 255, 255, 0.7);
  padding: 1.4rem;
  margin-bottom: 1rem;
  backdrop-filter: blur(16px);
}

.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

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

.metric {
  font-size: 2rem;
  font-weight: 800;
  margin: 0.25rem 0;
  color: var(--ls-navy);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  text-align: left;
  padding: 0.75rem;
  border-bottom: 1px solid rgba(11, 31, 58, 0.08);
  vertical-align: top;
}

.muted {
  color: var(--ls-muted);
}

.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.pill {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: rgba(47, 128, 237, 0.12);
  color: var(--ls-blue);
  font-size: 0.85rem;
  font-weight: 700;
}

.actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

a.button,
button {
  background: linear-gradient(135deg, var(--ls-blue), var(--ls-teal));
  color: white;
  text-decoration: none;
  border: 0;
  border-radius: 999px;
  padding: 0.72rem 1rem;
  cursor: pointer;
  font-weight: 800;
  box-shadow: 0 14px 32px rgba(47, 128, 237, 0.18);
}

a.button:hover,
button:hover {
  text-decoration: none;
  transform: translateY(-1px);
}

a.subtle,
button.subtle {
  background: rgba(11, 31, 58, 0.08);
  color: var(--ls-navy);
  box-shadow: none;
}

form p {
  margin-bottom: 0.9rem;
}

input,
textarea,
select {
  width: 100%;
  padding: 0.7rem;
  border-radius: 14px;
  border: 1px solid rgba(11, 31, 58, 0.14);
  box-sizing: border-box;
  background: white;
  color: var(--ls-ink);
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: rgba(47, 128, 237, 0.4);
  box-shadow: 0 0 0 4px rgba(47, 128, 237, 0.12);
}

.messages {
  list-style: none;
  padding: 0;
}

.messages li {
  background: rgba(0, 194, 168, 0.08);
  border: 1px solid rgba(0, 194, 168, 0.22);
  border-radius: 18px;
  padding: 0.85rem 1rem;
  margin-bottom: 0.75rem;
}

pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  background: var(--ls-navy);
  color: #e6eef9;
  padding: 1rem;
  border-radius: 16px;
}

.auth-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem 1rem;
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

.auth-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 15% 20%, rgba(255, 255, 255, 0.05), transparent 24%),
    linear-gradient(135deg, rgba(11, 31, 58, 0.9), rgba(21, 49, 94, 0.78) 56%, rgba(12, 69, 103, 0.72));
  z-index: -2;
}

.auth-shell::after {
  content: "";
  position: absolute;
  inset: auto auto -10% -6%;
  width: min(52vw, 760px);
  aspect-ratio: 1;
  background: center / contain no-repeat url("./brand/seerapps_icon.svg");
  opacity: 0.2;
  filter: saturate(0.7) brightness(1.15);
  z-index: -1;
  pointer-events: none;
}

.auth-card {
  width: min(520px, calc(100vw - 2rem));
  background:
    linear-gradient(180deg, rgba(9, 26, 51, 0.94), rgba(11, 31, 58, 0.9));
  border-radius: 30px;
  padding: 1.7rem;
  box-shadow: 0 30px 70px rgba(11, 31, 58, 0.34);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: white;
  backdrop-filter: blur(18px);
}

.auth-brand {
  margin-bottom: 1.25rem;
  display: grid;
  gap: 0.65rem;
}

.auth-brand__logo {
  width: min(240px, 100%);
  height: auto;
}

.auth-brand__eyebrow {
  margin: 0;
  color: rgba(79, 181, 255, 0.92);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.auth-brand__tagline {
  margin: 0;
  color: rgba(230, 238, 249, 0.78);
}

.auth-card h1 {
  color: white;
  margin-top: 0;
}

.auth-card .muted {
  color: rgba(230, 238, 249, 0.78);
}

.auth-card label {
  color: rgba(255, 255, 255, 0.88);
  font-weight: 700;
}

.auth-card input,
.auth-card textarea,
.auth-card select {
  background: rgba(255, 255, 255, 0.96);
  border-color: rgba(255, 255, 255, 0.16);
}

.auth-card a {
  color: #9fd3ff;
}

.auth-error {
  margin-bottom: 1rem;
  padding: 0.85rem 1rem;
  border-radius: 16px;
  background: #fff1f1;
  color: #9e1c1c;
  border: 1px solid #ffd2d2;
}

.auth-actions {
  margin-top: 1rem;
}

.auth-actions button {
  width: 100%;
}

@media (max-width: 900px) {
  .portal-user {
    justify-items: start;
  }

  .auth-shell::after {
    width: min(80vw, 520px);
    left: 50%;
    transform: translateX(-50%);
    bottom: -4%;
  }
}
