/* ============================================================
   Project AETest – Global Styles
   Dark mode, Valorant-inspired, glassmorphism
   ============================================================ */

/* --- Fonts & Reset --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --red: #ff4655;
  --red-dark: #c0313f;
  --red-glow: rgba(255, 70, 85, 0.25);
  --bg: #0d0e13;
  --bg-2: #13151c;
  --surface: rgba(255, 255, 255, 0.045);
  --border: rgba(255, 255, 255, 0.08);
  --border-red: rgba(255, 70, 85, 0.35);
  --text: #e8eaf0;
  --text-muted: #7a7f96;
  --text-dim: #4a4f65;
  --blue: #5b8df6;
  --purple: #9b6fff;
  --green: #3bcc6e;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
  --font: 'Outfit', system-ui, sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

/* --- Background decoration --- */
.bg-grid {
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
  z-index: 0;
}

.glow-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(100px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.35;
}

.glow-orb--1 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, #ff4655 0%, transparent 70%);
  top: -150px;
  right: -100px;
  animation: float1 12s ease-in-out infinite;
}

.glow-orb--2 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, #5b3aff 0%, transparent 70%);
  bottom: -100px;
  left: -80px;
  animation: float2 14s ease-in-out infinite;
}

@keyframes float1 {

  0%,
  100% {
    transform: translate(0, 0);
  }

  50% {
    transform: translate(-30px, 40px);
  }
}

@keyframes float2 {

  0%,
  100% {
    transform: translate(0, 0);
  }

  50% {
    transform: translate(30px, -30px);
  }
}

/* --- Glass card --- */
.glass {
  background: var(--surface);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

/* --- Utility --- */
.hidden {
  display: none !important;
}

/* ============================================================
   AUTH PAGE
   ============================================================ */
.auth-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
}

.auth-container {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
}

.auth-card {
  padding: 40px 36px 36px;
  box-shadow: var(--shadow), 0 0 0 1px var(--border-red) inset;
  animation: card-in 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

@keyframes card-in {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.97);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Brand */
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}

.brand-icon {
  width: 48px;
  height: 48px;
  background: rgba(255, 70, 85, 0.12);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 70, 85, 0.25);
}

.brand-name {
  display: block;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--text);
}

.brand-sub {
  display: block;
  font-size: 11.5px;
  font-weight: 400;
  color: var(--text-muted);
  letter-spacing: 0.3px;
}

/* Titles */
.auth-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 6px;
}

.auth-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 24px;
  line-height: 1.5;
}

/* Status message */
.status-msg {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  font-weight: 500;
  margin-bottom: 16px;
  border-left: 3px solid;
  animation: fade-in 0.2s ease;
}

.status-msg--error {
  background: rgba(255, 70, 85, 0.1);
  border-color: var(--red);
  color: #ff8a94;
}

.status-msg--success {
  background: rgba(59, 204, 110, 0.1);
  border-color: var(--green);
  color: #6de89a;
}

.status-msg--info {
  background: rgba(91, 141, 246, 0.1);
  border-color: var(--blue);
  color: #8db1ff;
}

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

/* Form */
.form-group {
  margin-bottom: 18px;
}

.form-label {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 7px;
}

.form-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.input-wrap {
  position: relative;
}

.form-input {
  width: 100%;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font);
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-input:focus {
  border-color: rgba(255, 70, 85, 0.5);
  box-shadow: 0 0 0 3px rgba(255, 70, 85, 0.1);
}

.form-input::placeholder {
  color: var(--text-dim);
}

.form-input--center {
  text-align: center;
  letter-spacing: 6px;
  font-size: 20px;
  font-weight: 600;
}

.toggle-pw {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  transition: color 0.2s;
}

.toggle-pw:hover {
  color: var(--text);
}

.auth-footer {
  margin-top: 20px;
  font-size: 11.5px;
  color: var(--text-dim);
  text-align: center;
  line-height: 1.5;
}

.auth-footer strong {
  color: var(--text-muted);
  font-weight: 500;
}

/* Step blocks (OAuth flow) */
.step-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 4px;
}

.step-header {
  display: flex;
  align-items: center;
  gap: 10px;
}

.step-badge {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  background: linear-gradient(135deg, var(--red), var(--red-dark));
  color: #fff;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px var(--red-glow);
}

.step-label {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}

.step-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.55;
}

.step-desc strong {
  color: var(--text);
}

.step-block {
  animation: fade-in 0.3s ease both;
}

/* URL paste input valid state */
.form-input--valid {
  border-color: rgba(59, 204, 110, 0.5) !important;
  box-shadow: 0 0 0 3px rgba(59, 204, 110, 0.1) !important;
}

/* Divider between steps */
.step-divider {
  margin: 8px 0;
}

.divider-line {
  height: 1px;
  background: var(--border);
  border-radius: 1px;
}



/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font);
  font-weight: 600;
  letter-spacing: 0.3px;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.18s ease;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.08);
  opacity: 0;
  transition: opacity 0.15s;
}

.btn:hover::after {
  opacity: 1;
}

.btn:active {
  transform: scale(0.97);
}

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: all;
}

.btn:disabled:hover::after {
  opacity: 0;
}

.btn:disabled:active {
  transform: none;
}

.btn--full {
  width: 100%;
  padding: 14px 20px;
  font-size: 15px;
}

