/* ==========================================================
   Financial & IPO Tracking Portal - Custom Stylesheet
   Enhanced aesthetics for InvestorGain-inspired tabular UI
   ========================================================== */

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

:root {
  --primary-navy: #0f172a;
  --accent-emerald: #10b981;
  --accent-blue: #2563eb;
  --border-light: #e2e8f0;
}

body {
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: #1e293b;
  background-color: #f8fafc;
  -webkit-font-smoothing: antialiased;
}

/* Custom Scrollbar for dense financial tables */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Infinite Marquee Animation for Header Ticker */
@keyframes ticker-slide {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(-50%, 0, 0);
  }
}

.ticker-wrap {
  overflow: hidden;
  white-space: nowrap;
  box-sizing: border-box;
}

.ticker-content {
  display: inline-flex;
  white-space: nowrap;
  animation: ticker-slide 35s linear infinite;
}

.ticker-content:hover {
  animation-play-state: paused;
}

/* Financial Table Enhancements */
.financial-table {
  border-collapse: separate;
  border-spacing: 0;
}

.financial-table th {
  position: sticky;
  top: 0;
  z-index: 10;
  background-color: #f8fafc;
}

.financial-table tr:hover td {
  background-color: #f8fafc;
}

/* Sticky column on mobile for company names */
@media (max-width: 640px) {
  .sticky-col {
    position: sticky;
    left: 0;
    background-color: white;
    z-index: 5;
    box-shadow: 2px 0 4px -2px rgba(0, 0, 0, 0.08);
  }
}

/* Subtle glow effects for high-performing IPOs */
.badge-glow-green {
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.25);
}

.badge-glow-blue {
  box-shadow: 0 0 10px rgba(37, 99, 235, 0.25);
}

/* Timeline Stepper Component */
.timeline-step {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
}

.timeline-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 18px;
  left: 50%;
  width: 100%;
  height: 3px;
  background-color: #e2e8f0;
  z-index: 1;
}

.timeline-step.completed:not(:last-child)::after {
  background-color: #10b981;
}

.timeline-step.active:not(:last-child)::after {
  background: linear-gradient(90deg, #10b981 50%, #e2e8f0 50%);
}

.timeline-node {
  position: relative;
  z-index: 2;
  width: 36px;
  height: 36px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.875rem;
  transition: all 0.2s ease;
}

/* Responsive Mobile Table Scroll Container */
.overflow-x-auto {
  -webkit-overflow-scrolling: touch;
  touch-action: pan-x pan-y;
}

/* Hide scrollbar utility for touch swipe tabs */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* Mobile responsive font sizing & tap target optimization */
@media (max-width: 640px) {
  .ticker-wrap {
    font-size: 11px;
  }
  
  /* Prevent iOS zoom on input focus */
  input[type="text"],
  input[type="number"],
  input[type="password"],
  input[type="email"],
  input[type="url"],
  select,
  textarea {
    font-size: 16px !important;
  }

  /* Responsive financial card padding */
  .financial-card {
    padding: 1rem !important;
  }
}

/* Print optimizations for IPO analysis sheet */
@media print {
  .no-print {
    display: none !important;
  }
  body {
    background: white;
    color: black;
  }
}
