:root {
  --pgp-bg: #04080f;
  --pgp-bg-soft: rgba(7, 20, 30, 0.9);
  --pgp-surface: rgba(10, 18, 28, 0.78);
  --pgp-surface-strong: rgba(14, 25, 38, 0.96);
  --pgp-border: rgba(117, 230, 255, 0.14);
  --pgp-border-strong: rgba(117, 230, 255, 0.28);
  --pgp-text: #ebf6ff;
  --pgp-text-soft: rgba(224, 241, 255, 0.72);
  --pgp-text-muted: rgba(173, 205, 224, 0.56);
  --pgp-accent: #7bf1ff;
  --pgp-accent-strong: #1ce4ff;
  --pgp-accent-dark: #08212c;
  --pgp-shadow: 0 26px 80px rgba(0, 0, 0, 0.34);
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top, rgba(28, 228, 255, 0.12), transparent 38%),
    radial-gradient(circle at 84% 14%, rgba(31, 96, 255, 0.16), transparent 28%),
    linear-gradient(180deg, #02060b 0%, #07111c 52%, #04080f 100%);
  color: var(--pgp-text);
  font-family: "Inter", sans-serif;
}

html[dir="rtl"] body {
  font-family: "Cairo", "Inter", sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

.pgp-auth-shell {
  position: relative;
  overflow: hidden;
}

.pgp-auth-shell::before,
.pgp-auth-shell::after {
  content: "";
  position: fixed;
  inset: auto;
  pointer-events: none;
  border-radius: 999px;
  filter: blur(48px);
  opacity: 0.55;
}

.pgp-auth-shell::before {
  top: -8rem;
  left: -6rem;
  width: 18rem;
  height: 18rem;
  background: rgba(28, 228, 255, 0.2);
}

.pgp-auth-shell::after {
  right: -7rem;
  bottom: 10%;
  width: 22rem;
  height: 22rem;
  background: rgba(63, 108, 255, 0.18);
}

.pgp-auth-header {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(20px);
  background: rgba(4, 8, 15, 0.72);
  border-bottom: 1px solid rgba(123, 241, 255, 0.08);
}

.pgp-auth-header-inner,
.pgp-auth-main,
.pgp-auth-footer-inner {
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
}

.pgp-auth-header-inner {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 1rem;
  padding: 1rem 0;
}

.pgp-auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  min-width: 0;
}

.pgp-auth-brand-mark {
  width: 2.7rem;
  height: 2.7rem;
  display: grid;
  place-items: center;
  border-radius: 0.95rem;
  border: 1px solid rgba(123, 241, 255, 0.2);
  background:
    linear-gradient(180deg, rgba(13, 27, 39, 0.95), rgba(8, 17, 27, 0.85));
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.03),
    0 12px 32px rgba(7, 15, 26, 0.42);
  color: var(--pgp-accent);
  font-family: "Orbitron", sans-serif;
  font-size: 1rem;
  letter-spacing: 0.12em;
}

.pgp-auth-brand-copy {
  display: grid;
  gap: 0.15rem;
  min-width: 0;
}

.pgp-auth-brand-copy strong {
  display: block;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  direction: ltr;
  unicode-bidi: isolate;
}

.pgp-auth-brand-copy span {
  color: var(--pgp-text-soft);
  font-size: 0.82rem;
}

.pgp-auth-header-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.8rem;
  min-width: 0;
  flex-wrap: wrap;
}

.pgp-auth-header-links {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.pgp-auth-lang-switcher {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0.3rem;
  border-radius: 999px;
  background: rgba(10, 20, 31, 0.78);
  border: 1px solid rgba(123, 241, 255, 0.1);
  direction: ltr;
}

.pgp-auth-lang-switcher button {
  min-width: 3.15rem;
  min-height: 2.45rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--pgp-text-soft);
  cursor: pointer;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: background 160ms ease, color 160ms ease, transform 160ms ease;
}

.pgp-auth-lang-switcher button:hover {
  transform: translateY(-1px);
  color: var(--pgp-text);
}

.pgp-auth-lang-switcher button.is-active {
  background: linear-gradient(90deg, #7bf1ff, #1ce4ff);
  color: #031018;
}

.pgp-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 0.9rem;
  border-radius: 999px;
  background: rgba(10, 20, 31, 0.78);
  border: 1px solid rgba(123, 241, 255, 0.08);
  color: var(--pgp-text-soft);
  font-size: 0.86rem;
}

