@import "../shared/css/editorial-ui.css";

@tailwind base;
@tailwind components;
@tailwind utilities;

body {
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

.mr-history-page {
  background:
    radial-gradient(circle at top left, rgba(153, 246, 228, 0.55), transparent 30%),
    radial-gradient(circle at bottom right, rgba(191, 219, 254, 0.7), transparent 28%),
    linear-gradient(180deg, #f8fafc 0%, #eff6ff 100%);
}

.mr-train-page {
  background:
    radial-gradient(circle at top right, rgba(186, 230, 253, 0.85), transparent 32%),
    radial-gradient(circle at bottom left, rgba(254, 215, 170, 0.75), transparent 28%),
    linear-gradient(180deg, #f8fafc 0%, #fff7ed 100%);
}

#authShell.hidden,
#appShell.hidden,
[id^="tab"].hidden,
[id^="authPanel"].hidden {
  display: none !important;
}

.mr-nav-item.active {
  background-color: #f5f4ed;
  border-left-color: #c96442;
  color: #c96442;
}

.material-symbols-outlined {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: inherit;
  font-size: 1em;
  line-height: 1;
}

.auth-screen {
  background: radial-gradient(ellipse at 20% 60%, #0d2444 0%, #07111f 45%, #050d1a 100%);
}

.auth-bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(37, 99, 235, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 99, 235, 0.07) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}

.auth-scan-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, rgba(56, 189, 248, 0.7) 50%, transparent 100%);
  box-shadow: 0 0 18px 3px rgba(56, 189, 248, 0.25);
  animation: authScan 7s linear infinite;
  pointer-events: none;
}

@keyframes authScan {
  0% { top: -2px; opacity: 0; }
  5% { opacity: 1; }
  95% { opacity: 1; }
  100% { top: 100%; opacity: 0; }
}

.auth-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(37, 99, 235, 0.28);
  border-radius: 9999px;
  background: rgba(37, 99, 235, 0.12);
  padding: 6px 14px;
  color: #93c5fd;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  backdrop-filter: blur(4px);
}

.auth-badge__dot {
  width: 6px;
  height: 6px;
  flex-shrink: 0;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 8px #22c55e;
  animation: authDotBlink 2s ease-in-out infinite;
}

@keyframes authDotBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.auth-logo-icon {
  display: flex;
  width: 76px;
  height: 76px;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(99, 179, 237, 0.3);
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(29, 78, 216, 0.7) 0%, rgba(37, 99, 235, 0.35) 100%);
  box-shadow: 0 0 36px rgba(37, 99, 235, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.auth-title-glow {
  background: linear-gradient(135deg, #ffffff 0%, #bfdbfe 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 30px rgba(96, 165, 250, 0.4));
}

.auth-feature-card {
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  padding: 16px 14px;
  backdrop-filter: blur(8px);
  transition: all 0.22s;
}

.auth-feature-card:hover {
  border-color: rgba(96, 165, 250, 0.4);
  background: rgba(37, 99, 235, 0.1);
  transform: translateY(-3px);
}

.auth-feature-icon {
  margin-bottom: 8px;
  font-size: 20px;
}

.auth-login-card {
  border: 1px solid rgba(99, 179, 237, 0.18);
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.65);
  padding: 36px 32px;
  box-shadow: 0 0 70px rgba(37, 99, 235, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(28px);
}

.auth-input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid rgba(99, 179, 237, 0.2);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  padding: 12px 16px;
  color: #f1f5f9;
  font-size: 14px;
  outline: none;
  transition: all 0.2s;
}

.auth-input::placeholder {
  color: rgba(148, 163, 184, 0.45);
}

.auth-input:focus {
  border-color: rgba(96, 165, 250, 0.55);
  background: rgba(37, 99, 235, 0.08);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.18);
}

.auth-label {
  display: block;
  margin-bottom: 8px;
  color: #64748b;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.auth-submit-btn {
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%);
  padding: 13px 28px;
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.02em;
  box-shadow: 0 4px 22px rgba(37, 99, 235, 0.42);
  cursor: pointer;
  transition: all 0.2s;
}

.auth-submit-btn:hover {
  background: linear-gradient(135deg, #1e40af 0%, #1d4ed8 100%);
  box-shadow: 0 6px 30px rgba(37, 99, 235, 0.6);
  transform: translateY(-1px);
}

.auth-tab-bar {
  display: flex;
  gap: 4px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  padding: 4px;
}

.auth-tab {
  flex: 1;
  border: none;
  border-radius: 9px;
  background: transparent;
  padding: 9px 0;
  color: rgba(148, 163, 184, 0.75);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.auth-tab.active {
  background: linear-gradient(135deg, #1d4ed8, #2563eb);
  color: #ffffff;
  box-shadow: 0 2px 14px rgba(37, 99, 235, 0.45);
}

.auth-demo-hint {
  border: 1px solid rgba(37, 99, 235, 0.2);
  border-radius: 10px;
  background: rgba(30, 58, 138, 0.2);
  padding: 12px 14px;
  color: #94a3b8;
  font-size: 12px;
}

.auth-demo-hint code {
  color: #93c5fd;
  font-weight: 700;
}

.auth-demo-hint--warning {
  margin-bottom: 16px;
  border-color: rgba(245, 158, 11, 0.28);
  background: rgba(120, 53, 15, 0.18);
}
