/* ===========================================================================
   PropEdge — the public/auth shell
   Ayaz · 20 Sep 2026 · workstream W3 · decision register E47

   STATUS: APPROVED with the Login screen, 23 Sep 2026 (D29 — the preview as
   committed in 575ec36). LIVE COPY at PropEdge_UI/css/propedge-auth.css,
   brought in by Mahenoor on 27 Sep: its rules identical to design/css/propedge-auth.css (synced by Ayaz, 28 Sep)
   apart from comments. Diff the two, comments stripped, before changing
   either one.
   It is the ONE shared auth stylesheet D21
   and D24 require — Forgot Password, Email Verification and the rest link
   this file; they never copy it.
   Load order: propedge-fonts.css -> propedge-tokens.css ->
   propedge-components.css -> this file. No Bootstrap on auth screens.
   Folding it into propedge-components.css (the original plan below) is a
   design-system change for Ayaz, not something to do in a screen build.

   Original note: this file is deliberately SEPARATE from
   propedge-components.css. That file is the approved M1 design system (D1);
   keeping them apart meant approving the Login screen did not quietly change
   anything already signed off.

   WHAT IT IS
   One shell for all five public screens — Login, Forgot Password, Email
   Verification, Free Trial, Landing's sign-in entry. A navy page, a white
   card floating on it, the brand above, a quiet line below. The card width
   is the only thing that changes between screens:

       --pe-auth-w   400px   Login, Forgot Password, Email Verification
       --pe-auth-w   640px   Free Trial (a longer form needs two columns at md)

   WHY A CARD AND NOT THE TWO-PANEL MARKETING LAYOUT
   The live page puts a marketing column beside the form. Three reasons it is
   gone. First, its copy promises "know who paid and who is overdue", which is
   rent collection — Phase 2 (P3). A trial user who reads that goes looking for
   a feature that is not there. Second, a returning member of staff signs in
   every morning; the column is permanent dead space for the person who uses
   this screen most. Third, a centred card mirrors for Arabic with no work at
   all, while a two-panel split has to be re-thought at every breakpoint in
   both directions. Landing is where we sell; this is where people get in.

   EVERYTHING IS LOGICAL PROPERTIES. No padding-left, no margin-right, no
   text-align:left anywhere in this file — that is defect W3-04's root cause.
   =========================================================================== */

/* ==========================================================================
   1. THE PAGE
   ========================================================================== */
/* body.pe-auth, not .pe-auth: `body.pe-root` in propedge-components.css sets
   the light canvas background with two selectors' worth of specificity, so a
   single class here loses to it and the page renders light grey. Caught in the
   browser, not assumed. */
body.pe-auth {
  --pe-auth-w: 400px;
  --pe-auth-gutter: var(--pe-space-16);

  box-sizing: border-box;
  min-height: 100vh;
  min-height: 100svh;                 /* iOS: svh excludes the collapsing bar */
  width: 100%;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;

  /* VERTICAL CENTRING, THE SAFE WAY — changed 22 Sep, defect W3-08.
     This line was `justify-content: center`. That centres correctly right up
     to the moment the content is taller than the viewport; then the overflow
     escapes past BOTH edges, and the part above the top edge is unreachable —
     there is no scroll position that reveals it, in any browser.
     Caught in the browser at 375x812 once the E52 checkbox, its helper line
     and the D24 footer were added: together they push Login past 812px, and
     the brand and the LANGUAGE SWITCHER became impossible to scroll to. An
     Arabic-reading landlord on a phone could not reach the one control that
     puts the page into Arabic. It would have been certain on Free Trial, which
     is a longer form on a wider card.
     The auto margins below give identical centring and degrade correctly: when
     free space is negative an auto margin resolves to zero, so the content
     starts at the top and overflows downwards, where the scrollbar reaches it.
     Do not put `justify-content: center` back. */
  justify-content: flex-start;

  background: var(--pe-brand-900);    /* #0C2A41 */
  padding-inline: var(--pe-auth-gutter);
  padding-block: var(--pe-space-32);
}
body.pe-auth *, body.pe-auth *::before, body.pe-auth *::after { box-sizing: border-box; }

/* The two auto margins that do the centring. They are on the FIRST and LAST
   in-flow children of the page, so any screen using this shell must keep that
   shape: strip, card, footer. The skip link is out of flow and does not count. */
body.pe-auth > .pe-auth__top { margin-block-start: auto; }
body.pe-auth > .pe-pubfoot   { margin-block-end: auto; }

/* Focus on the navy page needs its own colour. MEASURED: the standard ring
   --pe-border-focus #2A76AC is 3.01:1 on #0C2A41 — it passes WCAG 1.4.11 by
   one hundredth, which is not a margin to ship the keyboard user's only
   orientation cue on. White is 14.75:1 on the same navy. Note also that
   `outline-offset` shows the PARENT background in the gap, not white, so the
   "2px white offset" described in propedge-components.css does not actually
   produce a white halo on a dark surface. */
.pe-auth-onnavy :focus-visible { outline-color: var(--pe-neutral-0); }

/* FIX, Mahenoor 27 Sep (carried into design/css/propedge-auth.css 28 Sep).
   The rule above has the same specificity as `.pe-root :focus-visible` in
   propedge-components.css (0,2,0) and loads later, so it ALSO turned the ring
   white inside the white card: the Sign In button, the checkbox, Show/Hide,
   "Forgot password?", the trial link and the error-summary links had no
   visible focus at all (WCAG 2.4.7). Text inputs were unaffected only because
   they draw their own box-shadow ring. This puts the standard ring back inside
   the card - #2A76AC is 4.90:1 on white - and leaves the navy page white.
   Nothing changes in the resting state. */
