/* Main Styles for the360learning Educational Platform */

:root {
  --primary: #2d7d2f;
  --primary-dark: #1f5521;
  --secondary: #6c757d;
  --success: #28a745;
  --info: #17a2b8;
  --warning: #ffc107;
  --danger: #dc3545;
  --light: #f8f9fa;
  --dark: #343a40;
  --body-bg: #f8f9fa;
  --card-border: #dee2e6;
  --accent-green: #4caf50;
  --light-green: #e8f5e8;
}

/* Base Styles */
body {
  font-family: 'Nunito', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--body-bg);
  color: #333;
}

a {
  color: var(--primary);
  text-decoration: none;
}

a:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

/* Header & Navigation */
.navbar-brand {
  font-size: 1.5rem;
  font-weight: 700;
}

.navbar-brand span {
  color: var(--primary);
}

.navbar-custom {
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.navbar .nav-link {
  font-weight: 600;
  padding: 0.5rem 1rem;
}

.dropdown-menu {
  border: none;
  box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15);
}

/* Cards */
.card {
  border: 1px solid var(--card-border);
  border-radius: 0.35rem;
  box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.1);
  margin-bottom: 1.5rem;
}

.card-header {
  background-color: #f8f9fc;
  border-bottom: 1px solid var(--card-border);
  padding: 0.75rem 1.25rem;
}

.card-header h5, .card-header h6 {
  margin-bottom: 0;
  font-weight: 700;
}

/* Custom Buttons */
.btn-primary {
  background-color: var(--primary);
  border-color: var(--primary);
}

.btn-primary:hover {
  background-color: var(--primary-dark);
  border-color: var(--primary-dark);
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, #2d7d2f 0%, #1f5521 100%);
  color: white;
  padding: 4rem 0;
}

.hero h1 {
  font-weight: 700;
  font-size: 2.5rem;
}

.hero p {
  font-size: 1.25rem;
  opacity: 0.9;
}

/* Features Section */
.feature-card {
  text-align: center;
  padding: 2rem 1rem;
  transition: all 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-5px);
}

.feature-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--primary);
}

/* Dashboard Widgets */
.stat-card {
  border-left: 0.25rem solid var(--primary);
}

.stat-card.success {
  border-left-color: var(--success);
}

.stat-card.warning {
  border-left-color: var(--warning);
}

.stat-card.danger {
  border-left-color: var(--danger);
}

.stat-card.info {
  border-left-color: var(--info);
}

.stat-card .stat-value {
  font-size: 1.5rem;
  font-weight: 700;
}

.stat-card .stat-label {
  font-size: 0.875rem;
  color: var(--secondary);
  text-transform: uppercase;
}

/* Materials Display */
.material-card {
  height: 100%;
  transition: all 0.2s ease;
}

.material-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.material-icon {
  font-size: 2rem;
  margin-bottom: 1rem;
}

/* Assignment Status */
.assignment-status {
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 700;
}

.status-pending {
  background-color: #eaecf4;
  color: var(--secondary);
}

.status-submitted {
  background-color: #e8f5e8;
  color: #2d7d2f;
}

.status-graded {
  background-color: #e3f7ec;
  color: #1cc88a;
}

.status-late {
  background-color: #ffeae9;
  color: #e74a3b;
}

/* Video Conference */
.conference-card {
  border: 1px solid #e3e6f0;
  border-radius: 0.35rem;
}

.conference-active {
  border-left: 4px solid var(--success);
}

.conference-upcoming {
  border-left: 4px solid var(--primary);
}

.conference-past {
  border-left: 4px solid var(--secondary);
}

/* AI Tutor Chat */
.chat-container {
  max-height: 400px;
  overflow-y: auto;
}

.chat-message {
  padding: 10px 15px;
  border-radius: 10px;
  margin-bottom: 10px;
  max-width: 80%;
}

.chat-question {
  background-color: var(--light-green);
  margin-left: auto;
  border-top-right-radius: 0;
  border: 1px solid var(--accent-green);
}

.chat-answer {
  background-color: #f8f9fa;
  margin-right: auto;
  border-top-left-radius: 0;
  border: 1px solid var(--card-border);
}

/* Profile */
.profile-header {
  background: linear-gradient(135deg, #2d7d2f 0%, #1f5521 100%);
  color: white;
  padding: 2rem 0;
}

.profile-img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 4px solid white;
  object-fit: cover;
  background-color: #e0e0e0;
}

.profile-name {
  font-size: 1.75rem;
  font-weight: 700;
}

.profile-role {
  font-size: 1rem;
  opacity: 0.8;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .navbar-brand {
    font-size: 1.25rem;
  }
  
  .hero h1 {
    font-size: 2rem;
  }
  
  .profile-img {
    width: 80px;
    height: 80px;
  }
  
  .profile-name {
    font-size: 1.5rem;
  }
}

/* Footer */
footer {
  background-color: #fff;
  border-top: 1px solid var(--card-border);
  padding: 1.5rem 0;
}

/* Utilities */
.bg-gradient-primary {
  background: linear-gradient(135deg, #2d7d2f 0%, #1f5521 100%);
}

/* Green theme overrides for Bootstrap primary classes */
.text-green {
  color: #2d7d2f !important;
}

.btn-primary {
  background-color: #2d7d2f !important;
  border-color: #2d7d2f !important;
}

.btn-primary:hover {
  background-color: #1f5521 !important;
  border-color: #1f5521 !important;
}

.btn-outline-primary {
  color: #2d7d2f !important;
  border-color: #2d7d2f !important;
}

.btn-outline-primary:hover {
  background-color: #2d7d2f !important;
  border-color: #2d7d2f !important;
}

.bg-primary {
  background-color: #2d7d2f !important;
}

.border-primary {
  border-color: #2d7d2f !important;
}

.shadow-sm {
  box-shadow: 0 0.125rem 0.25rem 0 rgba(58, 59, 69, 0.2) !important;
}

.shadow {
  box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15) !important;
}

.rounded-circle {
  border-radius: 50% !important;
}

.text-xs {
  font-size: 0.7rem;
}

.text-green {
  color: var(--primary) !important;
}

.text-success {
  color: var(--success) !important;
}

.text-danger {
  color: var(--danger) !important;
}

.text-warning {
  color: var(--warning) !important;
}

.text-info {
  color: var(--info) !important;
}

.bg-light {
  background-color: var(--light) !important;
}

/* Loader */
.loader {
  border: 3px solid rgba(0, 0, 0, 0.1);
  border-radius: 50%;
  border-top: 3px solid var(--primary);
  width: 24px;
  height: 24px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
