/* id.kamoo.ai: the sign-in pages, in the colours and type of kamoo.ai (app/app/globals.css). */
@font-face {
  font-family: "Inter";
  src: url("inter-latin.5a2624dc55f2.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}
:root {
  color-scheme: light dark;
  --background: #faf8f5;
  --foreground: #1f1027;
  --card: #fff;
  --muted: #6e6875;
  --primary: #4b255f;
  --primary-foreground: #fff;
  --border: #e4dfe8;
  --field: #8b8592;
  --ring: #8e5fa8;
  --destructive: #c4321f;
  --success: #2f6f5f;
  --accent: #f1ecf6;
  --radius: 0.625rem;
}
@media (prefers-color-scheme: dark) {
  :root {
    --background: hsl(281 22% 6%);
    --foreground: hsl(276 20% 96%);
    --card: hsl(281 18% 10%);
    --muted: hsl(276 6% 60%);
    --primary: hsl(279 45% 42%);
    --border: hsl(281 14% 20%);
    --field: #7a6f80;
    --destructive: #f2836f;
    --success: #8fcbb7;
    --accent: #261d2b;
  }
}
* { box-sizing: border-box; }
html { font-family: Inter, system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
body { margin: 0; background: var(--background); color: var(--foreground); font-size: 15px; line-height: 1.5; }
a { color: inherit; text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--foreground); outline-offset: 3px; }
input { accent-color: var(--primary); }

/* The page: what Kamoo promises in a narrow column on the left, the form in the middle of the
   rest (Fly.io's sign-in, mirrored); on a phone only the form. */
.split { position: relative; min-height: 100dvh; display: grid; background: var(--card); }
@media (min-width: 64rem) { .split { grid-template-columns: minmax(0, 36rem) 1fr; } }
.side { display: flex; flex-direction: column; gap: 2rem; padding: 1.5rem 1rem; background: var(--card); }
@media (min-width: 40rem) { .side { padding: 2rem; } }
.brand { align-self: flex-start; display: flex; }
/* From lg up the logo (and the footer) stay put in the promise column while the page scrolls. */
@media (min-width: 64rem) { .brand { position: fixed; top: 2rem; left: 2rem; z-index: 1; } }
@media (prefers-color-scheme: dark) { .brand img { filter: invert(1) hue-rotate(180deg); } }
.signed-in { align-self: flex-start; }
.signed-in .text-button { display: inline-flex; align-items: center; gap: 0.375rem; text-decoration: none; }
.signed-in svg { width: 1rem; height: 1rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.content { flex: 1; width: 100%; max-width: 24rem; margin: 0 auto; display: flex; flex-direction: column; justify-content: center; gap: 1rem; }
.foot { margin: 0; font-size: 0.75rem; color: var(--muted); }
@media (min-width: 64rem) { .foot { position: fixed; bottom: 2rem; left: 2rem; z-index: 1; } }

.promise { display: none; }
@media (min-width: 64rem) {
  /* One window high and staying in view on a long page (Je account); its gradient ends in the
     white of the page, so below it the column simply goes on white. */
  .promise { order: -1; position: sticky; top: 0; align-self: start; height: 100dvh; display: grid; place-items: center; padding: 6rem 3rem 3rem; background: linear-gradient(to bottom in oklab, var(--accent), var(--card)); }
  .side { border-inline-start: 1px solid var(--border); }
}
.promise > div { max-width: 28rem; margin-inline: auto; display: grid; gap: 1.25rem; }
.drawing { width: 18rem; height: auto; margin-inline-start: -0.75rem; mix-blend-mode: multiply; }
@media (prefers-color-scheme: dark) { .drawing { mix-blend-mode: normal; background: #fff; border-radius: 1rem; padding: 0.75rem; } }
.claim { font-size: 1.5rem; font-weight: 600; letter-spacing: -0.01em; }
.promise ul { margin: 0.5rem 0 0; padding: 0; list-style: none; display: grid; gap: 1.25rem; }
.promise li { display: flex; gap: 0.75rem; }
.promise svg { flex-shrink: 0; width: 1.25rem; height: 1.25rem; margin-top: 0.125rem; fill: none; stroke: var(--primary); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
@media (prefers-color-scheme: dark) { .promise svg { stroke: var(--ring); } }
.promise li p:not(.title) { color: var(--muted); }
.title { font-weight: 500; }

h1 { margin: 0; font-size: 1.875rem; font-weight: 600; letter-spacing: -0.01em; }
h2 { margin: 0; font-size: 1.125rem; font-weight: 600; }
p { margin: 0; }
.muted { color: var(--muted); }
hr { border: 0; border-top: 1px solid var(--border); margin: 0.25rem 0; width: 100%; }

.form, .button-group { display: grid; gap: 1rem; }
.actions { display: grid; gap: 0.5rem; }
.field { display: grid; gap: 0.375rem; }
.field label { font-weight: 500; font-size: 0.875rem; }
:is(.field, .inline-field) input:not([type="checkbox"]):not([type="radio"]), .field textarea {
  width: 100%; height: 2.25rem; padding: 0 0.75rem; font: inherit; color: inherit;
  background: var(--card); border: 1px solid var(--field); border-radius: 1.125rem;
}
.field textarea { border-radius: calc(var(--radius) * 1.8); }
.field textarea { height: auto; padding: 0.5rem 0.75rem; }
:is(.field, .inline-field) input:focus { outline: 2px solid var(--ring); outline-offset: 1px; }
:is(.field, .inline-field) input[aria-invalid="true"] { border-color: var(--destructive); }
.field.check { grid-template-columns: auto 1fr; align-items: center; gap: 0.5rem; }
.field.check label { font-weight: 400; }
.error { color: var(--destructive); font-size: 0.8125rem; }
.help { color: var(--muted); font-size: 0.8125rem; }
.help ul { margin: 0; padding-left: 1.1rem; }

.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.375rem;
  height: 2.25rem; padding: 0 1rem; border-radius: 999px; font: inherit; font-weight: 500; white-space: nowrap;
  text-decoration: none; cursor: pointer; border: 1px solid transparent;
}
.button.primary { background: var(--primary); color: var(--primary-foreground); }
.button.primary:hover { filter: brightness(1.1); }
.button.outline { background: var(--card); border-color: var(--border); color: var(--foreground); box-shadow: 0 1px 2px rgb(31 16 39 / 0.05); }
.button.ghost { background: transparent; color: var(--foreground); }
.button.ghost:hover { background: color-mix(in oklch, var(--card), var(--foreground) 5%); }
.button.sm { height: 2rem; padding: 0 0.75rem; font-size: 0.875rem; flex-shrink: 0; }
.button.danger-outline { background: var(--card); border-color: color-mix(in oklch, var(--destructive) 35%, var(--border)); color: var(--destructive); }
.button.danger-outline:hover { background: color-mix(in oklch, var(--destructive) 8%, var(--card)); }
.button.outline:hover { background: color-mix(in oklch, var(--card), var(--foreground) 5%); }

.alert { margin: 0; padding: 0.75rem 1rem; border-radius: 0.75rem; }
.alert { background: color-mix(in oklch, var(--destructive) 12%, transparent); color: var(--destructive); }

/* Toasts (allauth/layouts/base.html, id.js): bottom right, newest at the bottom, as in the app. */
.toaster { position: fixed; z-index: 50; right: 1rem; bottom: 1rem; width: min(22rem, calc(100vw - 2rem)); margin: 0; padding: 0; list-style: none; display: grid; gap: 0.5rem; }
.toast { display: flex; align-items: flex-start; gap: 0.75rem; padding: 1rem; background: var(--card); border: 1px solid var(--border); border-radius: 1rem; box-shadow: 0 10px 15px -3px rgb(31 16 39 / 0.1), 0 4px 6px -4px rgb(31 16 39 / 0.1); font-size: 0.875rem; font-weight: 500; animation: toast-in 300ms cubic-bezier(0.22, 1, 0.36, 1); transition: opacity 200ms, translate 200ms; }
.toast[data-leaving] { opacity: 0; translate: 0 0.5rem; }
.toast > svg { flex-shrink: 0; width: 1rem; height: 1rem; margin-top: 0.125rem; fill: none; stroke: var(--success); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.toast:is([data-type="error"], [data-type="warning"]) > svg { stroke: var(--destructive); }
.toast > p { flex: 1; min-width: 0; overflow-wrap: break-word; }
.toast-close { display: grid; place-items: center; width: 1.5rem; height: 1.5rem; margin: -0.125rem -0.25rem 0 0; padding: 0; border: 0; border-radius: 0.5rem; background: transparent; color: var(--muted); cursor: pointer; }
.toast-close:hover { color: var(--foreground); background: color-mix(in oklch, var(--card), var(--foreground) 6%); }
.toast-close svg { width: 0.875rem; height: 0.875rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
@keyframes toast-in { from { opacity: 0; translate: 0 100%; } }
@media (prefers-reduced-motion: reduce) { .toast { animation: none; transition: none; } }

/* Two-factor: the QR code for the authenticator app, and recovery codes to copy. */
.qr { display: block; width: 11rem; height: 11rem; margin: 0 auto; padding: 0.5rem; background: #fff; border-radius: 0.75rem; }
#recovery_codes, #authenticator_secret { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
#recovery_codes { letter-spacing: 0.05em; }
#authenticator_secret { font-size: 0.8125rem; } /* 32 characters fit on a phone */
#recovery_codes { resize: none; }

/* The code from the app as six boxes in one row (id.js), like the app's InputOTP. */
.otp { position: relative; display: flex; width: fit-content; }
.otp-slot { display: grid; place-items: center; width: 2.75rem; height: 2.75rem; border: 1px solid var(--field); border-inline-start-width: 0; background: var(--card); font-size: 1.125rem; font-weight: 500; font-variant-numeric: tabular-nums; }
.otp-slot:first-child { border-inline-start-width: 1px; border-start-start-radius: 1.125rem; border-end-start-radius: 1.125rem; }
.otp-slot:nth-last-child(2) { border-start-end-radius: 1.125rem; border-end-end-radius: 1.125rem; }
.otp-slot[data-active] { position: relative; z-index: 1; outline: 2px solid var(--ring); outline-offset: -1px; }
.otp-slot[data-active]:empty::after { content: ""; width: 1px; height: 1.25rem; background: var(--foreground); animation: caret 1s step-end infinite; }
.otp:has([aria-invalid="true"]) .otp-slot { border-color: var(--destructive); }
/* The input itself: on top, invisible, 16px so a phone does not zoom in. */
.field .otp input[data-otp] { position: absolute; inset: 0; z-index: 2; width: 100%; height: 100%; padding: 0; border: 0; background: transparent; color: transparent; caret-color: transparent; font-size: 16px; outline: none; }
.otp input::selection { background: transparent; }
@keyframes caret { 50% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .otp-slot[data-active]:empty::after { animation: none; } }
.text-button { justify-self: start; padding: 0; border: 0; background: none; font: inherit; font-size: 0.875rem; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.text-button:hover { color: var(--foreground); }

/* Your account: one row per setting, with its action on the right. */
.rows { margin: 0; padding: 0; list-style: none; border: 1px solid var(--border); border-radius: calc(var(--radius) * 1.4); }
.rows :is(li, .row) { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.75rem 1rem; }
.rows :is(li, .row) + :is(li, .row) { border-top: 1px solid var(--border); }
.rows span { display: grid; min-width: 0; }
.rows strong { font-weight: 500; font-size: 0.875rem; }
.rows small { color: var(--muted); font-size: 0.8125rem; overflow-wrap: anywhere; }
.back { justify-self: start; font-size: 0.875rem; color: var(--muted); text-decoration: none; }
.back:hover { color: var(--foreground); }
a.danger { color: var(--destructive); }
.button.danger { background: var(--destructive); border-color: transparent; color: #fff; }
.button.danger:disabled { opacity: 0.5; cursor: not-allowed; }

/* "Typ VERWIJDEREN": the word as a chip you can copy, and the keys on the buttons (id.js). */
.chip { display: inline-flex; align-items: center; gap: 0.25rem; margin-inline: 0.125rem; padding: 0 0.375rem; border-radius: 0.5rem; background: color-mix(in oklch, var(--card), var(--foreground) 7%); font-weight: 600; }
.chip-copy { display: grid; place-items: center; width: 1.25rem; height: 1.25rem; padding: 0; border: 0; border-radius: 0.375rem; background: transparent; color: var(--muted); cursor: pointer; }
.chip-copy:hover { color: var(--foreground); }
.chip-copy svg { width: 0.75rem; height: 0.75rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.inline-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.keys { margin-inline-start: 0.375rem; padding: 0 0.3rem; border-radius: 0.375rem; background: color-mix(in oklch, currentColor 15%, transparent); font: inherit; font-size: 0.75rem; }
@media (max-width: 40rem) { .keys { display: none; } }

/* The consent page: which organisation an AI app works for. */
fieldset.field { border: 0; margin: 0; padding: 0; }
fieldset.field legend { font-weight: 500; font-size: 0.875rem; margin-bottom: 0.375rem; }
.choice { display: flex; align-items: center; gap: 0.5rem; padding: 0.625rem 0.75rem; border: 1px solid var(--border); border-radius: 0.75rem; cursor: pointer; }
.choice + .choice { margin-top: 0.375rem; }
.choice:has(input:checked) { border-color: var(--ring); }

/* Je account: wider than the sign-in forms, in sections with a heading. */
.content.wide { max-width: 36rem; justify-content: flex-start; gap: 1.5rem; padding-block: 2rem; }
@media (min-width: 64rem) { .content.wide { padding-block: 4rem; } }
.section { display: grid; gap: 0.75rem; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.section h2 { font-size: 1rem; }
.inline-field { display: grid; gap: 0.375rem; width: 100%; }
.inline-field label { font-weight: 500; font-size: 0.875rem; }
.inline-field > div { display: flex; gap: 0.5rem; }
.badge { display: inline-flex; align-items: center; height: 1.25rem; margin-inline-start: 0.375rem; padding: 0 0.5rem; border: 1px solid var(--border); border-radius: 999px; font-size: 0.75rem; font-style: normal; font-weight: 500; color: var(--muted); vertical-align: 1px; }

/* "of" between the form and the passkey button on the sign-in page. */
/* Microsoft and Google (socialaccount/snippets/buttons.html): full width, like the passkey. */
.providers { display: grid; gap: 0.5rem; }
.providers .button { width: 100%; }
.provider-logo { flex-shrink: 0; width: 1rem; height: 1rem; }
.rows .providers { display: flex; flex-wrap: wrap; justify-content: flex-end; }
.rows .providers .button { width: auto; height: 2rem; padding: 0 0.75rem; font-size: 0.875rem; }
.divider { display: flex; align-items: center; gap: 0.75rem; color: var(--muted); font-size: 0.8125rem; }
.divider::before, .divider::after { content: ""; flex: 1; border-top: 1px solid var(--border); }
