/* Bretton Woods Conference Simulation Styles */

:root {
  --blue-600: #2563eb;
  --red-600: #dc2626;
  --purple-600: #9333ea;
  --amber-600: #d97706;
  --green-600: #16a34a;
  --orange-600: #ea580c;
  --cyan-600: #0891b2;
  --slate-700: #334155;
  --slate-800: #1e293b;
  --slate-900: #0f172a;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: linear-gradient(135deg, #1e3a8a 0%, #1e293b 100%);
  min-height: 100vh;
  padding: 20px;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
}

/* Header Styles */
.header {
  text-align: center;
  color: white;
  margin-bottom: 40px;
}

.header h1 {
  font-size: 3rem;
  font-weight: bold;
  margin-bottom: 10px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.header p {
  font-size: 1.25rem;
  opacity: 0.9;
}

/* Card Styles */
.card {
  background: white;
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  margin-bottom: 20px;
}

/* Start Screen */
.start-screen {
  text-align: center;
}

.country-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.country-card {
  padding: 20px;
  border-radius: 8px;
  color: white;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.country-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

.country-card h3 {
  font-size: 1.5rem;
  margin-bottom: 12px;
}

.country-card ul {
  list-style: none;
  text-align: left;
  font-size: 0.9rem;
}

.country-card li {
  margin-bottom: 8px;
  padding-left: 20px;
  position: relative;
}

.country-card li:before {
  content: "→";
  position: absolute;
  left: 0;
}

/* Color classes */
.bg-blue-600 { background-color: var(--blue-600); }
.bg-red-600 { background-color: var(--red-600); }
.bg-purple-600 { background-color: var(--purple-600); }
.bg-amber-600 { background-color: var(--amber-600); }
.bg-green-600 { background-color: var(--green-600); }
.bg-orange-600 { background-color: var(--orange-600); }
.bg-cyan-600 { background-color: var(--cyan-600); }

.text-blue-600 { color: var(--blue-600); }
.text-red-600 { color: var(--red-600); }
.text-purple-600 { color: var(--purple-600); }
.text-amber-600 { color: var(--amber-600); }
.text-green-600 { color: var(--green-600); }
.text-orange-600 { color: var(--orange-600); }
.text-cyan-600 { color: var(--cyan-600); }

/* Game Screen */
.game-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  flex-wrap: wrap;
  gap: 20px;
}

.score-display {
  display: flex;
  gap: 30px;
  flex-wrap: wrap;
}

.score-item {
  text-align: center;
}

.score-item h3 {
  font-size: 0.875rem;
  color: #64748b;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.score-item p {
  font-size: 2rem;
  font-weight: bold;
}

/* Button Styles */
button {
  padding: 12px 24px;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 1rem;
}

.btn-primary {
  background-color: var(--blue-600);
  color: white;
}

.btn-primary:hover {
  background-color: #1d4ed8;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(37, 99, 235, 0.3);
}

.btn-secondary {
  background-color: #64748b;
  color: white;
}

.btn-secondary:hover {
  background-color: #475569;
}

.btn-success {
  background-color: var(--green-600);
  color: white;
}

.btn-success:hover {
  background-color: #15803d;
}

.btn-danger {
  background-color: var(--red-600);
  color: white;
}

.btn-danger:hover {
  background-color: #b91c1c;
}

/* Issue Card */
.issue-card {
  margin-bottom: 30px;
}

.issue-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.issue-header h2 {
  font-size: 1.5rem;
  color: var(--slate-800);
}

.issue-description {
  color: #64748b;
  margin-bottom: 20px;
  font-size: 1rem;
  line-height: 1.6;
}

/* Voting Grid */
.voting-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.vote-card {
  padding: 16px;
  border-radius: 8px;
  color: white;
}

.vote-card h4 {
  font-size: 0.875rem;
  font-weight: bold;
  margin-bottom: 12px;
}

.vote-buttons {
  display: flex;
  gap: 8px;
}

.vote-buttons button {
  flex: 1;
  padding: 10px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: white;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.vote-buttons button:hover {
  background: rgba(255, 255, 255, 0.3);
}

.vote-buttons button.voted-yes {
  background: rgba(34, 197, 94, 0.9);
  ring: 2px solid white;
}

.vote-buttons button.voted-no {
  background: rgba(239, 68, 68, 0.9);
  ring: 2px solid white;
}

/* Economic Data */
.economic-section {
  margin-top: 20px;
}

.economic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.economic-card {
  background: #f8fafc;
  padding: 16px;
  border-radius: 8px;
  border-left: 4px solid var(--blue-600);
}

.economic-card h4 {
  font-size: 0.875rem;
  color: #64748b;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.economic-card p {
  font-size: 1.25rem;
  font-weight: bold;
  color: var(--slate-800);
}

/* Results Screen */
.results-screen {
  text-align: center;
}

.results-screen h2 {
  font-size: 2rem;
  color: var(--slate-800);
  margin-bottom: 30px;
}

.final-scores {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 20px;
  margin: 30px 0;
}

.score-card {
  padding: 20px;
  border-radius: 8px;
  color: white;
}

.score-card h3 {
  font-size: 1.125rem;
  margin-bottom: 12px;
}

.score-card .score-value {
  font-size: 2.5rem;
  font-weight: bold;
}

/* Toggle Buttons */
.toggle-section {
  display: flex;
  gap: 12px;
  margin: 20px 0;
  flex-wrap: wrap;
}

/* Responsive Design */
@media (max-width: 768px) {
  .header h1 {
    font-size: 2rem;
  }
  
  .header p {
    font-size: 1rem;
  }
  
  .country-grid,
  .voting-grid,
  .economic-grid,
  .final-scores {
    grid-template-columns: 1fr;
  }
  .tie-announcement {
  position: fixed;
  top: 20%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10000;
  min-width: 500px;
  max-width: 700px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  animation: slideDown 0.4s ease-out;
}

.tie-announcement.tie-revote { border: 4px solid #ff9800; }
.tie-announcement.tie-unresolved { border: 4px solid #f44336; }

.tie-announcement-content {
  padding: 30px;
  text-align: center;
}

.tie-announcement-content h2 {
  margin: 0 0 15px 0;
  font-size: 28px;
  color: #333;
}

.tie-revote h2 { color: #ff9800; }
.tie-unresolved h2 { color: #f44336; }

.tie-details {
  font-size: 18px;
  color: #666;
  margin: 10px 0;
}

.tie-vote-counts {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin: 20px 0;
  padding: 15px;
  background: #f5f5f5;
  border-radius: 8px;
}

.tie-option {
  font-size: 20px;
  font-weight: bold;
  color: #333;
}

.tie-instruction {
  font-size: 20px;
  color: #ff9800;
  font-weight: bold;
  margin: 15px 0;
}

.tie-outcome {
  font-size: 18px;
  color: #f44336;
  font-weight: bold;
  margin: 15px 0;
}

.tie-attempt {
  display: inline-block;
  padding: 8px 16px;
  background: #ff9800;
  color: white;
  border-radius: 20px;
  font-weight: bold;
  margin-top: 10px;
}

@keyframes slideDown {
  from {
    top: -100px;
    opacity: 0;
  }
  to {
    top: 20%;
    opacity: 1;
  }
}

.tie-announcement.fade-out {
  animation: fadeOut 0.5s ease-out forwards;
}

@keyframes fadeOut {
  to {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
  }
}

@media (max-width: 768px) {
  .tie-announcement {
    min-width: 90%;
    max-width: 90%;
  }
  
  .tie-announcement-content {
    padding: 20px;
  }
  
  .tie-announcement-content h2 {
    font-size: 22px;
  }
  
  .tie-vote-counts {
    flex-direction: column;
    gap: 10px;
  }
}
  .game-header {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* Utility Classes */
.mt-4 { margin-top: 16px; }
.mt-6 { margin-top: 24px; }
.mb-4 { margin-bottom: 16px; }
.mb-6 { margin-bottom: 24px; }
.w-full { width: 100%; }
.text-center { text-align: center; }
.font-bold { font-weight: bold; }
.rounded-lg { border-radius: 12px; }
.shadow-lg { box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1); }
