:root {
  --bg-primary: #0a0c0f;
  --bg-secondary: #14181c;
  --bg-tertiary: #1e2329;
  --bg-hover: #232a33;
  --border-color: #2a2f35;
  --border-hover: #3a4450;
  --text-primary: #e6e9ef;
  --text-secondary: #a8b3cf;
  --text-muted: #6c7a96;
  --accent-blue: #5f7eb0;
  --accent-blue-light: #7a9bc9;
  --accent-subtle: #2e3b4e;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.5);
  --gradient: linear-gradient(135deg, var(--accent-blue), var(--accent-blue-light));
}

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

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;
  font-size: 16px;
}

/* Layout */
.app-container {
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.sidebar {
  background: var(--bg-secondary);
  border-right: 1px solid var(--border-color);
  padding: 2rem 1.5rem;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  width: 300px;
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
}

/* Profile Card */
.profile-card {
  text-align: center;
  padding: 1.5rem 1rem;
  margin-bottom: 2rem;
  margin-top: 3rem;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-tertiary);
  border-radius: 16px;
}

.avatar {
  width: 100px;
  height: 100px;
  margin: 0 auto 1rem;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--accent-blue);
  box-shadow: var(--shadow-md);
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-name {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.profile-nick {
  color: var(--text-muted);
  font-size: 0.875rem;
  margin-bottom: 1rem;
}

.social-tabs {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  flex-wrap: wrap;
}

.chip {
  padding: 0.375rem 1rem;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 30px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.875rem;
  transition: all 0.2s ease;
}

.chip:hover {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
  transform: translateY(-2px);
}

.contact-links .icon {
  width: 18px;
  height: 18px;
  vertical-align: middle;
  margin-right: 6px;
  filter: invert(73%) sepia(9%) saturate(420%) hue-rotate(186deg) brightness(92%) contrast(88%);
}

/* Category Tree */
.category-tree {
  padding: 1rem 0;
  max-height: calc(100vh - 300px);
  overflow-y: auto;
}

.category-tree ul {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.tree-root {
  padding-left: 0 !important;
}

.tree-node {
  margin: 4px 0;
  list-style: none;
}

.tree-node-content {
  display: flex;
  align-items: center;
  padding: 0.625rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.95rem;
}

.tree-node-content:hover {
  background: var(--bg-hover);
}

.tree-node-content.active {
  background: var(--accent-subtle);
  border-left: 3px solid var(--accent-blue);
}

.tree-toggle {
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  margin-right: 0.5rem;
  font-size: 0.8rem;
  cursor: pointer;
  user-select: none;
  transition: transform 0.2s;
  background: var(--bg-tertiary);
  border-radius: 4px;
}

.tree-toggle.expanded {
  transform: rotate(90deg);
  color: var(--accent-blue);
}

.tree-label {
  flex: 1;
  color: var(--text-primary);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tree-label:hover {
  color: var(--accent-blue);
}

.post-count-badge {
  background: var(--bg-tertiary);
  color: var(--text-muted);
  padding: 0.125rem 0.5rem;
  border-radius: 20px;
  font-size: 0.7rem;
  margin-left: 0.5rem;
  white-space: nowrap;
  border: 1px solid var(--border-color);
}

.tree-children {
  margin-left: 1.5rem;
  padding-left: 0.5rem;
  border-left: 2px solid var(--border-color);
  position: relative;
}

.tree-dot {
  margin-right: 0.5rem;
  color: var(--text-muted);
  font-size: 0.5rem;
}

/* Main Content */
.main-content {
  flex: 1;
  padding: 2.5rem;
  max-width: calc(100% - 300px);
  overflow-x: hidden;
}

/* Top Navigation */
.top-nav {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.nav-tab {
  padding: 0.5rem 1.25rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 30px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.875rem;
  transition: all 0.2s ease;
  font-weight: 500;
  display: inline-block;
}

.nav-tab:hover {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}



/* Page Header */
.page-header {
  margin-bottom: 2.5rem;
}

.page-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.page-description {
  color: var(--text-muted);
  font-size: 1.1rem;
}

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 0;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--border-color);
  flex-wrap: wrap;
  font-size: 0.95rem;
  position: relative;
  z-index: 10;
}

.breadcrumbs .nav-tab {
  margin-right: 0.5rem;
  background: transparent;
  border: none;
  border-radius: 4px;
  padding: 0.25rem 0.5rem;
  color: var(--text-secondary);
  box-shadow: none;
  transform: none;
}

.breadcrumbs a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.breadcrumbs .nav-tab:hover {
  color: var(--accent-blue);
  background: var(--bg-hover);
  border: none;
  box-shadow: none;
  transform: none;
}

.breadcrumbs a:hover {
  color: var(--accent-blue);
  background: var(--bg-hover);
}

.breadcrumbs .current {
  color: var(--text-primary);
  font-weight: 500;
  background: var(--bg-tertiary);
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
}

.separator {
  color: var(--text-muted);
  font-size: 0.875rem;
}

/* Stats Bar */
.stats-bar {
  display: flex;
  gap: 2rem;
  padding: 1.5rem;
  margin-bottom: 2.5rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  flex-wrap: wrap;
}

.stats-bar .stat-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex: 1;
  min-width: 150px;
}

.stat-icon {
  width: 48px;
  height: 48px;
  background: var(--bg-tertiary);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-blue);
  font-size: 1.5rem;
  border: 1px solid var(--border-color);
}

