/* ==========================================
   Insanegenix Product Authentication Styles
   auth.css — Dark Industrial Theme
   ========================================== */

@import url("https://fonts.googleapis.com/css2?family=Bebas+Neue&family=DM+Mono:wght@300;400;500&family=DM+Sans:wght@300;400;500;600&display=swap");

/* ── Page-level overrides ────────────────────────────────────────
   Force the entire page black and hide Astra page chrome
   so the shortcode looks like a standalone auth page (image 2)
   ─────────────────────────────────────────────────────────────── */

/* Black page background */
body:has(.igx-auth-wrapper) {
  background: #000000 !important;
}

/* Hide Astra page title ("Product Verification") */
body:has(.igx-auth-wrapper) .entry-title,
body:has(.igx-auth-wrapper) header.entry-header,
body:has(.igx-auth-wrapper) .ast-single-entry-banner {
  display: none !important;
}

/* Remove white padding/background from the page content area */
body:has(.igx-auth-wrapper) #primary,
body:has(.igx-auth-wrapper) .site-content,
body:has(.igx-auth-wrapper) .ast-container,
body:has(.igx-auth-wrapper) .entry-content,
body:has(.igx-auth-wrapper) .ast-article-single,
body:has(.igx-auth-wrapper) .ast-separate-container .ast-article-single,
body:has(.igx-auth-wrapper) #content {
  background: #000000 !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin: 0 !important;
  max-width: 100% !important;
}

/* Make the content area fill full viewport height */
body:has(.igx-auth-wrapper) .site-content {
  min-height: calc(100vh - 110px); /* 110px = approx header height */
  display: flex !important;
  align-items: center;
  justify-content: center;
}

body:has(.igx-auth-wrapper) .site-content .ast-container {
  width: 100%;
  display: flex !important;
  justify-content: center;
  padding: 48px 20px !important;
}

/* ── Animations ─────────────────────────────────────────────── */
@keyframes igx-fadeup {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes igx-scan {
  0% {
    transform: translateY(-100%);
  }
  100% {
    transform: translateY(600px);
  }
}

/* ── Wrapper ─────────────────────────────────────────────────── */
.igx-auth-wrapper {
  position: relative;
  width: 100%;
  max-width: 520px;
  background: #0d0d0d;
  border: 1px solid #2a0000;
  padding: 52px 44px 48px;
  overflow: hidden;
  font-family: "DM Sans", sans-serif;
  animation: igx-fadeup 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* Scanline sweep */
.igx-auth-wrapper::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(192, 57, 43, 0.6),
    transparent
  );
  animation: igx-scan 4s linear infinite;
  pointer-events: none;
  z-index: 0;
}

/* Noise texture overlay */
.igx-auth-wrapper::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
}

/* ── Corner accents ──────────────────────────────────────────── */
.igx-corner {
  position: absolute;
  width: 16px;
  height: 16px;
  z-index: 2;
}
.igx-corner--tl {
  top: 0;
  left: 0;
  border-top: 2px solid #c0392b;
  border-left: 2px solid #c0392b;
}
.igx-corner--tr {
  top: 0;
  right: 0;
  border-top: 2px solid #c0392b;
  border-right: 2px solid #c0392b;
}
.igx-corner--bl {
  bottom: 0;
  left: 0;
  border-bottom: 2px solid #c0392b;
  border-left: 2px solid #c0392b;
}
.igx-corner--br {
  bottom: 0;
  right: 0;
  border-bottom: 2px solid #c0392b;
  border-right: 2px solid #c0392b;
}

/* ── Stack content above overlays ───────────────────────────── */
.igx-auth-header,
.igx-auth-message,
.igx-auth-form {
  position: relative;
  z-index: 1;
}

/* ── Header ──────────────────────────────────────────────────── */
.igx-auth-header {
  margin-bottom: 36px;
  text-align: center;
}

