/* TNKE カテゴリーページ(脆弱性情報/お知らせ/技術情報)共通フィードデザイン */

.tnke-feed {
  --bg: #F5F7FB;
  --surface: #FFFFFF;
  --ink: #182236;
  --ink-muted: #59647A;
  --border: #DEE4EF;
  --brand: #2872FA;
  --brand-ink: #1559ED;
  --hero-bg: #142752;
  --hero-ink: #EDF1FA;
  --hero-muted: #9AACD1;
  --shadow: 0 16px 32px -20px rgba(24, 34, 54, 0.22);
  --radius: 10px;
  background: var(--bg);
  display: block;
}

:root[data-theme="dark"] .tnke-feed {
  --bg: #0A0E19;
  --surface: #131B2C;
  --ink: #E8EDF7;
  --ink-muted: #8894AD;
  --border: #223050;
  --brand: #6FA0FF;
  --brand-ink: #8FB4FF;
  --hero-bg: #112142;
  --hero-ink: #EDF1FA;
  --hero-muted: #8095C0;
  --shadow: 0 16px 32px -18px rgba(0, 0, 0, 0.55);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .tnke-feed {
    --bg: #0A0E19;
    --surface: #131B2C;
    --ink: #E8EDF7;
    --ink-muted: #8894AD;
    --border: #223050;
    --brand: #6FA0FF;
    --brand-ink: #8FB4FF;
    --hero-bg: #112142;
    --hero-ink: #EDF1FA;
    --hero-muted: #8095C0;
    --shadow: 0 16px 32px -18px rgba(0, 0, 0, 0.55);
  }
}

/* カテゴリーごとのアクセントカラー */
.tnke-feed.cat-vuln     { --accent: #B23A2E; --accent-soft: #FBEAE8; }
.tnke-feed.cat-announce { --accent: #2872FA; --accent-soft: #E9F0FE; }
.tnke-feed.cat-tech     { --accent: #1B7F79; --accent-soft: #E3F3F1; }

:root[data-theme="dark"] .tnke-feed.cat-vuln     { --accent: #E2685A; --accent-soft: rgba(226,104,90,0.16); }
:root[data-theme="dark"] .tnke-feed.cat-announce { --accent: #6FA0FF; --accent-soft: rgba(111,160,255,0.16); }
:root[data-theme="dark"] .tnke-feed.cat-tech     { --accent: #4FD1C5; --accent-soft: rgba(79,209,197,0.16); }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .tnke-feed.cat-vuln     { --accent: #E2685A; --accent-soft: rgba(226,104,90,0.16); }
  :root:not([data-theme="light"]) .tnke-feed.cat-announce { --accent: #6FA0FF; --accent-soft: rgba(111,160,255,0.16); }
  :root:not([data-theme="light"]) .tnke-feed.cat-tech     { --accent: #4FD1C5; --accent-soft: rgba(79,209,197,0.16); }
}

.tnke-feed .tnke-mono {
  font-family: ui-monospace, "SF Mono", "Cascadia Code", Consolas, "Courier New", monospace;
  font-variant-numeric: tabular-nums;
}

.tnke-feed a { color: var(--brand); text-decoration: none; }
.tnke-feed a:hover { color: var(--brand-ink); }
.tnke-feed a:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 4px; }

/* ---------- hero ---------- */
.tnke-feed .tnke-hero {
  background: var(--hero-bg);
  color: var(--hero-ink);
  padding: 46px 24px 36px;
  position: relative;
  overflow: hidden;
}
.tnke-feed .tnke-hero::after {
  content: "";
  position: absolute;
  inset: auto -10% -60% auto;
  width: 520px;
  height: 520px;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 20%, transparent), transparent 70%);
  pointer-events: none;
}
.tnke-feed .tnke-hero-inner {
  max-width: 1180px;
  margin: 0 auto;
  position: relative;
}
.tnke-feed .tnke-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--hero-muted);
  margin: 0 0 18px;
}
.tnke-feed .tnke-eyebrow .tnke-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.tnke-feed h1.tnke-hero-title {
  font-family: Georgia, "Hiragino Mincho ProN", serif;
  font-weight: 400;
  font-size: clamp(32px, 4.4vw, 46px);
  line-height: 1.25;
  margin: 0 0 10px;
  text-wrap: balance;
  max-width: 16ch;
}
.tnke-feed .tnke-hero-desc {
  font-size: 15.5px;
  line-height: 1.8;
  color: var(--hero-muted);
  max-width: 56ch;
  margin: 0 0 22px;
}
.tnke-feed .tnke-hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-top: 14px;
}
.tnke-feed .tnke-stat {
  padding: 0 28px;
  border-right: 1px solid rgba(255,255,255,0.12);
}
.tnke-feed .tnke-stat:first-child { padding-left: 0; }
.tnke-feed .tnke-stat:last-child { border-right: none; }
.tnke-feed .tnke-stat-num {
  font-size: 26px;
  font-weight: 600;
  color: var(--hero-ink);
  display: block;
  line-height: 1.1;
}
.tnke-feed .tnke-stat-label {
  font-size: 12px;
  color: var(--hero-muted);
  letter-spacing: 0.04em;
  margin-top: 4px;
  display: block;
}

/* ---------- content ---------- */
.tnke-feed .tnke-content {
  max-width: 1180px;
  margin: 0 auto;
  padding: 44px 24px 80px;
}

.tnke-feed .tnke-toolbar {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}
.tnke-feed .tnke-toolbar h2 {
  font-size: 15px;
  font-weight: 600;
  margin: 0;
  color: var(--ink-muted);
  letter-spacing: 0.02em;
}

.tnke-feed .tnke-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

.tnke-feed .tnke-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 22px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  box-shadow: var(--shadow);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.tnke-feed .tnke-card::before {
  content: "";
  position: absolute;
  top: 0; left: 22px; right: 22px;
  height: 2px;
  background: var(--accent);
  border-radius: 0 0 2px 2px;
  opacity: 0.85;
}
.tnke-feed .tnke-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 22px 40px -18px rgba(24, 34, 54, 0.28);
  border-color: color-mix(in srgb, var(--accent) 35%, var(--border));
}
@media (prefers-reduced-motion: reduce) {
  .tnke-feed .tnke-card { transition: none; }
  .tnke-feed .tnke-card:hover { transform: none; }
}

