/* The Labeler — all styling, one file.
   No external requests (self-hosted font below), so a strict CSP with
   style-src 'self' works. Committed dark theme: pure black to match the
   thermal-printer aesthetic. */

/* ---- Self-hosted display font (replaces Google Fonts) ---- */
@font-face {
  font-family: 'Bebas Neue';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/bebas-neue-latin.woff2') format('woff2');
}

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

:root {
  --bg: #000000;
  --fg: #ffffff;
  --accent: #ffd700;
  --muted: rgba(255, 255, 255, 0.6);
  --hairline: rgba(255, 255, 255, 0.1);
  --display: 'Bebas Neue', 'Arial Narrow', sans-serif;
  --body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--body);
  background: var(--bg);
  color: var(--fg);
  line-height: 1.6;
  min-height: 100vh;
}

/* ---- Accessibility: skip link + focus ---- */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: #000;
  padding: 10px 16px;
  z-index: 100;
  font-weight: 600;
}
.skip-link:focus {
  left: 8px;
  top: 8px;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* ---- Typography ---- */
h1 {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.05;
}

h2,
h3 {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: 0.02em;
}

a {
  color: var(--accent);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

/* ---- Decorative diagonal stripes (from the app icon) ---- */
.stripe-yellow {
  position: fixed;
  top: 0;
  left: 0;
  background: var(--accent);
  transform: rotate(45deg);
  pointer-events: none;
  z-index: 10;
}
.stripe-yellow-1 { top: -300px; left: -300px; width: 60px; height: 1000px; }
.stripe-yellow-2 { top: -300px; left: -200px; width: 70px; height: 1000px; }
.stripe-yellow-3 { top: -300px; left: -90px;  width: 55px; height: 1000px; }
.stripe-yellow-4 { top: -300px; left: 20px;   width: 65px; height: 1000px; }

/* ---- Shared containers ---- */
.container {
  max-width: 700px;
  margin: 0 auto;
  padding: 60px 24px;
}

/* ---- Home / hero ---- */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 24px 40px;
  text-align: center;
}

.logo-icon {
  width: 120px;
  height: 120px;
  margin-bottom: 24px;
}

.hero h1 {
  font-size: clamp(48px, 12vw, 72px);
  margin-bottom: 16px;
}

.tagline {
  font-size: clamp(20px, 5vw, 24px);
  opacity: 0.9;
  margin-bottom: 24px;
}

.description {
  max-width: 500px;
  font-size: 18px;
  opacity: 0.7;
  margin-bottom: 40px;
}

/* ---- Buttons ---- */
.app-store-badge,
.cta-button,
.home-link {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
}
.app-store-badge {
  background: #fff;
  color: #000;
}
.cta-button,
.home-link {
  background: var(--accent);
  color: #000;
}
.app-store-badge:hover,
.cta-button:hover,
.home-link:hover {
  opacity: 0.9;
  text-decoration: none;
}

/* ---- Features (home) ---- */
.features {
  max-width: 700px;
  margin: 0 auto;
  padding: 40px 24px 80px;
  display: grid;
  gap: 32px;
  grid-template-columns: repeat(2, 1fr);
}
.feature h2 {
  font-size: 24px;
  color: var(--accent);
  margin-bottom: 8px;
}
.feature p {
  opacity: 0.8;
}
@media (max-width: 560px) {
  .features { grid-template-columns: 1fr; }
}

/* ---- Content pages (privacy, support, zplkit) ---- */
.container h1 {
  font-size: 48px;
  margin-bottom: 8px;
}
.container h2 {
  font-size: 28px;
  color: var(--accent);
  margin-top: 48px;
  margin-bottom: 16px;
}
.container h3 {
  font-size: 22px;
  margin-bottom: 12px;
}
.container p {
  margin-bottom: 16px;
  opacity: 0.9;
}
.container ul,
.container ol {
  margin-bottom: 16px;
  padding-left: 24px;
}
.container li {
  margin-bottom: 8px;
  opacity: 0.9;
}
.updated,
.subtitle,
.intro {
  opacity: 0.6;
}
.updated { font-size: 14px; margin-bottom: 48px; }
.subtitle { font-size: 18px; margin-bottom: 8px; }
.intro { font-size: 18px; opacity: 0.8; margin-bottom: 48px; }

/* Callout boxes */
.highlight,
.contact-box {
  background: rgba(255, 215, 0, 0.1);
  border-left: 3px solid var(--accent);
  padding: 20px 24px;
  margin: 24px 0;
}
.contact-box { margin: 48px 0; }
.contact-box p { margin-bottom: 8px; }

/* FAQ */
.faq-item {
  border-bottom: 1px solid var(--hairline);
  padding: 20px 0;
}
.faq-question {
  font-weight: 600;
  margin-bottom: 8px;
}
.faq-answer p:last-child,
.faq-answer ol:last-child,
.faq-answer ul:last-child {
  margin-bottom: 0;
}

/* Code */
pre {
  background: #111;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  padding: 16px;
  overflow-x: auto;
  margin-bottom: 16px;
}
code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
}
pre code {
  background: none;
  padding: 0;
}

