/* JOMKER — Agent D Auth UI (Meridian source-first).
 * All auth layout, form, buttons, icons, inputs, .select, checkbox, typography and
 * dark theme colors come from /dashboard/assets/css/meridian.css, byte-equal to original Meridian.
 * Only product-specific feedback and accessibility refinements are scoped here.
 */
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }
.auth-preview{margin:0;background:var(--color-background);color:var(--color-foreground);}
.auth-preview .auth-preview-label{align-self:start;margin:0;padding:.4rem .65rem;border:1px solid var(--color-border-strong);border-radius:999px;background:var(--color-surface-2);color:var(--color-muted-foreground);font-size:var(--text-xs);font-weight:var(--font-weight-semibold);line-height:1.4;}
.auth-preview .auth-script-notice{margin:0;color:var(--color-muted-foreground);font-size:var(--text-sm);}
.auth-preview .auth-script-notice[hidden]{display:none!important;}
/* Shared flex-child minimum: keep Meridian's native form layout intact. */
.auth-preview .auth__panel,
.auth-preview .auth__form,
.auth-preview .auth__form>*{min-width:0;}
.auth-preview .auth__form .button{min-width:0;white-space:normal;}
.auth-preview .auth__form .button--block{width:100%;}
/* Keep Meridian's native focus states: .input-group:focus-within owns the
 * shared border + 3px ring; .select/.checkbox/.button/.link use their own
 * native :focus-visible rules. Never outline the inner .input separately. */
.auth-preview .field{min-width:0;}
.auth-preview .input-group,
.auth-preview .input-group .input{min-width:0;}
.auth-preview .input-group .input{min-height:3rem;font-size:max(1rem,1em);}
/* Edge adds its own password-reveal eye; keep the one custom Meridian button. */
.auth-preview input[data-password-field]::-ms-reveal,
.auth-preview input[data-password-field]::-ms-clear{display:none;}
.auth-preview [data-password-toggle]{min-width:3rem;min-height:3rem;cursor:pointer;}
.auth-preview [data-password-toggle]:focus-visible{outline:3px solid var(--color-ring);outline-offset:2px;}
.auth-preview .field__description{line-height:1.5;}
.auth-preview .auth-field-error{margin:calc(var(--spacing)*1) 0 0;color:var(--color-danger-emphasis);font-size:var(--text-xs);line-height:1.5;}
/* The invisible reference sentence reserves its natural wrapped height. Both
 * short required errors and long mismatch errors leave the checkbox in place. */
.auth-preview .auth-field-error[data-reserve-error]{display:grid;grid-template-columns:minmax(0,1fr);}
.auth-preview .auth-field-error[data-reserve-error]>*{grid-area:1/1;min-width:0;}
.auth-preview .auth-error-reserve{visibility:hidden;}
.auth-preview .auth-field-error[data-reserve-error][aria-hidden="true"]{visibility:hidden;}
/* Show validation error on the OUTER native control while blurred. On focus,
 * Meridian's blue focus-within ring takes priority over the error border. */
.auth-preview .input-group:has(.input[aria-invalid="true"]):not(:focus-within){border-color:var(--color-danger-emphasis);}
.auth-preview .checkbox[aria-invalid="true"]:not(:focus){border-color:var(--color-danger-emphasis);}
.auth-preview .auth-feedback{margin:0;border:1px solid var(--color-border-strong);border-radius:var(--radius-md);padding:calc(var(--spacing)*3);background:var(--color-surface-2);color:var(--color-foreground);line-height:1.5;}
.auth-preview .auth-feedback[hidden]{display:none!important;}
.auth-preview .auth-next-steps{display:flex;align-items:center;gap:.5rem 1rem;flex-wrap:wrap;margin-block-start:.65rem;}
.auth-preview .auth-next-steps a{color:var(--color-primary-emphasis);font-weight:var(--font-weight-semibold);text-decoration:underline;text-underline-offset:2px;}
.auth-preview .auth-next-steps a:focus-visible{outline:2px solid var(--color-ring);outline-offset:3px;}
.auth-preview .auth-separator{display:flex;align-items:center;gap:calc(var(--spacing)*3);text-align:center;}
.auth-preview .auth-separator::before,.auth-preview .auth-separator::after{content:"";height:1px;flex:1;background:var(--color-border);}
.auth-preview .auth-google-button{display:flex;justify-content:center;align-items:center;gap:calc(var(--spacing)*3);font-weight:var(--font-weight-medium);}
.auth-preview .auth-google-icon{display:inline-flex;justify-content:center;align-items:center;flex:none;width:24px;height:24px;background:var(--color-surface);border-radius:50%;}
.auth-preview .auth-google-icon img{display:block;width:20px;height:20px;object-fit:contain;}
.auth-preview .auth-preview-privacy{margin:0;text-align:center;line-height:1.5;}
/* Use the official JOMKER mark; remove the translucent Meridian placeholder tile. */
.auth-preview .auth__brand-mark{background:transparent;}
.auth-preview .auth__brand-mark img{display:block;width:100%;height:100%;object-fit:contain;}
.auth-preview .auth-preview-brand-subtitle{display:block;font-size:var(--text-xs);opacity:.8;line-height:1.4;margin-top:calc(var(--spacing)*1);}
.auth-preview .auth-preview-aside-foot{font-size:var(--text-xs);opacity:.74;}
.auth-preview .auth-preview-skip{position:fixed;inset-block-start:-100px;inset-inline-start:12px;background:var(--color-surface);border:2px solid var(--color-ring);padding:10px;z-index:90;color:var(--color-foreground);}
.auth-preview .auth-preview-skip:focus{inset-block-start:10px;}
/* The skip link must not fall back to the browser's 1px black 'auto' outline.
   Use the same Meridian focus token while preserving the keyboard reveal. */
