/*
Theme Name: Hikaku Pro
Theme URI: https://example.com/hikaku-pro
Author: Your Name
Author URI: https://example.com
Description: mybest風の比較メディア向けWordPressテーマ。ランキング・スペック比較表・星評価・絞り込み・アフィリボタン・FAQ構造化データに対応した汎用ジャンル向けテンプレート。
Version: 1.1.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: hikaku-pro
Tags: blog, magazine, comparison, ranking, affiliate, ecommerce
*/

/* ========================================================================
   Design Tokens
   ======================================================================== */
:root {
  /* Colors — 清潔感のあるブルー基調 + アクセントにコーラル */
  --hp-bg: #ffffff;
  --hp-bg-soft: #f6f8fb;
  --hp-bg-muted: #eef2f7;
  --hp-border: #e5e9f0;
  --hp-border-strong: #cfd6e0;
  --hp-text: #1f2937;
  --hp-text-muted: #6b7280;
  --hp-text-light: #9ca3af;
  --hp-primary: #2563eb;
  --hp-primary-dark: #1d4ed8;
  --hp-primary-soft: #dbeafe;
  --hp-accent: #ff6b5a;
  --hp-accent-dark: #e5523f;
  --hp-success: #10b981;
  --hp-warning: #f59e0b;
  --hp-danger: #ef4444;
  --hp-gold: #f5b100;
  --hp-silver: #b5b9c2;
  --hp-bronze: #c98851;

  /* Rakuten/Amazon/Yahooブランドカラー */
  --hp-rakuten: #bf0000;
  --hp-amazon: #ff9900;
  --hp-yahoo: #ff0033;

  /* Shadow */
  --hp-shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05);
  --hp-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
  --hp-shadow-lg: 0 12px 32px rgba(15, 23, 42, 0.12);

  /* Radius */
  --hp-radius-sm: 6px;
  --hp-radius: 10px;
  --hp-radius-lg: 16px;
  --hp-radius-full: 999px;

  /* Typography */
  --hp-font-sans: "Hiragino Sans", "Noto Sans JP", "Yu Gothic", "Meiryo", system-ui, -apple-system, sans-serif;
  --hp-font-display: "Noto Serif JP", "Yu Mincho", "Hiragino Mincho ProN", serif;

  /* Layout */
  --hp-container: 1200px;
  --hp-content: 780px;
  --hp-gap: 24px;
}

/* ========================================================================
   Reset & Base
   ======================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--hp-font-sans);
  font-size: 16px;
  line-height: 1.75;
  color: var(--hp-text);
  background: var(--hp-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--hp-primary); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--hp-primary-dark); text-decoration: underline; }
button { font-family: inherit; cursor: pointer; }
h1, h2, h3, h4, h5, h6 { line-height: 1.4; margin: 0 0 .6em; font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: 2rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1em; }
ul, ol { padding-left: 1.4em; }

/* ========================================================================
   Layout
   ======================================================================== */
.hp-container {
  max-width: var(--hp-container);
  margin: 0 auto;
  padding: 0 20px;
}

.hp-site-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 40px;
  padding: 40px 0 80px;
}
@media (max-width: 900px) {
  .hp-site-main { grid-template-columns: 1fr; gap: 32px; }
}

.hp-content-area { min-width: 0; }

/* ========================================================================
   Header
   ======================================================================== */
.hp-header {
  background: var(--hp-bg);
  border-bottom: 1px solid var(--hp-border);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: var(--hp-shadow-sm);
}
.hp-header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 68px;
}
.hp-logo {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--hp-text);
  letter-spacing: -0.02em;
  text-decoration: none !important;
  white-space: nowrap;
}
.hp-logo span { color: var(--hp-primary); }

