* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #4A90E2;
  --primary-light: #AECBFA;
  --primary-light-bright: #F0F4FF;

  --primary-dark: #357ABD;
  --button-dark: #4A90E2;
  --header-dark: #333333;

  --secondary: #FFC107;
  --accent: #D9534F;
  --success: #5CB85C;
  --danger: #D9534F;
  --warning: #F0AD4E;
  --dark: #212121;
  --light: #FFFFFF;
  --gray-100: #F8F9FA;
  --gray-200: #E9ECEF;
  --gray-300: #DEE2E6;
  --gray-400: #CED4DA;
  --gray-500: #6C757D;

  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);

  --transition: all 0.3s ease-in-out;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
  background: var(--gray-100);
  color: var(--dark);
  line-height: 1.6;
  min-height: 100vh;
  padding-top: 70px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  overflow-y: auto;
}

.petal-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.petal {
    position: absolute;
    top: -20px;
    width: 10px;
    height: 15px;
    background-color: var(--primary-light);
    border-radius: 0 50% 0 50%;
    opacity: 0.6;
    animation: fall 15s linear infinite;
}

@keyframes fall {
    0% {
        transform: translateY(0) rotateZ(0deg) rotateX(0deg);
        opacity: 0.6;
    }
    100% {
        transform: translateY(100vh) rotateZ(360deg) rotateX(180deg);
        opacity: 0;
    }
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.3;
  color: var(--header-dark);
}
h1 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary);
}
h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
}
h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--header-dark);
}
h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--header-dark);
}
p {
  color: var(--gray-500);
  font-size: 0.95rem;
  margin-bottom: 1rem;
}
a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}
a:hover {
  color: var(--primary-dark);
}
body.auth-page {
  padding-top: 0;
}

.auth-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  padding: 20px;
  background: linear-gradient(135deg, var(--primary-light-bright) 0%, var(--gray-100) 100%);
  position: relative;
  z-index: 0;
}

.auth-box {
  background: white;
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  padding: 48px 40px;
  width: 100%;
  max-width: 420px;
  animation: slideUp 0.4s ease;
  position: relative;
  z-index: 2;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.auth-box h1 {
  font-size: 2.25rem;
  text-align: center;
  margin-bottom: 8px;
  color: var(--header-dark);
}

.auth-box .subtitle {
  text-align: center;
  color: var(--gray-500);
  margin-bottom: 32px;
  font-size: 0.95rem;
}

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

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: var(--dark);
  font-size: 0.9rem;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--gray-300);
  border-radius: 8px;
  font-size: 0.95rem;
  transition: var(--transition);
  font-family: inherit;
  background: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
  background: white;
}

