/* Styles specific to search.html (the ticker/company lookup page, split out
   of index.html when the homepage became a market dashboard). */

:root {
  --electric-blue: #00c3ff;
  --electric-blue-soft: #4de2ff;
  --electric-blue-glow: rgba(0, 195, 255, 0.55);
}

/* ===== Floating hero orbs (decorative, fixed to viewport) ===== */

.hero-orb {
  position: fixed;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  filter: blur(45px);
  mix-blend-mode: screen;
  will-change: transform;
}

.hero-orb-1 {
  top: -6vw;
  left: -4vw;
  width: 36vw;
  height: 36vw;
  background: radial-gradient(circle, rgba(0, 195, 255, 0.9) 0%, rgba(0, 195, 255, 0) 68%);
  animation: orb-float-1 16s ease-in-out infinite;
}

.hero-orb-2 {
  top: 4vw;
  right: -6vw;
  width: 30vw;
  height: 30vw;
  background: radial-gradient(circle, rgba(96, 190, 150, 0.85) 0%, rgba(96, 190, 150, 0) 68%);
  animation: orb-float-2 20s ease-in-out infinite;
}

.hero-orb-3 {
  top: 18vw;
  left: 36vw;
  width: 24vw;
  height: 24vw;
  background: radial-gradient(circle, rgba(122, 127, 255, 0.85) 0%, rgba(122, 127, 255, 0) 68%);
  animation: orb-float-3 24s ease-in-out infinite;
}

@keyframes orb-float-1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(6vw, 4vw) scale(1.15); }
  66% { transform: translate(2vw, 8vw) scale(0.95); }
}

@keyframes orb-float-2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-7vw, 6vw) scale(1.2); }
}

@keyframes orb-float-3 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  40% { transform: translate(-4vw, -5vw) scale(1.1); }
  75% { transform: translate(5vw, 3vw) scale(0.9); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-orb {
    animation: none;
  }
}

@keyframes bg-pan-left {
  0% {
    background-position: 0% 30%, 100% 70%, 0% 50%;
  }
  50% {
    background-position: 70% 60%, 30% 20%, 100% 50%;
  }
  100% {
    background-position: 0% 30%, 100% 70%, 0% 50%;
  }
}

body.bg-pan-left {
  animation: bg-pan-left 18s ease-in-out infinite both;
  background:
    radial-gradient(circle at 20% 30%, rgba(96, 190, 150, 0.30) 0%, transparent 55%),
    radial-gradient(circle at 80% 20%, rgba(58, 117, 213, 0.30) 0%, transparent 55%),
    linear-gradient(120deg, #bbecff 0%, #dddfff 45%, #cfe8ff 75%, #bbecff 100%);
  background-size: 200% 200%, 200% 200%, 300% 300%;
}

main {
  padding: 2rem;
  max-width: 700px;
}

/* ===== Hero / intro ===== */

.info-list-enhanced {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  margin: 25px 0 16px 0;
  padding: 18px 24px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0.25) 100%);
  -webkit-backdrop-filter: blur(0px) saturate(100%);
  backdrop-filter: blur(0px) saturate(100%);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(31, 38, 135, 0.2);
  transition: all 0.35s ease;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

.info-list-enhanced:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.35) 0%, rgba(255, 255, 255, 0.1) 100%);
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 12px 40px rgba(31, 38, 135, 0.3), 0 0 20px rgba(255, 255, 255, 0.2);
}

.info-item {
  display: flex;
  align-items: center;
  gap: 0.7em;
  font-size: 1.08rem;
  color: #1c3762;
}

.info-icon {
  font-size: 1.3em;
  vertical-align: middle;
}

.info-item strong {
  color: #1670d6;
}

