/* Calculatrice Styles */
.calculatrice-section {
  padding: 100px 0 60px 0;
  min-height: 100vh;
}

.calculatrice-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 40px;
}

.calculatrice {
  background: linear-gradient(135deg, var(--card) 0%, #2a0101 100%);
  border: 2px solid var(--accent);
  border-radius: 20px;
  padding: 30px;
  box-shadow: 
    0 0 30px rgba(255, 56, 56, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  max-width: 400px;
  width: 100%;
  backdrop-filter: blur(10px);
  animation: slideInUp 0.6s ease;
}

.ecran {
  background: linear-gradient(180deg, #1a0000 0%, #0d0000 100%);
  border: 2px solid var(--accent-2);
  border-radius: 12px;
  padding: 25px 20px;
  margin-bottom: 20px;
  font-size: 2.5rem;
  text-align: right;
  color: var(--text);
  word-wrap: break-word;
  word-break: break-all;
  min-height: 80px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  font-weight: 600;
  letter-spacing: 1px;
  box-shadow: inset 0 4px 10px rgba(0, 0, 0, 0.5);
  font-family: 'Monaco', 'Courier New', monospace;
}

.touches {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.bouton {
  padding: 20px;
  font-size: 1.3rem;
  font-weight: 600;
  border: 2px solid transparent;
  border-radius: 10px;
  cursor: pointer;
  background: linear-gradient(135deg, #570000, #3b0202);
  color: var(--text);
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 15px rgba(255, 56, 56, 0.1);
  position: relative;
  overflow: hidden;
}

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

.bouton:hover {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border-color: var(--accent-2);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 56, 56, 0.3);
}

.bouton:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(255, 56, 56, 0.2);
}

.bouton.clear {
  background: linear-gradient(135deg, #8b0000, #5a0000);
  grid-column: span 1;
}

.bouton.clear:hover {
  background: linear-gradient(135deg, #a00000, #7a0000);
}

.bouton.operator {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #ffffff;
}

.bouton.operator:hover {
  background: linear-gradient(135deg, #ff4c4c, #ff7a7a);
  box-shadow: 0 6px 25px rgba(255, 56, 56, 0.4);
}

.bouton.equals {
  grid-column: span 1;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #ffffff;
  font-weight: 700;
}

.bouton.equals:hover {
  background: linear-gradient(135deg, #ff4c4c, #ff7a7a);
  box-shadow: 0 6px 25px rgba(255, 56, 56, 0.4);
}

/* Responsive */
@media (max-width: 768px) {
  .calculatrice-section {
    padding: 90px 0 40px 0;
  }

  .calculatrice {
    padding: 20px;
  }

  .ecran {
    font-size: 1.8rem;
    padding: 20px 15px;
    min-height: 60px;
  }

  .touches {
    gap: 8px;
  }

  .bouton {
    padding: 15px;
    font-size: 1.1rem;
  }
}

@media (max-width: 480px) {
  .calculatrice-section {
    padding: 80px 0 30px 0;
  }

  .calculatrice {
    padding: 15px;
  }

  .ecran {
    font-size: 1.5rem;
    padding: 15px 10px;
    min-height: 50px;
  }

  .touches {
    gap: 6px;
  }

  .bouton {
    padding: 12px;
    font-size: 1rem;
    min-height: 48px;
  }
}

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