/* Shared "tech" skin for the user-facing pages (login / workbench / canvas). */
:root {
  --tech-cyan: #5ff2ff;
  --tech-mint: #56e3c4;
  --tech-violet: #8b7bff;
  --tech-line: rgba(95, 242, 255, 0.14);
  --tech-glow: rgba(95, 242, 255, 0.35);
}

body.tech {
  position: relative;
  background:
    radial-gradient(1100px 620px at 8% -12%, rgba(86, 227, 196, 0.16), transparent 62%),
    radial-gradient(900px 560px at 92% -6%, rgba(139, 123, 255, 0.18), transparent 60%),
    radial-gradient(circle at 50% 130%, #10243c 0%, #08111d 55%, #04070d 100%);
}

/* Perspective grid + slow drift */
body.tech::before {
  content: "";
  position: fixed;
  inset: -20% -20% -30% -20%;
  z-index: -3;
  pointer-events: none;
  background-image:
    linear-gradient(var(--tech-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--tech-line) 1px, transparent 1px);
  background-size: 46px 46px, 46px 46px;
  mask-image: radial-gradient(circle at 50% 40%, #000 0%, transparent 78%);
  -webkit-mask-image: radial-gradient(circle at 50% 40%, #000 0%, transparent 78%);
  animation: techGridDrift 26s linear infinite;
}

/* Horizontal sweep line */
body.tech::after {
  content: "";
  position: fixed;
  left: 0;
  right: 0;
  height: 220px;
  top: -220px;
  z-index: -2;
  pointer-events: none;
  background: linear-gradient(
    to bottom,
    transparent,
    rgba(95, 242, 255, 0.05) 55%,
    rgba(95, 242, 255, 0.12) 78%,
    transparent
  );
  animation: techSweep 11s ease-in-out infinite;
}

@keyframes techGridDrift {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(46px, 46px, 0);
  }
}

@keyframes techSweep {
  0% {
    transform: translateY(0);
    opacity: 0;
  }
  12% {
    opacity: 1;
  }
  88% {
    opacity: 1;
  }
  100% {
    transform: translateY(140vh);
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.tech::before,
  body.tech::after {
    animation: none;
  }
}

/* Glass panels with a hairline neon edge */
body.tech .card,
body.tech .auth-card {
  position: relative;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.012)),
    rgba(9, 18, 30, 0.7);
  border: 1px solid rgba(120, 190, 230, 0.2);
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

body.tech .card::before,
body.tech .auth-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  padding: 1px;
  background: linear-gradient(
    130deg,
    rgba(95, 242, 255, 0.5),
    rgba(139, 123, 255, 0.28) 45%,
    transparent 70%
  );
  mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  mask-composite: exclude;
  -webkit-mask-composite: xor;
}

/* Corner brackets */
body.tech .card::after,
body.tech .auth-card::after {
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: 10px;
  pointer-events: none;
  background:
    linear-gradient(var(--tech-cyan), var(--tech-cyan)) left top / 14px 1px no-repeat,
    linear-gradient(var(--tech-cyan), var(--tech-cyan)) left top / 1px 14px no-repeat,
    linear-gradient(var(--tech-cyan), var(--tech-cyan)) right top / 14px 1px no-repeat,
    linear-gradient(var(--tech-cyan), var(--tech-cyan)) right top / 1px 14px no-repeat,
    linear-gradient(var(--tech-cyan), var(--tech-cyan)) left bottom / 14px 1px no-repeat,
    linear-gradient(var(--tech-cyan), var(--tech-cyan)) left bottom / 1px 14px no-repeat,
    linear-gradient(var(--tech-cyan), var(--tech-cyan)) right bottom / 14px 1px no-repeat,
    linear-gradient(var(--tech-cyan), var(--tech-cyan)) right bottom / 1px 14px no-repeat;
  opacity: 0.4;
}

body.tech .hero {
  overflow: hidden;
}

body.tech .hero h1 {
  text-shadow: 0 0 22px rgba(95, 242, 255, 0.28);
}

/* Buttons */
body.tech button:not(.secondary):not(.small):not(.tab-btn):not(.auth-tab),
body.tech .btn-canvas,
body.tech .auth-submit {
  position: relative;
  border: 1px solid rgba(95, 242, 255, 0.45);
  background: linear-gradient(135deg, #58ecd2, #4ea8ff 60%, #8b7bff);
  color: #04211c;
  box-shadow:
    0 10px 26px rgba(78, 168, 255, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.35);
  transition: box-shadow 0.18s ease, transform 0.18s ease, filter 0.18s ease;
}

body.tech button:not(.secondary):not(.small):not(.tab-btn):not(.auth-tab):hover,
body.tech .btn-canvas:hover,
body.tech .auth-submit:hover {
  filter: brightness(1.07);
  transform: translateY(-1px);
  box-shadow:
    0 14px 34px rgba(95, 242, 255, 0.36),
    inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

body.tech .secondary,
body.tech .small {
  border: 1px solid rgba(120, 190, 230, 0.28);
  background: rgba(255, 255, 255, 0.05);
  color: #dff1ff;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

body.tech .secondary:hover,
body.tech .small:hover {
  border-color: rgba(95, 242, 255, 0.6);
  background: rgba(95, 242, 255, 0.12);
  box-shadow: 0 0 18px rgba(95, 242, 255, 0.22);
}

/* Inputs */
body.tech input,
body.tech select,
body.tech textarea {
  background: rgba(3, 10, 18, 0.6);
  border: 1px solid rgba(120, 190, 230, 0.22);
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

body.tech input:focus,
body.tech select:focus,
body.tech textarea:focus {
  outline: none;
  border-color: rgba(95, 242, 255, 0.7);
  box-shadow: 0 0 0 3px rgba(95, 242, 255, 0.14);
}

/* Nav / pills */
body.tech .app-nav {
  background: rgba(5, 11, 20, 0.78);
  border-bottom: 1px solid rgba(95, 242, 255, 0.18);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

body.tech .nav-pills {
  border-color: rgba(95, 242, 255, 0.18);
  background: rgba(255, 255, 255, 0.03);
}

body.tech .nav-pills .tab-btn.active {
  color: #04211c;
  background: linear-gradient(135deg, #58ecd2, #4ea8ff);
  box-shadow: 0 6px 18px rgba(78, 168, 255, 0.3);
}

body.tech .brand-mark,
body.tech .auth-logo {
  background: linear-gradient(135deg, #5ff2ff, #8b7bff);
  box-shadow: 0 0 24px rgba(95, 242, 255, 0.45);
}

body.tech .chip {
  background: rgba(95, 242, 255, 0.12);
  border-color: rgba(95, 242, 255, 0.32);
  color: #d7f8ff;
}

/* Tables */
body.tech table thead th {
  color: #9fd8ea;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 12px;
}

body.tech tbody tr:hover {
  background: rgba(95, 242, 255, 0.05);
}
