.flex-container {
  min-height: calc(100vh - 60px);
  justify-content: center;
  align-items: center;
  padding: 24px 16px;
  box-sizing: border-box;
}

/* ── Shared field styles ─────────────────────────────────────── */
.field { text-align: left; margin-bottom: 18px; margin-left: 0; margin-right: 0; }
.field label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-bottom: 7px;
}
.field input {
  display: block;
  width: 100%;
  padding: 12px 14px;
  background: rgba(255,255,255,0.07);
  border: 1.5px solid rgba(255,255,255,0.16);
  border-radius: 10px;
  color: white;
  font-size: 0.95rem;
  font-family: inherit;
  box-sizing: border-box;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
.field input::placeholder { color: rgba(255,255,255,0.28); }
.field input:focus {
  outline: none;
  border-color: #1bc467;
  background: rgba(255,255,255,0.1);
  box-shadow: 0 0 0 3px rgba(27,196,103,0.18);
}
.field input.invalid { border-color: rgba(255,100,100,0.6); }

/* ── Error banner ────────────────────────────────────────────── */
.error-banner {
  background: rgba(200,50,50,0.25);
  border: 1px solid rgba(255,100,100,0.4);
  border-radius: 9px;
  padding: 10px 14px;
  font-size: 0.85rem;
  color: #ffaaaa;
  margin: 0 0 18px;
  margin-left: 0;
  margin-right: 0;
}

#output:not(:empty) {
  margin-top: 14px;
  background: rgba(200,50,50,0.25);
  border: 1px solid rgba(255,100,100,0.4);
  border-radius: 9px;
  padding: 10px 14px;
  font-size: 0.85rem;
  color: #ffaaaa;
  margin-left: 0;
  margin-right: 0;
}

/* ── Login two-panel wrapper ─────────────────────────────────── */
.login-wrapper {
  display: flex;
  width: 100%;
  max-width: 860px;
  margin-left: auto;
  margin-right: auto;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 28px 72px rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.14);
}

/* ── Login left: branding panel ─────────────────────────────── */
.login-brand-panel {
  flex: 1;
  background: linear-gradient(145deg, #0a7a38 0%, #14a356 50%, #1bc467 100%);
  padding: 48px 40px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}
.login-brand-panel::before {
  content: '';
  position: absolute;
  top: -30%;
  right: -20%;
  width: 130%;
  height: 130%;
  background: radial-gradient(circle at 70% 30%, rgba(255,255,255,0.08) 0%, transparent 60%);
  pointer-events: none;
}
.login-brand-top {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 6px;
}
.login-brand-top svg { width: 34px; height: 34px; stroke: white; stroke-width: 1.5; fill: none; flex-shrink: 0; }
.login-brand-top h2 { font-size: 1.55rem; margin: 0; text-align: left; }
.login-brand-tagline {
  font-size: 0.9rem;
  color: rgba(255,255,255,0.7);
  font-style: italic;
  margin: 0 0 40px;
}
.login-benefits {
  display: flex;
  flex-direction: column;
  gap: 22px;
  flex: 1;
}
.login-benefit {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin: 0;
}
.login-benefit svg { width: 18px; height: 18px; stroke: rgba(255,255,255,0.8); stroke-width: 2; fill: none; flex-shrink: 0; margin-top: 2px; }
.login-benefit-text { font-size: 0.88rem; color: rgba(255,255,255,0.82); line-height: 1.45; }
.login-benefit-text strong { display: block; font-size: 0.93rem; color: white; margin-bottom: 2px; }
.login-brand-footer {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.42);
  margin: 32px 0 0;
}

/* ── Login right: form panel ─────────────────────────────────── */
.login-form-panel {
  width: 350px;
  flex-shrink: 0;
  background: rgba(4, 28, 12, 0.94);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  padding: 48px 40px 40px;
  display: flex;
  flex-direction: column;
}
.login-form-panel h1 { font-size: 1.6rem; margin: 0 0 4px; text-align: left; }
.login-subtitle { font-size: 0.87rem; color: rgba(255,255,255,0.5); margin: 0 0 32px; }

.btn-signin {
  display: block;
  width: 100%;
  padding: 13px;
  margin-top: 8px;
  background: linear-gradient(135deg, #14a356 0%, #1bc467 100%);
  color: white;
  border: none;
  border-radius: 10px;
  font-size: 0.95rem;
  font-weight: 700;
  font-family: inherit;
  letter-spacing: 0.5px;
  cursor: pointer;
  box-sizing: border-box;
  transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
}
.btn-signin:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(20,163,86,0.4);
  filter: brightness(1.08);
}
.btn-signin:active { transform: translateY(0); filter: brightness(0.95); }