.form-group input::placeholder {
  color: var(--gray-400);
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.btn {
  padding: 11px 20px;
  border: none;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  white-space: nowrap;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  width: 100%;
  background: var(--button-dark);
  color: white;
  font-weight: 600;
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover:not(:disabled) {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-primary:active:not(:disabled) {
  transform: translateY(0);
}

.btn-secondary {
  background: var(--gray-100);
  color: var(--primary);
  border: 1px solid var(--gray-300);
}

.btn-secondary:hover:not(:disabled) {
  background: white;
  border-color: var(--primary);
}

.btn-small {
  padding: 8px 14px;
  font-size: 0.85rem;
  border-radius: 6px;
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--gray-300);
  color: var(--dark);
}

.btn-outline:hover {
  background: var(--gray-100);
  border-color: var(--primary);
  color: var(--primary);
}

.btn-logout {
  padding: 8px 14px;
  font-size: 0.85rem;
  border-radius: 6px;
  background: transparent;
  border: 1px solid var(--danger);
  color: var(--danger);
}

.btn-logout:hover:not(:disabled) {
  background: var(--danger);
  color: white;
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.navbar {
  background: #FFFFFF;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  padding: 16px 32px;
  border-radius: 0;
  border: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 1000;
}

.navbar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  max-width: 1280px;
  margin: 0 auto;
  min-width: 0;
}

.navbar-brand {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.navbar h2 {
  font-size: 1.3rem;
  margin: 0;
  font-weight: 600;
  color: var(--header-dark) !important;
  white-space: nowrap;
  letter-spacing: 0.3px;
}

.navbar-menu {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
  min-width: 0;
  flex-shrink: 1;
}

.navbar-menu span {
  font-weight: 500;
  color: var(--dark);
  font-size: 0.9rem;
}

.navbar-menu > * {
  flex-shrink: 0;
  margin: 0;
}

.navbar-menu > div {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  min-width: 0;
}

.navbar-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--primary);
  flex-shrink: 0;
}

.navbar-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.navbar-avatar span {
  font-size: 16px;
  font-weight: bold;
  color: var(--primary);
}

.navbar-menu button,
.navbar-menu a {
  color: var(--dark);
  text-decoration: none;
  font-weight: 500;
  cursor: pointer;
  background: transparent;
  border: 1px solid #E0E0E0;
  padding: 8px 16px;
  border-radius: 6px;
  transition: var(--transition);
  font-size: 0.9rem;
  white-space: nowrap;
  flex-shrink: 0;
  margin: 0;
}

.navbar-menu button:hover,
.navbar-menu a:hover {
  background: #F5F5F5;
  border-color: var(--primary);
  color: var(--primary);
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px 40px 24px;
  min-height: calc(100vh - 70px);
}

.tab-buttons {
  display: flex;
  gap: 8px;
  margin-top: 24px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.tab-buttons .btn {
  width: auto;
  background: white;
  border: 1px solid var(--gray-300);
  color: var(--gray-500);
}

.tab-buttons .btn-primary {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
  box-shadow: none;
}

.dashboard {
  display: none;
  animation: fadeIn 0.25s ease;
}

.dashboard.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
  margin-bottom: 32px;
}

.card {
  background: white;
  border-radius: 12px;
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: 1px solid var(--gray-200);
  margin-bottom: 20px;
  position: relative;
}

.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.card h3 {
  color: var(--dark);
  margin-bottom: 12px;
  font-size: 1.15rem;
}

.card p {
  color: var(--gray-500);
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 16px;
}

.card-badge {
  display: inline-block;
  background: var(--gray-100);
  color: var(--primary);
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-bottom: 12px;
}

.card-stats {
  background: var(--gray-50);
  padding: 16px;
  border-radius: 8px;
  margin: 12px 0;
  text-align: center;
  border: 1px solid var(--gray-200);
}

.card-stats strong {
  color: var(--primary);
  font-size: 1.5rem;
  display: block;
  margin-bottom: 4px;
}

.card-stats span {
  color: var(--gray-500);
  font-size: 0.85rem;
  font-weight: 500;
}

.card-actions {
  display: flex;
  gap: 8px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.teacher-section {
  background: white;
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gray-200);
}

#scoresContainer {
  display: grid;
  gap: 24px;
}

#reportsContainer {
  display: grid;
  gap: 24px;
}

#studentsContainer {
  display: grid;
  gap: 24px;
}

.teacher-section h3 {
  color: var(--dark);
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--gray-200);
}

.student-item {
  background: white;
  padding: 16px;
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid var(--gray-200);
  transition: var(--transition);
  margin-bottom: 0;
}

.student-item:hover {
  box-shadow: var(--shadow-sm);
  border-color: var(--primary);
}

.student-info h4 {
  color: var(--dark);
  margin-bottom: 4px;
  font-weight: 600;
  font-size: 0.95rem;
}

.student-info p {
  color: var(--gray-500);
  font-size: 0.85rem;
  margin: 2px 0;
}

#alertBox {
  margin-top: 20px;
}