.main-title {
  font-size: 2.5rem;
  margin: 0.5rem;
  font-weight: 800;
  text-align: center;
  background: linear-gradient(90deg, #1c3762 0%, var(--electric-blue) 50%, #1c3762 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: title-shine 6s ease-in-out infinite;
}

@keyframes title-shine {
  0%, 100% { background-position: 0% center; }
  50% { background-position: 100% center; }
}

.subtitle {
  font-size: 1.3rem;
  color: #555;
  margin-bottom: 1.25rem;
  text-align: center;
}

.hero-tagline {
  margin-top: 1.35rem;
  font-size: 1.05rem;
  color: var(--electric-blue);
  text-shadow: 0 0 12px var(--electric-blue-glow);
  text-align: center;
  animation: tagline-pulse 3.5s ease-in-out infinite;
}

@keyframes tagline-pulse {
  0%, 100% { opacity: 0.85; }
  50% { opacity: 1; text-shadow: 0 0 20px var(--electric-blue-glow); }
}

/* ===== Search box, suggestions, chips ===== */

.company-search-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin: 2rem 0;
  width: 100%;
}

.search-container {
  display: flex;
  align-items: center;
  background: #fff;
  border-radius: 2rem;
  box-shadow: 0 4px 16px rgba(58, 117, 213, 0.15), 0 0 0 1px rgba(0, 195, 255, 0.25);
  max-width: 500px;
  width: 100%;
  padding: 0.4rem;
  position: relative;
  animation: search-glow 4s ease-in-out infinite;
}

@keyframes search-glow {
  0%, 100% { box-shadow: 0 4px 16px rgba(58, 117, 213, 0.15), 0 0 0 1px rgba(0, 195, 255, 0.18); }
  50% { box-shadow: 0 4px 24px rgba(58, 117, 213, 0.22), 0 0 0 1px rgba(0, 195, 255, 0.45), 0 0 18px var(--electric-blue-glow); }
}

.search-icon {
  position: absolute;
  left: 1rem;
  z-index: 2;
  pointer-events: none;
  display: flex;
  align-items: center;
}

#searchInput {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 1.2rem;
  padding: 0.5rem 0 0.5rem 2.5rem;
}

.company-search-form input:focus {
  box-shadow: 0 0 0 2px #3a75d5;
  transition: box-shadow .2s;
  background: #f7feff;
  border-radius: 14px;
}

