/* ============================================
 ITNv7 Prep - Cisco Exam Preparation
 Modern Dark Theme (GitHub Style)
 ============================================ */

/* === RESET & BASE === */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { max-width: 100vw; }

:root {
 --bg-primary: #0d1117;
 --bg-secondary: #161b22;
 --bg-tertiary: #21262d;
 --border-color: #30363d;
 --text-primary: #e6edf3;
 --text-secondary: #8b949e;
 --text-muted: #6e7681;
 --text-tertiary: #484f58;
 --border-hover: #8b949e;
 --accent-green: #238636;
 --accent-green-hover: #2ea043;
 --accent-green-light: #3fb950;
 --accent-blue: #58a6ff;
 --accent-blue-light: #79c0ff;
 --accent-purple: #8957e5;
 --accent-purple-light: #d2a8ff;
 --accent-orange: #f78166;
 --accent-yellow: #d29922;
 --accent-red: #f85149;
 --radius-sm: 6px;
 --radius-md: 8px;
 --radius-lg: 12px;
 --shadow: 0 8px 24px rgba(0,0,0,0.4);
 --transition: all 0.2s ease;
}

body {
 font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
 background: var(--bg-primary);
 color: var(--text-primary);
 line-height: 1.6;
 min-height: 100vh;
}

a { color: var(--accent-blue); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--accent-blue-light); text-decoration: underline; }

/* === LAYOUT === */
.app-container {
 display: flex;
 min-height: 100vh;
 overflow-x: hidden;
 max-width: 100vw;
}

/* === SIDEBAR === */
.sidebar { width: 280px; background: var(--bg-secondary); border-right: 1px solid var(--border-color); position: fixed; top: 0; left: 0; height: 100vh; overflow-y: auto; z-index: 100; display: flex; flex-direction: column; -ms-overflow-style: none; scrollbar-width: none;}.sidebar::-webkit-scrollbar { display: none;}

.sidebar-header {
 padding: 20px;
 border-bottom: 1px solid var(--border-color);
 display: flex;
 align-items: center;
 gap: 12px;
}

.sidebar-logo {
 width: 40px;
 height: 40px;
 background: linear-gradient(135deg, var(--accent-green) 0%, var(--accent-blue) 100%);
 border-radius: var(--radius-md);
 display: flex;
 align-items: center;
 justify-content: center;
 font-size: 1.4em;
}

.sidebar-title {
 font-size: 1.1em;
 font-weight: 600;
 color: var(--text-primary);
}

.sidebar-subtitle {
 font-size: 0.75em;
 color: var(--text-secondary);
}

.sidebar-nav {
 flex: 1;
 padding: 16px 12px;
}

.nav-section {
 margin-bottom: 24px;
}

.nav-section-title {
 font-size: 0.7em;
 font-weight: 600;
 color: var(--text-muted);
 text-transform: uppercase;
 letter-spacing: 0.5px;
 padding: 0 12px;
 margin-bottom: 8px;
}

.nav-item {
 display: flex;
 align-items: center;
 gap: 12px;
 padding: 10px 12px;
 border-radius: var(--radius-sm);
 color: var(--text-secondary);
 transition: var(--transition);
 cursor: pointer;
 text-decoration: none;
}

.nav-item:hover {
 background: var(--bg-tertiary);
 color: var(--text-primary);
 text-decoration: none;
}

.nav-item.active {
 background: rgba(56, 139, 253, 0.15);
 color: var(--accent-blue);
}

.nav-item-icon {
 width: 20px;
 text-align: center;
 font-size: 0.9em;
}

.nav-item-text {
 flex: 1;
 font-size: 0.9em;
}

.nav-item-status {
 width: 8px;
 height: 8px;
 border-radius: 50%;
 background: var(--border-color);
}

.nav-item-status.completed { background: var(--accent-green-light); }
.nav-item-status.in-progress { background: var(--accent-yellow); }