.tnke-feed .tnke-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.tnke-feed .tnke-card-head.tnke-solo { justify-content: flex-end; }
.tnke-feed .tnke-chip {
  font-size: 12px;
  padding: 3px 9px;
  border-radius: 5px;
  background: var(--accent-soft);
  color: var(--accent);
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.tnke-feed .tnke-card-date {
  font-size: 12.5px;
  color: var(--ink-muted);
}

.tnke-feed .tnke-card h3 {
  font-family: Georgia, "Hiragino Mincho ProN", serif;
  font-weight: 400;
  font-size: 18.5px;
  line-height: 1.5;
  margin: 0;
}
.tnke-feed .tnke-card h3 a { color: var(--ink); }
.tnke-feed .tnke-card h3 a:hover { color: var(--brand); }

.tnke-feed .tnke-excerpt {
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--ink-muted);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tnke-feed .tnke-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 4px;
}
.tnke-feed .tnke-card-foot.tnke-only-link { justify-content: flex-end; }
.tnke-feed .tnke-cve {
  font-size: 11.5px;
  color: var(--ink-muted);
}
.tnke-feed .tnke-more-link {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.tnke-feed .tnke-more-link::after { content: " →"; }

/* ---------- pagination(WP標準 the_posts_pagination のクラスにあわせる) ---------- */
.tnke-feed .tnke-pagination {
  display: flex;
  justify-content: center;
  margin-top: 46px;
}
.tnke-feed .tnke-pagination .nav-links {
  display: flex;
  gap: 6px;
}
.tnke-feed .tnke-pagination .page-numbers {
  min-width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  font-size: 13px;
  color: var(--ink-muted);
  border: 1px solid transparent;
  font-family: ui-monospace, "SF Mono", "Cascadia Code", Consolas, "Courier New", monospace;
}
.tnke-feed .tnke-pagination a.page-numbers:hover { border-color: var(--border); color: var(--ink); }
.tnke-feed .tnke-pagination .page-numbers.current {
  background: var(--brand);
  color: #fff;
}
.tnke-feed .tnke-pagination .page-numbers.dots { border: none; }

@media (max-width: 640px) {
  .tnke-feed .tnke-hero { padding: 34px 18px 26px; }
  .tnke-feed .tnke-content { padding: 32px 18px 60px; }
  .tnke-feed .tnke-stat { padding: 0 18px; }
}
