/* Yazdfoam authentication layout v8 | isolated from storefront grid and responsive rules */
/* Prefer the site's existing Yekan Bakh webfont. Vazirmatn is an optional web fallback. */
html[lang="fa"] body#login,
html[lang="ar"] body#login {
  --yf-auth-font: 'yekan', 'Vazirmatn', 'Noto Sans Arabic', Tahoma, sans-serif;
}
html[lang="en"] body#login {
  --yf-auth-font: 'Inter', system-ui, 'Segoe UI', Arial, sans-serif;
}
body#login {
  --yf-ink: #142f3c;
  --yf-muted: #607987;
  --yf-line: #dce7ea;
  --yf-primary: #116e76;
  --yf-primary-dark: #09545c;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: flex-start !important;
  min-height: 100svh !important;
  height: auto !important;
  margin: 0 !important;
  padding: 28px 20px 44px !important;
  overflow-x: hidden;
  direction: inherit;
  background: radial-gradient(circle at 12% 10%, #eef5f4 0%, transparent 38%),
              radial-gradient(circle at 90% 93%, #edf5f5 0%, transparent 32%),
              #f7f9fa !important;
  color: var(--yf-ink) !important;
  font-family: var(--yf-auth-font) !important;
  -webkit-font-smoothing: antialiased;
  font-synthesis: none;
}
body#login *, body#login *::before, body#login *::after { box-sizing: border-box; }
body#login .yf-auth,
body#login .yf-auth input,
body#login .yf-auth button,
body#login .yf-auth a,
body#login .yf-auth label,
body#login .yf-auth p,
body#login .yf-auth h1,
body#login .yf-auth span,
body#login .yf-auth small,
body#login .yf-auth-locales,
body#login .yf-auth-locales a {
  font-family: var(--yf-auth-font) !important;
}
body#login .yf-auth {
  width: 100%;
  max-width: 520px;
  flex: none;
  margin: 0 auto;
  direction: inherit;
  line-height: 1.7;
}
body#login .yf-auth-card {
  width: 100%;
  position: relative;
  overflow: hidden;
  margin: 0;
  padding: 27px 42px 26px;
  background: #fff;
  border: 1px solid #e2e9eb;
  border-radius: 23px;
  box-shadow: 0 18px 55px rgba(18, 51, 59, .085), 0 3px 10px rgba(18, 51, 59, .025);
}
body#login .yf-auth-topline {
  position: absolute;
  top: 0; right: 0; left: 0;
  height: 4px;
  background: linear-gradient(90deg,#0d7379,#62baa8);
}
body#login .yf-auth a { color: var(--yf-primary); text-decoration: none; }
body#login .yf-auth a:hover { color: var(--yf-primary-dark); text-decoration: underline; }
body#login .yf-auth-logo {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  height: 80px;
  margin: 0 auto 14px;
  text-decoration: none !important;
}
body#login .yf-auth-logo img {
  display: block;
  width: auto;
  height: auto;
  max-width: 175px;
  max-height: 75px;
  object-fit: contain;
}
body#login .yf-auth-progress {
  display: flex;
  direction: inherit;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 0 auto 21px;
}
body#login .yf-auth-progress__point {
  display: grid;
  place-items: center;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid #e3ebee;
  background: #edf2f4;
  color: #718793;
  font-size: 13px;
  font-weight: 700;
  font-family: 'Inter', Arial, sans-serif !important;
  line-height: 1;
}
body#login .yf-auth-progress__point.is-current,
body#login .yf-auth-progress__point.is-complete {
  color: #fff;
  background: var(--yf-primary);
  border-color: var(--yf-primary);
}
body#login .yf-auth-progress__line { width: 84px; height: 2px; background: #e0e8eb; }
body#login .yf-auth-progress__line.is-complete { background: var(--yf-primary); }
body#login .yf-auth-title {
  margin: 0 0 5px !important;
  color: var(--yf-ink) !important;
  text-align: center !important;
  font-size: 24px !important;
  line-height: 1.6 !important;
  font-weight: 800 !important;
  letter-spacing: normal;
}
body#login .yf-auth-subtitle {
  margin: 0 auto 25px !important;
  color: var(--yf-muted) !important;
  text-align: center !important;
  font-size: 13px !important;
  font-weight: 400;
  line-height: 1.95;
}
body#login .yf-auth-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
  width: 100%;
}
body#login .yf-auth-field {
  display: flex;
  flex-direction: column;
  gap: 0;
  min-width: 0;
  width: 100%;
  margin: 0 0 17px !important;
  text-align: start;
}
body#login .yf-auth-field label {
  display: block;
  width: 100%;
  margin: 0 0 8px !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  color: #2a424c !important;
  line-height: 1.65;
  text-align: start !important;
}
body#login .yf-auth-field > small {
  color: #718894;
  font-size: 11px;
  line-height: 1.8;
  margin-top: 5px;
}
body#login .yf-auth-field input:not([type="checkbox"]) {
  display: block;
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  height: 49px !important;
  min-height: 49px !important;
  margin: 0 !important;
  padding: 11px 14px !important;
  border: 1px solid #d5e0e4 !important;
  border-radius: 11px !important;
  background: #fcfdfd !important;
  color: #1c3541 !important;
  outline: none !important;
  box-shadow: none !important;
  line-height: 1.55 !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  text-align: start;
  transition: border-color .2s ease, box-shadow .2s ease;
}
body#login .yf-auth-field input:not([type="checkbox"]):hover { border-color: #b6cbd0 !important; }
body#login .yf-auth-field input:not([type="checkbox"]):focus {
  border-color: #16838a !important;
  box-shadow: 0 0 0 3px rgba(17,110,118,.10) !important;
  background: #fff !important;
}
body#login .yf-auth-field input::placeholder { color: #9badb4 !important; opacity: 1; }
body#login .yf-auth-field input[dir="ltr"] {
  direction: ltr !important;
  text-align: left !important;
  font-family: 'Inter', 'Segoe UI', Arial, sans-serif !important;
  letter-spacing: .2px;
}
body#login .yf-auth-password-wrapper { display: block; position: relative; width: 100%; min-width: 0; }
/* LTR/RTL password text uses the same logical padding and icon position. */
body#login .yf-auth-password-wrapper input:not([type="checkbox"]) { padding-inline-end: 52px !important; }
body#login .yf-auth-reveal {
  position: absolute;
  z-index: 2;
  top: 50%;
  inset-inline-end: 8px;
  transform: translateY(-50%);
  display: flex;
  justify-content: center;
  align-items: center;
  width: 36px;
  height: 36px;
  min-width: 36px;
  margin: 0 !important;
  padding: 7px !important;
  border: 0 !important;
  border-radius: 9px !important;
  box-shadow: none !important;
  color: #68828b !important;
  background: transparent !important;
  cursor: pointer;
}
body#login .yf-auth-reveal:hover { background: #e9f3f3 !important; color: var(--yf-primary) !important; }
body#login .yf-auth-reveal svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
body#login .yf-auth-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
  margin: 3px 0 20px !important;
  padding: 0;
  line-height: 1.9;
  text-align: start;
  cursor: pointer;
  font-size: 12px;
  color: #536b75;
}
body#login .yf-auth-check input[type="checkbox"] {
  appearance: checkbox !important;
  -webkit-appearance: checkbox !important;
  display: inline-block !important;
  position: static !important;
  opacity: 1 !important;
  visibility: visible !important;
  flex: 0 0 17px;
  width: 17px !important;
  min-width: 17px !important;
  height: 17px !important;
  min-height: 17px !important;
  margin: 5px 0 0 !important;
  padding: 0 !important;
  accent-color: var(--yf-primary);
  cursor: pointer;
}
body#login .yf-auth-check span { flex: 1; min-width: 0; }
body#login .yf-auth-primary,
body#login .yf-auth-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 49px;
  padding: 11px 15px;
  border-radius: 11px;
  cursor: pointer;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.55 !important;
  text-align: center;
  transition: background .2s ease, transform .2s ease, box-shadow .2s ease;
}
body#login .yf-auth-primary {
  margin: 2px 0 0 !important;
  border: 1px solid #116e76 !important;
  color: #fff !important;
  background: #116e76 !important;
  box-shadow: 0 5px 15px rgba(17,110,118,.15) !important;
}
body#login .yf-auth-primary:hover:not(:disabled) { background: #09545c !important; transform: translateY(-1px); }
body#login .yf-auth-primary:disabled { cursor: wait; opacity: .55; }
body#login .yf-auth-secondary {
  margin: 12px 0 0 !important;
  border: 1px solid #cce3e1 !important;
  color: #116e76 !important;
  background: #eef7f5 !important;
  box-shadow: none !important;
}
body#login .yf-auth-secondary:disabled { opacity: .5; cursor: not-allowed; }
body#login .yf-auth-primary:focus-visible,
body#login .yf-auth-secondary:focus-visible,
body#login .yf-auth-reveal:focus-visible { outline: 3px solid #83ccbd !important; outline-offset: 2px; }
body#login .yf-auth-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: center;
  gap: 12px;
  margin: 23px 0 0;
  padding: 20px 0 0;
  border-top: 1px solid #eef1f2;
  font-size: 12px;
  line-height: 1.85;
}
body#login .yf-auth-links a { min-width: 0; }
body#login .yf-auth-links a:first-child { text-align: start; }
body#login .yf-auth-links a:last-child { text-align: end; }
body#login .yf-auth-forgot { display: block; text-align: end; font-size: 12px; margin: -2px 0 17px; }
body#login .yf-auth-message {
  padding: 12px 14px;
  margin: 0 0 18px;
  border: 1px solid #beded4;
  border-radius: 11px;
  background: #f1faf6;
  color: #176447;
  font-size: 12px;
  line-height: 1.8;
  text-align: start;
}
body#login .yf-auth-message.is-error { color: #a73c43; border-color: #f2ced0; background: #fff5f5; }
body#login .yf-auth [hidden] { display: none !important; }
body#login .yf-auth-phone-review {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin: 0 0 22px;
  padding: 11px 13px;
  border: 1px solid #d5e5e5;
  border-radius: 11px;
  background: #f5f9f9;
  color: #153342;
  direction: ltr;
  font-weight: 700;
}
body#login .yf-auth-phone-review [data-auth-phone] { font-family: 'Inter', Arial, sans-serif !important; letter-spacing: .3px; }
body#login .yf-auth-phone-review button {
  padding: 7px 9px;
  margin: 0 !important;
  border: 0 !important;
  border-radius: 8px;
  background: transparent !important;
  color: var(--yf-primary) !important;
  font-size: 12px;
  cursor: pointer;
}
body#login .yf-auth-phone-review button:hover { background: #e7f1f1 !important; }
body#login .yf-auth-field input.yf-auth-code {
  direction: ltr !important;
  text-align: center !important;
  letter-spacing: 9px !important;
  font-family: 'Inter', Arial, sans-serif !important;
  font-weight: 700 !important;
  font-size: 23px !important;
}
body#login .yf-auth-countdown {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 16px;
  font-size: 12px;
  color: var(--yf-muted);
}
body#login .yf-auth-countdown strong {
  flex: none;
  min-width: 68px;
  padding: 5px 9px;
  border-radius: 8px;
  border: 1px solid #d9e9e6;
  background: #edf7f4;
  color: #126971;
  font-family: 'Inter', Arial, sans-serif !important;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  text-align: center;
}
body#login .yf-auth-countdown.is-expired strong { color: #a43e39; border-color: #f7d5d0; background: #fff3f1; }
body#login .yf-auth-hint,body#login .yf-auth-secure {
  text-align: center;
  color: #6c8290;
  font-size: 12px;
  line-height: 1.85;
  margin: 11px 0 0;
}
body#login .yf-auth-secure { font-size: 11px; color: #84969e; }
body#login .yf-auth-locales {
  position: static !important;
  inset: auto !important;
  left: auto !important;
  transform: none !important;
  display: inline-flex;
  flex: none;
  justify-content: center;
  align-items: center;
  gap: 3px;
  max-width: 100%;
  min-height: 38px;
  margin: 0 auto 18px !important;
  padding: 4px !important;
  border: 1px solid #e1e8e9;
  border-radius: 99px !important;
  background: #fff;
  box-shadow: 0 3px 13px rgba(18,51,59,.045);
  white-space: nowrap;
  direction: ltr;
  z-index: 9;
}
body#login .yf-auth-locales a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 13px !important;
  margin: 0 !important;
  border-radius: 99px;
  background: transparent;
  color: #607987 !important;
  text-align: center;
  text-decoration: none !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  line-height: 1.65;
}
body#login .yf-auth-locales a[aria-current="page"] {
  color: #0b6169 !important;
  background: #eaf5f3;
  font-weight: 700 !important;
  text-decoration: none !important;
}
@media (max-width: 600px) {
  body#login { padding: 17px 14px 29px !important; }
  body#login .yf-auth-locales { margin-bottom: 14px !important; }
  body#login .yf-auth-card { padding: 24px 23px 23px; border-radius: 19px; }
  body#login .yf-auth-logo { height: 70px; margin-bottom: 12px; }
  body#login .yf-auth-logo img { max-height: 67px; max-width: 158px; }
  body#login .yf-auth-title { font-size: 22px !important; }
  body#login .yf-auth-subtitle { margin-bottom: 23px !important; }
  body#login .yf-auth-grid { gap: 10px; }
  body#login .yf-auth-field { margin-bottom: 14px !important; }
  body#login .yf-auth-links { gap: 9px; }
}
@media (max-width: 355px) {
  body#login { padding-inline: 10px !important; }
  body#login .yf-auth-card { padding-inline: 17px; }
  body#login .yf-auth-grid { grid-template-columns: 1fr; gap: 0; }
  body#login .yf-auth-links { grid-template-columns: 1fr; justify-items: center; }
  body#login .yf-auth-links a:first-child, body#login .yf-auth-links a:last-child { text-align: center; }
}
@media (prefers-reduced-motion: reduce) {
  body#login .yf-auth *,body#login .yf-auth *::before,body#login .yf-auth *::after { transition: none !important; }
}

