/* Suger High. One stylesheet, no scripts; light and dark from the system setting. */

:root {
  --background: #ffffff;
  --foreground: #18181b;
  --muted: #f4f4f5;
  --muted-foreground: #71717a;
  --card: #ffffff;
  --border: #e4e4e7;
  --primary: #18181b;
  --primary-foreground: #fafafa;
  --ring: #18181b;
  --info: #1d4ed8;
  --info-background: #eff6ff;
  --warning: #a16207;
  --warning-background: #fefce8;
  --error: #b91c1c;
  --error-background: #fef2f2;
  --radius: 0.625rem;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #09090b;
    --foreground: #fafafa;
    --muted: #18181b;
    --muted-foreground: #a1a1aa;
    --card: #111113;
    --border: #27272a;
    --primary: #fafafa;
    --primary-foreground: #18181b;
    --ring: #fafafa;
    --info: #93c5fd;
    --info-background: #172036;
    --warning: #fde68a;
    --warning-background: #2b2410;
    --error: #fca5a5;
    --error-background: #2d1414;
    color-scheme: dark;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--background);
  color: var(--foreground);
  font: 15px/1.5 ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

main {
  flex: 1;
}

h1,
h2,
h3,
p {
  margin: 0;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 2px;
}

.container {
  width: 100%;
  max-width: 72rem;
  margin: 0 auto;
  padding: 0 16px;
}

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

.small {
  font-size: 13px;
}

/* Top bar */

.topbar {
  border-bottom: 1px solid var(--border);
  background: var(--background);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 60px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 17px;
  text-decoration: none;
}

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

.topbar-email {
  color: var(--muted-foreground);
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.topbar-account form {
  margin: 0;
}

@media (max-width: 640px) {
  .topbar-email,
  .topbar-signout {
    display: none;
  }
}

/* Buttons */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 36px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: calc(var(--radius) - 2px);
  font: inherit;
  font-weight: 500;
  font-size: 14px;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}

.button-primary {
  background: var(--primary);
  color: var(--primary-foreground);
}

.button-primary:hover {
  opacity: 0.9;
}

.button-outline {
  background: var(--background);
  border-color: var(--border);
  color: var(--foreground);
}

.button-outline:hover {
  background: var(--muted);
}

.button-sm {
  height: 32px;
  padding: 0 12px;
  font-size: 13px;
}

.button-lg {
  height: 42px;
  padding: 0 20px;
  font-size: 15px;
}

.button-block {
  display: flex;
  width: 100%;
}

/* Cards */

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.05);
  padding: 24px;
}

.card h1 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.narrow {
  width: 100%;
  max-width: 28rem;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.center {
  display: flex;
  justify-content: center;
  padding: 64px 16px;
}

.card-mark {
  align-self: flex-start;
}

.lede {
  color: var(--muted-foreground);
  font-size: 16px;
}

.avatar {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: var(--primary);
  color: var(--primary-foreground);
  font-size: 12px;
  font-weight: 600;
}

.avatar-lg {
  width: 44px;
  height: 44px;
  font-size: 15px;
}

.badge {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--muted);
  color: var(--muted-foreground);
  font-size: 12px;
  font-weight: 500;
}

/* Notices */

.alert {
  border: 1px solid currentColor;
  border-radius: var(--radius);
  padding: 12px 14px;
  font-size: 14px;
}

.alert p {
  margin-top: 2px;
  color: var(--foreground);
}

.alert-info {
  color: var(--info);
  background: var(--info-background);
}

.alert-warning {
  color: var(--warning);
  background: var(--warning-background);
}

.alert-error {
  color: var(--error);
  background: var(--error-background);
}

/* Launcher */

.hero {
  border-bottom: 1px solid var(--border);
}

.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  padding-top: 64px;
  padding-bottom: 64px;
  text-align: center;
}

.hero h1 {
  font-size: clamp(36px, 7vw, 56px);
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1.05;
}

.hero .lede {
  max-width: 36rem;
  font-size: 18px;
}

.signed-in {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  max-width: 40rem;
  padding: 16px;
  text-align: left;
}

.signed-in-text {
  flex: 1;
  min-width: 0;
}

.signed-in-text p {
  overflow: hidden;
  text-overflow: ellipsis;
}

.signed-in form {
  margin: 0;
}

.apps {
  padding: 48px 0;
}

.apps-other {
  border-top: 1px solid var(--border);
  background: var(--muted);
}

.apps h2 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.apps h2 + p {
  margin-top: 4px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr));
  gap: 16px;
  margin-top: 20px;
}

.app-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.app-card h3 {
  font-size: 16px;
  font-weight: 600;
}

.app-icon {
  border-radius: 9px;
}

.app-card-footer {
  margin-top: auto;
  padding-top: 8px;
}

.app-card-locked .app-icon {
  filter: grayscale(1);
  opacity: 0.6;
}

.footer {
  border-top: 1px solid var(--border);
  padding: 20px 0;
  color: var(--muted-foreground);
  font-size: 13px;
}
