.account-page {
  min-height: 70vh;
  padding-block-end: 4.5rem;
  background: var(--brand-surface-warm);
}

.account-hero {
  padding-block: clamp(2.2rem, 5vw, 4rem);
  color: #ffffff;
  background: linear-gradient(115deg, var(--brand-green-deep) 0%, #145b3e 72%, #137448 100%);
}

.account-hero__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.account-eyebrow,
.account-section-kicker {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0;
  color: #b9ebce;
  font-size: 0.83rem;
  font-weight: 700;
}

.account-eyebrow span {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: var(--brand-orange);
}

.account-hero h1 {
  margin: 0.35rem 0 0;
  color: #ffffff;
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 600;
  line-height: 1.35;
}

.account-hero__inner > div:first-child > p:last-child {
  max-width: 42rem;
  margin: 0.6rem 0 0;
  color: rgb(255 255 255 / 78%);
  font-size: 0.94rem;
}

.account-hero__balance {
  display: grid;
  min-width: 13.5rem;
  justify-items: start;
  gap: 0.3rem;
  padding: 1.1rem 1.35rem;
  border: 1px solid rgb(255 255 255 / 22%);
  border-radius: 1rem;
  background: rgb(255 255 255 / 9%);
}

.account-hero__balance > span {
  color: rgb(255 255 255 / 78%);
  font-size: 0.8rem;
}

.account-hero__balance strong {
  color: #ffffff;
  font-size: 1.7rem;
  font-weight: 700;
  line-height: 1.35;
}

.account-hero__balance small {
  font-size: 0.88rem;
  font-weight: 400;
}

.account-hero__balance a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 700;
}

.account-hero__balance a:hover span {
  transform: translateX(-3px);
}

.account-hero__balance a span {
  transition: transform 160ms ease;
}

.account-layout {
  display: grid;
  grid-template-columns: minmax(13rem, 0.29fr) minmax(0, 1fr);
  align-items: start;
  gap: clamp(1.1rem, 2.8vw, 2.3rem);
  padding-block-start: 2rem;
}

.account-sidebar {
  position: sticky;
  inset-block-start: 7rem;
  display: grid;
  gap: 1rem;
  padding: 1.1rem;
  border: 1px solid var(--brand-border);
  border-radius: 1rem;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.account-sidebar__person {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding-block-end: 0.8rem;
  border-bottom: 1px solid var(--brand-border);
}

.account-sidebar__person > span:last-child {
  display: grid;
  line-height: 1.5;
}

.account-sidebar__person strong {
  color: var(--brand-green-deep);
  font-size: 0.9rem;
}

.account-sidebar__person small {
  color: var(--brand-gray);
  font-size: 0.72rem;
}

.account-avatar {
  display: grid;
  width: 2.7rem;
  height: 2.7rem;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  color: var(--brand-green-deep);
  background: var(--brand-green-soft);
  font-size: 1.2rem;
  font-weight: 700;
}

.account-sidebar nav {
  display: grid;
  gap: 0.25rem;
}

.account-sidebar nav a {
  display: flex;
  min-height: 42px;
  align-items: center;
  padding: 0.45rem 0.65rem;
  border-radius: 0.6rem;
  color: var(--brand-gray-dark);
  font-size: 0.82rem;
  font-weight: 600;
}

.account-sidebar nav a:hover,
.account-sidebar nav a:focus-visible {
  color: var(--brand-green-deep);
  background: var(--brand-green-soft);
}

.account-sidebar__note {
  margin: 0;
  padding: 0.7rem;
  border-radius: 0.65rem;
  color: var(--brand-gray-dark);
  background: var(--brand-surface-muted);
  font-size: 0.73rem;
  line-height: 1.8;
}

.account-content {
  display: grid;
  min-width: 0;
  gap: 1rem;
}

.account-demo-notice {
  display: grid;
  gap: 0.12rem;
  padding: 0.85rem 1rem;
  border-inline-start: 3px solid var(--brand-orange);
  border-radius: 0.25rem 0.75rem 0.75rem 0.25rem;
  color: #60451b;
  background: var(--brand-orange-soft);
  font-size: 0.8rem;
  line-height: 1.8;
}

.account-demo-notice strong {
  color: #4f350f;
  font-weight: 700;
}

.account-card {
  scroll-margin-top: 7rem;
  padding: clamp(1.1rem, 2.5vw, 1.7rem);
  border: 1px solid var(--brand-border);
  border-radius: 1rem;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.account-card__heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-block-end: 1.2rem;
}

.account-card__heading > div {
  min-width: 0;
}

.account-section-kicker {
  color: var(--brand-green-dark);
  font-size: 0.75rem;
}

.account-card__heading h2 {
  margin: 0.15rem 0 0;
  color: var(--brand-ink);
  font-size: clamp(1.15rem, 2.5vw, 1.45rem);
  font-weight: 600;
  line-height: 1.5;
}

.account-card__heading p:not(.account-section-kicker) {
  margin: 0.35rem 0 0;
  color: var(--brand-gray);
  font-size: 0.82rem;
  line-height: 1.8;
}

.account-card__icon {
  display: grid;
  width: 2.2rem;
  height: 2.2rem;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 0.7rem;
  color: var(--brand-green-deep);
  background: var(--brand-green-soft);
  font-size: 0.82rem;
  font-weight: 700;
}

.account-card__icon--orange {
  color: #713900;
  background: var(--brand-orange-soft);
}

.account-form,
.account-form__grid {
  display: grid;
  gap: 1rem;
}

.account-form__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.account-field {
  display: grid;
  min-width: 0;
  align-content: start;
  gap: 0.4rem;
}

.account-field--wide {
  grid-column: 1 / -1;
}

.account-field label,
.account-payment-method legend {
  color: var(--brand-ink);
  font-size: 0.82rem;
  font-weight: 700;
}

.account-field label span {
  margin-inline-start: 0.25rem;
  color: var(--brand-gray);
  font-size: 0.71rem;
  font-weight: 400;
}

.account-field label small {
  color: var(--brand-gray);
  font-size: 0.72rem;
  font-weight: 400;
}

.account-field input,
.account-field textarea {
  width: 100%;
  min-height: 2.9rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid #cbd8d1;
  border-radius: 0.68rem;
  outline: none;
  color: var(--brand-ink);
  background: #ffffff;
  font: inherit;
  font-size: 0.84rem;
  line-height: 1.7;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.account-field input:focus,
.account-field textarea:focus {
  border-color: var(--brand-green);
  box-shadow: 0 0 0 4px rgb(0 170 80 / 12%);
}

.account-field input::placeholder,
.account-field textarea::placeholder {
  color: #8a958f;
}

.account-field input[type="file"] {
  min-height: auto;
  padding: 0.55rem;
  color: var(--brand-gray-dark);
  font-size: 0.76rem;
}

.account-field > small {
  color: var(--brand-gray);
  font-size: 0.72rem;
  line-height: 1.7;
}

.account-form__divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--brand-green-deep);
  font-size: 0.84rem;
  font-weight: 700;
}

