/* ==========================================
   LOGIN PAGE STYLES - ORIGINAL DESIGN
   ========================================== */

/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  overflow: hidden;
  font-family: 'Courier New', monospace;
  background: #000;
}

/* ==========================================
   SCP-THEMED BOOT SCREEN
   ========================================== */

.boot-screen,
.logout-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000000;
  z-index: 9999;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  overflow-y: auto;
  padding: 2rem;
  /* Add red vignette effect */
  box-shadow: inset 0 0 200px rgba(204, 0, 0, 0.2);
}

.boot-container,
.logout-container {
  width: 90%;
  max-width: 900px;
  padding-top: 2rem;
  border: 1px solid rgba(204, 0, 0, 0.3);
  padding: 2rem;
  background: rgba(0, 0, 0, 0.8);
}

.boot-log,
.logout-log {
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  line-height: 1.6;
  color: #cccccc;
  text-shadow: 0 0 2px rgba(255, 255, 255, 0.3);
}

.boot-line {
  margin-bottom: 0.2rem;
  white-space: pre-wrap;
  word-wrap: break-word;
}

/* Typing cursor effect */
.boot-line:last-child::after {
  content: "▐";
  animation: cursorBlink 0.8s infinite;
  color: #cc0000;
  margin-left: 2px;
}

@keyframes cursorBlink {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

/* Warning pulse - more red */
@keyframes warningPulse {
  0%, 100% { 
    color: #cc0000;
    text-shadow: 0 0 10px rgba(204, 0, 0, 0.8);
  }
  50% { 
    color: #ff0000;
    text-shadow: 0 0 20px rgba(255, 0, 0, 1);
  }
}

/* Scan line effect - red tint */
.boot-screen::before,
.logout-screen::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    to bottom,
    transparent,
    rgba(204, 0, 0, 0.6),
    transparent
  );
  animation: scanline 4s linear infinite;
  pointer-events: none;
  z-index: 10;
}

@keyframes scanline {
  0% { transform: translateY(-10px); }
  100% { transform: translateY(calc(100vh + 10px)); }
}

/* Red static/noise overlay */
.boot-screen::after,
.logout-screen::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    repeating-linear-gradient(
      0deg,
      rgba(0, 0, 0, 0.15),
      rgba(0, 0, 0, 0.15) 1px,
      transparent 1px,
      transparent 2px
    );
  pointer-events: none;
  z-index: 1;
  opacity: 0.3;
}

/* CRT flicker effect */
.boot-screen,
.logout-screen {
  animation: flicker 0.15s infinite alternate;
}

@keyframes flicker {
  0%, 100% { opacity: 0.97; }
  50% { opacity: 1; }
}

/* Red glow for important sections */
.boot-line:has-text("SCP FOUNDATION"),
.boot-line:has-text("SECURE"),
.boot-line:has-text("CONTAIN"),
.boot-line:has-text("PROTECT") {
  text-shadow: 0 0 10px rgba(204, 0, 0, 0.8);
}

/* ==========================================
   LOGIN SCREEN
   ========================================== */

.login-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: opacity 0.5s;
}

.login-screen.hidden {
  opacity: 0;
  pointer-events: none;
}

.login-container {
  width: 90%;
  max-width: 440px;
  background: #000;
  border: 3px solid #cc0000;
  border-radius: 8px;
  padding: 2.5rem 2rem;
  box-shadow: 0 0 50px rgba(204, 0, 0, 0.6);
  position: relative;
}

/* Logo */
.login-logo {
  width: 120px;
  height: 120px;
  margin: 0 auto 1.5rem auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0 40px rgba(204, 0, 0, 1));
  animation: logoGlow 3s ease-in-out infinite;
}

/* Title */
.login-title {
  font-family: 'Courier New', monospace;
  font-size: 2rem;
  font-weight: bold;
  color: #fff;
  text-align: center;
  letter-spacing: 8px;
  margin: 0 0 1rem 0;
}

.login-divider {
  width: 100%;
  height: 2px;
  background: #cc0000;
  margin: 0 0 1rem 0;
}

.login-subtitle {
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  color: #cc0000;
  text-align: center;
  letter-spacing: 3px;
  margin-bottom: 2rem;
}

/* Access Info */
.login-access-info {
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  color: #999;
  text-align: center;
  letter-spacing: 2px;
  margin-bottom: 0.75rem;
  text-transform: uppercase;
}

.login-warning {
  font-family: 'Courier New', monospace;
  font-size: 0.75rem;
  color: #cc0000;
  text-align: center;
  letter-spacing: 1px;
  margin-bottom: 2rem;
}