.pe-auth-onnavy .pe-auth__card :focus-visible { outline-color: var(--pe-border-focus); }

.pe-auth__skip {
  position: absolute; inset-inline-start: var(--pe-space-16); inset-block-start: -100px;
  z-index: 10; background: var(--pe-neutral-0); color: var(--pe-brand-700);
  padding: var(--pe-space-8) var(--pe-space-16); border-radius: var(--pe-radius-sm);
  font-weight: var(--pe-fw-semibold); text-decoration: none;
}
.pe-auth__skip:focus { inset-block-start: var(--pe-space-16); }

/* ==========================================================================
   2. THE STRIP ABOVE THE CARD — brand on the inline-start, language on the end
   ========================================================================== */
/* max-width is the CARD width, not card + gutter. With the gutter added, the
   strip was wider than the card and at 440px the language link was pushed off
   the right edge. Matching the card also lines the brand and the language link
   up with the card's own edges, which is what it should have been anyway. */
.pe-auth__top {
  width: 100%;
  max-width: var(--pe-auth-w);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--pe-space-16);
  margin-block-end: var(--pe-space-24);
}

/* The lockup is an <img> of the on-dark SVG. That is only possible because the
   wordmark was outlined on 20 Sep; before that an <img> could not load the
   font and rendered in a fallback. Never swap this for the CSS lockup here —
   on navy it would need its own colour overrides. */
.pe-auth__brand img { display: block; height: 40px; width: auto; }

.pe-auth__lang {
  display: inline-flex; align-items: center; gap: var(--pe-space-8);
  min-height: var(--pe-control-h-md);        /* 44px hit area, WCAG 2.5.8 */
  padding-inline: var(--pe-space-12);
  border-radius: var(--pe-radius-sm);
  color: var(--pe-brand-200);                /* 9.58:1 on #0C2A41 */
  font-size: var(--pe-fs-sm);
  font-weight: var(--pe-fw-semibold);
  text-decoration: none;
  border: 1px solid rgba(179, 213, 236, .35);
  background: transparent;
  cursor: pointer;
}
.pe-auth__lang:hover { color: var(--pe-neutral-0); border-color: rgba(255,255,255,.6); }

/* BACK TO HOME — 6 Oct 2026 (founders' escalation: Sign in and Forgot
   Password had no way back to the landing page). Two routes, both in
   authheader.ascx: the lockup is now a link (.pe-auth__brand is an <a>), and
   a worded "Back to home" link sits on its own row under brand + language,
   at the inline-start, directly above the card. Top, not under the card:
   Free Trial's card is long, and a link below it would be off screen.
   The strip becomes a two-column grid so that row can span the full width
   while the link itself stays only as wide as its words (a 100%-wide flex
   item would make the whole row clickable). No new colours: the language
   link's brand-200 (#B3D5EC on #0C2A41 = 9.58:1), white on hover (14.75:1);
   the white focus ring of .pe-auth-onnavy applies. The arrow mirrors in
   Arabic through .pe-icon--directional (propedge-components.css). */
.pe-auth__top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  row-gap: var(--pe-space-4);
}
.pe-auth__brand { display: inline-flex; align-items: center; min-height: var(--pe-control-h-md); justify-self: start; border-radius: var(--pe-radius-xs); }   /* 44px target (11 Oct): the 32px phone lockup was a 32px link */
.pe-auth__home {
  grid-column: 1 / -1;
  justify-self: start;
  display: inline-flex; align-items: center; gap: var(--pe-space-8);
  min-height: var(--pe-control-h-md);        /* 44px hit area, WCAG 2.5.8 */
  padding-inline: var(--pe-space-4);
  margin-inline-start: calc(var(--pe-space-4) * -1);   /* arrow lines up with the card edge */
  border-radius: var(--pe-radius-sm);
  color: var(--pe-brand-200);                /* 9.58:1 on #0C2A41 */
  font-size: var(--pe-fs-sm);
  line-height: var(--pe-lh-snug);
  font-weight: var(--pe-fw-semibold);
  text-decoration: none;
}
.pe-auth__home:hover { color: var(--pe-neutral-0); text-decoration: underline; text-underline-offset: 3px; }

/* ==========================================================================
   3. THE CARD
   ========================================================================== */
.pe-auth__card {
  width: 100%;
  max-width: var(--pe-auth-w);
  background: var(--pe-surface);
  border-radius: var(--pe-radius-xl);
  box-shadow: var(--pe-shadow-xl);
  padding: var(--pe-space-32);
}
@media (min-width: 576px) { .pe-auth__card { padding: var(--pe-space-40); } }

.pe-auth__title { margin: 0 0 var(--pe-space-8); }
.pe-auth__sub   { margin: 0 0 var(--pe-space-24); color: var(--pe-text-muted); }

