/* ==========================================================================
   Van Khan Pages — Văn khấn cổ truyền
   Style riêng cho các trang trong /van-khan/
   ========================================================================== */

.vk-main {
  min-height: calc(100vh - 200px);
  padding: 24px 0 48px;
  background: #faf8f3;  /* warm paper tone for traditional feel */
}

.vk-container {
  max-width: 820px;
  margin: 0 auto;
  padding: 0 16px;
}

/* ===== Breadcrumb ===== */
.vk-breadcrumb {
  margin-bottom: 20px;
  font-size: 13px;
  color: #78716c;
}

.vk-breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.vk-breadcrumb li {
  display: flex;
  align-items: center;
}

.vk-breadcrumb li + li::before {
  content: '›';
  margin: 0 8px;
  color: #d6d3d1;
}

.vk-breadcrumb a {
  color: #57534e;
  text-decoration: none;
}

.vk-breadcrumb a:hover {
  color: #a16207;
  text-decoration: underline;
}

.vk-breadcrumb [aria-current="page"] {
  color: #1c1917;
  font-weight: 500;
}

/* ===== Article ===== */
.vk-article {
  background: #fffef9;
  border-radius: 12px;
  padding: 36px 40px;
  box-shadow: 0 1px 3px rgba(120, 53, 15, 0.06), 0 4px 16px rgba(120, 53, 15, 0.04);
  margin-bottom: 24px;
  border-top: 4px solid #b45309;
}

.vk-meta {
  margin-bottom: 12px;
}

.vk-category {
  display: inline-block;
  background: #fef3c7;
  color: #92400e;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.vk-title {
  font-size: 30px;
  line-height: 1.3;
  font-weight: 800;
  color: #1c1917;
  margin: 0 0 20px;
  letter-spacing: -0.02em;
  font-family: Georgia, 'Times New Roman', serif;
}

.vk-intro {
  font-size: 15px;
  line-height: 1.7;
  color: #57534e;
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px dashed #e7e5e4;
}

.vk-intro strong {
  color: #1c1917;
  font-weight: 600;
}

/* ===== Content (văn khấn text) ===== */
.vk-content {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 17px;
  line-height: 1.85;
  color: #292524;
  background: #fffbeb;
  padding: 28px 32px;
  border-radius: 8px;
  border-left: 4px solid #d97706;
  margin: 20px 0;
}

.vk-content p {
  margin: 0 0 14px;
  text-align: justify;
}

.vk-content p:last-child {
  margin-bottom: 0;
}

.vk-note {
  margin-top: 24px;
  padding: 16px 20px;
  background: #fef9c3;
  border-radius: 8px;
  font-size: 14px;
  line-height: 1.7;
  color: #713f12;
}

.vk-note strong {
  color: #422006;
}

/* ===== Prev/Next navigation ===== */
.vk-prev-next {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 24px 0;
}

.vk-nav-prev,
.vk-nav-next {
  display: flex;
  flex-direction: column;
  padding: 16px 20px;
  background: #fffef9;
  border-radius: 10px;
  text-decoration: none;
  border: 1px solid #fde68a;
  transition: all 0.15s;
}

.vk-nav-next {
  text-align: right;
}

.vk-nav-prev:hover,
.vk-nav-next:hover {
  background: #fef3c7;
  border-color: #f59e0b;
  transform: translateY(-2px);
}

.vk-nav-prev span,
.vk-nav-next span {
  font-size: 12px;
  color: #a16207;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.vk-nav-prev strong,
.vk-nav-next strong {
  font-size: 14px;
  color: #1c1917;
  font-weight: 600;
  line-height: 1.4;
}

.vk-nav-placeholder {
  display: block;
}

/* ===== Related ===== */
.vk-related {
  background: #fffef9;
  border-radius: 12px;
  padding: 24px 28px;
  box-shadow: 0 1px 3px rgba(120, 53, 15, 0.05);
  margin-bottom: 24px;
  border-left: 4px solid #d97706;
}

.vk-related h2 {
  font-size: 18px;
  font-weight: 700;
  color: #1c1917;
  margin: 0 0 14px;
}

.vk-related ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.vk-related li {
  margin-bottom: 8px;
}

.vk-related a {
  display: block;
  padding: 10px 14px;
  background: #fef3c7;
  border-radius: 8px;
  color: #92400e;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.15s;
}

.vk-related a:hover {
  background: #fde68a;
  color: #78350f;
  transform: translateX(4px);
}

.vk-related a::before {
  content: '→';
  margin-right: 8px;
  color: #d97706;
}

/* ===== Back link ===== */
.vk-back {
  text-align: center;
  padding: 16px 0;
}

.vk-back-link {
  display: inline-block;
  padding: 10px 20px;
  background: #fffef9;
  border: 1px solid #fde68a;
  border-radius: 999px;
  color: #78350f;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.15s;
}

.vk-back-link:hover {
  background: #fef3c7;
  border-color: #f59e0b;
}

/* ===== Index page ===== */
.vk-index-title {
  font-size: 36px;
  font-weight: 800;
  color: #1c1917;
  margin: 0 0 16px;
  letter-spacing: -0.02em;
  font-family: Georgia, 'Times New Roman', serif;
}

.vk-index-intro {
  font-size: 16px;
  line-height: 1.75;
  color: #57534e;
  max-width: 740px;
  margin: 0 0 32px;
}

.vk-index-intro strong {
  color: #1c1917;
  font-weight: 600;
}

.vk-group {
  background: #fffef9;
  border-radius: 12px;
  padding: 24px 28px;
  box-shadow: 0 1px 3px rgba(120, 53, 15, 0.05);
  margin-bottom: 20px;
}

.vk-group-title {
  font-size: 20px;
  font-weight: 700;
  color: #1c1917;
  margin: 0 0 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid #fef3c7;
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}

.vk-group-title a {
  color: #1c1917;
  text-decoration: none;
}

.vk-group-title a:hover {
  color: #a16207;
  text-decoration: underline;
}

.vk-count {
  font-size: 13px;
  font-weight: 500;
  color: #78716c;
  background: #fef3c7;
  padding: 2px 10px;
  border-radius: 999px;
}

.vk-group-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 8px;
}

