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

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Roboto', sans-serif;
  min-height: 100vh;
  background: linear-gradient(180deg, #00C7FF 0%, #0090C7 100%);
}

.auth-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Brand panel (mobile/tablet: top section, desktop: left half) */
.brand-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 56px 24px 96px;
  color: #fff;
  position: relative;
}

.brand-panel .back-btn {
  position: absolute;
  top: 20px;
  left: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  border: 1.5px solid rgba(255,255,255,0.5);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 18px;
}

.brand-panel .logo {
  width: 72px;
  height: 72px;
  margin-bottom: 16px;
}

.brand-panel .brand-name {
  font-size: 11px;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.75);
  font-weight: 300;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.brand-panel h1 {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 6px;
}

.brand-panel p {
  font-size: 14px;
  font-weight: 400;
  color: rgba(255,255,255,0.85);
  max-width: 320px;
}

/* Form panel + card */
.form-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.form-card {
  background: #fff;
  border-radius: 32px 32px 0 0;
  box-shadow: 0 -4px 24px rgba(0,0,0,0.2);
  flex: 1;
  padding: 32px 24px 48px;
}

.form-card .icon-circle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #E0F7FF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  margin: 0 auto 16px;
}

.form-card h2 {
  font-size: 20px;
  font-weight: 700;
  color: #1A1A2E;
  text-align: center;
  margin-bottom: 8px;
}

.form-card .subtitle {
  font-size: 14px;
  color: #888;
  text-align: center;
  margin-bottom: 24px;
}

.field-group { margin-bottom: 16px; }

.field-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: #888;
  margin-bottom: 8px;
}

.field-wrap {
  position: relative;
  display: flex;
  align-items: center;
  background: #fff;
  border: 1.5px solid #D0D0D0;
  border-radius: 8px;
  box-shadow: 0 0 8px 2px rgba(0,0,0,0.1);
  height: 56px;
  padding: 0 16px;
}

.field-wrap .country-code {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  border: none;
  outline: none;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%23888' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right center;
  font-family: 'Roboto', sans-serif;
  font-size: 16px;
  color: #000;
  margin-right: 12px;
  padding-right: 18px;
  border-right: 1px solid #ccc;
  cursor: pointer;
  max-width: 95px;
}

.field-wrap .country-code:focus { color: #00C7FF; }

.field-wrap input {
  flex: 1;
  width: 100%;
  border: none;
  outline: none;
  font-family: 'Roboto', sans-serif;
  font-size: 16px;
  color: #000;
  background: transparent;
}

.field-wrap input::placeholder { color: rgba(0,0,0,0.4); }

.toggle-eye {
  cursor: pointer;
  font-size: 18px;
  color: rgba(0,0,0,0.4);
  background: none;
  border: none;
  padding: 0;
}

.forgot-link {
  display: block;
  text-align: right;
  font-size: 13px;
  color: #00C7FF;
  text-decoration: none;
  margin-bottom: 24px;
}

.btn-primary {
  display: block;
  width: 100%;
  height: 52px;
  background: #00C7FF;
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  border: none;
  border-radius: 12px;
  box-shadow: 0 0 6px 2px rgba(0,43,61,0.2);
  cursor: pointer;
  font-family: 'Roboto', sans-serif;
}

.btn-primary:hover { background: #00b3e6; }

.switch-text {
  text-align: center;
  font-size: 14px;
  color: #555;
  margin-top: 16px;
}

.switch-text a { color: #00C7FF; font-weight: 700; text-decoration: none; }

.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: #aaa;
  font-size: 13px;
}
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: #e0e0e0; }

/* OTP */
.otp-inputs { display: flex; gap: 10px; justify-content: center; margin-bottom: 24px; }
.otp-inputs input {
  width: 48px;
  height: 56px;
  text-align: center;
  font-size: 20px;
  border: 1.5px solid #D0D0D0;
  border-radius: 8px;
  font-family: 'Roboto', sans-serif;
  outline: none;
}
.otp-inputs input:focus { border-color: #00C7FF; }

.resend-text { text-align: center; font-size: 14px; color: #888; }
.resend-text a { color: #00C7FF; text-decoration: none; font-weight: 500; }

.hint-text { font-size: 12px; color: #888; margin-top: -8px; margin-bottom: 16px; }

.back-link {
  display: block;
  text-align: center;
  font-size: 14px;
  color: #00C7FF;
  text-decoration: none;
  margin-top: 16px;
}

/* Two-column field row (signup, reset-password) */
.field-row { display: flex; gap: 16px; flex-wrap: wrap; }
.field-row .field-group { flex: 1; min-width: 220px; }

/* Desktop split layout */
@media (min-width: 1024px) {
  body { background: #fff; }
  .auth-shell { flex-direction: row; }

  .brand-panel {
    flex: 0 0 47%;
    background: linear-gradient(180deg, #00C7FF 0%, #0090C7 100%);
    padding: 0;
  }
  .brand-panel .back-btn { display: none; }
  .brand-panel .logo { width: 150px; height: 150px; margin-bottom: 24px; }
  .brand-panel .brand-name { font-size: 16px; letter-spacing: 3px; margin-bottom: 12px; }
  .brand-panel h1 { font-size: 28px; }
  .brand-panel p { font-size: 14px; max-width: 380px; }

  .form-panel { align-items: center; justify-content: center; }

  .form-card {
    flex: none;
    background: transparent;
    box-shadow: none;
    border-radius: 0;
    width: 100%;
    max-width: 440px;
    padding: 0;
  }

  .form-card h2 { text-align: left; font-size: 28px; }
  .form-card .subtitle { text-align: left; }
  .form-card .icon-circle { margin: 0 0 16px; }
  .forgot-link { margin-bottom: 16px; }

  .form-card.centered h2,
  .form-card.centered .subtitle { text-align: center; }
  .form-card.centered .icon-circle { margin: 0 auto 16px; }
}

/* ── Page transitions ─────────────────────────────── */
html { background: #0a0f1e; }
body { opacity: 0; transition: opacity .35s cubic-bezier(.4,0,.2,1); }
body.ready { opacity: 1; }
