/* Category Archive Styles */

/* Container & Header */
.category-header {
    max-width: 1200px;
    margin: 0 auto 2.5rem;
    text-align: center;
    padding: 0 1rem;
}

.category-header h1 {
    font-family: "Inter", sans-serif;
    font-weight: 700;
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: #111827;
}

.category-description {
    font-size: 1rem;
    color: #374151;
    line-height: 1.6;
    max-width: 800px;
    margin: 0.5rem auto 0;
}

.category-rich-content {
  font-size: 1rem;
  line-height: 1.6;
  color: #4b5563!important;
}
/* Grid of Posts */
.category-grid {         
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 1.75rem;
    max-width: 1200px;
    padding: 0 1rem;
    margin: 0 auto 3rem;
}

.post-card {
    text-align: center;
}

.post-card a {
    text-decoration: none;
    color: inherit;
}

.post-card__image img {
    width: 100%;
    height: auto;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease;
}

.post-card:hover .post-card__image img {
    transform: scale(1.04);
}

.post-card__title {
    margin-top: 0.65rem;
    font-size: 0.95rem;
    line-height: 1.3;
    color: #1f2937;
}

/* Show More Pagination Button */
.show-more-btn {
    text-align: center;
    margin-bottom: 4rem;
}

.show-more-btn a {
    display: inline-block;
    background: #3b82f6;
    color: #fff !important;
    padding: 0.75rem 1.75rem;
    border-radius: 6px;
    font-weight: 500;
    transition: background 0.2s ease;
}

.show-more-btn a:hover {
    background: #2563eb;
}

