/*
Theme Name: Market Data Theme
Description: A custom WordPress theme for managing market data with cron jobs and file management
Author: Custom Development
Version: 1.0
*/

/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f8f9fa;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* Header Styles */
.site-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 20px 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.site-title {
  font-size: 2.5rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 10px;
}

.site-description {
  text-align: center;
  font-size: 1.2rem;
  opacity: 0.9;
}

/* Market Data Dashboard */
.dashboard {
  background: white;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  padding: 30px;
  margin-top: 30px;
}

.dashboard-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  border-bottom: 2px solid #eee;
  padding-bottom: 20px;
}

.dashboard-title {
  font-size: 2rem;
  color: #333;
  font-weight: 600;
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  border-radius: 25px;
  font-weight: 500;
}

.status-active {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.status-inactive {
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

/* Controls */
.controls {
  display: flex;
  gap: 15px;
  margin-bottom: 30px;
  flex-wrap: wrap;
}

.btn {
  padding: 12px 24px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;
}

.btn-primary {
  background-color: #007bff;
  color: white;
}

.btn-primary:hover {
  background-color: #0056b3;
  transform: translateY(-2px);
}

.btn-success {
  background-color: #28a745;
  color: white;
}

.btn-success:hover {
  background-color: #1e7e34;
}

.btn-danger {
  background-color: #dc3545;
  color: white;
}

.btn-danger:hover {
  background-color: #c82333;
}

.btn-secondary {
  background-color: #6c757d;
  color: white;
}

.btn-secondary:hover {
  background-color: #545b62;
}

/* Additional button styles */
.btn-warning {
  background-color: #ffc107;
  color: #212529;
  border: 1px solid #ffc107;
}

.btn-warning:hover {
  background-color: #e0a800;
  border-color: #d39e00;
}

.btn-info {
  background-color: #17a2b8;
  color: white;
  border: 1px solid #17a2b8;
}

.btn-info:hover {
  background-color: #138496;
  border-color: #117a8b;
}

/* File List */
.file-list {
  background: #f8f9fa;
  border-radius: 8px;
  overflow: hidden;
}

.file-header {
  background: #e9ecef;
  padding: 15px 20px;
  font-weight: 600;
  border-bottom: 1px solid #dee2e6;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 20px;
  align-items: center;
}

.file-item {
  padding: 15px 20px;
  border-bottom: 1px solid #dee2e6;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 20px;
  align-items: center;
  transition: background-color 0.2s ease;
}

.file-item:hover {
  background-color: #f1f3f4;
}

.file-item:last-child {
  border-bottom: none;
}

.file-name {
  font-weight: 500;
  color: #333;
}

.file-size {
  color: #666;
  font-size: 0.9rem;
}

.file-date {
  color: #666;
  font-size: 0.9rem;
}

.file-actions {
  display: flex;
  gap: 10px;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
}

/* Stats Cards */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.stat-card {
  background: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  text-align: center;
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: #007bff;
  margin-bottom: 10px;
}

.stat-label {
  color: #666;
  font-weight: 500;
}

/* Footer Styles */
.site-footer {
  background-color: #343a40;
  color: white;
  text-align: center;
  padding: 20px 0;
  margin-top: 50px;
}

.site-footer p {
  margin: 0;
  opacity: 0.8;
}

/* File type badges */
.file-type-badge {
  display: inline-block;
  padding: 2px 6px;
  font-size: 10px;
  font-weight: 600;
  border-radius: 3px;
  margin-left: 8px;
  text-transform: uppercase;
}

.file-type-badge.txt {
  background-color: #28a745;
  color: white;
}

/* Bulk Actions */
.bulk-actions {
  display: flex;
  gap: 15px;
  margin-bottom: 20px;
  padding: 15px;
  background: #f8f9fa;
  border-radius: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.selected-info {
  font-weight: 500;
  color: #666;
  margin-left: auto;
}

/* File List Checkboxes */
.file-checkbox {
  margin-right: 10px;
  transform: scale(1.2);
}

#select-all-checkbox {
  margin-right: 10px;
  transform: scale(1.2);
}

.file-item.selected {
  background-color: #e3f2fd;
  border-left: 3px solid #2196f3;
}

/* Bulk action buttons */
.btn[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn[disabled]:hover {
  transform: none;
  background-color: inherit;
}

/* Responsive Design */
@media (max-width: 768px) {
  .dashboard-header {
    flex-direction: column;
    gap: 20px;
    text-align: center;
  }

  .controls {
    justify-content: center;
    flex-direction: column;
    gap: 10px;
  }

  .controls .btn {
    width: 100%;
  }

  .file-header,
  .file-item {
    grid-template-columns: 1fr;
    gap: 10px;
    text-align: center;
  }

  .file-actions {
    justify-content: center;
  }
}

/* Loading Spinner */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid #f3f3f3;
  border-top: 3px solid #007bff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Messages */
.message {
  padding: 15px;
  border-radius: 6px;
  margin-bottom: 20px;
}

.message-success {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.message-error {
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.message-info {
  background-color: #d1ecf1;
  color: #0c5460;
  border: 1px solid #bee5eb;
}
