@font-face {
  font-family: Plex;
  src: url("/static/fonts/ibm-plex-sans-var-roman.woff2") format("woff2");
  font-weight: 100 700;
  font-display: swap;
}
@font-face {
  font-family: PlexMono;
  src: url("/static/fonts/ibm-plex-mono-regular.woff2") format("woff2");
  font-display: swap;
}
:root {
  color-scheme: dark;
  --ink: #101116;
  --panel: #191a22;
  --paper: #eeeaf4;
  --muted: #a9a5b5;
  --accent: #c0afe9;
  --gold: #d4b77e;
  --line: #34323f;
  --green: #92cfb0;
  --red: #f1a6ae;
}
* {
  box-sizing: border-box;
  letter-spacing: 0;
}
html {
  min-width: 300px;
  background: var(--ink);
}
body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font:
    16px/1.55 Plex,
    "Segoe UI",
    sans-serif;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}
button,
input,
select {
  font: inherit;
  color: inherit;
}
button,
a,
input,
select {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
button:disabled {
  opacity: 0.6;
  cursor: wait;
}
a {
  color: inherit;
  text-decoration: none;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-size: 32px;
  line-height: 1.2;
  font-weight: 500;
}
h2 {
  font-size: 24px;
  line-height: 1.3;
  font-weight: 500;
}
h3 {
  font-size: 20px;
  font-weight: 500;
}
img {
  display: block;
}
svg {
  width: 19px;
  height: 19px;
  flex-shrink: 0;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}
[hidden] {
  display: none !important;
}
.container {
  width: min(1180px, calc(100% - 64px));
  margin-inline: auto;
}
.site-header {
  border-bottom: 1px solid var(--line);
}
.header-inner {
  min-height: 80px;
  display: flex;
  align-items: center;
  gap: 36px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 17px;
  font-weight: 600;
  white-space: nowrap;
}
.brand img {
  object-fit: contain;
}
nav {
  display: flex;
  align-self: stretch;
  gap: 24px;
}
.nav-button {
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 0 2px;
  color: var(--muted);
  font-size: 15px;
}
.nav-button.active {
  border-color: var(--accent);
  color: var(--paper);
}
.identity,
.back-home {
  margin-left: auto;
  display: flex;
  gap: 12px;
  align-items: center;
  min-width: 0;
  font-size: 14px;
}
.identity span {
  max-width: 230px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.back-home {
  color: var(--muted);
}
.icon-button {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
}
.icon-button:hover {
  border-color: var(--accent);
  color: var(--paper);
}
main {
  flex: 1;
  padding-block: 44px 64px;
}
.page-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}
.eyebrow {
  font:
    11px/1.6 PlexMono,
    monospace;
  color: var(--muted);
  margin-bottom: 10px;
}
.user-id {
  font:
    12px/1.5 PlexMono,
    monospace;
  color: var(--muted);
}
.service-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.service-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 22px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-height: 240px;
}
.service-heading {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 16px;
  font-weight: 500;
}
.service-heading svg {
  color: var(--accent);
}
.service-card[data-service="imagen"] .service-heading svg {
  color: var(--gold);
}
.service-card[data-service="instances"] .service-heading svg {
  color: var(--green);
}
.subscription {
  display: flex;
  flex-direction: column;
  align-items: start;
  gap: 5px;
  min-width: 0;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.subscription:first-child {
  padding-top: 0;
  border-top: 0;
}
.subscription-title {
  font-size: 20px;
  font-weight: 500;
  overflow-wrap: anywhere;
  line-height: 1.35;
}
.subscription small {
  color: var(--muted);
  font-size: 13px;
}
.subscription-details {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.badge {
  font:
    11px/1.6 PlexMono,
    monospace;
  color: var(--green);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.badge:before {
  content: "";
  width: 5px;
  height: 5px;
  background: currentColor;
  border-radius: 50%;
}
.badge.expired,
.badge.suspended,
.badge.attention {
  color: var(--gold);
}
.muted {
  color: var(--muted);
  font-size: 14px;
}
.empty {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 44px;
  padding: 10px 17px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: transparent;
  line-height: 1.35;
  font-size: 14px;
  text-align: center;
  overflow-wrap: anywhere;
}
.button:hover {
  border-color: var(--muted);
}
.button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #19151f;
  font-weight: 500;
}
.button.primary:hover {
  background: #d2c1f2;
  border-color: #d2c1f2;
}
.service-action {
  margin-top: auto;
  justify-content: space-between;
}
.plans-section {
  margin-top: 44px;
}
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}
.service-tabs {
  display: flex;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 24px;
}
.service-tabs button {
  display: flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  color: var(--muted);
  padding: 12px 0;
  font-size: 14px;
  min-height: 48px;
}
.service-tabs button[aria-selected="true"] {
  border-color: var(--accent);
  color: var(--paper);
}
.plans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.plan {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  align-items: start;
  min-width: 0;
  gap: 16px;
  position: relative;
}
.plan.chosen {
  border-color: var(--accent);
}
.plan h3 {
  overflow-wrap: anywhere;
}
.plan-price {
  font-size: 27px;
  font-weight: 500;
  line-height: 1.3;
}
.plan-period {
  display: block;
  font-size: 13px;
  color: var(--muted);
  font-weight: 400;
  margin-top: 3px;
}
.plan ul {
  list-style: none;
  padding: 0;
  margin: 0 0 6px;
  display: flex;
  flex-direction: column;
  gap: 9px;
  font-size: 13px;
  color: var(--muted);
  flex: 1;
}
.plan li {
  display: flex;
  gap: 8px;
  align-items: baseline;
  overflow-wrap: anywhere;
}
.plan li:before {
  content: "+";
  color: var(--green);
  font-family: PlexMono, monospace;
}
.plan .button {
  width: 100%;
  margin-top: auto;
}
.plan .current-label {
  font-size: 11px;
  color: var(--green);
}
.loading {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: center;
  min-height: 300px;
  color: var(--muted);
}
.loading svg {
  animation: spin 1.2s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.login {
  max-width: 480px;
  margin: 52px auto 70px;
  text-align: center;
}
.login-mark {
  margin: 0 auto 26px;
}
.login h1 {
  font-size: 36px;
}
.login .eyebrow {
  color: var(--gold);
}
.login-copy {
  color: var(--muted);
  margin: 20px 0 28px;
  font-size: 16px;
  line-height: 1.7;
}
.login .button {
  min-width: 245px;
}
.login-confirmation {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.login-code {
  font:
    32px/1.4 PlexMono,
    monospace;
  color: var(--accent);
}
.notice {
  padding: 12px 14px;
  border-left: 2px solid var(--gold);
  background: #d4b77e0a;
  color: var(--gold);
  font-size: 14px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}
.notice.error {
  border-color: var(--red);
  color: var(--red);
  background: #f1a6ae09;
}
.notice.success {
  border-color: var(--green);
  color: var(--green);
  background: #92cfb00a;
}
main > .notice {
  margin-top: 24px;
}
.footer {
  display: flex;
  gap: 16px;
  justify-content: space-between;
  align-items: center;
  padding-block: 22px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--muted);
}
.footer a {
  display: flex;
  align-items: center;
  gap: 6px;
}
.footer svg {
  width: 14px;
  height: 14px;
}
.skip {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 10;
  transform: translateY(-200%);
  background: var(--accent);
  color: var(--ink);
  padding: 8px 16px;
}
.skip:focus {
  transform: none;
}
dialog {
  background: var(--panel);
  color: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 26px;
  width: min(480px, calc(100% - 32px));
  max-height: calc(100dvh - 32px);
  overflow: auto;
}
dialog::backdrop {
  background: #060709cc;
}
.dialog-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 14px;
}
.dialog-heading .eyebrow {
  margin: 0;
}
dialog h2 {
  font-size: 25px;
  overflow-wrap: anywhere;
  line-height: 1.35;
}
.checkout-amount {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 22px 0;
}
.checkout-amount span {
  color: var(--muted);
  font-size: 14px;
}
.checkout-amount strong {
  font:
    28px/1.4 PlexMono,
    monospace;
  white-space: nowrap;
  font-weight: 400;
}
#checkout-state {
  margin-bottom: 24px;
}
#payment-instructions label,
#resource-form label {
  font-size: 13px;
  color: var(--muted);
  display: block;
  margin-bottom: 8px;
}
.copy-field {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  background: #101116;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 8px 8px 12px;
}
.copy-field code {
  font:
    12px/1.7 PlexMono,
    monospace;
  overflow-wrap: anywhere;
  flex: 1;
  min-width: 0;
}
.copy-field .icon-button {
  border: 0;
}
.payment-note {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
  margin: 12px 0 20px;
}
#boosty-link,
.check-button {
  width: 100%;
}
.check-button {
  margin-top: 12px;
}
.dialog-status {
  padding-top: 22px;
}
#checkout-error {
  margin-top: 18px;
}
#resource-form {
  padding-top: 24px;
}
input,
select {
  background: var(--ink);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px 12px;
  min-height: 44px;
  width: 100%;
  margin-bottom: 20px;
  min-width: 0;
}
#resource-form .button {
  width: 100%;
}
.payment-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) 130px 130px 38px;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  padding: 20px 0;
}
.payment-row .title {
  font-weight: 500;
  overflow-wrap: anywhere;
}
.payment-row .meta {
  font-size: 12px;
  color: var(--muted);
  margin-top: 3px;
}
.payment-row time {
  font-size: 13px;
  color: var(--muted);
}
.payment-row .sum {
  font:
    14px PlexMono,
    monospace;
  text-align: right;
  white-space: nowrap;
}
.payment-status {
  font-size: 12px;
  color: var(--gold);
}
.payment-status.fulfilled {
  color: var(--green);
}
#more-payments {
  margin-top: 24px;
}
@media (max-width: 950px) {
  .service-card {
    padding: 18px;
  }
  .header-inner {
    gap: 24px;
  }
  .service-grid {
    gap: 12px;
  }
  .plans-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .identity span {
    max-width: 140px;
  }
  .payment-row {
    grid-template-columns: 100px minmax(0, 1fr) 110px 110px 38px;
    gap: 12px;
  }
}
@media (max-width: 680px) {
  .container {
    width: calc(100% - 32px);
  }
  .header-inner {
    min-height: 68px;
    gap: 12px;
    flex-wrap: wrap;
    padding-block: 12px;
  }
  .brand {
    font-size: 15px;
    gap: 8px;
  }
  .brand img {
    width: 25px;
    height: 25px;
  }
  nav {
    order: 3;
    width: 100%;
    min-height: 40px;
    gap: 24px;
  }
  .nav-button {
    padding-block: 8px;
  }
  .identity span {
    max-width: 135px;
  }
  .identity {
    gap: 8px;
  }
  .back-home {
    font-size: 13px;
  }
  .page-heading {
    align-items: start;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
  }
  h1 {
    font-size: 28px;
  }
  h2 {
    font-size: 23px;
  }
  main {
    padding-top: 28px;
    padding-bottom: 40px;
  }
  .service-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .service-card {
    padding: 20px;
    min-height: 0;
    gap: 18px;
  }
  .service-heading {
    font-size: 16px;
  }
  .subscription-title {
    font-size: 21px;
  }
  .service-action {
    margin-top: 4px;
  }
  .plans-section {
    margin-top: 32px;
  }
  .service-tabs {
    gap: 0;
    justify-content: space-between;
  }
  .service-tabs button {
    font-size: 12px;
    gap: 5px;
    white-space: normal;
  }
  .service-tabs svg {
    width: 15px;
    height: 15px;
  }
  .plans-grid {
    gap: 12px;
  }
  .plan {
    padding: 16px;
    gap: 14px;
  }
  .plan h3 {
    font-size: 18px;
  }
  .plan-price {
    font-size: 24px;
  }
  .plan ul {
    font-size: 12px;
  }
  .plan .button {
    padding-inline: 8px;
    font-size: 13px;
  }
  .login {
    margin: 28px auto 44px;
  }
  .login h1 {
    font-size: 32px;
  }
  .login-copy {
    font-size: 15px;
  }
  .payment-row {
    grid-template-columns: minmax(0, 1fr) auto 38px;
    gap: 8px 12px;
    padding-block: 18px;
  }
  .payment-row time {
    grid-column: 1;
    grid-row: 2;
  }
  .payment-row .title-block {
    grid-row: 1;
    grid-column: 1;
  }
  .payment-row .sum {
    grid-row: 1;
    grid-column: 2;
  }
  .payment-row .payment-status {
    grid-row: 2;
    grid-column: 2;
  }
  .payment-row .icon-button {
    grid-row: 1 / span 2;
    grid-column: 3;
  }
  dialog {
    padding: 22px;
  }
  .checkout-amount strong {
    font-size: 26px;
  }
  .footer {
    font-size: 11px;
  }
}
@media (max-width: 360px) {
  .plans-grid {
    grid-template-columns: 1fr;
  }
  .identity span {
    max-width: 100px;
  }
  .service-tabs button {
    font-size: 11px;
    gap: 4px;
  }
  .service-tabs svg {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    scroll-behavior: auto !important;
  }
}
