/* yesitsyes.com - The Tech Deal Observatory
   Design: Bloomberg Terminal meets Wikipedia
   Colors: Dark Blue (#0f172a) + Amber (#f59e0b) + Slate (#f8fafc)
*/

/* ============================================
   CSS VARIABLES & RESET
============================================ */
:root {
  --color-primary: #0f172a;
  --color-primary-light: #1e293b;
  --color-accent: #f59e0b;
  --color-accent-hover: #d97706;
  --color-bg: #f8fafc;
  --color-bg-alt: #e2e8f0;
  --color-text: #1e293b;
  --color-text-muted: #64748b;
  --color-border: #cbd5e1;
  --color-success: #10b981;
  --color-danger: #ef4444;

  --font-heading: 'IBM Plex Serif', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  --max-width: 1200px;
  --timeline-width: 3px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.7;
  min-height: 100vh;
}

/* ============================================
   TYPOGRAPHY
============================================ */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.3;
  color: var(--color-primary);
}

h1 { font-size: 2.5rem; margin-bottom: 1rem; }
h2 { font-size: 1.75rem; margin: 2rem 0 1rem; }
h3 { font-size: 1.25rem; margin: 1.5rem 0 0.75rem; }

p { margin-bottom: 1rem; }

a {
  color: var(--color-primary);
  text-decoration: none;
  border-bottom: 1px solid var(--color-accent);
  transition: all 0.2s;
}

a:hover {
  color: var(--color-accent);
  border-bottom-color: var(--color-accent);
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.9em;
}

/* ============================================
   LAYOUT
============================================ */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

@media (max-width: 768px) {
  .grid-2, .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   HEADER - Minimal Data-Driven
============================================ */
.site-header {
  background: var(--color-primary);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 3px solid var(--color-accent);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border: none;
}

.logo img {
  height: 40px;
  width: auto;
}

.logo-text {
  color: white;
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.5px;
}

.logo-tagline {
  color: var(--color-accent);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  display: block;
  margin-top: -2px;
}

.nav-main {
  display: flex;
  gap: 1.5rem;
}

.nav-main a {
  color: rgba(255,255,255,0.8);
  font-size: 0.85rem;
  border: none;
  padding: 0.5rem 0;
  position: relative;
}

.nav-main a:hover {
  color: white;
}

.nav-main a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-accent);
  transition: width 0.3s;
}

.nav-main a:hover::after {
  width: 100%;
}

/* Mobile menu */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
}

@media (max-width: 768px) {
  .menu-toggle { display: block; }
  .nav-main {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-primary);
    flex-direction: column;
    padding: 1rem;
    gap: 0;
  }
  .nav-main.active { display: flex; }
  .nav-main a {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
  }
}

/* ============================================
   HERO - Observatory Style
============================================ */
.hero {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
  color: white;
  padding: 4rem 0;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background:
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 50px,
      rgba(255,255,255,0.02) 50px,
      rgba(255,255,255,0.02) 51px
    );
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
}

.hero h1 {
  color: white;
  font-size: 2.75rem;
  margin-bottom: 0.5rem;
}

.hero-tagline {
  color: var(--color-accent);
  font-size: 1.1rem;
  margin-bottom: 2rem;
  font-family: var(--font-mono);
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin-top: 2rem;
}

.stat-box {
  text-align: center;
}

.stat-number {
  font-family: var(--font-mono);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--color-accent);
  display: block;
}

.stat-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(255,255,255,0.7);
}

/* Search Bar */
.search-container {
  max-width: 600px;
  margin: 2rem auto 0;
}

.search-bar {
  display: flex;
  background: white;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.search-bar input {
  flex: 1;
  padding: 1rem 1.25rem;
  border: none;
  font-size: 1rem;
  font-family: var(--font-body);
}

.search-bar input:focus {
  outline: none;
}

.search-bar button {
  background: var(--color-accent);
  border: none;
  padding: 1rem 1.5rem;
  color: var(--color-primary);
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.search-bar button:hover {
  background: var(--color-accent-hover);
}

/* ============================================
   FILTER BAR
============================================ */
.filter-bar {
  background: white;
  border-bottom: 1px solid var(--color-border);
  padding: 1rem 0;
  position: sticky;
  top: 60px;
  z-index: 90;
}

.filter-inner {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  align-items: center;
}

.filter-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.filter-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--color-text-muted);
}

.filter-select {
  padding: 0.5rem 2rem 0.5rem 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  font-size: 0.85rem;
  font-family: var(--font-body);
  background: white url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2364748b' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat right 0.75rem center;
  appearance: none;
  cursor: pointer;
}

.filter-select:focus {
  outline: none;
  border-color: var(--color-accent);
}

/* ============================================
   TIMELINE - Core Feature
============================================ */
.timeline-section {
  padding: 3rem 0;
}

.timeline {
  position: relative;
  padding-left: 3rem;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--timeline-width);
  background: var(--color-border);
}

.timeline-item {
  position: relative;
  padding-bottom: 2rem;
  padding-left: 2rem;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -3rem;
  top: 0.5rem;
  width: 14px;
  height: 14px;
  background: var(--color-accent);
  border-radius: 50%;
  border: 3px solid var(--color-bg);
  box-shadow: 0 0 0 3px var(--color-accent);
}

.timeline-item:hover::before {
  transform: scale(1.2);
}

.timeline-date {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-bottom: 0.25rem;
}

