/* =========================================================
   Account — auth forms + profile
   ========================================================= */

.agf-auth {
  --aa-ink: #031012;
  --aa-muted: #6C7A79;
  --aa-line: #EEF1F1;
  --aa-green: #21C77A;
  --aa-green-2: #1aad68;
  --aa-dark: #083D3F;
  direction: rtl;
  padding: 48px 16px 72px;
  background: linear-gradient(180deg, #F3F6F6 0%, #FAFBFB 100%);
  min-height: 60vh;
}

.agf-auth__card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.95fr);
  max-width: 960px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 24px;
  background: #fff;
  border: 1px solid var(--aa-line);
  box-shadow: 0 16px 48px rgba(3, 16, 18, 0.06);
}

.agf-auth__card--solo {
  grid-template-columns: 1fr;
  max-width: 480px;
}

.agf-auth__form {
  padding: clamp(28px, 4vw, 40px);
}

.agf-auth__brand {
  display: flex;
  justify-content: center;
  margin-bottom: 22px;
}

.agf-auth__brand a {
  display: inline-flex;
}

.agf-auth__brand img {
  width: 132px;
  height: auto;
  display: block;
}

.agf-auth__title {
  margin: 0 0 6px;
  text-align: center;
  font-size: clamp(1.25rem, 2.2vw, 1.5rem);
  font-weight: 800;
  color: var(--aa-ink);
  letter-spacing: -0.02em;
}

.agf-auth__lead {
  margin: 0 0 24px;
  text-align: center;
  color: var(--aa-muted);
  font-size: 0.88rem;
  line-height: 1.8;
}

.agf-auth .form-group {
  margin-bottom: 14px;
}

.agf-auth .form-group label,
.agf-auth .control-label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.84rem;
  font-weight: 700;
  color: #2A3535;
}

.agf-auth .form-control {
  height: auto !important;
  min-height: 46px;
  padding: 10px 14px !important;
  border-radius: 12px !important;
  border: 1px solid #DDE2E2 !important;
  background: #FAFBFB !important;
  color: var(--aa-ink) !important;
  font-size: 0.92rem !important;
  box-shadow: none !important;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.agf-auth .form-control:focus {
  border-color: rgba(33, 199, 122, 0.55) !important;
  background: #fff !important;
  outline: none;
}

.agf-auth .text-danger,
.agf-auth .field-validation-error,
.agf-auth .validation-summary-errors {
  font-size: 0.8rem;
  font-weight: 600;
}

.agf-auth .validation-summary-errors ul {
  margin: 0 0 12px;
  padding-right: 18px;
}

.agf-auth__submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 8px;
  padding: 12px 18px;
  border: 0;
  border-radius: 999px;
  background: var(--aa-green);
  color: #031012;
  font-size: 0.95rem;
  font-weight: 800;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s ease, transform 0.2s ease;
}

.agf-auth__submit:hover {
  background: var(--aa-green-2);
  color: #031012;
  transform: translateY(-1px);
}

.agf-auth__submit--ghost {
  background: #fff;
  color: var(--aa-dark);
  border: 1px solid #DDE2E2;
}

.agf-auth__submit--ghost:hover {
  border-color: rgba(33, 199, 122, 0.45);
  background: rgba(33, 199, 122, 0.08);
}

.agf-auth__row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.agf-auth__row .agf-auth__submit {
  width: auto;
  flex: 1;
  min-width: 140px;
}

.agf-auth__divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0;
  color: var(--aa-muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.agf-auth__divider::before,
.agf-auth__divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--aa-line);
}

.agf-auth__links {
  margin-top: 16px;
  text-align: center;
  font-size: 0.86rem;
  color: var(--aa-muted);
  line-height: 1.8;
}

.agf-auth__links a {
  color: var(--aa-dark);
  font-weight: 700;
  text-decoration: none;
}

.agf-auth__links a:hover {
  color: var(--aa-green-2);
}

