/* ==========================================================================
   CKURO.CC — Core Styles
   Theme: Cyberpunk Terminal | Font: Share Tech Mono (via Google Fonts)
   Notes:
   - Colors set via CSS variables.
   - Mobile-first, fluid type with clamp().
   - Strong focus outlines and reduced motion support.
   ========================================================================== */

   :root {
    /* Palette */
    --bg: #07080d;
    --fg: #e6fff3;
    --fg-dim: #a6bdb3;
    --primary: #39ff14; /* neon green */
    --secondary: #ff0f7b; /* hot pink */
    --tertiary: #00ffff; /* cyan */
  
    /* UI */
    --muted: #0c0f16;
    --card: #0b0e14;
    --border: #1b2330;
    --focus: var(--primary);
    --shadow: 0 10px 30px rgba(0, 255, 170, 0.08);
  
    /* Typography */
    --font: "Share Tech Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    --fs-1: clamp(2rem, 4vw + 0.25rem, 3.75rem);
    --fs-2: clamp(1.25rem, 2.25vw + 0.25rem, 2rem);
    --fs-3: clamp(1.0625rem, 1.25vw + 0.25rem, 1.125rem);
    --line: 1.65;
  
    /* Layout */
    --maxw: 1100px;
    --pad: clamp(0.75rem, 1.6vw, 1.25rem);
    --radius: 14px;
    --gap: clamp(0.75rem, 1.4vw, 1.25rem);
  
    /* Effects */
    --glow: 0 0 12px rgba(57, 255, 20, 0.6), 0 0 24px rgba(57, 255, 20, 0.3);
  }
  
  *,
  *::before,
  *::after { box-sizing: border-box; }
  
  html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    background: radial-gradient(1200px 800px at 50% -10%, rgba(0,255,170,0.05), transparent 50%),
                radial-gradient(1000px 600px at 120% 10%, rgba(255,15,123,0.05), transparent 40%),
                var(--bg);
    color: var(--fg);
    font-family: var(--font);
    line-height: var(--line);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  }
  
  img { max-width: 100%; display: block; height: auto; }
  a { color: var(--primary); text-decoration: none; }
  a:hover { text-decoration: underline; }
  p { color: var(--fg-dim); }
  ul { padding-left: 1.1rem; }
  
  /* Layout shells */
  header {
    border-bottom: 1px solid var(--border);
    background: linear-gradient(180deg, rgba(8,12,18,0.8), rgba(8,12,18,0.5));
    backdrop-filter: blur(6px);
    position: sticky; top: 0; z-index: 50;
  }
  nav {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: calc(var(--pad) + 2px) var(--pad);
    display: flex; align-items: center; justify-content: space-between;
    gap: var(--gap);
  }
  nav .logo {
    font-size: 1.05rem;
    letter-spacing: 0.08em;
    color: var(--fg);
    padding: 0.25rem 0.5rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: linear-gradient(180deg, #0c1119, #0a0e15);
    box-shadow: inset 0 0 0 1px rgba(57,255,20,0.08);
  }
  nav ul {
    list-style: none; display: flex; gap: clamp(0.5rem, 1.8vw, 1.25rem);
    margin: 0; padding: 0;
  }
  nav ul a {
    color: var(--fg);
    padding: 0.4rem 0.6rem;
    border-radius: 8px;
  }
  nav ul a[aria-current="page"] {
    color: var(--bg);
    background: var(--primary);
    box-shadow: var(--glow);
  }
  
  main {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: calc(var(--pad) * 2) var(--pad);
  }
  
  /* Hero & page hero */
  .hero, .page-hero {
    text-align: center;
    padding: clamp(2rem, 7vw, 5rem) var(--pad) clamp(1.5rem, 4vw, 3rem);
  }
  .hero h1, .page-hero h1 {
    font-size: var(--fs-1);
    margin: 0 0 0.35em;
    line-height: 1.1;
    letter-spacing: 0.04em;
    text-shadow: var(--glow);
  }
  .hero p, .page-hero p {
    font-size: var(--fs-3);
    margin: 0 auto;
    max-width: 60ch;
  }
  
  /* Feature cards / card grid */
  .features,
  .cards {
    display: grid;
    gap: var(--gap);
    margin: clamp(1rem, 5vw, 3rem) 0;
  }
  .grid-3 {
    grid-template-columns: 1fr;
  }
  @media (min-width: 760px) {
    .grid-3 { grid-template-columns: repeat(3, 1fr); }
  }
  
  .feature-card, .card {
    background: linear-gradient(180deg, #0b0f16, #090d13);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: clamp(1rem, 2.5vw, 1.5rem);
    box-shadow: var(--shadow);
  }
  .feature-card h2, .card h2 {
    margin: 0 0 0.35em; font-size: var(--fs-2);
  }
  .feature-card p, .card p { margin: 0; }
  
  /* Buttons */
  .btn {
    display: inline-block;
    border-radius: 12px;
    padding: 0.65rem 1rem;
    border: 1px solid var(--border);
    background: #0e1420;
    color: var(--fg);
    text-decoration: none;
    transition: transform 120ms ease, box-shadow 120ms ease, background 120ms ease;
  }
  .btn:hover { transform: translateY(-1px); }
  .btn.primary {
    background: linear-gradient(180deg, #1aff8a 0%, #39ff14 60%, #1bd85d 100%);
    color: #001106;
    box-shadow: var(--glow);
    border-color: rgba(57,255,20,0.45);
  }
  .btn.secondary {
    background: linear-gradient(180deg, #00ffff 0%, #0dd4ff 60%, #00c0ff 100%);
    color: #001018;
    border-color: rgba(0,255,255,0.35);
  }
  .btn.disabled,
  .btn[aria-disabled="true"] {
    opacity: 0.6; cursor: not-allowed; filter: grayscale(0.2);
  }
  
  /* Forms */
  .form-shell {
    max-width: 520px;
    margin: 0 auto;
    background: linear-gradient(180deg, #0b0f16, #090d13);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: clamp(1rem, 3vw, 1.75rem);
    box-shadow: var(--shadow);
  }
  .form-row { display: grid; gap: 0.35rem; margin-bottom: 0.9rem; }
  label { color: var(--fg); font-size: 0.95rem; }
  input, textarea {
    width: 100%;
    background: #0b1018;
    color: var(--fg);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 0.65rem 0.75rem;
    outline: none;
  }
  input:focus, textarea:focus {
    border-color: var(--focus);
    box-shadow: 0 0 0 3px rgba(57,255,20,0.25);
  }
  .status {
    margin-top: 0.75rem;
    min-height: 1.2em;
    color: var(--tertiary);
  }
  .muted { color: var(--fg-dim); font-size: 0.95rem; }
  
  /* Simple two-column block */
  .two-col {
    display: grid;
    gap: var(--gap);
    margin: 2rem 0;
  }
  @media (min-width: 900px) {
    .two-col { grid-template-columns: 1fr 1fr; }
  }
  
  /* Doc pages */
  .doc {
    max-width: 70ch;
    margin: 0 auto;
    background: linear-gradient(180deg, #0b0f16, #090d13);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: clamp(1rem, 3vw, 1.75rem);
  }
  .bullets li { margin-bottom: 0.25rem; }
  
  /* Footer */
  footer {
    border-top: 1px solid var(--border);
    padding: var(--pad);
    margin-top: clamp(2rem, 6vw, 4rem);
    background: linear-gradient(180deg, rgba(8,12,18,0.5), rgba(8,12,18,0.8));
  }
  footer p { margin: 0 0 0.5rem; }
  footer ul {
    list-style: none; padding: 0; margin: 0;
    display: flex; gap: 0.75rem; flex-wrap: wrap;
  }
  footer a { color: var(--fg-dim); }
  footer a:hover { color: var(--primary); text-decoration: none; }
  
  /* Accessibility */
  .skip-link {
    position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden;
  }
  .skip-link:focus {
    position: fixed; left: var(--pad); top: var(--pad); width: auto; height: auto;
    background: var(--primary); color: #001106; padding: 0.4rem 0.6rem; border-radius: 8px;
    z-index: 1000;
  }
  :focus-visible {
    outline: 2px solid var(--focus);
    outline-offset: 2px;
  }
  
  /* CRT scanlines overlay (opt-in, apply .scanlines on body or container) */
  .scanlines {
    position: relative;
  }
  .scanlines::after {
    content: "";
    position: absolute; inset: 0;
    pointer-events: none;
    background: repeating-linear-gradient(
      to bottom,
      rgba(0,0,0,0.15) 0px,
      rgba(0,0,0,0.15) 1px,
      rgba(0,0,0,0.0) 2px,
      rgba(0,0,0,0.0) 3px
    );
    mix-blend-mode: multiply;
    opacity: 0.35;
    border-radius: inherit;
  }
  
  /* Glitch hook (keyframes in animations.css) */
  .glitch {
    position: relative;
    color: var(--primary);
  }
  .glitch::before,
  .glitch::after {
    content: attr(data-text);
    position: absolute; left: 0; top: 0;
    width: 100%; overflow: hidden;
    clip-path: inset(0 0 0 0);
    opacity: 0.8;
    mix-blend-mode: screen;
  }
  .glitch::before { color: var(--secondary); transform: translate(2px, 0); }
  .glitch::after  { color: var(--tertiary); transform: translate(-2px, 0); }
  
  /* Reduced motion handling */
  @media (prefers-reduced-motion: reduce) {
    * { animation: none !important; transition: none !important; }
    .glitch::before, .glitch::after { display: none; }
  }
  
  /* Utility */
  .center { text-align: center; }
  .hidden { display: none !important; }
  