/* =====================================================
   Mythic SMP – Auth Page Styles
   Matching the design language of mythicsmp.de
   ===================================================== */

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

/* ── Page Reset ── */
.mythic-auth-page {
  margin: 0;
  min-height: 100vh;
  background: #0a0c10;
  font-family: 'Nunito', sans-serif;
  color: #e8dfc8;
  overflow: hidden;
}

/* ── Background ── */
.mythic-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(20, 60, 20, 0.55) 0%, transparent 60%),
    linear-gradient(180deg, #060809 0%, #0d1410 40%, #0a0c10 100%);
}

.mythic-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.35;
}

.mythic-glow-1 {
  width: 600px; height: 600px;
  top: -200px; left: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, #2d7a2d 0%, transparent 70%);
  animation: glowPulse 8s ease-in-out infinite;
}

.mythic-glow-2 {
  width: 400px; height: 400px;
  bottom: -100px; left: -100px;
  background: radial-gradient(circle, #1a4a2a 0%, transparent 70%);
  animation: glowPulse 11s ease-in-out infinite 2s;
}

.mythic-glow-3 {
  width: 350px; height: 350px;
  bottom: 0; right: -80px;
  background: radial-gradient(circle, #3a7a1a 0%, transparent 70%);
  animation: glowPulse 9s ease-in-out infinite 4s;
}

@keyframes glowPulse {
  0%, 100% { opacity: 0.28; transform: translateX(-50%) scale(1); }
  50%       { opacity: 0.45; transform: translateX(-50%) scale(1.08); }
}

.mythic-glow-2, .mythic-glow-3 {
  animation-name: glowPulse2;
}
@keyframes glowPulse2 {
  0%, 100% { opacity: 0.22; }
  50%       { opacity: 0.42; }
}

/* Subtle grid/stone texture overlay */
.mythic-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.012) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.012) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}

/* ── Layout ── */
.mythic-auth-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}

