@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
  --auth-white: #ffffff;
  --auth-blue: #2563eb;
  --auth-blue-dark: #1e293b;
  --auth-text: #111827;
  --auth-muted: #6b7280;
  --auth-input-bg: #f3f4f6;
  --auth-input-border: #d1d5db;
  --auth-danger: #dc2626;
  --auth-success: #16a34a;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

.auth-page {
  min-height: 100vh;
  font-family: 'Inter', 'Roboto', system-ui, -apple-system, 'Segoe UI', sans-serif;
  background: var(--auth-white);
}

.auth-shell {
  min-height: 100vh;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.auth-panel {
  position: relative;
  overflow: hidden;
  padding: 42px 44px;
  color: #fff;
  display: flex;
  flex-direction: column;
}

.auth-panel::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('/img/photo_login_register.png') center / cover no-repeat;
  transform: scale(1.03);
}

.auth-panel::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(145deg, rgba(30, 41, 59, 0.9) 8%, rgba(37, 99, 235, 0.64) 100%);
}

.auth-brand,
.auth-title,
.auth-sub {
  position: relative;
  z-index: 1;
}

.auth-brand {
  display: inline-flex;
  align-items: center;
}

.auth-brand img {
  height: 120px;
  width: auto;
}

.auth-title {
  margin: auto 0 10px;
  max-width: 560px;
  align-self: center;
  text-align: center;
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.auth-sub {
  margin: 0 0 auto;
  max-width: 560px;
  align-self: center;
  text-align: center;
  color: rgba(255, 255, 255, 0.86);
  line-height: 1.6;
  font-size: 15px;
}

.auth-card {
  background: var(--auth-white);
  padding: clamp(28px, 5vw, 64px) clamp(22px, 7vw, 86px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.auth-card > h2,
.auth-card > .auth-card-sub,
.auth-card > form,
.auth-card > .auth-error-box,
.auth-card > .auth-success-box,
.auth-card > .auth-info-box,
.auth-card > .auth-foot {
  width: min(100%, 340px);
}

.auth-card h2,
.auth-card p.auth-card-sub {
  text-align: left;
}

.auth-card h2 {
  color: var(--auth-text);
  margin: 0 0 8px;
  font-size: 27px;
  line-height: 1.2;
  font-weight: 600;
}

.auth-card p.auth-card-sub {
  color: var(--auth-muted);
  margin: 0 0 26px;
  font-size: 14px;
}

.auth-error-box,
.auth-success-box,
.auth-info-box {
  margin-bottom: 14px;
  font-size: 13px;
  font-weight: 500;
}

.auth-error-box {
  border: 1px solid #fecaca;
  background: #fef2f2;
  color: #991b1b;
  padding: 10px 12px;
  border-radius: 8px;
}

.auth-success-box {
  color: #16a34a;
}

.auth-info-box {
  color: #1e40af;
}

.auth-error-box p,
.auth-success-box p,
.auth-info-box p {
  margin: 0;
}

.auth-field {
  margin-bottom: 15px;
}

.auth-field ul {
  margin: 6px 0 0;
  padding-left: 16px;
  color: #b91c1c;
  font-size: 12px;
}

.auth-label {
  display: block;
  margin-bottom: 8px;
  color: #374151;
  font-size: 13px;
  font-weight: 600;
}

.auth-input {
  width: 100%;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 13px 14px;
  background: var(--auth-input-bg);
  color: var(--auth-text);
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.auth-input::placeholder {
  color: #9ca3af;
}

.auth-input:focus {
  border-color: var(--auth-blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

.auth-input[readonly] {
  background: #eef0f4;
  border-color: transparent;
  color: #334155;
  cursor: not-allowed;
}

.auth-input[readonly]:focus {
  border-color: transparent;
  box-shadow: none;
}

.auth-input.is-invalid {
  border-color: var(--auth-danger);
}

.auth-input.is-valid {
  border-color: var(--auth-success);
}

.auth-row-between {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.auth-link {
  color: var(--auth-blue);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
}

.auth-pass-wrap {
  position: relative;
}

.auth-pass-wrap .auth-input {
  padding-right: 44px;
}

.auth-eye {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 30px;
  height: 30px;
  border: none;
  background: transparent;
  color: #6b7280;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.auth-eye svg {
  width: 18px;
  height: 18px;
}

.auth-check {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 8px 0 4px;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 6px 4px;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.auth-check.is-invalid {
  border-color: #fca5a5;
  background: #fff7f7;
}

.auth-check input[type='checkbox'] {
  margin-top: 2px;
  accent-color: var(--auth-blue);
}

.auth-check.is-invalid input[type='checkbox'] {
  outline: 2px solid rgba(220, 38, 38, 0.22);
  outline-offset: 2px;
}

.auth-check label {
  font-size: 12px;
  color: #4b5563;
  line-height: 1.45;
}

.auth-submit {
  width: 100%;
  border: none;
  border-radius: 8px;
  padding: 13px 15px;
  background: linear-gradient(92deg, #2563eb 0%, #1d4ed8 100%);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.28);
  transition: transform 0.15s ease, filter 0.2s ease, box-shadow 0.2s ease;
}

.auth-submit:hover {
  filter: brightness(0.98);
  transform: translateY(-1px);
  box-shadow: 0 12px 22px rgba(37, 99, 235, 0.32);
}

.auth-submit:active {
  transform: translateY(0);
}

.auth-resend-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  padding: 0;
  color: #16a34a;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.15s ease, opacity 0.15s ease;
}

.auth-resend-btn:hover:not(:disabled) {
  color: #15803d;
}

.auth-resend-btn:disabled {
  color: #9ca3af;
  cursor: not-allowed;
  text-decoration: none;
}

.auth-resend-btn svg {
  flex-shrink: 0;
}

.auth-foot {
  margin: 13px 0 0;
  text-align: center;
  font-size: 13px;
  color: #6b7280;
  line-height: 1.45;
}

.auth-foot + .auth-foot {
  margin-top: 18px;
}

.auth-foot a {
  color: var(--auth-blue);
  font-weight: 600;
  text-decoration: none;
}

.auth-link:hover,
.auth-foot a:hover {
  color: #1d4ed8;
}

.auth-msg {
  font-size: 12px;
  margin-top: 6px;
  min-height: 16px;
}

.auth-terms-msg {
  margin-top: 2px;
  margin-bottom: 14px;
  padding-left: 4px;
  min-height: 15px;
  font-size: 11px;
}

.auth-msg.error {
  color: #b91c1c;
}

.auth-msg.ok {
  color: #15803d;
}

.auth-mobile-logo {
  display: none;
}

@media (max-width: 980px) {
  .auth-shell {
    grid-template-columns: 1fr;
  }

  .auth-panel {
    display: none;
  }

  .auth-card {
    min-height: 100vh;
    padding: 28px 20px;
  }

  .auth-card h2 {
    font-size: 24px;
  }

  .auth-mobile-logo {
    display: flex;
    justify-content: center;
    width: min(100%, 340px);
    margin-bottom: 24px;
  }

  .auth-mobile-logo img {
    height: 72px;
    width: auto;
  }
}

.verify-page {
  min-height: 100vh;
  margin: 0;
  font-family: 'Inter', 'Roboto', system-ui, -apple-system, 'Segoe UI', sans-serif;
  color: #0f172a;
  background: #0f172a;
}

.verify-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(360px, 0.95fr) minmax(420px, 1.05fr);
}

.verify-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 42px;
  color: #fff;
  background: #111827;
}

.verify-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('/img/photo_login_register.png') center / cover no-repeat;
  opacity: 0.38;
  transform: scale(1.04);
}

.verify-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.94), rgba(29, 78, 216, 0.72));
}

.verify-brand,
.verify-hero-copy {
  position: relative;
  z-index: 1;
}

.verify-brand {
  width: fit-content;
}

.verify-brand img {
  height: 112px;
  width: auto;
  display: block;
}

.verify-hero-copy {
  margin: auto 0 120px;
  max-width: 560px;
}

.verify-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  color: rgba(255, 255, 255, 0.9);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.verify-hero h1 {
  margin: 18px 0 12px;
  max-width: 520px;
  font-size: clamp(34px, 4vw, 54px);
  line-height: 1.04;
  font-weight: 800;
}

.verify-hero p {
  margin: 0;
  max-width: 500px;
  color: rgba(255, 255, 255, 0.84);
  font-size: 16px;
  line-height: 1.7;
}

.verify-content {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(24px, 6vw, 72px);
  background: #f8fafc;
}

.verify-card {
  width: min(100%, 470px);
  padding: clamp(24px, 4vw, 36px);
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.14);
}

.verify-card-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 22px;
}

