html {
  overflow-x: hidden;
}

body {
  overflow-x: hidden;
  color: #000;
  background:
    repeating-linear-gradient(45deg, transparent 0 10px, rgba(255, 0, 255, 0.18) 10px 12px),
    radial-gradient(circle at 8px 8px, rgba(255, 255, 0, 0.5) 0 1px, transparent 2px),
    linear-gradient(90deg, rgba(0, 0, 128, 0.06) 1px, transparent 1px),
    linear-gradient(rgba(0, 0, 128, 0.06) 1px, transparent 1px),
    #9cc;
  background-size: 16px 16px;
  font-family: "MS PGothic", "Osaka", "Hiragino Kaku Gothic ProN", "Noto Sans JP", sans-serif;
}

.retro-shell {
  width: min(100% - 1rem, 62rem);
  max-width: none;
  padding: 0.75rem 0.5rem 1.25rem;
}

.retro-header,
.retro-box {
  border: 3px ridge #fff;
  background: #ffffcc;
}

.retro-header {
  margin-bottom: 0.75rem;
  padding: 0.75rem;
  text-align: center;
}

.retro-warning {
  margin: 0 0 0.5rem;
  color: #f00;
  background: #ff0;
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.4;
}

.retro-title-row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: center;
}

.retro-logo {
  image-rendering: auto;
  border: 2px outset #fff;
  background: #fff;
}

.retro-kicker {
  margin: 0 0 0.2rem;
  color: #800000;
  font-size: 0.8rem;
  line-height: 1.4;
}

.retro-header h1 {
  margin: 0;
  color: #00f;
  font-size: clamp(1.45rem, 4vw, 2.1rem);
  line-height: 1.25;
  text-decoration: underline;
  text-shadow: 2px 2px 0 #ff0;
}

.retro-marquee {
  overflow: hidden;
  margin: 0.75rem 0 0;
  border: 1px inset #fff;
  background: #000;
  color: #0f0;
  font-size: 0.9rem;
  white-space: nowrap;
}

.retro-marquee span {
  display: inline-block;
  min-width: 100%;
  padding: 0.1rem 0.5rem;
  animation: retro-scroll 18s linear infinite;
}

.retro-blink {
  margin: 0.6rem 0 0;
  color: #ff0;
  background: #f00;
  font-family: "Comic Sans MS", "MS PGothic", cursive;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.5;
  animation: retro-blink 0.8s steps(2, start) infinite;
}

.retro-top-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.25rem;
  margin-bottom: 0.75rem;
  padding: 0.35rem;
  border: 2px outset #fff;
  background: #ffc;
  font-size: 0.88rem;
}

.retro-top-links a {
  padding: 0 0.4rem;
  border-right: 1px solid #800080;
  color: #00e;
}

.retro-alerts {
  display: grid;
  gap: 0.35rem;
  margin-bottom: 0.75rem;
  padding: 0.5rem;
  border: 3px dashed #f00;
  background: #ff0;
  text-align: center;
}

.retro-alerts p {
  margin: 0;
  font-family: "Comic Sans MS", "MS Mincho", cursive;
  font-weight: 700;
}

.retro-rainbow {
  color: #f00;
  animation: retro-rainbow 1.4s linear infinite;
}

.retro-spin {
  display: inline-block;
  color: #00f;
  animation: retro-tilt 1.2s ease-in-out infinite;
}

.retro-free-link {
  color: #008000;
}

.retro-sync {
  color: #800000;
  background: #fff;
  border: 1px inset #fff;
}

.retro-top-links a:last-child {
  border-right: 0;
}

.retro-grid {
  display: grid;
  grid-template-columns: 15rem minmax(0, 1fr);
  gap: 0.75rem;
}

.retro-side,
.retro-main {
  display: grid;
  gap: 0.75rem;
  align-content: start;
  min-width: 0;
}

.retro-box {
  padding: 0.75rem;
  min-width: 0;
}

.retro-box h2 {
  margin: -0.75rem -0.75rem 0.65rem;
  padding: 0.25rem 0.5rem;
  color: #ff0;
  background: #800080;
  font-size: 0.95rem;
  line-height: 1.5;
  text-align: left;
}

.retro-box p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.75;
  overflow-wrap: anywhere;
}

.retro-menu,
.retro-mini-links,
.retro-news {
  margin: 0;
  padding-left: 1.25rem;
}

.retro-menu {
  list-style: "◇ ";
}

.retro-menu li + li,
.retro-mini-links li + li,
.retro-news li + li {
  margin-top: 0.2rem;
}

