/* The sign-in page's stylesheet.

   1. Fonts
   2. Tokens: every colour, light then dark; then type, spacing and radii
   3. Page base
   4. Shared pieces: field, button, link
   5. The sign-in page (the look called "Seam", with the filled seal): its phone-key view and
      the password view ("Ruled rows")
   6. The sign-in page's other steps: six-digit code, first time, set-up, and set-up with a
      phone key ("Serif note")
   7. Motion and hover of the shared pieces and the sign-in page

   Where the colours, type sizes, spacing, radii, fonts and images came from is written down
   in the project's design notes and not here: this file is handed to any browser that
   asks for it, before anyone has signed in. Nothing is loaded from another address: every
   file named in this stylesheet is this site's own. Dark follows the device's own setting
   and nothing else. */


/* ---- 1. Fonts ------------------------------------------------------------------------- */

@font-face { font-family: "Fraunces"; font-style: normal; font-weight: 300 700; font-display: swap; src: url(/site/templates/fonts/fraunces-latin.woff2) format("woff2"); }
@font-face { font-family: "Fraunces"; font-style: italic; font-weight: 300 600; font-display: swap; src: url(/site/templates/fonts/fraunces-italic-latin.woff2) format("woff2"); }
@font-face { font-family: "Schibsted Grotesk"; font-style: normal; font-weight: 400 900; font-display: swap; src: url(/site/templates/fonts/schibsted-latin.woff2) format("woff2"); }
@font-face { font-family: "Lexend"; font-style: normal; font-weight: 300 700; font-display: swap; src: url(/site/templates/fonts/lexend-latin.woff2) format("woff2"); }

/* The serif's italic "&" is a flourished "Et" that reads as a stray letter. This lends
   italic text the same serif's upright "&": the upright file, declared as the italic face,
   for that one character only. To have the flourished one back, delete this face. */
@font-face { font-family: "Fraunces Amp"; font-style: italic; font-weight: 300 700; font-display: swap; src: url(/site/templates/fonts/fraunces-latin.woff2) format("woff2"); unicode-range: U+26; }


/* ---- 2. Tokens ------------------------------------------------------------------------ */