.pe-auth__foot {
  margin-block-start: var(--pe-space-24);
  padding-block-start: var(--pe-space-20);
  border-block-start: 1px solid var(--pe-border);
  text-align: center;
  color: var(--pe-text-muted);
  font-size: var(--pe-fs-sm);
}
/* H2, Rahil's audit 6 Oct: a bare <a> in this line (Login's "Start a 30-day
   free trial") had NO author colour - auth screens load no Bootstrap - so it
   rendered the browser's default blue rgb(0,0,238), and purple once visited,
   beside "Forgot password?" in #1B5E8E. Same colour and weight as every other
   auth link now. A plain `a` selector covers :visited too (an author rule
   beats the browser's :visited colour). Focus: the card's standard ring,
   .pe-auth-onnavy .pe-auth__card :focus-visible above. Inline in a sentence,
   so no 44px box (WCAG 2.5.8 inline exception). */
.pe-auth__foot a { color: var(--pe-text-link); font-weight: var(--pe-fw-semibold); }   /* 6.91:1 on white */
.pe-auth__foot a:hover { color: var(--pe-text-link-hover); }

/* .pe-auth__legal — REMOVED 21 Sep, superseded by .pe-pubfoot (D24, section 4b).
   It was a second support line, and the footer now carries the D21 support
   contact. Two support lines on one screen means two places to update when the
   real number arrives, and one of them would have been missed. It also carried
   an INVENTED address, support@propedge.om, which nobody had confirmed — see
   the .pe-pubfoot__tbc note. If a future screen needs a quiet line under the
   card that is not support, give it a new class; do not revive this one. */

/* ==========================================================================
   4. FORM PIECES THIS SHELL ADDS
   ========================================================================== */

/* The error summary. One place, above the form, focused on failure, so a
   screen-reader user and a sighted user are told the same thing in the same
   order. role="alert" is on the element; it is EMPTY until there is something
   to say — an empty live region that already exists announces reliably, one
   inserted at the moment of failure often does not. */
.pe-auth__alert { margin-block-end: var(--pe-space-20); }
.pe-auth__alert:empty { display: none; }
.pe-auth__alert:focus { outline: 3px solid var(--pe-border-focus); outline-offset: 2px; }

/* When more than one field is wrong, the summary LISTS them as links. Clicking
   one moves focus to that field. A summary that only says "check the form"
   makes a screen-reader user hunt for what is actually wrong. */
.pe-auth__errlist { margin: var(--pe-space-8) 0 0; padding-inline-start: var(--pe-space-20); }
.pe-auth__errlist li { margin-block-start: var(--pe-space-4); }
.pe-auth__errlist a { color: var(--pe-danger-fg); font-weight: var(--pe-fw-semibold); }

/* NOTICES WITHOUT A ONE-WORD LAST LINE — OPT-IN (27 Sep fifth round, from
   design/css/propedge-auth.css; brought live 28 Sep with D35). A modifier a
   page adds to a notice it owns: every Forgot Password notice, and Login's
   "password changed" notice only - never an approved Login state. Acts on
   the notice's text block, the <div> beside the icon. */
.pe-alert--nowidow > div { text-wrap: pretty; }

/* Password field with a Show / Hide control inside it.
   Deliberately a WORD, not an eye icon. Two reasons: the icon set has no eye
   and inventing one needs approval; and "Show"/"Hide" states what will happen,
   where a crossed-out eye is ambiguous about which state it is reporting. */
.pe-pw { position: relative; display: block; }

/* THE ONE PLACE IN THIS FILE THAT USES PHYSICAL PROPERTIES, deliberately.
   The input is pinned to direction:ltr (a password is Latin), so ITS OWN
   inline-end is always the right-hand side — while the Show/Hide button is
   positioned against the WRAPPER, which does mirror. Using padding-inline-end
   on the input therefore reserved space on the right while the button sat on
   the left: measured in Arabic at 1440, the reserved gap and the button were
   on opposite sides and a long password would have run underneath the button.
   Keying the padding to [dir] is the correct fix, not a shortcut. */
.pe-pw .pe-input { padding-right: 4.75rem; padding-left: var(--pe-space-12); }
[dir="rtl"] .pe-pw .pe-input { padding-right: var(--pe-space-12); padding-left: 4.75rem; }
.pe-pw__toggle {
  position: absolute;
  inset-inline-end: var(--pe-space-4);
  inset-block-start: 50%;
  transform: translateY(-50%);
  min-height: var(--pe-control-h-md);         /* 44px */
  min-width: var(--pe-control-h-md);
  padding-inline: var(--pe-space-8);
  border: 0; background: transparent;
  color: var(--pe-text-link);                 /* 6.91:1 on white */
  font: inherit; font-size: var(--pe-fs-sm); font-weight: var(--pe-fw-semibold);
  cursor: pointer;
  border-radius: var(--pe-radius-xs);
}
.pe-pw__toggle:hover { color: var(--pe-brand-700); }

/* A password is always LTR, in both languages, and never letter-spaced. */
.pe-input[type="password"], .pe-pw .pe-input { direction: ltr; text-align: start; }
[dir="rtl"] .pe-input[type="password"], [dir="rtl"] .pe-pw .pe-input { text-align: right; }

/* An email address is always LTR too. Left in the RTL flow it splits around
   the @ and the dots exactly the way the +968 dial code does (defect W3-02). */
.pe-input[type="email"] { direction: ltr; }
[dir="rtl"] .pe-input[type="email"] { text-align: right; }

/* Caps Lock. A status, not an error: it does not set aria-invalid, does not
   block submit and does not steal focus. */