.hp-nav { flex: 1; }
.hp-nav ul {
  display: flex;
  gap: 22px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.hp-nav a {
  color: var(--hp-text);
  font-weight: 500;
  font-size: .95rem;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
}
.hp-nav a:hover { color: var(--hp-primary); border-color: var(--hp-primary); text-decoration: none; }

.hp-header-search {
  position: relative;
  width: 260px;
}
.hp-header-search input {
  width: 100%;
  height: 40px;
  padding: 0 40px 0 14px;
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius-full);
  background: var(--hp-bg-soft);
  font-size: .9rem;
}
.hp-header-search input:focus {
  outline: none;
  border-color: var(--hp-primary);
  background: #fff;
}
.hp-header-search button {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border: none;
  background: transparent;
  color: var(--hp-text-muted);
  border-radius: 50%;
}

.hp-menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border: 1px solid var(--hp-border);
  background: #fff;
  border-radius: var(--hp-radius);
  color: var(--hp-text);
}

@media (max-width: 900px) {
  .hp-nav, .hp-header-search { display: none; }
  .hp-menu-toggle { display: inline-flex; align-items: center; justify-content: center; margin-left: auto; }
  .hp-nav.is-open { display: block; position: absolute; top: 68px; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--hp-border); padding: 16px 20px; }
  .hp-nav.is-open ul { flex-direction: column; gap: 8px; }
}

/* ========================================================================
   Hero (Front Page)
   ======================================================================== */
.hp-hero {
  background: linear-gradient(135deg, #eaf2ff 0%, #fff3ef 100%);
  padding: 64px 0 56px;
  border-bottom: 1px solid var(--hp-border);
}
.hp-hero-inner { text-align: center; max-width: 720px; margin: 0 auto; }
.hp-hero h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  margin-bottom: .4em;
  letter-spacing: -0.02em;
}
.hp-hero p {
  font-size: 1.05rem;
  color: var(--hp-text-muted);
  margin-bottom: 28px;
}
.hp-hero-search {
  display: flex;
  max-width: 560px;
  margin: 0 auto;
  background: #fff;
  border-radius: var(--hp-radius-full);
  box-shadow: var(--hp-shadow);
  overflow: hidden;
}
.hp-hero-search input {
  flex: 1;
  border: none;
  height: 56px;
  padding: 0 22px;
  font-size: 1rem;
  background: transparent;
}
.hp-hero-search input:focus { outline: none; }
.hp-hero-search button {
  border: none;
  padding: 0 28px;
  background: var(--hp-primary);
  color: #fff;
  font-weight: 600;
  font-size: .95rem;
}
.hp-hero-search button:hover { background: var(--hp-primary-dark); }

/* ========================================================================
   Sections / Headings
   ======================================================================== */
.hp-section { padding: 56px 0; }
.hp-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 16px;
}
.hp-section-title {
  font-size: 1.6rem;
  margin: 0;
  position: relative;
  padding-left: 16px;
}
.hp-section-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  bottom: 8px;
  width: 5px;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--hp-primary), var(--hp-accent));
}
.hp-section-more {
  font-size: .9rem;
  font-weight: 600;
  color: var(--hp-primary);
  white-space: nowrap;
}

/* ========================================================================
   Category Grid
   ======================================================================== */
.hp-category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}
.hp-category-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 22px 12px;
  background: var(--hp-bg-soft);
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius);
  text-align: center;
  color: var(--hp-text);
  text-decoration: none !important;
  transition: all .2s ease;
}
.hp-category-card:hover {
  background: #fff;
  border-color: var(--hp-primary);
  transform: translateY(-2px);
  box-shadow: var(--hp-shadow);
  color: var(--hp-primary);
}
.hp-category-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--hp-primary-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
  font-size: 1.3rem;
}
.hp-category-name { font-weight: 600; font-size: .95rem; }
.hp-category-count { font-size: .8rem; color: var(--hp-text-light); margin-top: 2px; }

/* ========================================================================
   Article Card (List)
   ======================================================================== */