.auth-preview .auth-preview-skip:focus-visible{outline:2px solid var(--color-ring);outline-offset:2px;}
/* Keep the official Google secondary button legible in dark mode. */
html[data-theme="dark"] .auth-preview .auth-google-button,
html[data-theme="dark"] .auth-preview .auth-google-button:is(:hover,:focus-visible){color:var(--color-foreground);border-color:var(--color-border);}
/* D-owned hero imagery is confined to Meridian's right auth__aside.
 * Form, auth panel, responsive breakpoint and native brand/pitch are untouched. */
.auth-preview .auth-hero{
 position:relative;isolation:isolate;flex:0 1 auto;
 width:min(100%,360px);height:clamp(188px,36dvh,340px);
 margin-inline:auto;min-height:0;overflow:hidden;
 border-radius:var(--radius-xl);border:1px solid color-mix(in oklch,var(--color-overlay-foreground) 19%,transparent);
 background:var(--color-overlay);box-shadow:var(--shadow-xl);
}
.auth-preview .auth-hero__slides,
.auth-preview .auth-hero__slide{position:absolute;inset:0;}
.auth-preview .auth-hero__slide{opacity:0;z-index:0;pointer-events:none;
 transition:opacity 900ms cubic-bezier(.25,.46,.45,.94);will-change:opacity;}
.auth-preview .auth-hero__slide.is-active{opacity:1;z-index:1;}
.auth-preview .auth-hero__slide img{
 display:block;width:100%;height:100%;object-fit:cover;object-position:center 52%;
 transform:scale(1.01);transition:transform 5600ms ease-out;
}
.auth-preview .auth-hero__slide.is-active img{transform:scale(1.065);}
.auth-preview .auth-hero__controls{
 position:absolute;inset-inline:0;bottom:0;z-index:3;
 display:flex;align-items:center;justify-content:space-between;
 padding:15px 17px 12px;
 background:linear-gradient(180deg,transparent,color-mix(in oklch,var(--color-overlay) 60%,transparent));
}
.auth-preview .auth-hero__dots{display:flex;align-items:center;gap:7px;}
.auth-preview .auth-hero__dot{display:block;width:7px;height:7px;
 border-radius:999px;background:color-mix(in oklch,var(--color-overlay-foreground) 38%,transparent);transition:width 650ms ease,background 650ms ease;}
.auth-preview .auth-hero__dot.is-active{width:24px;background:var(--color-success);}
.auth-preview .auth-hero__toggle{
 min-height:34px;padding:4px 11px;border-radius:999px;
 border:1px solid color-mix(in oklch,var(--color-overlay-foreground) 35%,transparent);
 background:color-mix(in oklch,var(--color-overlay) 50%,transparent);
 color:var(--color-overlay-foreground);font:inherit;font-size:var(--text-xs);line-height:1;cursor:pointer;
}
.auth-preview .auth-hero__toggle:hover{background:color-mix(in oklch,var(--color-overlay) 88%,transparent);border-color:color-mix(in oklch,var(--color-overlay-foreground) 72%,transparent);}
.auth-preview .auth-hero__toggle:focus-visible{outline:3px solid var(--color-success);outline-offset:3px;}
.auth-preview .auth-hero__toggle[hidden]{display:none!important;}
@media(min-width:64rem) and (max-height:700px){
 .auth-preview .auth-hero{height:clamp(160px,28dvh,245px);}
}
@media(prefers-reduced-motion:reduce){.auth-preview *,.auth-preview *::before,.auth-preview *::after{animation-duration:0s!important;transition-duration:0s!important;}}

/* Shared full-bleed Auth hero, based on the existing Login layout.
   Login, Register and Forgot use the same photos, overlay and controls. */