.alert {
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 16px;
  font-weight: 500;
  animation: slideDown 0.25s ease;
  display: flex;
  align-items: center;
  gap: 10px;
  border-left: 3px solid;
  font-size: 0.9rem;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.alert-success {
  background: #f1fdf4;
  color: #1b5e20;
  border-left-color: var(--success);
}

.alert-error {
  background: #fff5f5;
  color: #c41c3b;
  border-left-color: var(--danger);
}

.alert-info {
  background: #f0f9ff;
  color: #0c3478;
  border-left-color: var(--primary);
}

.hidden {
  display: none !important;
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(2px);
}

.modal.active {
  display: flex;
}

/* Nested modals - higher z-index for modals opened from other modals */
#addWordToMyGroupModal {
  z-index: 2100;
}

.modal-content {
  background: white;
  border-radius: 12px;
  padding: 32px;
  max-width: 500px;
  width: 100%;
  box-shadow: var(--shadow-xl);
  animation: modalSlideUp 0.3s ease;
  max-height: 85vh;
  overflow-y: auto;
}

@keyframes modalSlideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--gray-200);
}

.modal-header h2 {
  color: var(--dark);
  margin: 0;
  font-size: 1.25rem;
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--gray-400);
  padding: 4px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: var(--transition);
}

.modal-close:hover {
  color: var(--dark);
  background: var(--gray-100);
}

.practice-container {
  background: white;
  border-radius: 12px;
  padding: 24px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 20px;
  border: 1px solid var(--gray-200);
}

.score-display {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: white;
  padding: 16px 24px;
  border-radius: 8px;
  display: flex;
  gap: 24px;
  align-items: center;
  box-shadow: var(--shadow-md);
  font-weight: 600;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.score-display span {
  font-weight: 500;
  display: flex;
  gap: 6px;
  align-items: center;
  font-size: 0.95rem;
}

.score-display strong {
  font-size: 1.25rem;
  font-weight: 700;
}

.vocab-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.vocab-item {
  background: white;
  padding: 20px;
  border-radius: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: var(--transition);
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-sm);
}

.vocab-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.vocab-item.game-mode {
  flex-direction: column;
  align-items: stretch;
  gap: 12px;
}

.vocab-item.game-mode .arabic {
  display: none;
}

.english {
  font-weight: 600;
  color: var(--dark);
  font-size: 1.05rem;
}

.arabic {
  font-weight: 600;
  color: var(--secondary);
  font-size: 1.1rem;
  font-family: 'Arial', sans-serif;
  direction: ltr;
  text-align: left;
}

.arabic-input {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--primary);
  border-radius: 6px;
  font-size: 0.95rem;
  direction: ltr;
  text-align: left;
  font-family: 'Arial', sans-serif;
  outline: none;
  transition: var(--transition);
  display: none;
  font-weight: 500;
}

.arabic-input::placeholder {
  text-align: left;
}

.vocab-item.game-mode .arabic-input {
  display: block;
}

.arabic-input:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
}

.vocab-item.correct {
  background: #f1fdf4;
  border-color: var(--success);
}

.vocab-item.correct .arabic-input {
  border-color: var(--success);
  background: #f1fdf4;
}

.vocab-item.incorrect {
  background: #fff5f5;
  border-color: var(--danger);
}

.vocab-item.incorrect .arabic-input {
  border-color: var(--danger);
  background: #fff5f5;
}

.quiz-container {
  display: none;
  background: white;
  padding: 32px;
  border-radius: 12px;
  text-align: center;
  margin-bottom: 20px;
  border: 1px solid var(--gray-200);
}

.quiz-container.active {
  display: block;
}

.quiz-question {
  font-size: 1.5rem;
  color: var(--dark);
  margin-bottom: 24px;
  font-weight: 500;
}

.quiz-question strong {
  color: var(--primary);
  font-size: 1.75rem;
  font-weight: 700;
}

.quiz-input {
  width: 100%;
  max-width: 380px;
  padding: 14px 16px;
  border: 1px solid var(--primary);
  border-radius: 8px;
  font-size: 1.1rem;
  direction: ltr;
  text-align: left;
  font-family: 'Arial', sans-serif;
  outline: none;
  margin-bottom: 20px;
  transition: var(--transition);
  font-weight: 500;
}