.btn--primary {
  background: linear-gradient(135deg, var(--red), var(--red-dark));
  color: #fff;
  box-shadow: 0 4px 20px var(--red-glow);
}

.btn--primary:hover:not(:disabled) {
  box-shadow: 0 6px 28px rgba(255, 70, 85, 0.45);
  transform: translateY(-1px);
}

.btn--danger {
  background: linear-gradient(135deg, #ff2336, #c40020);
  color: #fff;
  box-shadow: 0 6px 24px rgba(255, 35, 54, 0.35);
}

.btn--danger:hover:not(:disabled) {
  box-shadow: 0 10px 36px rgba(255, 35, 54, 0.55);
  transform: translateY(-2px);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 13px;
  padding: 7px 14px;
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
}

.btn--small {
  font-size: 12.5px;
  padding: 6px 12px;
  border-radius: 6px;
}

.btn--xl {
  padding: 20px 40px;
  font-size: 17px;
  border-radius: 12px;
  width: 100%;
  max-width: 360px;
  letter-spacing: 0.5px;
}

.btn-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

/* Spinner */
.btn-loader {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ============================================================
   DASHBOARD PAGE
   ============================================================ */
.dashboard-page {
  padding-bottom: 60px;
}

.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 28px;
  border-radius: 0;
  border-left: none;
  border-right: none;
  border-top: none;
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.navbar-user {
  display: flex;
  align-items: center;
  gap: 14px;
}

.user-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  border: 1px solid var(--border);
}

.user-name {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
}

.dashboard-container {
  position: relative;
  z-index: 1;
  max-width: 680px;
  margin: 0 auto;
  padding: 40px 24px 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Dodge card */
.dodge-card {
  padding: 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  border-color: var(--border-red);
  box-shadow: var(--shadow), 0 0 60px rgba(255, 70, 85, 0.07);
}

.dodge-card__header {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: center;
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--text-dim);
  transition: background 0.3s;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.06);
}

.status-dot--active {
  background: var(--green);
  box-shadow: 0 0 0 3px rgba(59, 204, 110, 0.2);
  animation: pulse-green 1.5s ease infinite;
}

.status-dot--waiting {
  background: var(--text-muted);
}

.status-dot--danger {
  background: var(--red);
  box-shadow: 0 0 0 3px rgba(255, 70, 85, 0.2);
  animation: pulse-red 1.5s ease infinite;
}

@keyframes pulse-green {

  0%,
  100% {
    box-shadow: 0 0 0 3px rgba(59, 204, 110, 0.2);
  }

  50% {
    box-shadow: 0 0 0 7px rgba(59, 204, 110, 0.05);
  }
}

@keyframes pulse-red {

  0%,
  100% {
    box-shadow: 0 0 0 3px rgba(255, 70, 85, 0.2);
  }

  50% {
    box-shadow: 0 0 0 7px rgba(255, 70, 85, 0.05);
  }
}

.status-label {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
}

.dodge-title {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.3px;
}

.dodge-desc {
  font-size: 14px;
  color: var(--text-muted);
  max-width: 380px;
}

.dodge-result {
  width: 100%;
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  border-left: 3px solid;
  text-align: left;
  animation: fade-in 0.25s ease;
}

.dodge-result--success {
  background: rgba(59, 204, 110, 0.1);
  border-color: var(--green);
  color: #6de89a;
}

.dodge-result--error {
  background: rgba(255, 70, 85, 0.1);
  border-color: var(--red);
  color: #ff8a94;
}

.dodge-result--info {
  background: rgba(91, 141, 246, 0.1);
  border-color: var(--blue);
  color: #8db1ff;
}

.dodge-hint {
  font-size: 12px;
  color: var(--text-dim);
}

/* Info grid */
.info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

@media (max-width: 520px) {
  .info-grid {
    grid-template-columns: 1fr;
  }

  .auth-card {
    padding: 28px 20px;
  }

  .navbar {
    padding: 12px 16px;
  }
}

.info-card {
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.info-card__icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.info-card__icon--blue {
  background: rgba(91, 141, 246, 0.15);
  color: var(--blue);
}

.info-card__icon--purple {
  background: rgba(155, 111, 255, 0.15);
  color: var(--purple);
}

.info-card__icon--green {
  background: rgba(59, 204, 110, 0.15);
  color: var(--green);
}

.info-card__body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.info-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  color: var(--text-dim);
  font-weight: 600;
}

.info-value {
  font-size: 15px;
  font-weight: 700;
  truncate: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}

.info-value--green {
  color: var(--green);
}

.badge {
  display: inline-block;
  font-size: 10.5px;
  font-weight: 600;
  padding: 2px 7px;
  background: rgba(91, 141, 246, 0.15);
  color: var(--blue);
  border-radius: 20px;
  border: 1px solid rgba(91, 141, 246, 0.25);
  vertical-align: middle;
  margin-left: 4px;
}

/* How-to */
.howto {
  padding: 24px 28px;
}

.howto__title {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.howto__steps {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.howto__steps li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
}

.howto__steps li strong {
  color: var(--text);
}

.step-num {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  background: rgba(255, 70, 85, 0.1);
  border: 1px solid rgba(255, 70, 85, 0.25);
  color: var(--red);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}