/* Form */
.login-form {
  margin-bottom: 1rem;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: block;
  font-family: 'Courier New', monospace;
  font-size: 0.75rem;
  color: #999;
  letter-spacing: 1px;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
}

.input-wrapper {
  position: relative;
}

.form-input {
  width: 100%;
  padding: 0.75rem 2.5rem 0.75rem 0.75rem;
  background: #fff;
  border: 2px solid #333;
  border-radius: 3px;
  color: #000;
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  transition: all 0.3s;
}

.form-input:focus {
  outline: none;
  border-color: #cc0000;
  box-shadow: 0 0 10px rgba(204, 0, 0, 0.3);
}

.input-icon {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.2rem;
  pointer-events: none;
}

/* Checkbox */
.checkbox-group {
  margin-bottom: 2rem;
}

.checkbox-label {
  display: flex;
  align-items: center;
  cursor: pointer;
  user-select: none;
}

.checkbox-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-right: 0.75rem;
  cursor: pointer;
  accent-color: #cc0000;
}

.checkbox-text {
  font-family: 'Courier New', monospace;
  font-size: 0.75rem;
  color: #fff;
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* Error Message */
.error-message {
  background: rgba(204, 0, 0, 0.2);
  border: 1px solid #cc0000;
  border-radius: 3px;
  padding: 0.75rem;
  margin-bottom: 1rem;
  color: #cc0000;
  font-size: 0.85rem;
  text-align: center;
  font-family: 'Courier New', monospace;
}

.error-message.hidden {
  display: none;
}

/* Buttons */
.login-button {
  width: 100%;
  padding: 1rem;
  background: #cc0000;
  border: none;
  border-radius: 3px;
  color: #fff;
  font-family: 'Courier New', monospace;
  font-size: 0.95rem;
  font-weight: bold;
  letter-spacing: 2px;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.login-button:hover {
  background: #ff0000;
  box-shadow: 0 0 20px rgba(204, 0, 0, 0.8);
}

.login-button:active {
  transform: scale(0.98);
}

.emergency-button {
  width: 100%;
  padding: 0.9rem;
  background: transparent;
  border: 2px solid #fff;
  border-radius: 3px;
  color: #fff;
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  font-weight: bold;
  letter-spacing: 2px;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
}

.emergency-button:hover {
  border-color: #cc0000;
  color: #cc0000;
  box-shadow: 0 0 10px rgba(204, 0, 0, 0.3);
}

/* Footer */
.login-footer {
  margin-top: 2rem;
  text-align: center;
}

.footer-line {
  width: 100%;
  height: 1px;
  background: #333;
  margin-bottom: 1rem;
}

.login-footer p {
  font-family: 'Courier New', monospace;
  font-size: 0.65rem;
  color: #666;
  line-height: 1.6;
  margin: 0.25rem 0;
  letter-spacing: 0.5px;
}

/* ==========================================
   LOGOUT SCREEN
   ========================================== */

.logout-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: opacity 0.5s;
  z-index: 9999;
}

.logout-screen.hidden {
  opacity: 0;
  pointer-events: none;
}

.logout-container {
  width: 90%;
  max-width: 500px;
  background: #000;
  border: 2px solid #cc0000;
  border-radius: 8px;
  padding: 3rem 2rem;
  box-shadow: 0 0 50px rgba(204, 0, 0, 0.5);
}

.logout-content {
  text-align: center;
}

.logout-logo {
  width: 100px;
  height: 100px;
  margin: 0 auto 2rem auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logout-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0 20px rgba(204, 0, 0, 0.7));
  opacity: 0.9;
}

.logout-title {
  font-family: 'Courier New', monospace;
  font-size: 1.8rem;
  color: #fff;
  letter-spacing: 2px;
  margin-bottom: 1rem;
}

.logout-message {
  font-size: 1rem;
  color: #999;
  margin-bottom: 2rem;
  font-family: 'Courier New', monospace;
}

.logout-details {
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid #333;
  border-radius: 4px;
  padding: 1.5rem;
  margin-bottom: 2rem;
  text-align: left;
}

.logout-details p {
  font-size: 0.9rem;
  color: #999;
  margin-bottom: 0.5rem;
  display: flex;
  justify-content: space-between;
  font-family: 'Courier New', monospace;
}

.logout-details p:last-child {
  margin-bottom: 0;
}

.logout-details span {
  color: #fff;
  font-weight: bold;
}

