@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;500;700&display=swap');

:root {
  --dark: #0d0d1a;
  --card: rgba(255,255,255,0.05);
  --card-border: rgba(255,255,255,0.1);
  --accent: #e94560;
  --accent2: #f5a623;
  --text: #f0f0f0;
  --text-muted: #888;
  --radius: 12px;
  --shadow: 0 8px 32px rgba(0,0,0,0.4);
}

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

body {
  font-family: 'Noto Sans JP', system-ui, sans-serif;
  background: var(--dark);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.7;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse at 15% 40%, rgba(233,69,96,.07) 0%, transparent 55%),
    radial-gradient(ellipse at 85% 10%, rgba(245,166,35,.05) 0%, transparent 55%);
  pointer-events: none;
  z-index: 0;
}

/* ヘッダー */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13,13,26,.9);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(233,69,96,.25);
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-size: 18px;
  font-weight: 700;
}

.logo-cat { font-size: 24px; animation: blink 4s ease-in-out infinite; }
@keyframes blink { 0%,90%,100%{transform:scaleY(1);} 95%{transform:scaleY(.1);} }

.logo-text {
  background: linear-gradient(135deg, #fff, var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.logo-badge {
  font-size: 11px;
  background: rgba(233,69,96,.2);
  border: 1px solid rgba(233,69,96,.4);
  color: var(--accent);
  padding: 2px 8px;
  border-radius: 20px;
  font-weight: 600;
}

.header-nav { display: flex; align-items: center; gap: 16px; }
.header-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  transition: color .2s;
}
.header-nav a:hover { color: var(--text); }

/* コンテナ */
.container {
  max-width: 860px;
  margin: 0 auto;
  padding: 32px 20px;
  position: relative;
  z-index: 1;
}

