
:root {
  --primary: #1a1a2e;
  --accent:  #e94560;
  --bg:      #f8f8f8;
  --card-bg: #ffffff;
  --text:    #333333;
  --text-sm: #666666;
  --border:  #e0e0e0;
  --radius:  8px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Noto Sans JP", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }

/* ===== HEADER ===== */
.site-header {
  background: var(--primary);
  color: #fff;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
.site-header .logo {
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.05em;
}
.site-header .logo span { color: var(--accent); }
.site-header nav a {
  color: #ccc;
  font-size: 0.85rem;
  margin-left: 20px;
}
.site-header nav a:hover { color: #fff; }

/* ===== HERO ===== */
.hero {
  background: linear-gradient(135deg, var(--primary) 0%, #16213e 50%, #0f3460 100%);
  color: #fff;
  padding: 80px 24px;
  text-align: center;
}
.hero h1 { font-size: clamp(1.8rem, 5vw, 2.8rem); font-weight: 700; margin-bottom: 16px; }
.hero h1 span { color: var(--accent); }
.hero p { font-size: 1.05rem; color: #aaa; max-width: 600px; margin: 0 auto 32px; }
.hero-stats { display: flex; justify-content: center; gap: 40px; margin-top: 32px; }
.hero-stats .stat { text-align: center; }
.hero-stats .stat .num { font-size: 2.2rem; font-weight: 700; color: var(--accent); }
.hero-stats .stat .label { font-size: 0.8rem; color: #aaa; }

/* ===== MAIN LAYOUT ===== */
.container { max-width: 1100px; margin: 0 auto; padding: 0 24px; }

/* ===== PREFECTURE GRID (index) ===== */
.section { margin: 48px 0; }
.section-title {
  font-size: 1.2rem;
  font-weight: 700;
  padding: 12px 16px;
  border-left: 4px solid var(--accent);
  margin-bottom: 20px;
  background: #fff;
  border-radius: 0 var(--radius) var(--radius) 0;
}
.pref-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}
.pref-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  transition: box-shadow 0.2s, transform 0.2s;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.pref-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
  transform: translateY(-2px);
}
.pref-card .pref-name { font-weight: 600; font-size: 1rem; }
.pref-card .pref-count { font-size: 0.8rem; color: var(--accent); font-weight: 600; }
.pref-card.coming-soon { opacity: 0.45; cursor: default; }

/* ===== ARTICLE PAGE ===== */
.article-header {
  background: linear-gradient(135deg, var(--primary) 0%, #16213e 60%, #0f3460 100%);
  color: #fff;
  padding: 56px 24px 44px;
  text-align: center;
}
.article-header .pref-label {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 4px 14px;
  border-radius: 20px;
  margin-bottom: 16px;
}
.article-header h1 { font-size: clamp(1.3rem, 4vw, 2rem); font-weight: 700; line-height: 1.4; }
.article-header p { color: #aaa; margin-top: 12px; font-size: 0.95rem; }

.article-body { padding: 40px 0; }
.company-count {
  display: flex;
  align-items: baseline;
  gap: 6px;
  color: var(--text-sm);
  font-size: 0.88rem;
  margin-bottom: 28px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}
.company-count strong { color: var(--accent); font-size: 1.3rem; font-weight: 700; }

/* ===== COMPANY SCREENSHOT ===== */
.company-screenshot {
  margin: -18px -20px 14px;
  border-radius: calc(var(--radius) - 1px) calc(var(--radius) - 1px) 0 0;
  overflow: hidden;
  aspect-ratio: 16 / 8;
  background: #f0f0f0;
}
.company-screenshot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
  transition: transform 0.3s;
}
.company-card:hover .company-screenshot img {
  transform: scale(1.03);
}

/* ===== COMPANY CARDS ===== */
.company-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}
.company-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 18px 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
  transition: box-shadow 0.2s, transform 0.2s;
}
.company-card:hover {
  box-shadow: 0 6px 22px rgba(0,0,0,0.1);
  transform: translateY(-3px);
}
.company-num {
  position: absolute;
  top: 14px;
  right: 14px;
  font-size: 0.7rem;
  font-weight: 700;
  color: #ccc;
  line-height: 1;
  min-width: auto;
  padding: 0;
}
.company-info { flex: 1; }
.company-name {
  font-size: 0.98rem;
  font-weight: 700;
  margin-bottom: 10px;
  padding-right: 36px;
  line-height: 1.45;
  color: var(--primary);
}
.company-url { margin-bottom: 10px; }
.company-url a {
  display: inline-block;
  font-size: 0.74rem;
  color: var(--accent);
  background: rgba(233, 69, 96, 0.07);
  border: 1px solid rgba(233, 69, 96, 0.22);
  padding: 3px 10px;
  border-radius: 20px;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: middle;
}
.company-url a:hover {
  background: rgba(233, 69, 96, 0.15);
  text-decoration: none;
}
.company-desc {
  font-size: 0.8rem;
  color: var(--text-sm);
  line-height: 1.65;
}

/* ===== BREADCRUMB ===== */
.breadcrumb {
  background: #fff;
  padding: 0;
  font-size: 0.83rem;
  color: var(--text-sm);
  border-bottom: 1px solid var(--border);
}
.breadcrumb .container {
  padding-top: 10px;
  padding-bottom: 10px;
}
.breadcrumb a { color: var(--text-sm); }
.breadcrumb a:hover { color: var(--accent); text-decoration: underline; }
.breadcrumb .sep { margin: 0 8px; color: #ccc; }

/* ===== FOOTER ===== */
.site-footer {
  background: var(--primary);
  color: #888;
  text-align: center;
  padding: 40px 24px;
  margin-top: 80px;
  font-size: 0.85rem;
}
.site-footer strong { color: #fff; }

/* ===== RESPONSIVE ===== */
@media (max-width: 700px) {
  .hero { padding: 48px 16px; }
  .hero-stats { gap: 24px; }
  .article-body { padding: 28px 0; }
  .company-list {
    grid-template-columns: 1fr;
  }
  .article-header { padding: 40px 20px 32px; }
}

@media (max-width: 480px) {
  .company-card { padding: 16px; }
  .company-name { font-size: 0.92rem; }
}

/* ===== COMPANY DETAIL INFO ===== */
.company-detail { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; }
.info-row { display: flex; gap: 6px; font-size: 0.76rem; line-height: 1.6; }
.info-label { color: #888; white-space: nowrap; min-width: 62px; flex-shrink: 0; font-weight: 500; }
.info-val { color: #444; word-break: break-all; }
