/* Application Review Page Styles */
.application-review-page {
  min-height: 100vh;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
}

/* Simplified Header */
.page-header {
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  padding: 20px 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-main {
  display: flex;
  align-items: center;
  gap: 16px;
}

.header-icon {
  width: 48px;
  height: 48px;
  background: #3b82f6;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 20px;
}

.header-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.page-title {
  margin: 0;
  font-size: 24px;
  font-weight: 600;
  color: #1e293b;
  line-height: 1.2;
}

.page-description {
  margin: 0;
  color: #64748b;
  font-size: 14px;
  font-weight: 400;
}

.header-actions {
  display: flex;
  align-items: center;
}

.view-mode-switch {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 16px;
  background: #f8fafc;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.switch-label {
  font-size: 14px;
  font-weight: 500;
  color: #475569;
}

.view-mode-switch .ant-switch {
  background: #cbd5e1;
}

.view-mode-switch .ant-switch-checked {
  background: #3b82f6 !important;
}

/* Filter Section - Optimized Layout */
.filter-section {
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid #e2e8f0;
  margin: 16px 24px 24px;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.filter-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #3b82f6 0%, #8b5cf6 50%, #06b6d4 100%);
}

.filter-container {
  max-width: 1400px;
  margin: 0 auto;
}

.filter-group {
  display: grid;
  grid-template-columns: 200px 200px 1fr;
  gap: 24px;
  align-items: end;
}

.filter-item {
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
}

.filter-item.search-item {
  max-width: 400px;
}

.filter-label {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 2px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.filter-label .anticon {
  color: #3b82f6;
  font-size: 14px;
  padding: 2px;
  background: rgba(59, 130, 246, 0.1);
  border-radius: 4px;
}

.filter-select {
  border-radius: 12px !important;
  border: 2px solid #e2e8f0 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06) !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  background: #ffffff !important;
  height: 44px !important;
}

.filter-select:hover {
  border-color: #3b82f6 !important;
  box-shadow: 0 4px 16px rgba(59, 130, 246, 0.15) !important;
  transform: translateY(-1px) !important;
}

.filter-select.ant-select-focused {
  border-color: #3b82f6 !important;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.12) !important;
  transform: translateY(-1px) !important;
}

.filter-select .ant-select-selector {
  border: none !important;
  box-shadow: none !important;
  background: transparent !important;
  height: 40px !important;
  padding: 0 16px !important;
}

.filter-select .ant-select-selection-item {
  line-height: 40px !important;
  font-weight: 500 !important;
  color: #374151 !important;
}

.search-input {
  border-radius: 12px !important;
  border: 2px solid #e2e8f0 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06) !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  background: #ffffff !important;
  height: 44px !important;
  padding: 0 16px !important;
  font-weight: 500 !important;
}

.search-input:hover {
  border-color: #3b82f6 !important;
  box-shadow: 0 4px 16px rgba(59, 130, 246, 0.15) !important;
  transform: translateY(-1px) !important;
}

.search-input:focus {
  border-color: #3b82f6 !important;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.12) !important;
  transform: translateY(-1px) !important;
}

.search-input .ant-input {
  font-weight: 500 !important;
  color: #374151 !important;
}

.search-input .anticon {
  color: #6b7280 !important;
  font-size: 16px !important;
}

/* Responsive Design for Filter Section */
@media (max-width: 1200px) {
  .applications-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  }
  
  .filter-group {
    grid-template-columns: 180px 180px 1fr;
    gap: 20px;
  }
  
  .filter-item.search-item {
    max-width: 350px;
  }
  
  .pagination-section {
    padding: 28px 0 36px;
  }
  
  .pagination-section .ant-pagination {
    padding: 14px 20px;
  }
}

@media (max-width: 992px) {
  .filter-section {
    margin: 12px 16px 20px;
    padding: 20px;
  }
  
  .filter-group {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  
  .filter-item.search-item {
    grid-column: 1 / -1;
    max-width: none;
  }
  
  .applications-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
  
  .app-card {
    min-height: 220px;
  }
}

@media (max-width: 768px) {
  .filter-section {
    margin: 8px 12px 16px;
    padding: 16px;
  }
  
  .filter-group {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  
  .filter-select,
  .search-input {
    height: 40px !important;
  }
  
  .filter-select .ant-select-selector {
    height: 36px !important;
    padding: 0 12px !important;
  }
  
  .filter-select .ant-select-selection-item {
    line-height: 36px !important;
  }
  
  .search-input {
    padding: 0 12px !important;
  }
}

@media (max-width: 480px) {
  .filter-section {
    margin: 8px;
    padding: 12px;
    border-radius: 12px;
  }
  
  .filter-label {
    font-size: 12px;
    gap: 6px;
  }
  
  .filter-label .anticon {
    font-size: 12px;
  }
}

/* Content Area */
.page-content {
  flex: 1;
  background: #f8fafc;
  padding: 32px 0 24px;
}

/* Content Main */
.content-main {
  max-width: 100%;
  margin: 0;
  padding: 32px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Applications Grid */
.applications-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-bottom: 32px;
}

/* App Card */
.app-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 20px;
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  min-height: 240px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.app-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  border-color: #3b82f6;
}

.app-card-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 20px;
}

.app-icon-wrapper {
  position: relative;
  flex-shrink: 0;
}

.app-icon {
  border-radius: 16px !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15) !important;
  transition: all 0.3s ease !important;
}