/* Sidebar Progress */
.progress-bar {
 height: 6px;
 background: var(--bg-primary);
 border-radius: 3px;
 overflow: hidden;
}

/* === MAIN CONTENT === */
.main-content {
 flex: 1;
 margin-left: 280px;
 min-height: 100vh;
 max-width: 100%;
 overflow-x: hidden;
}

.page-header {
 background: var(--bg-secondary);
 border-bottom: 1px solid var(--border-color);
 padding: 24px 40px;
}

.page-title {
 font-size: 1.8em;
 font-weight: 600;
 margin-bottom: 6px;
}

.page-subtitle {
 color: var(--text-secondary);
 font-size: 0.95em;
}

.page-content {
 padding: 30px 40px;
 max-width: 1200px;
}

/* === CARDS === */
.card {
 background: var(--bg-secondary);
 border: 1px solid var(--border-color);
 border-radius: var(--radius-lg);
 overflow: hidden;
 transition: var(--transition);
}

.card:hover {
 border-color: var(--accent-blue);
 transform: translateY(-2px);
 box-shadow: var(--shadow);
}

.card-header {
 padding: 16px 20px;
 border-bottom: 1px solid var(--border-color);
 display: flex;
 align-items: center;
 justify-content: space-between;
}

/* Module Cards Grid */
.modules-grid {
 display: grid;
 grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
 gap: 20px;
 margin-top: 24px;
}

.module-card {
 background: var(--bg-secondary);
 border: 1px solid var(--border-color);
 border-radius: var(--radius-lg);
 overflow: hidden;
 transition: var(--transition);
 cursor: pointer;
 text-decoration: none;
 color: inherit;
}

.module-card:hover {
 border-color: var(--accent-green);
 transform: translateY(-4px);
 box-shadow: var(--shadow);
 text-decoration: none;
 color: inherit;
}

.module-card-header {
 padding: 20px;
 background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%);
 display: flex;
 align-items: flex-start;
 gap: 16px;
}

.module-icon {
 width: 48px;
 height: 48px;
 background: var(--bg-primary);
 border-radius: var(--radius-md);
 display: flex;
 align-items: center;
 justify-content: center;
 font-size: 1.5em;
 flex-shrink: 0;
}

.module-info h3 {
 font-size: 1.05em;
 font-weight: 600;
 margin-bottom: 4px;
}

.module-info p {
 font-size: 0.85em;
 color: var(--text-secondary);
 line-height: 1.4;
}

.module-card-footer {
 padding: 14px 20px;
 border-top: 1px solid var(--border-color);
 display: flex;
 align-items: center;
 justify-content: space-between;
 font-size: 0.8em;
 color: var(--text-secondary);
}

.module-meta {
 display: flex;
 gap: 16px;
}

.module-meta span {
 display: flex;
 align-items: center;
 gap: 5px;
}

.module-status {
 padding: 4px 10px;
 border-radius: 12px;
 font-size: 0.75em;
 font-weight: 500;
}

.module-status.locked { background: var(--bg-tertiary); color: var(--text-muted); }
.module-status.available { background: rgba(35, 134, 54, 0.2); color: var(--accent-green-light); }
.module-status.in-progress { background: rgba(210, 153, 34, 0.2); color: var(--accent-yellow); }
.module-status.completed { background: rgba(63, 185, 80, 0.2); color: var(--accent-green-light); }

/* === STATS CARDS === */

/* === HERO SECTION === */
.hero {
 background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
 padding: 60px 40px;
 text-align: center;
 border-bottom: 1px solid var(--border-color);
}

.hero-badge {
 display: inline-block;
 background: rgba(35, 134, 54, 0.2);
 color: var(--accent-green-light);
 padding: 6px 16px;
 border-radius: 20px;
 font-size: 0.8em;
 font-weight: 500;
 margin-bottom: 20px;
}

