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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #ffffff;
  padding-top: 70px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 0.625rem 0.9375rem;
  z-index: 9999;
  border-bottom: 1px solid #eeeeee;
  flex-wrap: wrap;
}

.logo {
  font-weight: bold;
  display: inline-flex;
  text-align: center;
  align-items: center;
  padding: 0.625rem 1.5rem;
  color: #333333;
  text-decoration: none;
  margin: 0 0.375rem;
  font-size: 1.2rem;
  white-space: nowrap;
}

.logo img {
  width: 3.125rem;
  height: auto;
  max-height: 3.125rem;
  object-fit: contain;
}

.nav-links {
  display: flex;
  margin-left: 1.875rem;
  gap: 1.25rem;
}

.nav-right {
  display: flex;
  margin-left: auto;
  gap: 1.25rem;
}

.navbar .nav-links a,
.navbar .nav-right a {
  display: flex;
  align-items: center;
  padding: 0.5rem 0.75rem;
  color: #333333;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.3s ease;
  font-size: 1.2rem;
  font-weight: 500;
}

.navbar .nav-links a:hover,
.navbar .nav-right a:hover {
  color: #666666;
}

.nav-right a:last-child {
  margin-right: 1.875rem;
}

.content {
  flex: 1;
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.content h1 {
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  margin-bottom: 1rem;
}

.academic-section {
  text-align: center;
  padding: 4rem 2rem;
  background-color: #f9fafc;
  margin: 2rem 0;
  border-radius: 8px;
}

.academic-section .section-title {
  font-size: clamp(1.8rem, 5vw, 3rem);
  margin-bottom: 0.5rem;
  color: #2c3e50;
}

.academic-section .section-subtitle {
  font-size: 1.1rem;
  color: #6c757d;
  margin-bottom: 4rem;
}

.academic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2.5rem;
  max-width: 1100px;
  margin: 0 auto;
  align-items: stretch;
}

.academic-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem 1.5rem;
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%;
}

.academic-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.academic-card .card-icon {
  width: 60px;
  height: 60px;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background-color: #e3f2fd;
  color: #1976d2;
  font-size: 1.8rem;
}

.academic-card .card-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.academic-card .card-title {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: #2c3e50;
}

.academic-card .card-desc {
  font-size: 0.95rem;
  color: #6c757d;
  line-height: 1.7;
  margin-bottom: 0;
}

.academic-card .card-btn {
  text-decoration: none;
  color: #1976d2;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.3s ease;
  margin-top: 2rem;
}

.academic-card .card-btn:hover {
  color: #1565c0;
}

.global-nodes {
  text-align: center;
  padding: 3rem 2rem;
  margin: 3rem 0;
}

.global-nodes h2 {
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  margin-bottom: 1rem;
  color: #2c3e50;
}

.global-nodes p {
  color: #6c757d;
  font-size: 1.05rem;
}

.header {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  padding: 20px 30px;
  border-radius: 15px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.logo h1 {
  color: #2c3e50;
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 5px;
}

.subtitle {
  color: #7f8c8d;
  font-size: 14px;
  font-weight: 400;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 15px;
}

#username {
  font-weight: 600;
  color: #3498db;
  background: #f8f9fa;
  padding: 8px 16px;
  border-radius: 20px;
  border: 1px solid #e9ecef;
}

