/* ==========================================================================
   Quickly — Robot Mail Art Background Integration
   Designed for the light slate/navy/emerald theme
   ========================================================================== */

/* ---------- Background Artwork Layer ---------- */
.bg-robot-art {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

/* The artwork — positioned to complement the layout without competing */
.bg-robot-art::before {
  content: '';
  position: absolute;
  bottom: -8%;
  right: -6%;
  width: 65vw;
  max-width: 900px;
  height: auto;
  aspect-ratio: 1662 / 640;
  background-image: url('/robot-mail-art-light.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: bottom right;
  opacity: 0.5;
  transform: rotate(-1.5deg);
}

/* Subtle radial glow to blend artwork into page background */
.bg-robot-art::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 75% 85%, rgba(20, 182, 135, 0.04) 0%, transparent 55%),
    radial-gradient(ellipse at 25% 75%, rgba(15, 27, 45, 0.02) 0%, transparent 50%);
}

/* ---------- Page-Specific Positioning ---------- */

/* Landing page — artwork more prominent, anchors the hero section */
.page-landing .bg-robot-art::before {
  opacity: 0.6;
  width: 72vw;
  bottom: -10%;
  right: -8%;
}

/* Login page — artwork shifted to balance the centered form */
.page-login .bg-robot-art::before {
  opacity: 0.45;
  width: 58vw;
  bottom: -4%;
  right: 5%;
  transform: rotate(1deg) scaleX(-1); /* mirrored for left-side visual weight */
}

/* Signup page — artwork top-left, creates downward visual flow toward form */
.page-signup .bg-robot-art::before {
  opacity: 0.45;
  width: 55vw;
  top: -6%;
  left: -4%;
  bottom: auto;
  right: auto;
  transform: rotate(2deg);
}

/* Dashboard — very subtle, doesn't distract from work */
.page-dashboard .bg-robot-art::before {
  opacity: 0.25;
  width: 45vw;
  bottom: -5%;
  right: -3%;
}

/* Admin shell — minimal, professional */
.page-admin .bg-robot-art::before {
  opacity: 0.2;
  width: 40vw;
  bottom: -3%;
  right: -2%;
}

/* ---------- Content Layer (above background) ---------- */
.content-layer {
  position: relative;
  z-index: 1;
}

/* ---------- Auth Views Enhancement ---------- */
/* When background art is active, auth cards get a slightly more
   pronounced glass effect to stand out against the artwork */
.page-login .auth-card,
.page-signup .auth-card {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px) saturate(1.1);
  border: 1px solid rgba(221, 228, 238, 0.8);
  box-shadow:
    0 4px 10px rgba(15, 27, 45, 0.04),
    0 24px 48px rgba(15, 27, 45, 0.08),
    0 0 0 1px rgba(255, 255, 255, 0.5) inset;
}

/* ---------- Landing Page Hero Enhancement ---------- */
.page-landing .home-hero {
  position: relative;
  z-index: 1;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .bg-robot-art::before {
    width: 110vw;
    opacity: 0.35;
    bottom: -12%;
    right: -15%;
    transform: none;
  }

  .page-login .bg-robot-art::before,
  .page-signup .bg-robot-art::before {
    width: 100vw;
    opacity: 0.3;
    transform: none;
    top: auto;
    left: auto;
    bottom: -10%;
    right: -10%;
  }
}

/* ---------- Reduced Motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .bg-robot-art::before {
    transform: none !important;
  }
}

/* ---------- Print ---------- */
@media print {
  .bg-robot-art { display: none; }
}
