/* ============================================
   ヨルシコ - Neon Cyberpunk Style CSS
   Full-width 4-col grid + horizontal filter bar
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'Noto Sans JP', 'Segoe UI', sans-serif;
  background-color: #0d1117;
  color: #c9d1d9;
  line-height: 1.6;
  overflow-x: hidden;
  background-image:
    repeating-linear-gradient(0deg, transparent, transparent 49px, rgba(0, 212, 255, 0.03) 49px, rgba(0, 212, 255, 0.03) 50px),
    repeating-linear-gradient(90deg, transparent, transparent 49px, rgba(0, 212, 255, 0.03) 49px, rgba(0, 212, 255, 0.03) 50px);
  background-size: 50px 50px;
}
a { color: #00d4ff; text-decoration: none; transition: color 0.3s; }
a:hover { color: #ff0080; }
img { max-width: 100%; display: block; }

/* --- Header --- */
.site-header {
  position: sticky; top: 0; z-index: 9000;
  background: rgba(13, 17, 23, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 2px solid transparent;
  border-image: linear-gradient(90deg, #00d4ff, #ff0080) 1;
}
.header-inner {
  display: flex; justify-content: space-between; align-items: center;
  max-width: 1400px; margin: 0 auto; padding: 14px 24px;
}
.site-logo {
  font-family: 'Orbitron', sans-serif;
  font-weight: 900; font-size: 24px;
  color: #00d4ff;
  text-shadow: 0 0 10px #00d4ff, 0 0 30px rgba(0, 212, 255, 0.4);
  letter-spacing: 2px;
}
.site-logo span {
  color: #ff0080;
  text-shadow: 0 0 10px #ff0080, 0 0 30px rgba(255, 0, 128, 0.4);
}
.site-tagline {
  font-size: 12px; color: #484f58;
  font-family: 'Orbitron', sans-serif;
  letter-spacing: 2px;
}

/* ===== FILTER BAR (横スクロールタグバー) ===== */
.filter-bar {
  background: rgba(22, 27, 34, 0.8);
  border-bottom: 1px solid #30363d;
  position: sticky; top: 56px; z-index: 8000;
  backdrop-filter: blur(6px);
}
.filter-bar-inner {
  max-width: 1400px; margin: 0 auto;
  padding: 10px 24px;
  display: flex; flex-direction: column; gap: 8px;
}
.filter-group {
  display: flex; flex-wrap: wrap; gap: 6px;
}
.filter-divider { display: none; }
.filter-chip {
  font-family: 'Orbitron', sans-serif;
  font-size: 10px; font-weight: 700;
  letter-spacing: 1px;
  padding: 5px 12px;
  border-radius: 3px;
  cursor: pointer;
  border: 1px solid #30363d;
  background: transparent;
  color: #8b949e;
  white-space: nowrap;
  transition: all 0.2s;
}
.filter-chip:hover {
  color: #c9d1d9;
  border-color: #484f58;
}
.filter-chip.format { color: #39d353; border-color: rgba(57, 211, 83, 0.2); }
.filter-chip.format:hover { border-color: #39d353; box-shadow: 0 0 6px rgba(57, 211, 83, 0.2); }
.filter-chip.format.active {
  background: rgba(57, 211, 83, 0.15);
  border-color: #39d353; color: #39d353;
  box-shadow: 0 0 8px rgba(57, 211, 83, 0.3);
}
.filter-chip.genre:hover { border-color: #00d4ff; box-shadow: 0 0 6px rgba(0, 212, 255, 0.2); }
.filter-chip.genre.active {
  background: rgba(0, 212, 255, 0.15);
  border-color: #00d4ff; color: #00d4ff;
  box-shadow: 0 0 8px rgba(0, 212, 255, 0.3);
}

/* --- Top Controls (count + active filters) --- */
.top-controls {
  max-width: 1400px; margin: 0 auto;
  padding: 16px 24px 0;
}
.active-filter-display {
  font-size: 12px; color: #8b949e;
  margin-bottom: 8px;
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
}
.active-filter-display .filter-tag {
  display: inline-flex; align-items: center;
  background: rgba(0, 212, 255, 0.1);
  color: #00d4ff; padding: 2px 10px;
  font-size: 11px; cursor: pointer;
  border: 1px solid rgba(0, 212, 255, 0.25);
  border-radius: 3px;
  font-family: 'Orbitron', sans-serif;
  letter-spacing: 0.5px;
}
.active-filter-display .filter-tag.format {
  background: rgba(57, 211, 83, 0.1);
  color: #39d353; border-color: rgba(57, 211, 83, 0.25);
}
.active-filter-display .filter-tag::after { content: '\00d7'; margin-left: 6px; font-size: 14px; }
.active-filter-display .filter-tag:hover { opacity: 0.7; }
.active-filter-display .clear-all {
  font-family: 'Orbitron', sans-serif;
  font-size: 10px; color: #484f58; cursor: pointer;
  letter-spacing: 1px; margin-left: 4px;
}
.active-filter-display .clear-all:hover { color: #ff0080; }
.result-count {
  font-family: 'Orbitron', sans-serif;
  font-size: 10px; color: #484f58;
  letter-spacing: 2px; margin-bottom: 4px;
}

/* ===== GRID (full width, 4 columns) ===== */
.grid-container {
  max-width: 1400px; margin: 0 auto;
  padding: 16px 24px;
}
.works-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.work-card {
  background: #161b22;
  border: 1px solid #30363d;
  border-radius: 8px;
  overflow: hidden; position: relative;
  transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
}
.work-card:hover {
  transform: scale(1.03);
  border-color: #00d4ff;
  box-shadow: 0 0 20px rgba(0, 212, 255, 0.25), 0 0 40px rgba(0, 212, 255, 0.08);
}
.work-card a { display: block; color: inherit; }
.card-thumb-wrap { position: relative; overflow: hidden; }
.work-card .card-thumb {
  width: 100%; aspect-ratio: 4/3;
  object-fit: cover; display: block;
  transition: transform 0.4s;
}
.work-card:hover .card-thumb { transform: scale(1.05); }

/* --- Score Badge (SVG ring) --- */
.score-badge {
  position: absolute; top: 8px; right: 8px;
  width: 48px; height: 48px; z-index: 2;
}

.work-card .card-info { padding: 12px; }
.work-card .card-title {
  font-size: 13px; font-weight: 700; color: #e6edf3;
  line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
  margin-bottom: 4px;
}
.work-card .card-circle { font-size: 11px; color: #8b949e; margin-bottom: 6px; }
.work-card .card-meta { display: flex; gap: 8px; font-size: 10px; margin-bottom: 6px; }
.work-card .card-sales {
  font-family: 'Orbitron', sans-serif;
  color: #ff0080; font-weight: 700;
}
.work-card .card-date { color: #484f58; }
.work-card .card-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.work-card .card-tag {
  font-family: 'Orbitron', sans-serif;
  font-size: 9px; font-weight: 700; letter-spacing: 0.5px;
  color: #00d4ff; background: rgba(0, 212, 255, 0.08);
  padding: 2px 7px; border-radius: 3px;
  cursor: pointer; border: 1px solid transparent;
  transition: all 0.2s;
}
.work-card .card-tag:hover { border-color: #00d4ff; }
.work-card .card-format {
  font-family: 'Orbitron', sans-serif;
  font-size: 9px; font-weight: 700; letter-spacing: 0.5px;
  color: #39d353; background: rgba(57, 211, 83, 0.08);
  padding: 2px 7px; border-radius: 3px;
  cursor: pointer; border: 1px solid transparent;
  transition: all 0.2s;
}
.work-card .card-format:hover { border-color: #39d353; }

/* --- Pagination --- */
#pagination {
  display: flex; justify-content: center;
  gap: 4px; flex-wrap: wrap;
  max-width: 1400px; margin: 24px auto; padding: 0 24px;
}
#pagination button {
  font-family: 'Orbitron', sans-serif;
  font-size: 11px; font-weight: 700;
  color: #8b949e;
  background: #161b22;
  border: 1px solid #30363d;
  padding: 8px 14px; border-radius: 4px;
  cursor: pointer; transition: all 0.2s;
}
#pagination button:hover {
  color: #00d4ff; border-color: #00d4ff;
  box-shadow: 0 0 8px rgba(0, 212, 255, 0.2);
}
#pagination button.current {
  background: linear-gradient(135deg, #00d4ff, #ff0080);
  color: #fff; border-color: transparent;
  box-shadow: 0 0 12px rgba(0, 212, 255, 0.3);
}

/* --- Work Detail Page --- */
.container { max-width: 900px; margin: 32px auto; padding: 0 20px; }
.work-detail {
  background: #161b22;
  border: 1px solid #30363d;
  border-radius: 8px; padding: 32px;
}
.work-title {
  font-size: 24px; font-weight: 700; color: #e6edf3;
  line-height: 1.4; margin: 24px 0 16px;
}
.work-meta {
  display: flex; flex-wrap: wrap; gap: 16px;
  font-size: 13px; color: #8b949e;
  padding-bottom: 16px;
  border-bottom: 1px solid #30363d;
  margin-bottom: 16px;
}
.work-detail .card-tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.work-detail .card-tag, .work-detail .card-format {
  display: inline-block;
  font-family: 'Orbitron', sans-serif;
  font-size: 10px; font-weight: 700;
  letter-spacing: 1px; padding: 3px 10px;
  border: 1px solid rgba(0, 212, 255, 0.3);
  color: #00d4ff; border-radius: 3px;
  transition: all 0.2s;
}
.work-detail .card-format { color: #39d353; border-color: rgba(57, 211, 83, 0.3); }
.work-detail .card-tag:hover { background: rgba(0, 212, 255, 0.15); }
.work-detail .card-format:hover { background: rgba(57, 211, 83, 0.15); }
.work-description {
  font-size: 15px; line-height: 1.9; color: #c9d1d9; margin: 24px 0;
}
.work-description p { margin-bottom: 16px; }
.cta-area { text-align: center; margin: 32px 0 16px; }
.cta-button {
  display: inline-block;
  background: linear-gradient(135deg, #00d4ff, #ff0080);
  color: #fff;
  font-family: 'Orbitron', sans-serif;
  font-weight: 700; font-size: 13px;
  letter-spacing: 2px; padding: 14px 40px;
  border-radius: 4px;
  transition: box-shadow 0.3s, transform 0.2s;
  box-shadow: 0 0 15px rgba(0, 212, 255, 0.3);
}
.cta-button:hover {
  transform: translateY(-2px); color: #fff;
  box-shadow: 0 0 25px rgba(0, 212, 255, 0.5), 0 0 50px rgba(255, 0, 128, 0.3);
}

/* --- Gallery --- */
.work-gallery { display: flex; gap: 12px; margin-bottom: 24px; }
.gallery-main {
  flex: 1; height: 450px;
  display: flex; align-items: center; justify-content: center;
  background: #1a1f2e; overflow: hidden;
  border: 1px solid #30363d; border-radius: 8px;
}
.gallery-main img { max-width: 100%; max-height: 100%; object-fit: contain; }
.gallery-side { display: flex; flex-direction: column; gap: 4px; width: 80px; height: 450px; }
.gallery-thumbs {
  flex: 1; display: flex; flex-direction: column; gap: 4px;
  overflow-y: hidden; padding: 4px 0;
}
.gallery-thumb-wrap { position: relative; flex-shrink: 0; }
.gallery-thumb {
  width: 80px; height: 60px; object-fit: cover;
  cursor: pointer; opacity: 0.5;
  border: 2px solid transparent; border-radius: 4px;
  transition: opacity 0.2s, border-color 0.2s; display: block;
}
.gallery-thumb:hover { opacity: 0.8; }
.gallery-thumb.active { opacity: 1; border-color: #00d4ff; box-shadow: 0 0 6px rgba(0, 212, 255, 0.4); }
.gallery-thumb-play {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 24px; height: 24px;
  background: rgba(0,0,0,0.7); border-radius: 50%;
  color: #00d4ff; font-size: 10px;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none; padding-left: 2px;
}
.gallery-scroll-btn {
  width: 80px; height: 24px; flex-shrink: 0;
  background: #161b22; border: 1px solid #30363d;
  color: #484f58; cursor: pointer; font-size: 10px;
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s;
}
.gallery-scroll-btn:hover { color: #00d4ff; border-color: #00d4ff; }

/* --- Age Gate --- */
.age-gate {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  min-height: 100vh; text-align: center; padding: 20px;
}
.age-gate h1 {
  font-family: 'Orbitron', sans-serif;
  font-weight: 900; font-size: 32px;
  letter-spacing: 3px; margin-bottom: 24px;
}
.age-gate h1 .cyan { color: #00d4ff; text-shadow: 0 0 15px #00d4ff, 0 0 40px rgba(0, 212, 255, 0.3); }
.age-gate h1 .pink { color: #ff0080; text-shadow: 0 0 15px #ff0080, 0 0 40px rgba(255, 0, 128, 0.3); }
.age-gate p { font-size: 14px; color: #8b949e; margin-bottom: 32px; line-height: 1.8; }
.btn-group { display: flex; gap: 16px; }
.btn-yes {
  background: linear-gradient(135deg, #00d4ff, #0099cc);
  color: #fff; padding: 14px 40px;
  font-family: 'Orbitron', sans-serif;
  font-weight: 700; font-size: 13px;
  letter-spacing: 1px; border: none;
  border-radius: 4px; cursor: pointer;
  box-shadow: 0 0 15px rgba(0, 212, 255, 0.3);
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn-yes:hover { transform: translateY(-2px); box-shadow: 0 0 25px rgba(0, 212, 255, 0.5); }
.btn-no {
  background: transparent; color: #8b949e;
  padding: 14px 40px; border: 1px solid #30363d;
  border-radius: 4px; cursor: pointer;
  font-family: 'Orbitron', sans-serif;
  font-weight: 700; font-size: 13px;
  transition: all 0.2s;
}
.btn-no:hover { border-color: #ff0080; color: #ff0080; }

/* --- Footer --- */
.site-footer {
  max-width: 1400px; margin: 0 auto;
  padding: 28px 24px;
  border-top: 2px solid transparent;
  border-image: linear-gradient(90deg, #00d4ff, #ff0080) 1;
  text-align: center;
}
.site-footer p { font-size: 12px; color: #484f58; line-height: 1.8; }

/* --- Responsive --- */
@media (max-width: 1200px) {
  .works-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  .works-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .header-inner { flex-direction: column; gap: 6px; text-align: center; }
  .works-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .work-card .card-info { padding: 10px; }
  .work-card .card-title { font-size: 12px; }
  .score-badge { width: 36px; height: 36px; }
  .work-gallery { flex-direction: column; }
  .gallery-main { height: 300px; }
  .gallery-side { flex-direction: row; width: 100%; height: auto; }
  .gallery-thumbs { flex-direction: row; overflow-x: auto; overflow-y: hidden; padding: 0 4px; }
  .gallery-thumb { width: 60px; height: 45px; }
  .gallery-scroll-btn { width: 24px; height: 45px; }
  .work-detail { padding: 20px 16px; }
  .work-title { font-size: 20px; }
}