.app-card:hover .app-icon {
  transform: scale(1.05);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2) !important;
}

.status-indicator {
  position: absolute;
  top: -4px;
  right: -4px;
  width: 24px;
  height: 24px;
  background: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  font-size: 12px;
}

.status-approved {
  color: #52c41a;
}

.status-waiting {
  color: #faad14;
}

.status-checking {
  color: #1890ff;
}

.status-rejected {
  color: #ff4d4f;
}

.app-info {
  flex: 1;
  min-width: 0;
}

.app-name {
  margin: 0 0 12px 0;
  font-size: 18px;
  font-weight: 700;
  color: #1a1a1a;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.app-description {
  color: #6b7280;
  font-size: 13px;
  line-height: 1.5;
  margin: 8px 0 12px 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.app-time {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #8c8c8c;
  font-size: 13px;
  margin-bottom: 16px;
}

.app-time .anticon {
  font-size: 12px;
}

.app-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: #666;
}

.app-author {
  display: flex;
  align-items: center;
  gap: 4px;
}

.app-version {
  background: #f0f2f5;
  padding: 2px 8px;
  border-radius: 6px;
  font-weight: 500;
}

.app-card-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}



.app-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid #f0f0f0;
}

.approve-btn {
  border-radius: 6px !important;
  font-weight: 500 !important;
  background: #52c41a !important;
  border-color: #52c41a !important;
  transition: all 0.2s ease !important;
}

.approve-btn:hover {
  background: #73d13d !important;
  border-color: #73d13d !important;
  transform: translateY(-1px) !important;
}

.reject-btn {
  border-radius: 6px !important;
  font-weight: 500 !important;
  transition: all 0.2s ease !important;
}

.reject-btn:hover {
  transform: translateY(-1px) !important;
}

.preview-btn {
  background: #3b82f6 !important;
  border: none !important;
  border-radius: 6px !important;
  font-weight: 500 !important;
  transition: all 0.2s ease !important;
}

.preview-btn:hover {
  background: #2563eb !important;
  transform: translateY(-1px) !important;
}

/* Pagination - Optimized Position */
.pagination-section {
  display: flex;
  justify-content: center;
  padding: 32px 0 40px;
  margin-top: 16px;
  background: linear-gradient(to bottom, transparent 0%, rgba(248, 250, 252, 0.8) 100%);
}

.pagination-section .ant-pagination {
  background: rgba(255, 255, 255, 0.9);
  padding: 16px 24px;
  border-radius: 16px;
  border: 1px solid rgba(226, 232, 240, 0.6);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(10px);
}

.pagination-section .ant-pagination-item {
  border-radius: 6px !important;
  border: 1px solid #d1d5db !important;
  transition: all 0.2s ease !important;
}

.pagination-section .ant-pagination-item:hover {
  border-color: #3b82f6 !important;
}

.pagination-section .ant-pagination-item-active {
  background: #3b82f6 !important;
  border-color: #3b82f6 !important;
}

.pagination-section .ant-pagination-item-active a {
  color: white !important;
}

/* Modern Preview Modal */
.modern-preview-modal .ant-modal-content {
  border-radius: 24px !important;
  overflow: hidden !important;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25) !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  background: rgba(255, 255, 255, 0.95) !important;
  backdrop-filter: blur(20px) !important;
}

.modern-preview-modal .ant-modal-header {
  border-bottom: none !important;
  padding: 0 !important;
}

.modern-preview-modal .ant-modal-body {
  padding: 32px !important;
}