.login-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 24px 0;
  margin-left: 0;
  margin-right: 0;
}
.login-divider::before,
.login-divider::after { content: ''; flex: 1; height: 1px; background: rgba(255,255,255,0.1); }
.login-divider span { font-size: 0.7rem; color: rgba(255,255,255,0.3); letter-spacing: 1px; text-transform: uppercase; }

.login-footer { font-size: 0.82rem; color: rgba(255,255,255,0.48); line-height: 2.1; margin-left: 0; margin-right: 0; }
.login-footer a {
  color: #4cd98a;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgba(76,217,138,0.3);
  transition: color 0.15s, border-color 0.15s;
}
.login-footer a:hover { color: #7de8ab; border-color: rgba(125,232,171,0.55); }

@media (max-width: 680px) {
  .login-wrapper { flex-direction: column; max-width: 440px; }
  .login-brand-panel { padding: 32px 28px; }
  .login-benefits { display: none; }
  .login-form-panel { width: 100%; padding: 32px 28px; }
}

/* ── Register two-panel wrapper ──────────────────────────────── */
.reg-wrapper {
  display: flex;
  width: 100%;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 28px 72px rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.14);
}

/* Register left brand panel */
.reg-brand-panel {
  flex: 1;
  background: linear-gradient(145deg, #0a7a38 0%, #14a356 50%, #1bc467 100%);
  padding: 48px 40px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}
.reg-brand-panel::before {
  content: '';
  position: absolute;
  top: -30%; right: -20%;
  width: 130%; height: 130%;
  background: radial-gradient(circle at 70% 30%, rgba(255,255,255,0.08) 0%, transparent 60%);
  pointer-events: none;
}
.reg-brand-top { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.reg-brand-top svg { width: 34px; height: 34px; stroke: white; stroke-width: 1.5; fill: none; flex-shrink: 0; }
.reg-brand-top h2 { font-size: 1.55rem; margin: 0; text-align: left; }
.reg-brand-tagline { font-size: 0.9rem; color: rgba(255,255,255,0.7); font-style: italic; margin: 0 0 36px; }
.reg-benefits { display: flex; flex-direction: column; gap: 20px; flex: 1; }
.reg-benefit { display: flex; align-items: flex-start; gap: 14px; margin: 0; }
.reg-benefit svg { width: 18px; height: 18px; stroke: rgba(255,255,255,0.8); stroke-width: 2; fill: none; flex-shrink: 0; margin-top: 2px; }
.reg-benefit-text { font-size: 0.88rem; color: rgba(255,255,255,0.82); line-height: 1.45; }
.reg-benefit-text strong { display: block; font-size: 0.93rem; color: white; margin-bottom: 2px; }
.reg-brand-footer { font-size: 0.72rem; color: rgba(255,255,255,0.42); margin: 28px 0 0; }

/* Register right form panel */
.reg-form-panel {
  width: 380px;
  flex-shrink: 0;
  background: rgba(4, 28, 12, 0.94);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  padding: 44px 38px 40px;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}
.reg-form-panel h1 { font-size: 1.5rem; margin: 0 0 4px; text-align: left; }
.reg-subtitle { font-size: 0.87rem; color: rgba(255,255,255,0.5); margin: 0 0 28px; }

.btn-register {
  display: block; width: 100%; padding: 13px; margin-top: 6px;
  background: linear-gradient(135deg, #14a356 0%, #1bc467 100%);
  color: white; border: none; border-radius: 10px;
  font-size: 0.95rem; font-weight: 700; font-family: inherit;
  letter-spacing: 0.5px; cursor: pointer; box-sizing: border-box;
  transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
}
.btn-register:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(20,163,86,0.4); filter: brightness(1.08); }
.btn-register:disabled { opacity: 0.6; transform: none; cursor: not-allowed; }

.reg-footer {
  font-size: 0.82rem; color: rgba(255,255,255,0.48);
  line-height: 2.1; margin: 20px 0 0; margin-left: 0; margin-right: 0;
}
.reg-footer a {
  color: #4cd98a; font-weight: 600; text-decoration: none;
  border-bottom: 1px solid rgba(76,217,138,0.3);
  transition: color 0.15s, border-color 0.15s;
}
.reg-footer a:hover { color: #7de8ab; border-color: rgba(125,232,171,0.55); }

.password-hint {
  font-size: 0.73rem;
  color: rgba(255,255,255,0.35);
  margin: 4px 0 0;
  margin-left: 0;
}

@media (max-width: 700px) {
  .reg-wrapper { flex-direction: column; max-width: 440px; }
  .reg-brand-panel { padding: 32px 28px; }
  .reg-benefits { display: none; }
  .reg-form-panel { width: 100%; padding: 32px 28px; }
}