/* OTP placeholder centering v10 — scoped to auth verification, no JS changes.
   Using six centered decorative marks avoids bidi-sensitive text placeholder alignment. */
body#login .yf-auth-otp-input-wrap {
  position: relative;
  width: 100%;
  min-width: 0;
}
body#login .yf-auth-otp-input-wrap input#yf-code {
  display: block;
  width: 100% !important;
  direction: ltr !important;
  text-align: center !important;
  text-indent: 0 !important;
  letter-spacing: 8px !important;
  padding-inline: 18px !important;
  font-variant-numeric: tabular-nums;
}
body#login .yf-auth-otp-input-wrap input#yf-code::placeholder {
  color: transparent !important;
  opacity: 0 !important;
}
body#login .yf-auth-otp-input-wrap .yf-auth-code-guide {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 11px;
  width: 100%;
  pointer-events: none;
  direction: ltr;
  user-select: none;
  -webkit-user-select: none;
}
body#login .yf-auth-otp-input-wrap .yf-auth-code-guide > span {
  display: block;
  flex: 0 0 11px;
  width: 11px;
  height: 3px;
  background: #98aab3;
  border-radius: 5px;
}
body#login .yf-auth-otp-input-wrap input#yf-code:not(:placeholder-shown) + .yf-auth-code-guide {
  visibility: hidden;
}