.hp-article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}
.hp-card {
  background: #fff;
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all .2s ease;
}
.hp-card:hover { transform: translateY(-3px); box-shadow: var(--hp-shadow-lg); border-color: var(--hp-border-strong); }
.hp-card-thumb {
  aspect-ratio: 16 / 9;
  background: var(--hp-bg-muted);
  overflow: hidden;
  position: relative;
}
.hp-card-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.hp-card:hover .hp-card-thumb img { transform: scale(1.04); }
.hp-card-body { padding: 16px 18px 20px; flex: 1; display: flex; flex-direction: column; }
.hp-card-cat {
  display: inline-block;
  font-size: .72rem;
  font-weight: 700;
  color: var(--hp-primary);
  background: var(--hp-primary-soft);
  padding: 3px 10px;
  border-radius: var(--hp-radius-full);
  margin-bottom: 10px;
  align-self: flex-start;
}
.hp-card-title {
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.5;
  margin: 0 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.hp-card-title a { color: var(--hp-text); }
.hp-card-title a:hover { color: var(--hp-primary); text-decoration: none; }
.hp-card-meta {
  margin-top: auto;
  display: flex;
  gap: 12px;
  font-size: .8rem;
  color: var(--hp-text-light);
}

/* Featured card (large) */
.hp-featured {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 24px;
  background: #fff;
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius-lg);
  overflow: hidden;
  margin-bottom: 32px;
}
.hp-featured-thumb { aspect-ratio: 4 / 3; background: var(--hp-bg-muted); }
.hp-featured-thumb img { width: 100%; height: 100%; object-fit: cover; }
.hp-featured-body { padding: 32px; display: flex; flex-direction: column; justify-content: center; }
.hp-featured-body h3 { font-size: 1.5rem; line-height: 1.4; }
@media (max-width: 700px) {
  .hp-featured { grid-template-columns: 1fr; }
  .hp-featured-body { padding: 20px; }
}

/* ========================================================================
   Single Article
   ======================================================================== */
.hp-single { background: #fff; }
.hp-article-header { margin-bottom: 32px; }
.hp-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  font-size: .82rem;
  color: var(--hp-text-muted);
  margin-bottom: 14px;
  list-style: none;
  padding: 0;
}
.hp-breadcrumb li + li::before { content: "›"; margin-right: 6px; color: var(--hp-text-light); }
.hp-breadcrumb a { color: var(--hp-text-muted); }

.hp-article-cat {
  display: inline-block;
  font-size: .8rem;
  font-weight: 700;
  color: #fff;
  background: var(--hp-primary);
  padding: 4px 14px;
  border-radius: var(--hp-radius-full);
  margin-bottom: 12px;
}
.hp-article-title {
  font-size: clamp(1.6rem, 3.5vw, 2.25rem);
  margin-bottom: 16px;
  line-height: 1.35;
}
.hp-article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  font-size: .88rem;
  color: var(--hp-text-muted);
  padding-bottom: 18px;
  border-bottom: 1px solid var(--hp-border);
}
.hp-article-author { display: flex; align-items: center; gap: 8px; }
.hp-article-author img { width: 32px; height: 32px; border-radius: 50%; }

.hp-article-content {
  font-size: 1.02rem;
  line-height: 1.85;
}
.hp-article-content > * + * { margin-top: 1em; }
.hp-article-content h2 {
  font-size: 1.55rem;
  margin: 2em 0 .8em;
  padding: .4em 0 .4em 16px;
  border-left: 6px solid var(--hp-primary);
  background: linear-gradient(90deg, var(--hp-primary-soft), transparent);
}
.hp-article-content h3 {
  font-size: 1.25rem;
  margin: 1.8em 0 .6em;
  padding-bottom: .3em;
  border-bottom: 2px solid var(--hp-border);
}
.hp-article-content blockquote {
  border-left: 4px solid var(--hp-accent);
  background: var(--hp-bg-soft);
  padding: 16px 20px;
  margin: 1.4em 0;
  border-radius: 0 var(--hp-radius) var(--hp-radius) 0;
  color: var(--hp-text-muted);
}
.hp-article-content img { border-radius: var(--hp-radius); margin: 1em 0; }