.mythic-auth-center {
  width: 100%;
  max-width: 420px;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* ── Flash Messages ── */
.mythic-flash-stack {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mythic-flash {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  border-radius: 0.6rem;
  font-size: 0.9rem;
  border: 1px solid transparent;
}

.mythic-flash-error {
  background: rgba(180, 40, 40, 0.18);
  border-color: rgba(200, 60, 60, 0.35);
  color: #f59e8a;
}

.mythic-flash-success {
  background: rgba(40, 140, 60, 0.18);
  border-color: rgba(60, 180, 80, 0.35);
  color: #86efac;
}

.mythic-flash button {
  background: none;
  border: none;
  color: inherit;
  cursor: pointer;
  font-size: 1.2rem;
  opacity: 0.7;
  line-height: 1;
  padding: 0 0.2rem;
}

/* ── Card ── */
.mythic-login-card {
  background: linear-gradient(160deg, rgba(14, 20, 14, 0.92), rgba(8, 14, 10, 0.96));
  border: 1px solid rgba(70, 120, 50, 0.28);
  border-radius: 1.1rem;
  padding: 2.5rem 2.25rem 2rem;
  box-shadow:
    0 0 0 1px rgba(80, 160, 60, 0.08),
    0 32px 64px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(150, 220, 100, 0.07);
  backdrop-filter: blur(20px);
  position: relative;
  overflow: hidden;
}

/* Corner rune decoration */
.mythic-login-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, #4aaa30 30%, #6dcc45 50%, #4aaa30 70%, transparent);
  border-radius: 1rem 1rem 0 0;
}

.mythic-login-card::after {
  content: '⬡';
  position: absolute;
  top: -0.6rem; left: 50%;
  transform: translateX(-50%);
  font-size: 1.25rem;
  color: #4aaa30;
  filter: drop-shadow(0 0 8px #4aaa30);
}

/* ── Logo Area ── */
.mythic-logo-area {
  text-align: center;
  margin-bottom: 2rem;
}

.mythic-diamond {
  width: 52px;
  height: 52px;
  margin: 0 auto 1rem;
  background: linear-gradient(135deg, #2ab540 0%, #1a7a30 40%, #0d4a1a 100%);
  clip-path: polygon(50% 0%, 100% 35%, 100% 65%, 50% 100%, 0% 65%, 0% 35%);
  box-shadow:
    0 0 0 1px rgba(80, 200, 80, 0.3),
    0 0 24px rgba(60, 180, 60, 0.4);
  animation: diamondGlow 3s ease-in-out infinite;
}

@keyframes diamondGlow {
  0%, 100% { box-shadow: 0 0 0 1px rgba(80,200,80,0.3), 0 0 24px rgba(60,180,60,0.4); }
  50%       { box-shadow: 0 0 0 1px rgba(80,200,80,0.5), 0 0 40px rgba(60,220,60,0.6); }
}

.mythic-title {
  display: block;
  font-family: 'Cinzel', serif;
  font-weight: 700;
  font-size: 1.7rem;
  letter-spacing: 0.06em;
  background: linear-gradient(135deg, #a8e890 0%, #5dcc40 40%, #3aaa20 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.4rem;
}

.mythic-subtitle {
  color: rgba(200, 220, 180, 0.55);
  font-size: 0.85rem;
  margin: 0;
  font-weight: 400;
}

/* ── Form ── */
.mythic-form {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.mythic-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.mythic-field label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(180, 210, 150, 0.7);
}

.mythic-field input {
  background: rgba(6, 12, 8, 0.7);
  border: 1px solid rgba(60, 100, 45, 0.35);
  border-radius: 0.6rem;
  padding: 0.8rem 1rem;
  color: #d8ecca;
  font-size: 0.95rem;
  font-family: 'Nunito', sans-serif;
  transition: border-color 200ms, box-shadow 200ms;
  outline: none;
}

.mythic-field input::placeholder {
  color: rgba(160, 190, 140, 0.35);
}

.mythic-field input:focus {
  border-color: rgba(80, 180, 60, 0.6);
  box-shadow: 0 0 0 3px rgba(60, 160, 40, 0.15), 0 0 16px rgba(60, 160, 40, 0.1);
}

/* ── Remember Me ── */
.mythic-remember {
  margin-top: -0.2rem;
}

.mythic-checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: rgba(200, 220, 170, 0.75);
  user-select: none;
}

.mythic-checkbox-label input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.mythic-checkmark {
  width: 18px;
  height: 18px;
  min-width: 18px;
  background: rgba(6, 12, 8, 0.7);
  border: 1.5px solid rgba(60, 110, 45, 0.45);
  border-radius: 0.3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 160ms, border-color 160ms, box-shadow 160ms;
}

.mythic-checkmark::after {
  content: '';
  width: 5px;
  height: 9px;
  border: 2px solid transparent;
  border-top: none;
  border-left: none;
  transform: rotate(45deg) translateY(-1px);
  transition: border-color 160ms;
}

.mythic-checkbox-label input:checked ~ .mythic-checkmark {
  background: linear-gradient(135deg, #2a9a20, #1a7018);
  border-color: #3aaa28;
  box-shadow: 0 0 10px rgba(50, 180, 40, 0.35);
}

.mythic-checkbox-label input:checked ~ .mythic-checkmark::after {
  border-color: #ffffff;
}

/* ── Primary Button ── */
.mythic-btn-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.9rem 1.5rem;
  background: linear-gradient(135deg, #2aaa20 0%, #1a8018 50%, #156015 100%);
  color: #e8f8e0;
  border: 1px solid rgba(80, 200, 60, 0.3);
  border-radius: 0.7rem;
  font-family: 'Cinzel', serif;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: transform 180ms, box-shadow 180ms, background 180ms;
  box-shadow: 0 4px 20px rgba(30, 160, 20, 0.3), 0 1px 0 rgba(200, 255, 180, 0.1) inset;
  margin-top: 0.4rem;
}

.mythic-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(40, 180, 30, 0.45), 0 1px 0 rgba(200, 255, 180, 0.12) inset;
  background: linear-gradient(135deg, #30bb25 0%, #1e9020 50%, #186820 100%);
}

.mythic-btn-primary:active {
  transform: translateY(0);
}

.mythic-btn-primary svg {
  transition: transform 200ms;
}

.mythic-btn-primary:hover svg {
  transform: translateX(3px);
}

/* ── Auth Switch ── */
.mythic-switch {
  text-align: center;
  margin: 1.2rem 0 0;
  font-size: 0.88rem;
  color: rgba(180, 200, 155, 0.55);
}

.mythic-switch a {
  color: #5acc3a;
  font-weight: 600;
  text-decoration: none;
  transition: color 150ms;
}

.mythic-switch a:hover {
  color: #78dd58;
  text-decoration: underline;
}

/* ── Responsive ── */
@media (max-width: 460px) {
  .mythic-login-card {
    padding: 2rem 1.5rem 1.75rem;
  }

  .mythic-title {
    font-size: 1.4rem;
  }
}