.stat-info h4 {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.2;
}

.stat-info p {
  font-size: 0.875rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Modern Filter Bar */
.filter-bar-modern {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 60px;
  padding: 0.75rem 1rem 0.75rem 1.5rem;
  margin-bottom: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  box-shadow: var(--shadow-sm);
}

.search-wrapper {
  flex: 2;
  min-width: 280px;
  position: relative;
}

.search-wrapper input {
  width: 100%;
  padding: 0.875rem 1rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 40px;
  color: var(--text-primary);
  font-size: 1rem;
  transition: all 0.2s;
}

.search-wrapper input:focus {
  outline: none;
  border-color: var(--accent-blue);
  box-shadow: 0 0 0 3px rgba(95, 126, 176, 0.2);
}

.search-wrapper input::placeholder {
  color: var(--text-muted);
}

.search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 1.2rem;
}

.filter-dropdowns {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  flex: 1;
}

.filter-select {
  padding: 0.75rem 2.5rem 0.75rem 1.25rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 40px;
  color: var(--text-primary);
  font-size: 0.95rem;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236c7a96' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  min-width: 160px;
  transition: all 0.2s;
}

.filter-select:focus {
  outline: none;
  border-color: var(--accent-blue);
}

.filter-select:hover {
  background: var(--bg-hover);
}

/* Active Filters */
.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1rem 0 2rem;
}

.filter-badge {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 0.5rem 1rem;
  border-radius: 40px;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  transition: all 0.2s;
  box-shadow: var(--shadow-sm);
}

.filter-badge:hover {
  border-color: var(--accent-blue);
  background: var(--accent-subtle);
}

.filter-badge button {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1.2rem;
  line-height: 1;
  padding: 0 0.25rem;
  transition: color 0.2s;
}

.filter-badge button:hover {
  color: var(--accent-blue);
}

/* Section Title */
.section-title {
  font-size: 1.75rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
  position: relative;
  padding-bottom: 0.75rem;
}



/* Modern Category Cards */
.categories-grid-modern {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0 3rem;
}

.category-card-modern {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 24px;
  padding: 1.75rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  text-align: center;
}

.category-card-modern::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.category-card-modern:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent-blue);
}

.category-card-modern:hover::before {
  opacity: 1;
}

.category-icon {
  width: 56px;
  height: 56px;
  background: var(--bg-tertiary);
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem auto;
  color: var(--accent-blue);
  font-size: 1.75rem;
  border: 1px solid var(--border-color);
  transition: all 0.3s;
}

.category-card-modern:hover .category-icon {
  background: var(--accent-blue);
  color: white;
  border-color: var(--accent-blue);
}

.category-card-modern h3 {
  font-size: 1.35rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}

.category-card-modern h3 a {
  color: inherit;
  text-decoration: none;
}

.category-card-modern h3 a:hover {
  color: var(--accent-blue);
}

