/* static/css/civil/concrete-footing-yard-calculator.css */

.footing-visualization-container {
  height: 350px;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  overflow: hidden;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  position: relative;
}

.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin-bottom: 20px;
}

.stat-item {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  padding: 15px;
  border-radius: 12px;
  text-align: center;
  border: 1px solid #e9ecef;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.stat-value {
  font-size: 1.3rem;
  font-weight: 700;
  color: #0d6efd;
  margin-bottom: 5px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.stat-label {
  font-size: 0.85rem;
  color: #6c757d;
  font-weight: 500;
}

.tips-list {
  font-size: 0.9rem;
  padding-left: 20px;
  margin-bottom: 0;
}

.tips-list li {
  margin-bottom: 10px;
  color: #495057;
  line-height: 1.4;
}

.chart-container {
  height: 250px;
  position: relative;
}

.advanced-options {
  transition: all 0.3s ease;
  border-top: 1px solid #e9ecef;
  padding-top: 1rem;
}

.advanced-toggle {
  cursor: pointer;
  user-select: none;
  transition: color 0.2s ease;
}

.advanced-toggle:hover {
  color: #0b5ed7 !important;
}

.advanced-content {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.3s ease;
}

.advanced-content.show {
  max-height: 600px;
}

.calculation-note {
  font-size: 0.85rem;
  color: #6c757d;
  background: linear-gradient(90deg, #f8f9fa 0%, #e9ecef 100%);
  border-left: 4px solid #0d6efd;
  padding: 0.75rem 1rem;
  margin-top: 1rem;
  border-radius: 0 8px 8px 0;
}

.result-highlight {
  background: linear-gradient(135deg, #e7f3ff 0%, #cce7ff 100%);
  padding: 1.25rem;
  border-radius: 12px;
  border-left: 4px solid #0dcaf0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Reinforcement visualization styles */
.reinforcement-details {
  background-color: #f8f9fa;
  border-radius: 8px;
  padding: 15px;
  margin-top: 15px;
}

.reinforcement-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #e9ecef;
}

.reinforcement-item:last-child {
  border-bottom: none;
}

.bar-visualization {
  display: flex;
  align-items: center;
  margin: 10px 0;
}

.bar-indicator {
  width: 100px;
  height: 20px;
  background: linear-gradient(45deg, #dc3545, #fd7e14);
  margin-right: 15px;
  border-radius: 10px;
  position: relative;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.bar-indicator::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80%;
  height: 2px;
  background-color: rgba(255, 255, 255, 0.8);
  border-radius: 1px;
}

.dimension-indicator {
  position: absolute;
  background-color: rgba(13, 110, 253, 0.9);
  color: white;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 600;
  pointer-events: none;
  z-index: 10;
}

/* 3D Controls */
.view-controls {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  z-index: 5;
}

.view-control-btn {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid #dee2e6;
  border-radius: 4px;
  padding: 5px 8px;
  font-size: 0.7rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.view-control-btn:hover {
  background: rgba(13, 110, 253, 0.9);
  color: white;
}

.view-control-btn.active {
  background: #0d6efd;
  color: white;
}

/* Footing type specific styles */
.footing-type-square {
  border-left-color: #28a745;
}

.footing-type-rectangular {
  border-left-color: #007bff;
}

.footing-type-circular {
  border-left-color: #ffc107;
}

.footing-type-strip {
  border-left-color: #dc3545;
}

.footing-type-stepped {
  border-left-color: #6f42c1;
}

/* Loading animation for 3D visualization */
.loading-3d {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  flex-direction: column;
  color: #6c757d;
}

.loading-3d .spinner-border {
  margin-bottom: 15px;
}

/* Material grade indicators */
.grade-m15 { color: #dc3545; }
.grade-m20 { color: #fd7e14; }
.grade-m25 { color: #ffc107; }
.grade-m30 { color: #28a745; }
.grade-m35 { color: #20c997; }

/* Steel grade indicators */
.steel-fe415 { color: #007bff; }
.steel-fe500 { color: #6f42c1; }
.steel-fe550 { color: #e83e8c; }

/* Export specific styles */
.export-section {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 2rem;
}

.export-title {
  color: #495057;
  font-weight: 600;
  margin-bottom: 1rem;
  text-align: center;
}

/* CSV Export Notification */
.csv-export-notification {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
  color: white;
  padding: 12px 24px;
  border-radius: 8px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  z-index: 1050;
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.csv-export-notification.show {
  opacity: 1;
  transform: translateY(0);
}

/* Enhanced table styling for results */
.table-footing-results {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.table-footing-results th {
  background: linear-gradient(135deg, #495057 0%, #343a40 100%);
  color: white;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
  border: none;
  padding: 15px 12px;
}

.table-footing-results td {
  padding: 12px;
  border-color: #f1f3f4;
  vertical-align: middle;
}

.table-footing-results tbody tr:hover {
  background-color: #f8f9fa;
  transform: scale(1.001);
  transition: all 0.2s ease;
}

/* Responsive design improvements */
@media (max-width: 768px) {
  .chart-container {
    height: 200px;
  }
  
  .footing-visualization-container {
    height: 250px;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  
  .stat-value {
    font-size: 1.2rem;
  }
  
  .advanced-content.show {
    max-height: 800px;
  }
}

@media (max-width: 576px) {
  .footing-visualization-container {
    height: 200px;
  }
  
  .result-highlight {
    padding: 1rem;
  }
  
  .btn-group .btn {
    font-size: 0.8rem;
    padding: 0.375rem 0.5rem;
  }
}

/* Custom scrollbar for advanced options */
.advanced-content::-webkit-scrollbar {
  width: 4px;
}

.advanced-content::-webkit-scrollbar-track {
  background: #f1f3f4;
}

.advanced-content::-webkit-scrollbar-thumb {
  background: #0d6efd;
  border-radius: 2px;
}

/* Animation keyframes */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

.pulse-animation {
  animation: pulse 2s infinite;
}

/* 3D visualization enhancements */
.footing-3d-controls {
  position: absolute;
  top: 15px;
  left: 15px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 10;
}

.control-button {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  backdrop-filter: blur(5px);
}

.control-button:hover {
  background: rgba(13, 110, 253, 0.9);
  color: white;
  transform: translateX(2px);
}

.control-button.active {
  background: #0d6efd;
  color: white;
  box-shadow: 0 2px 8px rgba(13, 110, 253, 0.3);
}