.pe-caps {
  display: none;
  align-items: flex-start; gap: var(--pe-space-8);
  margin-block-start: var(--pe-space-8);
  padding: var(--pe-space-8) var(--pe-space-12);
  background: var(--pe-warning-bg); border: 1px solid var(--pe-warning-border);
  border-radius: var(--pe-radius-sm);
  color: var(--pe-warning-fg);                /* 6.93:1 on #FDF3E2 */
  font-size: var(--pe-fs-caption);
}
.pe-caps.is-on { display: flex; }

/* ---------------------------------------------------------------------------
   THE OPTIONS ROW — "Keep me signed in" on the inline-start, "Forgot password?"
   on the inline-end, sitting between the password field and the button (E52).

   WHY A ROW AND NOT TWO STACKED BLOCKS. These are the two things a person does
   on this screen that are not "type the password", and they are opposites: one
   is "let me back in faster next time", the other is "I cannot get in now".
   Side by side they read as a pair of choices; stacked, the checkbox reads as
   another form field and gets ticked without being read.

   It WRAPS rather than shrinking. The helper text under the checkbox is a full
   sentence, so below roughly 480px the two no longer fit on one line and the
   Forgot link drops to its own row, still on the inline-end. Nothing is
   truncated and nothing overlaps — measured at 375 and at 320.
   --------------------------------------------------------------------------- */
.pe-auth__options {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: var(--pe-space-4) var(--pe-space-16);
  margin-block: calc(var(--pe-space-8) * -1) var(--pe-space-20);
}

/* The checkbox block. .pe-choice (propedge-components.css) already gives the
   label a 44px minimum height and a pointer cursor, so the whole label — box
   and words — is one hit target. It is NOT decoration and must not read as
   decoration. */
.pe-auth__keep { flex: 1 1 15rem; min-width: 0; }
.pe-auth__keep .pe-choice { padding-block: var(--pe-space-4); }
.pe-auth__keep .pe-choice__text {
  font-size: var(--pe-fs-sm);
  line-height: var(--pe-lh-snug);             /* explicit, per E51 */
  font-weight: var(--pe-fw-medium);
}

/* The helper sentence sits OUTSIDE the <label> and is wired with
   aria-describedby. Inside the label it would become part of the checkbox's
   accessible name, so a screen reader would announce the whole sentence every
   time focus landed on the box. Outside it, the name stays "Keep me signed in"
   and the sentence is offered as a description. */
.pe-auth__keephint {
  margin: 0;
  padding-inline-start: calc(22px + var(--pe-space-12));  /* aligns under the label text, not the box */
  font-size: var(--pe-fs-caption);
  line-height: var(--pe-lh-snug);             /* explicit, per E51 */
  color: var(--pe-text-muted);                /* 6.78:1 on white */
  text-align: start;
}

/* Forgot-password link, on the inline-end of the options row.
   `margin-inline-start: auto` and NOT a media query, deliberately — corrected
   22 Sep after seeing it in the browser. The row wraps according to the width
   of the CARD, not the width of the viewport, so a `max-width: 479.98px` media
   query fires at the wrong moment: at an 800px viewport the card is still
   400px, the row had already wrapped, and the link sat at the inline-START of
   its new line looking like a stray sentence. An auto inline-start margin
   absorbs the free space on whichever line the link ends up on, so it stays on
   the inline-end whether it shares a line with the checkbox or has its own —
   and being a logical property, it mirrors for Arabic with no second rule. */
.pe-auth__aside {
  display: flex;
  flex: 0 0 auto;
  margin-inline-start: auto;
}
.pe-auth__aside a {
  display: inline-flex; align-items: center;
  min-height: var(--pe-control-h-md);         /* 44px hit area */
  padding-inline: var(--pe-space-4);
  color: var(--pe-text-link); font-size: var(--pe-fs-sm);
  line-height: var(--pe-lh-snug);             /* explicit, per E51 */
  font-weight: var(--pe-fw-semibold);
}

/* ==========================================================================
   4b. THE PUBLIC FOOTER — D24
   All five public screens, from this one stylesheet. Deliberately thin.

   WHAT IT IS AND IS NOT. A sign-in footer is OPERATIONAL, never marketing.
   The two comparables the team fetched have almost nothing in common — Zoho's
   sign-in footer is a single copyright line, Xero's is six operational links —
   but neither carries "About Us" and neither sells anything. So this footer
   carries exactly two things: who we are, and how to reach a human.

   WHAT IS DELIBERATELY ABSENT, so nobody "completes" it later by accident:
     · no legal entity, CR number, address or VAT number — the company is not
       registered yet (P8), and a footer that implies otherwise is a false
       statement on the page that collects the password;
     · no Privacy or Terms LINK — GAP-4 is open and we have no privacy notice.
       The slot is reserved in the markup below and renders nothing. A link
       that goes nowhere is a worse trust signal than its absence;
     · no third-party origin of any kind — no badge, icon font, widget, CDN
       script or preconnect. GAP-14 means there is no Content-Security-Policy
       constraining a script on this page. The WhatsApp entry is an ordinary
       href the user clicks; nothing is loaded from wa.me;
     · no claim we cannot substantiate today — no uptime, no customer count,
       no certification.
   ========================================================================== */
