/* 招生动态样式 */
/* 阴影样式 */
.shadow-card {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.shadow-card-hover {
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* 过渡效果 */
.transition-custom {
  transition: all 0.3s ease;
}

/* 筛选工具栏样式 */
#school-search-input:focus,
#region-filter:focus,
#major-filter:focus,
#year-filter:focus,
#sort-select:focus {
  box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.1);
}

/* 学校卡片样式 */
[data-school-id] {
  height: 100%;
  display: flex;
  flex-direction: column;
}

[data-school-id] .view-detail-btn {
  margin-top: auto;
}

/* 收藏按钮样式 */
.follow-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.25rem;
  padding: 0.25rem;
}

.follow-btn.active i {
  color: #ffc107;
  transform: scale(1.1);
}

/* 倒计时样式 */
.countdown {
  color: #dc3545;
  font-weight: 600;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
  100% {
    opacity: 1;
  }
}

/* 模态框样式 */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.show {
  opacity: 1;
  visibility: visible;
}

.modal-container {
  background-color: white;
  border-radius: 12px;
  width: 90%;
  max-width: 900px;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.modal-overlay.show .modal-container {
  transform: scale(1);
}

.modal-header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1f2937;
  margin: 0;
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: #6b7280;
  padding: 0.25rem;
  line-height: 1;
}

.modal-close:hover {
  color: #374151;
}

.modal-body {
  padding: 2rem;
  overflow-y: auto;
  flex: 1;
}

.modal-footer {
  padding: 1.5rem 2rem;
  border-top: 1px solid #e5e7eb;
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
}

/* 时间轴样式 */
.timeline {
  position: relative;
  padding-left: 2.5rem;
  margin: 2rem 0;
}

.timeline::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0.75rem;
  width: 2px;
  background-color: #e5e7eb;
}

.timeline-item {
  position: relative;
  margin-bottom: 1.5rem;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-item::before {
  content: '';
  position: absolute;
  top: 0.5rem;
  left: -2.5rem;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  background-color: #ffffff;
  border: 2px solid #3b82f6;
}

.timeline-item.completed::before {
  background-color: #3b82f6;
}

.timeline-item.current::before {
  background-color: #ffffff;
  border-color: #ef4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
}

.timeline-date {
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.25rem;
}

.timeline-title {
  font-weight: 500;
  color: #6b7280;
}

/* 表格样式 */
.major-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
}

.major-table th,
.major-table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid #e5e7eb;
}

.major-table th {
  background-color: #f9fafb;
  font-weight: 600;
  color: #374151;
}

.major-table tr:hover {
  background-color: #f9fafb;
}

/* 按钮样式 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-weight: 500;
  transition: all 0.3s ease;
  cursor: pointer;
  border: none;
  text-decoration: none;
}

.btn-primary {
  background-color: #3b82f6;
  color: white;
}

.btn-primary:hover {
  background-color: #2563eb;
}

.btn-outline {
  background-color: white;
  color: #3b82f6;
  border: 1px solid #3b82f6;
}

.btn-outline:hover {
  background-color: #f9fafb;
}

/* 通知样式 */
.notification {
  position: fixed;
  top: 2rem;
  right: 2rem;
  padding: 1rem 1.5rem;
  border-radius: 0.5rem;
  background-color: #10b981;
  color: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transform: translateX(100%);
  transition: transform 0.3s ease;
  z-index: 1001;
}

.notification.show {
  transform: translateX(0);
}

.notification.success {
  background-color: #10b981;
}

.notification.error {
  background-color: #ef4444;
}

.notification.warning {
  background-color: #f59e0b;
}

.notification-info {
  background-color: #3b82f6;
}

/* 分页样式 */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin-top: 2rem;
}

.pagination button {
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  border: 1px solid #e5e7eb;
  background-color: white;
  cursor: pointer;
  transition: all 0.2s ease;
}

.pagination button:hover:not(:disabled) {
  background-color: #f9fafb;
}

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

.pagination button.active {
  background-color: #3b82f6;
  color: white;
  border-color: #3b82f6;
}

/* 加载状态 */
.loading {
  display: inline-block;
  width: 1.5rem;
  height: 1.5rem;
  border: 2px solid #e5e7eb;
  border-top: 2px solid #3b82f6;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

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

/* 响应式设计 */
@media (max-width: 768px) {
  .modal-container {
    width: 95%;
    margin: 1rem;
  }
  
  .modal-header,
  .modal-body,
  .modal-footer {
    padding: 1rem;
  }
  
  .timeline {
    padding-left: 2rem;
  }
  
  .timeline::before {
    left: 0.5rem;
  }
  
  .timeline-item::before {
    left: -2rem;
    width: 1rem;
    height: 1rem;
  }
  
  .major-table {
    font-size: 0.875rem;
  }
  
  .major-table th,
  .major-table td {
    padding: 0.75rem 0.5rem;
  }
  
  .notification {
    top: 1rem;
    right: 1rem;
    left: 1rem;
  }
}

/* 打印样式 */
@media print {
  .modal-overlay {
    position: static;
    background: none;
  }
  
  .modal-container {
    width: 100%;
    max-height: none;
    box-shadow: none;
  }
  
  .modal-header .modal-close,
  .modal-footer,
  .btn,
  .follow-btn,
  .pagination,
  #admin-entry-btn {
    display: none;
  }
}

/* 暗色模式支持 */
@media (prefers-color-scheme: dark) {
  .shadow-card {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  }
  
  .shadow-card-hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  }
  
  [data-school-id] {
    background-color: #1f2937;
    border-color: #374151;
  }
  
  [data-school-id] h3 {
    color: #f9fafb;
  }
  
  [data-school-id] p {
    color: #d1d5db;
  }
  
  .modal-container {
    background-color: #1f2937;
  }
  
  .modal-header,
  .modal-footer {
    border-color: #374151;
  }
  
  .modal-header h2 {
    color: #f9fafb;
  }
  
  .major-table th {
    background-color: #374151;
    color: #f9fafb;
  }
  
  .major-table tr:hover {
    background-color: #374151;
  }
  
  .timeline::before {
    background-color: #374151;
  }
  
  .timeline-date {
    color: #f9fafb;
  }
  
  .timeline-title {
    color: #d1d5db;
  }
}