/* The sign-in dialog (#401, #570): warm video demo pane beside the auth column; auth-only at 760px and below. */
.signin {
  --title-size: 28px;
  --demo-title-size: 22px;
  --copy-size: 16px;
  --button-size: 15px;
  box-sizing: border-box;
  width: min(722px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  overflow: auto;
}
.signin *, .signin *::before, .signin *::after { box-sizing: border-box; }
:where(html:not(.revemaker)) .signin {
  --sg-bg: #fff;
  --sg-text: #16131d;
  --sg-muted: #55506a;
  --sg-border: #dcd7e8;
  --sg-field: #f5f3fa;
  --sg-link: #5d10d6;
  --sg-focus: #16131d;
  width: min(700px, calc(100vw - 32px));
  padding: 0;
  border: 0;
  border-radius: 20px;
  background: var(--sg-bg);
  color: var(--sg-text);
  font: 400 15px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  box-shadow: 0 24px 80px rgb(0 0 0 / .45);
}
@media (prefers-color-scheme: dark) {
  :where(html:not(.revemaker)) .signin { --sg-bg: #161616; --sg-text: #fff; --sg-muted: #b0b0b0; --sg-border: #333; --sg-field: #1f1f1f;
    --sg-link: #c4a5ff; --sg-focus: #fff; }
}
:where(html:not(.revemaker)) .signin.dark { --sg-bg: #161616; --sg-text: #fff; --sg-muted: #b0b0b0; --sg-border: #333; --sg-field: #1f1f1f;
  --sg-link: #c4a5ff; --sg-focus: #fff; color-scheme: dark; }
:where(html:not(.revemaker)) .signin::backdrop { background: rgb(10 8 16 / .55); backdrop-filter: blur(6px); }
html.signin-open { overflow: hidden; }
:where(html:not(.revemaker)) .signin :focus-visible { outline: 2px solid var(--sg-focus); outline-offset: 2px; }
.signin h2, .signin p { margin: 0; }
:where(.signin) figure { margin: 0; }
.signin svg { flex: none; }
.signin-panes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); min-height: 0; --text-top: 48px; }
.signin-teaser { display: flex; padding: 16px; background: var(--sg-bg); }
.signin-card {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 0;
  padding: calc(var(--text-top) - 16px) 0 5%;
  border-radius: 14px;
  overflow: hidden;
  container-type: inline-size;
  color: #342719;
  background: radial-gradient(ellipse at 76% 28%, #fff7e3 0%, transparent 52%),
    linear-gradient(155deg, #d8bea0, #f1dfc4 51%, #c49d80);
}
.signin-card :focus-visible { outline: 2px solid #342719; outline-offset: 2px; }
.demo-source { position: relative; display: flex; align-items: flex-start; justify-content: space-between; gap: 5%; margin: 0 13% 0 9%; }
.demo-phone {
  position: relative;
  flex: 0 0 27%;
  aspect-ratio: 10 / 17;
  margin: 0;
  overflow: hidden;
  transform: translateY(1.5cqw) rotate(5deg);
  border: 1.2cqw solid #332920;
  border-radius: 4.5cqw;
  background: #332920;
  box-shadow: 0 6px 15px #58392335;
}
.demo-phone img { display: block; width: 100%; height: 100%; object-fit: cover; }
.demo-copy strong { display: block; font: 850 var(--demo-title-size)/.99 system-ui, sans-serif; letter-spacing: -.06em; }
.demo-copy small { display: block; margin-top: .8em; font-size: var(--copy-size); line-height: 1.45; }
.demo-arrow { position: absolute; left: 48%; top: 56%; width: 25%; height: calc(44% + 10cqw); transform: scale(.75); transform-origin: bottom right; color: #624228; }
.demo-result {
  position: relative;
  width: 57%;
  flex: none;
  aspect-ratio: 1;
  margin: 10cqw auto 0;
  overflow: hidden;
  border-radius: 3cqw;
  background: #c5b6a6;
  box-shadow: 0 0 0 2px #fff1db, 0 8px 20px #64442435;
}
.demo-result video { display: block; width: 100%; height: 100%; object-fit: contain; }
.demo-action {
  display: block;
  border: 0;
  margin: 4% 4.5% 0;
  padding: .85em;
  border-radius: 1.8cqw;
  text-align: center;
  font: 650 var(--button-size) system-ui, sans-serif;
  background: #302621;
  color: #fff8ef;
  cursor: pointer;
}
.demo-action:active { filter: brightness(90%); }
@media (hover: hover) and (pointer: fine) {
  .demo-action { transition: background-color 160ms ease, filter 160ms ease; }
  .demo-action:hover:not(:disabled) { background: #1e1714; }
}
.signin-auth { position: relative; display: flex; flex-direction: column; justify-content: flex-start; gap: 14px; padding: var(--text-top) 14px 32px; text-align: center; }
.signin-close { position: absolute; top: 12px; right: 12px; }
.signin-close:where(:not(.btn)) { display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 999px;
  background: transparent; color: var(--sg-muted); cursor: pointer; }
.signin .signin-close:where(:not(.btn)):hover:not(:disabled) { background: var(--sg-field); color: var(--sg-text); }
.signin-close svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.signin .welcome { color: var(--sg-muted); font-size: var(--copy-size); font-weight: 600; }
.signin h2 { font: var(--section-title-weight) var(--title-size)/1.24 var(--font-brand); letter-spacing: var(--heading-tracking); }
.signin-sub { color: var(--sg-muted); font-size: var(--copy-size); }
.signin-google { margin: 16px 0 0; }
.signin-provider { position: relative; width: 100%; padding-inline: 48px; font-size: var(--button-size); }
.signin-provider:where(:not(.btn)) { display: flex; align-items: center; justify-content: center; min-height: 44px; padding-block: 0;
  border: 1px solid var(--sg-border); border-radius: 9999px; background: var(--sg-bg); color: var(--sg-text); font-weight: 650; cursor: pointer; }
.signin .signin-provider:where(:not(.btn)):hover:not(:disabled) { background: var(--sg-field); border-color: var(--sg-border); }
.signin-provider svg { position: absolute; left: 16px; width: 20px; height: 20px; }
.signin-google svg { stroke: none; }
.signin .signin-consent { margin-top: auto; padding-top: 10px; color: var(--sg-muted); font-size: 10.5px; text-align: center; }
.signin-consent a { color: var(--sg-link); font-size: inherit; }
@media (max-width: 760px) {
  .signin { width: calc(100vw - 16px); max-height: calc(100dvh - 16px); }
  .signin-panes { grid-template-columns: 1fr; min-height: 0; }
  .signin-teaser { display: none; }
  .signin-auth { padding: 52px 20px 24px; }
}
@media (prefers-reduced-motion: reduce) { .signin::backdrop { backdrop-filter: none; } }
@media (forced-colors: active) { .signin { border: 1px solid CanvasText; } .signin-provider, .demo-action { border: 1px solid ButtonText; } }

:where(.revemaker) .signin {
  --sg-bg: var(--surface);
  --sg-text: var(--text);
  --sg-muted: var(--muted);
  --sg-border: var(--border);
  --sg-field: var(--raised);
  --sg-link: var(--link);
}
:where(.revemaker) .signin-teaser, :where(.revemaker) .signin-auth {
  background: var(--surface);
  border-radius: var(--card-radius);
}
:where(.revemaker) .signin-card {
  border-radius: var(--inset-radius);
}
