:root {
  color-scheme: dark;
  --ink: #f5f7f4;
  --muted: #a8b1aa;
  --line: rgba(255, 255, 255, 0.12);
  --accent: #b8ff5a;
  --accent-soft: rgba(184, 255, 90, 0.11);
  --surface: rgba(255, 255, 255, 0.045);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 82% 18%, rgba(94, 166, 77, 0.17), transparent 28rem),
    linear-gradient(145deg, #0d1310 0%, #111a15 52%, #0a0f0c 100%);
}

body::before {
  position: fixed;
  inset: 0;
  pointer-events: none;
  content: "";
  opacity: 0.2;
  background-image: linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(to bottom, black, transparent 72%);
}

.shell {
  position: relative;
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 96px;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  gap: 12px;
  align-items: center;
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 720;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  color: #11180f;
  background: var(--accent);
  border-radius: 11px;
  place-items: center;
  font-size: 0.78rem;
  font-weight: 900;
}

.status {
  display: inline-flex;
  gap: 9px;
  align-items: center;
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.status-dot {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 18px var(--accent);
}

.nav-actions,
.account-menu {
  display: flex;
  gap: 14px;
  align-items: center;
}

.nav-login,
.logout-button {
  padding: 10px 15px;
  color: var(--ink);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
  font-size: 0.82rem;
  text-decoration: none;
  cursor: pointer;
}

.nav-login:hover,
.logout-button:hover {
  border-color: rgba(184, 255, 90, 0.55);
}

.account-initial {
  display: grid;
  overflow: hidden;
  width: 34px;
  height: 34px;
  color: #11180f;
  background: var(--accent);
  border-radius: 50%;
  place-items: center;
  font-size: 0.8rem;
  font-weight: 900;
}

.account-initial > * {
  grid-area: 1 / 1;
}

.account-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.account-avatar[hidden] {
  display: none;
}

.account-name {
  max-width: 170px;
  overflow: hidden;
  font-size: 0.84rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero {
  max-width: 900px;
  padding: clamp(80px, 12vw, 150px) 0 90px;
}

.eyebrow {
  margin-bottom: 26px;
  color: var(--accent);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1 {
  max-width: 840px;
  margin: 0;
  font-size: clamp(3.5rem, 9vw, 7.8rem);
  font-weight: 780;
  letter-spacing: -0.075em;
  line-height: 0.88;
}

h1 span {
  color: transparent;
  -webkit-text-stroke: 1px rgba(245, 247, 244, 0.55);
}

.intro {
  max-width: 690px;
  margin: 42px 0 0;
  color: var(--muted);
  font-size: clamp(1.05rem, 2vw, 1.28rem);
  line-height: 1.7;
}

.notice {
  display: inline-flex;
  gap: 16px;
  align-items: center;
  margin-top: 40px;
  padding: 16px 20px;
  background: var(--accent-soft);
  border: 1px solid rgba(184, 255, 90, 0.2);
  border-radius: 14px;
}

.notice-icon {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  color: #11180f;
  background: var(--accent);
  border-radius: 50%;
  place-items: center;
  font-weight: 900;
}

.notice div {
  display: grid;
  gap: 3px;
}

.notice strong {
  font-size: 0.93rem;
}

.notice div span {
  color: var(--muted);
  font-size: 0.86rem;
}

.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.login-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(240px, 0.7fr);
  gap: 40px;
  align-items: center;
  margin-bottom: 70px;
  padding: clamp(28px, 5vw, 54px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
}

.login-panel h2 {
  margin: 14px 0 12px;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
}

.login-panel p {
  max-width: 620px;
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.login-action {
  display: grid;
  gap: 12px;
  justify-items: stretch;
}

.google-login {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: center;
  padding: 15px 20px;
  color: #172014;
  background: var(--accent);
  border-radius: 12px;
  font-size: 0.94rem;
  font-weight: 760;
  text-decoration: none;
}

.google-login[aria-disabled="true"] {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.08);
  cursor: not-allowed;
}

.google-mark {
  display: grid;
  width: 24px;
  height: 24px;
  background: #fff;
  border-radius: 50%;
  place-items: center;
  color: #222;
  font-weight: 900;
}

.login-action small {
  color: #768078;
  text-align: center;
}

.login-action .legal-note {
  line-height: 1.5;
}

.legal-note a,
.footer-links a,
.legal-copy a {
  color: inherit;
  text-underline-offset: 3px;
}

.signed-in {
  gap: 6px;
  padding: 18px 20px;
  background: var(--accent-soft);
  border: 1px solid rgba(184, 255, 90, 0.2);
  border-radius: 14px;
}

.signed-in:not([hidden]) {
  display: grid;
}

.signed-in-label,
#signed-in-email,
#signed-in-type {
  color: var(--muted);
  font-size: 0.8rem;
}

.features article {
  min-height: 230px;
  padding: 34px 34px 40px 0;
}

.features article + article {
  padding-left: 34px;
  border-left: 1px solid var(--line);
}

.number {
  color: var(--accent);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.74rem;
}

h2 {
  margin: 48px 0 12px;
  font-size: 1.2rem;
  letter-spacing: -0.025em;
}

.features p {
  max-width: 300px;
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.6;
}

footer {
  display: flex;
  justify-content: space-between;
  padding: 34px 0 48px;
  color: #768078;
  font-size: 0.78rem;
}

.footer-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.legal-page .nav {
  margin-bottom: clamp(48px, 8vw, 90px);
}

.legal-copy {
  max-width: 820px;
  padding-bottom: 80px;
}

.legal-copy .eyebrow {
  margin-bottom: 16px;
}

.legal-copy h1 {
  margin-bottom: 40px;
  font-size: clamp(2.7rem, 7vw, 5.4rem);
  line-height: 0.95;
}

.legal-copy h2 {
  margin: 42px 0 12px;
  font-size: 1.3rem;
}

.legal-copy h3 {
  margin: 28px 0 10px;
  font-size: 1rem;
}

.legal-copy p,
.legal-copy li,
.legal-copy address {
  color: var(--muted);
  font-size: 0.96rem;
  font-style: normal;
  line-height: 1.7;
}

.legal-copy ul {
  padding-left: 22px;
}

.legal-copy strong {
  color: var(--ink);
}

.legal-meta {
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.admin-header {
  max-width: 820px;
  padding: clamp(64px, 10vw, 110px) 0 55px;
}

.admin-header h1 {
  font-size: clamp(3rem, 8vw, 6.6rem);
}

.admin-header p {
  max-width: 690px;
  margin: 30px 0 0;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.65;
}

.admin-card {
  margin-bottom: 70px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
}

.admin-card-heading {
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
  padding: 28px 30px;
  border-bottom: 1px solid var(--line);
}

.admin-card-heading h2 {
  margin: 8px 0 0;
}

.admin-message {
  color: var(--muted);
  font-size: 0.82rem;
}

.user-table-wrap {
  overflow-x: auto;
}

.user-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.user-table th,
.user-table td {
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

.user-table th {
  color: #768078;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.user-table td {
  color: var(--muted);
  font-size: 0.86rem;
}

.user-table tbody tr:last-child td {
  border-bottom: 0;
}

.user-table td:first-child strong,
.user-table td:first-child span {
  display: block;
}

.user-table td:first-child strong {
  color: var(--ink);
  margin-bottom: 4px;
}

.role-badge,
.role-select {
  display: inline-block;
  min-width: 100px;
  padding: 8px 10px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
  border-radius: 9px;
  font: inherit;
}

.role-owner {
  color: var(--accent);
  background: var(--accent-soft);
  border-color: rgba(184, 255, 90, 0.22);
}

@media (max-width: 720px) {
  .shell {
    width: min(100% - 28px, 1180px);
  }

  .nav {
    min-height: 78px;
  }

  .status {
    font-size: 0;
  }

  .account-name {
    display: none;
  }

  footer {
    gap: 18px;
    flex-direction: column;
  }

  .footer-links {
    gap: 12px 18px;
    justify-content: flex-start;
  }

  .nav-actions {
    gap: 8px;
  }

  .nav-login,
  .logout-button {
    padding: 9px 11px;
  }

  .hero {
    padding: 72px 0 68px;
  }

  h1 {
    font-size: clamp(3.2rem, 17vw, 5.4rem);
  }

  .notice {
    align-items: flex-start;
  }

  .features {
    grid-template-columns: 1fr;
  }

  .login-panel {
    grid-template-columns: 1fr;
    gap: 28px;
    margin-bottom: 48px;
  }

  .admin-card-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .user-table th,
  .user-table td {
    padding: 15px 16px;
    white-space: nowrap;
  }

  .features article {
    min-height: 0;
    padding: 30px 0;
  }

  .features article + article {
    padding-left: 0;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  h2 {
    margin-top: 24px;
  }
}
