/* ==========================================================================
   旧日时光 · 2003 個人サイト風
   クリーム色サイドバー / ターコイズのタイル / LED カウンタ / 拍手
   ========================================================================== */

:root {
  --side-bg: #fff6dc;
  --side-dot: #ffe6a6;
  --main-bg: #d8f3ec;
  --main-dot: #bfe7dd;
  --panel: #fffdf7;
  --panel-head: #c6ebe2;
  --border: #7fbfb5;
  --border-dark: #4f9c90;
  --ink: #223333;
  --ink-soft: #5c6b6b;
  --link: #0000cc;
  --visited: #663399;
  --orange: #e2571e;
  --red: #c0392b;
  --led: #3dff63;
  --star: #f2a900;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 10px 0 24px;
  background-color: var(--main-bg);
  background-image:
    radial-gradient(circle at 50% 50%, var(--main-dot) 1.5px, transparent 1.6px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.55) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.55) 1px, transparent 1px);
  background-size: 16px 16px, 16px 16px, 16px 16px;
  color: var(--ink);
  font-family: "MS PGothic", "IPAMonaPGothic", "Hiragino Kaku Gothic Pro", "Microsoft YaHei",
    "PingFang SC", sans-serif;
  font-size: 13px;
  line-height: 1.7;
}

a {
  color: var(--link);
}

a:visited {
  color: var(--visited);
}

a:hover {
  color: var(--orange);
}

img {
  max-width: 100%;
  height: auto;
}

/* ---------- 全体枠 ---------- */

.site {
  display: flex;
  width: 900px;
  max-width: 100%;
  margin: 0 auto;
  border: 1px solid var(--border-dark);
  background: var(--panel);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.5), 0 6px 16px rgba(0, 0, 0, 0.12);
}

/* ---------- サイドバー ---------- */

.side {
  width: 172px;
  flex: none;
  padding: 10px 8px 16px;
  background-color: var(--side-bg);
  background-image: radial-gradient(circle at 5px 5px, var(--side-dot) 1.6px, transparent 2px);
  background-size: 14px 14px;
  border-right: 1px solid var(--border);
}

.side__title {
  margin: 0 0 8px;
  padding: 2px 0;
  text-align: center;
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--ink-soft);
  border-top: 1px solid #e6cf95;
  border-bottom: 1px solid #e6cf95;
}

.menu {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
  font-size: 12px;
}

.menu li {
  margin: 0 0 3px;
  padding: 0;
}

.menu a {
  display: block;
  padding: 1px 2px;
  color: var(--link);
  text-decoration: none;
}

.menu a::before {
  content: "◆ ";
  color: var(--orange);
  font-size: 10px;
}

.menu a:hover {
  background: #ffffff;
  color: var(--orange);
  text-decoration: underline;
}

.side__box {
  margin: 0 0 10px;
  padding: 5px 6px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid #e0c98e;
  font-size: 11px;
  line-height: 1.65;
}

.side__box p {
  margin: 0 0 3px;
}

.side__box-title {
  font-weight: bold;
  color: var(--orange);
  border-bottom: 1px dotted #d9c07e;
  margin-bottom: 4px;
}

.side__box--notice {
  background: #fffbe8;
}

.side__line {
  color: var(--ink-soft);
}

/* 工事中 */