.pgp-chip strong {
  color: var(--pgp-text);
  font-weight: 600;
}

.pgp-auth-main {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(320px, 0.98fr);
  gap: 1.5rem;
  padding: 4.25rem 0 3.5rem;
}

.pgp-auth-panel,
.pgp-auth-card {
  position: relative;
  border: 1px solid var(--pgp-border);
  background:
    linear-gradient(180deg, rgba(8, 17, 27, 0.82), rgba(8, 15, 23, 0.9));
  border-radius: 1.75rem;
  box-shadow: var(--pgp-shadow);
}

.pgp-auth-panel {
  padding: 2.2rem;
  overflow: hidden;
}

.pgp-auth-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at top right, rgba(28, 228, 255, 0.12), transparent 28%),
    linear-gradient(135deg, rgba(28, 228, 255, 0.06), transparent 40%);
  pointer-events: none;
}

.pgp-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
  background: rgba(123, 241, 255, 0.08);
  border: 1px solid rgba(123, 241, 255, 0.14);
  color: var(--pgp-accent);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

html[dir="rtl"] .pgp-eyebrow,
html[dir="rtl"] .pgp-auth-card-header span,
html[dir="rtl"] .pgp-auth-divider {
  letter-spacing: 0.04em;
}

html[dir="rtl"] .pgp-eyebrow {
  flex-direction: row-reverse;
}

html[dir="rtl"] .pgp-eyebrow::before {
  background: linear-gradient(270deg, transparent, var(--pgp-accent));
}

.pgp-auth-panel h1 {
  margin: 1.25rem 0 0.9rem;
  max-width: 12ch;
  font-family: "Manrope", sans-serif;
  font-size: clamp(2rem, 5vw, 4.25rem);
  line-height: 0.98;
  letter-spacing: -0.04em;
}

.pgp-auth-panel p {
  margin: 0;
  max-width: 40rem;
  color: var(--pgp-text-soft);
  font-size: 1rem;
  line-height: 1.75;
}

.pgp-auth-bullets,
.pgp-auth-meta {
  display: grid;
  gap: 0.95rem;
  margin-top: 1.8rem;
}

.pgp-auth-bullet,
.pgp-auth-meta-card {
  padding: 1rem 1.1rem;
  border-radius: 1rem;
  background: rgba(12, 22, 33, 0.72);
  border: 1px solid rgba(123, 241, 255, 0.08);
}

.pgp-auth-bullet strong,
.pgp-auth-meta-card strong {
  display: block;
  margin-bottom: 0.25rem;
  font-size: 0.95rem;
}

.pgp-auth-bullet span,
.pgp-auth-meta-card span {
  color: var(--pgp-text-soft);
  font-size: 0.92rem;
}