.verify-icon {
  flex: 0 0 auto;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: #2563eb;
}

.verify-icon svg {
  width: 24px;
  height: 24px;
}

.verify-card h2 {
  margin: 0 0 4px;
  font-size: 25px;
  line-height: 1.2;
  font-weight: 750;
  color: #0f172a;
}

.verify-card-head p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
}

.verify-card-head strong {
  display: inline-block;
  max-width: 260px;
  vertical-align: bottom;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #2563eb;
  font-weight: 700;
}

.verify-alert {
  margin-bottom: 18px;
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 13px;
  line-height: 1.45;
  font-weight: 650;
}

.verify-alert-success {
  border: 1px solid #bbf7d0;
  background: #f0fdf4;
  color: #166534;
}

.verify-alert-warning {
  border: 1px solid #bfdbfe;
  background: #eff6ff;
  color: #1e40af;
}

.verify-alert-error {
  border: 1px solid #fecaca;
  background: #fef2f2;
  color: #991b1b;
}

.verify-form {
  display: grid;
  gap: 18px;
}

.verify-field label {
  display: block;
  margin-bottom: 10px;
  color: #334155;
  font-size: 13px;
  font-weight: 750;
}

.verify-code-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.verify-code-preview {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.verify-code-preview span {
  height: 58px;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f8fafc;
  color: #94a3b8;
  font-size: 25px;
  font-weight: 800;
  line-height: 1;
  cursor: text;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.verify-code-preview span.is-filled {
  background: #fff;
  border-color: #2563eb;
  color: #0f172a;
}

.verify-code-preview span.is-active {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

.verify-field p {
  margin: 10px 0 0;
  color: #64748b;
  font-size: 12px;
}

.verify-submit {
  width: 100%;
  min-height: 46px;
  border: 0;
  border-radius: 10px;
  padding: 0 16px;
  background: #2563eb;
  color: #fff;
  font-size: 14px;
  font-weight: 750;
  cursor: pointer;
  transition: background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.verify-submit:hover {
  background: #1d4ed8;
  box-shadow: 0 12px 22px rgba(37, 99, 235, 0.22);
}

.verify-submit:active {
  transform: translateY(1px);
}

.verify-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid #e2e8f0;
}

.verify-actions form {
  margin: 0;
}

.verify-actions button,
.verify-actions a {
  border: 0;
  background: transparent;
  color: #64748b;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: color 0.18s ease;
}

.verify-actions button:hover,
.verify-actions a:hover {
  color: #2563eb;
}

@media (max-width: 860px) {
  .verify-shell {
    grid-template-columns: 1fr;
  }

  .verify-hero {
    min-height: 280px;
    padding: 28px 24px;
  }

  .verify-brand img {
    height: 82px;
  }

  .verify-hero-copy {
    margin: 32px 0 36px;
  }

  .verify-hero p {
    font-size: 14px;
  }

  .verify-content {
    align-items: flex-start;
    padding: 22px 16px 32px;
  }
}

@media (max-width: 460px) {
  .verify-card {
    border-radius: 14px;
    padding: 22px 16px;
  }

  .verify-card-head {
    align-items: flex-start;
  }

  .verify-code-preview {
    gap: 6px;
  }

  .verify-code-preview span {
    height: 50px;
    border-radius: 10px;
    font-size: 22px;
  }

  .verify-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .verify-actions button,
  .verify-actions a {
    width: 100%;
    text-align: center;
  }
}