/* Table of Contents */
.hp-toc {
  background: var(--hp-bg-soft);
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius);
  padding: 20px 24px;
  margin: 32px 0;
}
.hp-toc-title {
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.hp-toc-title::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 18px;
  background: var(--hp-primary);
  border-radius: 2px;
}
.hp-toc ol { list-style: none; padding: 0; margin: 0; counter-reset: toc; }
.hp-toc ol ol { padding-left: 20px; margin-top: 6px; }
.hp-toc li {
  counter-increment: toc;
  padding: 5px 0;
  font-size: .95rem;
}
.hp-toc li::before {
  content: counter(toc) ". ";
  color: var(--hp-primary);
  font-weight: 700;
  margin-right: 4px;
}
.hp-toc ol ol li::before { content: ""; }
.hp-toc a { color: var(--hp-text); }
.hp-toc a:hover { color: var(--hp-primary); }

/* ========================================================================
   Ranking Block (1位・2位...)
   ======================================================================== */
.hp-ranking { margin: 40px 0; }
.hp-rank-item {
  position: relative;
  background: #fff;
  border: 2px solid var(--hp-border);
  border-radius: var(--hp-radius-lg);
  padding: 28px 28px 24px;
  margin-bottom: 28px;
  transition: all .2s ease;
}
.hp-rank-item:hover { box-shadow: var(--hp-shadow-lg); }