.quiz-input::placeholder {
  text-align: left;
}

.quiz-input:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
}

.quiz-feedback {
  font-size: 1rem;
  font-weight: 600;
  margin-top: 16px;
  min-height: 28px;
}

.quiz-feedback.correct {
  color: var(--success);
}

.quiz-feedback.incorrect {
  color: var(--danger);
}

.quiz-controls {
  margin-top: 20px;
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-quiz {
  background: var(--primary);
  color: white;
  border: none;
  padding: 10px 24px;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.btn-quiz:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-quiz.skip {
  background: var(--warning);
}

.group-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
  background: white;
  border: 1px solid var(--gray-200);
}

.group-checkbox:hover {
  background: var(--gray-100);
}

.group-checkbox input[type="checkbox"] {
  cursor: pointer;
  width: 18px;
  height: 18px;
}

.group-checkbox label {
  margin: 0;
  cursor: pointer;
  flex: 1;
  font-weight: 500;
  font-size: 0.95rem;
}

@media (max-width: 1024px) and (min-width: 769px) {
  .navbar-content {
    gap: 20px;
  }

  .navbar-menu {
    gap: 14px;
  }
}

@media (max-width: 768px) {
  .navbar-content {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .navbar-menu {
    width: 100%;
    gap: 12px;
    justify-content: flex-start;
  }

  .navbar-menu button,
  .navbar-menu a {
    padding: 8px 14px;
  }

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

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

  .tab-buttons {
    flex-direction: column;
  }

  .tab-buttons .btn {
    width: 100%;
  }

  .student-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .modal-content {
    padding: 24px;
  }

  .score-display {
    justify-content: space-around;
  }

  .auth-box {
    padding: 32px 24px;
  }

  h1 {
    font-size: 1.75rem;
  }

  h2 {
    font-size: 1.25rem;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .navbar {
    padding: 12px 16px;
  }

  .navbar h2 {
    font-size: 1.25rem;
  }

  .navbar-menu {
    gap: 12px;
    width: 100%;
    justify-content: flex-end;
  }

  .navbar-menu button,
  .navbar-menu a {
    padding: 8px 12px;
    font-size: 0.85rem;
  }

  .auth-box {
    padding: 24px 20px;
  }

  .auth-box h1 {
    font-size: 1.75rem;
  }

  .modal-content {
    padding: 20px;
  }

  .tab-buttons {
    gap: 6px;
  }

  .quiz-question {
    font-size: 1.25rem;
  }
}

.text-center {
  text-align: center;
}

.mt-20 {
  margin-top: 20px;
}

.mb-20 {
  margin-bottom: 20px;
}

.loading {
  opacity: 0.6;
  pointer-events: none;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--gray-100);
}

::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-dark);
}

.teacher-assignment-badge {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: white;
  border-radius: 12px;
  padding: 16px 20px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--gray-200);
  z-index: 1000;
  min-width: 200px;
  animation: slideUp 0.3s ease;
}

.teacher-assignment-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.teacher-assignment-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--primary);
  flex-shrink: 0;
}

.teacher-assignment-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.teacher-assignment-avatar span {
  font-size: 20px;
  font-weight: bold;
  color: var(--primary);
}

.teacher-assignment-text {
  flex: 1;
  min-width: 0;
}

@media (max-width: 768px) {
  .teacher-assignment-badge {
    bottom: 16px;
    right: 16px;
    left: 16px;
    min-width: auto;
  }
}

/* Language Selector */
.language-selector {
  position: relative;
  width: 100%;
}

.language-selected {
  padding: 12px 16px;
  border: 2px solid var(--gray-300);
  border-radius: 8px;
  background: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  transition: var(--transition);
  user-select: none;
}

.language-selected:hover {
  border-color: var(--primary);
  background: var(--primary-light-bright);
}

