:root {
  --brand-primary: #0b1f3a;
  --brand-accent: #0066cc;
  --brand-soft: #f3f6fb;
  --brand-border: #d8dee7;
  --brand-text: #1b2430;
  --brand-error: #b42318;
  --brand-shadow: 0 10px 30px rgba(11, 31, 58, 0.08);
}

* { box-sizing: border-box; }

body {
  font-family: "Inter", "Lato", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--brand-text);
  background: #ffffff;
  margin: 0;
}

#resp-outheader {
  background: #fff;
  border-bottom: 1px solid var(--brand-border);
  padding-bottom: 18px;
}

.hdr-logo-padding img { max-height: 60px; }

.login-padding label {
  font-size: 13px;
  font-weight: 600;
  color: var(--brand-primary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}

.login-input input {
  width: 100%;
  padding: 12px 14px;
  font-size: 15px;
  border: 1px solid var(--brand-border);
  border-radius: 6px;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.login-input input:focus {
  outline: none;
  border-color: var(--brand-accent);
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.15);
}

.forgot-password {
  display: inline-block;
  margin-top: 8px;
  font-size: 13px;
  color: var(--brand-accent) !important;
  text-decoration: none;
}
.forgot-password:hover { text-decoration: underline; }

.login-button-group {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  padding-top: 22px;
}

.btn-login {
  background: var(--brand-primary);
  color: #fff;
  border: none;
  padding: 12px 28px;
  font-weight: 600;
  letter-spacing: 0.03em;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s ease;
}
.btn-login:hover { background: var(--brand-accent); }
.btn-login[disabled] { opacity: 0.7; cursor: wait; }

.phone-card-wrap {
  display: flex;
  justify-content: center;
  padding: 48px 16px 80px;
}

.phone-card {
  width: 100%;
  max-width: 520px;
  background: #fff;
  border: 1px solid var(--brand-border);
  border-radius: 14px;
  padding: 40px 32px 32px;
  box-shadow: var(--brand-shadow);
  text-align: center;
}

.phone-card-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.phone-card-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--brand-primary);
  margin: 0 0 8px;
}

.phone-card-sub {
  font-size: 15px;
  color: #4a5568;
  line-height: 1.5;
  margin: 0 0 28px;
}

.phone-input-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--brand-border);
  border-radius: 8px;
  background: var(--brand-soft);
  max-width: 380px;
  margin: 0 auto;
}

.phone-seg {
  width: 70px;
  padding: 10px 0;
  font-size: 18px;
  font-family: "SF Mono", "Menlo", monospace;
  text-align: center;
  letter-spacing: 0.08em;
  border: 1px solid var(--brand-border);
  border-radius: 6px;
  background: #fff;
  color: var(--brand-text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.phone-seg:focus {
  outline: none;
  border-color: var(--brand-accent);
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.15);
}

.phone-seg#phone3 { width: 88px; }

.phone-sep {
  color: #8a95a3;
  font-size: 18px;
  font-weight: 600;
  user-select: none;
}

.phone-error {
  color: var(--brand-error);
  font-size: 13px;
  margin: 12px 0 0;
}

.phone-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 28px;
}

.btn-try-again {
  background: #fff;
  border: 1px solid var(--brand-border);
  color: var(--brand-primary);
  padding: 11px 26px;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.btn-try-again:hover { background: var(--brand-soft); }

.btn-continue {
  background: var(--brand-primary);
  border: 1px solid var(--brand-primary);
  color: #fff;
  padding: 11px 30px;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s ease;
}
.btn-continue:hover { background: var(--brand-accent); border-color: var(--brand-accent); }

.btn-continue[disabled] {
  background: #cbd3dd;
  border-color: #cbd3dd;
  cursor: not-allowed;
}

.sms-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 20px;
  display: flex;
  justify-content: center;
  pointer-events: none;
  opacity: 0;
  transform: translateY(-20px);
  transition: opacity 0.35s ease, transform 0.35s ease;
  z-index: 9999;
}

.sms-overlay.visible {
  opacity: 1;
  transform: translateY(0);
}

