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

:root {
  --auth-primary: #e52628;
  --auth-secondary: #b91c1c;
  --auth-text: #1a1a1a;
  --auth-bg: #0f172a;
  --glass-bg: rgba(255, 255, 255, 0.95);
  --glass-border: rgba(255, 255, 255, 0.3);
}

.auth-body {
  font-family: "Inter", sans-serif;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at top right, #3d0000, #0a0a0a);
  position: relative;
  overflow: hidden;
  margin: 0;
  padding: 20px;
}

/* Updated Animated Background Shapes to Red */
.auth-shape {
  position: absolute;
  filter: blur(100px);
  z-index: 0;
  border-radius: 50%;
  opacity: 0.6;
}

.shape-1 {
  width: 500px;
  height: 500px;
  background: rgba(229, 38, 40, 0.3);
  top: -150px;
  left: -150px;
  animation: flow 25s infinite alternate;
}

.shape-2 {
  width: 400px;
  height: 400px;
  background: rgba(185, 28, 28, 0.2);
  bottom: -100px;
  right: -100px;
  animation: flow 20s infinite alternate-reverse;
}

@keyframes flow {
  from {
    transform: translate(0, 0) scale(1);
  }
  to {
    transform: translate(150px, 150px) scale(1.2);
  }
}

/* Premium Glass Card */
.auth-card {
  background: var(--glass-bg);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border: 1px solid var(--glass-border);
  border-radius: 32px;
  padding: 50px 40px;
  width: 100%;
  max-width: 500px;
  box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.5);
  position: relative;
  z-index: 1;
  animation: fadeInUp 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.auth-card h2 {
  font-family: "Jost", sans-serif;
  color: var(--auth-text);
  font-weight: 700;
  margin-bottom: 10px;
  text-align: center;
  font-size: 28px;
  letter-spacing: -0.5px;
}

.auth-card p.subtitle {
  color: #64748b;
  text-align: center;
  margin-bottom: 35px;
  font-size: 15px;
}

/* Form Styles */
.form-group {
  margin-bottom: 22px;
}

.form-label {
  display: block;
  font-weight: 600;
  color: #334155;
  margin-bottom: 10px;
  font-size: 14px;
}

.auth-input {
  width: 100%;
  padding: 14px 18px;
  background: #f8fafc;
  border: 2px solid #f1f5f9;
  border-radius: 16px;
  color: var(--auth-text);
  font-size: 15px;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

.auth-input:focus {
  outline: none;
  border-color: var(--auth-primary);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(229, 38, 40, 0.1);
}

.auth-btn {
  width: 100%;
  padding: 16px;
  background: var(--auth-primary);
  color: white;
  border: none;
  border-radius: 16px;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  margin-top: 12px;
  box-shadow: 0 8px 20px -6px rgba(229, 38, 40, 0.4);
}

.auth-btn:hover {
  transform: translateY(-3px);
  background: var(--auth-secondary);
  box-shadow: 0 12px 25px -5px rgba(229, 38, 40, 0.5);
}

.auth-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

/* Social Login Styling */
.social-auth-wrapper {
  margin-top: 25px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.google-auth-wrapper {
  display: flex;
  justify-content: center;
  width: 100%;
  max-width: 320px;
}

.apple-signin-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  max-width: 320px;
  padding: 14px;
  background: #000;
  color: #fff;
  border: none;
  border-radius: 16px;
  font-size: 15px;
  font-weight: 600;
  transition: 0.3s ease;
}

.apple-signin-btn:hover {
  background: #262626;
  transform: translateY(-2px);
}

.divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 30px 0;
  color: #94a3b8;
  font-size: 13px;
  font-weight: 500;
}

.divider::before,
.divider::after {
  content: "";
  flex: 1;
  border-bottom: 1px solid #e2e8f0;
}

.divider:not(:empty)::before {
  margin-right: 1.5em;
}
.divider:not(:empty)::after {
  margin-left: 1.5em;
}

.auth-footer {
  margin-top: 30px;
  text-align: center;
  font-size: 14px;
  color: #64748b;
  font-weight: 500;
}

.auth-footer a {
  color: var(--auth-primary);
  text-decoration: none;
  font-weight: 700;
  margin-left: 4px;
}

.auth-footer a:hover {
  text-decoration: underline;
}

/* Utilities */
.text-primary {
  color: var(--auth-primary) !important;
}
.text-main {
  color: var(--auth-primary) !important;
}
.fw-600 {
  font-weight: 600;
}
.font-12 {
  font-size: 12px;
}

.pass-wrapper {
  position: relative;
}
.pass-toggle {
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  cursor: pointer;
  padding: 5px;
  z-index: 5;
}

