/* FADS Academy - Consolidated Styles */

/* CSS Variables */
:root {
  --brand: #2E86C1;
  --brand-dark: #1B6396;
  --bg: #f4f6f7;
  --card: #ffffff;
  --muted: #f9f9f9;
  --border: #e5e7eb;
  --text: #333;
  --text-muted: #666;
}

/* Global Styles */
* {
  box-sizing: border-box;
}

body {
  font-family: Raleway, Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
}

/* Header Styles */
header {
  background: var(--brand);
  color: #fff;
  text-align: center;
  padding: 18px 16px;
  font-size: 22px;
  font-weight: 700;
}

/* Dashboard Specific Styles */
.toolbar {
  display: flex;
  gap: 8px;
  justify-content: center;
  align-items: center;
  background: #1f5f8d;
  color: #fff;
  padding: 8px 12px;
}

.toolbar a {
  color: #fff;
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 6px;
}

.toolbar a:hover {
  background: rgba(255,255,255,0.15);
}

.dashboard {
  display: grid;
  gap: 20px;
  padding: 20px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 900px) {
  .dashboard {
    grid-template-columns: 1fr;
  }
}

.section {
  background: var(--card);
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
  padding: 16px;
  border: 1px solid var(--border);
}

.section h2 {
  background: var(--brand);
  color: #fff;
  padding: 10px 12px;
  margin: 0 0 14px;
  border-radius: 8px;
  font-size: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modules {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.module {
  background: var(--muted);
  border: 1px solid var(--border);
  border-radius: 8px;
  text-align: center;
  padding: 12px;
  font-size: 13px;
  font-weight: 700;
  transition: 0.2s;
  user-select: none;
}

.module:hover {
  background: var(--brand);
  color: #fff;
  cursor: pointer;
  transform: translateY(-1px);
}

/* Course Management Specific Styles */
.container {
  padding: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.page-header {
  background: white;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  padding: 20px;
  margin-bottom: 20px;
}

.page-header h1 {
  background: var(--brand);
  color: white;
  padding: 15px;
  border-radius: 6px;
  font-size: 24px;
  margin: 0;
  text-align: center;
}

.content {
  background: white;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  padding: 40px;
}

/* Breadcrumb Navigation */
.breadcrumb {
  background: white;
  padding: 10px 0;
  border-radius: 8px;
  margin-bottom: 15px;
  font-size: 14px;
}

.breadcrumb a {
  color: var(--brand);
  text-decoration: none;
  transition: color 0.3s;
}

.breadcrumb a:hover {
  color: var(--brand-dark);
  text-decoration: underline;
}

.breadcrumb .separator {
  margin: 0 8px;
  color: var(--text-muted);
}

/* Page Title */
.page-title {
  background: white;
  padding: 15px 20px;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  margin-bottom: 20px;
  border-left: 4px solid var(--brand);
}

.page-title h2 {
  margin: 0;
  color: var(--brand);
  font-size: 20px;
  font-weight: 600;
}

/* Form Styles */
.form-container {
  background: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

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

.form-label {
  display: block;
  margin-bottom: 5px;
  font-weight: 600;
  color: var(--text);
}

.form-input {
  width: 100%;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 14px;
  transition: border-color 0.3s;
}

.form-input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(46, 134, 193, 0.1);
}

/* Button Styles */
.btn {
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.3s;
  text-align: center;
}

.btn-primary {
  background: var(--brand);
  color: white;
}

.btn-primary:hover {
  background: var(--brand-dark);
  transform: translateY(-1px);
}

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

.btn-secondary:hover {
  background: #545b62;
}

.btn-danger {
  background: #dc3545;
  color: white;
}

.btn-danger:hover {
  background: #c82333;
}

.btn-small {
  padding: 6px 12px;
  font-size: 12px;
}

/* Table Styles */
.table-container {
  overflow-x: auto;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
}

.data-table th,
.data-table td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.data-table th {
  background: var(--brand);
  color: white;
  font-weight: 600;
  font-size: 14px;
}

.data-table tbody tr:hover {
  background: var(--muted);
}

/* Alert Styles */
.alert {
  padding: 12px 16px;
  border-radius: 6px;
  margin-bottom: 16px;
  border-left: 4px solid;
}

.alert-success {
  background: #d4edda;
  border-left-color: #28a745;
  color: #155724;
}

.alert-error {
  background: #f8d7da;
  border-left-color: #dc3545;
  color: #721c24;
}

.alert-warning {
  background: #fff3cd;
  border-left-color: #ffc107;
  color: #856404;
}

.alert-info {
  background: #d1ecf1;
  border-left-color: #17a2b8;
  color: #0c5460;
}

/* Card Styles */
.card {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  overflow: hidden;
  margin-bottom: 20px;
}

.card-header {
  background: var(--brand);
  color: white;
  padding: 15px 20px;
  font-weight: 600;
}

.card-body {
  padding: 20px;
}

.card-footer {
  background: var(--muted);
  padding: 15px 20px;
  border-top: 1px solid var(--border);
}

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }

.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }

.p-1 { padding: 0.25rem; }
.p-2 { padding: 0.5rem; }
.p-3 { padding: 1rem; }
.p-4 { padding: 1.5rem; }

.d-flex { display: flex; }
.d-block { display: block; }
.d-inline-block { display: inline-block; }

.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.align-center { align-items: center; }

.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 1rem; }

/* Responsive Design */
@media (max-width: 768px) {
  .container {
    padding: 10px;
  }

  .content {
    padding: 20px;
  }

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

  .breadcrumb {
    font-size: 12px;
  }

  .page-title h2 {
    font-size: 18px;
  }
}