/* ===================================
   Smith Family Secret Santa 2025
   Main Styles - Cozy Christmas Theme
   =================================== */

:root {
  /* Christmas Colors */
  --christmas-red: #b91c1c;
  --christmas-red-dark: #991b1b;
  --christmas-red-darker: #7f1d1d;
  --christmas-green: #166534;
  --christmas-green-light: #22c55e;
  --christmas-gold: #fbbf24;
  --christmas-cream: #fef3c7;
  --snow-white: #ffffff;
  --soft-white: #fafafa;
  
  /* Typography */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'Crimson Pro', Georgia, serif;
  
  /* Shadows */
  --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.15);
  --shadow-glow: 0 0 40px rgba(251, 191, 36, 0.3);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  font-family: var(--font-body);
  background: linear-gradient(135deg, var(--christmas-red) 0%, var(--christmas-red-dark) 50%, var(--christmas-red-darker) 100%);
  min-height: 100vh;
  color: var(--snow-white);
  overflow-x: hidden;
}

/* Snow Container */
#snow-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

/* ===================================
   LOGIN PAGE STYLES
   =================================== */

.login-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 2rem;
}

.login-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  max-width: 1200px;
  width: 100%;
  gap: 2rem;
  z-index: 10;
  position: relative;
}

/* Left side - Form */
.login-form-section {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.tree-icon {
  font-size: 2rem;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

.logo-text {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  opacity: 0.9;
}

.login-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  text-shadow: 2px 4px 8px rgba(0, 0, 0, 0.2);
}

.login-title .highlight {
  color: var(--christmas-gold);
  text-shadow: 0 0 30px rgba(251, 191, 36, 0.5);
}

.login-subtitle {
  font-size: 1.2rem;
  opacity: 0.9;
  margin-bottom: 2.5rem;
  line-height: 1.6;
  max-width: 400px;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 0.5rem;
  opacity: 0.8;
}

.name-dropdown {
  width: 100%;
  max-width: 320px;
  padding: 1rem 1.5rem;
  font-family: var(--font-body);
  font-size: 1.1rem;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--snow-white);
  cursor: pointer;
  transition: all 0.3s ease;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 1.2rem;
}

.name-dropdown:hover,
.name-dropdown:focus {
  border-color: var(--christmas-gold);
  background-color: rgba(255, 255, 255, 0.15);
  outline: none;
}

.name-dropdown option {
  background: var(--christmas-red-dark);
  color: var(--snow-white);
  padding: 0.5rem;
}

.password-input {
  width: 100%;
  max-width: 320px;
  padding: 1rem 1.5rem;
  font-family: var(--font-body);
  font-size: 1.1rem;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--snow-white);
  transition: all 0.3s ease;
}

.password-input::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.password-input:hover,
.password-input:focus {
  border-color: var(--christmas-gold);
  background-color: rgba(255, 255, 255, 0.15);
  outline: none;
}

.error-message {
  color: #fca5a5;
  font-size: 0.95rem;
  margin-bottom: 1rem;
  min-height: 1.5em;
}

.enter-button {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 2.5rem;
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--christmas-red-dark);
  background: var(--snow-white);
  border: none;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-soft);
}

.enter-button:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow), var(--shadow-soft);
  background: var(--christmas-cream);
}

.enter-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.enter-button span {
  font-size: 1.3rem;
}

.budget-note {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 2rem;
  padding: 0.75rem 1.25rem;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 30px;
  font-size: 0.95rem;
}

.budget-note strong {
  color: var(--christmas-gold);
}

/* Right side - Santa */
.santa-section {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.santa-image-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  max-height: 80vh;
}

.santa-image {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  animation: float 6s ease-in-out infinite;
  /* Soft radial mask to blur/fade edges */
  mask-image: radial-gradient(ellipse 70% 70% at center, black 40%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at center, black 40%, transparent 100%);
}

/* Glowing ambient effect behind image */
.santa-image-wrapper::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120%;
  height: 120%;
  background: radial-gradient(ellipse at center, rgba(255, 255, 255, 0.15) 0%, transparent 60%);
  z-index: -1;
  filter: blur(30px);
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-15px); }
}

/* Fallback if no Santa image */
.santa-section .santa-image-wrapper::after {
  content: '🎅';
  font-size: 15rem;
  position: absolute;
  opacity: 0;
  transition: opacity 0.3s;
}

.santa-image[src=""],
.santa-image:not([src]) {
  display: none;
}

.santa-image[src=""] ~ .santa-section::after,
.santa-image:not([src]) ~ .santa-section::after {
  opacity: 1;
}

/* Mobile Responsive */
@media (max-width: 900px) {
  .login-container {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .login-form-section {
    align-items: center;
  }
  
  .logo {
    justify-content: center;
  }
  
  .login-subtitle {
    margin-left: auto;
    margin-right: auto;
  }
  
  .name-dropdown {
    max-width: 100%;
  }
  
  .santa-section {
    order: -1;
    max-height: 300px;
  }
  
  .santa-image {
    max-height: 250px;
  }
}

/* ===================================
   UTILITY CLASSES
   =================================== */

.hidden {
  display: none !important;
}

.fade-in {
  animation: fadeIn 0.5s ease forwards;
}

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