.igx-auth-brand {
  font-family: "DM Mono", monospace;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 5px;
  text-transform: uppercase;
  color: #c0392b;
  margin-bottom: 10px;
}

.igx-auth-title {
  font-family: "Bebas Neue", sans-serif !important;
  font-size: clamp(42px, 8vw, 64px) !important;
  font-weight: 400 !important;
  letter-spacing: 2px;
  color: #ffffff !important;
  line-height: 1 !important;
  margin-bottom: 10px !important;
  padding: 0 !important;
}

.igx-auth-subtitle {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.3);
  font-weight: 300;
  letter-spacing: 0.4px;
}

/* ── Flash messages ──────────────────────────────────────────── */
.igx-auth-message {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 16px;
  margin-bottom: 28px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.3px;
  border-left: 3px solid;
}

.igx-message-icon {
  font-size: 14px;
  flex-shrink: 0;
}

.igx-success {
  background: rgba(34, 197, 94, 0.06);
  border-color: #22c55e;
  color: #4ade80;
}

.igx-error {
  background: rgba(192, 57, 43, 0.08);
  border-color: #c0392b;
  color: #f87171;
}

/* ── Form ────────────────────────────────────────────────────── */
.igx-auth-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.igx-field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.igx-field label {
  font-family: "DM Mono", monospace;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
}

/* ── Inputs ──────────────────────────────────────────────────── */
.igx-field input {
  width: 100%;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0 !important;
  color: #ffffff !important;
  font-family: "DM Sans", sans-serif !important;
  font-size: 15px !important;
  font-weight: 400;
  outline: none !important;
  box-shadow: none !important;
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    box-shadow 0.2s ease;
  -webkit-appearance: none;
  appearance: none;
  height: auto !important;
}

.igx-field input::placeholder {
  color: rgba(255, 255, 255, 0.18) !important;
}

.igx-field input:hover:not(:focus) {
  border-color: rgba(255, 255, 255, 0.18);
}

.igx-field input:focus {
  border-color: #c0392b !important;
  background: rgba(192, 57, 43, 0.04) !important;
  box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.1) !important;
  outline: none !important;
}

/* Product code field */
.igx-field--code input {
  font-family: "DM Mono", monospace !important;
  letter-spacing: 4px !important;
  font-size: 14px !important;
  text-transform: uppercase;
}

.igx-code-hint {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.2);
  font-style: italic;
}

/* ── Submit button ───────────────────────────────────────────── */
.igx-submit-btn {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 16px 24px !important;
  margin-top: 8px;
  background: #c0392b !important;
  border: none !important;
  border-radius: 0 !important;
  color: #ffffff !important;
  font-family: "DM Mono", monospace !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  letter-spacing: 3px;
  text-transform: uppercase;
  cursor: pointer;
  transition:
    background 0.2s ease,
    transform 0.15s ease,
    box-shadow 0.2s ease !important;
  position: relative;
  overflow: hidden;
  line-height: 1 !important;
  height: auto !important;
}

.igx-submit-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.08) 0%,
    transparent 60%
  );
  pointer-events: none;
}

.igx-btn-arrow {
  transition: transform 0.2s ease;
  font-size: 16px;
}

.igx-submit-btn:hover {
  background: #e74c3c !important;
  box-shadow: 0 8px 28px rgba(192, 57, 43, 0.45) !important;
  transform: translateY(-1px);
  color: #ffffff !important;
}

.igx-submit-btn:hover .igx-btn-arrow {
  transform: translateX(4px);
}

.igx-submit-btn:active {
  transform: translateY(0) !important;
  background: #a93226 !important;
  box-shadow: none !important;
}

.igx-submit-btn.is-loading {
  opacity: 0.6;
  pointer-events: none;
}

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 600px) {
  .igx-auth-wrapper {
    padding: 36px 24px 32px;
  }
  .igx-field input {
    padding: 13px 14px !important;
    font-size: 14px !important;
  }
}
