/* -- Confetti canvas ------------------------------------------------------- */
#confetti-canvas {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  pointer-events: none; z-index: 100;
}



/* -- Animations ----------------------------------------------------------- */
@keyframes fadeUp   { from { opacity:0; transform:translateY(14px); } to { opacity:1; transform:translateY(0); } }
@keyframes fadeIn   { from { opacity:0; } to { opacity:1; } }
@keyframes pulseDot { 0%,100% { opacity:1; transform:scale(1); } 50% { opacity:0.3; transform:scale(0.8); } }
@keyframes spin     { to { transform:rotate(360deg); } }

.anim-fade-up  { animation: fadeUp  0.5s ease forwards; opacity: 0; }
.anim-fade-in  { animation: fadeIn  0.35s ease forwards; opacity: 0; }
.anim-spin     { animation: spin    1.1s linear infinite; }
.anim-pulse    { animation: pulseDot 1.4s ease-in-out infinite; }
.delay-1 { animation-delay: 0.05s; }
.delay-2 { animation-delay: 0.12s; }
.delay-3 { animation-delay: 0.22s; }

/* -- Focus rings ----------------------------------------------------------- */
:focus-visible { outline: 2px solid var(--ac); outline-offset: 2px; }

/* -- Mobile --------------------------------------------------------------- */
@media (max-width: 540px) {
  .main { padding-top: 8px; }
  .deep-scan-cta-inner { flex-direction: column; align-items: flex-start; gap: 12px; }
  .deep-scan-cta-btn { width: 100%; text-align: center; }
  .result-domain-row { gap: 4px; }
  .scan-time { order: 0; }

  /* Badge modal mobile responsive */
  .badge-modal-backdrop {
    justify-content: flex-start;
    padding: 12px;
  }
  .badge-modal {
    width: calc(100vw - 40px);
    max-width: none;
    padding: 16px 12px;
    gap: 16px;
  }
}

/* -- Glow orb transition -------------------------------------------------- */
.bg-glow { transition: background 0.8s ease; }

/* -- Reduced motion ------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .gc-ring-fill { transition: none !important; }
  .bar-fill { transition: none !important; }
  .scan-ring-outer, .scan-ring-inner { animation: none !important; }
}


/* -- Checks Modal -------------------------------------------------------- */
.checks-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(8,8,13,0.85);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  overflow: auto;
}

@media (max-width: 768px) {
  .checks-modal-backdrop {
    width: calc(100% - 110px);
    align-items: flex-start;
    padding-top: 16px;
  }
}

.checks-modal {
  background: #0a0a0f;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  width: 100%;
  max-width: 520px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 40px rgba(0,0,0,0.6);
  overflow: hidden;
  box-sizing: border-box;
  position: relative;
}