:root {
  color-scheme: light;

  /* the brand's own */
  --color-bg: #f5ebe5;
  --color-bg-alt: #efe2db;
  --color-bg-mid: #faf6f3;
  --color-bg-elevated: #f8ede6;
  --color-surface: #faf6f3;
  --color-border: rgba(58, 40, 40, 0.1);
  --color-border-hover: rgba(58, 40, 40, 0.2);
  /* a field's edge. 0.6, where the mock-up had 0.5: at 0.5 the drawn edge measured 2.6 to 1
     against the page and 2.9 to 1 against the field's paper; an edge needs 3 to 1 */
  --color-field-line: rgba(58, 40, 40, 0.6);
  --color-heading: #3a2828;
  --color-body: #5a4a44;
  --color-muted: #685850;
  --color-eyebrow: #7d5252;
  --color-accent: #4daab8;
  --color-rose: #d4a0a0;
  --color-rose-deep: #a97672;
  --color-link: #29707b;
  --color-cta-bg: #996a67;
  --color-cta-bg-hover: #8a5f5c;
  --color-cta-text: #ffffff;
  /* the focus ring. #317d88, where the brand has #38848f: drawn round a wide pill, over the
     pill's own shadow, the brand's ring measured 2.78 to 2.98 to 1 against what it lies on; a
     ring needs 3. Seven levels deeper holds 3 on every ring it draws in light, wherever the ring is
     not under a veil */
  --color-focus-ring: #317d88;
  --color-error-text: #a5281b;
  --color-error-bg: rgba(192, 57, 43, 0.08);
  --color-accent-glow: #cf7089;
  --gradient-accent: linear-gradient(90deg, #4daab8, #d4a0a0);
  --shadow-xl: 0 20px 40px rgba(58, 40, 40, 0.1);

  /* the sign-in look: the brand's rose, glow rose and teal at set strengths */
  --frame: rgba(58, 40, 40, 0.32);
  --seal-a: #b8807c;
  --seal-b: #8a5854;
  /* the ink for words set over the aurora: deep enough to hold 3 to 1 on its lightest patch */
  --ink-a: #8a5854;
  --ink-b: #9c6763;
  --ink-c: #2f6c75;
  /* the ink of the link under the form. It sits in the form side's soft light and under the
     grain, where the brand's link teal (#29707b) measured 4.27 to 4.45 to 1 on a phone and
     its text-safe teal (#2f6c75) 4.47 at 320 wide. This is that teal four levels deeper:
     4.74 at its worst place. */
  --ink-link: #2c6870;
  /* the fill of the sign-in page's button. The grain lies over that button and takes the
     brand's pair (white on --color-cta-bg, 4.55 to 1) to 4.39 as drawn; four levels deeper
     measures 4.64. Every other button keeps the brand's own --color-cta-bg. */
  --door-cta-bg: #956663;
  --au-1: rgba(212, 160, 160, 0.85);
  --au-2: rgba(207, 112, 137, 0.5);
  --au-3: rgba(77, 170, 184, 0.5);
  --au-4: rgba(250, 246, 243, 0.9);
  --form-glow: rgba(207, 112, 137, 0.13);
  --split-shade: rgba(58, 40, 40, 0.1);
  --field-inset: rgba(0, 0, 0, 0.05);
  --btn-shadow: rgba(0, 0, 0, 0.14);
  --btn-shadow-hover: rgba(0, 0, 0, 0.16);
  /* the tile under the square code: white in both themes, or a phone cannot scan it */
  --qr-tile: #ffffff;

  --font-display: "Schibsted Grotesk", Arial, sans-serif;
  --font-serif: "Fraunces", Georgia, serif;
  --font-body: "Lexend", Arial, sans-serif;

  --text-xs: clamp(0.7rem, 0.65rem + 0.25vw, 0.8rem);
  --text-sm: clamp(0.8rem, 0.75rem + 0.3vw, 0.9rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.1rem);
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --radius-md: 0.75rem;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;

    --color-bg: #073542;
    --color-bg-alt: #05242e;
    --color-bg-mid: #0c3a40;
    --color-bg-elevated: #0a4555;
    --color-surface: #0a4555;
    --color-border: rgba(255, 255, 255, 0.08);
    --color-border-hover: rgba(255, 255, 255, 0.15);
    --color-field-line: rgba(255, 255, 255, 0.5);
    --color-heading: #ffffff;
    --color-body: #9cbcc6;
    --color-muted: #8bb0bb;
    --color-eyebrow: #d4a0a0;
    --color-accent: #0fa4b6;
    --color-rose-deep: #e8b9b6;
    --color-link: #11bdd2;
    --color-cta-bg: #0fa4b6;
    --color-cta-bg-hover: #0d8e9e;
    --color-cta-text: #021a22;
    --color-focus-ring: #0fa4b6;
    --color-error-text: #ffb1a6;
    --color-error-bg: rgba(231, 76, 60, 0.16);
    --color-accent-glow: #0fa4b6;
    --gradient-accent: linear-gradient(90deg, #0fa4b6, #d4a0a0);
    --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.3);

    --frame: rgba(255, 255, 255, 0.3);
    --seal-a: #f0c9c6;
    --seal-b: #d4a0a0;
    --ink-a: #f0c9c6;
    --ink-b: #e8b9b6;
    --ink-c: #11bdd2;
    --ink-link: #11bdd2;
    --door-cta-bg: #0fa4b6; /* dark: the brand's own button colour, unchanged (5.73 as drawn) */
    --au-1: rgba(15, 164, 182, 0.75);
    --au-2: rgba(17, 189, 210, 0.38);
    --au-3: rgba(232, 185, 182, 0.3);
    --au-4: rgba(10, 69, 85, 0.9);
    --form-glow: rgba(15, 164, 182, 0.16);
    --split-shade: rgba(1, 15, 20, 0.4);
  }
}


/* ---- 3. Page base --------------------------------------------------------------------- */

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

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

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  background: var(--color-bg);
  color: var(--color-body);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}