.pgp-auth-meta {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.pgp-auth-card {
  padding: 1.65rem;
  display: grid;
  gap: 1.15rem;
}

.pgp-auth-card-header {
  display: grid;
  gap: 0.35rem;
}

.pgp-auth-card-header span {
  color: var(--pgp-accent);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.pgp-auth-card-header h2 {
  margin: 0;
  font-family: "Manrope", sans-serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  letter-spacing: -0.03em;
}

.pgp-auth-card-header p {
  margin: 0;
  color: var(--pgp-text-soft);
  font-size: 0.95rem;
}

.pgp-auth-form {
  display: grid;
  gap: 0.95rem;
}

.pgp-field {
  display: grid;
  gap: 0.45rem;
}

.pgp-field label {
  font-size: 0.88rem;
  color: var(--pgp-text-soft);
}

.pgp-field input {
  width: 100%;
  min-height: 3.35rem;
  padding: 0.95rem 1rem;
  border-radius: 1rem;
  border: 1px solid rgba(123, 241, 255, 0.1);
  background: rgba(5, 12, 20, 0.92);
  color: var(--pgp-text);
  font: inherit;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.pgp-field input:focus {
  outline: none;
  border-color: var(--pgp-border-strong);
  box-shadow: 0 0 0 4px rgba(28, 228, 255, 0.09);
  transform: translateY(-1px);
}

.pgp-field input::placeholder {
  color: rgba(173, 205, 224, 0.42);
}

.pgp-auth-error,
.pgp-auth-success {
  display: none;
  padding: 0.85rem 0.95rem;
  border-radius: 0.95rem;
  font-size: 0.92rem;
}

.pgp-auth-error.is-visible,
.pgp-auth-success.is-visible {
  display: block;
}

.pgp-auth-error {
  background: rgba(255, 101, 132, 0.14);
  border: 1px solid rgba(255, 101, 132, 0.24);
  color: #ffd7df;
}

.pgp-auth-success {
  background: rgba(104, 255, 198, 0.14);
  border: 1px solid rgba(104, 255, 198, 0.2);
  color: #d5ffee;
}

.pgp-primary-button,
.pgp-secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 3.35rem;
  padding: 0.95rem 1.25rem;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  border: 0;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, border-color 180ms ease;
}

.pgp-primary-button {
  background: linear-gradient(90deg, #7bf1ff, #1ce4ff);
  color: #031018;
  box-shadow: 0 18px 40px rgba(28, 228, 255, 0.26);
}

.pgp-primary-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 20px 44px rgba(28, 228, 255, 0.3);
}

.pgp-primary-button:disabled {
  opacity: 0.68;
  cursor: wait;
}

.pgp-google-wrap {
  display: grid;
  gap: 0.6rem;
}

.pgp-google-wrap.is-busy {
  opacity: 0.66;
  pointer-events: none;
}

.pgp-google-button {
  min-height: 44px;
}

.pgp-secondary-button {
  background: rgba(255, 255, 255, 0.02);
  color: var(--pgp-text);
  border: 1px solid rgba(123, 241, 255, 0.14);
}

.pgp-secondary-button:hover {
  transform: translateY(-1px);
  border-color: rgba(123, 241, 255, 0.22);
}

.pgp-auth-actions,
.pgp-auth-links {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.pgp-auth-divider {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  color: var(--pgp-text-muted);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.pgp-auth-divider::before,
.pgp-auth-divider::after {
  content: "";
  flex: 1 1 0;
  height: 1px;
  background: rgba(123, 241, 255, 0.08);
}

.pgp-auth-links {
  justify-content: space-between;
  align-items: center;
  color: var(--pgp-text-soft);
  font-size: 0.9rem;
}

.pgp-auth-links a {
  color: var(--pgp-accent);
}

.pgp-auth-footer {
  padding: 0 0 2.25rem;
}

.pgp-auth-footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  color: var(--pgp-text-muted);
  font-size: 0.84rem;
}

.pgp-auth-footer-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

html[dir="rtl"] .pgp-auth-panel,
html[dir="rtl"] .pgp-auth-card,
html[dir="rtl"] .pgp-auth-footer-inner {
  text-align: right;
}

html[dir="rtl"] .pgp-auth-header-tools,
html[dir="rtl"] .pgp-auth-header-links {
  justify-content: flex-start;
}

html[dir="rtl"] .pgp-auth-actions,
html[dir="rtl"] .pgp-auth-links,
html[dir="rtl"] .pgp-auth-footer-links {
  justify-content: flex-start;
}

html[dir="rtl"] .pgp-auth-links {
  align-items: flex-start;
}

html[dir="rtl"] .pgp-auth-bullet,
html[dir="rtl"] .pgp-auth-meta-card,
html[dir="rtl"] .pgp-auth-card-header,
html[dir="rtl"] .pgp-field {
  text-align: right;
}

html[dir="rtl"] .pgp-field input {
  text-align: right;
}

@media (max-width: 960px) {
  .pgp-auth-main {
    grid-template-columns: 1fr;
    padding-top: 3rem;
  }

  .pgp-auth-meta {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .pgp-auth-header-inner,
  .pgp-auth-footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .pgp-auth-header-inner {
    display: flex;
  }

  .pgp-auth-main,
  .pgp-auth-header-inner,
  .pgp-auth-footer-inner {
    width: min(100% - 1.25rem, 1180px);
  }

  .pgp-auth-panel,
  .pgp-auth-card {
    padding: 1.25rem;
    border-radius: 1.4rem;
  }

  .pgp-auth-header-tools {
    width: 100%;
    justify-content: space-between;
  }

  .pgp-auth-header-links {
    width: 100%;
    justify-content: flex-start;
  }

  .pgp-auth-links {
    flex-direction: column;
    align-items: flex-start;
  }
}