.pe-pubfoot {
  --pe-pubfoot-w: 34rem;                      /* 544px - a support line needs a
                                                 wider measure than the 400px
                                                 card; centred, so it still
                                                 reads as one column */
  width: 100%;
  max-width: min(100%, var(--pe-pubfoot-w));
  margin-block-start: var(--pe-space-24);
  text-align: center;
  font-size: var(--pe-fs-caption);
  line-height: var(--pe-lh-base);             /* explicit, per E51 */
  color: var(--pe-brand-200);                 /* 9.58:1 on #0C2A41 */
}
.pe-pubfoot p { margin: 0; }
.pe-pubfoot__id { font-weight: var(--pe-fw-regular); }

.pe-pubfoot__support {
  margin-block-start: var(--pe-space-8) !important;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--pe-space-4) var(--pe-space-12);
}
.pe-pubfoot a {
  display: inline-flex; align-items: center;
  min-height: var(--pe-control-h-md);         /* 44px hit area, WCAG 2.5.8 */
  padding-inline: var(--pe-space-4);
  color: var(--pe-neutral-0);                 /* 14.75:1 on #0C2A41 */
  text-decoration: underline;
  text-underline-offset: 3px;
}
/* No separator glyph between the support contacts — see the note in login.html.
   The gap separates them, and unlike a "·" it survives the line wrap at 375. */

/* ---------------------------------------------------------------------------
   PLACEHOLDER MARKER — this must never ship.
   The real support email and the real Omani WhatsApp number are not known yet.
   An invented-but-plausible address (support@propedge.om, which this preview
   used to carry) is the dangerous version: it survives review because it looks
   finished. This treatment is loud on purpose — amber chip, dashed border,
   a literal "TBC" said aloud to a screen reader as well as shown.
   Delete .pe-pubfoot__tbc from this file on the day the real values land; the
   page will then fail loudly if any placeholder is still in the markup.
   --------------------------------------------------------------------------- */
.pe-pubfoot__tbc {
  background: var(--pe-warning-bg);           /* #FDF3E2 */
  color: var(--pe-warning-fg) !important;     /* #7A4800 - 6.93:1 on that bg */
  border: 2px dashed var(--pe-warning-solid); /* #9A5B00 - 4.93:1 on #FDF3E2,
                                                 against a 3:1 non-text need */
  border-radius: var(--pe-radius-sm);
  padding-inline: var(--pe-space-8);
  font-weight: var(--pe-fw-semibold);
  text-decoration: underline;
}
.pe-pubfoot__tbc:hover { background: #F7E4C4; }

/* ==========================================================================
   4c. FORGOT PASSWORD — folded in 28 Sep (D35), Mahenoor
   The preview's "PAGE-LOCAL ADDITIONS" (design/previews/forgotpassword.html
   at b8e74c7), moved here as that preview said they must be once approved:
   Free Trial also sets a password. Values unchanged. Rules that must NOT
   reach the approved Login are scoped to html.pe-page-forgot (the class is
   on forgotpassword.aspx only). Carried into design/css/propedge-auth.css
   by Ayaz, 28 Sep.
   Only rule B's panel is here (Sameera, 28 Sep): rule A's title and its
   "(A–Z)" / "! @ # $" examples are gone with rule A.
   ========================================================================== */

/* THIS PAGE ONLY: no one-word orphan on a two-line heading (O9), and none on
   the error-summary links (fifth round, 6a - in the shared shell it changed
   the approved Login's `empty` state). */
html.pe-page-forgot .pe-auth__title { text-wrap: balance; }
html.pe-page-forgot .pe-auth__errlist li { text-wrap: pretty; }

/* A heading with no sub-line under it (steps 2 and 3a). */
.pe-auth__title--solo { margin-block-end: var(--pe-space-24); }

/* The "check your email" paragraph, and the quieter line under it. */
.pe-auth__lede {
  margin: 0 0 var(--pe-space-8);
  font-size: var(--pe-fs-base);
  line-height: var(--pe-lh-base);
  color: var(--pe-text);
  text-align: start;
}
.pe-auth__note {
  margin: 0 0 var(--pe-space-24);
  font-size: var(--pe-fs-sm);
  line-height: var(--pe-lh-base);
  color: var(--pe-text-muted);               /* 6.78:1 on white */
  text-align: start;
}

/* O-C1: no one-word last line in body copy. .pe-auth__sub is scoped: it is
   Login's sub-line too. */
html.pe-page-forgot .pe-auth__sub,
.pe-auth__lede, .pe-auth__note, .pe-auth__account, .pe-pwrules__tip { text-wrap: pretty; }

/* An email address inside running text: one inline-block no wider than the
   line, so an address that fits stays whole; a wider one breaks only between
   its pieces, each ending in "." or "@" - never after "-" (R1, O-L1). */
.pe-auth__addr {
  display: inline-block;
  max-width: 100%;
  font-weight: var(--pe-fw-semibold);
  color: var(--pe-text-strong);
}
.pe-auth__addr-part { display: inline-block; max-width: 100%; overflow-wrap: anywhere; }
/* In Arabic the address's own lines hang from the right edge like the text
   around them (O3). The characters inside each line stay left-to-right. */
[dir="rtl"] .pe-auth__addr { text-align: right; }

/* Step 2's address on its own line, above the sentence (O3). */
.pe-auth__addrline { margin: 0 0 var(--pe-space-8); line-height: var(--pe-lh-snug); text-align: start; }

/* Card-level links: colour, weight and 44px hit area of Login's "Forgot
   password?". */
.pe-auth__link {
  display: inline-flex; align-items: center; gap: var(--pe-space-4);
  min-height: var(--pe-control-h-md);
  padding-inline: var(--pe-space-4);
  color: var(--pe-text-link);                /* 6.91:1 on white */
  font-size: var(--pe-fs-sm);
  line-height: var(--pe-lh-snug);
  font-weight: var(--pe-fw-semibold);
}
.pe-auth__link:hover { color: var(--pe-text-link-hover); }
.pe-auth__center { display: flex; justify-content: center; margin-block-start: var(--pe-space-8); }

/* "Send the link again" carries its own result, so nothing on the card moves:
   idle | sending (the .is-loading spinner) | done (tick + "Sent again", 5 s) |
   waiting (rate-limited, aria-disabled, readable 6.27:1 - not the faint stock
   disabled look). */
.pe-btn__done { display: none; }
.pe-btn.is-done .pe-btn__done { display: inline-block; }
.pe-btn--secondary.is-done { color: var(--pe-success-fg); border-color: var(--pe-success-solid); } /* 8.12:1; border 5.42:1 */
.pe-btn--secondary.is-waiting,
.pe-btn--secondary.is-waiting:hover {
  background: var(--pe-surface-sunken); border-color: var(--pe-neutral-300);
  color: var(--pe-text-muted); cursor: not-allowed; transform: none;
}

/* B2: the email field is locked while the request is in flight, so the
   confirmation can only name the address actually sent. #161C23 on #F4F6F8
   is 15.83:1. readonly, not disabled: it stays focusable and announced. */
form#frm_Forgot .pe-input[readonly] { background: var(--pe-surface-sunken); }

.pe-field--last { margin-block-end: var(--pe-space-24); }

/* A read-only line naming the account whose password is being set. */
.pe-auth__account { margin: 0 0 var(--pe-space-24); font-size: var(--pe-fs-sm);
                    line-height: var(--pe-lh-snug); color: var(--pe-text-muted); text-align: start; }

/* "Checking your link" while the token is validated. */
.pe-auth__checking { display: flex; align-items: center; gap: var(--pe-space-12);
                     margin: 0; color: var(--pe-text-muted); font-size: var(--pe-fs-sm);
                     line-height: var(--pe-lh-snug); }
/* hidden when the check itself could not answer (display:flex beats [hidden]) */
.pe-auth__checking[hidden] { display: none; }
.pe-auth__checking::before {
  content: ""; width: 18px; height: 18px; flex: 0 0 auto; border-radius: 50%;
  border: 2.5px solid var(--pe-brand-600); border-top-color: transparent;
  animation: pe-spin .7s linear infinite;
}

/* THE PASSWORD RULES — hidden until the New password field is first
   focused; once shown, the panel STAYS (O-T1: hiding it on blur moved the
   Confirm field under the finger tapping it). Each state differs in more than
   colour: pending grey regular + ring-and-dot; met green semibold + tick;
   failed red semibold + cross + WAVY UNDERLINE (O-G1, separates met from
   failed in greyscale); plus hidden "done" / "not yet" text. */
.pe-pwrules {
  margin-block-start: var(--pe-space-8);
  padding: var(--pe-space-12);
  background: var(--pe-surface-sunken);      /* #F4F6F8 */
  border-radius: var(--pe-radius-md);
  font-size: var(--pe-fs-caption);
  line-height: var(--pe-lh-snug);
  text-align: start;
}
.pe-pwrules ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--pe-space-4); }
.pe-pwrules li { display: flex; align-items: flex-start; gap: var(--pe-space-8);
                 color: var(--pe-text-muted); }                          /* 6.27:1 on #F4F6F8 */