.category-stats {
  display: flex;
  gap: 1.25rem;
  margin-bottom: 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.category-stats span {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.category-description {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  flex: 1;
}

.category-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: auto;
}

.category-tag {
  padding: 0.35rem 1rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 30px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.2s;
}

.category-tag:hover {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
}

/* Modern Post Cards */
.posts-grid-modern {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}

.post-card-modern {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 24px;
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
  box-shadow: var(--shadow-sm);
}

.post-card-modern:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent-blue);
}

.post-card-image-modern {
  height: 200px;
  overflow: hidden;
  position: relative;
  background: var(--bg-tertiary);
}

.post-card-image-modern img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.post-card-modern:hover .post-card-image-modern img {
  transform: scale(1.05);
}

.post-card-category {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: var(--accent-blue);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
  z-index: 2;
}

/* Writeup content images */
.writeup-content img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  margin: 1rem auto;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
}

.writeup-content video {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  margin: 1rem 0;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  background: black;
  display: block;
}

.writeup-content code {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.9em;
}
.writeup-content pre {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1rem;
  margin: 1rem 0;
  overflow-x: auto;
  line-height: 1.5;
}
.writeup-content pre code {
  background: transparent;
  border: none;
  padding: 0;
}
.writeup-content blockquote {
  border-left: 4px solid var(--accent-blue);
  background: var(--accent-subtle);
  margin: 1rem 0;
  padding: 0.75rem 1rem;
  color: var(--text-secondary);
  border-radius: 0 8px 8px 0;
}
.writeup-content hr {
  border: none;
  border-top: 1px solid var(--border-color);
  margin: 2rem 0;
}
.writeup-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  overflow: hidden;
  border-radius: 8px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
}
.writeup-content th,
.writeup-content td {
  border: 1px solid var(--border-color);
  padding: 0.6rem 0.75rem;
  text-align: left;
}
.writeup-content thead th {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}
.writeup-content .mermaid {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1rem;
  overflow-x: auto;
  margin: 1rem 0;
}

/* Code block container with header */
.code-block {
  position: relative;
  margin: 1rem 0;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-tertiary);
}
.code-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0.75rem;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  font-size: 0.85rem;
  color: var(--text-muted);
}
.code-lang {
  opacity: 0.8;
}
.code-copy {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.code-copy:hover {
  background: var(--accent-subtle);
  border-color: var(--accent-blue);
  color: var(--text-primary);
}
.code-content {
  padding: 0;
}
.code-block pre {
  border: none;
  border-radius: 0;
  margin: 0;
}

.writeup-content img:hover {
  box-shadow: var(--shadow-md);
  transform: scale(1.02);
  transition: all 0.3s ease;
}

.writeup-content .indent-p {
  margin-left: 0.9rem;
}
.writeup-content .indent-list {
  margin-left: 1.5rem;
}

/* Obsidian-like list indentation */
.writeup-content ul,
.writeup-content ol {
  margin: 0.25rem 0 0.75rem 1.25rem;
  padding-left: 1.25rem;
}
.writeup-content li {
  margin: 0.25rem 0;
}
.writeup-content li ul,
.writeup-content li ol {
  margin-left: 1.25rem;
}

/* Image container for better spacing */
.writeup-content p:has(img) {
  text-align: center;
  margin: 1.5rem 0;
}

/* Responsive images */
@media (max-width: 768px) {
  .writeup-content img {
    margin: 0.5rem 0;
  }
}

/* Writeup meta (date + tags) */
.writeup .writeup-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  row-gap: 0.4rem;
  color: var(--text-muted);
  margin: 0.5rem 0 1rem;
}
.writeup .writeup-date {
  font-size: 0.95rem;
  color: var(--text-secondary);
}
.writeup .writeup-date time {
  background: transparent;
  border: none;
  padding: 0;
  border-radius: 0;
  color: var(--text-secondary);
}
.writeup .tags-label {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-right: 0.25rem;
}
.writeup .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.writeup .tags-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.writeup .tags .tag {
  padding: 0.35rem 0.75rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 999px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  transition: all 0.2s ease;
}
.writeup .tags .tag:hover {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
  color: #fff;
}