.timeline-card {
  background: white;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  padding: 1.25rem;
  transition: all 0.2s;
  display: block;
}

.timeline-card:hover {
  border-color: var(--color-accent);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transform: translateX(4px);
}

.timeline-title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 0.5rem;
}

.timeline-meta {
  display: flex;
  gap: 1rem;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-bottom: 0.5rem;
}

.timeline-meta span {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.timeline-excerpt {
  font-size: 0.9rem;
  color: var(--color-text);
  line-height: 1.5;
}

/* Deal Type Tags */
.deal-tag {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 3px;
  margin-right: 0.5rem;
}

.deal-tag.acquihire {
  background: #dbeafe;
  color: #1e40af;
}

.deal-tag.strategic {
  background: #dcfce7;
  color: #166534;
}

.deal-tag.product {
  background: #fef3c7;
  color: #92400e;
}

.deal-tag.mega {
  background: #fce7f3;
  color: #9d174d;
}

/* Deal Amount */
.deal-amount {
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--color-success);
}

.deal-amount.undisclosed {
  color: var(--color-text-muted);
  font-style: italic;
}

/* ============================================
   SIDEBAR - Quick Stats
============================================ */
.main-with-sidebar {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 2rem;
  padding: 2rem 0;
}

@media (max-width: 960px) {
  .main-with-sidebar {
    grid-template-columns: 1fr;
  }
  .sidebar { order: -1; }
}

.sidebar {
  position: sticky;
  top: 120px;
  align-self: start;
}

.sidebar-box {
  background: white;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.sidebar-title {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--color-text-muted);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--color-accent);
}

.stat-row {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--color-bg-alt);
}

.stat-row:last-child {
  border-bottom: none;
}

.stat-row .label {
  color: var(--color-text-muted);
  font-size: 0.85rem;
}

.stat-row .value {
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--color-primary);
}

/* Top Acquirers List */
.top-list {
  list-style: none;
}

.top-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--color-bg-alt);
}

.top-list li:last-child {
  border-bottom: none;
}

.top-list .rank {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--color-text-muted);
  width: 1.5rem;
}

.top-list .name {
  flex: 1;
  font-size: 0.9rem;
}

.top-list .count {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--color-accent);
  font-weight: 600;
}

/* ============================================
   ARTICLE PAGES
============================================ */
.article-header {
  background: var(--color-primary);
  color: white;
  padding: 3rem 0 2rem;
}

.article-header h1 {
  color: white;
  max-width: 800px;
}

.article-meta {
  display: flex;
  gap: 1.5rem;
  margin-top: 1rem;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.7);
}

.article-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem 0 4rem;
}

.article-content h2 {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--color-border);
}

.article-content h2:first-of-type {
  border-top: none;
  padding-top: 0;
}

/* Data Tables */
.data-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.9rem;
}

.data-table th,
.data-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}

.data-table th {
  background: var(--color-bg-alt);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--color-text-muted);
}

.data-table tr:hover {
  background: var(--color-bg);
}

.data-table .mono {
  font-family: var(--font-mono);
}

/* Info Box */
.info-box {
  background: var(--color-bg);
  border-left: 4px solid var(--color-accent);
  padding: 1.25rem 1.5rem;
  margin: 1.5rem 0;
}

.info-box h4 {
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

/* FAQ Section */
.faq-section {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 2px solid var(--color-primary);
}

.faq-item {
  border-bottom: 1px solid var(--color-border);
  padding: 1.25rem 0;
}

.faq-question {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--color-primary);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-question::after {
  content: '+';
  font-size: 1.5rem;
  color: var(--color-accent);
  transition: transform 0.3s;
}

.faq-item.active .faq-question::after {
  transform: rotate(45deg);
}

.faq-answer {
  padding-top: 1rem;
  display: none;
}

.faq-item.active .faq-answer {
  display: block;
}

/* ============================================
   FOOTER
============================================ */
.site-footer {
  background: var(--color-primary);
  color: rgba(255,255,255,0.7);
  padding: 3rem 0 1.5rem;
  margin-top: 4rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.footer-about {
  font-size: 0.9rem;
  line-height: 1.6;
}

.footer-title {
  color: white;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 1rem;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  color: rgba(255,255,255,0.7);
  font-size: 0.9rem;
  border: none;
}

.footer-links a:hover {
  color: var(--color-accent);
}

.footer-bottom {
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
}

/* ============================================
   UTILITIES
============================================ */
.text-center { text-align: center; }
.text-muted { color: var(--color-text-muted); }
.text-accent { color: var(--color-accent); }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background: var(--color-accent);
  color: var(--color-primary);
  font-weight: 600;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn:hover {
  background: var(--color-accent-hover);
  color: var(--color-primary);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--color-accent);
  color: var(--color-accent);
}

.btn-outline:hover {
  background: var(--color-accent);
  color: var(--color-primary);
}

/* Schema Markup Hidden */
.schema-data {
  display: none;
}

/* ============================================
   INFOGRAPHICS
============================================ */
.infographic-container {
  margin: 2rem 0;
  text-align: center;
}

.infographic-container img,
.infographic {
  max-width: 100%;
  max-height: 500px;
  width: auto;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  object-fit: contain;
}

.infographic-container figcaption {
  margin-top: 0.75rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  font-style: italic;
}

/* ============================================
   STICKY NAVIGATION
============================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--color-primary);
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
