/* ============================================
   GLOBAL STYLES
   ============================================ */
:root {
  --primary-color: #7c3aed;
  --secondary-color: #6c757d;
  --success-color: #7c3aed;
  --danger-color: #dc3545;
  --warning-color: #ffc107;
  --info-color: #0dcaf0;
  --light-color: #f8f9fa;
  --dark-color: #212529;
  --purple-color: #7c3aed;
  --shadow-sm: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
  --shadow-md: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 1rem 3rem rgba(0, 0, 0, 0.175);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 14px;
  position: relative;
  min-height: 100%;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #f3e7ff 0%, #e9d5ff 100%);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  margin-bottom: 60px;
}

/* ============================================
   NAVBAR STYLING
   ============================================ */
.navbar {
  background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  border-bottom: 3px solid #00d4ff;
  padding: 1rem 0;
}

.navbar-brand {
  font-size: 1.5rem;
  font-weight: 700;
  color: white !important;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.nav-link {
  color: rgba(255, 255, 255, 0.9) !important;
  font-weight: 500;
  margin: 0 5px;
  transition: all 0.3s ease;
  border-radius: 5px;
}

.nav-link:hover {
  background-color: rgba(255, 255, 255, 0.2);
  color: white !important;
  transform: translateY(-2px);
}

.dropdown-menu {
  background: white;
  border: none;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.dropdown-item {
  color: #212529;
  transition: all 0.2s ease;
}

.dropdown-item:hover {
  background-color: #f8f9fa;
  color: #0d6efd;
  padding-left: 1.5rem;
}

/* ============================================
   CARD STYLING
   ============================================ */
.card {
  border: none;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  overflow: hidden;
}

.card:hover {
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
  transform: translateY(-5px);
}

.card-header {
  border-bottom: 2px solid rgba(0, 0, 0, 0.1);
  font-weight: 600;
  padding: 1.25rem;
  background: linear-gradient(135deg, var(--primary-color), var(--info-color));
  color: white;
}

.card-body {
  padding: 1.5rem;
}

/* ============================================
   BUTTON STYLING
   ============================================ */
.btn {
  border-radius: 8px;
  font-weight: 600;
  padding: 0.5rem 1.5rem;
  transition: all 0.3s ease;
  border: none;
}

.btn:focus,
.btn:active:focus,
.btn-link.nav-link:focus,
.form-control:focus,
.form-check-input:focus {
  box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.btn-primary {
  background: linear-gradient(135deg, #0d6efd, #0055cc);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #0055cc, #003d99);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.btn-success {
  background: linear-gradient(135deg, #198754, #146c43);
}

.btn-success:hover {
  background: linear-gradient(135deg, #146c43, #0e5435);
  transform: translateY(-2px);
}

.btn-danger {
  background: linear-gradient(135deg, #dc3545, #bb2d3b);
}

.btn-danger:hover {
  background: linear-gradient(135deg, #bb2d3b, #a02622);
  transform: translateY(-2px);
}

.btn-warning {
  background: linear-gradient(135deg, #ffc107, #ff9800);
  color: white;
}

.btn-warning:hover {
  background: linear-gradient(135deg, #ff9800, #e68900);
  transform: translateY(-2px);
}

.btn-secondary {
  background: linear-gradient(135deg, #6c757d, #545b62);
}

.btn-secondary:hover {
  background: linear-gradient(135deg, #545b62, #3d4147);
  transform: translateY(-2px);
}

.btn-sm {
  padding: 0.35rem 0.75rem;
  font-size: 0.875rem;
}

.btn-lg {
  padding: 0.75rem 2rem;
  font-size: 1.1rem;
}

/* ============================================
   FORM STYLING
   ============================================ */
.form-control {
  border-radius: 8px;
  border: 2px solid #e0e0e0;
  padding: 0.75rem 1rem;
  transition: all 0.3s ease;
  font-size: 1rem;
}

.form-control:focus {
  border-color: #0d6efd;
  box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.form-control::placeholder {
  color: #999;
  font-style: italic;
}

.form-label {
  font-weight: 600;
  color: #212529;
  margin-bottom: 0.5rem;
}

.form-floating > .form-control-plaintext::placeholder,
.form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder,
.form-floating > .form-control:focus::placeholder {
  text-align: start;
}

/* ============================================
   TABLE STYLING
   ============================================ */
.table {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.table thead {
  background: linear-gradient(135deg, #0d6efd, #0055cc);
  color: white;
  font-weight: 600;
}

.table-hover tbody tr:hover {
  background-color: #f0f4ff;
  transform: scale(1.01);
}

.table-responsive {
  border-radius: 8px;
}

/* ============================================
   BADGE STYLING
   ============================================ */
.badge {
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-weight: 600;
  display: inline-block;
}

.badge.bg-success {
  background: linear-gradient(135deg, #198754, #146c43) !important;
}

.badge.bg-danger {
  background: linear-gradient(135deg, #dc3545, #bb2d3b) !important;
}

.badge.bg-info {
  background: linear-gradient(135deg, #0dcaf0, #0ea5e9) !important;
}

.badge.bg-warning {
  background: linear-gradient(135deg, #ffc107, #ff9800) !important;
  color: white;
}

.badge.bg-primary {
  background: linear-gradient(135deg, #0d6efd, #0055cc) !important;
}

/* ============================================
   ALERT STYLING
   ============================================ */
.alert {
  border-radius: 8px;
  border: none;
  padding: 1rem 1.5rem;
  margin-bottom: 1.5rem;
}

.alert-info {
  background: linear-gradient(135deg, rgba(13, 202, 240, 0.1), rgba(13, 202, 240, 0.05));
  border-left: 4px solid #0dcaf0;
  color: #0c5460;
}

.alert-success {
  background: linear-gradient(135deg, rgba(25, 135, 84, 0.1), rgba(25, 135, 84, 0.05));
  border-left: 4px solid #198754;
  color: #155724;
}

.alert-danger {
  background: linear-gradient(135deg, rgba(220, 53, 69, 0.1), rgba(220, 53, 69, 0.05));
  border-left: 4px solid #dc3545;
  color: #721c24;
}

.alert-warning {
  background: linear-gradient(135deg, rgba(255, 193, 7, 0.1), rgba(255, 193, 7, 0.05));
  border-left: 4px solid #ffc107;
  color: #856404;
}

/* ============================================
   FOOTER STYLING
   ============================================ */
footer {
  margin-top: auto;
  background: linear-gradient(135deg, #212529, #000);
  color: white;
  padding: 2rem 0;
  border-top: 2px solid #0d6efd;
}

footer a {
  color: #0dcaf0;
  text-decoration: none;
  transition: all 0.3s ease;
}

footer a:hover {
  color: white;
  text-decoration: underline;
}

/* ============================================
   CONTAINER & LAYOUT
   ============================================ */
.container {
  background: white;
  border-radius: 12px;
  margin: 2rem auto;
  padding: 2rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  max-width: 1200px;
}

main {
  flex: 1;
}

/* ============================================
   SPACING UTILITIES
   ============================================ */
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.mt-5 { margin-top: 3rem; }

.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mb-5 { margin-bottom: 3rem; }

/* ============================================
   TEXT UTILITIES
   ============================================ */
.text-center { text-align: center; }
.text-white { color: white; }
.text-muted { color: #6c757d; }
.text-danger { color: #dc3545; }
.text-success { color: #198754; }
.text-info { color: #0dcaf0; }
.fw-bold { font-weight: 700; }
.fw-600 { font-weight: 600; }

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  color: #212529;
  margin-bottom: 1rem;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 768px) {
  .container {
    padding: 1rem;
    margin: 1rem auto;
  }

  .navbar-brand {
    font-size: 1.25rem;
  }

  .btn {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
  }

  .card-body {
    padding: 1rem;
  }
}