.hp-rank-badge {
  position: absolute;
  top: -16px;
  left: 20px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 18px 6px 14px;
  border-radius: var(--hp-radius-full);
  color: #fff;
  font-weight: 800;
  font-size: .95rem;
  letter-spacing: 0.02em;
  box-shadow: var(--hp-shadow);
}
.hp-rank-badge .num { font-size: 1.3rem; font-family: var(--hp-font-display); }
.hp-rank-item[data-rank="1"] { border-color: var(--hp-gold); }
.hp-rank-item[data-rank="1"] .hp-rank-badge { background: linear-gradient(135deg, #f5b100, #d98e00); }
.hp-rank-item[data-rank="2"] { border-color: var(--hp-silver); }
.hp-rank-item[data-rank="2"] .hp-rank-badge { background: linear-gradient(135deg, #b5b9c2, #8b909c); }
.hp-rank-item[data-rank="3"] { border-color: var(--hp-bronze); }
.hp-rank-item[data-rank="3"] .hp-rank-badge { background: linear-gradient(135deg, #c98851, #a56a3a); }
.hp-rank-item:not([data-rank="1"]):not([data-rank="2"]):not([data-rank="3"]) .hp-rank-badge {
  background: linear-gradient(135deg, var(--hp-primary), var(--hp-primary-dark));
}

.hp-rank-head {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 24px;
  align-items: start;
  margin-top: 8px;
}
@media (max-width: 640px) {
  .hp-rank-head { grid-template-columns: 1fr; }
}
.hp-rank-thumb {
  aspect-ratio: 1 / 1;
  background: var(--hp-bg-soft);
  border-radius: var(--hp-radius);
  overflow: hidden;
  border: 1px solid var(--hp-border);
}
.hp-rank-thumb img { width: 100%; height: 100%; object-fit: contain; padding: 8px; }

.hp-rank-brand {
  font-size: .85rem;
  color: var(--hp-text-muted);
  margin-bottom: 4px;
}
.hp-rank-name {
  font-size: 1.3rem;
  font-weight: 700;
  margin: 0 0 12px;
  line-height: 1.4;
}
.hp-rank-name a { color: var(--hp-text); }

.hp-rank-score-overall {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  background: var(--hp-bg-soft);
  border-radius: var(--hp-radius);
  margin-bottom: 14px;
}
.hp-rank-score-num {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--hp-primary);
  font-family: var(--hp-font-display);
  line-height: 1;
}
.hp-rank-score-num small { font-size: 1rem; color: var(--hp-text-muted); font-weight: 400; }
.hp-rank-score-stars { flex: 1; }

.hp-rank-subscores {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px 20px;
  padding: 16px 0;
  border-top: 1px dashed var(--hp-border);
  border-bottom: 1px dashed var(--hp-border);
  margin: 14px 0;
}
.hp-subscore { display: flex; flex-direction: column; gap: 4px; }
.hp-subscore-label { font-size: .78rem; color: var(--hp-text-muted); font-weight: 500; }
.hp-subscore-bar {
  display: flex;
  align-items: center;
  gap: 8px;
}
.hp-subscore-track {
  flex: 1;
  height: 6px;
  background: var(--hp-bg-muted);
  border-radius: 3px;
  overflow: hidden;
}
.hp-subscore-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--hp-primary), var(--hp-accent));
  border-radius: 3px;
}
.hp-subscore-val { font-size: .82rem; font-weight: 700; color: var(--hp-text); min-width: 26px; text-align: right; }

.hp-rank-description { font-size: .95rem; color: var(--hp-text); margin: 10px 0 0; }

.hp-rank-pros-cons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin: 16px 0;
}
@media (max-width: 540px) { .hp-rank-pros-cons { grid-template-columns: 1fr; } }
.hp-pros, .hp-cons {
  padding: 14px 16px;
  border-radius: var(--hp-radius);
  font-size: .88rem;
}
.hp-pros { background: #ecfdf5; border: 1px solid #a7f3d0; }
.hp-cons { background: #fef2f2; border: 1px solid #fecaca; }
.hp-pros-title, .hp-cons-title { font-weight: 700; margin-bottom: 6px; display: flex; align-items: center; gap: 6px; }
.hp-pros-title { color: #047857; }
.hp-cons-title { color: #b91c1c; }
.hp-pros ul, .hp-cons ul { margin: 0; padding-left: 18px; }
.hp-pros li, .hp-cons li { margin-bottom: 4px; }

.hp-rank-spec-mini {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 1px;
  background: var(--hp-border);
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius);
  overflow: hidden;
  margin: 16px 0;
}
.hp-rank-spec-mini > div {
  background: #fff;
  padding: 10px 12px;
  font-size: .82rem;
}
.hp-rank-spec-mini .label { color: var(--hp-text-muted); font-size: .72rem; display: block; }
.hp-rank-spec-mini .value { font-weight: 600; color: var(--hp-text); }

/* ========================================================================
   Star Rating
   ======================================================================== */
.hp-stars {
  display: inline-flex;
  gap: 2px;
  position: relative;
  font-size: 1.05rem;
  line-height: 1;
}
.hp-stars-bg, .hp-stars-fg {
  display: inline-flex;
  gap: 2px;
}
.hp-stars-bg { color: #e5e9f0; }
.hp-stars-fg {
  color: var(--hp-gold);
  position: absolute;
  top: 0;
  left: 0;
  overflow: hidden;
  white-space: nowrap;
}

/* ========================================================================
   Affiliate Buttons
   ======================================================================== */
.hp-affiliate {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  margin: 16px 0 4px;
}
.hp-aff-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 48px;
  padding: 0 16px;
  border-radius: var(--hp-radius);
  color: #fff !important;
  font-weight: 700;
  font-size: .92rem;
  text-decoration: none !important;
  transition: transform .15s ease, filter .15s ease;
  box-shadow: var(--hp-shadow-sm);
  border: none;
}
.hp-aff-btn:hover { transform: translateY(-2px); filter: brightness(1.05); box-shadow: var(--hp-shadow); }
.hp-aff-btn .arrow { transition: transform .15s ease; }
.hp-aff-btn:hover .arrow { transform: translateX(3px); }
.hp-aff-rakuten { background: var(--hp-rakuten); }
.hp-aff-amazon  { background: var(--hp-amazon); color: #111 !important; }
.hp-aff-yahoo   { background: var(--hp-yahoo); }
.hp-aff-official { background: var(--hp-text); }
.hp-aff-price {
  font-size: .78rem;
  opacity: .9;
  font-weight: 500;
}

/* ========================================================================
   Spec Comparison Table
   ======================================================================== */
.hp-spec-wrap {
  margin: 40px 0;
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius-lg);
  overflow: hidden;
  background: #fff;
}
.hp-spec-wrap > .hp-spec-head {
  padding: 18px 24px;
  border-bottom: 1px solid var(--hp-border);
  background: var(--hp-bg-soft);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.hp-spec-head h3 { margin: 0; font-size: 1.1rem; }
.hp-spec-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.hp-spec-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: .9rem;
  min-width: 720px;
}
.hp-spec-table th,
.hp-spec-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--hp-border);
  text-align: left;
  vertical-align: top;
}
.hp-spec-table thead th {
  background: var(--hp-bg-soft);
  font-weight: 700;
  font-size: .85rem;
  color: var(--hp-text-muted);
  border-bottom: 2px solid var(--hp-border-strong);
  position: sticky;
  top: 0;
}
.hp-spec-table tbody th {
  width: 140px;
  background: #fafbfc;
  font-weight: 600;
  color: var(--hp-text-muted);
  font-size: .82rem;
  position: sticky;
  left: 0;
  border-right: 1px solid var(--hp-border);
  z-index: 1;
}
.hp-spec-table tbody tr:hover td { background: #fafbfc; }
.hp-spec-product {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-width: 140px;
}
.hp-spec-product img { width: 80px; height: 80px; object-fit: contain; }
.hp-spec-product-name { font-weight: 700; font-size: .92rem; text-align: center; }
.hp-spec-rank-label {
  display: inline-block;
  padding: 2px 10px;
  border-radius: var(--hp-radius-full);
  background: var(--hp-primary-soft);
  color: var(--hp-primary);
  font-size: .7rem;
  font-weight: 700;
}

/* ========================================================================
   Filter Bar
   ======================================================================== */
.hp-filter {
  background: #fff;
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius);
  padding: 18px 20px;
  margin-bottom: 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
}
.hp-filter-group {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .88rem;
}
.hp-filter-group label {
  font-weight: 600;
  color: var(--hp-text-muted);
}
.hp-filter select,
.hp-filter input[type="text"] {
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius-sm);
  padding: 8px 12px;
  font-size: .88rem;
  background: #fff;
  min-width: 120px;
}
.hp-filter select:focus, .hp-filter input:focus { outline: none; border-color: var(--hp-primary); }

.hp-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.hp-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  border-radius: var(--hp-radius-full);
  background: var(--hp-bg-soft);
  border: 1px solid var(--hp-border);
  font-size: .82rem;
  color: var(--hp-text);
  cursor: pointer;
  transition: all .15s ease;
}
.hp-chip:hover { border-color: var(--hp-primary); color: var(--hp-primary); }
.hp-chip.is-active { background: var(--hp-primary); color: #fff; border-color: var(--hp-primary); }

.hp-sort {
  margin-left: auto;
}

/* ========================================================================
   FAQ Block
   ======================================================================== */
.hp-faq {
  margin: 40px 0;
}
.hp-faq details {
  background: #fff;
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius);
  margin-bottom: 12px;
  overflow: hidden;
}
.hp-faq details[open] { box-shadow: var(--hp-shadow); border-color: var(--hp-primary); }
.hp-faq summary {
  list-style: none;
  padding: 18px 52px 18px 54px;
  font-weight: 700;
  cursor: pointer;
  position: relative;
  font-size: 1rem;
}
.hp-faq summary::-webkit-details-marker { display: none; }
.hp-faq summary::before {
  content: "Q";
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--hp-primary);
  color: #fff;
  font-family: var(--hp-font-display);
  font-size: .92rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hp-faq summary::after {
  content: "";
  position: absolute;
  right: 24px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--hp-text-muted);
  border-bottom: 2px solid var(--hp-text-muted);
  transform: translateY(-70%) rotate(45deg);
  transition: transform .2s ease;
}
.hp-faq details[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.hp-faq-answer {
  padding: 0 24px 20px 54px;
  color: var(--hp-text);
  font-size: .95rem;
  line-height: 1.8;
  position: relative;
}
.hp-faq-answer::before {
  content: "A";
  position: absolute;
  left: 18px;
  top: 2px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--hp-accent);
  color: #fff;
  font-family: var(--hp-font-display);
  font-size: .92rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ========================================================================
   Sidebar
   ======================================================================== */
.hp-sidebar .widget {
  background: #fff;
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius);
  padding: 20px;
  margin-bottom: 24px;
}
.hp-sidebar .widget-title {
  font-size: 1rem;
  margin: 0 0 14px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--hp-primary);
  display: inline-block;
}
.hp-sidebar ul { list-style: none; padding: 0; margin: 0; }
.hp-sidebar li { padding: 8px 0; border-bottom: 1px dashed var(--hp-border); font-size: .9rem; }
.hp-sidebar li:last-child { border-bottom: none; }
.hp-sidebar li a { color: var(--hp-text); }
.hp-sidebar li a:hover { color: var(--hp-primary); }