/* the "not common" line is in the markup from load, hidden until the server
   refuses a password - display:flex above would otherwise override [hidden] */
.pe-pwrules li[hidden] { display: none; }
.pe-pwrules .pe-icon { width: 18px; height: 18px; margin-block-start: 0; color: var(--pe-text-muted); }
.pe-pwrules li.is-met             { color: var(--pe-success-fg); font-weight: var(--pe-fw-semibold); } /* 7.50:1 */
.pe-pwrules li.is-met .pe-icon    { color: var(--pe-success-fg); }
.pe-pwrules li.is-failed          { color: var(--pe-danger-fg); font-weight: var(--pe-fw-semibold); }  /* 8.29:1 */
.pe-pwrules li.is-failed .pe-icon { color: var(--pe-danger-fg); }
.pe-pwrules li.is-failed .pe-pwrules__text {
  text-decoration-line: underline;
  text-decoration-style: wavy;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}
/* Rule B's tip: ordinary helper text in the panel, shown whenever the panel
   is (fourth round). */
.pe-pwrules__tip { margin: var(--pe-space-8) 0 0; color: var(--pe-text-muted); }   /* 6.27:1 on #F4F6F8 */

/* Views: exactly one is shown; [hidden] also removes the others from the
   accessibility tree, so there is only ever one h1. */
[data-view][hidden] { display: none !important; }

/* THIS PAGE ONLY (sixth and seventh rounds). The card grows downward when the
   rules panel opens, so a desktop page can become taller than the window
   mid-typing; the scrollbar that then appears pushed the centred card ~10px
   sideways. Reserving it on BOTH edges from the start keeps the card exactly
   on Login's centre. Only from 992px: below that Chrome's reserved gutter made
   the card narrower than Login's. The root is painted navy so the gutter is
   navy in a frame too. Residual, proposed to accept (review item 14): a desktop
   window narrowed to 769-991px can still show the shift. */