/* ---- Footer ---- */
footer {
  margin-top: 60px;
  padding-top: 24px;
  border-top: 1px solid var(--hairline);
  font-size: 14px;
  opacity: 0.6;
}
footer a {
  color: var(--fg);
  margin-right: 24px;
}
footer .powered-by {
  display: block;
  margin-top: 16px;
  opacity: 0.8;
  font-size: 12px;
}
footer .powered-by a {
  margin: 0;
}
/* Hero footer variant (centered, no top border) */
.hero-footer {
  text-align: center;
  padding: 40px 20px;
  margin-top: 0;
  border-top: 0;
}
.hero-footer a { margin: 0 12px; }

/* ---- 404: animated printer ---- */
.error-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.error-page .container { padding: 40px 24px; }
.printer {
  width: 200px;
  height: 140px;
  margin: 0 auto 40px;
  position: relative;
  animation: shake 0.3s infinite;
}
.printer-body {
  width: 200px;
  height: 80px;
  background: #333;
  border-radius: 8px;
  position: absolute;
  bottom: 0;
}
.printer-top {
  width: 180px;
  height: 50px;
  background: #444;
  border-radius: 6px 6px 0 0;
  position: absolute;
  bottom: 70px;
  left: 10px;
}
.printer-slot {
  width: 160px;
  height: 8px;
  background: #222;
  position: absolute;
  bottom: 60px;
  left: 20px;
  border-radius: 2px;
}
.light {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  position: absolute;
  top: 15px;
}
.light-red { right: 20px; background: #ff3333; animation: blink-red 0.5s infinite; }
.light-yellow { right: 40px; background: var(--accent); animation: blink-yellow 0.7s infinite; }
.light-green { right: 60px; background: #444; }
.paper {
  width: 100px;
  height: 60px;
  background: #fff;
  position: absolute;
  bottom: 55px;
  left: 50px;
  transform-origin: bottom center;
  animation: paper-jam 1.5s ease-in-out infinite;
}
.paper::before {
  content: "404";
  position: absolute;
  top: 15px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--display);
  font-size: 24px;
  color: #000;
}
.error-page h1 { font-size: 48px; margin-bottom: 16px; }
.error-page .message {
  font-size: 18px;
  opacity: 0.7;
  margin: 0 auto 32px;
  max-width: 400px;
}

@keyframes blink-red {
  0%, 50% { opacity: 1; box-shadow: 0 0 10px #ff3333; }
  51%, 100% { opacity: 0.3; box-shadow: none; }
}
@keyframes blink-yellow {
  0%, 30% { opacity: 1; box-shadow: 0 0 8px var(--accent); }
  31%, 100% { opacity: 0.3; box-shadow: none; }
}
@keyframes paper-jam {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  25% { transform: translateY(-5px) rotate(2deg); }
  50% { transform: translateY(-2px) rotate(-1deg); }
  75% { transform: translateY(-8px) rotate(3deg); }
}
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-2px); }
  75% { transform: translateX(2px); }
}

/* ---- Reduced motion ---- */
@media (prefers-reduced-motion: reduce) {
  .printer, .paper, .light-red, .light-yellow { animation: none; }
  .light-red { opacity: 1; box-shadow: 0 0 10px #ff3333; }
  .light-yellow { opacity: 1; box-shadow: 0 0 8px var(--accent); }
}
