/* styles/widgets.css — 1999 widgets, revived. Inlined into every exported page. */

/* Blink revival (Req 5.10): <blink> is dead, a 1 Hz CSS step animation lives on */
.gc-blink {
  display: inline-block;
  margin: 4px 0 8px;
  font-family: var(--gc-font-mono);
  font-weight: bold;
  color: var(--gc-accent);
  animation: gc-blink 1s steps(1, end) infinite;
}
@keyframes gc-blink { 50% { visibility: hidden; } }

/* Marquee revival (Req 5.9, 9.3): CSS translate instead of <marquee> */
.gc-marquee {
  overflow: hidden;
  white-space: nowrap;
  max-width: 720px;
  margin: 12px auto;
  border-top: 2px dotted var(--gc-accent);
  border-bottom: 2px dotted var(--gc-accent);
  background: rgba(0, 0, 0, 0.45);
}
.gc-marquee-text {
  display: inline-block;
  margin: 6px 0;
  padding-left: 100%;
  font-weight: bold;
  color: var(--gc-link);
  animation: gc-scroll 16s linear infinite;
}
.gc-marquee:hover .gc-marquee-text,
.gc-marquee-text[contenteditable] { animation-play-state: paused; }
@keyframes gc-scroll { to { transform: translateX(-100%); } }
@media (prefers-reduced-motion: reduce) {
  .gc-marquee { white-space: normal; }
  .gc-marquee-text { padding-left: 0; }
}

/* Under construction (Req 5.3) */
.gc-construction {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  max-width: 480px;
  margin: 10px auto;
  padding: 6px 10px;
  color: #000;
  font-family: var(--gc-font-heading);
  font-weight: 900;
  text-transform: uppercase;
  background: repeating-linear-gradient(-45deg, #ffd400 0 14px, #111 14px 28px);
  background-size: 40px 40px;
  border: 3px solid #000;
  animation: gc-hazard 1.2s linear infinite;
}
.gc-construction-text { background: #ffd400; padding: 0 8px; }
.gc-construction-icon { display: inline-block; animation: gc-dig 0.6s ease-in-out infinite alternate; }
@keyframes gc-hazard { to { background-position: 40px 0; } }
@keyframes gc-dig { to { transform: rotate(-18deg) translateY(-2px); } }

/* Hit counter odometer (Req 5.7, 10.2) */
.gc-counter-label { margin: 0 0 4px; font-size: 0.9rem; }
.gc-counter { display: inline-flex; gap: 2px; padding: 4px; background: #000; border: 2px inset #777; }
.gc-digit {
  display: inline-block;
  min-width: 1.1em;
  padding: 2px 3px;
  font-family: var(--gc-font-mono);
  font-size: 1.4rem;
  font-weight: bold;
  line-height: 1.1;
  color: #ff3b3b;
  text-shadow: 0 0 6px #ff3b3b;
  background: linear-gradient(#222, #000 50%, #222);
  border: 1px solid #444;
}

/* Guestbook (Req 5.6, 11) */
.gc-guestbook h3 { margin-top: 0; }
.gc-guestbook-form { display: grid; gap: 6px; text-align: left; }
.gc-guestbook-form label { display: grid; gap: 2px; font-size: 0.9rem; }
.gc-guestbook-form input,
.gc-guestbook-form textarea {
  font: inherit;
  color: #000;
  background: #fffbe6;
  border: 2px inset #999;
  padding: 4px;
}
.gc-guestbook-form button,
.gc-chiptune-btn {
  justify-self: center;
  font: bold 0.95rem var(--gc-font-body);
  color: #000;
  background: linear-gradient(#f4f4f4, #bdbdbd);
  border: 3px outset #ddd;
  padding: 4px 14px;
  cursor: pointer;
}
.gc-guestbook-form button:active,
.gc-chiptune-btn:active { border-style: inset; }
.gc-guestbook-entries { margin-top: 10px; text-align: left; }
.gc-guestbook-entry { padding: 6px 0; border-top: 1px dashed var(--gc-border); }
.gc-guestbook-name { font-weight: bold; color: var(--gc-accent); }
.gc-guestbook-date { margin-left: 8px; font-size: 0.8rem; opacity: 0.75; }
.gc-guestbook-message { margin: 2px 0 0; }
.gc-guestbook-empty { font-style: italic; opacity: 0.8; }

/* Chiptune (Req 6.2) */
.gc-chiptune { margin: 12px auto; }
.gc-chiptune-btn[aria-pressed="true"] { background: linear-gradient(#b6ffb0, #5fd35a); }

/* Webring footer (Req 5.8, 12) */
.gc-footer { margin-top: 18px; }
.gc-webring-nav {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 14px;
  padding: 8px 14px;
  background: var(--gc-panel);
  border: 3px double var(--gc-accent);
}
.gc-footer-credit { font-size: 0.8rem; opacity: 0.8; }

/* Cursor trail glyphs (Req 6.1) */
.gc-trail {
  position: absolute;
  z-index: 5;
  pointer-events: none;
  font-size: 18px;
  transform: translate(-50%, -50%);
  animation: gc-trail 0.9s ease-out forwards;
}
@keyframes gc-trail {
  to { opacity: 0; transform: translate(-50%, 30px) scale(0.4) rotate(40deg); }
}
