@import url('https://fonts.googleapis.com/css2?family=Hanken+Grotesk:wght@400;500;600;700;800&family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600;700&display=swap');

@tailwind base;
@tailwind components;
@tailwind utilities;

:root {
  --background: #F6F9FF;
  --foreground: #161C22;
  --card: #FFFFFF;
  --card-foreground: #161C22;
  --primary: #000000;
  --primary-foreground: #FFFFFF;
  --border: #E2E8F0;
  --slate: #475569;
  --font-hanken: 'Hanken Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-inter: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

body {
  color: var(--foreground);
  background-color: var(--background);
  font-family: var(--font-inter);
  overflow-x: hidden;
}

button,
a,
[role="button"] {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 2px solid #000000;
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Custom crisp technical scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: #F6F9FF;
}
::-webkit-scrollbar-thumb {
  background: #C4C7C9;
  border-radius: 0px;
}
::-webkit-scrollbar-thumb:hover {
  background: #747779;
}

/* Zenith Silver Architectural Elements */
.zenith-card {
  background-color: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 0px;
}

.zenith-card-subtle {
  background-color: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 0px;
}

.zenith-btn-primary {
  background-color: #000000;
  color: #FFFFFF;
  border-radius: 0px;
  font-family: var(--font-mono), monospace;
  font-size: 13px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: all 0.15s ease-in-out;
}
.zenith-btn-primary:hover {
  background-color: #334155;
}

.zenith-btn-secondary {
  background-color: #FFFFFF;
  color: #000000;
  border: 1px solid #000000;
  border-radius: 0px;
  font-family: var(--font-mono), monospace;
  font-size: 13px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: all 0.15s ease-in-out;
}
.zenith-btn-secondary:hover {
  background-color: #F1F5F9;
}

.zenith-btn-ghost {
  background-color: transparent;
  color: #475569;
  border: 1px solid #E2E8F0;
  border-radius: 0px;
  font-family: var(--font-mono), monospace;
  font-size: 13px;
  letter-spacing: 0.05em;
  transition: all 0.15s ease-in-out;
}
.zenith-btn-ghost:hover {
  background-color: #FFFFFF;
  color: #000000;
  border-color: #000000;
}

/* Technical Monospace Labels */
.zenith-label {
  font-family: var(--font-mono), monospace;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #64748B;
}

/* Interactive Grid & Cell Focus */
.excel-cell:focus {
  outline: 2px solid #000000;
  outline-offset: -1px;
  background-color: #F8FAFC !important;
}

/* Shimmer scan animation */
@keyframes scanline {
  0% { top: 0%; opacity: 0; }
  15% { opacity: 1; }
  85% { opacity: 1; }
  100% { top: 100%; opacity: 0; }
}

.animate-scanline {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: #000000;
  animation: scanline 2.2s ease-in-out infinite;
}

/* ---- Auth screens ---------------------------------------------------- */

@keyframes auth-rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.auth-rise {
  animation: auth-rise 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes auth-fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.auth-fade {
  animation: auth-fade-in 0.2s ease-out both;
}

@keyframes auth-pop {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.auth-pop {
  animation: auth-pop 0.24s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* Scan line sweeping the receipt mock in the auth brand panel. */
@keyframes auth-scan-sweep {
  0% {
    top: -10%;
    opacity: 0;
  }
  12% {
    opacity: 1;
  }
  88% {
    opacity: 1;
  }
  100% {
    top: 105%;
    opacity: 0;
  }
}

.auth-scanline {
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: rgba(255, 255, 255, 0.85);
  box-shadow: 0 0 12px 2px rgba(255, 255, 255, 0.35);
  animation: auth-scan-sweep 3.2s ease-in-out infinite;
}

/* Spreadsheet cells filling in behind the scan. */
@keyframes auth-cell-in {
  from {
    transform: scaleX(0);
    opacity: 0;
  }
  to {
    transform: scaleX(1);
    opacity: 1;
  }
}

.auth-cell-in {
  transform-origin: left center;
  animation: auth-cell-in 0.5s ease-out both;
}
