:root {
  --green-950: #052e20;
  --green-900: #0b3b25;
  --green-800: #125a35;
  --green-700: #17733f;
  --green-600: #1b8b4b;
  --green-500: #25a95b;
  --green-100: #dcfce7;
  --green-50: #f0fdf4;
  --ink: #17221c;
  --muted: #647269;
  --surface: #ffffff;
  --canvas: #f1f6f2;
  --border: #dce7df;
  --danger: #c52c2c;
  --warning: #a35b09;
  --shadow: 0 30px 80px rgba(8, 58, 34, 0.15);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
}

body {
  position: relative;
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--canvas);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
}

svg {
  display: block;
}

[hidden] {
  display: none !important;
}

.page-glow {
  position: fixed;
  z-index: -1;
  border-radius: 999px;
  filter: blur(1px);
  pointer-events: none;
}

.page-glow-one {
  top: -260px;
  right: -190px;
  width: 610px;
  height: 610px;
  background: rgba(37, 169, 91, 0.12);
}

.page-glow-two {
  bottom: -280px;
  left: -230px;
  width: 560px;
  height: 560px;
  border: 90px solid rgba(18, 90, 53, 0.055);
}

.topbar {
  position: relative;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: min(1240px, calc(100% - 40px));
  margin: 0 auto;
  padding: 20px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  border-radius: 15px;
  background: linear-gradient(145deg, var(--green-800), var(--green-500));
  box-shadow: 0 10px 24px rgba(18, 90, 53, 0.22);
}

.brand-mark svg {
  width: 27px;
  color: #fff;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.brand-copy strong,
.brand-copy small {
  display: block;
}

.brand-copy strong {
  font-size: 14px;
  font-weight: 850;
  letter-spacing: -0.01em;
}

.brand-copy small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.api-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 9px 13px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: #4d5b52;
  font-size: 11px;
  font-weight: 800;
  box-shadow: 0 8px 22px rgba(21, 66, 41, 0.06);
  backdrop-filter: blur(12px);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.api-status:not(:disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 26px rgba(21, 66, 41, 0.1);
}

.api-status > svg {
  width: 15px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.status-dot {
  width: 9px;
  height: 9px;
  flex: 0 0 9px;
  border-radius: 50%;
  background: #d99a22;
  box-shadow: 0 0 0 4px rgba(217, 154, 34, 0.13);
}

.api-status.is-connected {
  border-color: #bde7ca;
  color: #166534;
}

.api-status.is-connected .status-dot {
  background: #22a957;
  box-shadow: 0 0 0 4px rgba(34, 169, 87, 0.14);
}

.api-status.is-failed {
  border-color: #f1c5c5;
  color: #a62424;
}

.api-status.is-failed .status-dot {
  background: var(--danger);
  box-shadow: 0 0 0 4px rgba(197, 44, 44, 0.12);
}

.api-status.is-checking > svg {
  animation: spin 1s linear infinite;
}

.container {
  width: min(1240px, calc(100% - 40px));
  margin: 10px auto 26px;
}

.login-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(420px, 0.82fr);
  min-height: min(720px, calc(100vh - 145px));
  overflow: hidden;
  border: 1px solid rgba(211, 226, 216, 0.85);
  border-radius: 32px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-width: 0;
  padding: clamp(34px, 5vw, 66px);
  overflow: hidden;
  background:
    radial-gradient(circle at 87% 14%, rgba(101, 223, 145, 0.22), transparent 23%),
    linear-gradient(145deg, var(--green-950), var(--green-800));
  color: #fff;
}

.hero-panel::before,
.hero-panel::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;
}

.hero-panel::before {
  right: -190px;
  bottom: -210px;
  width: 500px;
  height: 500px;
}

.hero-panel::after {
  right: -115px;
  bottom: -135px;
  width: 350px;
  height: 350px;
}

.hero-grid {
  position: absolute;
  inset: 0;
  opacity: 0.038;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.8) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.8) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(to bottom right, #000, transparent 72%);
}

.hero-content,
.impact-card {
  position: relative;
  z-index: 2;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.82);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.eyebrow span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #6ee7a2;
  box-shadow: 0 0 0 4px rgba(110, 231, 162, 0.1);
}

.hero-panel h1 {
  max-width: 720px;
  margin: 26px 0 0;
  font-size: clamp(42px, 5.2vw, 72px);
  line-height: 0.99;
  letter-spacing: -0.055em;
}