/* ヒーロー */
.hero {
  text-align: center;
  padding: 48px 20px 32px;
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: clamp(28px, 6vw, 48px);
  font-weight: 700;
  background: linear-gradient(135deg, #fff 30%, var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
}

.hero p {
  color: var(--text-muted);
  font-size: 16px;
  max-width: 500px;
  margin: 0 auto 28px;
}

/* 検索・フィルター */
.filters {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 28px;
  align-items: center;
}

.search-input {
  flex: 1;
  min-width: 200px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px;
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
  padding: 10px 14px;
  outline: none;
  transition: border-color .2s;
}
.search-input::placeholder { color: var(--text-muted); }
.search-input:focus { border-color: rgba(233,69,96,.5); }

.tag-filter {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all .2s;
  border: 1px solid transparent;
}

.tag-feature  { background: rgba(46,204,113,.15);  color: #2ecc71; border-color: rgba(46,204,113,.3); }
.tag-fix      { background: rgba(233,69,96,.15);   color: #e94560; border-color: rgba(233,69,96,.3); }
.tag-improve  { background: rgba(52,152,219,.15);  color: #3498db; border-color: rgba(52,152,219,.3); }
.tag-security { background: rgba(245,166,35,.15);  color: #f5a623; border-color: rgba(245,166,35,.3); }
.tag-other    { background: rgba(255,255,255,.08); color: var(--text-muted); border-color: rgba(255,255,255,.15); }
.tag:hover, .tag.active { opacity: .8; transform: translateY(-1px); }

/* 更新カード */
.update-card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
  transition: transform .2s, border-color .2s;
  animation: slideUp .4s ease both;
  text-decoration: none;
  display: block;
  color: inherit;
}

.update-card:hover {
  transform: translateY(-2px);
  border-color: rgba(233,69,96,.3);
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.version-badge {
  font-size: 13px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent), #c0392b);
  color: white;
  padding: 3px 10px;
  border-radius: 6px;
  white-space: nowrap;
}

.card-date {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}

.card-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text);
}

.card-body {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 14px;
}

/* 詳細ページ */
.post-header {
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--card-border);
}

.post-title {
  font-size: clamp(22px, 5vw, 36px);
  font-weight: 700;
  margin: 12px 0 8px;
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  color: var(--text-muted);
  font-size: 13px;
}

.post-body {
  font-size: 16px;
  line-height: 1.9;
  color: #ddd;
}

.post-body h2 { font-size: 22px; margin: 28px 0 12px; color: var(--text); }
.post-body h3 { font-size: 18px; margin: 22px 0 10px; color: var(--text); }
.post-body p  { margin-bottom: 16px; }
.post-body ul, .post-body ol { margin: 0 0 16px 24px; }
.post-body li { margin-bottom: 6px; }
.post-body code {
  background: rgba(255,255,255,.08);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: 'Courier New', monospace;
  font-size: 14px;
}
.post-body pre {
  background: rgba(0,0,0,.4);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 10px;
  padding: 16px;
  overflow-x: auto;
  margin-bottom: 16px;
}
.post-body pre code { background: none; padding: 0; }
.post-body blockquote {
  border-left: 3px solid var(--accent);
  padding-left: 16px;
  color: var(--text-muted);
  margin-bottom: 16px;
}
.post-body a { color: var(--accent); }
.post-body hr { border: none; border-top: 1px solid var(--card-border); margin: 24px 0; }

/* ボタン */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border: none;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
  text-decoration: none;
}
.btn-primary {
  background: linear-gradient(135deg, var(--accent), #c0392b);
  color: white;
  box-shadow: 0 4px 14px rgba(233,69,96,.35);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(233,69,96,.5); }
.btn-secondary {
  background: rgba(255,255,255,.08);
  color: var(--text);
  border: 1px solid rgba(255,255,255,.15);
}
.btn-secondary:hover { background: rgba(255,255,255,.14); }
.btn-danger {
  background: rgba(233,69,96,.15);
  color: var(--accent);
  border: 1px solid rgba(233,69,96,.3);
}
.btn-danger:hover { background: rgba(233,69,96,.25); }

/* フォーム */
.form-group { margin-bottom: 18px; }
.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px;
  color: var(--text);
  font-family: inherit;
  font-size: 15px;
  padding: 12px 14px;
  outline: none;
  transition: border-color .2s;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--text-muted); }
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus { border-color: rgba(233,69,96,.5); }
.form-group textarea { min-height: 200px; resize: vertical; }
.form-group select option { background: #1a1a2e; }

/* アラート */
.alert {
  padding: 12px 16px;
  border-radius: 10px;
  margin-bottom: 16px;
  font-size: 14px;
}
.alert-success { background: rgba(46,204,113,.12); border: 1px solid rgba(46,204,113,.3); color: #7deba5; }
.alert-error   { background: rgba(233,69,96,.15);  border: 1px solid rgba(233,69,96,.3);  color: #ff8a9a; }

/* 購読ボックス */
.subscribe-box {
  background: linear-gradient(135deg, rgba(233,69,96,.1), rgba(245,166,35,.08));
  border: 1px solid rgba(233,69,96,.25);
  border-radius: var(--radius);
  padding: 28px;
  text-align: center;
  margin: 32px 0;
}
.subscribe-box h3 { font-size: 20px; margin-bottom: 8px; }
.subscribe-box p  { color: var(--text-muted); font-size: 14px; margin-bottom: 18px; }
.subscribe-form   { display: flex; gap: 10px; max-width: 420px; margin: 0 auto; }
.subscribe-form input {
  flex: 1;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
  padding: 10px 14px;
  outline: none;
}
.subscribe-form input:focus { border-color: rgba(233,69,96,.5); }

/* ページネーション */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 32px;
  flex-wrap: wrap;
}
.page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  background: rgba(255,255,255,.06);
  color: var(--text-muted);
  border: 1px solid rgba(255,255,255,.1);
  transition: all .2s;
}
.page-btn:hover, .page-btn.active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

/* 管理画面 */
.admin-header {
  background: rgba(233,69,96,.08);
  border: 1px solid rgba(233,69,96,.2);
  border-radius: 10px;
  padding: 14px 18px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-nav { display: flex; gap: 10px; flex-wrap: wrap; }

/* フッター */
.site-footer {
  border-top: 1px solid var(--card-border);
  padding: 24px;
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
  margin-top: 60px;
  position: relative;
  z-index: 1;
}
.site-footer a { color: var(--accent); text-decoration: none; }

/* RSS リンク */
.rss-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #f5a623;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  padding: 5px 10px;
  border: 1px solid rgba(245,166,35,.3);
  border-radius: 6px;
  transition: all .2s;
}
.rss-link:hover { background: rgba(245,166,35,.1); }

/* スクロールバー */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--dark); }
::-webkit-scrollbar-thumb { background: rgba(233,69,96,.4); border-radius: 3px; }

@media (max-width: 600px) {
  .site-header { padding: 0 14px; }
  .container { padding: 20px 14px; }
  .subscribe-form { flex-direction: column; }
  .filters { flex-direction: column; }
  .search-input { min-width: unset; }
}