.vk-group-list li {
  margin: 0;
}

.vk-group-list a {
  display: block;
  padding: 10px 14px;
  color: #92400e;
  text-decoration: none;
  border-radius: 6px;
  font-size: 14px;
  line-height: 1.4;
  transition: all 0.15s;
}

.vk-group-list a:hover {
  background: #fef3c7;
  color: #78350f;
}

.vk-group-list a::before {
  content: '🕉 ';
  opacity: 0.5;
  font-size: 12px;
}

/* ===== Category page ===== */
.vk-cat-title {
  font-size: 32px;
  font-weight: 800;
  color: #1c1917;
  margin: 0 0 12px;
  font-family: Georgia, 'Times New Roman', serif;
}

.vk-cat-intro {
  font-size: 15px;
  line-height: 1.7;
  color: #57534e;
  margin: 0 0 28px;
  max-width: 720px;
}

.vk-cat-list {
  list-style: none;
  padding: 0;
  margin: 0 0 32px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.vk-cat-list .vk-item {
  background: #fffef9;
  border-radius: 10px;
  border: 1px solid #fde68a;
  transition: all 0.15s;
}

.vk-cat-list .vk-item:hover {
  border-color: #f59e0b;
  transform: translateX(4px);
}

.vk-cat-list .vk-item a {
  display: block;
  padding: 14px 18px;
  text-decoration: none;
  color: #1c1917;
}

.vk-item-title {
  font-size: 15px;
  font-weight: 500;
}

.vk-cat-list .vk-item a::before {
  content: '🕉 ';
  margin-right: 6px;
  opacity: 0.6;
}

/* ===== Other categories nav ===== */
.vk-other-cats {
  background: #fffef9;
  border-radius: 12px;
  padding: 20px 24px;
  border: 1px solid #fde68a;
}

.vk-other-cats h2 {
  font-size: 16px;
  font-weight: 700;
  color: #1c1917;
  margin: 0 0 12px;
}

.vk-other-cats-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.vk-other-cats-list a {
  display: inline-block;
  padding: 6px 12px;
  background: #fef3c7;
  border-radius: 999px;
  color: #92400e;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.15s;
}

.vk-other-cats-list a:hover {
  background: #fde68a;
  color: #78350f;
}

/* ===== Responsive ===== */
@media (max-width: 640px) {
  .vk-main { padding: 16px 0 32px; }
  .vk-container { padding: 0 12px; }
  .vk-article { padding: 20px 22px; }
  .vk-title { font-size: 22px; }
  .vk-content {
    font-size: 15px;
    padding: 18px 20px;
  }
  .vk-index-title { font-size: 26px; }
  .vk-cat-title { font-size: 24px; }
  .vk-prev-next { grid-template-columns: 1fr; }
  .vk-group-list { grid-template-columns: 1fr; }
}

/* ===== Dark mode ===== */
body.theme-dark .vk-main { background: #1c1917; }
body.theme-dark .vk-article,
body.theme-dark .vk-related,
body.theme-dark .vk-group,
body.theme-dark .vk-other-cats,
body.theme-dark .vk-cat-list .vk-item {
  background: #292524;
  border-color: #44403c;
}
body.theme-dark .vk-title,
body.theme-dark .vk-index-title,
body.theme-dark .vk-cat-title,
body.theme-dark .vk-group-title,
body.theme-dark .vk-group-title a,
body.theme-dark .vk-related h2 {
  color: #fafaf9;
}
body.theme-dark .vk-content {
  background: #1f1b12;
  color: #fafaf9;
  border-left-color: #b45309;
}
body.theme-dark .vk-intro,
body.theme-dark .vk-index-intro,
body.theme-dark .vk-cat-intro {
  color: #d6d3d1;
}
body.theme-dark .vk-note {
  background: #422006;
  color: #fef3c7;
}
body.theme-dark .vk-related a,
body.theme-dark .vk-group-list a,
body.theme-dark .vk-other-cats-list a {
  background: #422006;
  color: #fef3c7;
}
body.theme-dark .vk-nav-prev,
body.theme-dark .vk-nav-next {
  background: #292524;
  border-color: #44403c;
}
body.theme-dark .vk-nav-prev strong,
body.theme-dark .vk-nav-next strong {
  color: #fafaf9;
}