/* ---- 4. Shared pieces: field, button, link -------------------------------------------- */

.field { display: grid; gap: 0.4rem; }

.field__label {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-muted);
}

/* a boxed field with a clear edge. 18px type: an iPhone zooms the page for anything under 16 */
.field__input {
  width: 100%;
  min-height: 3.5rem;
  margin: 0;
  padding: 0.8rem 1.1rem;
  border: 1.5px solid var(--color-field-line);
  border-radius: 0.8rem;
  background: var(--color-surface);
  box-shadow: inset 0 1px 2px var(--field-inset);
  color: var(--color-heading);
  font: inherit;
  font-size: 1.125rem;
}

/* a field the person cannot change: the same box, without the paper; an email too long
   for a narrow phone ends in three dots */
.field__input[readonly] {
  background: transparent;
  box-shadow: none;
  color: var(--color-body);
  text-overflow: ellipsis;
}

/* a field the browser filled in keeps the field's own paper and ink */
.field__input:-webkit-autofill {
  -webkit-text-fill-color: var(--color-heading);
  caret-color: var(--color-heading);
  box-shadow: inset 0 1px 2px var(--field-inset), inset 0 0 0 4rem var(--color-surface);
}

/* a code to type: the six digits, and the set-up code */
.field__input--code {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 600;
  letter-spacing: 0.22em;
}

.field__hint {
  margin: 0;
  color: var(--color-body);
  font-size: var(--text-sm);
  text-wrap: pretty;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 3.5rem;
  margin: 0;
  padding: 0 2rem;
  border: 0;
  border-radius: var(--radius-full);
  background: var(--color-cta-bg);
  box-shadow: 0 6px 16px var(--btn-shadow);
  color: var(--color-cta-text);
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
}
.btn svg { flex: none; width: 1.1rem; height: 1.1rem; }

.link {
  color: var(--color-link);
  font-size: var(--text-sm);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.25em;
}

.field__input:focus-visible,
.btn:focus-visible,
.link:focus-visible {
  outline: 2px solid var(--color-focus-ring);
  outline-offset: 3px;
}
.field__input:focus-visible { border-color: var(--color-focus-ring); }


/* ---- 5. The sign-in page: "Seam", with the filled seal -------------------------------- */
/* Two sides on a computer, a band over the form on a phone, both in the page's own theme.
   One hairline frame goes round everything and one hairline runs between the two sides.
   DOMINANT MOMENT: the salon's ringed Kb icon in rose, tilted, on a paper disc that sits
   on that line, pressed onto it like a seal. */

.door {
  --inset: clamp(0.75rem, 2.2vw, 1.75rem);
  /* the page's side margin: inside the frame on a phone, a centred column on a tablet */
  --gutter: max(calc(var(--inset) + clamp(1.25rem, 5vw, 2.25rem)), calc((100% - 28rem) / 2));
  --seal: clamp(5rem, 24vw, 6rem);
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-rows: auto 1fr;
  min-height: 100vh;
  min-height: 100svh;
  overflow: hidden; /* the tilted seal's square box must not widen the page */
  /* the form side: the page colour with one soft light in its far corner */
  background: radial-gradient(46rem 34rem at 100% 100%, var(--form-glow), transparent 65%);
}

/* one frame round everything */
.door::before {
  content: "";
  position: absolute;
  inset: var(--inset);
  z-index: 2;
  border: 1px solid var(--frame);
  pointer-events: none;
}

/* the grain: noise.svg, over both sides, so the aurora never bands. It
   belongs to the page that has it, not to the body, and it is fixed to the window as in the
   approved render (laid down with the page it comes out a step or two off in every pixel). */
.door::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 3;
  background-image: url(/site/templates/images/noise.svg);
  background-size: 200px;
  opacity: 0.05;
  pointer-events: none;
}

/* the brand side: one tone deeper than the form side, in the same theme */
.door__brand {
  position: relative;
  overflow: hidden;
  padding: calc(var(--inset) + 1.6rem) var(--gutter) 2.5rem;
  background: var(--color-bg-alt);
}