.post-navigation {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin: 2rem 0 0;
}
.post-navigation .nav-link {
  flex: 1;
  text-decoration: none;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 0.85rem 1rem;
  border-radius: 12px;
  text-align: center;
  transition: all 0.2s ease;
  box-shadow: var(--shadow-sm);
}
.post-navigation .nav-link:hover {
  border-color: var(--accent-blue);
  color: #fff;
  background: var(--accent-subtle);
}

.post-card-content-modern {
  padding: 1.75rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  text-align: center;
}

.post-card-meta-modern {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.post-card-date {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.post-card-title-modern {
  font-size: 1.35rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.post-card-title-modern a {
  color: var(--text-primary);
  text-decoration: none;
  transition: color 0.2s;
}

.post-card-title-modern a:hover {
  color: var(--accent-blue);
}

.post-card-excerpt-modern {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  flex: 1;
}

.post-card-tags-modern {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: auto;
}

.post-tag-modern {
  padding: 0.35rem 1rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 30px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.2s;
}

.post-tag-modern:hover {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
}

/* Tag Cloud Section */
.tag-cloud-section {
  margin: 3rem 0;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  padding: 1.5rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 24px;
}

.tag-cloud-item {
  padding: 0.5rem 1.25rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 40px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: calc(0.8rem + 0.2rem * var(--weight, 1));
  transition: all 0.2s;
  cursor: pointer;
}

.tag-cloud-item:hover {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
  transform: scale(1.05);
}

.tag-cloud-item.active {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
}

/* Empty State */
.no-results-modern {
  text-align: center;
  padding: 4rem 2rem;
  background: var(--bg-secondary);
  border-radius: 32px;
  border: 2px dashed var(--border-color);
  margin: 2rem 0;
}

.no-results-icon {
  font-size: 5rem;
  margin-bottom: 1.5rem;
  opacity: 0.5;
}

.no-results-modern h3 {
  font-size: 1.75rem;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}

.no-results-modern p {
  color: var(--text-muted);
  margin-bottom: 2rem;
  font-size: 1.1rem;
}

.reset-filters-btn {
  padding: 0.875rem 2.5rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 40px;
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.2s;
  font-size: 1rem;
  font-weight: 500;
}

.reset-filters-btn:hover {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
  transform: translateY(-2px);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
  display: none;
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  background: var(--accent-blue);
  border: none;
  border-radius: 50%;
  width: 56px;
  height: 56px;
  font-size: 1.75rem;
  color: white;
  cursor: pointer;
  z-index: 1001;
  box-shadow: var(--shadow-lg);
  transition: all 0.2s;
}

.mobile-menu-toggle:hover {
  background: var(--accent-blue-light);
  transform: scale(1.1);
}

.mobile-menu-toggle.active {
  background: var(--accent-subtle);
}

/* Mobile Responsive */
@media (max-width: 1024px) {
  .main-content {
    padding: 2rem;
  }
  
  .stats-bar {
    flex-direction: column;
    gap: 1rem;
  }
  
  .stat-item {
    min-width: auto;
  }
}

/* About Page Styles */
.about-section {
  margin-top: 2rem;
}

.about-header {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-bottom: 3rem;
  padding: 2rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
}

.about-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--accent-blue);
  box-shadow: var(--shadow-md);
}

.about-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-intro h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.about-title {
  font-size: 1.2rem;
  color: var(--accent-blue-light);
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.about-handle {
  font-size: 1rem;
  color: var(--text-muted);
  font-family: monospace;
}

.about-content {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.about-card {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2rem;
  transition: all 0.3s ease;
}

.about-card:hover {
  border-color: var(--accent-blue);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.about-card h2 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.about-card p {
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 1rem;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.skill-item {
  padding: 0.5rem 1rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-align: center;
  transition: all 0.3s ease;
}

.skill-item:hover {
  border-color: var(--accent-blue);
  color: var(--text-primary);
  transform: translateY(-1px);
}

.tech-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.tech-category h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: var(--accent-blue-light);
}

.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tech-tags span {
  padding: 0.35rem 0.75rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  font-size: 0.8rem;
  color: var(--text-muted);
  transition: all 0.3s ease;
}

.tech-tags span:hover {
  border-color: var(--accent-blue);
  color: var(--text-primary);
}

.cert-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 1rem;
}

.cert-item {
  padding: 1rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  transition: all 0.3s ease;
}

.cert-item:hover {
  border-color: var(--accent-blue);
  transform: translateX(4px);
}

.cert-title {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.cert-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.contact-section {
  margin-top: 3rem;
  text-align: center;
}

.contact-section h2 {
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.contact-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.contact-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  text-decoration: none;
  color: var(--text-secondary);
  transition: all 0.3s ease;
}

.contact-link:hover {
  border-color: var(--accent-blue);
  color: var(--text-primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.contact-link .icon {
  font-size: 1.2rem;
}

@media (max-width: 768px) {
  .about-header {
    flex-direction: column;
    text-align: center;
  }
  
  .about-intro h1 {
    font-size: 2rem;
  }
  
  .skills-grid {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  }
  
  .tech-grid {
    grid-template-columns: 1fr;
  }
  
  .contact-links {
    flex-direction: column;
    align-items: center;
  }
}

/* Modern Category Page Styles */
.category-header {
  margin-bottom: 2rem;
  padding: 2rem 0;
  border-bottom: 1px solid var(--border-color);
}

.category-title {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 1rem;
}

.category-stats {
  display: flex;
  gap: 2rem;
  color: var(--text-secondary);
  font-size: 1.1rem;
}

.category-stat {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.category-stat::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--accent-blue);
  border-radius: 50%;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--accent-blue);
}

.subcategories-section {
  margin-bottom: 3rem;
}

.subcategories-grid-modern {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.posts-section {
  margin-bottom: 2rem;
}

.posts-grid-modern {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 2.5rem;
}

/* Callouts */
.callout {
  border: 1px solid var(--border-color);
  background: var(--bg-tertiary);
  border-radius: 10px;
  padding: 1rem 1rem 1rem 1.25rem;
  margin: 1rem 0;
  position: relative;
}
.callout::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--border-color);
  border-radius: 10px 0 0 10px;
}
.callout-title {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}
.callout-info::before { background: var(--accent-blue); }
.callout-warning::before { background: #b58900; }
.callout-tip::before { background: #2aa198; }
.callout-note::before { background: #6c7a96; }

/* Footnotes */
.footnotes {
  margin-top: 2rem;
  color: var(--text-secondary);
}
.footnotes ol {
  padding-left: 1.25rem;
}
.footnote-backref {
  margin-left: 0.5rem;
  text-decoration: none;
  color: var(--accent-blue);
}

/* Subcategory Card Modern */
.subcategory-card-modern {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 0.75rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  text-decoration: none;
  color: var(--text-primary);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  text-align: center;
  aspect-ratio: 1 / 1;
}

.subcategory-card-modern::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--accent-blue);
  transform: scaleY(0);
  transition: transform 0.3s ease;
}

.subcategory-card-modern:hover {
  transform: translateY(-4px);
  border-color: var(--accent-blue);
  box-shadow: var(--shadow-lg);
}

.subcategory-card-modern:hover::before {
  transform: scaleY(1);
}

.subcategory-name {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.subcategory-count {
  color: var(--text-muted);
  font-size: 0.75rem;
  margin-bottom: 0.4rem;
}

.subcategory-link {
  color: var(--accent-blue);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  transition: color 0.3s ease;
}

.subcategory-link:hover {
  color: var(--accent-blue-light);
  text-decoration: underline;
}

/* Responsive Category */
@media (max-width: 768px) {
  .category-title {
    font-size: 2rem;
  }
  
  .category-stats {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .posts-grid-modern {
    grid-template-columns: 1fr;
  }
  
  .subcategories-grid-modern {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .sidebar {
    position: fixed;
    left: -300px;
    top: 0;
    height: 100vh;
    z-index: 1000;
    transition: left 0.3s ease;
    box-shadow: var(--shadow-lg);
  }
  
  .sidebar.active {
    left: 0;
  }
  
  .mobile-menu-toggle {
    display: block;
  }
  
  .main-content {
    max-width: 100%;
    padding: 1.5rem;
  }
  
  .filter-bar-modern {
    flex-direction: column;
    align-items: stretch;
    border-radius: 24px;
    padding: 1rem;
  }
  
  .filter-dropdowns {
    flex-direction: column;
  }
  
  .filter-select {
    width: 100%;
  }
  
  .categories-grid-modern,
  .posts-grid-modern {
    grid-template-columns: 1fr;
  }
  
  .page-title {
    font-size: 2rem;
  }
  
  .tag-cloud {
    padding: 1rem;
  }
}

/* Search Page Styles */
.search-section {
  margin-top: 2rem;
}

.search-container {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
}

.search-input {
  flex: 1;
  padding: 1rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 1rem;
  transition: all 0.3s ease;
}

.search-input:focus {
  outline: none;
  border-color: var(--accent-blue);
  box-shadow: 0 0 0 2px var(--accent-blue);
}

.search-button {
  padding: 1rem 2rem;
  background: var(--accent-blue);
  color: white;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.search-button:hover {
  background: var(--accent-blue-light);
  transform: translateY(-1px);
}

.search-filters {
  margin-bottom: 2rem;
}

.search-filters h3 {
  margin-bottom: 1rem;
  color: var(--text-primary);
  font-size: 1.1rem;
}

.filter-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.filter-tag {
  padding: 0.5rem 1rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.filter-tag:hover {
  border-color: var(--accent-blue);
  color: var(--text-primary);
}

.filter-tag.active {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
}

.filter-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.filter-checkbox {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  color: var(--text-secondary);
  transition: color 0.3s ease;
}

.filter-checkbox:hover {
  color: var(--text-primary);
}

.filter-checkbox input[type="checkbox"] {
  appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid var(--border-color);
  border-radius: 6px;
  background: var(--bg-tertiary);
  position: relative;
  display: inline-block;
  transition: all 0.2s ease;
  box-shadow: inset 0 0 0 2px transparent;
}

.filter-checkbox input[type="checkbox"]:hover {
  border-color: var(--accent-blue);
}

.filter-checkbox input[type="checkbox"]:checked {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
}

.filter-checkbox input[type="checkbox"]:checked::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 6px;
  width: 4px;
  height: 8px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.search-results {
  min-height: 300px;
}

.search-placeholder {
  text-align: center;
  padding: 3rem;
  color: var(--text-muted);
}

.search-placeholder h3 {
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

.search-result-item {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1rem;
  transition: all 0.3s ease;
}

.search-result-item:hover {
  border-color: var(--accent-blue);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.search-result-title {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.search-result-title a {
  color: inherit;
  text-decoration: none;
}

.search-result-title a:hover {
  color: var(--accent-blue);
}

.search-result-meta {
  display: flex;
  gap: 1rem;
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.search-result-excerpt {
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 0.75rem;
}

.search-result-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.search-result-tag {
  padding: 0.25rem 0.75rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Map Page Styles */
.map-section {
  margin-top: 2rem;
}

.map-tree {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 2rem;
}

.map-tree ul {
  list-style: none;
  padding-left: 0;
  margin: 0;
  position: relative;
}

.map-tree li {
  position: relative;
  padding: 0.4rem 0 0.4rem 1.25rem;
  margin: 0;
}

.map-tree .tree-level-0 {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--accent-blue);
  margin-bottom: 1rem;
}

.map-tree .tree-level-1 {
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-left: 0;
  margin-bottom: 0.75rem;
}

.map-tree .tree-level-2 {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-left: 3rem;
  margin-bottom: 0.5rem;
}

.map-tree .tree-level-3 {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-left: 4.5rem;
  margin-bottom: 0.25rem;
}

.map-tree a {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s ease;
}

.map-tree a:hover {
  color: var(--accent-blue-light);
}

.map-tree .post-count {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-left: 0.5rem;
}

.map-tree li::before {
  content: '';
  position: absolute;
  left: 0.5rem;
  top: 0;
  bottom: -0.4rem;
  width: 1px;
  background: var(--border-color);
}

.map-tree li::after {
  content: '';
  position: absolute;
  left: 0.5rem;
  top: 1.1rem;
  width: 0.75rem;
  height: 1px;
  background: var(--border-color);
}

.map-tree ul > li:last-child::before {
  bottom: 1.1rem;
}

.post-card-modern,
.category-card-modern {
  animation: fadeIn 0.5s ease;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-blue);
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Modern Home Page Styles */
.hero-section {
  margin: 2.5rem 0 0 0;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
  text-align: center;
  position: relative;
  overflow: visible;
  box-shadow: none;
}

.hero-section::before {
  content: none;
}

.hero-content {
  position: relative;
  z-index: 2;
}

/* hero title removed on home */

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.6;
}

.hero-stats {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  justify-content: center;
  gap: 2rem;
  margin-top: 2rem;
  width: 100%;
  flex-wrap: wrap;
}

.hero-stats .stat-item {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  flex: 1 1 calc(50% - 1rem);
  max-width: calc(50% - 1rem);
  min-width: 0;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1rem 1.25rem;
  box-shadow: var(--shadow-sm);
}

.hero-stats .stat-item:nth-child(3) {
  flex-basis: 100%;
  margin-inline: auto;
  max-width: 100%;
}

.hero-stats .stat-item:hover {
  border-color: var(--accent-blue);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.stat-number {
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--accent-blue);
  margin-bottom: 0.25rem;
  font-family: monospace;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.section-header h2 {
  font-size: 1.8rem;
  font-weight: 600;
  color: var(--text-primary);
}

.view-all-link {
  color: var(--accent-blue);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
  padding: 0.5rem 1rem;
  border: 1px solid var(--accent-blue);
  border-radius: 8px;
  font-size: 0.9rem;
}

.view-all-link:hover {
  background: var(--accent-blue);
  color: white;
  transform: translateX(4px);
}

.posts-grid-modern {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

.post-card-modern {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.post-card-modern::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.post-card-modern:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent-blue);
}

.post-card-modern:hover::before {
  opacity: 1;
}

.post-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.post-card-date {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-family: monospace;
}

.post-card-category {
  padding: 0.25rem 0.75rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  font-size: 0.7rem;
  color: var(--accent-blue-light);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.post-card-title {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1rem;
  line-height: 1.4;
}

.post-card-excerpt {
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

.post-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.post-card-tag {
  padding: 0.25rem 0.5rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-size: 0.7rem;
  color: var(--text-muted);
  transition: all 0.3s ease;
}

.post-card-tag:hover {
  border-color: var(--accent-blue);
  color: var(--accent-blue-light);
}

.post-card-link {
  color: var(--accent-blue);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.post-card-link:hover {
  color: var(--accent-blue-light);
}

.categories-grid-modern {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.category-card-modern {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  text-align: center;
  transition: all 0.3s ease;
  text-decoration: none;
  color: var(--text-primary);
}

.category-card-modern:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--accent-blue);
}

.category-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  display: block;
}

.category-name {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.category-count {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.tag-cloud-modern {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 3rem;
}

.tag-cloud-item {
  padding: 0.5rem 1rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.tag-cloud-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--gradient);
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 1;
}

.tag-cloud-item span {
  position: relative;
  z-index: 2;
}

.tag-cloud-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
  color: white;
  border-color: transparent;
}

.tag-cloud-item:hover::before {
  opacity: 1;
}

.featured-section,
.categories-preview,
.tags-cloud-section {
  margin-bottom: 4rem;
}

@media (max-width: 768px) {
  .hero-section {
    padding: 2rem 1rem;
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .hero-subtitle {
    font-size: 1rem;
  }
  
  .hero-stats {
    flex-direction: column;
    gap: 1.5rem;
    margin-inline-start: 0;
  }
  
  .hero-stats .stat-item {
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
    padding: 0.85rem 1rem;
    border-radius: 12px;
  }
  
  .stat-number {
    font-size: 1.9rem;
  }
  
  .posts-grid-modern {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .categories-grid-modern {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1rem;
  }
  
  .subcategories-grid-modern {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.75rem;
  }
  .subcategory-card-modern {
    padding: 0.75rem;
    aspect-ratio: auto;
    min-height: 110px;
  }
  
  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  
  .view-all-link {
    align-self: flex-end;
  }
  
  .contact-links {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }
  .contact-link {
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    justify-content: center;
  }
}