.hero-panel h1::first-line {
  color: #eafff0;
}

.hero-panel p {
  max-width: 590px;
  margin: 24px 0 0;
  color: rgba(255, 255, 255, 0.69);
  font-size: 14px;
  line-height: 1.8;
}

.feature-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  max-width: 650px;
  margin-top: 36px;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 13px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(8px);
}

.feature-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  border-radius: 12px;
  background: rgba(123, 232, 161, 0.14);
  color: #8af0ad;
}

.feature-icon svg {
  width: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.feature-item strong,
.feature-item small {
  display: block;
}

.feature-item strong {
  font-size: 12px;
}

.feature-item small {
  margin-top: 4px;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.52);
  font-size: 9px;
  line-height: 1.4;
  text-overflow: ellipsis;
}

.impact-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 56px;
  padding: 18px 19px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(10px);
}

.impact-label,
.impact-card strong {
  display: block;
}

.impact-label {
  color: #8af0ad;
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.impact-card strong {
  margin-top: 5px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 12px;
}

.impact-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border-radius: 13px;
  background: #fff;
  color: var(--green-700);
  font-size: 23px;
}

.auth-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: clamp(32px, 4vw, 54px);
  background: rgba(255, 255, 255, 0.98);
}

.auth-heading {
  display: flex;
  align-items: center;
  gap: 15px;
}

.auth-icon {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  flex: 0 0 54px;
  border-radius: 17px;
  background: var(--green-100);
  color: var(--green-700);
}

.auth-icon svg {
  width: 25px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.auth-kicker {
  display: block;
  color: var(--green-700);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.auth-heading h2 {
  margin: 5px 0 0;
  font-size: clamp(24px, 2.5vw, 31px);
  line-height: 1.1;
  letter-spacing: -0.035em;
}

.auth-intro {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}

.connection-banner {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-top: 21px;
  padding: 11px 13px;
  border: 1px solid #f0d8a8;
  border-radius: 13px;
  background: #fffaf0;
  color: #875108;
}

.connection-icon {
  width: 10px;
  height: 10px;
  flex: 0 0 10px;
  border-radius: 50%;
  background: #d99a22;
  box-shadow: 0 0 0 5px rgba(217, 154, 34, 0.12);
}

.connection-banner strong,
.connection-banner small {
  display: block;
}

.connection-banner strong {
  font-size: 10px;
}

.connection-banner small {
  margin-top: 2px;
  color: currentColor;
  font-size: 9px;
  opacity: 0.72;
}

.connection-banner.is-connected {
  border-color: #bfe8ca;
  background: var(--green-50);
  color: #166534;
}

.connection-banner.is-connected .connection-icon {
  background: #22a957;
  box-shadow: 0 0 0 5px rgba(34, 169, 87, 0.12);
}

.connection-banner.is-failed {
  border-color: #f1c6c6;
  background: #fff4f4;
  color: #a62424;
}

.connection-banner.is-failed .connection-icon {
  background: var(--danger);
  box-shadow: 0 0 0 5px rgba(197, 44, 44, 0.1);
}

.login-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  margin-top: 20px;
  padding: 4px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: #f3f6f4;
}

.login-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 42px;
  padding: 8px 11px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #6e7b73;
  font-size: 10px;
  font-weight: 850;
  transition: 0.2s;
}

