/* ==========================================================================
   yusufte.fun — Gold Pixel Canvas Background
   Base: #FFD700 top-to-bottom sunlit gold gradient
   Pattern: 24x24 staggered stepped pixel-diamond & chiseled cross weave
            rendered on a strict integer pixel grid (crispEdges).
   ========================================================================== */

:root {
  /* Core Gold Gradient Stops (anchored on #FFD700) */
  --gold-top: #FFE347;
  --gold-core: #FFD700;
  --gold-mid: #F6BE00;
  --gold-bottom: #E49B00;

  /* Pixel Tile Scale (24 logical pixels * 8px = 192px) */
  --pixel-tile-size: 192px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  width: 100%;
  min-height: 100%;
  background-color: var(--gold-core);
  overflow-x: hidden;
}

.bg-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;

  /* Top-to-bottom gold gradient anchored on #FFD700 */
  background-color: var(--gold-core);
  background-image: linear-gradient(
    180deg,
    var(--gold-top) 0%,
    var(--gold-core) 28%,
    var(--gold-mid) 70%,
    var(--gold-bottom) 100%
  );
}

/* Lighter-gold crisp pixel tessellation layer */
.bg-canvas::before {
  content: "";
  position: absolute;
  inset: 0;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  background-repeat: repeat;
  background-position: top center;
  background-size: var(--pixel-tile-size) var(--pixel-tile-size);

  /*
    24x24 logical pixel seamless half-drop weave:
    - Primary stepped pixel-diamonds at (6,6) and (18,18)
      with sunlit top-left bevel pixels (#FFF7C2) and soft light-gold body (#FFEC80)
    - Secondary 3x3 hollow pixel-cross accents at (18,6) and (6,18)
    - Subtle 1x1 vertex glint pixels at (0,0), (12,0), (0,12), (12,12)
  */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' shape-rendering='crispEdges'%3E%3Cg fill='%23FFF8CC' fill-opacity='0.46'%3E%3Crect x='6' y='3' width='1' height='1'/%3E%3Crect x='5' y='4' width='1' height='1'/%3E%3Crect x='4' y='5' width='1' height='1'/%3E%3Crect x='3' y='6' width='1' height='1'/%3E%3Crect x='6' y='6' width='1' height='1'/%3E%3Crect x='18' y='15' width='1' height='1'/%3E%3Crect x='17' y='16' width='1' height='1'/%3E%3Crect x='16' y='17' width='1' height='1'/%3E%3Crect x='15' y='18' width='1' height='1'/%3E%3Crect x='18' y='18' width='1' height='1'/%3E%3C/g%3E%3Cg fill='%23FFEE88' fill-opacity='0.38'%3E%3Crect x='7' y='4' width='1' height='1'/%3E%3Crect x='8' y='5' width='1' height='1'/%3E%3Crect x='9' y='6' width='1' height='1'/%3E%3Crect x='8' y='7' width='1' height='1'/%3E%3Crect x='7' y='8' width='1' height='1'/%3E%3Crect x='6' y='9' width='1' height='1'/%3E%3Crect x='5' y='8' width='1' height='1'/%3E%3Crect x='4' y='7' width='1' height='1'/%3E%3Crect x='19' y='16' width='1' height='1'/%3E%3Crect x='20' y='17' width='1' height='1'/%3E%3Crect x='21' y='18' width='1' height='1'/%3E%3Crect x='20' y='19' width='1' height='1'/%3E%3Crect x='19' y='20' width='1' height='1'/%3E%3Crect x='18' y='21' width='1' height='1'/%3E%3Crect x='17' y='20' width='1' height='1'/%3E%3Crect x='16' y='19' width='1' height='1'/%3E%3C/g%3E%3Cg fill='%23FFF7C2' fill-opacity='0.36'%3E%3Crect x='18' y='5' width='1' height='1'/%3E%3Crect x='17' y='6' width='1' height='1'/%3E%3Crect x='6' y='17' width='1' height='1'/%3E%3Crect x='5' y='18' width='1' height='1'/%3E%3C/g%3E%3Cg fill='%23FFEE88' fill-opacity='0.28'%3E%3Crect x='19' y='6' width='1' height='1'/%3E%3Crect x='18' y='7' width='1' height='1'/%3E%3Crect x='7' y='18' width='1' height='1'/%3E%3Crect x='6' y='19' width='1' height='1'/%3E%3C/g%3E%3Cg fill='%23FFF8CC' fill-opacity='0.26'%3E%3Crect x='0' y='0' width='1' height='1'/%3E%3Crect x='12' y='0' width='1' height='1'/%3E%3Crect x='0' y='12' width='1' height='1'/%3E%3Crect x='12' y='12' width='1' height='1'/%3E%3C/g%3E%3C/svg%3E");
}

@media (max-width: 640px) {
  :root {
    --pixel-tile-size: 144px;
  }
}
