:root {
  --hk-red: #e41426;
  --hk-red-dark: #a90f19;
  --hk-ink: #111827;
  --hk-muted: #64748b;
  --hk-line: #e5e7eb;
  --hk-soft: #f8fafc;
  --hk-card: #ffffff;
  --hk-max: 1180px;
  --hk-shadow: 0 14px 34px rgba(15, 23, 42, .10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; max-width: 100%; overflow-x: hidden; margin: 0; padding: 0; }
body {
  margin: 0 !important;
  padding-top: 0 !important;
  max-width: 100%;
  overflow-x: hidden;
  color: var(--hk-ink);
  background:
    radial-gradient(circle at 15% 0, rgba(228,20,38,.08), transparent 32rem),
    linear-gradient(180deg, #fff 0, #f8fafc 42rem);
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
input, textarea, select, button { max-width: 100%; }

.site-header { position: sticky; top: 0 !important; z-index: 1000; margin: 0 !important; box-shadow: 0 8px 24px rgba(15,23,42,.10); }
.site-header, .site-header * { line-height: normal; }
.topbar { background: var(--hk-red); color: #fff; }
.topbar-inner, .catbar-inner, .breaking-inner, .site-container {
  width: min(var(--hk-max), calc(100% - 32px));
  margin: 0 auto;
}
.topbar-inner {
  height: 48px;
  display: flex;
  align-items: center;
  gap: 18px;
}
.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #fff;
  font-weight: 900;
  letter-spacing: -.02em;
  white-space: nowrap;
}
.site-logo-mark {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #fff;
  border-radius: 8px;
  flex: 0 0 auto;
}
.site-logo-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.site-logo-text { font-size: 18px; }
.quicklinks { display: none; }
.quicklinks::-webkit-scrollbar, .catlinks::-webkit-scrollbar { display: none; }
.quicklinks a { color: #fff; font-weight: 800; font-size: 14px; white-space: nowrap; opacity: .95; }
.quicklinks a:hover { opacity: 1; text-decoration: underline; text-underline-offset: 4px; }
.top-actions { display: flex; align-items: center; justify-content: flex-end; gap: 12px; margin-left: auto; flex: 1; min-height: 48px; }
.site-search {
  position: relative;
  width: clamp(260px, 30vw, 360px);
  height: 48px;
  display: flex;
  align-items: center;
  align-self: center;
  margin-right: auto;
}
.site-search input {
  width: 100%;
  height: 34px;
  border: 0;
  border-radius: 999px;
  padding: 0 78px 0 14px;
  margin: 0;
  outline: none;
  display: block;
}
.site-search button {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  height: 26px;
  border: 0;
  border-radius: 999px;
  padding: 0 12px;
  background: var(--hk-red-dark);
  color: #fff;
  font-weight: 800;
  cursor: pointer;
  line-height: 26px;
}
.donate-btn {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 13px;
  border-radius: 999px;
  color: #7f1d1d;
  background: linear-gradient(135deg, #fff7ed, #ffffff);
  border: 1px solid rgba(255,255,255,.75);
  font-weight: 900;
  white-space: nowrap;
  box-shadow: 0 8px 18px rgba(127,29,29,.12);
}
.donate-btn:hover {
  transform: translateY(-1px);
  background: #fff;
}
.fal-icon img {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #fff;
  padding: 3px;
  box-shadow: 0 0 0 3px rgba(255,255,255,.28);
  cursor: pointer;
}
.tarot-mini {
  height: 34px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0 11px;
  background: #111827;
  color: #fff;
  font-weight: 900;
  box-shadow: 0 0 0 3px rgba(255,255,255,.18);
}
.auth-btn {
  background: #fff;
  color: var(--hk-red);
  border-radius: 999px;
  padding: 8px 14px;
  font-weight: 900;
  white-space: nowrap;
}
.catbar { background: #f3f4f6; border-bottom: 1px solid var(--hk-line); }
.catbar-inner { min-height: 48px; display: flex; align-items: center; gap: 12px; }
.allcats {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border: 1px solid #d1d5db;
  background: #fff;
  color: #1f2937;
  border-radius: 9px;
  padding: 8px 12px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}
.catlinks { display: flex; gap: 22px; overflow-x: auto; scrollbar-width: none; flex: 1; }
.catlinks a {
  color: #111827;
  font-weight: 800;
  font-size: 14px;
  white-space: nowrap;
  padding: 16px 0;
  position: relative;
}
.catlinks a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 3px;
  background: var(--hk-red);
  transition: width .2s ease;
}
.catlinks a:hover::after { width: 100%; }
.hamburger { display: none; border: 0; background: transparent; color: #fff; font-size: 26px; cursor: pointer; }
.theme-toggle {
  border: 1px solid rgba(255,255,255,.42);
  border-radius: 999px;
  background: rgba(255,255,255,.13);
  color: #fff;
  min-height: 34px;
  padding: 0 12px;
  font-weight: 900;
  cursor: pointer;
  white-space: nowrap;
}
.theme-toggle:hover { background: rgba(255,255,255,.22); transform: translateY(-1px); }

body.hk-dark {
  --hk-ink: #e5eefb;
  --hk-muted: #a7b4c8;
  --hk-line: rgba(148,163,184,.22);
  --hk-soft: #101827;
  --hk-card: #121c2d;
  background:
    radial-gradient(circle at 12% 0, rgba(228,20,38,.20), transparent 30rem),
    radial-gradient(circle at 80% 10%, rgba(14,165,233,.12), transparent 28rem),
    linear-gradient(180deg, #07111f 0, #0b1220 100%);
}
body.hk-dark .catbar,
body.hk-dark .info-strip { background: rgba(15,23,42,.92); border-color: rgba(148,163,184,.22); }
body.hk-dark .allcats,
body.hk-dark .info-chip,
body.hk-dark .mobile-menu,
body.hk-dark .fal-box,
body.hk-dark .home-chat-card,
body.hk-dark .hero-empty,
body.hk-dark .empty-state,
body.hk-dark .premium-empty { background: #121c2d; border-color: rgba(148,163,184,.22); color: #e5eefb; }
body.hk-dark .catlinks a,
body.hk-dark .mm-list a,
body.hk-dark .section-title { color: #f8fafc; }
body.hk-dark .mm-list a:hover { background: rgba(255,255,255,.07); }
body.hk-dark .site-footer { background: #070d18; }

.breaking { background: linear-gradient(90deg, #7f0d12, #b5121c); color: #fff; box-shadow: inset 0 -1px 0 rgba(255,255,255,.12); }
.breaking-inner { display: flex; min-height: 40px; align-items: center; overflow: hidden; position: relative; }
.breaking-label { flex:0 0 auto; align-self: stretch; display: flex; align-items: center; padding: 0 16px; margin-left: -16px; background: #5b0a0f; font-weight: 900; letter-spacing: .02em; position:relative; z-index:2; box-shadow: 18px 0 28px rgba(91,10,15,.96); }
.breaking-track { min-width:0; display: flex; gap: 28px; padding-left: 18px; white-space: nowrap; animation: hkTicker 30s linear infinite; will-change: transform; }
.breaking-track a { color: #fff; font-weight: 700; }
@keyframes hkTicker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.mobile-menu {
  position: fixed;
  inset: 0 auto 0 -330px;
  width: min(330px, 86vw);
  background: #fff;
  box-shadow: 18px 0 40px rgba(15,23,42,.22);
  transition: left .25s ease;
  z-index: 1200;
}
.mobile-menu.show { left: 0; }
.mm-head { display: flex; align-items: center; justify-content: space-between; padding: 18px; border-bottom: 1px solid var(--hk-line); font-weight: 900; }
.mm-close { border: 0; background: #fee2e2; color: var(--hk-red); border-radius: 10px; padding: 8px 10px; cursor: pointer; }
.mm-list { display: grid; gap: 4px; padding: 12px; }
.mm-list a { padding: 12px; border-radius: 12px; color: #111827; font-weight: 800; }
.mm-list a:hover { background: #f3f4f6; }

.fal-modal { position: fixed; inset: 0; background: rgba(15,23,42,.58); display: none; align-items: center; justify-content: center; z-index: 1300; padding: 18px; }
.fal-box { background: #fff; width: min(420px, 100%); border-radius: 22px; padding: 24px; box-shadow: var(--hk-shadow); text-align: center; }
.fal-box h2 { margin: 0 0 10px; }
.fal-text { color: var(--hk-muted); line-height: 1.55; }
.fal-close { margin-top: 18px; border: 0; background: var(--hk-red); color: #fff; border-radius: 999px; padding: 10px 16px; font-weight: 900; cursor: pointer; }

.info-strip { background: rgba(255,255,255,.86); border-bottom: 1px solid var(--hk-line); backdrop-filter: blur(10px); }
.info-strip-inner {
  width: min(var(--hk-max), calc(100% - 32px));
  margin: 0 auto;
  min-height: 46px;
  display: flex;
  gap: 10px;
  align-items: center;
  overflow-x: auto;
  scrollbar-width: none;
}
.info-strip-inner::-webkit-scrollbar { display: none; }
.info-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  padding: 8px 12px;
  background: #fff;
  border: 1px solid var(--hk-line);
  border-radius: 999px;
  color: #334155;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(15,23,42,.05);
}
.info-chip strong { color: var(--hk-red); }
.prayer-pop {
  display: none;
  position: fixed;
  left: min(var(--prayer-left, calc(100vw - 340px)), calc(100vw - 336px));
  top: var(--prayer-top, 142px);
  width: min(320px, calc(100vw - 32px));
  padding: 14px;
  border-radius: 18px;
  background: linear-gradient(135deg, #111827, #7f0d12);
  color: #fff;
  line-height: 1.45;
  z-index: 2000;
  box-shadow: 0 22px 52px rgba(15,23,42,.28);
}
.prayer-chip:hover .prayer-pop,
.prayer-chip.is-open .prayer-pop { display: block; }

.site-shell { width: min(var(--hk-max), calc(100% - 32px)); margin: 22px auto 40px; }
.search-shell { margin-top: 34px; }
.search-hero {
  width: min(820px, 100%);
  margin: 0 auto 26px;
  text-align: center;
}
.search-hero .section-title {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 0 18px;
}
.search-page-form {
  display: flex;
  gap: 10px;
  margin: 0 auto;
  width: min(760px, 100%);
}
.search-page-form input {
  flex: 1;
  padding: 14px 16px;
  border: 1px solid var(--hk-line);
  border-radius: 14px;
}
.search-page-form button {
  border: 0;
  background: var(--hk-red);
  color: #fff;
  border-radius: 14px;
  padding: 0 22px;
  font-weight: 900;
  cursor: pointer;
}
.hero-empty, .empty-state {
  background: #fff7f7;
  border: 1px solid #fecdd3;
  color: #7f1d1d;
  border-radius: 18px;
  padding: 24px;
}
.section-title { color: #0f172a; margin: 28px 4px 14px; font-size: 22px; font-weight: 900; }
.section-title::before { content: ""; display: inline-block; width: 6px; height: 22px; border-radius: 999px; background: var(--hk-red); margin-right: 9px; vertical-align: -4px; }
.premium-empty {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(240px, .8fr);
  gap: 18px;
  align-items: stretch;
  background:
    radial-gradient(circle at 20% 20%, rgba(228,20,38,.14), transparent 20rem),
    linear-gradient(135deg, #fff, #fff7f7);
  border: 1px solid #fecdd3;
  border-radius: 26px;
  padding: clamp(22px, 4vw, 38px);
  box-shadow: var(--hk-shadow);
}
.premium-empty h1, .premium-empty h2 { margin: 0 0 10px; font-size: clamp(2rem, 5vw, 4rem); line-height: .95; letter-spacing: -.05em; }
.premium-empty p { margin: 0; color: var(--hk-muted); line-height: 1.6; max-width: 620px; }
.premium-empty-panel {
  min-height: 220px;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(0,0,0,0), rgba(0,0,0,.48)),
    linear-gradient(135deg, #e41426, #7f0d12);
  color: #fff;
  padding: 18px;
  display: flex;
  align-items: end;
  font-weight: 900;
}

.news-card, .kutu, .side-item, .hx-card {
  background: var(--hk-card);
  border: 1px solid var(--hk-line);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(15,23,42,.07);
  transition: transform .18s ease, box-shadow .18s ease;
}

.site-footer {
  margin-top: 48px;
  background: #111827;
  color: #e5e7eb;
  border-top: 4px solid var(--hk-red);
}
.site-footer-inner {
  width: min(var(--hk-max), calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 28px;
  padding: 38px 0;
}
.footer-logo { color: #fff; }
.footer-brand p { color: #cbd5e1; line-height: 1.65; max-width: 420px; }
.footer-col { display: grid; align-content: start; gap: 9px; }
.footer-col h3 { color: #fff; margin: 0 0 6px; font-size: 1rem; }
.footer-col a { color: #cbd5e1; }
.footer-col a:hover { color: #fff; }
.newsletter-form {
  display: grid;
  gap: 8px;
  margin-top: 12px;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 16px;
  background: rgba(255,255,255,.06);
}
.newsletter-form input {
  border: 0;
  border-radius: 12px;
  padding: 10px 11px;
}
.newsletter-form button {
  border: 0;
  border-radius: 12px;
  padding: 10px 12px;
  background: var(--hk-red);
  color: #fff;
  font-weight: 900;
  cursor: pointer;
}
.newsletter-form small { color: rgba(255,255,255,.78); min-height: 16px; }
.footer-bottom {
  width: min(var(--hk-max), calc(100% - 32px));
  margin: 0 auto;
  border-top: 1px solid rgba(255,255,255,.10);
  padding: 16px 0;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: #94a3b8;
  font-size: .9rem;
}
.news-card:hover, .kutu:hover, .side-item:hover, .hx-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--hk-shadow);
}

.home-chat-teaser {
  margin: 18px 0 8px;
  width: min(480px, 100%);
}
.home-chat-card {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  padding: clamp(14px, 2vw, 18px);
  border: 1px solid rgba(228,20,38,.16);
  border-radius: 28px;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 10% 10%, rgba(255,255,255,.20), transparent 20rem),
    linear-gradient(135deg, #111827, #7f0d12 58%, #e41426);
  box-shadow: 0 22px 54px rgba(15,23,42,.18);
  transition: transform .2s ease, filter .2s ease, box-shadow .2s ease;
  min-height: 0;
  align-items: stretch;
}
.home-chat-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0);
  transition: background .2s ease;
  pointer-events: none;
}
.home-chat-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 28px 70px rgba(15,23,42,.24);
}
.home-chat-card:hover::after {
  background: rgba(0,0,0,.12);
}
.home-chat-copy,
.home-chat-list {
  position: relative;
  z-index: 1;
}
.home-chat-eyebrow {
  display: inline-flex;
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 999px;
  padding: 7px 10px;
  background: rgba(255,255,255,.12);
  font-weight: 900;
}
.home-chat-copy h2 {
  margin: 10px 0 6px;
  font-size: clamp(1.08rem, 1.7vw, 1.45rem);
  line-height: .96;
  letter-spacing: -.05em;
}
.home-chat-copy p {
  margin: 0 0 10px;
  color: rgba(255,255,255,.78);
  line-height: 1.55;
}
.home-chat-copy strong {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  background: #fff;
  color: var(--hk-red);
}
.home-chat-list {
  display: grid;
  gap: 7px;
  align-content: center;
}
.home-chat-msg {
  padding: 7px 10px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 13px;
  background: rgba(255,255,255,.10);
  backdrop-filter: blur(8px);
}
.home-chat-msg span {
  display: block;
  color: rgba(255,255,255,.72);
  font-size: .82rem;
  font-weight: 900;
}
.home-chat-msg p {
  margin: 4px 0 0;
  line-height: 1.35;
  font-weight: 750;
  font-size: .92rem;
}
.home-chat-msg.is-admin {
  background: rgba(255,255,255,.18);
  box-shadow: 0 0 0 1px rgba(255,255,255,.18), 0 0 22px rgba(255,255,255,.08);
}

@media (max-width: 980px) {
  .quicklinks, .site-search, .auth-btn, .donate-btn, .tarot-mini, .theme-toggle { display: none; }
  .hamburger { display: block; }
}
@media (max-width: 1120px) {
  .quicklinks { display: none; }
  .site-search { width: min(300px, 42vw); margin-left: auto; }
  .donate-btn { padding-inline: 10px; font-size: .86rem; }
}
@media (max-width: 800px) {
  .topbar-inner { gap: 10px; }
  .catbar-inner { align-items: stretch; padding-block: 8px; }
  .catlinks {
    display: none;
  }
  .allcats {
    width: 100%;
    justify-content: center;
  }
  .info-strip-inner {
    width: min(100% - 20px, var(--hk-max));
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 10px 0;
    overflow: visible;
  }
  .info-chip {
    width: 100%;
    justify-content: space-between;
    border-radius: 14px;
  }
  .prayer-pop {
    position: fixed;
    left: 10px;
    right: 10px;
    top: var(--prayer-top, 178px);
    bottom: auto;
    width: auto;
  }
}
@media (max-width: 640px) {
  .topbar-inner, .catbar-inner, .breaking-inner, .site-shell {
    width: min(100% - 20px, var(--hk-max));
  }
  .site-logo-text { font-size: 16px; }
  .catlinks { gap: 16px; }
  .breaking-label { margin-left: -10px; }
  .premium-empty { grid-template-columns: 1fr; }
  .home-chat-card { grid-template-columns: 1fr; }
  .site-footer-inner { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; }
  .search-page-form { flex-direction: column; }
  .search-page-form button { min-height: 44px; }
}
@media (max-width: 460px) {
  .site-logo-text { font-size: 14px; }
  .site-logo-mark { width: 30px; height: 30px; font-size: 17px; }
  .fal-icon img { width: 30px; height: 30px; }
  .info-strip-inner { grid-template-columns: 1fr; }
}

@media (max-width: 360px) {
  .topbar-inner, .catbar-inner, .breaking-inner, .site-shell {
    width: min(100% - 12px, var(--hk-max));
  }
  .topbar-inner { min-height: 44px; gap: 6px; }
  .top-actions { gap: 6px; margin-left: auto; }
  .site-logo-text { display: none; }
  .site-logo-mark { width: 28px; height: 28px; font-size: 16px; }
  .fal-icon img { width: 28px; height: 28px; }
  .hamburger { font-size: 22px; padding: 0; }
  .breaking-label { padding: 0 10px; font-size: .78rem; }
  .breaking-track { gap: 18px; padding-left: 10px; }
}

@media (max-width: 180px) {
  .fal-icon { display: none; }
  .topbar-inner, .catbar-inner, .breaking-inner, .info-strip-inner, .site-shell {
    width: calc(100% - 8px);
  }
  .allcats { padding: 7px 8px; font-size: .78rem; }
  .breaking-label { font-size: .68rem; }
}