.login-tab svg {
  width: 17px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.login-tab.is-active {
  background: #fff;
  color: var(--green-700);
  box-shadow: 0 5px 16px rgba(14, 69, 40, 0.08);
}

.login-panel {
  margin-top: 22px;
}

.login-form {
  display: grid;
  gap: 17px;
}

.field-group {
  display: grid;
  gap: 7px;
}

.field-group label,
.token-form label {
  color: #314239;
  font-size: 10px;
  font-weight: 850;
}

.label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.label-row span {
  color: #8a958e;
  font-size: 8px;
}

.input-shell {
  display: flex;
  align-items: center;
  min-height: 49px;
  border: 1px solid #cedbd2;
  border-radius: 13px;
  background: #fff;
  color: #8b978f;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.input-shell:focus-within {
  border-color: var(--green-500);
  box-shadow: 0 0 0 4px rgba(37, 169, 91, 0.11);
  color: var(--green-700);
}

.input-shell > svg {
  width: 18px;
  margin-left: 14px;
  flex: 0 0 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.input-shell input {
  width: 100%;
  min-width: 0;
  min-height: 47px;
  padding: 10px 12px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-size: 12px;
}

.input-shell input::placeholder,
.token-row input::placeholder {
  color: #a1aba5;
}

.input-action {
  position: relative;
  display: grid;
  place-items: center;
  width: 43px;
  height: 43px;
  margin-right: 3px;
  flex: 0 0 43px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #849188;
}

.input-action:hover {
  background: #f2f7f3;
  color: var(--green-700);
}

.input-action svg {
  width: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.input-action.is-showing::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 1.5px;
  transform: rotate(-42deg);
  background: currentColor;
}

.field-error {
  min-height: 12px;
  color: var(--danger);
  font-size: 9px;
}

.primary-button,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 49px;
  border-radius: 13px;
  font-size: 11px;
  font-weight: 850;
  transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
}

.primary-button {
  border: 0;
  background: linear-gradient(135deg, var(--green-800), var(--green-600));
  color: #fff;
  box-shadow: 0 12px 24px rgba(18, 90, 53, 0.2);
}

.primary-button:not(:disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 15px 28px rgba(18, 90, 53, 0.26);
}

.primary-button:disabled {
  opacity: 0.53;
  box-shadow: none;
}

.primary-button > svg {
  width: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.primary-button.is-loading > svg {
  animation: pulse 0.9s ease-in-out infinite alternate;
}

.secondary-button {
  border: 1px solid var(--border);
  background: #fff;
  color: #4d5b52;
}

.secondary-button:hover {
  border-color: #b8c9be;
  background: #f7faf8;
}

.qr-copy strong {
  display: block;
  font-size: 12px;
}

.qr-copy p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

.qr-reader {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 245px;
  margin-top: 14px;
  overflow: hidden;
  border: 1px dashed #b9cdc0;
  border-radius: 17px;
  background: #f4f8f5;
}

.qr-reader video {
  width: 100% !important;
  min-height: 245px;
  object-fit: cover;
}

.qr-viewport {
  position: absolute;
  inset: 0;
  width: 100%;
}

.qr-viewport > div {
  border: 0 !important;
}

.qr-viewport img[alt="Info icon"] {
  display: none;
}

.qr-placeholder {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  flex-direction: column;
  justify-content: center;
  padding: 24px;
  text-align: center;
}

.qr-frame {
  position: relative;
  display: grid;
  place-items: center;
  width: 94px;
  height: 94px;
  color: var(--green-700);
}

.qr-frame svg {
  width: 46px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.5;
}

.qr-frame i {
  position: absolute;
  width: 22px;
  height: 22px;
  border-color: #7ab38e;
  border-style: solid;
}

.qr-frame i:nth-child(1) {
  top: 0;
  left: 0;
  border-width: 2px 0 0 2px;
  border-radius: 8px 0 0;
}

.qr-frame i:nth-child(2) {
  top: 0;
  right: 0;
  border-width: 2px 2px 0 0;
  border-radius: 0 8px 0 0;
}

.qr-frame i:nth-child(3) {
  right: 0;
  bottom: 0;
  border-width: 0 2px 2px 0;
  border-radius: 0 0 8px;
}

.qr-frame i:nth-child(4) {
  bottom: 0;
  left: 0;
  border-width: 0 0 2px 2px;
  border-radius: 0 0 0 8px;
}

.qr-placeholder strong {
  margin-top: 8px;
  font-size: 11px;
}

.qr-placeholder small {
  max-width: 240px;
  margin-top: 5px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.5;
}

.scanner-actions {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 9px;
  margin-top: 11px;
}

.scanner-actions .secondary-button {
  padding: 0 18px;
}

.scanner-message {
  margin: 8px 0 0;
  color: #7c8981;
  font-size: 8.5px;
  line-height: 1.45;
}

.manual-access {
  margin-top: 13px;
  border-top: 1px solid #e3ebe5;
}

.manual-access summary {
  padding: 13px 0 0;
  color: var(--green-700);
  font-size: 9px;
  font-weight: 850;
  cursor: pointer;
}

.token-form {
  display: grid;
  gap: 7px;
  margin-top: 12px;
}

.token-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.token-row input {
  min-width: 0;
  min-height: 43px;
  padding: 9px 11px;
  border: 1px solid #cedbd2;
  border-radius: 11px;
  outline: none;
  font-size: 10px;
}

.token-row input:focus {
  border-color: var(--green-500);
  box-shadow: 0 0 0 3px rgba(37, 169, 91, 0.1);
}

.token-row button {
  min-height: 43px;
  padding: 8px 16px;
  border: 0;
  border-radius: 11px;
  background: var(--green-800);
  color: #fff;
  font-size: 10px;
  font-weight: 850;
}

.token-row button:disabled {
  opacity: 0.5;
}

.security-note {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 21px;
  padding-top: 17px;
  border-top: 1px solid #e3ebe5;
  color: #758179;
  font-size: 8.5px;
  line-height: 1.55;
}

.security-note svg {
  width: 16px;
  flex: 0 0 16px;
  color: var(--green-600);
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 2px 18px 24px;
  color: #829087;
  font-size: 9px;
}

.footer-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #9caaa1;
}

.toast-container {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 300;
  display: grid;
  gap: 9px;
}

.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  width: min(360px, calc(100vw - 32px));
  padding: 13px 15px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 13px;
  background: var(--green-800);
  color: #fff;
  font-size: 10px;
  line-height: 1.5;
  box-shadow: 0 18px 42px rgba(15, 45, 28, 0.25);
  animation: toast-in 0.25s ease-out;
  transition: opacity 0.25s, transform 0.25s;
}