/* the aurora: four soft lights blurred into each other (it drifts in section 7) */
.door__brand::before {
  content: "";
  position: absolute;
  inset: -30% -12%;
  z-index: 0;
  background:
    radial-gradient(38% 34% at 78% 22%, var(--au-1), transparent 70%),
    radial-gradient(34% 36% at 92% 70%, var(--au-2), transparent 70%),
    radial-gradient(40% 38% at 46% 96%, var(--au-3), transparent 72%),
    radial-gradient(36% 30% at 14% 8%, var(--au-4), transparent 70%);
  filter: blur(30px) saturate(1.25);
  pointer-events: none;
}

/* the line between the two sides: the brand side's own edge, unbroken */
.door__brand::after {
  content: "";
  position: absolute;
  z-index: 1;
  left: var(--inset);
  right: var(--inset);
  bottom: 0;
  height: 1px;
  background: var(--frame);
  pointer-events: none;
}

/* the serif voice: Fraunces at 340, the accent word in rose italic at 480 */
.door__name,
.door__title {
  margin: 0;
  font-family: "Fraunces Amp", var(--font-serif);
  font-weight: 340;
  letter-spacing: -0.02em;
  color: var(--color-heading);
}
.door__name span:last-child,
.door__title span {
  font-style: italic;
  font-weight: 480;
  color: var(--color-rose-deep);
}

.door__name {
  position: relative;
  z-index: 1;
  font-size: clamp(2.7rem, 1.7rem + 5vw, 3.6rem);
  line-height: 0.96;
}
.door__name span { display: block; }
/* over the aurora the last part takes the deeper ink, run from rose into teal */
.door__name span:last-child {
  width: fit-content;
  margin: 0 0 -0.2em -0.04em;
  padding: 0 0.1em 0.2em 0.04em;
  color: var(--ink-a);
}
@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  .door__name span:last-child {
    background: linear-gradient(100deg, var(--ink-a) 0%, var(--ink-b) 46%, var(--ink-c) 108%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
  }
}
/* a device that forces its own colours takes backgrounds away: give the words their ink back */
@media (forced-colors: active) {
  .door__name span:last-child { background: none; -webkit-text-fill-color: currentColor; }
}

/* the title starts below the seal's lower half, at every width */
.door__main {
  position: relative;
  z-index: 1;
  padding: calc(var(--seal) / 2 + 0.9rem) var(--gutter) calc(var(--inset) + 2.25rem);
}

/* the seal and its disc share one place: centred on the line between the sides */
.door__main::before,
.door__main::after {
  content: "";
  position: absolute;
  top: calc(var(--seal) / -2);
  right: var(--gutter);
  width: var(--seal);
  aspect-ratio: 1;
  pointer-events: none;
}
/* the disc: the form fields' paper colour, cut to sit just under the ring's stroke
   (the ring runs from 91% to 96% of the icon's half-width) */
.door__main::after {
  z-index: 1;
  background: radial-gradient(closest-side, var(--color-surface) 93.6%, transparent 94.2%);
  filter: drop-shadow(0 0.4rem 0.9rem var(--split-shade));
}
/* the seal: the salon's ringed Kb icon as a mask, so it takes the theme's rose */
.door__main::before {
  z-index: 2;
  transform: rotate(-11deg);
  background: linear-gradient(140deg, var(--seal-a), var(--seal-b));
  -webkit-mask: url(/site/templates/images/k-bella-icon-mono.svg) center / contain no-repeat;
  mask: url(/site/templates/images/k-bella-icon-mono.svg) center / contain no-repeat;
}

.door__title {
  margin-bottom: 1.9rem;
  font-size: clamp(2.5rem, 2rem + 2.4vw, 3.5rem);
  line-height: 1;
  text-wrap: balance;
}
/* the rose words stay together: a narrow phone must not break "sign-in" at its hyphen */
.door__title span { white-space: nowrap; }

.door__error {
  margin: 0 0 1.35rem;
  padding: 0.75rem 1rem;
  border-left: 3px solid var(--color-error-text);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  background: var(--color-error-bg);
  color: var(--color-error-text);
  font-size: var(--text-sm);
  font-weight: 500;
}

