/* Offline Calculator Page Styles */

.offline-page {
  background: linear-gradient(135deg, #f5f5f5 0%, #e8f5e9 100%);
  min-height: 100vh;
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

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

.offline-header {
  background: linear-gradient(135deg, #2d6a4f 0%, #40916c 100%);
  color: white;
  padding: 30px;
  border-radius: 12px;
  margin-bottom: 30px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.offline-header h1 {
  margin: 0 0 10px 0;
  font-size: 2rem;
}

.offline-header h1 i {
  margin-right: 10px;
}

.offline-status {
  margin: 0;
  opacity: 0.9;
  font-size: 1.1rem;
}

.offline-content {
  margin-bottom: 30px;
}

.formula-section {
  background: white;
  border-radius: 12px;
  padding: 25px;
  margin-bottom: 25px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.formula-section h2 {
  color: #2d6a4f;
  margin-top: 0;
  margin-bottom: 20px;
  font-size: 1.5rem;
}

.formula-section h2 i {
  margin-right: 10px;
  color: #40916c;
}

.formula-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}

.formula-card {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-radius: 8px;
  padding: 20px;
  border-left: 4px solid #40916c;
  transition: transform 0.2s ease;
}

.formula-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.formula-card h3 {
  color: #2d6a4f;
  margin: 0 0 15px 0;
  font-size: 1.2rem;
}

.formula {
  background: white;
  padding: 15px;
  border-radius: 6px;
  font-family: 'Courier New', monospace;
  font-size: 1.3rem;
  text-align: center;
  margin-bottom: 15px;
  color: #1a1a1a;
  border: 1px solid #dee2e6;
}

.formula-desc {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-size: 0.9rem;
  color: #495057;
}

.formula-desc span {
  padding: 3px 0;
}

.constants-table,
.elements-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 15px;
}

.constants-table th,
.constants-table td,
.elements-table th,
.elements-table td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid #dee2e6;
}

.constants-table th,
.elements-table th {
  background: #2d6a4f;
  color: white;
  font-weight: 600;
}

.constants-table tr:hover,
.elements-table tr:hover {
  background: #f8f9fa;
}

.elements-table tr:nth-child(even) {
  background: #f8f9fa;
}

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

.action-card {
  background: white;
  border-radius: 12px;
  padding: 25px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.action-card h3 {
  color: #2d6a4f;
  margin: 0 0 10px 0;
}

.action-card h3 i {
  margin-right: 10px;
  color: #40916c;
}

.action-card p {
  color: #495057;
  margin-bottom: 20px;
}

.btn {
  display: inline-block;
  padding: 12px 24px;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, #2d6a4f 0%, #40916c 100%);
  color: white;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(45, 106, 79, 0.4);
}

.btn-secondary {
  background: #6c757d;
  color: white;
}

.btn-secondary:hover {
  background: #5a6268;
}

.offline-footer {
  text-align: center;
  padding: 20px;
  color: #495057;
  font-size: 0.9rem;
}

.offline-tip {
  margin-top: 5px;
  font-style: italic;
  color: #6c757d;
}

/* Mobile responsive */
@media (max-width: 768px) {
  .offline-container {
    padding: 10px;
  }

  .offline-header {
    padding: 20px;
  }

  .offline-header h1 {
    font-size: 1.5rem;
  }

  .formula-grid {
    grid-template-columns: 1fr;
  }

  .formula-section {
    padding: 15px;
  }

  .constants-table,
  .elements-table {
    font-size: 0.85rem;
  }

  .constants-table th,
  .constants-table td,
  .elements-table th,
  .elements-table td {
    padding: 8px;
  }

  .offline-actions {
    grid-template-columns: 1fr;
  }
}