.hero h1 {
 font-size: 2.8em;
 font-weight: 700;
 margin-bottom: 16px;
 background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent-blue) 100%);
 -webkit-background-clip: text;
 -webkit-text-fill-color: transparent;
 background-clip: text;
}

.hero p {
 font-size: 1.15em;
 color: var(--text-secondary);
 max-width: 600px;
 margin: 0 auto 30px;
 line-height: 1.7;
}

.hero-buttons {
 display: flex;
 gap: 16px;
 justify-content: center;
 flex-wrap: wrap;
}

/* === BUTTONS === */
.btn {
 display: inline-flex;
 align-items: center;
 gap: 8px;
 padding: 12px 24px;
 border-radius: var(--radius-sm);
 font-size: 0.95em;
 font-weight: 600;
 cursor: pointer;
 border: none;
 transition: var(--transition);
 text-decoration: none;
}

.btn-primary {
 background: var(--accent-green);
 color: white;
}

.btn-primary:hover {
 background: var(--accent-green-hover);
 transform: translateY(-2px);
 text-decoration: none;
 color: white;
}

.btn-secondary {
 background: var(--bg-tertiary);
 color: var(--text-primary);
 border: 1px solid var(--border-color);
}

.btn-secondary:hover {
 border-color: var(--accent-blue);
 color: var(--accent-blue);
 text-decoration: none;
}

/* === PROGRESS CIRCLE === */
/* === CISCO TERMINAL === */
/* === EXERCISES === */
.exercise-container {
 background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
 border: 2px solid var(--accent-green);
 border-radius: var(--radius-lg);
 margin: 24px 0;
 overflow: hidden;
}

.exercise-container.success { border-color: var(--accent-green-light); box-shadow: 0 0 20px rgba(63, 185, 80, 0.2); }
.exercise-container.error { border-color: var(--accent-red); }

.exercise-header {
 background: linear-gradient(135deg, var(--accent-green) 0%, var(--accent-green-hover) 100%);
 padding: 14px 20px;
 display: flex;
 justify-content: space-between;
 align-items: center;
}

.exercise-header h4 {
 color: white;
 font-size: 1em;
 display: flex;
 align-items: center;
 gap: 10px;
}

.exercise-badge {
 background: rgba(255,255,255,0.2);
 padding: 4px 12px;
 border-radius: 20px;
 font-size: 0.8em;
}

.exercise-difficulty {
 display: flex;
 gap: 4px;
}

.exercise-difficulty span {
 width: 10px;
 height: 10px;
 border-radius: 50%;
 background: rgba(255,255,255,0.3);
}

.exercise-difficulty span.active { background: white; }

.exercise-body { padding: 20px; }

.exercise-prompt {
 color: var(--text-secondary);
 margin-bottom: 16px;
 line-height: 1.6;
}

.exercise-prompt strong { color: var(--text-primary); }
.exercise-prompt code {
 background: var(--bg-tertiary);
 color: var(--accent-blue-light);
 padding: 2px 8px;
 border-radius: 4px;
}

.exercise-input {
 display: flex;
 align-items: center;
 background: #000;
 border: 1px solid var(--border-color);
 border-radius: var(--radius-md);
 padding: 12px 16px;
 font-family: 'SF Mono', monospace;
}

.exercise-input .prompt {
 color: var(--accent-green-light);
 font-weight: 600;
 white-space: nowrap;
 margin-right: 8px;
}

.exercise-input input {
 flex: 1;
 background: transparent;
 border: none;
 outline: none;
 color: white;
 font-family: inherit;
 font-size: 0.95em;
 caret-color: var(--accent-green-light);
}

.exercise-input input::placeholder { color: var(--text-muted); }

.exercise-feedback {
 margin-top: 12px;
 padding: 12px 16px;
 border-radius: var(--radius-sm);
 display: none;
 align-items: center;
 gap: 10px;
}