.sms-toast {
  width: 100%;
  max-width: 420px;
  background: rgba(28, 28, 30, 0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 16px;
  padding: 14px 16px;
  color: #fff;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
}

.sms-head {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: #b0b0b5;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.sms-sender { font-weight: 600; }

.sms-body {
  font-size: 14px;
  line-height: 1.45;
  color: #f2f2f7;
}

.sms-code {
  font-family: "SF Mono", Menlo, monospace;
  font-weight: 700;
  letter-spacing: 0.15em;
  font-size: 16px;
  color: #4cd964;
}

#footer-footer {
  border-top: 1px solid var(--brand-border);
  padding: 24px 16px;
  margin-top: 40px;
}

.footertext {
  text-align: center;
  font-size: 12px;
  color: #6b7280;
  line-height: 1.6;
}

.footertext a { color: var(--brand-accent); text-decoration: none; }
.footertext a:hover { text-decoration: underline; }

.fdic-logo { max-width: 90px; margin-bottom: 8px; }

@media (max-width: 767px) {
  .login-button-group { flex-direction: column; align-items: stretch; }
  .btn-login { width: 100%; }
  .phone-card { padding: 32px 20px 24px; }
  .phone-seg { width: 60px; font-size: 16px; }
  .phone-seg#phone3 { width: 76px; }
  .phone-input-group { gap: 5px; padding: 10px; }
  .phone-actions { flex-direction: column; }
  .btn-try-again, .btn-continue { width: 100%; }
}

/* ---------- SMS toast v2: persistent, dismissable ---------- */
.sms-overlay { pointer-events: none; }
.sms-overlay.visible { pointer-events: auto; }

.sms-toast {
  padding: 16px 18px 14px;
}

.sms-body {
  font-size: 14px;
  line-height: 1.5;
  color: #f2f2f7;
}

.sms-code-line {
  margin-top: 12px;
  font-size: 14px;
  color: #e6e6ea;
  display: flex;
  align-items: center;
  gap: 8px;
}

.sms-code {
  font-family: "SF Mono", Menlo, monospace;
  font-weight: 700;
  letter-spacing: 0.18em;
  font-size: 18px;
  color: #4cd964;
  background: rgba(76, 217, 100, 0.1);
  padding: 4px 10px;
  border-radius: 6px;
  user-select: all;
}

.sms-note {
  margin-top: 12px;
  font-size: 12px;
  line-height: 1.45;
  color: #a4a4ad;
}

.sms-dismiss {
  display: block;
  width: 100%;
  margin-top: 14px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 10px;
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.sms-dismiss:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.22);
}
.sms-dismiss:active {
  background: rgba(255, 255, 255, 0.06);
}

/* ---------- SMS toast v2: persistent, dismissable ---------- */
.sms-overlay { pointer-events: none; }
.sms-overlay.visible { pointer-events: auto; }

.sms-toast {
  padding: 16px 18px 14px;
}

.sms-body {
  font-size: 14px;
  line-height: 1.5;
  color: #f2f2f7;
}

.sms-code-line {
  margin-top: 12px;
  font-size: 14px;
  color: #e6e6ea;
  display: flex;
  align-items: center;
  gap: 8px;
}

.sms-code {
  font-family: "SF Mono", Menlo, monospace;
  font-weight: 700;
  letter-spacing: 0.18em;
  font-size: 18px;
  color: #4cd964;
  background: rgba(76, 217, 100, 0.1);
  padding: 4px 10px;
  border-radius: 6px;
  user-select: all;
}

.sms-note {
  margin-top: 12px;
  font-size: 12px;
  line-height: 1.45;
  color: #a4a4ad;
}

.sms-dismiss {
  display: block;
  width: 100%;
  margin-top: 14px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 10px;
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.sms-dismiss:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.22);
}
.sms-dismiss:active {
  background: rgba(255, 255, 255, 0.06);
}

/* ---------- Security alert banner ---------- */
.sec-alert-banner {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 16px;
  background: #fff7f5;
  border: 1px solid #f6c9be;
  border-left: 4px solid #b42318;
  border-radius: 10px;
  margin-bottom: 22px;
  text-align: left;
}

.sec-alert-icon {
  flex: 0 0 auto;
  color: #b42318;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 2px;
}

.sec-alert-title {
  font-size: 14px;
  font-weight: 700;
  color: #7a1a10;
  line-height: 1.3;
  margin-bottom: 4px;
}

.sec-alert-sub {
  font-size: 13px;
  line-height: 1.45;
  color: #5a2a22;
}

/* ---------- KYC field blocks ---------- */
.field-block {
  margin-bottom: 16px;
  text-align: left;
}

.field-block label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--brand-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 6px;
}

.text-input {
  width: 100%;
  padding: 12px 14px;
  font-size: 15px;
  color: var(--brand-text);
  background: #fff;
  border: 1px solid var(--brand-border);
  border-radius: 8px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.text-input.mono {
  font-family: "SF Mono", "Menlo", monospace;
  letter-spacing: 0.18em;
  font-size: 16px;
}

.text-input:focus {
  outline: none;
  border-color: var(--brand-accent);
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.15);
}

.text-input::placeholder {
  color: #9aa3af;
  letter-spacing: 0.05em;
}

/* phone input group already exists — tighten spacing */
.field-block .phone-input-group { margin: 0; }

.contact-support-text {
  font-size: 15px;
  color: #4a5568;
  line-height: 1.55;
  margin: 0 0 22px;
  text-align: center;
}