.retro-menu button {
  padding: 0;
  border: 0;
  color: #0000ee;
  background: transparent;
  font: inherit;
  text-align: left;
  text-decoration: underline;
  cursor: pointer;
}

.retro-menu button:visited,
.retro-mini-links a:visited,
.retro-table a:visited {
  color: #551a8b;
}

.retro-menu button.is-active {
  color: #f00;
  font-weight: 700;
}

.retro-counter {
  display: flex;
  gap: 2px;
  margin-bottom: 0.45rem;
}

.retro-counter span {
  display: inline-grid;
  place-items: center;
  width: 1.35rem;
  height: 1.75rem;
  border: 2px inset #fff;
  color: #00ff66;
  background: #000;
  font-family: "Courier New", monospace;
  font-size: 1rem;
  line-height: 1;
}

.retro-note {
  color: #333;
  font-size: 0.78rem !important;
}

.retro-reset {
  margin-top: 0.45rem;
  padding: 0.1rem 0.5rem;
  border: 2px outset #fff;
  color: #000;
  background: #ddd;
  font: inherit;
  font-size: 0.75rem;
  cursor: pointer;
}

.retro-reset:active {
  border-style: inset;
}

.retro-under p {
  color: #f00;
  font-weight: 700;
}

.retro-mystery-links {
  margin: 0.5rem 0 0;
  padding-left: 1.25rem;
}

.retro-mystery-links a {
  color: #00e;
  font-weight: 700;
}

.retro-mystery-links li:nth-child(2) a {
  color: #f0f;
}

.retro-table-wrap {
  display: block;
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  border: 1px inset #fff;
}

.retro-table {
  width: 100%;
  min-width: 42rem;
  border-collapse: collapse;
  background: #fff;
  font-size: 0.86rem;
}

.retro-table th,
.retro-table td {
  border: 1px solid #808080;
  padding: 0.35rem 0.45rem;
  vertical-align: top;
}

.retro-table th {
  color: #fff;
  background: #000080;
  text-align: left;
}

.retro-table tr:nth-child(even) td {
  background: #e0ffff;
}

.retro-table a {
  color: #0000ee;
  font-weight: 700;
}

.retro-category {
  white-space: nowrap;
  color: #800000;
  font-weight: 700;
}

.retro-date {
  white-space: nowrap;
  font-family: "Courier New", monospace;
}

.retro-banner-area {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  background: #ffccff;
}

.retro-banner {
  display: inline-grid;
  place-items: center;
  width: 11rem;
  min-height: 2rem;
  border: 2px outset #fff;
  color: #ffff00;
  background: #000080;
  font-family: "Courier New", monospace;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
}

.retro-banner--mikan {
  color: #000;
  background: #ffcc66;
}

.retro-banner--edu {
  color: #fff;
  background: #006400;
}

.retro-banner--tech {
  color: #fff;
  background: #800080;
}

.retro-guestbook {
  display: grid;
  gap: 0.35rem;
}

.retro-guestbook p {
  padding: 0.35rem 0.45rem;
  border: 1px dotted #800080;
  background: #fff;
}

.retro-local-footer {
  margin-top: 0.75rem;
  padding: 0.6rem;
  border: 3px ridge #fff;
  color: #000;
  background: #ffc;
  text-align: center;
  font-size: 0.8rem;
}

.retro-local-footer p {
  margin: 0.15rem 0;
}

@keyframes retro-scroll {
  from {
    transform: translateX(100%);
  }

  to {
    transform: translateX(-100%);
  }
}

@keyframes retro-blink {
  50% {
    visibility: hidden;
  }
}

@keyframes retro-rainbow {
  0% {
    color: #f00;
  }

  20% {
    color: #f0f;
  }

  40% {
    color: #00f;
  }

  60% {
    color: #008000;
  }

  80% {
    color: #f60;
  }

  100% {
    color: #f00;
  }
}

@keyframes retro-tilt {
  0%, 100% {
    transform: rotate(-2deg) scale(1);
  }

  50% {
    transform: rotate(2deg) scale(1.08);
  }
}

@media (prefers-reduced-motion: reduce) {
  .retro-marquee span,
  .retro-blink,
  .retro-rainbow,
  .retro-spin {
    animation: none;
  }
}

@media (max-width: 760px) {
  .retro-grid {
    grid-template-columns: 1fr;
  }

  .retro-title-row {
    align-items: flex-start;
  }

  .retro-logo {
    width: 48px;
    height: 48px;
  }

  .retro-shell {
    width: min(100% - 0.5rem, 62rem);
    padding-top: 4rem;
  }
}
