@tailwind base;
@tailwind components;
@tailwind utilities;
.container {
  max-width: 600px;
  margin: 50px auto;
  padding: 20px;
  font-family: Arial, sans-serif;
}

h1 {
  text-align: center;
  margin-bottom: 30px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
  color: #555;
}

.form-control {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 16px;
}

.btn {
  background-color: #007bff;
  color: white;
  padding: 12px 24px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  width: 100%;
}

.btn:hover {
  background-color: #0056b3;
}

.result {
  margin-top: 30px;
  padding: 20px;
  background-color: #f8f9fa;
  border-radius: 4px;
  text-align: center;
}

.result h2 {
  color: #28a745;
  margin-bottom: 20px;
}

.result-details {
  text-align: left;
  max-width: 400px;
  margin: 0 auto;
}

.result-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #e9ecef;
}

.result-row:last-child {
  border-bottom: none;
}

.result-row .label {
  font-weight: bold;
  color: #555;
}

.result-row .value {
  color: #333;
  font-weight: 500;
}

.result-row .value.success {
  color: #28a745;
  font-weight: bold;
}

.result-row .value.failure {
  color: #dc3545;
  font-weight: bold;
}
/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * Styles in this file should be added after the last require_* statement.
 *


 */

/* Modifier Card Styles */
.modifier-card {
  width: 32px;
  height: 44px;
  border-radius: 6px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  font-weight: bold;
  font-size: 14px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  transform-style: preserve-3d;
  
  /* DEFAULT STATE: Always grey */
  background: linear-gradient(135deg, #374151, #4b5563);
  color: #9ca3af;
  border-color: rgba(156, 163, 175, 0.4);
}

.modifier-card:hover {
  transform: translateY(-2px) rotateY(5deg);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.modifier-card:active {
  transform: translateY(0) rotateY(0deg);
}

/* Remove all the permanent modifier states - cards stay grey by default */
/* Flash effect classes - HIGH PRIORITY - these will override the default grey */
.modifier-card.flash-positive {
  background: linear-gradient(135deg, #10b981, #059669) !important;
  border-color: #10b981 !important;
  color: white !important;
  transform: scale(1.05) !important;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.6) !important;
  z-index: 10;
}

.modifier-card.flash-negative {
  background: linear-gradient(135deg, #ef4444, #dc2626) !important;
  border-color: #ef4444 !important;
  color: white !important;
  transform: scale(1.05) !important;
  box-shadow: 0 0 20px rgba(239, 68, 68, 0.6) !important;
  z-index: 10;
}

/* Modifier indicator cards */
.modifier-indicator {
  width: 20px;
  height: 28px;
  border: 2px solid #e5e7eb;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 12px;
  margin-left: 4px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.modifier-indicator.positive {
  background: linear-gradient(135deg, #86efac, #6ee7b7);
  color: #064e3b;
  border-color: #86efac;
}

.modifier-indicator.negative {
  background: linear-gradient(135deg, #fca5a5, #fecaca);
  color: #7f1d1d;
  border-color: #fca5a5;
}

.card-symbol {
  font-weight: bold;
  font-size: 16px;
  color: inherit;
}

/* Duel Type Button Styles */
.duel-type-toggle {
  position: relative;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  padding: 4px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 4px;
  transition: all 0.3s ease;
}

.duel-type-toggle::before {
  content: '';
  position: absolute;
  top: 4px;
  left: 4px;
  right: 4px;
  height: calc(100% - 8px);
  background: linear-gradient(135deg, #10b981, #059669);
  border-radius: 8px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1;
}

.duel-type-toggle[data-active="simple"]::before {
  left: 4px;
  right: calc(66.667% + 2.67px);
}

.duel-type-toggle[data-active="opposed"]::before {
  left: calc(33.333% + 2.67px);
  right: calc(33.333% + 2.67px);
}

.duel-type-toggle[data-active="opposed_with_tn"]::before {
  left: calc(66.667% + 2.67px);
  right: 4px;
}

.duel-type-btn {
  position: relative;
  z-index: 2;
  background: transparent;
  color: #cbd5e1;
  border: none;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
  white-space: normal;
  min-width: 0;
  line-height: 1.2;
}

.duel-type-btn:hover {
  color: white;
}

.duel-type-btn.active {
  color: white;
  font-weight: 600;
}

/* Results Display Enhanced Styles */
.results-card {
  animation: slideInUp 0.6s ease-out;
}

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

.parameter-card {
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.parameter-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transition: left 0.5s ease;
}

.parameter-card:hover::before {
  left: 100%;
}

.parameter-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.success-rate-display {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(5, 150, 105, 0.1));
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 24px;
}

.raise-rate-display {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(6, 182, 212, 0.1));
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 24px;
}

.modifier-badge {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

.summary-legend {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 16px;
  margin-top: 24px;
}

.legend-item {
  transition: all 0.2s ease;
}

.legend-item:hover {
  transform: scale(1.05);
}

/* Enhanced gradient borders */
.gradient-border {
  position: relative;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 1px;
}

.gradient-border::before {
  content: '';
  position: absolute;
  inset: 0;
  padding: 1px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.05));
  border-radius: 16px;
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
}

.gradient-border > * {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 15px;
  padding: 16px;
}

/* Duel Summary Box Styles */
.duel-summary-box {
  background: linear-gradient(135deg, rgba(147, 51, 234, 0.15), rgba(59, 130, 246, 0.15));
  border: 1px solid rgba(147, 51, 234, 0.3);
  border-radius: 16px;
  padding: 20px;
  margin: 24px 0;
  transition: all 0.3s ease;
}

.duel-summary-box:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(147, 51, 234, 0.2);
}

.duel-summary-content {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 18px;
  line-height: 1.5;
}

.duel-type-section {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #cbd5e1;
  font-weight: 500;
}

.duel-type-section .duel-type-icon {
  font-size: 24px;
}

.duel-type-section .duel-type-label {
  text-transform: capitalize;
  font-size: 16px;
}

.attacker-section {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
}

.attacker-section .attacker-stat {
  font-weight: bold;
  font-size: 20px;
}

.defender-section {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
}

.defender-section .defender-stat {
  font-weight: bold;
  font-size: 20px;
}

.target-section {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
}

.target-section .target-value {
  font-weight: bold;
  font-size: 20px;
}

.separator {
  color: rgba(255, 255, 255, 0.5);
  font-weight: 300;
  font-size: 20px;
}

.vs-separator {
  color: white;
  font-weight: 600;
  font-size: 18px;
  padding: 0 8px;
}

/* Responsive adjustments for smaller screens */
@media (max-width: 768px) {
  .duel-summary-box {
    padding: 16px;
    margin: 16px 0;
  }
  
  .duel-summary-content {
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 8px;
    font-size: 14px;
    justify-content: center;
    align-items: center;
    overflow-x: auto;
    padding: 0 4px;
  }
  
  .duel-type-section {
    flex-shrink: 0;
    gap: 4px;
  }
  
  .duel-type-section .duel-type-icon {
    font-size: 18px;
  }
  
  .duel-type-section .duel-type-label {
    font-size: 12px;
    white-space: nowrap;
  }
  
  .attacker-section .attacker-stat,
  .defender-section .defender-stat,
  .target-section .target-value {
    font-size: 16px;
  }
  
  .separator, .vs-separator {
    font-size: 16px;
    padding: 0 4px;
  }
  
  .modifier-indicator {
    width: 16px;
    height: 22px;
    font-size: 10px;
    margin-left: 2px;
  }
}

/* Extra small screens */
@media (max-width: 480px) {
  .duel-summary-box {
    padding: 12px;
    margin: 12px 0;
  }
  
  .duel-summary-content {
    gap: 6px;
    font-size: 12px;
  }
  
  .duel-type-section .duel-type-icon {
    font-size: 16px;
  }
  
  .duel-type-section .duel-type-label {
    font-size: 11px;
  }
  
  .attacker-section .attacker-stat,
  .defender-section .defender-stat,
  .target-section .target-value {
    font-size: 14px;
  }
  
  .separator, .vs-separator {
    font-size: 14px;
    padding: 0 2px;
  }
  
  .modifier-indicator {
    width: 14px;
    height: 20px;
    font-size: 9px;
    margin-left: 1px;
  }
}

/* Responsive adjustments for smaller screens */
@media (max-width: 768px) {
  .duel-type-toggle {
    padding: 3px;
    gap: 3px;
  }
  
  .duel-type-btn {
    padding: 6px 8px;
    font-size: 12px;
    line-height: 1.1;
  }
}

/* Extra small screens */
@media (max-width: 480px) {
  .duel-type-toggle {
    padding: 2px;
    gap: 2px;
  }
  
  .duel-type-btn {
    padding: 4px 6px;
    font-size: 13px;
    line-height: 1.1;
  }
}