.checks-modal-close {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 10;
  background: rgba(10,10,15,0.95);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 6px;
  cursor: pointer;
  color: #e2e8f0;
  padding: 6px 10px;
  line-height: 1;
  font-size: 18px;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.checks-modal-close:hover {
  background: rgba(10,10,15,1);
  border-color: rgba(255,255,255,0.4);
}

.checks-modal-header {
  padding: 8px 48px 8px 8px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  flex-shrink: 0;
  box-sizing: border-box;
}

.checks-modal-header-content {
  min-width: 0;
  overflow: hidden;
}

.checks-modal-domain {
  font-size: 11px;
  font-family: 'DM Mono', monospace;
  color: #60a5fa;
  margin: 0 0 4px;
  letter-spacing: 0.02em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.checks-modal-title {
  font-size: 14px;
  font-weight: 500;
  color: #e2e8f0;
  margin: 0 0 12px 0;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.checks-modal-status {
  font-size: 11px;
  font-family: 'DM Mono', monospace;
  color: #475569;
  margin: 4px 0 0;
  line-height: 1.4;
}

.checks-modal-status-passed {
  color: #86efac;
}

.checks-modal-status-failed {
  color: #fca5a5;
}

.checks-modal-status-pending {
  color: var(--t3);
}

.checks-modal-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  flex-shrink: 0;
}

.checks-modal-tab {
  flex: 1;
  padding: 8px 12px;
  font-size: 12px;
  font-family: 'DM Mono', monospace;
  background: none;
  color: #475569;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
}

.checks-modal-tab.active {
  background: rgba(59,130,246,0.12);
  color: #60a5fa;
  border-bottom-color: #60a5fa;
}

.checks-modal-content {
  overflow-y: auto;
  overflow-x: hidden;
  padding: 16px 20px 24px;
}

.checks-modal-notice {
  margin-bottom: 14px;
  padding: 10px 12px;
  background: rgba(99,102,241,0.07);
  border: 1px solid rgba(99,102,241,0.2);
  border-radius: 8px;
}

.checks-modal-notice-text {
  font-size: 11px;
  font-family: 'DM Mono', monospace;
  color: #818cf8;
  margin: 0;
  line-height: 1.5;
}

.checks-modal-notice-muted {
  color: #64748b;
}


/* Check items */
.check-category {
  margin-bottom: 16px;
}

.check-category-header {
  display: flex;
  align-items: center;
  margin: 0 0 6px;
}

.check-category-header-label {
  font-size: 10px;
  font-family: 'DM Mono', monospace;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  flex: 1;
}

.check-category-header-severity {
  font-size: 10px;
  font-family: 'DM Mono', monospace;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.check-category-title {
  font-size: 10px;
  font-family: 'DM Mono', monospace;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 0 0 6px;
}

.check-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

.check-icon {
  flex-shrink: 0;
  font-size: 13px;
  line-height: 1;
  width: 20px;
  display: inline-block;
  text-align: center;
}
.check-icon-passed::before {
  content: '✓';
  color: var(--gn);
}
.check-icon-failed::before {
  content: '×';
  color: var(--rd);
  font-size: 16px;
}

.check-icon-pending {
  width: 20px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
}

.check-icon-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.check-name {
  font-size: 12px;
  flex: 1;
  word-wrap: break-word;
  overflow-wrap: break-word;
  min-width: 0;
}

.check-name-passed {
  color: #86efac;
}

.check-name-failed {
  color: #fca5a5;
}

.check-name-pending {
  color: #cbd5e1;
}

.check-severity {
  font-size: 10px;
  font-family: 'DM Mono', monospace;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}
.auth-email-input {
  width: 100%; background: #fff;
  border: 1px solid rgba(0,0,0,0.12);
  border-radius: 8px; padding: 10px 14px;
  font-size: 14px; color: #1e293b;
  outline: none; transition: border-color 0.15s;
  margin-bottom: 14px;
}
.auth-otp-input {
  width: 100%; background: var(--s2);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px; padding: 10px 14px;
  font-size: 14px; color: var(--tx);
  outline: none; transition: border-color 0.15s;
  margin-bottom: 14px;
}
.auth-email-input:focus,
.auth-otp-input:focus {
  border-color: var(--ac);
  box-shadow: 0 0 0 3px rgba(124,106,239,0.15);
}
.auth-button-row {
  display: flex; align-items: center; gap: 14px;
  margin-bottom: 14px;
}
.auth-btn-primary {
  background: var(--ac); color: #fff;
  border: none; border-radius: 8px;
  padding: 10px 20px; font-size: 13px; font-weight: 600;
  cursor: pointer; transition: background 0.15s;
  flex-shrink: 0;
}
.auth-button-hint {
  font-size: 13px; color: var(--t3);
  line-height: 1.4;
}
.auth-btn-primary:hover:not(:disabled) { background: #6a58d6; }
.auth-btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }
.auth-error {
  font-size: 12px; color: var(--rd);
  padding: 8px 12px; margin-bottom: 14px;
  background: var(--rdbg);
  border-radius: 6px; border: 1px solid var(--rdbd);
}
.auth-privacy {
  font-size: 12px; color: var(--t4);
  margin: 0 0 14px; text-align: center;
}
.auth-privacy a {
  color: var(--ac2); text-decoration: none;
}
.auth-privacy a:hover {
  text-decoration: underline;
}

/* -- Site footer ----------------------------------------------------------- */
.site-footer {
  text-align: center;
  padding: 2rem 1rem;
  margin-top: 4rem;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.footer-link {
  color: var(--t4);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 400;
  transition: color 0.2s;
}

.footer-link:hover {
  color: var(--ac);
  text-decoration: underline;
}

.footer-login-btn {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-size: 0.9rem;
}

@media (max-width: 640px) {
  .site-footer {
    flex-direction: column;
    gap: 1rem;
  }
}