@media (min-width: 992px) {
  html.pe-page-forgot { scrollbar-gutter: stable both-edges; background: var(--pe-brand-900); }   /* #0C2A41 */
}

/* ==========================================================================
   4d. FREE TRIAL — moved onto this shell 6 Oct (founders' escalation), Mahenoor
   freetrial.aspx only, through body.pe-auth--trial. Existing tokens only: no
   new colour, font or size. Carried into design/css/propedge-auth.css by
   Ayaz, 6 Oct.
   ========================================================================== */

/* The wider card the header of this file always reserved for Free Trial.
   The strip above it follows, because it reads the same variable. */
body.pe-auth.pe-auth--trial { --pe-auth-w: 640px; }

/* Two fields a row from 768px (First/Last, Email/Mobile, Password/Confirm);
   Company, Address and Country span the row. One column below 768px - the
   same fields reflow, nothing is hidden. */
.pe-trial__grid { display: grid; grid-template-columns: minmax(0, 1fr); column-gap: var(--pe-space-16); }
@media (min-width: 768px) {
  .pe-trial__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pe-trial__full { grid-column: 1 / -1; }
}
.pe-trial__submit { margin-block-start: var(--pe-space-8); }

/* freetrial.js toggles "d-none" (Bootstrap's name) on the spinner and the
   "checking…" notes; Bootstrap is no longer on the page. */
body.pe-auth--trial .d-none { display: none !important; }

/* "checking…" while the duplicate check runs: its OWN line under the hint (a
   sibling in the .pe-field column), never run into the hint's sentence.
   Errors use the shared .pe-field.is-invalid + .pe-error, as on Login. */
.pe-trial__checking { font-weight: var(--pe-fw-semibold); color: var(--pe-text-link); }   /* 6.91:1 on white */

/* The Sign Up button's own spinner (sp_FreeTrialSignUpSpinner) - the ring of
   .pe-btn.is-loading, as an element because freetrial.js shows and hides it. */
.pe-trial__spinner {
  display: inline-block; width: 18px; height: 18px; flex: 0 0 auto;
  border: 2.5px solid currentColor; border-top-color: transparent; border-radius: 50%;
  animation: pe-spin .7s linear infinite;
}

/* common.js PageLoading(): during the request a layer covers the page so
   nothing else can be pressed. On this page the button's spinner is the
   visible signal, so the layer is clear and draws no second spinner. Fixed,
   so it never becomes the shell's last in-flow child (section 1). */
body.pe-auth--trial > .centered-div-for-loading { position: fixed; inset: 0; z-index: var(--pe-z-modal); cursor: progress; }
body.pe-auth--trial > .centered-div-for-loading .pe-spinner { display: none; }

/* "Check your email" - the second view of the card */
.pe-trial__sent-icon { color: var(--pe-brand-600); margin-block-end: var(--pe-space-12); }
.pe-auth--trial .pe-auth__sub, .pe-auth--trial .pe-auth__lede { text-wrap: pretty; }

/* ---------------------------------------------------------------------------
   THE MOBILE FIELD — intl-tel-input 23.1.0 (vendored; its stylesheet is a
   written L1 exception, Sameera 6 Oct). Restyled here to .pe-input: border,
   radius, font, focus ring and the country list. A phone number is ONE
   left-to-right run in both languages (W3-02): the wrapper is dir="ltr" and
   freetrial.js builds the widget as LTR, so the widget's own [dir=rtl]
   rules - which match the Arabic page root - are undone inside the wrapper.
   --------------------------------------------------------------------------- */
.pe-trial__phone .iti { display: block; width: 100%; }
.pe-trial__phone .iti--allow-dropdown input.iti__tel-input[type="tel"] { padding-right: var(--pe-space-12); }
.pe-trial__phone .iti__country-container { padding: 1px; }
.pe-trial__phone .iti__selected-country { border-radius: var(--pe-radius-md) 0 0 var(--pe-radius-md); }
.pe-trial__phone .iti__selected-country-primary { padding-inline: var(--pe-space-12) var(--pe-space-4); border-radius: inherit; }
.pe-trial__phone .iti--allow-dropdown .iti__country-container .iti__selected-country-primary:hover { background-color: var(--pe-surface-sunken); }
.pe-trial__phone .iti__arrow { border-top-color: var(--pe-text); }
.pe-trial__phone .iti__arrow--up { border-bottom-color: var(--pe-text); }
.pe-trial__phone .iti .iti__selected-dial-code {
  font-size: var(--pe-fs-base); color: var(--pe-text-strong);
  direction: ltr; unicode-bidi: isolate;                 /* BUG-G5-2: never "968+" */
}
[dir="rtl"] .pe-trial__phone .iti--allow-dropdown .iti__country-container { right: auto; left: 0; }
/* the digits sit against "+968", as in an LTR prefix group (propedge-components.css) */
[dir="rtl"] .pe-trial__phone .pe-input { text-align: left; }
[dir="rtl"] .pe-trial__phone .iti__arrow { margin-right: 0; margin-left: 6px; }
[dir="rtl"] .pe-trial__phone .iti .iti__selected-dial-code { margin-right: 0; margin-left: 4px; }

/* The country list - inline under the field on desktop; on a phone the widget
   moves it to a full-screen layer on <body>, so these are not scoped to the
   wrapper. The list's names are the library's English (its own i18n is not
   loaded); the dial codes stay LTR in it too. */