.toast-error {
  background: #a52323;
}

.toast-warning {
  background: #97540a;
}

.toast-symbol {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  font-size: 11px;
  font-weight: 900;
}

.toast.is-hiding {
  transform: translateY(12px);
  opacity: 0;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes pulse {
  to { opacity: 0.4; }
}

@keyframes toast-in {
  from { transform: translateY(12px); opacity: 0; }
}

@media (max-width: 980px) {
  .login-layout {
    grid-template-columns: minmax(0, 0.95fr) minmax(390px, 1.05fr);
  }

  .hero-panel {
    padding: 42px 34px;
  }

  .feature-list {
    grid-template-columns: 1fr;
  }

  .feature-item:nth-child(2) {
    display: none;
  }
}

@media (max-width: 780px) {
  .topbar,
  .container {
    width: min(680px, calc(100% - 24px));
  }

  .topbar {
    padding: 14px 0;
  }

  .login-layout {
    grid-template-columns: 1fr;
    min-height: auto;
    border-radius: 25px;
  }

  .hero-panel {
    min-height: 335px;
    padding: 34px;
  }

  .hero-panel h1 {
    max-width: 590px;
    font-size: clamp(39px, 8vw, 58px);
  }

  .hero-panel p {
    max-width: 540px;
    margin-top: 17px;
  }

  .feature-list,
  .impact-card {
    display: none;
  }

  .auth-panel {
    padding: 38px 34px;
  }
}

@media (max-width: 560px) {
  .topbar,
  .container {
    width: calc(100% - 16px);
  }

  .brand-mark {
    width: 42px;
    height: 42px;
    flex-basis: 42px;
    border-radius: 13px;
  }

  .brand-copy small {
    display: none;
  }

  .brand-copy strong {
    max-width: 140px;
    line-height: 1.25;
  }

  .api-status {
    min-height: 39px;
    padding: 8px 10px;
    font-size: 9px;
  }

  .api-status > svg {
    display: none;
  }

  .container {
    margin-top: 0;
  }

  .login-layout {
    border-radius: 20px;
  }

  .hero-panel {
    min-height: 274px;
    padding: 26px 22px 31px;
  }

  .hero-panel h1 {
    margin-top: 20px;
    font-size: clamp(35px, 11vw, 47px);
  }

  .hero-panel p {
    margin-top: 15px;
    font-size: 11px;
    line-height: 1.65;
  }

  .auth-panel {
    padding: 28px 21px 31px;
  }

  .auth-icon {
    width: 49px;
    height: 49px;
    flex-basis: 49px;
  }

  .auth-heading h2 {
    font-size: 25px;
  }

  .connection-banner {
    margin-top: 18px;
  }

  .login-tabs {
    margin-top: 17px;
  }

  .qr-reader,
  .qr-reader video {
    min-height: 225px;
  }

  .footer {
    flex-direction: column;
    gap: 4px;
    padding-top: 0;
    text-align: center;
  }

  .footer-dot {
    display: none;
  }
}

@media (max-width: 380px) {
  .brand-copy strong {
    max-width: 116px;
    font-size: 12px;
  }

  .api-status {
    max-width: 128px;
  }

  .hero-panel h1 {
    font-size: 34px;
  }

  .login-tab {
    padding-right: 7px;
    padding-left: 7px;
  }

  .token-row {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Login redesign: visual only — existing login and QR behaviour remain unchanged. */
body {
  min-height: 100svh;
  background: #f6f8ff;
}

.page-glow {
  display: none;
}

.topbar {
  position: absolute;
  z-index: 20;
  top: 0;
  left: 0;
  width: 50%;
  margin: 0;
  padding: 39px clamp(30px, 4.1vw, 64px);
  pointer-events: none;
}

.brand {
  gap: 10px;
  color: #ffffff;
  pointer-events: auto;
}

.brand-mark {
  width: 36px;
  height: 36px;
  flex-basis: 36px;
  border-radius: 3px;
  background: rgba(0, 0, 0, 0.28);
  box-shadow: none;
}

.brand-mark svg {
  width: 22px;
  color: rgba(255, 255, 255, 0.9);
}

.brand-copy strong {
  max-width: 170px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 900;
  line-height: 1.08;
  letter-spacing: 0.025em;
  text-transform: uppercase;
}

.brand-copy small {
  margin-top: 3px;
  color: #9ae9af;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

/* API status remains available to assistive technology; connection errors stay visible in the form. */
.api-status {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  white-space: nowrap;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
}

.container {
  width: 100%;
  min-height: 100svh;
  margin: 0;
}

.login-layout {
  grid-template-columns: minmax(0, 1fr) minmax(380px, 1fr);
  min-height: 100svh;
  border: 0;
  border-radius: 0;
  background: #f6f8ff;
  box-shadow: none;
}

.hero-panel {
  justify-content: initial;
  padding: 0 clamp(30px, 4.1vw, 64px) 28px;
  background:
    radial-gradient(circle at 105% -12%, rgba(98, 218, 135, 0.18), transparent 32%),
    linear-gradient(145deg, #004923 0%, #005227 62%, #00471f 100%);
}

.hero-panel::before {
  right: -245px;
  bottom: -260px;
  width: 520px;
  height: 520px;
  border-color: rgba(136, 236, 164, 0.09);
}

.hero-panel::after {
  right: -135px;
  bottom: -145px;
  width: 340px;
  height: 340px;
  border-color: rgba(136, 236, 164, 0.09);
}

.hero-grid {
  opacity: 0.026;
  background-size: 38px 38px;
}

.hero-content {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding-top: clamp(156px, 20vh, 218px);
}

.eyebrow,
.impact-card {
  display: none;
}

.hero-panel h1 {
  max-width: 475px;
  margin: 0;
  color: #ffffff;
  font-size: clamp(32px, 3.25vw, 48px);
  font-weight: 850;
  line-height: 1.18;
  letter-spacing: -0.052em;
}

.hero-panel h1::first-line {
  color: inherit;
}

.hero-panel h1 em {
  color: #8eeaa8;
  font-style: normal;
}

.hero-panel p {
  max-width: 440px;
  margin-top: 19px;
  color: rgba(233, 255, 239, 0.7);
  font-size: 14px;
  line-height: 1.58;
}

.feature-list {
  max-width: none;
  margin-top: auto;
  gap: 12px;
}

.feature-item {
  min-height: 72px;
  padding: 12px 13px;
  border-color: rgba(184, 242, 199, 0.12);
  border-radius: 9px;
  background: rgba(126, 226, 152, 0.1);
  backdrop-filter: none;
}

.feature-icon {
  width: 33px;
  height: 33px;
  flex-basis: 33px;
  border-radius: 8px;
  background: rgba(92, 222, 125, 0.12);
  color: #a3f5bb;
}

.feature-icon svg {
  width: 18px;
}

.feature-item strong {
  font-size: 10px;
}

.feature-item small {
  margin-top: 3px;
  color: rgba(239, 255, 243, 0.58);
  font-size: 8px;
  line-height: 1.48;
}

.auth-panel {
  align-items: center;
  justify-content: center;
  padding: clamp(48px, 7vh, 76px) clamp(36px, 6.8vw, 94px);
  background: #f6f8ff;
}

.auth-panel > * {
  width: min(100%, 400px);
}

.auth-heading {
  display: block;
}

.auth-icon,
.auth-intro {
  display: none;
}

.auth-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 25px;
  padding: 0 11px;
  border: 1px solid #ffbeb9;
  border-radius: 999px;
  background: #ffe1df;
  color: #b5241d;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.02em;
  text-transform: none;
}

.auth-kicker::before {
  content: "\1F512";
  margin-right: 6px;
  font-size: 9px;
}

.auth-heading h2 {
  margin: 28px 0 0;
  color: #102b52;
  font-size: clamp(28px, 3vw, 42px);
  font-weight: 850;
  line-height: 1.08;
  letter-spacing: -0.055em;
}

.connection-banner {
  display: none;
}

.connection-banner.is-checking,
.connection-banner.is-failed {
  display: flex;
  margin-top: 15px;
}

.login-tabs {
  gap: 0;
  margin-top: 27px;
  padding: 3px;
  border-color: #d8e2f7;
  border-radius: 7px;
  background: #dce8ff;
}

.login-tab {
  min-height: 33px;
  padding: 6px 9px;
  border-radius: 5px;
  color: #536583;
  font-size: 10px;
}

.login-tab svg {
  width: 15px;
}

.login-tab.is-active {
  color: #244369;
  box-shadow: 0 1px 3px rgba(22, 52, 92, 0.16);
}

.login-panel {
  margin-top: 25px;
}

.login-form {
  gap: 15px;
}

.field-group {
  gap: 6px;
}

.field-group label,
.token-form label {
  color: #435778;
  font-size: 10px;
  font-weight: 800;
}

.label-row span {
  color: #8d9aad;
}

.input-shell {
  min-height: 45px;
  border-color: #d8dde8;
  border-radius: 10px;
  background: #ffffff;
  color: #57708c;
  box-shadow: 0 1px 2px rgba(24, 49, 84, 0.02);
}

.input-shell:focus-within {
  border-color: #75a8f5;
  box-shadow: 0 0 0 3px rgba(88, 146, 238, 0.14);
  color: #2e619b;
}

.input-shell > svg {
  width: 17px;
  margin-left: 13px;
}

.input-shell input {
  min-height: 43px;
  padding: 8px 10px;
  color: #243853;
  font-size: 11px;
}

.input-shell input::placeholder,
.token-row input::placeholder {
  color: #8a9bb1;
}

.input-action {
  width: 39px;
  height: 39px;
  flex-basis: 39px;
  color: #74869d;
}

.input-action:hover {
  background: #edf3ff;
  color: #2e619b;
}

.field-error {
  min-height: 10px;
}

.primary-button,
.secondary-button {
  min-height: 45px;
  border-radius: 10px;
}

.primary-button {
  background: #005523;
  box-shadow: 0 8px 16px rgba(0, 79, 33, 0.19);
  font-size: 10px;
}

.primary-button:not(:disabled):hover {
  background: #006b30;
  box-shadow: 0 10px 19px rgba(0, 79, 33, 0.25);
}

.primary-button > svg {
  width: 17px;
}

.security-note {
  gap: 10px;
  margin-top: 31px;
  padding: 14px;
  border: 0;
  border-radius: 9px;
  background: #e3edff;
  color: #46648a;
  font-size: 8.5px;
  line-height: 1.55;
}

.security-note svg {
  width: 17px;
  flex-basis: 17px;
  color: #2d5d91;
}

.footer {
  display: none;
}

@media (max-width: 780px) {
  .topbar {
    width: 100%;
    padding: 26px 25px;
  }

  .login-layout {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .hero-panel {
    min-height: 350px;
    padding: 0 25px 29px;
  }

  .hero-content {
    padding-top: 125px;
  }

  .hero-panel h1 {
    max-width: 560px;
    font-size: clamp(32px, 8vw, 48px);
  }

  .feature-list,
  .impact-card {
    display: none;
  }

  .auth-panel {
    padding: 44px max(25px, calc((100% - 520px) / 2));
  }
}

@media (max-width: 430px) {
  .topbar {
    padding: 21px 20px;
  }

  .brand-copy small {
    display: none;
  }

  .hero-panel {
    min-height: 320px;
    padding: 0 20px 25px;
  }

  .hero-content {
    padding-top: 105px;
  }

  .hero-panel h1 {
    font-size: 31px;
  }

  .auth-panel {
    padding: 36px 20px 42px;
  }

  .auth-heading h2 {
    font-size: 29px;
  }
}

/* Keep the brand hierarchy compact and the two login methods in one stable frame. */
.brand-copy strong:first-child {
  font-size: 13px;
  line-height: 1;
}

.brand-copy strong + strong {
  margin-top: 3px;
  color: #9ae9af;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.1em;
  line-height: 1;
}

@media (min-width: 781px) {
  .auth-panel {
    justify-content: flex-start;
    overflow-y: auto;
    scrollbar-gutter: stable;
  }

  .auth-heading,
  .login-tabs,
  .login-panel,
  .security-note {
    flex-shrink: 0;
  }
}

/* Ilustrasi Bank Sampah dan batas panel melengkung. */
.hero-panel {
  background-image:
    linear-gradient(90deg, rgba(245, 255, 249, 0.98) 0%, rgba(245, 255, 249, 0.9) 37%, rgba(235, 250, 241, 0.5) 61%, rgba(235, 250, 241, 0.08) 100%),
    url("../assets/waste-bank-illustration.svg");
  background-position: center, center;
  background-size: cover, cover;
  color: #113f2a;
}

.hero-panel::before,
.hero-panel::after,
.hero-grid {
  display: none;
}

.hero-panel h1 {
  color: #123f2a;
  text-shadow: none;
}

.hero-panel h1 em {
  color: #148151;
}

.hero-panel p {
  color: rgba(20, 63, 42, 0.78);
}

.feature-item {
  border-color: rgba(21, 105, 67, 0.15);
  background: rgba(255, 255, 255, 0.66);
  box-shadow: 0 8px 24px rgba(28, 102, 66, 0.08);
}

.feature-icon {
  background: rgba(45, 171, 101, 0.14);
  color: #148151;
}

.feature-item small {
  color: rgba(20, 63, 42, 0.68);
}

.topbar .brand {
  color: #113f2a;
}

.topbar .brand-mark {
  background: #0b633c;
}

.topbar .brand-copy strong:first-child {
  color: #113f2a;
}

.topbar .brand-copy strong + strong,
.topbar .brand-copy small {
  color: #168253;
}

@media (min-width: 781px) {
  .login-layout {
    overflow: hidden;
  }

  .hero-panel {
    z-index: 2;
    width: 100%;
    margin-right: 0;
    padding-right: clamp(30px, 4.1vw, 64px);
    clip-path: ellipse(100% 125% at 0% 50%);
  }

  .auth-panel {
    position: relative;
    z-index: 1;
    padding-left: clamp(42px, 4.8vw, 74px);
  }
}

@media (max-width: 780px) {
  .hero-panel {
    background-position: center, 64% center;
  }
}

/* Komposisi form login mengikuti desain portal admin. */
.auth-panel > * {
  width: min(100%, 404px);
}

.auth-heading h2 {
  margin-top: 27px;
  font-size: clamp(29px, 2.4vw, 39px);
  letter-spacing: -0.045em;
}

.login-tabs {
  margin-top: 29px;
  padding: 3px;
  border-radius: 8px;
}

.login-tab {
  min-height: 37px;
  font-size: 10px;
}

.login-panel {
  margin-top: 27px;
}

.login-form {
  gap: 17px;
}

.field-group {
  gap: 8px;
}

.field-group label,
.token-form label {
  font-size: 10px;
  letter-spacing: 0.01em;
}

.input-shell {
  min-height: 45px;
  border-color: #d6ddd7;
  border-radius: 11px;
}

.input-shell input {
  min-height: 43px;
  font-size: 11px;
}

.input-action::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 1.5px;
  transform: rotate(-42deg);
  background: currentColor;
}

.input-action.is-showing::after {
  display: none;
}

.login-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: -1px;
  color: #5d6d64;
  font-size: 10px;
  font-weight: 700;
}

.remember-choice {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
}

.remember-choice input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: #00713a;
  cursor: pointer;
}

.forgot-password {
  padding: 2px 0;
  border: 0;
  background: transparent;
  color: #087242;
  font: inherit;
  font-weight: 850;
  cursor: pointer;
}

.forgot-password:hover,
.forgot-password:focus-visible {
  color: #00562f;
  text-decoration: underline;
}

.primary-button {
  min-height: 45px;
  margin-top: 1px;
}

.security-note {
  margin-top: 28px;
  padding: 15px 16px;
  border-radius: 10px;
}

.security-note svg {
  width: 19px;
  flex-basis: 19px;
}

@media (max-width: 780px) {
  .auth-panel {
    padding-top: 46px;
  }

  .auth-heading h2 {
    font-size: 30px;
  }
}

/* Penyempurnaan input: satu permukaan utuh, padat, dan responsif. */
.auth-panel > * {
  width: min(100%, 380px);
}

.auth-heading h2 {
  margin-top: 23px;
}

.login-tabs {
  margin-top: 24px;
}

.login-panel {
  margin-top: 22px;
}

.login-form {
  gap: 14px;
}

.field-group {
  gap: 7px;
}

.input-shell {
  gap: 11px;
  min-height: 47px;
  padding: 0 12px 0 14px;
  border-color: #d5ddd8;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 2px 5px rgba(21, 63, 42, 0.025);
  transition: border-color 0.2s ease, box-shadow 0.2s ease,
    transform 0.2s ease;
}

.input-shell:hover {
  border-color: #b8c9be;
}

.input-shell:focus-within {
  border-color: #148151;
  box-shadow: 0 0 0 4px rgba(20, 129, 81, 0.11);
}

.input-shell > svg {
  width: 18px;
  margin-left: 0;
  flex-basis: 18px;
  color: #5b8070;
}

.input-shell input {
  min-height: 45px;
  padding: 9px 0;
  border-radius: 8px;
  background: transparent;
  color: #183d2d;
  font-size: 11px;
  font-weight: 600;
}

/* Chrome tidak lagi memberi blok warna berbeda saat autofill. */
.input-shell input:-webkit-autofill,
.input-shell input:-webkit-autofill:hover,
.input-shell input:-webkit-autofill:focus,
.input-shell input:-webkit-autofill:active {
  -webkit-text-fill-color: #183d2d;
  -webkit-box-shadow: 0 0 0 100px #ffffff inset;
  box-shadow: 0 0 0 100px #ffffff inset;
  caret-color: #183d2d;
}

.input-action {
  width: 32px;
  height: 32px;
  margin: 0 -3px 0 0;
  flex-basis: 32px;
  border-radius: 8px;
  color: #6b8197;
}

.input-action:hover {
  background: #eff7f2;
  color: #087242;
}

.login-options {
  margin-top: 0;
}

.remember-choice {
  color: #56685e;
}

.remember-choice input {
  appearance: none;
  display: grid;
  width: 17px;
  height: 17px;
  place-content: center;
  border: 1.5px solid #b4c1ba;
  border-radius: 5px;
  background: #ffffff;
  transition: background-color 0.18s ease, border-color 0.18s ease,
    transform 0.18s ease;
}

.remember-choice input::before {
  width: 8px;
  height: 5px;
  content: "";
  border-bottom: 1.8px solid #ffffff;
  border-left: 1.8px solid #ffffff;
  transform: rotate(-45deg) scale(0);
  transition: transform 0.14s ease;
}

.remember-choice input:hover {
  border-color: #148151;
}

.remember-choice input:checked {
  border-color: #087242;
  background: #087242;
}

.remember-choice input:checked::before {
  transform: rotate(-45deg) scale(1);
}

.remember-choice input:focus-visible,
.forgot-password:focus-visible {
  outline: 3px solid rgba(20, 129, 81, 0.2);
  outline-offset: 3px;
}

.primary-button {
  min-height: 46px;
  border-radius: 12px;
  box-shadow: 0 9px 18px rgba(0, 79, 33, 0.17);
}

.security-note {
  margin-top: 24px;
  padding: 14px 15px;
}

/* Transisi hero ke login pada layar ponsel. */
@media (max-width: 780px) {
  .login-layout {
    background: #f6f8ff;
  }

  .hero-panel {
    z-index: 2;
    min-height: 344px;
    margin-bottom: -24px;
    padding-bottom: 54px;
    overflow: hidden;
    border-radius: 0 0 50% 50% / 0 0 34px 34px;
    box-shadow: 0 14px 28px rgba(15, 95, 53, 0.1);
  }

  .auth-panel {
    position: relative;
    z-index: 1;
    padding-top: 62px;
  }
}

@media (max-width: 430px) {
  .hero-panel {
    min-height: 326px;
    padding-bottom: 48px;
    border-radius: 0 0 50% 50% / 0 0 28px 28px;
  }

  .auth-panel {
    padding-top: 56px;
  }
}