.door__form { display: grid; gap: 1.35rem; }
/* the wide pill button, in the fill measured for this page (see --door-cta-bg). Under a
   pointer it takes the brand's hover colour like any button: that rule comes later. */
.door__form .btn { width: 100%; min-height: 3.75rem; margin-top: 0.6rem; background: var(--door-cta-bg); }

.door__hint {
  margin: 0;
  color: var(--color-body);
  font-size: var(--text-sm);
  text-wrap: pretty;
}

.door__alt { margin: 1.6rem 0 0; }
/* the link under the form takes the ink measured for where it sits (see --ink-link) */
.door .link { color: var(--ink-link); }

/* The phone-key view (the page itself) and the password view: "Ruled rows". The Bluetooth
   line under the pill is a margin note behind a rose rule: it reads as the instruction it is.
   The other ways in are full-width rows ruled with the frame's hairline, like the lines of a
   list: each row is pressable from edge to edge and 56 pixels tall, an easy target on the
   salon iPad, and plainly not the one main action. A sentence that something failed is boxed
   in the fault's ink, on no tint, so it is never taken for the rose note (the set-up screen's
   phone-key view has the same box). */
.door--key .door__form { gap: 1.1rem; }
.door--key .door__hint {
  padding: 0.15rem 0 0.15rem 0.95rem;
  border-left: 2px solid var(--ink-b);
}

.door--key .door__alt,
.door--password .door__alt {
  position: relative;
  margin: 0;
  border-bottom: 1px solid var(--frame);
}
.door--key .door__form + .door__alt,
.door--password .door__form + .door__alt {
  margin-top: 2rem;
  border-top: 1px solid var(--frame);
}
.door--key .door__alt .link,
.door--password .door__alt .link {
  display: flex;
  align-items: center;
  min-height: 3.5rem;
  font-size: var(--text-base);
}
/* the whole row is the link's to press */
.door--key .door__alt .link::after,
.door--password .door__alt .link::after {
  content: "";
  position: absolute;
  inset: 0;
}

.door--key .door__error,
.door--setup-key .door__error {
  border: 1px solid var(--color-error-text);
  border-radius: var(--radius-md);
  background: transparent;
  line-height: 1.55;
}

@media (min-width: 60rem) {
  .door {
    --seal: clamp(9.5rem, 13vw, 12.5rem);
    --seal-c: 36%;
    --brand-pad: calc(var(--inset) + clamp(2rem, 3.4vw, 3.25rem));
    grid-template-columns: minmax(0, 6fr) minmax(0, 7fr);
    grid-template-rows: 1fr;
  }

  .door__brand {
    display: grid;
    align-content: end;
    padding: var(--brand-pad);
    padding-right: 1.25rem;
  }
  .door__brand::before { inset: -22%; filter: blur(46px) saturate(1.25); }
  .door__brand::after {
    top: var(--inset);
    right: 0;
    bottom: var(--inset);
    left: auto;
    width: 1px;
    height: auto;
  }
  /* sized so "Hair Studio" always fits its side on one line, from the narrowest computer
     up. It is about 4.5 times the font size wide: do not raise this, or the small right
     margin above, without running the layout check again. */
  .door__name { font-size: clamp(4rem, -0.4rem + 8.4vw, 7.6rem); line-height: 0.92; }

  .door__main {
    display: grid;
    align-content: center;
    justify-items: center;
    padding: calc(var(--inset) + 2rem) calc(var(--inset) + 2.5rem) calc(var(--inset) + 2rem) calc(var(--seal) / 2 + 2.5rem);
  }
  .door__main > * { width: 100%; max-width: 26rem; }
  .door__form .btn { padding: 0 2.4rem; }

  .door__main::before,
  .door__main::after {
    top: calc(var(--seal-c) - var(--seal) / 2);
    right: auto;
    left: calc(var(--seal) / -2);
  }
}


/* ---- 6. The other steps of the sign-in page ------------------------------------------- */

/* The set-up code: eight characters and a hyphen, in capitals as the field itself asks a
   phone's keyboard for. Its type follows the screen's width so that the widest code there
   can be (WWWW-WWWW, about 10.4 times the font size) fits its field from 320 pixels up. */