.modal-close-icon {
  font-size: 16px !important;
  color: #666 !important;
  padding: 8px !important;
  border-radius: 50% !important;
  background: rgba(0, 0, 0, 0.05) !important;
  transition: all 0.3s ease !important;
}

.modal-close-icon:hover {
  background: rgba(0, 0, 0, 0.1) !important;
  transform: scale(1.1) !important;
}

.modern-preview-content {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.modal-header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding-bottom: 24px;
  border-bottom: 1px solid #f0f2f5;
}

.app-preview-icon {
  position: relative;
  flex-shrink: 0;
}

.preview-avatar {
  border-radius: 20px !important;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15) !important;
}

.status-badge {
  margin-top: 12px;
}

.app-preview-info {
  flex: 1;
}

.preview-title {
  margin: 0 0 12px 0;
  font-size: 24px;
  font-weight: 700;
  color: #1a1a1a;
  line-height: 1.3;
}

.preview-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #666;
}

.version-info {
  background: #f0f2f5;
  padding: 4px 12px;
  border-radius: 8px;
  font-weight: 500;
}

.author-info {
  display: flex;
  align-items: center;
  gap: 4px;
}

.modal-body {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.info-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.section-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #333;
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-title .anticon {
  color: #667eea;
}

.categories-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.preview-category-tag {
  color: white !important;
  border: none !important;
  border-radius: 8px !important;
  padding: 6px 16px !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  margin: 0 !important;
}

.preview-description {
  margin: 0;
  font-size: 15px;
  line-height: 1.7;
  color: #555;
}

.submission-time {
  margin: 0;
  font-size: 14px;
  color: #666;
  background: #f8f9fa;
  padding: 12px 16px;
  border-radius: 12px;
  border-left: 4px solid #667eea;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .applications-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  }
  
  .pagination-section {
    padding: 28px 0 36px;
  }
  
  .pagination-section .ant-pagination {
    padding: 14px 20px;
  }
}

@media (max-width: 768px) {
  .filter-section {
    margin: 8px 12px 16px;
    padding: 16px;
  }
  
  .filter-group {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  
  .filter-select,
  .search-input {
    height: 40px !important;
  }
  
  .filter-select .ant-select-selector {
    height: 36px !important;
    padding: 0 12px !important;
  }
  
  .filter-select .ant-select-selection-item {
    line-height: 36px !important;
  }
  
  .search-input {
    padding: 0 12px !important;
  }
  
  .applications-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  

  
  .approve-btn,
  .reject-btn,
  .preview-btn {
    min-width: 70px;
  }
  
  .pagination-section {
    padding: 24px 0 32px;
    margin-top: 12px;
  }
  
  .pagination-section .ant-pagination {
    padding: 12px 16px;
    border-radius: 12px;
  }
}

@media (max-width: 480px) {
  .content-main {
    padding: 24px 16px 16px;
  }
  
  .app-card {
    padding: 16px;
  }
  

  
  .pagination-section {
    padding: 20px 0 28px;
  }
  
  .filter-group {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
  }
  
  .header-container {
    padding: 0 16px;
  }
  
  .content-main {
    padding: 32px 16px 24px;
  }
  
  .filter-section {
    margin: 8px 16px 20px;
  }
}

@media (max-width: 900px) {
  .applications-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  }
}

@media (max-width: 768px) {
  .page-header {
    padding: 16px 0;
  }
  
  .header-container {
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
    padding: 0 12px;
  }
  
  .content-main {
    padding: 32px 12px 24px;
  }
  
  .filter-section {
    margin: 8px 12px 20px;
    padding: 16px;
  }
  
  .filter-group {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
  }
  
  .applications-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .app-card {
    padding: 16px;
  }
  
  .modern-preview-modal .ant-modal-body {
    padding: 20px !important;
  }
  
  .modal-header {
    flex-direction: column;
    text-align: center;
  }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
  .modern-application-review {
    background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
  }
  
  .modern-header {
    background: rgba(45, 55, 72, 0.95);
  }
  
  .header-text h1 {
    color: #f7fafc;
  }
  
  .header-text p {
    color: #a0aec0;
  }
  
  .app-card {
    background: rgba(45, 55, 72, 0.95);
  }
  
  .app-name {
    color: #f7fafc;
  }
  
  .app-description {
    color: #a0aec0;
  }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focus states for accessibility */
.app-card:focus-visible {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

.preview-btn:focus-visible {
  outline: 2px solid #667eea;
  outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .app-card {
    border: 2px solid #000;
  }
  
  .preview-btn {
    background: #000 !important;
    color: #fff !important;
  }
}