.logout-return-btn {
  width: 100%;
  padding: 1rem;
  background: #cc0000;
  border: none;
  border-radius: 4px;
  color: #fff;
  font-family: 'Courier New', monospace;
  font-size: 1rem;
  font-weight: bold;
  letter-spacing: 2px;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
}

.logout-return-btn:hover {
  background: #ff0000;
  box-shadow: 0 0 20px rgba(204, 0, 0, 0.8);
}

/* ==========================================
   ANIMATIONS
   ========================================== */

@keyframes fadeOut {
  from { opacity: 1; }
  to { opacity: 0; }
}

/* ==========================================
   RESPONSIVE
   ========================================== */

@media (max-width: 768px) {
  .login-container {
    padding: 2rem 1.5rem;
  }

  .login-title {
    font-size: 1.6rem;
    letter-spacing: 6px;
  }

  .login-logo {
    width: 100px;
    height: 100px;
  }

  .boot-logo {
    width: 120px;
    height: 120px;
  }
}

@media (max-width: 480px) {
  .login-container {
    padding: 1.5rem 1rem;
    max-width: 95%;
  }

  .login-title {
    font-size: 1.3rem;
    letter-spacing: 4px;
  }

  .login-logo {
    width: 90px;
    height: 90px;
  }

  .boot-logo {
    width: 100px;
    height: 100px;
  }

  .logout-logo {
    width: 80px;
    height: 80px;
  }

  .form-input {
    font-size: 0.85rem;
    padding: 0.65rem 2.5rem 0.65rem 0.65rem;
  }

  .login-button,
  .emergency-button,
  .logout-return-btn {
    padding: 0.85rem;
    font-size: 0.85rem;
  }
}

/* ==========================================
   UTILITY CLASSES
   ========================================== */

.hidden {
  display: none !important;
}

/* Logo Image Styles - FIXED SIZE */
.scp-logo {
  width: 150px;
  height: 150px;
  margin: 0 auto 1.5rem auto;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.logo-image {
  width: 150px;
  height: 150px;
  max-width: 150px;
  max-height: 150px;
  object-fit: contain;
  filter: drop-shadow(0 0 30px rgba(204, 0, 0, 0.8));
  animation: logoGlow 3s ease-in-out infinite;
}

@keyframes logoGlow {
  0%, 100% {
    filter: drop-shadow(0 0 30px rgba(204, 0, 0, 0.8));
  }
  50% {
    filter: drop-shadow(0 0 50px rgba(204, 0, 0, 1));
  }
}

/* Remove old CSS logo styles if they exist */
.logo-circle,
.logo-arrows,
.arrow {
  display: none !important;
}

/* Responsive logo sizing */
@media (max-width: 768px) {
  .scp-logo {
    width: 120px;
    height: 120px;
  }
  
  .logo-image {
    width: 120px;
    height: 120px;
    max-width: 120px;
    max-height: 120px;
  }
}

@media (max-width: 480px) {
  .scp-logo {
    width: 100px;
    height: 100px;
  }
  
  .logo-image {
    width: 100px;
    height: 100px;
    max-width: 100px;
    max-height: 100px;
  }
}

/* Boot Screen Skip Button */
.skip-boot-btn {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  padding: 0.75rem 1.5rem;
  background: transparent;
  border: 2px solid var(--color-accent);
  border-radius: 4px;
  color: var(--color-accent);
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  font-weight: bold;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s;
  text-transform: uppercase;
  z-index: 10001;
}

.skip-boot-btn:hover {
  background: var(--color-accent);
  color: #000;
  box-shadow: 0 0 20px rgba(204, 0, 0, 0.8);
  transform: translateY(-2px);
}

.skip-boot-btn:active {
  transform: translateY(0);
}

/* Boot screen logo styles */
.boot-screen .boot-logo {
  width: 150px;
  height: 150px;
  margin: 0 auto 2rem auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.boot-screen .boot-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 0 30px rgba(204, 0, 0, 0.9));
  animation: logoGlow 2s ease-in-out infinite;
}

/* Responsive skip button */
@media (max-width: 768px) {
  .skip-boot-btn {
    bottom: 1.5rem;
    right: 1.5rem;
    padding: 0.65rem 1.25rem;
    font-size: 0.75rem;
  }
}

@media (max-width: 480px) {
  .skip-boot-btn {
    bottom: 1rem;
    right: 1rem;
    left: 1rem;
    width: calc(100% - 2rem);
    padding: 0.75rem;
    font-size: 0.7rem;
  }
}