:root {
  --ink: #172521;
  --muted: #68766f;
  --line: #dfe6e2;
  --paper: #ffffff;
  --snow: #f7fbff;
  --green: #0d624c;
  --green-dark: #074534;
  --red: #c9142d;
  --gold: #e7b241;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: "Inter", system-ui, sans-serif;
  background:
    radial-gradient(circle at 15% 15%, rgba(231, 178, 65, 0.16), transparent 26rem),
    linear-gradient(135deg, #f9fcff 0%, #eef8f3 50%, #fff7f2 100%);
}

a {
  color: var(--red);
  font-weight: 800;
  text-decoration: none;
}

.auth-shell,
.account-shell {
  width: min(1120px, calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  padding: 32px 0;
}

.auth-shell {
  display: grid;
  align-content: center;
}

.auth-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.auth-brand,
.account-nav > a {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 0;
  color: var(--green-dark);
  font-size: 1.1rem;
  font-weight: 900;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.language-switcher {
  margin: 0;
}

.language-switcher select {
  min-height: 42px;
  min-width: 68px;
  border: 1px solid var(--line);
  border-radius: 999px;
  appearance: none;
  background:
    linear-gradient(45deg, transparent 50%, currentColor 50%) right 15px center / 5px 5px no-repeat,
    linear-gradient(135deg, currentColor 50%, transparent 50%) right 10px center / 5px 5px no-repeat,
    var(--paper);
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  font-weight: 900;
  padding: 0 28px 0 16px;
}

.auth-panel,
.account-panel {
  width: min(560px, 100%);
  padding: clamp(28px, 5vw, 56px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 24px 70px rgba(20, 56, 44, 0.13);
}

.account-panel {
  width: 100%;
}

.auth-eyebrow {
  margin: 0 0 10px;
  color: var(--green);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  color: var(--ink);
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(2.4rem, 7vw, 4.8rem);
  line-height: 0.95;
  letter-spacing: 0;
}

.auth-copy {
  max-width: 34rem;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.65;
}

.auth-form {
  display: grid;
  gap: 18px;
  margin-top: 30px;
}

.oauth-actions {
  display: grid;
  gap: 12px;
  margin-top: 28px;
}

.oauth-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font-weight: 900;
  box-shadow: 0 14px 28px rgba(20, 56, 44, 0.08);
}

.oauth-button:hover {
  border-color: rgba(13, 98, 76, 0.35);
}

.oauth-logo {
  display: block;
  width: 26px;
  height: 26px;
  flex: 0 0 auto;
}

.auth-divider {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  height: 1px;
  background: var(--line);
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

label {
  display: grid;
  gap: 8px;
  color: var(--ink);
  font-size: 0.94rem;
  font-weight: 800;
}

input {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  padding: 0 16px;
}

input:focus {
  border-color: var(--green);
  outline: 3px solid rgba(13, 98, 76, 0.14);
}

small {
  color: var(--red);
  font-weight: 700;
}

.form-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.check-row {
  display: inline-flex;
  grid-template-columns: auto 1fr;
  align-items: center;
  width: fit-content;
}

.check-row input {
  width: 18px;
  min-height: 18px;
}

.auth-consent-row {
  align-items: flex-start;
  color: var(--muted);
  gap: 10px;
  line-height: 1.4;
  width: 100%;
}

.auth-consent-row input {
  flex: 0 0 auto;
  margin-top: 2px;
}

.auth-consent-row a,
.oauth-legal-note a {
  color: var(--green);
  font-weight: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.oauth-legal-note {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 500;
  line-height: 1.45;
  margin: 12px 0 0;
}

.auth-error-summary {
  background: rgba(201, 20, 45, 0.08);
  border: 1px solid rgba(201, 20, 45, 0.2);
  border-radius: 8px;
  color: var(--ink);
  display: grid;
  gap: 8px;
  margin: 18px 0 22px;
  padding: 14px 16px;
}

.auth-error-summary strong {
  color: var(--red);
  font-size: 0.95rem;
  font-weight: 700;
}

.auth-error-summary ul {
  color: var(--muted);
  font-weight: 500;
  line-height: 1.35;
  margin: 0;
  padding-left: 20px;
}

.auth-submit,
.account-nav button {
  min-height: 54px;
  border: 0;
  border-radius: 999px;
  background: var(--red);
  color: white;
  cursor: pointer;
  font: inherit;
  font-weight: 900;
  padding: 0 24px;
  box-shadow: 0 16px 34px rgba(201, 20, 45, 0.22);
}

.auth-alt {
  margin: 24px 0 0;
  color: var(--muted);
  font-weight: 700;
}

.flash-stack {
  display: grid;
  gap: 10px;
  margin-bottom: 22px;
}

.flash {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 14px;
  color: var(--ink);
  background: var(--snow);
  font-weight: 750;
}

.flash-success {
  border-color: rgba(13, 98, 76, 0.24);
  background: rgba(13, 98, 76, 0.08);
}

.flash-danger {
  border-color: rgba(201, 20, 45, 0.24);
  background: rgba(201, 20, 45, 0.08);
}

.flash-warning {
  border-color: rgba(231, 178, 65, 0.34);
  background: rgba(231, 178, 65, 0.12);
}

.account-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.account-nav > a {
  margin: 0;
}

.account-nav button {
  min-height: 44px;
  box-shadow: none;
}

.verify-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 28px;
  border: 1px solid rgba(231, 178, 65, 0.42);
  border-radius: 8px;
  background: rgba(231, 178, 65, 0.12);
  padding: 18px;
}

.verify-banner strong {
  display: block;
  font-size: 1.02rem;
}

.verify-banner p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.verify-banner button {
  min-height: 44px;
  border: 0;
  border-radius: 999px;
  background: var(--green);
  color: white;
  cursor: pointer;
  font: inherit;
  font-weight: 900;
  padding: 0 20px;
  white-space: nowrap;
}

.profile-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 32px 0 0;
}

.profile-list div {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  padding: 18px;
}

.profile-list dt {
  color: var(--muted);
  font-weight: 900;
}

.profile-list dd {
  margin: 8px 0 0;
  font-size: 1.05rem;
  font-weight: 850;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  margin-left: 8px;
  border-radius: 999px;
  padding: 0 10px;
  font-size: 0.78rem;
  font-weight: 900;
}

.status-ok {
  background: rgba(13, 98, 76, 0.1);
  color: var(--green-dark);
}

.status-warn {
  background: rgba(231, 178, 65, 0.18);
  color: #8a6415;
}

@media (max-width: 680px) {
  .field-grid,
  .profile-list {
    grid-template-columns: 1fr;
  }

  .verify-banner {
    align-items: flex-start;
    flex-direction: column;
  }

  .auth-panel,
  .account-panel {
    padding: 24px;
  }
}