.under-construction {
  margin: 6px 0;
  padding: 3px 4px;
  font-size: 10px;
  text-align: center;
  color: #5a4a12;
  background: repeating-linear-gradient(45deg, #ffe680 0 8px, #4a4a4a 8px 16px);
  border: 1px solid #b89b2a;
}

.under-construction span {
  display: block;
  padding: 1px 2px;
  background: #fff6cc;
}

/* 88x31 バナー */

.banner-88 {
  display: block;
  width: 88px;
  height: 31px;
  margin: 6px auto;
  padding: 2px;
  text-align: center;
  text-decoration: none;
  color: #1d3f8f;
  background: linear-gradient(#eafaf6, #bfe8df);
  border: 1px solid var(--border-dark);
  box-shadow: 1px 1px 0 #fff inset;
  font-size: 10px;
  line-height: 1.25;
  overflow: hidden;
}

.banner-88 b {
  display: block;
  font-size: 11px;
  letter-spacing: 1px;
}

.banner-88 small {
  display: block;
  font-size: 8px;
  color: #5c6b6b;
}

.banner-88:hover {
  background: linear-gradient(#fff6d8, #ffd970);
  color: var(--red);
}

/* ---------- メイン ---------- */

.main {
  flex: 1;
  min-width: 0;
  background-color: var(--main-bg);
  background-image:
    radial-gradient(circle at 50% 50%, var(--main-dot) 1.5px, transparent 1.6px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.5) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.5) 1px, transparent 1px);
  background-size: 16px 16px, 16px 16px, 16px 16px;
}

/* ヘッダー */

.banner-head {
  position: relative;
  padding: 12px 10px 8px;
  text-align: center;
  background: linear-gradient(#f4fffc, #cdeee6);
  border-bottom: 1px dashed var(--border);
}

.banner-head__row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.banner-head__title {
  margin: 0;
  font-size: 32px;
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: 5px;
  color: #1d3f8f;
  text-shadow: 2px 2px 0 #fff, -1px -1px 0 #fff, 1px -1px 0 #fff, -1px 1px 0 #fff,
    3px 4px 0 rgba(29, 63, 143, 0.25);
}

.banner-head__title a {
  color: inherit;
  text-decoration: none;
}

.banner-head__sub {
  margin: 2px 0 0;
  font-size: 11px;
  color: #3f6b8f;
  letter-spacing: 1px;
}

/* ようこそ */

.welcome {
  margin: 0;
  padding: 6px 8px;
  text-align: center;
  font-size: 11px;
  color: #2c4a4a;
  background: rgba(255, 255, 255, 0.55);
  border-bottom: 1px solid #a9d9cf;
}

.welcome .star {
  color: var(--star);
}

/* マーキー */

.marquee {
  overflow: hidden;
  padding: 2px 0;
  background: #0b3d3a;
  color: #aaf5e6;
  font-size: 11px;
  border-bottom: 1px solid #072b29;
}

.marquee span {
  display: inline-block;
  padding-left: 12%;
  white-space: nowrap;
  animation: marquee 28s linear infinite;
}

@keyframes marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-115%);
  }
}

/* カウンタ */

.counter-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 6px 8px;
  font-size: 11px;
  color: #2c4a4a;
  background: rgba(255, 255, 255, 0.45);
  border-bottom: 1px dashed var(--border);
}

.led {
  display: inline-block;
  padding: 0 6px;
  font-family: "Courier New", monospace;
  font-size: 15px;
  font-weight: bold;
  letter-spacing: 3px;
  color: var(--led);
  background: #101010;
  border: 2px inset #555;
  text-shadow: 0 0 5px var(--led);
}

.led--small {
  font-size: 11px;
  letter-spacing: 1px;
}

/* 本文エリア */

.content {
  width: 620px;
  max-width: calc(100% - 20px);
  margin: 10px auto 4px;
}

/* パネル */

.panel {
  margin: 0 0 14px;
  background: var(--panel);
  border: 1px solid var(--border);
  box-shadow: 2px 2px 0 rgba(79, 156, 144, 0.18);
}