.search-btn {
  flex-shrink: 0;
  margin-left: 0.5rem;
  padding: 0.65rem 1.2rem;
  border: none;
  border-radius: 2rem;
  background: linear-gradient(90deg, #1E3A8A 0%, var(--electric-blue) 150%);
  color: white;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
}
.search-btn:hover {
  background: linear-gradient(90deg, #3350c2 0%, var(--electric-blue-soft) 150%);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px var(--electric-blue-glow);
}

.suggestions-list {
  position: absolute;
  top: 3.2rem;
  left: 50%;
  width: 100%;
  max-width: 500px;
  transform: translateX(-50%);
  background: white;
  border-radius: 0.5rem;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  display: none;
  z-index: 10;
}

.suggestion-item {
  padding: 10px 18px;
  cursor: pointer;
  transition: background 0.15s;
}
.suggestion-item:hover, .suggestion-item.active {
  background: #eaf1fb;
}

.search-hint {
  margin-top: 0.75rem;
  color: #777;
  font-size: 0.97rem;
}

.suggestion-chip {
  background: #eaf1fb;
  color: #3a75d5;
  border-radius: 1rem;
  padding: 0.15rem 0.7rem;
  font-weight: 500;
  cursor: pointer;
  margin-right: 0.2em;
  transition: background 0.15s, color 0.15s, transform 0.15s, box-shadow 0.15s;
}
.suggestion-chip:hover, .suggestion-chip:focus {
  background: var(--electric-blue);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px var(--electric-blue-glow);
}

/* ===== "Coming soon" service badge (reused here for the info-list-enhanced
   badge) ===== */

.service-badge {
  display: inline-block;
  font-size: 0.62em;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  background: var(--color-surface-tint);
  border-radius: 1em;
  padding: 0.2em 0.6em;
  margin-left: 0.4em;
  vertical-align: middle;
}

/* ===== Dark mode ===== */

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) body.bg-pan-left {
    background:
      radial-gradient(circle at 20% 30%, rgba(46, 130, 100, 0.35) 0%, transparent 55%),
      radial-gradient(circle at 80% 20%, rgba(58, 117, 213, 0.35) 0%, transparent 55%),
      linear-gradient(120deg, #0c1830 0%, #10142c 45%, #0b1f33 75%, #0c1830 100%);
  }
  :root:not([data-theme="light"]) .info-list-enhanced {
    background: linear-gradient(135deg, rgba(24, 33, 48, 0.55) 0%, rgba(24, 33, 48, 0.55) 100%);
    border-color: rgba(255, 255, 255, 0.12);
  }
  :root:not([data-theme="light"]) .info-list-enhanced:hover {
    background: linear-gradient(135deg, rgba(24, 33, 48, 0.7) 0%, rgba(24, 33, 48, 0.4) 100%);
  }
  :root:not([data-theme="light"]) .info-item { color: var(--color-text); }
  :root:not([data-theme="light"]) .info-item strong { color: var(--electric-blue-soft); }
  :root:not([data-theme="light"]) .subtitle,
  :root:not([data-theme="light"]) .search-hint { color: var(--color-text-secondary); }
  :root:not([data-theme="light"]) .search-container,
  :root:not([data-theme="light"]) .suggestions-list { background: var(--color-surface); }
  :root:not([data-theme="light"]) .company-search-form input:focus { background: var(--color-surface-soft); }
  :root:not([data-theme="light"]) .suggestion-item:hover,
  :root:not([data-theme="light"]) .suggestion-item.active { background: var(--color-surface-tint); }
  :root:not([data-theme="light"]) .suggestion-chip { background: var(--color-surface-tint); color: var(--electric-blue-soft); }
}

:root[data-theme="dark"] body.bg-pan-left {
  background:
    radial-gradient(circle at 20% 30%, rgba(46, 130, 100, 0.35) 0%, transparent 55%),
    radial-gradient(circle at 80% 20%, rgba(58, 117, 213, 0.35) 0%, transparent 55%),
    linear-gradient(120deg, #0c1830 0%, #10142c 45%, #0b1f33 75%, #0c1830 100%);
}
:root[data-theme="dark"] .info-list-enhanced {
  background: linear-gradient(135deg, rgba(24, 33, 48, 0.55) 0%, rgba(24, 33, 48, 0.55) 100%);
  border-color: rgba(255, 255, 255, 0.12);
}
:root[data-theme="dark"] .info-list-enhanced:hover {
  background: linear-gradient(135deg, rgba(24, 33, 48, 0.7) 0%, rgba(24, 33, 48, 0.4) 100%);
}
:root[data-theme="dark"] .info-item { color: var(--color-text); }
:root[data-theme="dark"] .info-item strong { color: var(--electric-blue-soft); }
:root[data-theme="dark"] .subtitle,
:root[data-theme="dark"] .search-hint { color: var(--color-text-secondary); }
:root[data-theme="dark"] .search-container,
:root[data-theme="dark"] .suggestions-list { background: var(--color-surface); }
:root[data-theme="dark"] .company-search-form input:focus { background: var(--color-surface-soft); }
:root[data-theme="dark"] .suggestion-item:hover,
:root[data-theme="dark"] .suggestion-item.active { background: var(--color-surface-tint); }
:root[data-theme="dark"] .suggestion-chip { background: var(--color-surface-tint); color: var(--electric-blue-soft); }

/* ===== Small screens ===== */

@media (max-width: 600px) {
  main {
    padding: 1rem;
  }
  header {
    padding: 0.5rem;
  }
  footer {
    padding: 0.5rem;
  }
  .search-container {
    margin: 1rem auto;
    max-width: 99vw;
  }
  .company-search-form {
    max-width: 100%;
  }
  .search-container, #suggestions {
    width: 100%;
    max-width: 100%;
  }
  .search-container {
    flex-direction: row;
    padding: 0.4rem;
    border-radius: 2rem;
  }
  .search-icon {
    top: 50%;
    transform: translateY(-50%);
    left: 1rem;
  }
  #searchInput {
    font-size: 1rem;
    padding-left: 2.3rem;
    min-width: 0;
  }
  .search-btn {
    flex-shrink: 0;
    padding: 0.6rem 1rem;
    border-radius: 1.5rem;
    margin-left: 0.4rem;
    font-size: 0.9rem;
  }
}