.custom-alert {
  padding: 14px 20px;
  border-radius: 16px;
  margin-bottom: 25px;
  font-size: 14px;
  font-weight: 600;
  display: none;
  animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.alert-error {
  background: #fff1f2;
  color: #be123c;
  border: 1px solid #fecdd3;
}

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

/* Animations */
.animated {
  animation-duration: 1s;
  animation-fill-mode: both;
}
.shake {
  animation-name: shake;
}
@keyframes shake {
  from,
  to {
    transform: translate3d(0, 0, 0);
  }
  10%,
  30%,
  50%,
  70%,
  90% {
    transform: translate3d(-5px, 0, 0);
  }
  20%,
  40%,
  60%,
  80% {
    transform: translate3d(5px, 0, 0);
  }
}
.rotateIn {
  animation-name: rotateIn;
}
@keyframes rotateIn {
  from {
    transform-origin: center;
    transform: rotate3d(0, 0, 1, -200deg);
    opacity: 0;
  }
  to {
    transform-origin: center;
    transform: translate3d(0, 0, 0);
    opacity: 1;
  }
}
.bounceIn {
  animation-name: bounceIn;
  animation-duration: 0.75s;
}
@keyframes bounceIn {
  from,
  20%,
  40%,
  60%,
  80%,
  to {
    animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
  }
  0% {
    opacity: 0;
    transform: scale3d(0.3, 0.3, 0.3);
  }
  20% {
    transform: scale3d(1.1, 1.1, 1.1);
  }
  40% {
    transform: scale3d(0.9, 0.9, 0.9);
  }
  60% {
    opacity: 1;
    transform: scale3d(1.03, 1.03, 1.03);
  }
  80% {
    transform: scale3d(0.97, 0.97, 0.97);
  }
  to {
    opacity: 1;
    transform: scale3d(1, 1, 1);
  }
}

/* Auth tabs */
.auth-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 28px;
  background: #f1f5f9;
  padding: 6px;
  border-radius: 16px;
}

.auth-tab {
  flex: 1;
  padding: 12px 16px;
  border: none;
  background: transparent;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
  transition: all 0.25s ease;
}

.auth-tab:hover {
  color: var(--auth-primary);
}

.auth-tab.active {
  background: #fff;
  color: var(--auth-primary);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.auth-subtabs {
  display: flex;
  gap: 6px;
  margin-bottom: 20px;
}

.auth-subtab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 12px;
  border: 2px solid #f1f5f9;
  background: #f8fafc;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
  transition: all 0.2s ease;
}

.auth-subtab i {
  font-size: 12px;
  opacity: 0.85;
}

.auth-subtab.active {
  border-color: var(--auth-primary);
  background: #fff;
  color: var(--auth-primary);
}

.auth-tab-panel {
  display: none;
}

.auth-tab-panel.active {
  display: block;
}

.auth-btn-outline {
  background: transparent;
  color: var(--auth-primary);
  border: 2px solid var(--auth-primary);
  box-shadow: none;
}

.auth-btn-outline:hover {
  background: rgba(229, 38, 40, 0.06);
  transform: translateY(-2px);
  box-shadow: none;
}

/* OTP giriş akışı */
.auth-otp-hint {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 0 20px;
  padding: 12px 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  font-size: 13px;
  line-height: 1.5;
  color: #64748b;
}

.auth-otp-hint i {
  color: var(--auth-primary);
  margin-top: 2px;
  flex-shrink: 0;
}

.otp-step {
  animation: fadeIn 0.35s ease;
}

.otp-sent-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  margin-bottom: 22px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 16px;
}

.otp-sent-banner > i {
  font-size: 22px;
  color: #15803d;
  flex-shrink: 0;
}

.otp-sent-banner strong {
  display: block;
  font-size: 14px;
  color: #15803d;
  margin-bottom: 2px;
}

.otp-sent-banner span {
  display: block;
  font-size: 13px;
  color: #166534;
  font-weight: 500;
}

.otp-change-phone {
  margin-left: auto;
  flex-shrink: 0;
  border: none;
  background: transparent;
  color: var(--auth-primary);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 0;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.otp-change-phone:hover {
  color: var(--auth-secondary);
}

.auth-otp-input {
  text-align: center;
  font-size: 28px !important;
  letter-spacing: 12px;
  font-weight: 700;
  padding: 18px 16px !important;
  font-family: "Jost", monospace, sans-serif;
}

.auth-otp-input::placeholder {
  letter-spacing: 6px;
  font-size: 22px;
  color: #cbd5e1;
  font-weight: 400;
}

.otp-resend-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 18px;
  font-size: 13px;
  color: #64748b;
}

.otp-resend-link {
  border: none;
  background: transparent;
  color: var(--auth-primary);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.otp-resend-link:disabled {
  color: #94a3b8;
  cursor: not-allowed;
  text-decoration: none;
}

.otp-resend-link:not(:disabled):hover {
  color: var(--auth-secondary);
}

.otp-countdown {
  font-size: 12px;
  color: #94a3b8;
  font-weight: 500;
}

.font-14 {
  font-size: 14px;
}
.text-muted {
  color: #64748b;
}