.field__input--code[autocapitalize="characters"] {
  font-size: clamp(1.3rem, 0.45rem + 4.25vw, 1.8rem);
  text-transform: uppercase;
}

/* The set-up screen holds three parts, so its title is smaller and the parts are ruled off
   with the same hairline as the frame. */
.door--setup .door__title {
  margin-bottom: 1.25rem;
  font-size: clamp(2rem, 1.7rem + 1.5vw, 2.6rem);
}
.door--setup .door__form { gap: 1.75rem; }

.door__part {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}
.door__part > * + * { margin-top: 1.1rem; }

.door__legend {
  display: block;
  width: 100%;
  padding: 1.4rem 0 0;
  border-top: 1px solid var(--frame);
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--color-heading);
  text-wrap: balance;
}

/* The square code sits on a white tile in both themes: the one light surface that stays
   in dark mode, because a phone cannot scan the square on a dark one. */
.door__qr {
  width: fit-content;
  max-width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--color-border-hover);
  border-radius: var(--radius-md);
  background: var(--qr-tile);
  line-height: 0;
}
.door__qr img {
  display: block;
  max-width: 100%;
  height: auto;
  image-rendering: pixelated;
}

/* the key to type when the square cannot be scanned: its own line, one tap picks it all */
.door__key {
  display: block;
  margin-top: 0.4rem;
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--color-heading);
  -webkit-user-select: all;
  user-select: all;
}

/* The set-up screen with a phone key: "Serif note". "Signing in as NAME. Do this on your own
   phone." is the whole point of this screen, so it is set in the serif of the set-up screen's
   part headings, behind the rose rule of the phone-key view's Bluetooth note, with the button
   straight under it. Its failure sentence is boxed as on the phone-key view (section 5). */
.door--setup-key .door__form { gap: 1.6rem; }
.door--setup-key .door__hint {
  padding: 0.1rem 0 0.2rem 1rem;
  border-left: 2px solid var(--ink-b);
  font-family: "Fraunces Amp", var(--font-serif);
  font-size: 1.3rem;
  font-weight: 400;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--color-heading);
  text-wrap: balance;
}
.door--setup-key .door__form .btn { margin-top: 0; }

@media (min-width: 60rem) {
  /* The set-up screen is taller than a computer's window. Its brand side keeps the first
     screenful as on the other steps: the name at the foot of the window, the seal at the
     same height. */
  .door--setup .door__brand {
    align-content: start;
    grid-template-rows: minmax(min-content, calc(100vh - 2 * var(--brand-pad)));
    grid-template-rows: minmax(min-content, calc(100svh - 2 * var(--brand-pad)));
  }
  .door--setup .door__name { align-self: end; }
  .door--setup .door__main::before,
  .door--setup .door__main::after {
    top: calc(36vh - var(--seal) / 2);
    top: calc(36svh - var(--seal) / 2);
  }
}


/* ---- 7. Motion and hover of the shared pieces and the sign-in page -------------------- */

@media (prefers-reduced-motion: no-preference) {
  /* the aurora drifts very slowly; without this it is still */
  .door__brand::before { animation: kbc-aurora 26s ease-in-out infinite alternate; }
  @keyframes kbc-aurora {
    from { transform: translate3d(-2%, -1%, 0) rotate(0deg) scale(1); }
    to   { transform: translate3d(3%, 2%, 0) rotate(5deg) scale(1.08); }
  }

  .field__input { transition: border-color 150ms ease, box-shadow 150ms ease; }
  .btn { transition: background-color 150ms ease, transform 150ms ease, box-shadow 150ms ease; }
  .btn svg { transition: transform 200ms ease; }
  .link { transition: color 150ms ease; }
}

@media (hover: hover) {
  .btn:hover { background: var(--color-cta-bg-hover); box-shadow: 0 8px 18px var(--btn-shadow-hover); }
  .link:hover { color: var(--color-heading); }
}

@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .btn:hover { transform: translateY(-2px); }
  .btn:hover svg { transform: translateX(4px); }
}