.pe-auth--trial .iti__dropdown-content {
  border: 1px solid var(--pe-border); border-radius: var(--pe-radius-md);
  box-shadow: var(--pe-shadow-lg); background: var(--pe-surface);
  font-size: var(--pe-fs-sm); color: var(--pe-text); overflow: hidden;
}
.pe-auth--trial .iti__search-input {
  min-height: var(--pe-control-h-md); padding: var(--pe-space-8) var(--pe-space-12);
  font: inherit; color: var(--pe-text-strong); border-radius: 0;
}
.pe-auth--trial .iti__search-input:focus { outline: none; box-shadow: inset var(--pe-focus-ring); }
.pe-auth--trial .iti__search-input + .iti__country-list { border-top-color: var(--pe-border); }
.pe-auth--trial .iti__country { padding: var(--pe-space-8) var(--pe-space-12); }
.pe-auth--trial .iti__country.iti__highlight { background-color: var(--pe-brand-50); }
.pe-auth--trial .iti__dial-code { color: var(--pe-text-muted); direction: ltr; unicode-bidi: isolate; }
/* In Arabic the LIST reads right to left (flag, Arabic name, then "+968"), even
   though it opens from the LTR number field; only the number itself stays LTR. */
[dir="rtl"] .pe-auth--trial .iti__dropdown-content { direction: rtl; text-align: right; }

/* ==========================================================================
   5. NARROW SCREENS — 375px reference width
   ========================================================================== */
@media (max-width: 575.98px) {
  body.pe-auth { padding-block: var(--pe-space-20); }
  .pe-auth__card { border-radius: var(--pe-radius-lg); padding: var(--pe-space-24); }
  .pe-auth__brand img { height: 32px; }
  .pe-auth__title { font-size: var(--pe-fs-h3); }   /* 22px, not 28px */
}

/* 320px is the WCAG 1.4.10 reflow floor. Nothing may scroll sideways there. */
@media (max-width: 359.98px) {
  body.pe-auth { --pe-auth-gutter: var(--pe-space-12); }
  .pe-auth__card { padding: var(--pe-space-20); }
}

/* ==========================================================================
   6. MOTION — respect the user's setting
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  .pe-auth *, .pe-auth *::before, .pe-auth *::after {
    animation-duration: .001ms !important; transition-duration: .001ms !important;
  }
}

/* TOUCH TARGETS (look-and-feel #9, 14 Oct): on a touch screen every link on the public pages
   has a 44 x 44 px tap area. Same technique as propedge-app.css: an invisible ::after around
   the text, layout unchanged; buttons grow to 44 px. */
@media (pointer: coarse) {
  .pe-auth .pe-btn { min-height: var(--pe-tap-min); }
  .pe-auth__skip { min-height: var(--pe-tap-min); display: inline-flex; align-items: center; }
  .pe-auth__foot a { display: inline-block; }   /* a link that wrapped over two lines had no single tap box */
  .pe-auth__card a:not(.pe-btn), .pe-auth__top a:not(.pe-btn):not(.pe-auth__skip), .pe-pubfoot a { position: relative; }
  .pe-auth__card a:not(.pe-btn)::after, .pe-auth__top a:not(.pe-btn)::after, .pe-pubfoot a::after {
    content: ""; position: absolute;
    inset-block: min(0px, calc((100% - var(--pe-tap-min)) / 2));
    inset-inline: min(0px, calc((100% - var(--pe-tap-min)) / 2));
  }
}

/* ==========================================================================
   LEGAL PAGES - terms.aspx and privacy.aspx (founders' D88, 26 Oct 2026).
   The auth shell with a wider card for reading; plain document typography.
   Existing tokens only.
   ========================================================================== */
body.pe-auth.pe-auth--legal { --pe-auth-w: 760px; }
.pe-legal { line-height: 1.65; }
.pe-legal__date { margin: 0 0 var(--pe-space-24); color: var(--pe-text-muted); }
.pe-legal h2 { font-size: var(--pe-fs-h4); font-weight: var(--pe-fw-semibold); margin: var(--pe-space-24) 0 var(--pe-space-8); }
.pe-legal p, .pe-legal li { text-wrap: pretty; }
.pe-legal p { margin: 0 0 var(--pe-space-12); }
.pe-legal ul { margin: 0 0 var(--pe-space-12); padding-inline-start: var(--pe-space-24); }
.pe-legal li { margin-block-end: var(--pe-space-4); }
.pe-legal a { overflow-wrap: anywhere; }

/* Free trial acknowledgements (D88): two required tick boxes under the password. */
.pe-trial__consent { border: 0; margin: var(--pe-space-16) 0 0; padding: 0; display: grid; gap: var(--pe-space-12); }
.pe-trial__consent legend { padding: 0; margin-block-end: var(--pe-space-4); font-weight: var(--pe-fw-semibold); }
.pe-trial__check { display: flex; flex-direction: row; align-items: flex-start; gap: var(--pe-space-8); min-height: var(--pe-tap-min); }
.pe-trial__check input[type="checkbox"] { inline-size: 20px; block-size: 20px; margin-block-start: 2px; flex: 0 0 auto; accent-color: var(--pe-brand-600); }
.pe-trial__check label { cursor: pointer; }
.pe-field.is-invalid .pe-trial__check input[type="checkbox"], .pe-trial__check input[aria-invalid="true"] { outline: 2px solid var(--pe-danger-fg); outline-offset: 2px; }