.hp-popular-list { counter-reset: pop; }
.hp-popular-list li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 10px 0;
}
.hp-popular-list li::before {
  counter-increment: pop;
  content: counter(pop);
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--hp-bg-muted);
  color: var(--hp-text-muted);
  font-weight: 700;
  font-size: .82rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hp-popular-list li:nth-child(-n+3)::before { background: var(--hp-primary); color: #fff; }
.hp-popular-list .thumb { flex: none; width: 64px; height: 48px; border-radius: 4px; overflow: hidden; background: var(--hp-bg-muted); }
.hp-popular-list .thumb img { width: 100%; height: 100%; object-fit: cover; }
.hp-popular-list .title { font-size: .85rem; line-height: 1.45; font-weight: 600; }

/* ========================================================================
   Pagination
   ======================================================================== */
.hp-pagination {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin: 40px 0 0;
  flex-wrap: wrap;
}
.hp-pagination a, .hp-pagination span {
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--hp-border);
  border-radius: var(--hp-radius-sm);
  color: var(--hp-text);
  font-weight: 600;
  font-size: .9rem;
  background: #fff;
}
.hp-pagination a:hover { border-color: var(--hp-primary); color: var(--hp-primary); text-decoration: none; }
.hp-pagination .current { background: var(--hp-primary); color: #fff; border-color: var(--hp-primary); }

/* ========================================================================
   Footer
   ======================================================================== */
.hp-footer {
  background: #1f2937;
  color: #cbd5e1;
  padding: 56px 0 24px;
  margin-top: 40px;
}
.hp-footer a { color: #cbd5e1; }
.hp-footer a:hover { color: #fff; }
.hp-footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 32px;
  margin-bottom: 40px;
}
@media (max-width: 800px) { .hp-footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 500px) { .hp-footer-grid { grid-template-columns: 1fr; } }
.hp-footer h4 { font-size: .92rem; color: #fff; margin: 0 0 14px; letter-spacing: 0.04em; }
.hp-footer ul { list-style: none; padding: 0; margin: 0; }
.hp-footer li { padding: 4px 0; font-size: .88rem; }
.hp-footer-brand p { font-size: .85rem; line-height: 1.7; color: #94a3b8; margin-top: 10px; }
.hp-footer-bottom {
  border-top: 1px solid #334155;
  padding-top: 20px;
  text-align: center;
  font-size: .82rem;
  color: #94a3b8;
}
.hp-footer-disclaimer {
  background: #0f172a;
  padding: 14px 20px;
  border-radius: var(--hp-radius);
  font-size: .78rem;
  margin-bottom: 24px;
  color: #94a3b8;
  line-height: 1.6;
}

/* ========================================================================
   Utilities
   ======================================================================== */
.hp-sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
.hp-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: var(--hp-radius);
  background: var(--hp-primary);
  color: #fff !important;
  font-weight: 600;
  font-size: .9rem;
  text-decoration: none !important;
  border: none;
  cursor: pointer;
}
.hp-btn:hover { background: var(--hp-primary-dark); }
.hp-btn-outline {
  background: transparent;
  color: var(--hp-primary) !important;
  border: 1.5px solid var(--hp-primary);
}
.hp-btn-outline:hover { background: var(--hp-primary); color: #fff !important; }
