@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@700;900&family=Special+Elite&family=Courier+Prime&display=swap');

:root {
  --gold: #D4AF37;
  --cream: #F5E6D3;
  --danger: #8B0000;
  --black: #0A0A0A;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Courier Prime', monospace;
  background: var(--black);
  color: var(--cream);
}

.title-font {
  font-family: 'Playfair Display', serif;
  font-weight: 900;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
  letter-spacing: 2px;
}

.subtitle-font {
  font-family: 'Special Elite', cursive;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
}

.body-font {
  font-family: 'Courier Prime', monospace;
  line-height: 1.6;
}

.game-bg {
  background: 
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 2px,
      rgba(212, 175, 55, 0.03) 2px,
      rgba(212, 175, 55, 0.03) 4px
    ),
    radial-gradient(ellipse at center, #1a1a1a 0%, #0a0a0a 100%);
  background-attachment: fixed;
  position: relative;
}

.game-bg::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 1px,
      rgba(255, 255, 255, 0.02) 1px,
      rgba(255, 255, 255, 0.02) 2px
    );
  pointer-events: none;
  opacity: 0.5;
}

.vintage-header {
  background: linear-gradient(180deg, rgba(212, 175, 55, 0.2) 0%, rgba(10, 10, 10, 0.9) 100%);
  border-bottom: 3px solid var(--gold);
  box-shadow: 0 4px 20px rgba(212, 175, 55, 0.3);
}

.vintage-panel {
  background: 
    linear-gradient(135deg, rgba(245, 230, 211, 0.05) 0%, rgba(10, 10, 10, 0.8) 100%),
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 10px,
      rgba(212, 175, 55, 0.02) 10px,
      rgba(212, 175, 55, 0.02) 20px
    );
  border: 2px solid var(--gold);
  box-shadow: 
    0 8px 32px rgba(212, 175, 55, 0.2),
    inset 0 0 20px rgba(212, 175, 55, 0.05);
  position: relative;
}

.vintage-panel::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(45deg, var(--gold), transparent, var(--gold));
  opacity: 0.1;
  pointer-events: none;
}

.vintage-button {
  background: linear-gradient(135deg, var(--gold) 0%, #8B7000 100%);
  color: var(--black);
  border: 2px solid var(--gold);
  padding: 12px 24px;
  font-family: 'Special Elite', cursive;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.4);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.vintage-button:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(212, 175, 55, 0.6);
  background: linear-gradient(135deg, #FFD700 0%, var(--gold) 100%);
}

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

.vintage-button-secondary {
  background: transparent;
  color: var(--gold);
  border: 2px solid var(--gold);
  padding: 12px 24px;
  font-family: 'Special Elite', cursive;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.vintage-button-secondary:hover {
  background: rgba(212, 175, 55, 0.1);
  transform: translateY(-2px);
}

.choice-button {
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.2) 0%, rgba(10, 10, 10, 0.8) 100%);
  color: var(--cream);
  border: 2px solid var(--gold);
  padding: 16px 20px;
  font-family: 'Courier Prime', monospace;
  font-size: 15px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 10px rgba(212, 175, 55, 0.2);
}

.choice-button:hover:not(:disabled) {
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.3) 0%, rgba(10, 10, 10, 0.9) 100%);
  transform: translateX(8px);
  box-shadow: 0 4px 20px rgba(212, 175, 55, 0.4);
  border-color: #FFD700;
}

.stat-bar {
  width: 100%;
  height: 12px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(212, 175, 55, 0.3);
  overflow: hidden;
  position: relative;
}

.stat-bar-fill {
  height: 100%;
  transition: width 0.5s ease;
  box-shadow: 0 0 10px currentColor;
}

.stat-bar-fill::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.text-gold {
  color: var(--gold);
}

.text-cream {
  color: var(--cream);
}

.text-danger {
  color: var(--danger);
}

.bg-gold {
  background-color: var(--gold);
}

.bg-danger {
  background-color: var(--danger);
}

.border-gold {
  border-color: var(--gold);
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: rgba(10, 10, 10, 0.5);
}

::-webkit-scrollbar-thumb {
  background: var(--gold);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #FFD700;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .title-font {
    font-size: 2.5rem !important;
  }
  
  .vintage-panel {
    padding: 1rem !important;
  }
  
  .choice-button {
    font-size: 14px;
    padding: 12px 16px;
  }
}

/* Film grain effect */
@keyframes grain {
  0%, 100% { transform: translate(0, 0); }
  10% { transform: translate(-5%, -10%); }
  20% { transform: translate(-15%, 5%); }
  30% { transform: translate(7%, -25%); }
  40% { transform: translate(-5%, 25%); }
  50% { transform: translate(-15%, 10%); }
  60% { transform: translate(15%, 0%); }
  70% { transform: translate(0%, 15%); }
  80% { transform: translate(3%, 35%); }
  90% { transform: translate(-10%, 10%); }
}

.game-bg::after {
  content: '';
  position: fixed;
  top: -50%;
  left: -50%;
  right: -50%;
  bottom: -50%;
  width: 200%;
  height: 200%;
  background: transparent url('data:image/svg+xml,%3Csvg viewBox="0 0 256 256" xmlns="http://www.w3.org/2000/svg"%3E%3Cfilter id="noise"%3E%3CfeTurbulence type="fractalNoise" baseFrequency="0.9" numOctaves="4" /%3E%3C/filter%3E%3Crect width="100%25" height="100%25" filter="url(%23noise)" opacity="0.05"/%3E%3C/svg%3E') repeat;
  pointer-events: none;
  animation: grain 1s steps(10) infinite;
  opacity: 0.4;
}