main.container {
  padding: 0 !important;
  margin: 0 auto !important;
  max-width: 100% !important;
  width: 100% !important;
}

.explore-header {
  background: linear-gradient(45deg, #2B5876, #4E4376);
  padding: 3rem 0;
  color: white;
  margin-bottom: 2rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  width: 100%;
}

.explore-header h1 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  text-align: center;
  font-weight: 700;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.media-nav,
.tags-container,
.sort-container,
.sort-options,
.grid-item .meta,
.pagination,
.audio-preview,
.pdf-preview,
.document-preview,
.video-preview,
.code-badge {
  display: flex;
}

.media-nav {
  justify-content: center;
  gap: 0.75rem;
  margin: 0 auto 2rem;
  padding: 0 1rem;
  max-width: 1200px;
  flex-wrap: wrap;
}

.media-nav a,
.tag {
  color: white;
  text-decoration: none;
  border-radius: 9999px;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.media-nav a {
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  min-width: 120px;
  justify-content: center;
}

.media-nav a i {
  font-size: 1.1em;
}

.media-nav a:hover,
.tag:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.media-nav a.selected {
  background: rgba(255, 255, 255, 0.25);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.search-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1rem;
}

.search-form {
  display: flex;
  background: white;
  border-radius: 9999px;
  padding: 0.75rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  transition: all 0.3s;
  border: 2px solid transparent;
}

.search-form:focus-within {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
}

.search-form input {
  flex: 1;
  border: none;
  padding: 0.5rem 1rem;
  font-size: 1.1rem;
  outline: none;
  color: #2d3748;
  background: transparent;
}

.search-form input::placeholder {
  color: #a0aec0;
}

.search-form button {
  background: none;
  border: none;
  padding: 0.5rem 1rem;
  cursor: pointer;
  color: #4a5568;
  font-size: 1.2rem;
  transition: color 0.3s;
}

.search-form button:hover {
  color: #2b6cb0;
}

.tags-container {
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 1.5rem;
  padding: 0 1rem;
}

.tag {
  background: rgba(255, 255, 255, 0.1);
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  backdrop-filter: blur(5px);
}

.content-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1rem;
  width: 100%;
}

.sort-container {
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  background: white;
  border-radius: 8px;
  margin-bottom: 1rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.results-count {
  color: #4a5568;
  font-size: 0.95rem;
}

.results-count i,
.sort-options a i {
  margin-right: 0.5rem;
}

.results-count i {
  color: #3182ce;
}

.sort-options {
  gap: 1rem;
}

.sort-options a {
  color: #4a5568;
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-size: 0.95rem;
  transition: all 0.2s;
}

.sort-options a:hover {
  background: #f7fafc;
}

.sort-options a.selected {
  background: #3182ce;
  color: white;
}

.grid-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
  padding: 1rem;
}

.grid-item {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.grid-item .preview {
  position: relative;
  width: 100%;
  padding-top: 75%;
  overflow: hidden;
  display: block;
  background: #f8f9fa;
}

.grid-item .preview > * {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.grid-item .info {
  padding: 1rem;
  border-top: 1px solid #eee;
}

.grid-item .title {
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.grid-item .meta {
  align-items: center;
  gap: 1rem;
  font-size: 0.8rem;
  color: #6c757d;
}

.file-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 3rem;
  color: var(--text-secondary);
  transition: all 0.3s;
  background: rgba(255, 255, 255, 0.9);
  padding: 1rem;
  border-radius: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.grid-item:hover .file-icon {
  transform: translate(-50%, -50%) scale(1.1);
}

.file-type-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(0, 0, 0, 0.5);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 0.85rem;
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  color: #718096;
  max-width: 1400px;
  margin: 0 auto;
}

.empty-state i {
  font-size: 4rem;
  margin-bottom: 1rem;
  color: #a0aec0;
}

.empty-state h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  color: #4a5568;
}

.empty-state p {
  max-width: 500px;
  margin: 0 auto;
}

.pagination {
  justify-content: center;
  gap: 0.5rem;
  margin: 3rem auto;
  max-width: 1400px;
  padding: 0 1rem;
}

.pagination a,
.pagination span {
  padding: 0.75rem 1.25rem;
  border-radius: 0.5rem;
  text-decoration: none;
  transition: all 0.3s;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.pagination a {
  background: white;
  color: #2b6cb0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.pagination a:hover {
  background: #ebf8ff;
  transform: translateY(-1px);
}

.pagination span {
  background: #f7fafc;
  color: #a0aec0;
}

.pagination span.current {
  background: #2b6cb0;
  color: white;
}

.audio-preview,
.pdf-preview,
.document-preview,
.video-preview,
.note-preview,
.archive-preview,
.file-preview {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.audio-preview,
.pdf-preview,
.document-preview,
.video-preview,
.note-preview,
.archive-preview,
.file-preview {
  align-items: center;
  justify-content: center;
}

.audio-preview {
  flex-direction: column;
  padding: 1rem;
}

.audio-preview audio {
  width: 100%;
  margin-top: auto;
  margin-bottom: 1rem;
}

.pdf-preview,
.archive-preview,
.file-preview {
  display: flex;
  flex-direction: column;
  background: #f8f9fa;
  padding: 1rem;
}

.pdf-preview .file-icon {
  font-size: 2.5rem;
  color: #dc3545;
  margin-bottom: 0.5rem;
}

.pdf-info,
.archive-info,
.file-info {
  color: #6c757d;
  font-size: 0.9rem;
}

.document-preview {
  padding: 1rem;
}

.document-content,
.video-info,
.note-content {
  text-align: center;
}

.document-info {
  margin-top: 1rem;
}

.document-ext,
.video-ext {
  font-size: 1.2rem;
  font-weight: 600;
  display: block;
}

.document-ext {
  color: var(--text-primary);
}

.document-size {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.video-preview {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 1rem;
}

.video-preview .file-icon {
  font-size: 3rem;
  color: white;
  margin-bottom: 0.5rem;
}

.video-info {
  margin-top: 0.5rem;
}

.video-ext {
  color: white;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.video-size {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.9);
}

.share-link {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s;
}

.share-link:hover {
  color: var(--primary-color);
}

.meta {
  display: flex;
  gap: 1rem;
  color: var(--text-secondary);
  font-size: 0.875rem;
}

.note-preview {
  display: flex;
  background: #f8f9fa;
  padding: 1.5rem;
}

.note-content .file-icon {
  font-size: 2.5rem;
  color: #3182ce;
  margin-bottom: 1rem;
}

.note-info h3 {
  font-size: 1.1rem;
  color: #2d3748;
  margin: 0.5rem 0;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.4;
}

.code-badge {
  align-items: center;
  background: rgba(49, 130, 206, 0.1);
  color: #3182ce;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  margin-top: 0.5rem;
}

.code-badge i {
  margin-right: 0.25rem;
}

@media (max-width: 768px) {
  .explore-header { padding: 2rem 0; }
  .explore-header h1 { font-size: 2rem; padding: 0 1rem; }
  .media-nav { gap: 0.5rem; padding: 0 0.5rem; }
  .media-nav a { padding: 0.5rem 1rem; font-size: 0.9rem; min-width: auto; }
  .search-container { padding: 0 0.5rem; }

  .grid-container {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
    padding: 1rem 0.5rem;
  }

  .sort-container {
    margin: 1rem 0.5rem;
    padding: 1rem;
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start;
  }

  .sort-options {
    width: 100%;
    justify-content: space-between;
  }

  .grid-item .preview { padding-top: 100%; }
  .audio-preview audio { width: 90%; }
}