.category-post-card {
  font-family: 'Inter', Arial, sans-serif;
  font-size: 13px;
  color: #34495e;
  min-width: 180px;
  height: 220px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  background: #fff;
  border-radius: 14px;
  margin: 0 10px 24px 10px;
  padding: 0;
  overflow: hidden;
  box-shadow: none;
  transition: transform 0.18s;
}
.category-post-card:hover {
  box-shadow: none;
  transform: translateY(-2px) scale(1.02);
}
.category-post-title {
  font-size: 14px;
  color: #00bfae;
  font-weight: 400;
  margin-top: 10px;
  margin-bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
.category-post-title .dot {
  width: 8px;
  height: 8px;
  background: #2563eb;
  border-radius: 50%;
  display: inline-block;
  margin-right: 4px;
}
.coloring-page-stack {
  position: relative;
  width: 130px;
  height: 150px;
  margin: 0 auto 8px auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
.coloring-page-fake-back {
  position: absolute;
  left: 3px;
  top: 3px;
  width: 100%;
  height: 100%;
  border-radius: 10px;
  background: #fff;
  border: 1.5px solid #e5e7ef;
  z-index: 1;
  opacity: 1;
  box-shadow: 0 2px 8px rgba(44,62,80,0.06);
}
.coloring-page-thumb {
  position: relative;
  z-index: 2;
  border-radius: 10px;
  background: #fff;
  border: 1.5px solid #e5e7ef;
  box-shadow: 0 2px 8px rgba(44,62,80,0.08);
  object-fit: contain;
  width: 100%;
  height: 100%;
  padding: 10px;
  box-sizing: border-box;
}
.coloring-page-stack::before,
.coloring-page-stack::after {
  content: '';
  position: absolute;
  left: 10px;
  top: 10px;
  width: 100%;
  height: 100%;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 1px 6px rgba(0,0,0,0.04);
  z-index: 0;
}

.coloring-page-thumb.stack-img-1 {
  left: 8px;
  top: 8px;
  opacity: 0.7;
  z-index: 1;
}
.coloring-page-thumb.stack-img-2 {
  left: 16px;
  top: 16px;
  opacity: 0.5;
  z-index: 0;
}
.coloring-page-thumb.stack-img-0 {
  left: 0;
  top: 0;
  z-index: 2;
  opacity: 1;
}
.category-post-title a {
  color: #121737;
  text-decoration: none;
  font-weight: 400;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  display: inline-block;
}
.category-post-title a:hover {
  text-decoration: underline;
}

.category-posts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
  margin-top: 24px;
  margin-bottom: 24px;
}

@media (max-width: 900px) {
  .category-posts {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
}
@media (max-width: 600px) {
  .category-posts {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

/* Responsive Tweaks */
@media (min-width: 640px) {
    .category-header h1 {
        font-size: 2.25rem;
    }
}

@media (min-width: 1024px) {
    .category-header h1 {
        font-size: 2.5rem;
    }
}

.container.category-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 24px 40px 24px;
  background: #fff;
  border-radius: 18px;
  box-sizing: border-box;
}
.category-title {
  font-size: 2.1rem;
  font-weight: 700;
  color: #121737;
  margin-bottom: 12px;
  text-align: left;
}
.category-description, .category-rich-content {
  font-size: 1.08rem;
  color: #444;
  margin-bottom: 18px;
  line-height: 1.7;
  text-align: left;
}
.category-pagination {
  margin: 32px 0 0 0;
  text-align: center;
}
.category-pagination ul {
  display: inline-flex;
  gap: 8px;
  padding: 0;
  margin: 0;
  list-style: none;
}
.category-pagination li {
  display: inline-block;
}
.category-pagination a, .category-pagination span {
  display: inline-block;
  padding: 8px 18px;
  border-radius: 6px;
  background: #f5f7fa;
  color: #2563eb;
  font-weight: 500;
  font-size: 1rem;
  text-decoration: none;
  margin: 0 2px;
  transition: background 0.18s, color 0.18s;
}
.category-pagination .current, .category-pagination a:hover {
  background: #2563eb;
  color: #fff;
}

.category-load-more-btn {
  background: #2563eb;
  color: #fff;
  font-size: 1.08rem;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  padding: 12px 32px;
  margin: 0 auto;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(44,62,80,0.08);
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  display: inline-block;
}
.category-load-more-btn:hover, .category-load-more-btn:focus {
  background: #00bfae;
  color: #fff;
  box-shadow: 0 4px 16px rgba(0,191,174,0.13);
}

.category-show-more-btn {
  background: #f5f7fa;
  color: #2563eb;
  font-size: 1rem;
  font-weight: 500;
  border: none;
  border-radius: 6px;
  padding: 8px 18px;
  margin: 10px 0 0 0;
  cursor: pointer;
  transition: background 0.18s, color 0.18s;
  display: inline-block;
}
.category-show-more-btn:hover, .category-show-more-btn:focus {
  background: #2563eb;
  color: #fff;
}

.category-post-card .category-post-image-link {
  display: block;
  border-radius: 12px;
  overflow: hidden;
}
.category-post-card .category-post-image-link:focus {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}

.category-rich-content {
  position: relative;
  margin-bottom: 18px;
  font-size: 1.08rem;
  color: #444;
  line-height: 1.7;
  text-align: left;
}
.category-content-collapsed {
  max-height: 4.8em;
  overflow: hidden;
  position: relative;
  display: block;
  /* Fade-out effect */
}
.category-content-collapsed::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2.2em;
  background: linear-gradient(to bottom, rgba(255,255,255,0) 0%, #fff 90%);
  pointer-events: none;
}
.category-content-expanded {
  max-height: none;
  overflow: visible;
}
.category-show-more-link {
  display: inline;
  background: none;
  border: none;
  color: #2563eb;
  font-size: 1rem;
  font-weight: 500;
  text-decoration: underline;
  cursor: pointer;
  margin-left: 8px;
  padding: 0;
  transition: color 0.18s;
  position: relative;
}
.category-show-more-link:hover, .category-show-more-link:focus {
  color: #00bfae;
  text-decoration: underline;
}

/* Color Online Grid Custom Columns */
#color-online-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1.5rem;
  max-width: 1200px;
  margin: 0 auto 3rem auto;
  padding: 0 1rem;
}

@media (min-width: 1200px) {
  #color-online-grid {
    grid-template-columns: repeat(6, 1fr);
  }
}
@media (min-width: 900px) and (max-width: 1199px) {
  #color-online-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}
@media (max-width: 899px) {
  #color-online-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 600px) {
  #color-online-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
}