.language-search {
  width: 100%;
  padding: 10px 16px;
  border: 2px solid var(--gray-300);
  border-radius: 8px;
  font-size: 14px;
  margin-bottom: 8px;
  outline: none;
  transition: var(--transition);
}

.language-search:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
}

.language-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  max-height: 300px;
  overflow-y: auto;
  background: white;
  border: 2px solid var(--gray-300);
  border-radius: 8px;
  box-shadow: var(--shadow-lg);
  z-index: 1000;
  margin-top: 4px;
}

.language-option {
  padding: 12px 16px;
  cursor: pointer;
  transition: var(--transition);
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

.language-option:last-child {
  border-bottom: none;
}

.language-option:hover {
  background: var(--primary-light-bright);
}

.language-option.selected {
  background: var(--primary-light);
  font-weight: 600;
}

.language-dropdown::-webkit-scrollbar {
  width: 8px;
}

.language-dropdown::-webkit-scrollbar-track {
  background: var(--gray-100);
  border-radius: 4px;
}

.language-dropdown::-webkit-scrollbar-thumb {
  background: var(--gray-400);
  border-radius: 4px;
}

.language-dropdown::-webkit-scrollbar-thumb:hover {
  background: var(--gray-500);
}

.site-footer {
  background: linear-gradient(135deg, #2C3E50 0%, #34495E 100%);
  color: #ECF0F1;
  padding: 30px 20px;
  margin-top: 60px;
  border-top: 5px solid var(--primary);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.footer-section {
  text-align: left;
}

.footer-section h3 {
  color: var(--primary);
  font-size: 1.1rem;
  margin-bottom: 15px;
  font-weight: 700;
  position: relative;
  padding-bottom: 8px;
}

.footer-section h3::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 50px;
  height: 3px;
  background: var(--primary);
  border-radius: 2px;
}

.footer-section p {
  margin: 8px 0;
  font-size: 0.9rem;
  color: #BDC3C7;
  line-height: 1.5;
}

.footer-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-section ul li {
  margin: 10px 0;
}

.footer-section a {
  color: #ECF0F1;
  text-decoration: none;
  font-size: 0.95rem;
  transition: all 0.3s;
  display: inline-block;
  position: relative;
}

.footer-section a::before {
  content: '›';
  margin-right: 8px;
  color: var(--primary);
  font-weight: bold;
  transition: margin-right 0.3s;
}

.footer-section a:hover {
  color: var(--primary);
  padding-left: 5px;
}

.footer-section a:hover::before {
  margin-right: 12px;
}

.footer-contact-item {
  display: flex;
  align-items: center;
  margin: 15px 0;
  color: #BDC3C7;
}

.footer-contact-item strong {
  color: var(--primary);
  margin-right: 10px;
  min-width: 80px;
}

.footer-copyright {
  margin-top: 20px;
  color: #95A5A6;
  font-size: 0.85rem;
}

.footer-brand {
  font-weight: 700;
  color: var(--primary);
  font-size: 0.95rem;
}

.footer-features {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  margin-top: 15px;
}

.footer-feature-tag {
  background: rgba(74, 144, 226, 0.1);
  color: var(--primary);
  padding: 5px 12px;
  border-radius: 15px;
  font-size: 0.85rem;
  border: 1px solid rgba(74, 144, 226, 0.3);
}

@media (max-width: 768px) {
  .footer-container {
    grid-template-columns: 1fr;
    gap: 25px;
  }

  .footer-section {
    text-align: center;
  }

  .footer-section h3::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .footer-contact-item {
    justify-content: center;
  }

  .footer-copyright {
    text-align: center;
  }
}

/* Fullscreen Mode - Hide navbar elements except brand name */
body.fullscreen-mode .navbar-brand > span,
body.fullscreen-mode .navbar-menu {
  display: none !important;
}

body.fullscreen-mode .navbar-brand h2 {
  font-size: 1.1rem !important;
}

body.fullscreen-mode .navbar {
  padding: 8px 15px !important;
}

body.fullscreen-mode .navbar-content {
  justify-content: center !important;
}