.panel__title {
  margin: 0;
  padding: 3px 8px;
  font-size: 13px;
  font-weight: bold;
  text-align: center;
  letter-spacing: 2px;
  color: #1d4f4a;
  background: linear-gradient(#e9f9f5, var(--panel-head));
  border-bottom: 1px solid var(--border);
}

.panel__body {
  padding: 8px 10px 10px;
}

/* 更新履歴 */

.history {
  width: 100%;
  border-collapse: collapse;
  font-size: 11.5px;
}

.history th,
.history td {
  padding: 2px 6px;
  border-bottom: 1px dotted #b9dcd4;
  text-align: left;
  vertical-align: top;
}

.history th {
  font-weight: normal;
  color: #3f6b66;
  background: #f1fbf8;
  white-space: nowrap;
}

.history td.date {
  width: 86px;
  white-space: nowrap;
  color: var(--ink-soft);
}

/* 日記 */

.diary {
  padding: 0 0 10px;
  margin: 0 0 10px;
  border-bottom: 1px dashed #b9dcd4;
}

.diary:last-child {
  border-bottom: 0;
  margin-bottom: 0;
  padding-bottom: 2px;
}

.diary__date {
  font-size: 11px;
  color: var(--orange);
  font-weight: bold;
  letter-spacing: 0.5px;
}

.diary__title {
  margin: 1px 0 3px;
  font-size: 15px;
  line-height: 1.45;
}

.diary__title a {
  color: var(--link);
  text-decoration: none;
}

.diary__title a:hover {
  text-decoration: underline;
  color: var(--orange);
}

.diary__excerpt {
  margin: 0 0 4px;
  font-size: 12px;
  color: #3a4a4a;
  line-height: 1.7;
}

.diary__meta {
  margin: 0;
  font-size: 10.5px;
  color: var(--ink-soft);
}

.diary__meta a {
  color: var(--link);
}

.tag-link:not(:last-of-type)::after {
  content: "、";
  color: var(--ink-soft);
}

/* NEW! バッジ */

.new-badge {
  display: none;
  margin-left: 4px;
  padding: 0 3px;
  font-size: 9px;
  font-weight: bold;
  color: #fff;
  background: var(--red);
  vertical-align: 2px;
  animation: blink 1.1s steps(1) infinite;
}

.new-badge.is-on {
  display: inline-block;
}

@keyframes blink {
  0%,
  60% {
    opacity: 1;
  }
  61%,
  100% {
    opacity: 0.25;
  }
}

/* 記事ページ */

.entry__date {
  font-size: 11px;
  color: var(--orange);
  font-weight: bold;
}

.entry__title {
  margin: 2px 0 4px;
  font-size: 19px;
  line-height: 1.4;
  color: #1d3f8f;
}

.entry__meta {
  margin: 0 0 8px;
  font-size: 10.5px;
  color: var(--ink-soft);
  border-bottom: 1px dotted #b9dcd4;
  padding-bottom: 5px;
}

.entry__meta a {
  color: var(--link);
}

/* 本文 */

.prose {
  font-size: 13px;
  line-height: 1.85;
  color: #223333;
  overflow-wrap: anywhere;
}

.prose p {
  margin: 0 0 0.9em;
}

.prose h2,
.prose h3,
.prose h4 {
  margin: 1.2em 0 0.4em;
  line-height: 1.5;
  font-size: 14px;
  font-weight: bold;
  color: #1d4f4a;
}

.prose h2 {
  padding: 2px 8px;
  background: linear-gradient(90deg, var(--panel-head), transparent);
  border-left: 4px solid var(--border-dark);
}

.prose h3 {
  border-bottom: 1px dashed var(--border);
}

.prose a {
  color: var(--link);
}

.prose strong {
  background: linear-gradient(transparent 60%, #ffe680 60%);
}

.prose em {
  font-style: italic;
  color: #3a4a4a;
}

.prose blockquote {
  margin: 0.6em 0;
  padding: 4px 8px;
  background: #f4fbf9;
  border: 1px dashed var(--border);
  color: #3a4a4a;
}

.prose blockquote p:last-child {
  margin-bottom: 0;
}

.prose ul,
.prose ol {
  margin: 0 0 0.9em;
  padding-left: 1.5em;
}

.prose ul li::marker {
  content: "◆  ";
  color: var(--orange);
  font-size: 8px;
}

.prose img {
  display: block;
  margin: 8px auto;
  padding: 3px;
  background: #fff;
  border: 1px solid var(--border);
}

.prose hr {
  border: 0;
  border-top: 1px dashed var(--border);
  margin: 12px 0;
}

.prose code {
  padding: 0 3px;
  background: #eef8f5;
  border: 1px solid #cde8e1;
  font-family: "Courier New", monospace;
  font-size: 12px;
  color: #7a3b1d;
}

.prose pre {
  margin: 8px 0;
  padding: 6px 8px;
  overflow-x: auto;
  background: #0f2b28;
  border: 2px inset #0b1f1d;
  color: #bff5e8;
  font-family: "Courier New", monospace;
  font-size: 12px;
  line-height: 1.6;
}

.prose pre code {
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font-size: inherit;
}

.prose table {
  margin: 8px 0;
  border-collapse: collapse;
  font-size: 12px;
}

.prose th,
.prose td {
  border: 1px solid var(--border);
  padding: 2px 6px;
}

.prose th {
  background: var(--panel-head);
}

/* 拍手 */

.clap {
  margin: 16px 0 0;
  padding: 8px;
  text-align: center;
  background: #fffbe8;
  border: 1px dashed #d9c07e;
}

.clap__label {
  margin: 0 0 4px;
  font-size: 11px;
  color: #7a5a12;
}

.clap__btn {
  padding: 2px 14px;
  font-family: inherit;
  font-size: 12px;
  color: #1d3f8f;
  background: linear-gradient(#ffffff, #d9e9f7 50%, #b9d4ec);
  border: 1px solid #7c9cb8;
  border-radius: 3px;
  cursor: pointer;
  box-shadow: 1px 1px 0 #fff inset;
}

.clap__btn:hover {
  background: linear-gradient(#fffdf0, #ffe9a8 50%, #ffd970);
  color: var(--red);
}

.clap__btn:active {
  transform: translateY(1px);
}

.clap__count {
  margin: 4px 0 0;
  font-size: 11px;
  color: var(--ink-soft);
}

.clap__count b {
  color: var(--orange);
}

/* コメント */

.comments {
  margin-top: 14px;
}

.comments__title {
  margin: 0 0 6px;
  font-size: 13px;
  font-weight: bold;
  color: #1d4f4a;
}

/* ページャ */

.pager {
  margin: 10px 0 0;
  text-align: center;
  font-size: 11.5px;
  color: var(--ink-soft);
}

.pager a {
  padding: 0 4px;
  color: var(--link);
}

.pager a.is-off {
  color: #9aa;
  pointer-events: none;
}

.pager__info {
  margin: 0 6px;
  color: var(--ink-soft);
}

/* 同盟バナー */

.webring {
  margin: 14px auto 8px;
  text-align: center;
}

.webring__title {
  margin: 0 0 6px;
  font-size: 11px;
  color: #2c4a4a;
}

.webring__title .star {
  color: var(--star);
}

.webring__row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

/* フッター */

.foot {
  padding: 8px 10px 14px;
  text-align: center;
  font-size: 10.5px;
  color: #2c4a4a;
  border-top: 1px dashed var(--border);
}

.foot p {
  margin: 0 0 2px;
}

.foot a {
  color: var(--link);
}

.foot .aa {
  display: inline-block;
  margin: 4px 0;
  font-family: "IPAMonaPGothic", "MS PGothic", "Courier New", monospace;
  font-size: 11px;
  line-height: 1.2;
  color: #4f6b66;
  white-space: pre;
  text-align: left;
}

/* ---------- 看板娘 ---------- */

.mascot {
  position: fixed;
  right: 8px;
  bottom: 6px;
  z-index: 30;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  pointer-events: none;
}

.mascot__bubble {
  transform-origin: 78% 100%;
  animation: bubble-in 0.45s steps(5) both;
}

@keyframes bubble-in {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.94);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.mascot__bubble {
  position: relative;
  width: 174px;
  padding: 6px 8px;
  background: #fffdf5;
  border: 1px solid var(--border-dark);
  border-radius: 8px;
  font-size: 11px;
  line-height: 1.6;
  color: #223333;
  pointer-events: auto;
  box-shadow: 2px 2px 0 rgba(79, 156, 144, 0.2);
}

.mascot__bubble::before {
  content: attr(data-name);
  display: block;
  font-size: 10px;
  color: var(--orange);
  border-bottom: 1px dotted #e0c98e;
  margin-bottom: 2px;
}

.mascot__bubble::after {
  content: "";
  position: absolute;
  right: 40px;
  bottom: -7px;
  width: 10px;
  height: 10px;
  background: #fffdf5;
  border-right: 1px solid var(--border-dark);
  border-bottom: 1px solid var(--border-dark);
  transform: rotate(45deg);
}

.mascot__name {
  display: none;
}

.mascot__text {
  margin: 0;
  min-height: 3.2em;
}

.mascot__close {
  position: absolute;
  top: 2px;
  right: 4px;
  padding: 0;
  border: 0;
  background: none;
  color: #999;
  font-size: 11px;
  cursor: pointer;
}

.mascot__close:hover {
  color: var(--red);
}

.mascot__img {
  width: 230px;
  height: auto;
  image-rendering: auto;
  filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.18));
  pointer-events: auto;
  cursor: pointer;
  filter: drop-shadow(2px 2px 0 rgba(0, 0, 0, 0.12));
}

.mascot.is-hidden {
  display: none;
}

/* ---------- レスポンシブ ---------- */

@media (max-width: 900px) {
  body {
    padding: 0;
  }

  .site {
    display: block;
    width: 100%;
    border: 0;
    box-shadow: none;
  }

  .side {
    width: 100%;
    border-right: 0;
    border-bottom: 1px solid var(--border);
    padding: 6px 8px;
  }

  .side__box,
  .banner-88,
  .under-construction {
    display: none;
  }

  .menu {
    display: flex;
    flex-wrap: wrap;
    gap: 2px 10px;
    margin: 0;
  }

  .menu a::before {
    content: "";
  }

  .banner-head__title {
    font-size: 24px;
    letter-spacing: 2px;
  }

  .mascot {
    display: none;
  }
}

@media (max-width: 480px) {
  .counter-bar,
  .welcome {
    font-size: 10px;
  }

  .content {
    width: auto;
    padding: 0 6px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

@media print {
  .mascot,
  .marquee,
  .webring,
  .clap,
  .side {
    display: none !important;
  }
}

/* ==========================================================================
   灯绳开关 / 关灯模式
   ========================================================================== */

.lamp {
  position: fixed;
  top: 0;
  right: 18px;
  z-index: 60;
  pointer-events: none;
}

.lamp__switch {
  position: relative;
  display: block;
  width: 44px;
  height: 118px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  pointer-events: auto;
}

.lamp__rose {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 18px;
  height: 7px;
  background: #d8ccb0;
  border: 1px solid #8a7d5f;
  border-radius: 2px;
  box-shadow: 0 1px 0 #fff inset;
}

.lamp__cord {
  position: absolute;
  top: 7px;
  left: 50%;
  width: 2px;
  height: 68px;
  margin-left: -1px;
  background: repeating-linear-gradient(to bottom, #d9c9a0 0 5px, #b3a173 5px 10px);
  transition: height 0.18s ease-out;
}

.lamp__knob {
  position: absolute;
  top: 73px;
  left: 50%;
  width: 16px;
  height: 24px;
  margin-left: -8px;
  border-radius: 7px;
  background: radial-gradient(circle at 50% 32%, #fff7cf, #e0bf55 58%, #b5912c);
  border: 1px solid #8a6d1f;
  box-shadow: 0 0 10px rgba(255, 220, 120, 0.75), 0 2px 0 rgba(0, 0, 0, 0.15);
  transition: top 0.18s ease-out, box-shadow 0.25s;
}

.lamp.is-pulling .lamp__cord {
  height: 84px;
}

.lamp.is-pulling .lamp__knob {
  top: 89px;
}

html.is-dark .lamp__knob {
  box-shadow: 0 0 18px rgba(255, 236, 160, 1), 0 0 44px rgba(255, 210, 90, 0.55);
}

@media (max-width: 900px) {
  .lamp {
    right: 4px;
    transform: scale(0.8);
    transform-origin: top right;
  }
}

@media print {
  .lamp {
    display: none !important;
  }
}

/* ---------- 关灯模式 ---------- */

html.is-dark {
  --side-bg: #17140e;
  --side-dot: #211c12;
  --main-bg: #0d1514;
  --main-dot: #14201d;
  --panel: #121918;
  --panel-head: #1c3330;
  --border: #2a403b;
  --border-dark: #3d5a54;
  --ink: #cfd9d5;
  --ink-soft: #93a49f;
  --link: #86b6ff;
  --visited: #c39be8;
  --orange: #ff9a6b;
  --red: #ff6b6b;
  --star: #ffcf5c;
}

html.is-dark body {
  background-color: #0b100f;
  background-image:
    radial-gradient(circle at 50% 50%, #16211e 1.5px, transparent 1.6px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px);
}

html.is-dark .site {
  background: var(--panel);
  border-color: #26403b;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.04), 0 8px 24px rgba(0, 0, 0, 0.6);
}

html.is-dark .side {
  border-right-color: #26403b;
}

html.is-dark .side__title {
  border-color: #3a3323;
  color: #a99b7e;
}

html.is-dark .menu a:hover {
  background: #1d2624;
}

html.is-dark .side__box {
  background: rgba(255, 255, 255, 0.04);
  border-color: #3a3323;
}

html.is-dark .side__box--notice {
  background: #1b1a12;
}

html.is-dark .under-construction {
  color: #e6d9a8;
}

html.is-dark .under-construction span {
  background: #2a2618;
}

html.is-dark .banner-88 {
  background: linear-gradient(#1b2c28, #152421);
  border-color: #3d5a54;
  color: #9fc4ff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08) inset;
}

html.is-dark .banner-88 small {
  color: #93a49f;
}

html.is-dark .banner-head {
  background: linear-gradient(#101b19, #0b1312);
  border-bottom-color: #26403b;
}

html.is-dark .banner-head__title {
  color: #8fb6ff;
  text-shadow: 2px 2px 0 #050908, -1px -1px 0 #050908, 1px -1px 0 #050908,
    -1px 1px 0 #050908, 3px 4px 0 rgba(0, 0, 0, 0.5);
}

html.is-dark .banner-head__sub {
  color: #7ea3c4;
}

html.is-dark .welcome {
  background: rgba(255, 255, 255, 0.04);
  border-bottom-color: #24403b;
  color: #b6c8c3;
}

html.is-dark .marquee {
  background: #05100e;
  color: #7fd9c6;
  border-bottom-color: #0a1a17;
}

html.is-dark .counter-bar {
  background: rgba(255, 255, 255, 0.03);
  border-bottom-color: #26403b;
  color: #b6c8c3;
}

html.is-dark .panel {
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.35);
}

html.is-dark .panel__title {
  background: linear-gradient(#17292a, #1c3330);
  color: #a8d8ce;
  border-bottom-color: #2a403b;
}

html.is-dark .history th {
  background: #16201f;
  color: #8fb5ad;
}

html.is-dark .history th,
html.is-dark .history td {
  border-bottom-color: #26403b;
}

html.is-dark .diary {
  border-bottom-color: #26403b;
}

html.is-dark .diary__excerpt {
  color: #b9c7c3;
}

html.is-dark .entry__meta {
  border-bottom-color: #26403b;
}

html.is-dark .prose {
  color: #c6d2ce;
}

html.is-dark .prose h2,
html.is-dark .prose h3,
html.is-dark .prose h4 {
  color: #a8d8ce;
}

html.is-dark .prose h2 {
  background: linear-gradient(90deg, #1c3330, transparent);
}

html.is-dark .prose blockquote {
  background: #15201e;
  border-color: #2a403b;
  color: #b9c7c3;
}

html.is-dark .prose img {
  background: #0f1615;
  border-color: #2a403b;
}

html.is-dark .prose code {
  background: #1a2422;
  border-color: #2a3c38;
  color: #f0b98a;
}

html.is-dark .prose strong {
  background: linear-gradient(transparent 60%, rgba(255, 214, 64, 0.28) 60%);
}

html.is-dark .clap {
  background: #1a1810;
  border-color: #4a3f22;
}

html.is-dark .clap__label {
  color: #d8c184;
}

html.is-dark .clap__btn {
  background: linear-gradient(#243130, #1b2726 50%, #16201f);
  border-color: #3d5a54;
  color: #9fc4ff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

html.is-dark .clap__btn:hover {
  background: linear-gradient(#2a2620, #241f14);
  color: #ffcf5c;
}

html.is-dark .comments__title,
html.is-dark .panel__title {
  color: #a8d8ce;
}

html.is-dark .foot {
  border-top-color: #26403b;
  color: #a9bbb6;
}

html.is-dark .foot .aa {
  color: #6f8b85;
}

html.is-dark .mascot__bubble {
  background: #161d1c;
  border-color: #3d5a54;
  color: #d7e0dc;
}

html.is-dark .mascot__bubble::before {
  border-bottom-color: #3a3323;
}

html.is-dark .mascot__bubble::after {
  background: #161d1c;
  border-right-color: #3d5a54;
  border-bottom-color: #3d5a54;
}

html.is-dark .lamp__rose {
  background: #6d6450;
  border-color: #2a2418;
}

html.is-dark ::-webkit-scrollbar-track {
  background-color: #101716;
  background-image: none;
}

html.is-dark ::-webkit-scrollbar-thumb {
  background: #2a3b37;
  border-color: #0b100f;
  box-shadow: inset 1px 1px 0 #3d5a54;
}

html.is-dark .main {
  background-color: #0f1615;
  background-image:
    radial-gradient(circle at 50% 50%, #16211e 1.5px, transparent 1.6px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px);
}

/* ==========================================================================
   霓虹辉光
   ========================================================================== */

.foot__beian {
  font-size: 10.5px;
}

.foot__top {
  margin-top: 6px;
  font-size: 10.5px;
}

html.neon .banner-head__title {
  text-shadow:
    2px 2px 0 #fff,
    -1px -1px 0 #fff,
    1px -1px 0 #fff,
    -1px 1px 0 #fff,
    3px 4px 0 rgba(29, 63, 143, 0.25),
    0 0 6px rgba(120, 210, 255, 0.9),
    0 0 18px rgba(90, 170, 255, 0.7),
    0 0 42px rgba(60, 120, 255, 0.45);
}

html.is-dark.neon .banner-head__title {
  text-shadow:
    2px 2px 0 #050908,
    -1px -1px 0 #050908,
    1px -1px 0 #050908,
    -1px 1px 0 #050908,
    0 0 6px rgba(120, 210, 255, 0.95),
    0 0 20px rgba(90, 170, 255, 0.8),
    0 0 48px rgba(60, 120, 255, 0.5);
}

html.neon .panel {
  border-color: rgba(90, 200, 190, 0.55);
  box-shadow:
    2px 2px 0 rgba(79, 156, 144, 0.18),
    0 0 10px rgba(90, 200, 190, 0.25),
    inset 0 0 18px rgba(90, 200, 190, 0.06);
}

html.is-dark.neon .panel {
  border-color: rgba(90, 220, 205, 0.45);
  box-shadow:
    2px 2px 0 rgba(0, 0, 0, 0.35),
    0 0 14px rgba(70, 220, 200, 0.28),
    inset 0 0 22px rgba(70, 220, 200, 0.07);
}

html.neon .panel__title {
  text-shadow: 0 0 6px rgba(120, 230, 215, 0.7), 0 0 16px rgba(120, 230, 215, 0.35);
}

html.neon .led {
  text-shadow: 0 0 6px #3dff63, 0 0 14px rgba(61, 255, 99, 0.8), 0 0 30px rgba(61, 255, 99, 0.5);
  box-shadow: 0 0 10px rgba(61, 255, 99, 0.45), inset 0 0 6px rgba(61, 255, 99, 0.25);
}

html.neon .marquee span {
  text-shadow: 0 0 6px rgba(127, 217, 198, 0.9), 0 0 20px rgba(127, 217, 198, 0.5);
}

html.neon .new-badge {
  box-shadow: 0 0 8px rgba(255, 107, 107, 0.85);
}

html.neon .mascot__bubble {
  box-shadow: 2px 2px 0 rgba(79, 156, 144, 0.2), 0 0 16px rgba(90, 200, 190, 0.35);
}

html.neon .diary__title a:hover,
html.neon .menu a:hover,
html.neon .prose a:hover,
html.neon .foot a:hover,
html.neon .webring__title {
  text-shadow: 0 0 8px currentColor;
}

html.neon .lamp__knob {
  box-shadow: 0 0 18px rgba(255, 236, 160, 1), 0 0 46px rgba(255, 210, 90, 0.6);
}

.pager-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 6px 14px;
  font-size: 11.5px;
}

/* ==========================================================================
   登录 / 注册等认证页面（覆盖 gateway_fragments/layout.html）
   ========================================================================== */

body.retro-auth {
  min-height: 100vh;
  padding: 0 0 34px;
  background-color: var(--main-bg);
  background-image:
    radial-gradient(circle at 50% 50%, var(--main-dot) 1.5px, transparent 1.6px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.5) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.5) 1px, transparent 1px);
  background-size: 16px 16px;
}

.auth-shell {
  width: 560px;
  max-width: calc(100% - 20px);
  margin: 26px auto 40px;
}

.auth-head {
  padding: 8px 0 4px;
  text-align: center;
}

.auth-title {
  display: inline-block;
  font-size: 30px;
  font-weight: 900;
  letter-spacing: 5px;
  color: #1d3f8f;
  text-decoration: none;
  text-shadow: 2px 2px 0 #fff, -1px -1px 0 #fff, 1px -1px 0 #fff, -1px 1px 0 #fff,
    3px 4px 0 rgba(29, 63, 143, 0.25);
}

.auth-sub {
  margin: 4px 0 0;
  font-size: 11px;
  letter-spacing: 1px;
  color: #3f6b8f;
}

.auth-panel {
  margin: 10px 0 0;
  padding: 14px 18px 16px;
  background: var(--panel);
  border: 1px solid var(--border);
  box-shadow: 2px 2px 0 rgba(79, 156, 144, 0.18);
}

.auth-foot {
  margin: 10px 0 0;
  text-align: center;
  font-size: 11px;
  color: #2c4a4a;
}

/* Halo 网关表单样式覆写 */

.retro-auth .halo-logo {
  display: none;
}

.retro-auth .gateway-wrapper {
  width: auto;
  max-width: none;
  margin: 0;
  padding: 0;
}

.retro-auth .halo-form-wrapper {
  margin: 0;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.retro-auth .form-title {
  margin: 0 0 10px;
  font-size: 15px;
  color: #1d4f4a;
  text-align: center;
}

.retro-auth .halo-form .form-item {
  margin-bottom: 10px;
}

.retro-auth .halo-form .form-item label {
  font-size: 12px;
  color: var(--ink-soft);
}

.retro-auth .halo-form .form-input input {
  width: 100%;
  padding: 4px 6px;
  background: #fffdf7;
  border: 1px solid var(--border);
  border-radius: 0;
  color: #223333;
  font-family: inherit;
  font-size: 13px;
}

.retro-auth .halo-form .form-input input:focus {
  outline: 2px solid rgba(79, 156, 144, 0.35);
  border-color: var(--border-dark);
}

.retro-auth .halo-form button[type="submit"],
.retro-auth .halo-form #emailCodeSendButton {
  padding: 3px 16px;
  background: linear-gradient(#ffffff, #d9e9f7 50%, #b9d4ec);
  border: 1px solid #7c9cb8;
  border-radius: 3px;
  color: #1d3f8f;
  font-family: inherit;
  font-size: 13px;
  cursor: pointer;
}

.retro-auth .halo-form button[type="submit"]:hover,
.retro-auth .halo-form #emailCodeSendButton:hover {
  background: linear-gradient(#fffdf0, #ffe9a8 50%, #ffd970);
  color: #c0392b;
}

.retro-auth .alert {
  border-radius: 0;
  font-size: 11px;
}

.retro-auth .halo-form .form-item .alert {
  margin: 3px 0 0;
}

.retro-auth .login-notice-content,
.retro-auth .returntosite-content {
  font-size: 11px;
}

html.is-dark body.retro-auth {
  background-color: #0b100f;
  background-image:
    radial-gradient(circle at 50% 50%, #16211e 1.5px, transparent 1.6px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px);
}

html.is-dark .auth-title {
  color: #8fb6ff;
  text-shadow: 2px 2px 0 #050908, -1px -1px 0 #050908, 1px -1px 0 #050908,
    -1px 1px 0 #050908, 3px 4px 0 rgba(0, 0, 0, 0.5);
}

html.is-dark .auth-sub,
html.is-dark .auth-foot {
  color: #a9bbb6;
}

html.is-dark .auth-panel {
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.35);
}

html.is-dark .retro-auth .form-title {
  color: #a8d8ce;
}

html.is-dark .retro-auth .halo-form .form-input input {
  background: #101716;
  border-color: #2a403b;
  color: #cfd9d5;
}

html.is-dark .retro-auth .halo-form button[type="submit"],
html.is-dark .retro-auth .halo-form #emailCodeSendButton {
  background: linear-gradient(#243130, #1b2726 50%, #16201f);
  border-color: #3d5a54;
  color: #9fc4ff;
}

html.neon .auth-title {
  text-shadow: 2px 2px 0 #fff, -1px -1px 0 #fff, 1px -1px 0 #fff, -1px 1px 0 #fff,
    0 0 6px rgba(120, 210, 255, 0.9), 0 0 18px rgba(90, 170, 255, 0.7), 0 0 42px rgba(60, 120, 255, 0.45);
}

html.is-dark.neon .auth-title {
  text-shadow: 2px 2px 0 #050908, -1px -1px 0 #050908, 1px -1px 0 #050908,
    -1px 1px 0 #050908, 0 0 6px rgba(120, 210, 255, 0.95), 0 0 20px rgba(90, 170, 255, 0.8),
    0 0 48px rgba(60, 120, 255, 0.5);
}

/* 认证表单：边框放在 Halo 的 .form-input 容器上，避免双层边框 */
.retro-auth .halo-form .form-input {
  height: 2.4em;
  padding: 0 6px;
  background: #fffdf7;
  border: 1px solid var(--border);
  border-radius: 0;
}

.retro-auth .halo-form .form-input:focus-within {
  border-color: var(--border-dark);
  outline: 2px solid rgba(79, 156, 144, 0.25);
}

.retro-auth .halo-form .form-item input {
  border: 0;
  background: none;
  padding: 0;
  color: #223333;
  font-family: inherit;
  font-size: 13px;
}

html.is-dark .retro-auth .halo-form .form-input {
  background: #101716;
  border-color: #2a403b;
}

html.is-dark .retro-auth .halo-form .form-item input {
  color: #cfd9d5;
}

/* 日记 / 文章模板 */

.diary-date {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 0 0 2px;
}

.diary-date__ymd {
  font-size: 15px;
  font-weight: bold;
  letter-spacing: 1px;
  color: var(--orange);
}

.diary-date__week {
  font-size: 11px;
  color: var(--ink-soft);
}

.entry__title--lg {
  font-size: 22px;
  line-height: 1.35;
}

.entry__excerpt {
  margin: 0 0 6px;
  padding-bottom: 4px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--ink-soft);
  border-bottom: 1px dotted #b9dcd4;
}

.entry__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 10px 0 0;
}

.post-cover {
  margin: 0 0 12px;
}

.post-cover__link {
  display: block;
  overflow: hidden;
  padding: 4px;
  background: #fff;
  border: 1px solid var(--border);
}

.post-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cover--16x9 .post-cover__link {
  aspect-ratio: 16 / 9;
}

.cover--4x3 .post-cover__link {
  aspect-ratio: 4 / 3;
}

.cover--auto .post-cover__link {
  aspect-ratio: auto;
}

.cover--auto img {
  height: auto;
}

html.is-dark .post-cover__link {
  background: #0f1615;
  border-color: #2a403b;
}

html.is-dark .entry__excerpt {
  border-bottom-color: #26403b;
}

/* 投稿模板：作者卡片 */

.author-card {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--border);
}

.author-card__avatar {
  width: 44px;
  height: 44px;
  flex: none;
  border-radius: 50%;
  border: 1px solid var(--border-dark);
  background: #fffdf7;
  object-fit: cover;
}

.author-card__name {
  margin: 0;
  font-size: 13px;
}

.author-card__name a {
  font-weight: bold;
}

.author-card__badge {
  display: inline-block;
  margin-left: 6px;
  padding: 0 5px;
  font-size: 10px;
  color: #fff;
  background: var(--orange);
  border-radius: 2px;
  vertical-align: 1px;
}

.author-card__bio {
  margin: 3px 0 0;
  font-size: 11px;
  color: var(--ink-soft);
}

html.is-dark .author-card {
  background: rgba(255, 255, 255, 0.04);
}

html.is-dark .author-card__avatar {
  background: #101716;
}