.agf-auth__aside {
  position: relative;
  min-height: 320px;
  background:
    radial-gradient(ellipse 70% 55% at 50% 40%, rgba(33, 199, 122, 0.22), transparent 70%),
    linear-gradient(165deg, #083D3F 0%, #031012 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 36px 28px;
  text-align: center;
  color: #fff;
}

.agf-auth__aside h2 {
  margin: 0 0 10px;
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.agf-auth__aside p {
  margin: 0;
  max-width: 28ch;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.88rem;
  line-height: 1.85;
}

.agf-auth__msg {
  text-align: center;
  padding: 12px 0 8px;
}

.agf-auth__msg-ico {
  width: 56px;
  height: 56px;
  margin: 0 auto 16px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(33, 199, 122, 0.14);
  color: var(--aa-dark);
  font-size: 1.35rem;
}

.agf-auth__msg-ico.is-warn {
  background: rgba(220, 53, 69, 0.12);
  color: #c0392b;
}

.agf-auth__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 22px;
}

.agf-auth__actions .agf-auth__submit {
  width: auto;
  min-width: 140px;
}

@media (max-width: 991.98px) {
  .agf-auth__card {
    grid-template-columns: 1fr;
  }

  .agf-auth__aside {
    display: none;
  }
}

/* ----- Profile ----- */
.agf-profile {
  --aa-ink: #031012;
  --aa-muted: #6C7A79;
  --aa-line: #EEF1F1;
  --aa-green: #21C77A;
  --aa-dark: #083D3F;
  direction: rtl;
  padding: 40px 0 72px;
  background: #F6F8F8;
}

.agf-profile__wrap {
  max-width: 960px;
  margin: 0 auto;
}

.agf-profile__hero {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 22px;
  align-items: center;
  padding: 28px;
  margin-bottom: 18px;
  border-radius: 22px;
  background: #fff;
  border: 1px solid var(--aa-line);
  box-shadow: 0 10px 32px rgba(3, 16, 18, 0.04);
}

.agf-profile__avatar {
  position: relative;
  width: 108px;
  height: 108px;
  flex-shrink: 0;
}

.agf-profile__avatar img {
  width: 108px;
  height: 108px;
  object-fit: cover;
  border-radius: 28px;
  border: 3px solid #fff;
  box-shadow: 0 8px 24px rgba(3, 16, 18, 0.12);
  background: #E8EEEE;
}

.agf-profile__avatar-btn {
  position: absolute;
  left: 50%;
  bottom: -8px;
  transform: translateX(-50%);
  padding: 5px 12px;
  border-radius: 999px;
  background: #031012;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
  overflow: hidden;
  white-space: nowrap;
}

.agf-profile__avatar-btn input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.agf-profile__meta h1 {
  margin: 0 0 4px;
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--aa-ink);
}

.agf-profile__meta p {
  margin: 0 0 4px;
  color: var(--aa-muted);
  font-size: 0.88rem;
}

.agf-profile__balance {
  margin-top: 10px;
  font-size: 0.9rem;
  color: var(--aa-muted);
  font-weight: 600;
}

.agf-profile__balance strong {
  color: var(--aa-dark);
  font-size: 1.15rem;
  font-weight: 800;
}

.agf-profile__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 18px;
  border-radius: 999px;
  background: var(--aa-green);
  color: #031012;
  font-size: 0.86rem;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.2s ease;
}

.agf-profile__cta:hover {
  background: #1aad68;
  color: #031012;
}

.agf-profile__panel {
  padding: 24px 26px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid var(--aa-line);
  box-shadow: 0 10px 32px rgba(3, 16, 18, 0.04);
}

.agf-profile__panel h2 {
  margin: 0 0 18px;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--aa-ink);
}

.agf-profile__rows {
  display: grid;
  gap: 0;
}

.agf-profile__row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid #F0F3F3;
  align-items: center;
}

.agf-profile__row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.agf-profile__row:first-child {
  padding-top: 0;
}

.agf-profile__row dt {
  margin: 0;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--aa-muted);
}

.agf-profile__row dd {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--aa-ink);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.agf-profile__row a {
  color: var(--aa-dark);
  text-decoration: none;
}

.agf-profile__row a:hover {
  color: var(--aa-green);
}

.agf-profile__ok {
  color: var(--aa-green);
}

.agf-profile__bad {
  color: #c0392b;
}

.agf-profile__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.agf-profile__nav a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--aa-line);
  background: #FAFBFB;
  color: var(--aa-dark);
  font-size: 0.8rem;
  font-weight: 700;
  text-decoration: none;
}

.agf-profile__nav a:hover {
  border-color: rgba(33, 199, 122, 0.4);
  background: rgba(33, 199, 122, 0.08);
}

@media (max-width: 767.98px) {
  .agf-profile__hero {
    grid-template-columns: 1fr;
    text-align: center;
    justify-items: center;
  }

  .agf-profile__row {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .agf-profile__row dd {
    justify-content: center;
  }
}