.exercise-feedback.show { display: flex; }
.exercise-feedback.success { background: rgba(63, 185, 80, 0.15); border: 1px solid rgba(63, 185, 80, 0.4); color: var(--accent-green-light); }
.exercise-feedback.error { background: rgba(248, 81, 73, 0.15); border: 1px solid rgba(248, 81, 73, 0.4); color: var(--accent-red); }

.hint-box {
 background: rgba(137, 87, 229, 0.1);
 border-left: 3px solid var(--accent-purple);
 padding: 12px 16px;
 margin-top: 12px;
 border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
 color: var(--accent-purple-light);
 display: none;
 font-size: 0.9em;
}

.hint-box.show { display: block; }
.hint-box code { background: rgba(137, 87, 229, 0.2); color: var(--accent-purple-light); }

/* === BADGES === */
.badge {
 display: inline-flex;
 align-items: center;
 gap: 6px;
 padding: 4px 12px;
 border-radius: 20px;
 font-size: 0.75em;
 font-weight: 500;
}

/* === MOBILE MENU BUTTON === */
.mobile-menu-btn {
 display: none;
}

/* === RESPONSIVE === */
@media (max-width: 1024px) {
 .sidebar { width: 240px; }
 .main-content { margin-left: 240px; }
}

@media (max-width: 768px) {
 /* Mobile Menu Button */
 .mobile-menu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 56px;
  height: 56px;
  background: var(--accent-green);
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 24px;
  font-weight: bold;
  cursor: pointer;
  z-index: 10000;
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
 }

 .mobile-menu-btn:active {
  transform: scale(0.95);
 }

 /* Sidebar Mobile */
 .sidebar {
 transform: translateX(-100%);
 transition: transform 0.3s ease;
 z-index: 9999;
 }

 .sidebar.open { transform: translateX(0); z-index: 9999; }

 .main-content { margin-left: 0; max-width: 100vw; overflow-x: hidden; }

 .hero h1 { font-size: 2em; }
 .page-content { padding: 15px; }
 .page-header { padding: 16px 15px; }
 .modules-grid { grid-template-columns: 1fr; }

 /* Auth Modal - Mobile */
 .auth-modal-content {
  margin: 10px;
  max-width: calc(100% - 20px);
  max-height: calc(100vh - 20px);
  overflow-y: auto;
 }
 .auth-modal-header { padding: 20px 20px 0; }
 .auth-modal-header h2 { font-size: 1.2em; }
 .auth-tabs { margin: 16px 16px 0; }
 .auth-tab { padding: 10px 8px; font-size: 0.85em; }
 .auth-form { padding: 16px; }
 .form-group { margin-bottom: 12px; }
 .form-input { padding: 10px 12px; font-size: 0.9em; }
 .password-requirements { padding: 10px; }
 .password-requirements ul { grid-template-columns: 1fr; }
 .btn-auth { padding: 12px; font-size: 0.95em; }

 /* Exercises - Mobile */
 .exercise-container { margin: 16px 0; border-radius: var(--radius-md); }
 .exercise-header { padding: 12px 14px; flex-wrap: wrap; gap: 8px; }
 .exercise-header h4 { font-size: 0.9em; }
 .exercise-badge { padding: 3px 8px; font-size: 0.7em; }
 .exercise-body { padding: 14px; }
 .exercise-prompt { font-size: 0.9em; margin-bottom: 12px; }
 .exercise-input { padding: 10px 12px; flex-wrap: wrap; }
 .exercise-input .prompt { font-size: 0.85em; margin-bottom: 4px; width: 100%; }
 .exercise-input input { font-size: 0.9em; width: 100%; }
 .exercise-feedback { padding: 10px 12px; font-size: 0.85em; }
 .hint-box { padding: 10px 12px; font-size: 0.85em; }

 /* Exercise Actions - Mobile */
 .exercise-actions { flex-wrap: wrap; gap: 8px; }
 .exercise-actions .btn { padding: 8px 12px; font-size: 0.8em; flex: 1; min-width: 80px; justify-content: center; }
}