.account-form__divider::after {
  height: 1px;
  flex: 1;
  background: var(--brand-border);
  content: "";
}

.account-payment-method {
  display: grid;
  gap: 0.55rem;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.account-payment-method legend {
  margin-block-end: 0.45rem;
  padding: 0;
}

.account-payment-method label {
  display: flex;
  min-height: 3rem;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem 0.65rem;
  border: 1px solid var(--brand-border);
  border-radius: 0.68rem;
  cursor: pointer;
}

.account-payment-method input {
  width: 1rem;
  height: 1rem;
  accent-color: var(--brand-green);
}

.account-payment-method label span {
  display: grid;
  line-height: 1.5;
}

.account-payment-method strong {
  color: var(--brand-ink);
  font-size: 0.78rem;
}

.account-payment-method small {
  color: var(--brand-gray);
  font-size: 0.69rem;
}

.account-form__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem 1rem;
  margin-block-start: 0.2rem;
}

.account-button {
  display: inline-flex;
  min-height: 2.85rem;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1rem;
  border: 1px solid transparent;
  border-radius: 0.7rem;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 160ms ease, background-color 160ms ease, border-color 160ms ease;
}

.account-button:hover {
  transform: translateY(-1px);
}

.account-button--primary,
.account-button--charge {
  color: #ffffff;
  background: var(--brand-green);
}

.account-button--primary:hover,
.account-button--charge:hover {
  background: var(--brand-green-dark);
}

.account-button--outline {
  border-color: var(--brand-green);
  color: var(--brand-green-deep);
  background: #ffffff;
}

.account-button--outline:hover {
  background: var(--brand-green-soft);
}

.account-form__actions > p {
  flex: 1 1 15rem;
  margin: 0;
  color: var(--brand-green-deep);
  font-size: 0.78rem;
  line-height: 1.75;
}

.account-empty {
  display: grid;
  justify-items: center;
  padding: 1.7rem 1rem;
  border: 1px dashed #cbd8d1;
  border-radius: 0.8rem;
  text-align: center;
}

.account-empty > span {
  display: grid;
  width: 2.5rem;
  height: 2.5rem;
  place-items: center;
  border-radius: 50%;
  color: var(--brand-green-deep);
  background: var(--brand-green-soft);
  font-size: 1.35rem;
}

.account-empty strong {
  margin-block-start: 0.55rem;
  color: var(--brand-ink);
  font-size: 0.87rem;
}

.account-empty p {
  max-width: 30rem;
  margin: 0.2rem 0 0;
  color: var(--brand-gray);
  font-size: 0.77rem;
  line-height: 1.8;
}

.account-footer {
  padding-block: 1.2rem;
  border-top: 1px solid var(--brand-border);
  background: #ffffff;
}

.account-footer .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  color: var(--brand-gray);
  font-size: 0.76rem;
}

.account-footer a:first-child {
  color: var(--brand-green-deep);
  font-weight: 700;
}

.account-footer a:last-child:hover {
  color: var(--brand-green-dark);
}

@media (max-width: 850px) {
  .account-layout {
    grid-template-columns: 1fr;
  }

  .account-sidebar {
    position: static;
  }

  .account-sidebar nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .account-hero__inner {
    align-items: stretch;
    flex-direction: column;
    gap: 1.25rem;
  }

  .account-hero__balance {
    grid-template-columns: 1fr auto;
    align-items: center;
    min-width: 0;
  }

  .account-hero__balance > span {
    grid-column: 1 / -1;
  }

  .account-hero__balance strong {
    grid-row: 2 / 4;
    grid-column: 1;
  }

  .account-hero__balance a {
    grid-row: 2 / 4;
    grid-column: 2;
    min-height: 2.75rem;
    padding: 0.4rem 0.7rem;
    border-radius: 0.6rem;
    background: var(--brand-green);
  }

  .account-layout {
    padding-block-start: 1rem;
  }

  .account-form__grid {
    grid-template-columns: 1fr;
  }

  .account-field--wide {
    grid-column: auto;
  }

  .account-sidebar nav {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .account-button,
  .account-field input,
  .account-field textarea,
  .account-hero__balance a span {
    transition: none;
  }
}
