/* ============================================================
   DRESS 釣果シェアキャンペーン — style.css
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Helvetica Neue", "Yu Gothic", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  color: #1a1a1a;
  background: #ffffff;
  line-height: 1.6;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; }
p { margin: 0; }

.container { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.narrow    { width: min(860px,  calc(100% - 40px)); margin: 0 auto; }
.section   { padding: 72px 0; }
.page-top-space { padding-top: 40px; }

.pc-only { display: block; }
.sp-only { display: none; }

.bg-light { background: #f7f7f7; }
.text-red { color: #dc2626; }

.section-label {
  display: inline-block;
  margin-bottom: 10px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.26em;
  color: #dc2626;
  text-transform: uppercase;
}

h1, h2, h3 { margin: 0; line-height: 1.15; color: #111; }
h2 { font-size: 36px; font-weight: 900; letter-spacing: -0.02em; }
h3 { font-size: 20px; font-weight: 800; }
.page-title { font-size: 40px; font-weight: 900; line-height: 1.2; letter-spacing: -0.03em; }
.section-text { margin-top: 14px; max-width: 760px; color: #666; font-size: 15px; line-height: 1.85; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 36px; }

/* ============================================================
   ヘッダー
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #111111;
  border-bottom: 3px solid #dc2626;
}

.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 12px 0; }

.logo-wrap { display: flex; align-items: center; }
.site-logo { height: 34px; width: auto; display: block; }

.main-nav { display: flex; align-items: center; gap: 24px; }
.main-nav a { font-size: 13px; font-weight: 600; color: #aaaaaa; letter-spacing: 0.05em; text-transform: uppercase; transition: color 0.15s; }
.main-nav a:hover { color: #ffffff; }

.header-post-count {
  font-size: 12px;
  color: #aaaaaa;
  white-space: nowrap;
  margin-left: auto;
}
.header-post-count strong { color: #dc2626; font-weight: 800; font-size: 14px; }

.header-btn { flex-shrink: 0; }

/* ============================================================
   ボタン
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: all 0.15s;
  border: 2px solid transparent;
  cursor: pointer;
  text-align: center;
}
.btn.large { padding: 16px 36px; font-size: 15px; }
.btn-primary  { background: #dc2626; color: #fff; border-color: #dc2626; }
.btn-primary:hover  { background: #b91c1c; border-color: #b91c1c; transform: translateY(-1px); }
.btn-secondary { background: #fff; color: #dc2626; border-color: #dc2626; }
.btn-secondary:hover { background: #fef2f2; }

/* ============================================================
   ① ファーストビュー
   ============================================================ */
.section-fv {
  background: #ffffff;
  border-bottom: 1px solid #e8e8e8;
  padding-top: 16px;
}

.fv-grid {
  display: grid;
  grid-template-columns: 1fr 1.8fr;
  min-height: 500px;
}

.fv-copy {
  padding: 56px 48px 56px 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
}

.fv-eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: #dc2626;
  text-transform: uppercase;
}

.fv-h1 {
  font-size: 56px;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: #111;
}

.fv-desc {
  font-size: 16px;
  color: #555;
  line-height: 1.8;
}