@media(min-width:64rem){
 .auth-preview .auth__panel{flex:9 1 0;}
 .auth-preview .auth__aside--full-hero{flex:11 1 0;}
}
.auth-preview .auth__aside--full-hero{
 position:relative;isolation:isolate;overflow:hidden;min-height:100dvh;height:100dvh;
 margin:0;border-radius:0;background:var(--color-overlay);
 padding:clamp(30px,3.6vw,56px);justify-content:flex-start;gap:0;
}
.auth-preview .auth__aside--full-hero::after{
 content:"";position:absolute;inset:0;z-index:1;pointer-events:none;
 background:linear-gradient(180deg,
  color-mix(in oklch,var(--color-overlay) 59%,transparent) 0%,
  color-mix(in oklch,var(--color-overlay) 7%,transparent) 31%,
  color-mix(in oklch,var(--color-overlay) 17%,transparent) 49%,
  color-mix(in oklch,var(--color-overlay) 86%,transparent) 100%);
}
.auth-preview .auth-hero--full{
 position:absolute;inset:0;width:100%;height:100%;min-height:100%;max-width:none;
 margin:0;border:0;border-radius:0;box-shadow:none;background:var(--color-overlay);z-index:0;
}
.auth-preview .auth-hero--full .auth-hero__slide{
 transition:opacity 750ms cubic-bezier(.22,.61,.36,1);will-change:opacity;
}
.auth-preview .auth-hero--full .auth-hero__slide img,
.auth-preview .auth-hero--full .auth-hero__slide.is-active img{
 display:block;width:100%;height:100%;object-fit:cover;transform:none;transition:none;
}
.auth-preview .auth__aside--full-hero>.auth__brand,
.auth-preview .auth__aside--full-hero>.auth__pitch{
 position:relative;z-index:2;
}
.auth-preview .auth__aside--full-hero>.auth__pitch{
 margin-block-start:auto;margin-block-end:clamp(60px,7dvh,88px);max-width:37rem;
}
 .auth-preview .auth__aside--full-hero .auth__pitch-title,
 .auth-preview .auth__aside--full-hero .auth__pitch-title span{color:var(--color-overlay-foreground);}
 .auth-preview .auth__aside--full-hero .auth__pitch-lede{color:color-mix(in oklch,var(--color-overlay-foreground) 90%,transparent);}
.auth-preview .auth__aside--full-hero > .auth-hero__controls{
 z-index:3;inset:auto clamp(30px,3.6vw,56px) clamp(22px,3.3dvh,40px);
 padding:0;background:none;display:flex;align-items:center;justify-content:flex-start;gap:16px;
}
.auth-preview .auth-hero__count{
  color:var(--color-overlay-foreground);font-size:var(--text-xs);font-weight:var(--font-weight-medium);font-variant-numeric:tabular-nums;white-space:nowrap;
}
.auth-preview .auth-hero__dots{gap:1px;}
.auth-preview .auth-hero__dot,
.auth-preview .auth-hero__dot.is-active{
 appearance:none;border:0;background:transparent;box-shadow:none;
 display:grid;place-items:center;flex:0 0 36px;width:36px;height:36px;
 padding:0;cursor:pointer;transition:none;
}
.auth-preview .auth-hero__dot-indicator{
  width:7px;height:7px;border-radius:999px;background:color-mix(in oklch,var(--color-overlay-foreground) 55%,transparent);
 transition:width 250ms ease,background 250ms ease;
}
.auth-preview .auth-hero__dot.is-active .auth-hero__dot-indicator{
  width:24px;background:var(--color-success);
}
 .auth-preview .auth-hero__dot:hover .auth-hero__dot-indicator{background:var(--color-overlay-foreground);}
.auth-preview .auth-hero__dot:focus-visible{
  outline:2px solid var(--color-overlay-foreground);outline-offset:1px;border-radius:999px;
}
.auth-preview .auth-hero__toggle{
  margin-inline-start:auto;background:color-mix(in oklch,var(--color-overlay) 42%,transparent);
  border-color:color-mix(in oklch,var(--color-overlay-foreground) 45%,transparent);color:var(--color-overlay-foreground);
}
@media(min-width:64rem) and (max-height:670px){
 .auth-preview .auth__aside--full-hero{padding:28px;}
 .auth-preview .auth__aside--full-hero>.auth__pitch{margin-block-end:64px;}
}
@media(prefers-reduced-motion:reduce){
 .auth-preview .auth-hero--full .auth-hero__slide,
 .auth-preview .auth-hero__dot-indicator{transition-duration:0s;}
}

/* Announce user-selected slides to assistive technology without changing hero layout. */
.auth-preview .auth-hero__announcement{
  position:absolute;inline-size:1px;block-size:1px;padding:0;margin:-1px;
  overflow:hidden;clip-path:inset(50%);white-space:nowrap;pointer-events:none;
}

/* Shared full-bleed caption entrance (380ms) for all Auth screens. */
@keyframes applytrack-auth-caption-enter{from{opacity:.2;transform:translateY(7px)}to{opacity:1;transform:translateY(0)}}
.auth-preview .auth__pitch.is-changing{animation:applytrack-auth-caption-enter 380ms ease-out both;}
@media(prefers-reduced-motion:reduce){.auth-preview .auth__pitch.is-changing{animation:none!important;}}

/* Email action states use the same Meridian form geometry. */
.auth-preview[data-auth-page="action"] [hidden]{display:none!important;}
.auth-preview[data-auth-page="action"] .auth-feedback[data-kind="error"]{border-color:var(--color-danger-emphasis);color:var(--color-danger-emphasis);}