.btn {
  padding: 10px 20px;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn:active {
  transform: translateY(0);
}

.btn-primary {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
}

.btn-secondary {
  background: #f8f9fa;
  color: #495057;
  border: 1px solid #dee2e6;
}

.btn-secondary:hover {
  background: #e9ecef;
}

.btn-success {
  background: linear-gradient(135deg, #4CAF50 0%, #2E7D32 100%);
  color: white;
}

.btn-success:hover {
  background: linear-gradient(135deg, #43a047 0%, #1b5e20 100%);
}

.btn-info {
  background: linear-gradient(135deg, #29b6f6 0%, #0288d1 100%);
  color: white;
}

.btn-info:hover {
  background: linear-gradient(135deg, #03a9f4 0%, #0277bd 100%);
}

.btn-danger {
  background: linear-gradient(135deg, #f44336 0%, #c62828 100%);
  color: white;
}

.btn-danger:hover {
  background: linear-gradient(135deg, #e53935 0%, #b71c1c 100%);
}

.control-panel {
  background: rgba(255, 255, 255, 0.95);
  padding: 25px;
  border-radius: 15px;
  margin-bottom: 25px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.search-box {
  display: flex;
  gap: 10px;
  align-items: center;
  flex: 1;
  min-width: 300px;
}

.search-box input {
  flex: 1;
  padding: 12px 20px;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  font-size: 14px;
  transition: all 0.3s ease;
}

.search-box input:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.action-buttons {
  display: flex;
  gap: 15px;
  align-items: center;
}

.page-size-select {
  padding: 10px 15px;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  background: white;
  font-size: 14px;
  color: #495057;
  cursor: pointer;
  transition: all 0.3s ease;
}

.page-size-select:focus {
  outline: none;
  border-color: #667eea;
}

.table-container {
  background: rgba(255, 255, 255, 0.95);
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  margin-bottom: 25px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  position: relative;
  min-height: 300px;
}

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

.data-table thead {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.data-table th {
  padding: 18px 20px;
  text-align: left;
  color: white;
  font-weight: 600;
  font-size: 14px;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.data-table th:last-child {
  border-right: none;
}

.data-table tbody tr {
  border-bottom: 1px solid #e9ecef;
  transition: all 0.3s ease;
}

.data-table tbody tr:hover {
  background-color: #f8f9fa;
}

.data-table td {
  padding: 16px 20px;
  color: #495057;
  font-size: 14px;
}

.data-table .status {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.status.success {
  background: #d4edda;
  color: #155724;
}

.status.warning {
  background: #fff3cd;
  color: #856404;
}

.status.error {
  background: #f8d7da;
  color: #721c24;
}

.action-buttons-cell {
  display: flex;
  gap: 8px;
}

.action-btn {
  padding: 6px 12px;
  border: none;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.action-btn.view {
  background: #e3f2fd;
  color: #1565c0;
}

.action-btn.edit {
  background: #fff3e0;
  color: #ef6c00;
}

.action-btn.delete {
  background: #ffebee;
  color: #c62828;
}

.action-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.loading {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.9);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 20px;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 3px solid #f3f3f3;
  border-top: 3px solid #667eea;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.empty-data {
  padding: 60px 20px;
  text-align: center;
  color: #6c757d;
  font-size: 16px;
}

.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 15px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.pagination-btn {
  padding: 8px 16px;
  border: 1px solid #dee2e6;
  background: white;
  color: #495057;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  min-width: 40px;
  text-align: center;
}

.pagination-btn:hover:not(:disabled) {
  background: #f8f9fa;
  border-color: #667eea;
}

.pagination-btn.active {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border-color: transparent;
}

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

.pagination-info {
  margin: 0 20px;
  color: #6c757d;
  font-size: 14px;
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
  z-index: 1000;
  justify-content: center;
  align-items: center;
  animation: fadeIn 0.3s ease;
}

.modal-content {
  background: white;
  border-radius: 15px;
  width: 90%;
  max-width: 800px;
  max-height: 90vh;
  overflow-y: auto;
  animation: slideUp 0.3s ease;
}

.modal-header {
  padding: 25px 30px;
  border-bottom: 1px solid #e9ecef;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h2 {
  color: #2c3e50;
  font-size: 24px;
  font-weight: 700;
}

.close-btn {
  background: none;
  border: none;
  font-size: 24px;
  color: #6c757d;
  cursor: pointer;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.close-btn:hover {
  background: #f8f9fa;
  color: #495057;
}

.modal-body {
  padding: 30px;
}

.modal-footer {
  padding: 20px 30px;
  border-top: 1px solid #e9ecef;
  display: flex;
  justify-content: flex-end;
  gap: 15px;
}

.form-row {
  display: flex;
  gap: 20px;
  margin-bottom: 20px;
}

.form-row .form-group {
  flex: 1;
}

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

.form-group label {
  display: block;
  margin-bottom: 8px;
  color: #495057;
  font-weight: 600;
  font-size: 14px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e9ecef;
  border-radius: 8px;
  font-size: 14px;
  transition: all 0.3s ease;
  background: white;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

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

.form-hint {
  display: block;
  margin-top: 6px;
  color: #6c757d;
  font-size: 12px;
}

.detail-modal {
  max-width: 700px;
}

.detail-content {
  background: #f8f9fa;
  padding: 25px;
  border-radius: 10px;
}

.detail-row {
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid #e9ecef;
}

.detail-row:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.detail-label {
  font-weight: 600;
  color: #495057;
  margin-bottom: 8px;
  font-size: 14px;
}

.detail-value {
  color: #6c757d;
  line-height: 1.8;
  font-size: 15px;
}

.detail-value.multiline {
  white-space: pre-wrap;
  background: white;
  padding: 15px;
  border-radius: 8px;
  border: 1px solid #e9ecef;
}

.confirm-modal {
  max-width: 500px;
}

.confirm-info {
  margin-top: 15px;
  padding: 12px;
  background: #fff3cd;
  border-radius: 6px;
  color: #856404;
  font-weight: 600;
}

.login-modal {
  max-width: 400px;
}

.login-form {
  margin-top: 20px;
}

.footer-section {
  background-color: #333;
  color: #ccc;
  width: 100%;
  padding: 1.875rem 1.25rem;
  margin-top: auto;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 1.25rem;
  margin-bottom: 0.9375rem;
  flex-wrap: wrap;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.footer-links a {
  color: #ccc;
  text-decoration: none;
  font-size: 0.875rem;
  padding: 0.25rem 0.5rem;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: #fff;
  text-decoration: underline;
}

.footer-info {
  text-align: center;
  font-size: 0.75rem;
  line-height: 1.8;
  max-width: 1200px;
  margin: 0 auto;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.25rem;
}

.footer-info a {
  color: #ccc;
  text-decoration: none;
}

.footer-info a:hover {
  color: #fff;
  text-decoration: underline;
}

@media screen and (max-width: 768px) {
  body {
    padding-top: 60px;
  }
  
  .navbar {
    padding: 0.5rem 0.75rem;
    flex-wrap: nowrap;
  }
  
  .logo {
    padding: 0.5rem 1rem;
    font-size: 1.1rem;
  }
  
  .logo img {
    width: 2.5rem;
    max-height: 2.5rem;
  }
  
  .nav-links {
    margin-left: 1rem;
    gap: 0.75rem;
  }
  
  .nav-right {
    gap: 0.75rem;
  }
  
  .navbar .nav-links a,
  .navbar .nav-right a {
    padding: 0.375rem 0.625rem;
    font-size: 1.2rem;
  }
  
  .nav-right a:last-child {
    margin-right: 1rem;
  }
  
  .content {
    padding: 1.5rem;
  }
  
  .academic-section {
    padding: 3rem 1.5rem;
  }
  
  .academic-grid {
    gap: 1.5rem;
  }
  
  .academic-card {
    padding: 1.5rem 1rem;
  }
  
  .control-panel {
    flex-direction: column;
    align-items: stretch;
  }
  
  .search-box {
    min-width: 100%;
  }
  
  .action-buttons {
    width: 100%;
    justify-content: space-between;
  }
  
  .action-buttons .btn {
    flex: 1;
    margin: 0 5px;
  }
  
  .table-container {
    overflow-x: auto;
  }
  
  .data-table {
    min-width: 700px;
  }
  
  .modal-content {
    width: 90%;
    margin: 20px;
  }
  
  .form-row {
    flex-wrap: wrap;
  }
  
  .form-row .form-group {
    flex: 1 0 45%;
  }
  
  .footer-links {
    gap: 1rem;
  }
  
  .footer-links a {
    font-size: 0.85rem;
  }
}

@media screen and (max-width: 480px) {
  html {
    font-size: 14px;
  }
  
  body {
    padding-top: 55px;
  }
  
  .navbar {
    flex-wrap: wrap;
    padding: 0.375rem 0.5rem;
  }
  
  .logo {
    padding: 0.375rem 0.75rem;
    font-size: 1rem;
    margin: 0 auto;
    width: 100%;
    justify-content: center;
  }
  
  .logo img {
    width: 2.25rem;
    max-height: 2.25rem;
  }
  
  .nav-links,
  .nav-right {
    margin-left: 0;
    justify-content: center;
    width: 100%;
    margin-top: 0.5rem;
    gap: 0.5rem;
  }
  
  .navbar .nav-links a,
  .navbar .nav-right a {
    padding: 0.5rem;
    font-size: 1.0rem;
  }
  
  .nav-right a:last-child {
    margin-right: 0;
  }
  
  .content {
    padding: 1rem 0.75rem;
  }
  
  .academic-section {
    padding: 2rem 1rem;
    margin: 1rem 0;
  }
  
  .academic-section .section-title {
    font-size: clamp(1.5rem, 5vw, 2.2rem);
  }
  
  .academic-section .section-subtitle {
    font-size: 0.95rem;
    margin-bottom: 2.5rem;
  }
  
  .academic-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .academic-card .card-icon {
    width: 50px;
    height: 50px;
    font-size: 1.5rem;
  }
  
  .academic-card .card-title {
    font-size: 1.1rem;
  }
  
  .academic-card .card-desc {
    font-size: 0.9rem;
  }
  
  .global-nodes {
    padding: 2rem 1rem;
    margin: 2rem 0;
  }
  
  .global-nodes h2 {
    font-size: clamp(1.3rem, 4vw, 1.8rem);
  }
  
  .global-nodes p {
    font-size: 0.9rem;
  }
  
  .header {
    flex-direction: column;
    align-items: flex-start;
    padding: 15px 20px;
    margin-bottom: 20px;
    gap: 15px;
  }
  
  .logo h1 {
    font-size: 22px;
  }
  
  .user-info {
    width: 100%;
    justify-content: space-between;
    gap: 10px;
  }
  
  #username {
    font-size: 13px;
    padding: 6px 12px;
  }
  
  .control-panel {
    flex-direction: column;
    align-items: stretch;
    padding: 20px 15px;
    gap: 15px;
  }
  
  .search-box {
    min-width: 100%;
    flex-direction: column;
    align-items: stretch;
  }
  
  .search-box input {
    width: 100%;
    padding: 10px 15px;
    font-size: 16px;
  }
  
  .action-buttons {
    width: 100%;
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .action-buttons .btn {
    flex: 1 0 45%;
    min-width: 45%;
    text-align: center;
    justify-content: center;
    padding: 12px 10px;
    margin: 5px;
  }
  
  .page-size-select {
    width: 100%;
    padding: 12px 15px;
    margin-top: 10px;
  }
  
  .table-container {
    margin: 0 -0.75rem;
    border-radius: 0;
    border-left: none;
    border-right: none;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .data-table {
    min-width: 600px;
  }
  
  .data-table th,
  .data-table td {
    padding: 12px 15px;
    font-size: 13px;
    white-space: nowrap;
  }
  
  .data-table th:nth-child(3),
  .data-table td:nth-child(3),
  .data-table th:nth-child(4),
  .data-table td:nth-child(4) {
    display: none;
  }
  
  .action-buttons-cell {
    flex-direction: column;
    gap: 5px;
  }
  
  .action-btn {
    width: 100%;
    padding: 8px 10px;
    font-size: 11px;
  }
  
  .status {
    padding: 3px 8px;
    font-size: 10px;
  }
  
  .pagination {
    flex-wrap: wrap;
    padding: 15px;
    gap: 8px;
  }
  
  .pagination-btn {
    min-width: 36px;
    height: 36px;
    padding: 0;
  }
  
  .pagination-info {
    order: -1;
    width: 100%;
    text-align: center;
    margin: 0 0 15px 0;
  }
  
  .modal-content {
    width: 95%;
    margin: 10px;
    max-height: 85vh;
  }
  
  .modal-header {
    padding: 20px 15px;
  }
  
  .modal-header h2 {
    font-size: 20px;
  }
  
  .modal-body {
    padding: 20px 15px;
  }
  
  .modal-footer {
    padding: 15px;
    flex-wrap: wrap;
  }
  
  .modal-footer .btn {
    flex: 1 0 100%;
    margin-bottom: 10px;
  }
  
  .modal-footer .btn:last-child {
    margin-bottom: 0;
  }
  
  .form-row {
    flex-direction: column;
    gap: 15px;
    margin-bottom: 15px;
  }
  
  .form-group label {
    font-size: 14px;
    margin-bottom: 6px;
  }
  
  .form-group input,
  .form-group textarea,
  .form-group select {
    padding: 12px;
    font-size: 16px;
    min-height: 44px;
  }
  
  .form-group textarea {
    min-height: 120px;
  }
  
  .detail-content {
    padding: 15px;
  }
  
  .detail-row {
    margin-bottom: 15px;
    padding-bottom: 15px;
  }
  
  .detail-label {
    font-size: 13px;
  }
  
  .detail-value {
    font-size: 14px;
  }
  
  .loading {
    padding: 20px;
  }
  
  .loading p {
    font-size: 14px;
  }
  
  .empty-data {
    padding: 40px 20px;
    font-size: 14px;
  }
  
  .btn .icon {
    width: 18px;
    height: 18px;
  }
  
  .footer-section {
    padding: 1.5rem 0.75rem;
  }
  
  .footer-links {
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
  }
  
  .footer-links a {
    font-size: 0.8rem;
    text-align: center;
    width: 100%;
  }
  
  .footer-info {
    font-size: 0.7rem;
  }
}

@media screen and (min-width: 1200px) {
  .content {
    padding: 2.5rem 3rem;
  }
  
  .academic-section {
    padding: 5rem 2rem;
  }
  
  .footer-section {
    padding: 2.5rem 3rem;
  }
}

@media screen and (min-width: 1600px) {
  .content,
  .footer-links,
  .footer-info {
    max-width: 1400px;
  }
  
  .academic-section {
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
  }
}

@media screen and (max-width: 480px) {
  .hide-on-mobile {
    display: none !important;
  }
}

@media screen and (min-width: 481px) {
  .hide-on-desktop {
    display: none !important;
  }
}

body.accessibility-mode {
  font-size: 18px !important;
  line-height: 2 !important;
  color: #000000 !important;
  background-color: #ffffff !important;
  --text-color: #000000;
  --bg-color: #ffffff;
  --primary-color: #0047AB;
  --secondary-color: #0056B3;
  --focus-color: #FF6B00;
  --link-color: #003366;
  font-weight: 500 !important;
}

.accessibility-mode .navbar,
.accessibility-mode .content,
.accessibility-mode .main-article,
.accessibility-mode .notice-board,
.accessibility-mode .notice-detail,
.accessibility-mode .footer-section {
  background-color: var(--bg-color) !important;
  color: var(--text-color) !important;
}

.accessibility-mode h1,
.accessibility-mode h2,
.accessibility-mode h3,
.accessibility-mode h4,
.accessibility-mode p,
.accessibility-mode .logo,
.accessibility-mode .nav-links a,
.accessibility-mode .nav-right a,
.accessibility-mode .article-subtitle,
.accessibility-mode .article-section-title,
.accessibility-mode .article-paragraph,
.accessibility-mode .notice-title,
.accessibility-mode .notice-link,
.accessibility-mode .notice-text,
.accessibility-mode .notice-detail-title,
.accessibility-mode .notice-detail-content,
.accessibility-mode .footer-links a,
.accessibility-mode .footer-info {
  color: var(--text-color) !important;
}

.accessibility-mode .hero-section {
  background: var(--bg-color) !important;
  color: var(--text-color) !important;
  min-height: auto !important;
  padding: 2rem !important;
  position: relative !important;
}

.accessibility-mode .hero-section::before {
  display: none !important;
}

.accessibility-mode .hero-content {
  color: var(--text-color) !important;
  background-color: var(--bg-color) !important;
  padding: 2rem !important;
  border: 3px solid var(--text-color) !important;
  border-radius: 8px !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2) !important;
}

.accessibility-mode .hero-title,
.accessibility-mode .hero-text {
  color: var(--text-color) !important;
  text-shadow: none !important;
  font-weight: bold !important;
  line-height: 1.8 !important;
}

.accessibility-mode a:focus,
.accessibility-mode button:focus,
.accessibility-mode input:focus,
.accessibility-mode select:focus,
.accessibility-mode textarea:focus {
  outline: 4px solid var(--focus-color) !important;
  outline-offset: 2px !important;
  box-shadow: 0 0 0 6px rgba(255, 107, 0, 0.3) !important;
  border-radius: 2px !important;
}

.accessibility-mode .btn:focus,
.accessibility-mode .notice-back-button:focus,
.accessibility-mode .notice-more-link:focus {
  outline: 4px solid var(--focus-color) !important;
  outline-offset: 4px !important;
}

.accessibility-mode * {
  animation-duration: 0.001s !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.001s !important;
}

.accessibility-mode .navbar .nav-links a:hover,
.accessibility-mode .navbar .nav-right a:hover,
.accessibility-mode .notice-item:hover,
.accessibility-mode .notice-back-button:hover,
.accessibility-mode .notice-more-link:hover,
.accessibility-mode .footer-links a:hover {
  transform: none !important;
  box-shadow: none !important;
}

.accessibility-mode a:not(.btn):not(.logo):not(.notice-back-button) {
  text-decoration: underline !important;
  text-decoration-thickness: 2px !important;
  text-underline-offset: 4px !important;
}

.accessibility-mode a:not(.btn):not(.logo):not(.notice-back-button):hover,
.accessibility-mode a:not(.btn):not(.logo):not(.notice-back-button):focus {
  text-decoration-thickness: 4px !important;
  background-color: rgba(0, 71, 171, 0.1) !important;
}

.accessibility-mode .navbar {
  border-bottom: 3px solid var(--text-color) !important;
  padding: 1rem 0.9375rem !important;
  background-color: var(--bg-color) !important;
}

.accessibility-mode .nav-links a,
.accessibility-mode .nav-right a {
  font-size: 1.3rem !important;
  padding: 0.75rem 1rem !important;
  border: 2px solid transparent !important;
  border-radius: 4px !important;
  margin: 0.125rem !important;
  min-height: 50px !important;
  min-width: 50px !important;
  position: relative !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.accessibility-mode .logo {
  font-size: 1.4rem !important;
  border: 2px solid transparent !important;
}

.accessibility-mode .nav-links a:focus,
.accessibility-mode .nav-right a:focus,
.accessibility-mode .logo:focus {
  border: 2px solid var(--focus-color) !important;
  outline: 2px solid var(--focus-color) !important;
}

.accessibility-mode input,
.accessibility-mode select,
.accessibility-mode textarea,
.accessibility-mode button {
  border: 3px solid var(--text-color) !important;
  background-color: var(--bg-color) !important;
  color: var(--text-color) !important;
  font-size: 1.25rem !important;
  padding: 0.75rem !important;
  min-height: 44px !important;
  min-width: 44px !important;
}

.accessibility-mode .responsive-img {
  border: 3px solid var(--text-color) !important;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2) !important;
}

.accessibility-mode .article-image figcaption {
  font-size: 1.1rem !important;
  color: var(--text-color) !important;
  font-weight: 500 !important;
  border: 2px solid var(--text-color) !important;
  padding: 0.5rem !important;
  background-color: rgba(0, 0, 0, 0.05) !important;
}

.accessibility-mode .navbar a,
.accessibility-mode .notice-link,
.accessibility-mode .notice-back-button,
.accessibility-mode .notice-more-link,
.accessibility-mode .footer-links a {
  min-height: 44px !important;
  min-width: 44px !important;
}

.accessibility-mode .main-article,
.accessibility-mode .notice-detail-container {
  max-width: 70ch !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

.accessibility-mode p,
.accessibility-mode li {
  margin-bottom: 1.5rem !important;
}

.accessibility-mode .notice-item {
  margin-bottom: 1.2rem !important;
  padding-left: 1.5rem !important;
  position: relative !important;
  border-bottom: 2px solid var(--text-color) !important;
}

.accessibility-mode .notice-board,
.accessibility-mode .notice-detail {
  border: 3px solid var(--text-color) !important;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2) !important;
}

.accessibility-mode .notice-board::before {
  background: var(--primary-color) !important;
  width: 8px !important;
}

.accessibility-mode .notice-board {
  background-color: var(--bg-color) !important;
}

.accessibility-mode .notice-title {
  color: var(--text-color) !important;
  font-weight: bold !important;
}

.accessibility-mode .notice-link {
  color: var(--text-color) !important;
  font-weight: 500 !important;
  font-size: 1.1rem !important;
}

.accessibility-mode .notice-link:hover {
  color: var(--text-color) !important;
  background-color: rgba(0, 0, 0, 0.05) !important;
  text-decoration: underline !important;
}

.accessibility-mode .notice-date {
  color: #333 !important;
  font-weight: 500 !important;
}

.accessibility-mode .new-badge,
.accessibility-mode .new-count-badge {
  background-color: #000 !important;
  color: #fff !important;
  font-weight: bold !important;
}

.accessibility-mode .pinned-notice {
  background-color: rgba(255, 193, 7, 0.2) !important;
  border-left: 4px solid #ffc107 !important;
}

.accessibility-mode .footer-section {
  background-color: var(--text-color) !important;
  color: var(--bg-color) !important;
  border-top: 5px solid var(--primary-color) !important;
}

.accessibility-mode .footer-links a,
.accessibility-mode .footer-links p,
.accessibility-mode .footer-info,
.accessibility-mode .footer-info a,
.accessibility-mode .footer-info p {
  color: var(--bg-color) !important;
}

.accessibility-mode .footer-links a:hover,
.accessibility-mode .footer-links a:focus,
.accessibility-mode .footer-links p:hover,
.accessibility-mode .footer-links p:focus {
  background-color: rgba(255, 255, 255, 0.2) !important;
  outline: 2px solid var(--bg-color) !important;
}

.accessibility-mode .skip-nav {
  position: absolute !important;
  top: -50px !important;
  left: 10px !important;
  background-color: var(--primary-color) !important;
  color: white !important;
  padding: 12px !important;
  text-decoration: none !important;
  z-index: 10001 !important;
  border: 3px solid white !important;
}

.accessibility-mode .skip-nav:focus {
  top: 10px !important;
  outline: 4px solid var(--focus-color) !important;
}

.accessibility-mode [tabindex]:focus {
  outline: 4px solid var(--focus-color) !important;
  outline-offset: 4px !important;
  box-shadow: 0 0 0 8px rgba(255, 107, 0, 0.3) !important;
}

.accessibility-mode ::-webkit-scrollbar {
  width: 16px !important;
}

.accessibility-mode ::-webkit-scrollbar-track {
  background-color: var(--bg-color) !important;
  border: 2px solid var(--text-color) !important;
}

.accessibility-mode ::-webkit-scrollbar-thumb {
  background-color: var(--primary-color) !important;
  border: 3px solid var(--bg-color) !important;
  border-radius: 8px !important;
}

.accessibility-mode ::-webkit-scrollbar-thumb:hover {
  background-color: var(--secondary-color) !important;
}

.accessibility-mode .global-nodes {
  border: 3px solid var(--text-color) !important;
  background-color: rgba(0, 71, 171, 0.05) !important;
  border-radius: 8px !important;
  margin: 3rem 0 !important;
}

.accessibility-mode .academic-grid {
  gap: 2rem !important;
}

.accessibility-mode .academic-card .card-title {
  font-weight: 700 !important;
  margin-bottom: 1.5rem !important;
  font-size: 1.4rem !important;
}

.accessibility-mode .academic-card .card-desc {
  font-size: 1.1rem !important;
  line-height: 1.8 !important;
}

@media screen and (max-width: 768px) {
  .accessibility-mode {
    font-size: 1.1rem !important;
  }
  
  .accessibility-mode .navbar {
    flex-wrap: wrap !important;
  }
  
  .accessibility-mode .nav-links,
  .accessibility-mode .nav-right {
    width: 100% !important;
    justify-content: center !important;
    margin-top: 1rem !important;
  }
  
  .accessibility-mode .nav-links a,
  .accessibility-mode .nav-right a {
    min-width: 44px !important;
    padding: 0.75rem !important;
  }
  
  .accessibility-mode .hero-section {
    padding: 1rem !important;
  }
  
  .accessibility-mode .hero-content {
    padding: 1.5rem !important;
  }
}

@media screen and (max-width: 480px) {
  .accessibility-mode .content,
  .accessibility-mode .main-article,
  .accessibility-mode .notice-detail-container {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  
  .accessibility-mode .nav-links a,
  .accessibility-mode .nav-right a {
    width: 100% !important;
    margin-bottom: 0.5rem !important;
    justify-content: center !important;
  }
  
  .accessibility-mode .hero-title {
    font-size: 1.5rem !important;
  }
  
  .accessibility-mode .hero-text {
    font-size: 1.1rem !important;
  }
}

@media print {
  .accessibility-mode * {
    color: #000000 !important;
    background-color: #ffffff !important;
    box-shadow: none !important;
    text-shadow: none !important;
  }
  
  .accessibility-mode a {
    text-decoration: underline !important;
  }
  
  .accessibility-mode .navbar,
  .accessibility-mode .hero-section::before {
    display: none !important;
  }
  
  .accessibility-mode .content {
    max-width: 100% !important;
  }
}

.bg-blue-animate-scroll {
  width: 100vw;
  height: 100vh;
  background: linear-gradient(90deg, #E3F2FD, #BBDEFB, #B3E5FC, #BBDEFB, #E3F2FD);
  background-size: 300% 100%;
  animation: blueScrollAnimate 15s ease-in-out infinite;
}

@media (hover: none) and (pointer: coarse) {
  .btn,
  .action-btn,
  .pagination-btn,
  .close-btn {
    min-height: 44px;
    min-width: 44px;
  }
  
  .form-group input,
  .form-group select,
  .form-group textarea {
    font-size: 16px;
  }
  
  .data-table tbody tr {
    padding: 10px 0;
  }
  
  .btn:hover,
  .action-btn:hover,
  .pagination-btn:hover {
    transform: none;
  }
  
  .btn:active,
  .action-btn:active,
  .pagination-btn:active {
    transform: scale(0.98);
    opacity: 0.9;
  }
}

@media screen and (min-width: 769px) {
  .table-container {
    overflow-x: visible;
    overflow: hidden;
  }
  
  .data-table {
    table-layout: auto;
    width: 100%;
    max-width: 100%;
  }
  
  .data-table th,
  .data-table td {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  
  .data-table td:nth-child(2),
  .data-table td:nth-child(5) {
    white-space: normal;
    word-wrap: break-word;
    word-break: break-word;
  }
  
  .action-buttons-cell {
    display: flex;
    flex-wrap: nowrap;
    gap: 5px;
  }
  
  .action-btn {
    flex-shrink: 0;
    min-width: 50px;
  }
  
  html, body {
    overflow-x: hidden;
  }
}

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

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

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

@keyframes blueScrollAnimate {
  0% {
    background-position: 0% 0%;
  }
  50% {
    background-position: 100% 0%;
  }
  100% {
    background-position: 0% 0%;
  }
}
html {
  overflow-x: hidden;
  overflow-y: auto;
}
body {
  overflow-x: hidden;
  overflow-y: auto;
}
::-webkit-scrollbar {
  width: 12px;
  height: 12px;
}
::-webkit-scrollbar-track {
  background: #f5f5f5;
  border-radius: 6px;
}
::-webkit-scrollbar-thumb {
  background: #dcdcdc;
  border-radius: 6px;
  border: 2px solid #f5f5f5;
}
::-webkit-scrollbar-thumb:hover {
  background: #c5c5c5; 
}
.navbar {
  width: calc(100%) !important; 
  right: 0 !important; 
  left: auto !important; 
}
@media screen and (max-width: 768px) {
  body {
    padding-right: 0 !important; 
  }
  .navbar {
    width: 100% !important; 
  }
  ::-webkit-scrollbar {
    display: none;
  }
  html, body {
    -ms-overflow-style: none; 
    scrollbar-width: none; 
  }
}
html {
  scrollbar-width: thin; 
  scrollbar-color: #dcdcdc #f5f5f5; 
}
#auth-initial-style{
  a[href="test.html"] {
    opacity: 0.3;
    pointer-events: none;
    cursor: not-allowed;
    transition: all 0.3s ease; 
  }
  a[href="test.html"].link-enabled,
  a[href="test.html"][style*="opacity: 1"] {
    opacity: 1 !important;
    pointer-events: auto !important;
    cursor: pointer !important;
  }
  #loginLink::after {
    content: " (未登录)";
    font-size: 0.8em;
    color: #666;
  }
  #loginLink.user-logged-in::after {
    content: " ✓";
    color: #4CAF50;
    font-size: 1em;
  }
}

#beian img {
  width: 15px;
  height: auto;
  transform: translateY(0.1875rem);
}

#beian p {
  width: auto;
  height: auto;
}