/* === ANIMATIONS === */
@keyframes fadeIn {
 from { opacity: 0; transform: translateY(10px); }
 to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
 0%, 100% { transform: scale(1); }
 50% { transform: scale(1.05); }
}

/* === PRINT === */
@media print {
 .sidebar, .exercise-container, .btn { display: none; }
 .main-content { margin-left: 0; }
}

/* === USER MENU & AUTH === */
.user-menu {
 display: flex;
 align-items: center;
 gap: 12px;
 padding: 12px 16px;
 background: var(--bg-tertiary);
 border-radius: var(--radius-md);
 margin: 12px;
 margin-bottom: 8px;
}

.user-avatar {
 width: 36px;
 height: 36px;
 background: linear-gradient(135deg, var(--accent-green) 0%, var(--accent-blue) 100%);
 border-radius: 50%;
 display: flex;
 align-items: center;
 justify-content: center;
 font-weight: 600;
 font-size: 0.9em;
 color: white;
}

.user-info { flex: 1; min-width: 0; }
.user-name { font-weight: 600; font-size: 0.9em; color: var(--text-primary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-status { font-size: 0.75em; color: var(--accent-green-light); }
.user-actions { display: flex; gap: 6px; }

.user-action-btn {
 width: 28px;
 height: 28px;
 border: none;
 background: var(--bg-secondary);
 border-radius: var(--radius-sm);
 color: var(--text-secondary);
 cursor: pointer;
 display: flex;
 align-items: center;
 justify-content: center;
 transition: var(--transition);
 font-size: 0.8em;
}

.user-action-btn:hover { background: var(--bg-primary); color: var(--text-primary); }
.user-action-btn.danger:hover { background: rgba(248, 81, 73, 0.2); color: var(--accent-red); }

/* Guest Banner */
/* Auth Modal */
.auth-modal {
 display: none;
 position: fixed;
 top: 0;
 left: 0;
 width: 100%;
 height: 100%;
 z-index: 99999;
}

.auth-modal.show { display: flex; align-items: center; justify-content: center; }

.auth-modal-backdrop {
 position: absolute;
 top: 0;
 left: 0;
 width: 100%;
 height: 100%;
 background: rgba(0, 0, 0, 0.7);
 backdrop-filter: blur(4px);
}

.auth-modal-content {
 position: relative;
 background: var(--bg-secondary);
 border: 1px solid var(--border-color);
 border-radius: var(--radius-lg);
 width: 100%;
 max-width: 420px;
 margin: 20px;
 box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
 animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
 from { opacity: 0; transform: translateY(-20px) scale(0.95); }
 to { opacity: 1; transform: translateY(0) scale(1); }
}

.auth-modal-header { padding: 24px 24px 0; text-align: center; }
.auth-modal-header h2 { font-size: 1.4em; font-weight: 600; margin-bottom: 8px; }
.auth-modal-header p { color: var(--text-secondary); font-size: 0.9em; }

.auth-modal-close {
 position: absolute;
 top: 16px;
 right: 16px;
 width: 32px;
 height: 32px;
 border: none;
 background: var(--bg-tertiary);
 border-radius: var(--radius-sm);
 color: var(--text-secondary);
 cursor: pointer;
 display: flex;
 align-items: center;
 justify-content: center;
 font-size: 1.2em;
 transition: var(--transition);
}

.auth-modal-close:hover { background: var(--bg-primary); color: var(--text-primary); }

.auth-tabs { display: flex; margin: 20px 24px 0; border-bottom: 1px solid var(--border-color); }

.auth-tab {
 flex: 1;
 padding: 12px;
 border: none;
 background: none;
 color: var(--text-secondary);
 font-size: 0.95em;
 font-weight: 500;
 cursor: pointer;
 border-bottom: 2px solid transparent;
 transition: var(--transition);
}

.auth-tab:hover { color: var(--text-primary); }
.auth-tab.active { color: var(--accent-green); border-bottom-color: var(--accent-green); }

.auth-form { padding: 24px; display: none; }
.auth-form.active { display: block; }

.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 0.85em; font-weight: 500; margin-bottom: 8px; color: var(--text-secondary); }

.form-input {
 width: 100%;
 padding: 12px 16px;
 background: var(--bg-tertiary);
 border: 1px solid var(--border-color);
 border-radius: var(--radius-sm);
 color: var(--text-primary);
 font-size: 0.95em;
 transition: var(--transition);
}

.form-input:focus { outline: none; border-color: var(--accent-green); box-shadow: 0 0 0 3px rgba(35, 134, 54, 0.2); }
.form-input::placeholder { color: var(--text-muted); }

.password-requirements { margin-top: 8px; padding: 12px; background: var(--bg-tertiary); border-radius: var(--radius-sm); font-size: 0.8em; }
.password-requirements p { color: var(--text-secondary); margin-bottom: 8px; }
.password-requirements ul { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.password-requirements li { color: var(--text-muted); display: flex; align-items: center; gap: 6px; }
.password-requirements li.valid { color: var(--accent-green-light); }

.auth-error { background: rgba(248, 81, 73, 0.15); border: 1px solid rgba(248, 81, 73, 0.3); color: var(--accent-red); padding: 12px; border-radius: var(--radius-sm); margin-bottom: 16px; font-size: 0.9em; text-align: center; font-weight: 500; }

.auth-error:empty { display: none; }

.auth-error.show { display: block; }

.btn-auth {
 width: 100%;
 padding: 14px;
 background: var(--accent-green);
 border: none;
 border-radius: var(--radius-sm);
 color: white;
 font-size: 1em;
 font-weight: 600;
 cursor: pointer;
 transition: var(--transition);
}

.btn-auth:hover { background: var(--accent-green-hover); }
.btn-auth:disabled { opacity: 0.6; cursor: not-allowed; }

/* Auth Required - Blur content when not logged in */
body.auth-required .main-content {
 filter: blur(8px);
 pointer-events: none;
 user-select: none;
}

.password-requirements span {
 font-size: 0.7em;
 padding: 2px 8px;
 background: var(--bg-tertiary);
 border-radius: 10px;
 color: var(--text-muted);
 transition: all 0.2s ease;
 display: inline-block;
 margin: 2px;
}

.password-requirements span.valid {
 background: rgba(35, 134, 54, 0.3);
 color: var(--accent-green-light);
}

/* Leaderboard Table */
.leaderboard-table {
 width: 100%;
 border-collapse: collapse;
 font-size: 0.9em;
}

.leaderboard-table th,
.leaderboard-table td {
 padding: 12px 10px;
 text-align: left;
 border-bottom: 1px solid var(--border-color);
}

.leaderboard-table th {
 background: var(--bg-tertiary);
 font-weight: 600;
 color: var(--text-secondary);
 font-size: 0.85em;
 text-transform: uppercase;
}

.leaderboard-table tr:hover {
 background: var(--bg-tertiary);
}

.leaderboard-table .leaderboard-me {
 background: rgba(35, 134, 54, 0.15);
}

.leaderboard-table .leaderboard-me td {
 color: var(--accent-green-light);
 font-weight: 600;
}

.form-hint {
 color: var(--accent-blue);
 font-style: italic;
 margin-bottom: 8px;
 padding: 10px;
 background: var(--bg-tertiary);
 border-radius: var(--radius-sm);
}

.auth-modal-close {
 position: absolute;
 top: 16px;
 right: 16px;
 width: 32px;
 height: 32px;
 border: none;
 background: var(--bg-tertiary);
 border-radius: var(--radius-sm);
 color: var(--text-secondary);
 cursor: pointer;
 display: flex;
 align-items: center;
 justify-content: center;
 font-size: 1.4em;
 transition: var(--transition);
}

.auth-modal-close:hover {
 background: rgba(248, 81, 73, 0.2);
 color: var(--accent-red);
}

/* === FOOTER === */
.site-footer {
 background: var(--bg-secondary);
 border-top: 1px solid var(--border-color);
 padding: 20px;
 text-align: center;
 font-size: 0.85em;
 color: var(--text-secondary);
 margin-top: auto;
 max-width: 100%;
 overflow-x: hidden;
 box-sizing: border-box;
}
.site-footer a {
 color: var(--accent-blue);
 text-decoration: none;
 margin: 0 10px;
}
.site-footer a:hover {
 text-decoration: underline;
}
.site-footer .copyright {
 margin-bottom: 8px;
}

.footer-links {
 margin-bottom: 10px;
}
.footer-links a {
 margin: 0 8px;
}
.disclaimer {
 font-size: 0.75em;
 color: var(--text-tertiary);
 margin-top: 10px;
 font-style: italic;
}

/* === LANGUAGE SELECTOR === */
.lang-selector {
 position: fixed;
 top: 16px;
 right: 16px;
 z-index: 1000;
 display: flex;
 gap: 6px;
 background: var(--bg-secondary);
 border: 1px solid var(--border-color);
 border-radius: var(--radius-md);
 padding: 6px;
}

.lang-btn {
 display: flex;
 align-items: center;
 justify-content: center;
 width: 36px;
 height: 28px;
 border: none;
 background: transparent;
 border-radius: var(--radius-sm);
 cursor: pointer;
 transition: var(--transition);
 font-size: 1.1em;
 opacity: 0.6;
 text-decoration: none;
}

.lang-btn:hover {
 background: var(--bg-tertiary);
 opacity: 1;
 text-decoration: none;
}

.lang-btn.active {
 background: var(--bg-tertiary);
 opacity: 1;
 box-shadow: 0 0 0 2px var(--accent-green);
}

.lang-btn img {
 width: 24px;
 height: 16px;
 border-radius: 2px;
 object-fit: cover;
}

/* On landing page, selector is inline in nav */
.landing-page .lang-selector {
 position: static !important;
 background: transparent;
 border: none;
 padding: 0;
}

.landing-page .lang-btn {
 background: var(--bg-tertiary);
 border: 1px solid var(--border-color);
}

@media (max-width: 768px) {
 .lang-selector {
  top: 12px;
  right: 12px;
  padding: 4px;
 }
 .lang-btn {
  width: 32px;
  height: 24px;
  font-size: 1em;
 }
}


/* Hide fixed lang selector on pages with sidebar (not landing page) */
.page-dashboard .lang-selector,
.page-module .lang-selector,
.page-exam .lang-selector {
 display: none;
}

/* === SIDEBAR LANGUAGE SELECTOR === */
.sidebar-footer {
 padding: 16px 20px;
 border-top: 1px solid var(--border-color);
 margin-top: auto;
}

.sidebar-lang-selector {
 display: flex;
 align-items: center;
 justify-content: space-between;
}

.sidebar-lang-label {
 font-size: 0.85em;
 color: var(--text-secondary);
}

.lang-buttons {
 display: flex;
 gap: 6px;
}

.sidebar-lang-selector .lang-btn {
 width: 36px;
 height: 28px;
 background: var(--bg-tertiary);
 border: 1px solid var(--border-color);
 border-radius: var(--radius-sm);
 display: flex;
 align-items: center;
 justify-content: center;
 font-size: 1.1em;
 opacity: 0.7;
 transition: var(--transition);
 text-decoration: none;
}

.sidebar-lang-selector .lang-btn:hover {
 opacity: 1;
 border-color: var(--accent-green);
}

.sidebar-lang-selector .lang-btn.active {
 opacity: 1;
 border-color: var(--accent-green);
 box-shadow: 0 0 0 2px rgba(35, 134, 54, 0.3);
}