.fv-more-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 800;
  color: #dc2626;
  border: 2px solid #dc2626;
  padding: 10px 20px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  transition: all 0.15s;
}
.fv-more-link:hover { background: #dc2626; color: #fff; }

/* 右：写真グリッド */
.fv-photos {
  background: #f5f5f5;
  border-left: 1px solid #e8e8e8;
  display: flex;
  flex-direction: column;
  margin-top: 16px;
  border-radius: 0;
  overflow: hidden;
}

.fv-photos-grid {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 3px;
}

.fv-empty {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  color: #aaa;
  font-size: 14px;
  text-align: center;
  line-height: 1.8;
}

/* SP用「もっと見る」 */
.fv-photos-sp-more { display: none; }
.fv-sp-more-link { font-size: 12px; color: #aaa; font-weight: 600; letter-spacing: 0.06em; }

/* 写真アイテム共通 */
.photo-item {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #ddd;
}

.photo-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.3s ease; }
.photo-item:hover img { transform: scale(1.06); }

.photo-fallback { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; padding: 8px; background: #e8e8e8; }
.photo-fallback span { font-size: 12px; font-weight: 700; color: #999; text-align: center; }

.photo-overlay {
  position: absolute;
  inset: auto 0 0;
  padding: 6px 8px 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.photo-fish {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  background: rgba(0,0,0,0.62);
  padding: 2px 6px;
  border-radius: 2px;
  align-self: flex-start;
}

.photo-region {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  background: rgba(220,38,38,0.82);
  padding: 2px 6px;
  border-radius: 2px;
  align-self: flex-start;
}

/* ============================================================
   ② ランキング
   ============================================================ */
.section-ranking {
  padding: 56px 0;
  background: #ffffff;
  border-bottom: 1px solid #e8e8e8;
}

.ranking-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 56px;
  align-items: start;
}

.ranking-h2 { font-size: 28px; font-weight: 900; margin-bottom: 20px; }

.ranking-list { display: flex; flex-direction: column; }

.ranking-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #f0f0f0;
}
.ranking-item:last-child { border-bottom: none; }

.ranking-left { display: flex; align-items: center; gap: 10px; width: 90px; flex-shrink: 0; }

.rank-badge { font-size: 13px; font-weight: 700; width: 22px; text-align: center; }
.rank-1 { color: #dc2626; font-size: 15px; }
.rank-2, .rank-3 { color: #888; }
.rank-4, .rank-5, .rank-6, .rank-7, .rank-8 { color: #bbb; }

.region-name { font-size: 15px; font-weight: 700; color: #111; }
.ranking-bar-wrap { flex: 1; }
.ranking-bar-track { height: 5px; background: #eee; border-radius: 99px; overflow: hidden; }
.ranking-bar-fill  { height: 100%; background: #dc2626; border-radius: 99px; }
.ranking-right { text-align: right; flex-shrink: 0; width: 52px; }
.post-count { font-size: 16px; font-weight: 800; color: #111; }
.post-unit  { font-size: 11px; color: #aaa; }

.ranking-side-inner {
  padding-top: 52px;
}
.ranking-side-text { font-size: 14px; color: #888; line-height: 1.8; }

/* ============================================================
   ③ 不足魚種
   ============================================================ */
.card-grid { display: grid; gap: 18px; }
.card-grid.four  { grid-template-columns: repeat(4, 1fr); }
.card-grid.three { grid-template-columns: repeat(3, 1fr); }

.fish-card {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-top: 3px solid #dc2626;
  border-radius: 4px;
  padding: 20px;
}

.fish-card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.mini-label { font-size: 10px; font-weight: 700; letter-spacing: 0.14em; color: #999; text-transform: uppercase; margin-bottom: 4px; }
.multi-badge { padding: 6px 10px; border-radius: 2px; background: #dc2626; color: #fff; font-size: 12px; font-weight: 900; white-space: nowrap; }
.fish-count-row { display: flex; justify-content: space-between; align-items: flex-end; margin-top: 16px; }
.fish-current { font-size: 30px; font-weight: 900; color: #111; }
.fish-target  { font-size: 18px; font-weight: 800; color: #ccc; text-align: right; }
.mini-text    { font-size: 11px; color: #999; margin-top: 2px; }
.remain-text  { margin-top: 8px; font-size: 12px; font-weight: 700; color: #dc2626; }
.progress-meta { margin-top: 14px; display: flex; justify-content: space-between; font-size: 12px; color: #888; }
.progress-meta strong { color: #dc2626; }
.progress-bar  { width: 100%; height: 5px; margin-top: 6px; border-radius: 99px; background: #eee; overflow: hidden; }
.progress-fill { height: 100%; border-radius: 99px; background: #dc2626; }

/* ============================================================
   ④ 参加メリット（黒背景）
   ============================================================ */
.section-merit { background: #f7f7f7; padding: 64px 0; border-top: 1px solid #e8e8e8; border-bottom: 1px solid #e8e8e8; }
.merit-h2 { color: #111; margin-bottom: 36px; }
.merit-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; }
.merit-item { background: #fff; padding: 32px 28px; border: 1px solid #e8e8e8; border-radius: 4px; }
.merit-num { font-size: 11px; font-weight: 800; letter-spacing: 0.16em; color: #dc2626; margin-bottom: 14px; }
.merit-item h3 { font-size: 18px; color: #111; margin-bottom: 10px; }
.merit-item p  { font-size: 14px; color: #666; line-height: 1.8; }

/* ============================================================
   ⑤ HOW TO（PC横 / SP縦）
   ============================================================ */
.howto-steps { display: flex; align-items: flex-start; margin-top: 36px; }
.howto-step { flex: 1; text-align: center; padding: 0 12px; }
.howto-num { font-size: 10px; font-weight: 800; letter-spacing: 0.2em; color: #dc2626; margin-bottom: 14px; }
.howto-circle { width: 52px; height: 52px; background: #111; color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 18px; font-weight: 900; margin: 0 auto 14px; }
.howto-step h3 { font-size: 16px; color: #111; margin-bottom: 6px; }
.howto-step p  { font-size: 13px; color: #666; line-height: 1.7; }
.howto-arrow { font-size: 28px; color: #ddd; padding: 0 4px; margin-top: 48px; flex-shrink: 0; }

.howto-list { display: none; flex-direction: column; margin-top: 28px; }
.howto-list-item { display: flex; align-items: flex-start; gap: 16px; padding: 16px 0; border-bottom: 1px solid #f0f0f0; }
.howto-list-item:last-child { border-bottom: none; }
.howto-list-num { width: 36px; height: 36px; background: #111; color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 900; flex-shrink: 0; }
.howto-list-item strong { font-size: 15px; color: #111; display: block; margin-bottom: 4px; }
.howto-list-item p { font-size: 13px; color: #666; line-height: 1.7; }

/* ============================================================
   ⑥ FAQ
   ============================================================ */
.section-faq { background: #f7f7f7; }
.faq-list { display: flex; flex-direction: column; gap: 10px; margin-top: 28px; }
.faq-item { background: #fff; border: 1px solid #e8e8e8; border-left: 4px solid #111; border-radius: 4px; padding: 20px 24px; }
.faq-item h3 { font-size: 16px; color: #111; margin-bottom: 8px; }
.faq-item p  { font-size: 14px; color: #666; line-height: 1.8; }

/* ============================================================
   ⑦ CTA
   ============================================================ */
.section-cta-final { background: #111; border-top: 3px solid #dc2626; }
.cta-final-inner { display: flex; align-items: center; justify-content: space-between; gap: 32px; padding: 52px 0; }
.cta-final-copy h2 { color: #fff; font-size: 28px; margin-bottom: 8px; }
.cta-final-copy p  { color: #555; font-size: 14px; }

/* ============================================================
   通知・状態
   ============================================================ */
.inline-notice { padding: 12px 16px; border-radius: 4px; border-left: 4px solid #dc2626; background: #fff5f5; color: #b91c1c; font-size: 14px; line-height: 1.7; }
.success-notice { margin: 16px 0; padding: 12px 16px; border-radius: 4px; border-left: 4px solid #16a34a; background: #f0fdf4; color: #15803d; font-size: 14px; line-height: 1.7; }
.empty-state { padding: 28px 24px; border: 1px dashed #d4d4d4; border-radius: 4px; background: #fafafa; color: #999; text-align: center; font-size: 14px; }

/* ============================================================
   汎用カード・投稿カード（posts.php等）
   ============================================================ */
.info-card, .step-card, .post-card, .content-card { background: #fff; border: 1px solid #e8e8e8; border-radius: 4px; }
.info-card { padding: 24px; border-top: 3px solid #111; }
.step-card { padding: 24px; border-top: 3px solid #dc2626; }
.info-card p, .step-card p { margin-top: 10px; color: #666; font-size: 14px; line-height: 1.85; }
.icon-circle { width: 44px; height: 44px; border-radius: 4px; background: #111; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 18px; font-weight: 900; margin-bottom: 14px; }
.step-no { font-size: 10px; font-weight: 900; letter-spacing: 0.2em; color: #dc2626; margin-bottom: 10px; }

.post-card { overflow: hidden; }
.real-post-thumb { aspect-ratio: 4/3; overflow: hidden; background: #f2f2f2; border-bottom: 1px solid #e8e8e8; }
.real-post-thumb img { width: 100%; height: 100%; object-fit: cover; }
.post-thumb { aspect-ratio: 4/3; background: #f5f5f5; display: flex; flex-direction: column; justify-content: flex-end; padding: 20px; border-bottom: 1px solid #e8e8e8; }
.post-thumb span { font-size: 10px; font-weight: 700; letter-spacing: 0.14em; color: #dc2626; text-transform: uppercase; }
.post-thumb strong { margin-top: 8px; font-size: 26px; font-weight: 900; color: #aaa; }
.fallback-thumb { height: 100%; }
.post-body { padding: 16px 18px; }
.post-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.tag { display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 2px; font-size: 11px; font-weight: 700; }
.tag.red  { background: #fef2f2; color: #dc2626; }
.tag.gray { background: #f2f2f2; color: #666; }
.content-card { padding: 22px; }
.content-card-header { margin-bottom: 16px; border-bottom: 1px solid #e8e8e8; padding-bottom: 12px; }

/* ============================================================
   ランキングページ（ranking.php）
   ============================================================ */
.ranking-layout { display: grid; grid-template-columns: 1.25fr 0.75fr; gap: 20px; margin-top: 28px; }
.ranking-table-wrap, .admin-table-wrap { overflow-x: auto; }
.ranking-table, .admin-table { width: 100%; border-collapse: collapse; }
.ranking-table th, .ranking-table td,
.admin-table th, .admin-table td { padding: 12px 10px; border-bottom: 1px solid #e8e8e8; text-align: left; font-size: 14px; vertical-align: middle; }
.ranking-table th, .admin-table th { color: #888; font-weight: 700; background: #f2f2f2; font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; }
.table-rank-badge { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 4px; background: #111; color: #fff; font-weight: 900; font-size: 13px; }
.table-link { color: #dc2626; font-weight: 700; }
.table-link:hover { text-decoration: underline; }

.mini-post-list { display: grid; gap: 10px; }
.mini-post-item { display: grid; grid-template-columns: 80px 1fr; gap: 10px; align-items: center; padding: 8px; border: 1px solid #e8e8e8; border-radius: 4px; }
.mini-post-thumb { width: 80px; height: 80px; overflow: hidden; border-radius: 4px; background: #f2f2f2; }
.mini-post-thumb img { width: 100%; height: 100%; object-fit: cover; }
.mini-post-fallback { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: #f5f5f5; color: #aaa; font-size: 11px; font-weight: 700; text-align: center; padding: 6px; }
.mini-post-title { font-size: 14px; font-weight: 800; color: #111; }
.mini-post-meta  { margin-top: 4px; font-size: 12px; color: #999; }

/* ============================================================
   管理画面
   ============================================================ */
.admin-filter-bar { display: flex; gap: 8px; flex-wrap: wrap; margin: 18px 0; }
.filter-chip { display: inline-flex; align-items: center; justify-content: center; padding: 7px 14px; border-radius: 2px; background: #f2f2f2; border: 1px solid #e8e8e8; color: #666; font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; transition: all 0.15s; }
.filter-chip.active { background: #dc2626; color: #fff; border-color: #dc2626; }
.filter-chip:hover:not(.active) { border-color: #111; color: #111; }
.admin-table-wrap { margin-top: 18px; background: #fff; border: 1px solid #e8e8e8; border-radius: 4px; overflow: hidden; }
.admin-strong { font-weight: 800; color: #111; }
.admin-thumb-box { width: 68px; height: 68px; border-radius: 4px; overflow: hidden; border: 1px solid #e8e8e8; background: #f2f2f2; }
.admin-thumb-img { width: 100%; height: 100%; object-fit: cover; }
.admin-thumb-fallback { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 10px; color: #999; }
.admin-action-stack { display: grid; gap: 5px; }
.admin-action-stack form { margin: 0; }
.admin-action-btn { width: 100%; min-width: 76px; padding: 7px 8px; font-size: 12px; }
.status-badge, .duplicate-badge { display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 2px; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.status-pending  { background: #fff7ed; color: #c2410c; border: 1px solid #fed7aa; }
.status-approved { background: #f0fdf4; color: #15803d; border: 1px solid #bbf7d0; }
.status-rejected { background: #f2f2f2; color: #888; border: 1px solid #d4d4d4; }
.duplicate-badge { background: #fef2f2; color: #dc2626; border: 1px solid #fecaca; }
.duplicate-cell { display: grid; gap: 3px; }
.duplicate-detail { font-size: 11px; color: #b91c1c; }
.duplicate-ok { font-size: 11px; color: #15803d; font-weight: 700; }
.card-actions { margin-top: 16px; }
.card-btn-full { width: 100%; }

/* ============================================================
   フッター
   ============================================================ */
.site-footer { border-top: 3px solid #dc2626; background: #111; padding: 28px 0 48px; }
.footer-inner { display: flex; justify-content: space-between; gap: 24px; align-items: center; }
.footer-title { font-size: 13px; font-weight: 700; color: #888; }
.footer-copy  { margin-top: 5px; font-size: 12px; color: #555; }
.footer-links { display: flex; gap: 20px; }
.footer-links a { font-size: 13px; color: #555; }
.footer-links a:hover { color: #dc2626; }

/* ============================================================
   レスポンシブ — タブレット
   ============================================================ */
@media (max-width: 1024px) {
  h2 { font-size: 28px; }
  .main-nav { display: none; }
  .fv-grid { grid-template-columns: 1fr 1.4fr; }
  .fv-h1 { font-size: 44px; }
  .ranking-grid { grid-template-columns: 1fr; gap: 24px; }
  .merit-grid { grid-template-columns: repeat(3,1fr); }
  .card-grid.four  { grid-template-columns: repeat(2, 1fr); }
  .card-grid.three { grid-template-columns: repeat(2, 1fr); }
  .ranking-layout { grid-template-columns: 1fr; }
  .section-head { flex-direction: column; align-items: flex-start; }
  .cta-final-inner { flex-direction: column; align-items: flex-start; gap: 20px; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 14px; }
}

/* ============================================================
   レスポンシブ — スマホ
   ============================================================ */
@media (max-width: 768px) {
  .container, .narrow { width: calc(100% - 28px); }
  .section { padding: 48px 0; }
  .page-top-space { padding-top: 24px; }

  .pc-only { display: none !important; }
  .sp-only { display: block; }

  h2 { font-size: 24px; }
  h3 { font-size: 17px; }
  .page-title { font-size: 26px; }

  /* ヘッダー */
  .header-inner { gap: 10px; }
  .site-logo { height: 24px; }
  .header-btn { padding: 8px 14px; font-size: 12px; }
  .header-post-count { display: none; }

  /* ① FV：SP は写真が先、コピーが下 */
  .fv-grid {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .fv-copy {
    padding: 20px 0 24px;
    order: 2;
    gap: 10px;
  }

  .fv-eyebrow { font-size: 10px; }
  .fv-h1 { font-size: 30px; }
  .fv-desc { font-size: 14px; }


  .fv-photos {
    order: 1;
    border-left: none;
    border-bottom: 1px solid #e8e8e8;
  }

  .fv-photos-grid {
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
  }

  /* SP：photo-overlay 常時表示 */
  .photo-overlay { opacity: 1; }

  /* SP：もっと見るリンク（fv-copyのボタンを使用） */

  /* ② ランキング */
  .section-ranking { padding: 40px 0; }
  .ranking-h2 { font-size: 22px; margin-bottom: 16px; }

  /* ③ 不足魚種 */
  .card-grid.four { grid-template-columns: repeat(2, 1fr); }
  .fish-current { font-size: 24px; }

  /* ④ メリット */
  .merit-grid { grid-template-columns: 1fr; gap: 2px; }
  .merit-item { padding: 22px 20px; }

  .howto-list { display: flex; }

  /* ⑦ CTA */
  .section-cta-final { padding: 0; }
  .cta-final-inner { padding: 36px 0; flex-direction: column; gap: 20px; align-items: flex-start; }
  .cta-final-copy h2 { font-size: 22px; }
  .cta-final-inner .btn { width: 100%; }

  /* 管理画面 */
  .admin-filter-bar { gap: 6px; }
  .ranking-layout { grid-template-columns: 1fr; }
  .mini-post-item { grid-template-columns: 68px 1fr; }
  .mini-post-thumb { width: 68px; height: 68px; }
  .card-grid.three { grid-template-columns: 1fr; }

  /* フッター */
  .site-footer { padding-bottom: 28px; }
}

/* ============================================================
   共通ページレイアウト（サブページ）
   ============================================================ */
.page-main {
  padding: 56px 0 80px;
  min-height: calc(100vh - 200px);
}

/* ============================================================
   投稿フォーム（upload.php）
   ============================================================ */
.upload-page {
  padding: 56px 0 80px;
  min-height: 100vh;
}

.upload-wrap { width: min(900px, calc(100% - 32px)); margin: 0 auto; }

.upload-header { margin-bottom: 32px; }
.upload-header p { margin-top: 12px; color: #666; font-size: 15px; line-height: 1.85; }

.upload-form-card {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-top: 3px solid #dc2626;
  border-radius: 4px;
  padding: 36px;
}

.form-grid { display: flex; flex-direction: column; gap: 24px; }

.form-group label { display: block; font-size: 14px; font-weight: 700; margin-bottom: 10px; color: #111; }

.form-group input[type="text"],
.form-group input[type="file"],
.form-group input[type="search"],
.form-group select {
  width: 100%;
  border: 1px solid #e4e4e7;
  border-radius: 4px;
  padding: 12px 14px;
  font-size: 15px;
  outline: none;
  background: #fff;
  transition: border-color 0.15s;
}

.form-group input:focus,
.form-group select:focus {
  border-color: #dc2626;
  box-shadow: 0 0 0 3px rgba(220,38,38,0.08);
}

.helper-text { margin-top: 8px; font-size: 13px; color: #888; line-height: 1.7; }
.file-size-hint { margin-top: 4px; font-size: 12px; color: #aaa; }

.suggest-box {
  margin-top: 8px;
  border: 1px solid #e4e4e7;
  border-radius: 4px;
  background: #fff;
  max-height: 220px;
  overflow-y: auto;
  display: none;
}

.suggest-item { padding: 11px 14px; border-bottom: 1px solid #f4f4f5; cursor: pointer; font-size: 14px; }
.suggest-item:last-child { border-bottom: none; }
.suggest-item:hover { background: #fef2f2; }

.selected-species {
  margin-top: 8px;
  display: none;
  padding: 10px 14px;
  border-radius: 4px;
  background: #fef2f2;
  color: #dc2626;
  font-size: 14px;
  font-weight: 700;
  border: 1px solid #fecaca;
}

.request-link { margin-top: 10px; font-size: 14px; }
.request-link button { background: none; border: none; color: #dc2626; font-weight: 700; cursor: pointer; padding: 0; text-decoration: underline; }

.preview-area { display: none; margin-top: 12px; }
.preview-area img { width: 100%; max-width: 320px; border-radius: 4px; border: 1px solid #e8e8e8; }

.submit-row { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; margin-top: 8px; }
.back-link { color: #888; font-size: 14px; font-weight: 600; }
.back-link:hover { color: #111; }

.message-box { display: none; margin-bottom: 16px; padding: 12px 16px; border-radius: 4px; font-size: 14px; line-height: 1.7; }
.message-box.error   { display: block; background: #fff5f5; color: #b91c1c; border: 1px solid #fecaca; }
.message-box.success { display: block; background: #f0fdf4; color: #15803d; border: 1px solid #bbf7d0; }

/* ============================================================
   投稿完了（thanks.php）
   ============================================================ */
.thanks-page {
  padding: 56px 0 80px;
  min-height: calc(100vh - 200px);
}

.thanks-wrap { width: min(760px, calc(100% - 32px)); margin: 0 auto; }

.thanks-card {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-top: 3px solid #dc2626;
  border-radius: 4px;
  padding: 48px 40px;
  text-align: center;
}

.thanks-icon {
  width: 72px; height: 72px;
  margin: 0 auto 20px;
  border-radius: 4px;
  background: #fef2f2;
  color: #dc2626;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: 900;
}

.thanks-title { font-size: 32px; font-weight: 900; color: #111; }
.thanks-text  { margin-top: 16px; font-size: 16px; color: #555; line-height: 1.9; }

.thanks-note {
  margin-top: 20px;
  padding: 16px 18px;
  border-radius: 4px;
  background: #f7f7f7;
  color: #555;
  font-size: 14px;
  line-height: 1.8;
  text-align: left;
}

.thanks-alert {
  margin-top: 16px;
  padding: 14px 18px;
  border-radius: 4px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #9a3412;
  font-size: 14px;
  line-height: 1.8;
  text-align: left;
}

.thanks-actions { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; margin-top: 28px; }

/* ============================================================
   レスポンシブ追加
   ============================================================ */
@media (max-width: 768px) {
  .upload-page { padding: 32px 0 80px; }
  .upload-form-card { padding: 22px; }
  .thanks-card { padding: 28px 20px; }
  .thanks-title { font-size: 26px; }
  .thanks-actions { flex-direction: column; }
  .thanks-actions .btn { width: 100%; }
  .page-main { padding: 40px 0 60px; }
}

/* ============================================================
   マイページ
   ============================================================ */
.mypage-search {
  display: flex;
  gap: 10px;
  margin-top: 28px;
  margin-bottom: 8px;
}
.mypage-search input {
  flex: 1;
  border: 1px solid #e4e4e7;
  border-radius: 4px;
  padding: 12px 14px;
  font-size: 15px;
  outline: none;
}
.mypage-search input:focus { border-color: #dc2626; }

/* ランクカード */
.mypage-rank-card {
  margin-top: 32px;
  background: #fff;
  border: 1px solid #e8e8e8;
  border-top: 3px solid #dc2626;
  border-radius: 4px;
  padding: 24px;
}
.mypage-rank-header { display: flex; align-items: center; gap: 16px; margin-bottom: 16px; }
.mypage-rank-icon   { font-size: 40px; line-height: 1; }
.mypage-rank-name   { font-size: 22px; font-weight: 900; color: #111; }
.mypage-rank-sub    { font-size: 13px; color: #888; margin-top: 4px; }
.mypage-rank-name   { font-size: 22px; font-weight: 900; color: #111; }

.mypage-progress-section { border-top: 1px solid #f0f0f0; padding-top: 16px; }
.mypage-progress-label   { font-size: 13px; color: #555; font-weight: 600; }
.mypage-progress-note    { font-size: 12px; color: #aaa; font-weight: 400; }

.mypage-next-rank       { margin-top: 14px; }
.mypage-next-rank-label { font-size: 12px; color: #888; margin-bottom: 6px; }
.mypage-conditions      { display: flex; flex-wrap: wrap; gap: 10px; }
.mypage-cond            { font-size: 13px; font-weight: 600; }
.mypage-cond.ok         { color: #15803d; }
.mypage-cond.ng         { color: #dc2626; }

.mypage-legend-rank     { font-size: 24px; font-weight: 900; color: #dc2626; margin-top: 8px; }

/* ポイントサマリー */
.mypage-points-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 20px;
}
.mypage-point-card {
  background: #f7f7f7;
  border-radius: 4px;
  padding: 16px;
  border-top: 3px solid #e8e8e8;
}
.mypage-point-card.accent { background: #fef2f2; border-top-color: #dc2626; }
.mypage-point-label { font-size: 11px; color: #888; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 6px; }
.mypage-point-value { font-size: 28px; font-weight: 900; color: #111; }
.mypage-point-unit  { font-size: 14px; font-weight: 400; color: #888; margin-left: 2px; }

/* ストリーク＋ミッション */
.mypage-daily-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 14px;
  margin-top: 14px;
}
.mypage-daily-card {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 4px;
  padding: 18px;
}
.mypage-daily-title    { font-size: 13px; font-weight: 700; color: #111; margin-bottom: 12px; }
.mypage-streak-count   { font-size: 32px; font-weight: 900; color: #dc2626; }
.mypage-streak-sub     { font-size: 12px; color: #888; margin-top: 4px; }
.mypage-streak-warning { font-size: 12px; color: #c2410c; font-weight: 700; margin-top: 8px; }
.mypage-streak-next    { font-size: 12px; color: #555; margin-top: 8px; }

.mypage-mission-list    { display: flex; flex-direction: column; gap: 8px; }
.mypage-mission-item    { font-size: 13px; color: #555; }
.mypage-mission-item.done { color: #15803d; }
.mypage-mission-pt      { font-size: 12px; color: #dc2626; font-weight: 700; margin-left: 4px; }
.mypage-daily-cap       { margin-top: 12px; font-size: 12px; color: #888; border-top: 1px solid #f0f0f0; padding-top: 10px; }

/* バッジ */
.mypage-section       { margin-top: 28px; }
.mypage-section-title { font-size: 15px; font-weight: 800; color: #111; margin-bottom: 14px; border-bottom: 1px solid #f0f0f0; padding-bottom: 8px; }
.mypage-badges        { display: flex; flex-wrap: wrap; gap: 10px; }
.mypage-badge         { display: flex; align-items: center; gap: 6px; background: #f7f7f7; border: 1px solid #e8e8e8; border-radius: 4px; padding: 8px 12px; }
.mypage-badge-icon    { font-size: 18px; }
.mypage-badge-name    { font-size: 12px; font-weight: 700; color: #333; }

/* 最近の投稿 */
.mypage-post-list { display: flex; flex-direction: column; gap: 0; }
.mypage-post-item {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 12px 0; border-bottom: 1px solid #f0f0f0;
}
.mypage-post-item:last-child { border-bottom: none; }
.mypage-post-fish   { font-size: 15px; font-weight: 700; color: #111; }
.mypage-post-meta   { font-size: 12px; color: #888; margin-top: 3px; }
.mypage-post-date   { margin-left: 8px; }
.mypage-post-status { font-size: 12px; white-space: nowrap; }

/* ポイント履歴テーブル */
.mypage-log-table-wrap { overflow-x: auto; }
.mypage-log-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.mypage-log-table th {
  background: #f2f2f2; padding: 10px 12px;
  text-align: left; font-size: 11px; color: #888;
  text-transform: uppercase; letter-spacing: .06em;
  border-bottom: 1px solid #e8e8e8;
}
.mypage-log-table td { padding: 10px 12px; border-bottom: 1px solid #f0f0f0; color: #333; }
.log-plus  { color: #15803d; font-weight: 700; }
.log-minus { color: #dc2626; font-weight: 700; }

/* レスポンシブ */
@media (max-width: 768px) {
  .mypage-search { flex-direction: column; }
  .mypage-points-grid { grid-template-columns: repeat(3,1fr); gap: 8px; }
  .mypage-point-value { font-size: 22px; }
  .mypage-daily-grid  { grid-template-columns: 1fr; }
  .mypage-rank-icon   { font-size: 32px; }
  .mypage-rank-name   { font-size: 18px; }
}

/* ============================================================
   交換ページ
   ============================================================ */
.exchange-balance-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 4px;
  padding: 14px 18px;
  margin-top: 24px;
  margin-bottom: 8px;
}
.exchange-balance-label { font-size: 13px; color: #888; }
.exchange-balance-value { font-size: 24px; font-weight: 900; color: #dc2626; }
.exchange-mypage-link   { font-size: 13px; color: #dc2626; margin-left: auto; font-weight: 600; }

.exchange-section-title {
  font-size: 16px;
  font-weight: 800;
  color: #111;
  margin-top: 24px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.exchange-section-note { font-size: 12px; color: #dc2626; font-weight: 600; }

.exchange-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.exchange-card {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 4px;
  padding: 20px;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.exchange-card.recommended { border-color: #dc2626; border-width: 2px; }
.exchange-card.out-of-stock { opacity: 0.5; }
.exchange-card.coupon-card  { border-top: 3px solid #888; }

.exchange-recommended-badge {
  font-size: 11px;
  font-weight: 700;
  color: #dc2626;
  letter-spacing: .06em;
}
.exchange-stock-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 2px;
  background: #f2f2f2;
  color: #666;
  width: fit-content;
}
.exchange-stock-badge.low { background: #fff7ed; color: #c2410c; }

.exchange-card-name   { font-size: 16px; font-weight: 800; color: #111; }
.exchange-card-desc   { font-size: 13px; color: #666; line-height: 1.7; }
.exchange-card-value  { font-size: 13px; color: #888; }
.exchange-card-points { font-size: 22px; font-weight: 900; color: #dc2626; }
.exchange-btn { width: 100%; margin-top: 4px; }
.exchange-cant-btn {
  width: 100%;
  padding: 11px;
  text-align: center;
  font-size: 12px;
  color: #aaa;
  background: #f7f7f7;
  border-radius: 4px;
  margin-top: 4px;
}

/* 確認画面 */
.exchange-confirm-card {
  background: #fff;
  border: 1px solid #e8e8e8;
  border-top: 3px solid #dc2626;
  border-radius: 4px;
  padding: 28px;
  margin-top: 24px;
}
.exchange-confirm-card h2 { margin-bottom: 20px; }
.exchange-confirm-detail  { display: flex; flex-direction: column; gap: 0; margin-bottom: 20px; }
.exc-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid #f0f0f0;
  font-size: 15px;
}
.exc-row:last-child { border-bottom: none; }
.exc-label { color: #888; }
.exc-value { font-weight: 700; color: #111; }

.exchange-novelty-note {
  background: #fff7ed;
  border-left: 4px solid #f97316;
  padding: 12px 14px;
  font-size: 13px;
  color: #9a3412;
  line-height: 1.7;
  margin-bottom: 20px;
  border-radius: 2px;
}
.exchange-confirm-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 8px;
}

/* 完了画面 */
.exchange-complete-card {
  text-align: center;
  padding: 40px 24px;
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 4px;
  margin-top: 24px;
}
.exchange-complete-icon { font-size: 48px; margin-bottom: 12px; }
.exchange-complete-card h2 { margin-bottom: 20px; }

.exchange-coupon-box {
  background: #fef2f2;
  border: 2px dashed #dc2626;
  border-radius: 4px;
  padding: 24px;
  margin: 0 auto 20px;
  max-width: 400px;
}
.exchange-coupon-label  { font-size: 12px; color: #888; margin-bottom: 8px; }
.exchange-coupon-code   { font-size: 24px; font-weight: 900; color: #dc2626; letter-spacing: .1em; font-family: monospace; }
.exchange-coupon-amount { font-size: 18px; font-weight: 700; color: #111; margin-top: 6px; }
.exchange-coupon-note   { font-size: 12px; color: #666; margin-top: 12px; line-height: 1.7; }

.exchange-novelty-complete { font-size: 15px; color: #555; line-height: 1.8; }
.exchange-complete-balance { font-size: 14px; color: #888; margin: 20px 0; }
.exchange-complete-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* レスポンシブ */
@media (max-width: 768px) {
  .exchange-grid { grid-template-columns: 1fr; }
  .exchange-balance-bar { flex-wrap: wrap; }
  .exchange-mypage-link { margin-left: 0; width: 100%; }
  .exchange-confirm-actions { flex-direction: column; }
  .exchange-confirm-actions .btn { width: 100%; }
}

/* ============================================================
   レジェンドランキングページ
   ============================================================ */
.legend-list { display: flex; flex-direction: column; gap: 8px; margin-top: 28px; }

.legend-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 4px;
}
.legend-item.top1 { border-color: #dc2626; border-width: 2px; background: #fff9f9; }
.legend-item.top2 { border-color: #888; }
.legend-item.top3 { border-color: #c2955b; }
.legend-item.is-me { outline: 2px solid #dc2626; outline-offset: 2px; }

.legend-rank-num { width: 44px; text-align: center; flex-shrink: 0; }
.legend-crown    { font-size: 28px; }
.legend-silver   { font-size: 24px; }
.legend-bronze   { font-size: 24px; }
.legend-num      { font-size: 18px; font-weight: 900; color: #bbb; }

.legend-info   { flex: 1; }
.legend-nick   { font-size: 17px; font-weight: 800; color: #111; display: flex; align-items: center; gap: 8px; }
.legend-sub    { font-size: 12px; color: #888; margin-top: 3px; }
.legend-me-badge { font-size: 11px; background: #dc2626; color: #fff; padding: 2px 8px; border-radius: 2px; font-weight: 700; }

.legend-points      { text-align: right; flex-shrink: 0; }
.legend-pt-value    { font-size: 22px; font-weight: 900; color: #111; }
.legend-pt-unit     { font-size: 12px; color: #aaa; }

.legend-my-rank {
  font-size: 14px;
  font-weight: 700;
  color: #dc2626;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 4px;
  padding: 10px 14px;
  margin-bottom: 16px;
}
.legend-my-rank strong { font-size: 18px; }

.legend-howto {
  margin-top: 32px;
  padding: 20px 24px;
  background: #111;
  border-radius: 4px;
  border-top: 3px solid #dc2626;
}
.legend-howto-title { font-size: 14px; font-weight: 800; color: #fff; margin-bottom: 8px; }
.legend-howto-body  { font-size: 13px; color: #888; line-height: 1.8; }

/* トップページ：レジェンドティーザー */
.legend-teaser {
  margin-top: 20px;
  padding: 16px;
  background: #1a1a1a;
  border-radius: 4px;
  border-top: 2px solid #dc2626;
}
.legend-teaser-label { font-size: 11px; font-weight: 700; color: #dc2626; letter-spacing: .1em; margin-bottom: 10px; }
.legend-teaser-list  { display: flex; flex-direction: column; gap: 6px; }
.legend-teaser-item  { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.legend-teaser-rank  { color: #dc2626; font-weight: 700; width: 24px; }
.legend-teaser-nick  { color: #eee; font-weight: 600; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.legend-teaser-pt    { color: #888; font-size: 12px; white-space: nowrap; }

/* ============================================================
   キャンペーン告知バナー
   ============================================================ */
.campaign-notice-bar {
  background: #c2410c;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  padding: 10px 0;
  text-align: center;
  letter-spacing: .02em;
  line-height: 1.6;
}

/* ============================================================
   広告枠
   ============================================================ */
.ad-slot { padding: 20px 0; }
.ad-slot-top-feed { background: #f7f7f7; border-top: 1px solid #e8e8e8; border-bottom: 1px solid #e8e8e8; }
.ad-slot img { width: 100%; height: auto; display: block; border-radius: 4px; }

/* ============================================================
   レスポンシブ追加
   ============================================================ */
@media (max-width: 768px) {
  .legend-item { padding: 12px 14px; gap: 10px; }
  .legend-pt-value { font-size: 18px; }
  .legend-nick { font-size: 15px; }
}

/* ============================================================
   認証フォーム・ヘッダーユーザー表示
   ============================================================ */
.auth-form { margin-top: 24px; display: flex; flex-direction: column; gap: 16px; }
.auth-required { color: #dc2626; }
.auth-terms { font-size: 12px; color: #888; line-height: 1.7; }
.auth-terms a { color: #dc2626; }
.auth-switch { margin-top: 20px; text-align: center; font-size: 14px; color: #666; }
.auth-switch a { color: #dc2626; font-weight: 700; }
.auth-forgot { font-size: 13px; color: #888; }
.auth-forgot:hover { color: #dc2626; }

.header-user-info {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}
.header-user-nick {
  font-size: 13px;
  color: #eee;
  font-weight: 600;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.header-logout-link {
  font-size: 12px;
  color: #666;
  transition: color .15s;
}
.header-logout-link:hover { color: #dc2626; }
.header-btn-sub {
  flex-shrink: 0;
  padding: 10px 16px;
  font-size: 13px;
}

@media (max-width: 768px) {
  .header-user-info { display: none; }
  .header-btn-sub   { display: none; }
}

/* ============================================================
   ページ内アクションボタン行
   ============================================================ */
.page-action-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 20px;
  margin-bottom: 8px;
}

/* 投稿数バー（トップページ） */
.header-post-count-bar {
  background: #111;
  border-bottom: 1px solid #222;
}

/* マイページ：ログイン誘導ガイド */
.mypage-login-guide {
  background: #f7f7f7;
  border: 1px solid #e8e8e8;
  border-radius: 4px;
  padding: 16px 20px;
  margin-top: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.mypage-login-guide-text {
  font-size: 13px;
  color: #666;
  flex: 1;
  line-height: 1.7;
}

@media (max-width: 768px) {
  .page-action-row { gap: 8px; }
  .page-action-row .btn { font-size: 13px; padding: 10px 16px; }
  .mypage-login-guide { flex-direction: column; align-items: flex-start; }
}

/* FV認証ガイド */
.fv-auth-guide {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.fv-auth-note {
  width: 100%;
  font-size: 12px;
  color: #888;
  margin-top: 4px;
}

@media (max-width: 768px) {
  .fv-auth-guide .btn { flex: 1; text-align: center; }
}

/* マイページ：ゲスト案内 */
.mypage-guest-notice {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  background: #f7f7f7;
  border: 1px solid #e8e8e8;
  border-left: 4px solid #dc2626;
  border-radius: 4px;
  padding: 14px 18px;
  margin-top: 20px;
  font-size: 14px;
  color: #555;
}
