/* ─────────────────────────────────────────────
   Drovus News — Yahoo News layout
   ───────────────────────────────────────────── */
:root {
  --brand-red:     #e00;
  --brand-dark:    #1a1a1a;
  --brand-gray:    #6b7280;
  --brand-light:   #f4f4f4;
  --brand-white:   #ffffff;
  --accent-orange: #e85d04;
  --accent-green:  #2d6a4f;
  --accent-purple: #7b2d8b;
  --accent-blue:   #1a6496;
  --section-border: 3px solid var(--brand-red);
  --radius: 6px;
  --shadow: 0 1px 4px rgba(0,0,0,.08);
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 15px;
  color: var(--brand-dark);
  background: #f0f0f0;
  line-height: 1.55;
  padding-bottom: 60px; /* room for mobile bottom nav */
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--brand-red); }
img { max-width: 100%; height: auto; display: block; }

/* ── Breaking news bar ── */
.breaking-bar {
  background: var(--brand-red);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .5px;
  padding: 6px 0;
  overflow: hidden;
}
.breaking-bar__inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.breaking-bar__label {
  white-space: nowrap;
  background: rgba(0,0,0,.25);
  padding: 2px 8px;
  border-radius: 3px;
  text-transform: uppercase;
}
.breaking-bar__ticker {
  flex: 1;
  overflow: hidden;
  white-space: nowrap;
  mask-image: linear-gradient(to right, transparent, #fff 8%, #fff 92%, transparent);
}
.ticker-items { display: inline-flex; gap: 60px; animation: ticker 40s linear infinite; }
.ticker-items span { cursor: pointer; }
.ticker-items span:hover { text-decoration: underline; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ── Site header ── */
.site-header {
  background: var(--brand-white);
  border-bottom: 1px solid #e5e5e5;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 1px 3px rgba(0,0,0,.1);
}
.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  align-items: center;
  height: 60px;
  gap: 24px;
}
.site-logo {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -1px;
  color: var(--brand-dark);
  flex-shrink: 0;
}
.site-logo span { color: var(--brand-red); }
.site-logo__country {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  color: var(--brand-gray);
  margin-top: 1px;
}

/* ── Navigation ── */
.primary-nav { flex: 1; }
.primary-nav ul { display: flex; list-style: none; gap: 2px; }
.primary-nav a {
  display: block;
  padding: 6px 10px;
  font-size: 13px;
  font-weight: 600;
  border-radius: var(--radius);
  transition: background .15s, color .15s;
  color: var(--brand-dark);
}
.primary-nav a:hover { background: var(--brand-light); color: var(--brand-red); }

.header-search {
  display: flex;
  align-items: center;
  background: var(--brand-light);
  border: 1px solid #ddd;
  border-radius: 20px;
  padding: 6px 14px;
  gap: 8px;
  flex-shrink: 0;
}
.header-search input {
  border: none;
  background: transparent;
  font-size: 13px;
  outline: none;
  width: 160px;
  color: var(--brand-dark);
}
.header-search button {
  border: none;
  background: none;
  cursor: pointer;
  color: var(--brand-gray);
  font-size: 15px;
  padding: 0;
}
.header-search:focus-within { border-color: var(--brand-red); }

/* ── Section tabs ── */
.section-tabs {
  background: var(--brand-white);
  border-bottom: 1px solid #e5e5e5;
}
.section-tabs__inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  overflow-x: auto;
  scrollbar-width: none;
}
.section-tabs__inner::-webkit-scrollbar { display: none; }
.section-tab {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  margin-bottom: -1px;
  cursor: pointer;
  transition: color .15s, border-color .15s;
  color: var(--brand-gray);
}
.section-tab:hover { color: var(--brand-dark); }
.section-tab.active { color: var(--brand-dark); border-color: var(--brand-red); }

/* ── Layout ── */
.page-wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 20px 16px;
}
.content-grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 24px;
  align-items: start;
}

/* ── Hero section — Yahoo style: text BELOW image ── */
.hero-section { margin-bottom: 24px; }
.hero-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 3px;
  background: #ddd;
  border-radius: var(--radius);
  overflow: hidden;
}

/* Main hero story */
.hero-main {
  background: var(--brand-white);
  display: flex;
  flex-direction: column;
}
.hero-img-link { display: block; overflow: hidden; }
.hero-img-link img {
  width: 100%;
  height: 320px;
  object-fit: cover;
  transition: transform .3s;
}
.hero-img-link:hover img { transform: scale(1.02); }
.hero-text {
  padding: 16px 18px 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.hero-text .cat-badge { align-self: flex-start; }
.hero-text h2 {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.25;
  color: var(--brand-dark);
}
.hero-text h2 a:hover { color: var(--brand-red); }
.hero-text .hero-excerpt {
  font-size: 14px;
  color: #444;
  line-height: 1.5;
}
.hero-text .story-meta { margin-top: auto; padding-top: 8px; }

/* Side stack of 2 small cards */
.hero-stack {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.story-card-sm {
  background: var(--brand-white);
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.card-sm-img { display: block; overflow: hidden; }
.card-sm-img img {
  width: 100%;
  height: 130px;
  object-fit: cover;
  transition: transform .3s;
}
.card-sm-img:hover img { transform: scale(1.03); }
.card-sm-text {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}
.card-sm-text h3 {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--brand-dark);
}
.card-sm-text h3 a:hover { color: var(--brand-red); }

/* ── Regular story cards (image above, text below) ── */
.story-card {
  background: var(--brand-white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: box-shadow .15s;
  display: flex;
  flex-direction: column;
}
.story-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,.12); }

.card-img-link { display: block; overflow: hidden; }
.card-img-link img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  transition: transform .3s;
}
.card-img-link:hover img { transform: scale(1.03); }

.story-card .card-body {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}
.story-card h3 {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.35;
  color: var(--brand-dark);
}
.story-card h3 a:hover { color: var(--brand-red); }
.story-card p.excerpt {
  font-size: 13px;
  color: #555;
  line-height: 1.5;
}

/* ── Horizontal card (list-style) ── */
.story-hcard {
  display: flex;
  gap: 12px;
  padding: 12px;
  background: var(--brand-white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.story-hcard:hover { box-shadow: 0 3px 12px rgba(0,0,0,.1); }
.hcard-img { display: block; flex-shrink: 0; overflow: hidden; border-radius: 4px; }
.hcard-img img {
  width: 110px;
  height: 74px;
  object-fit: cover;
  border-radius: 4px;
  transition: transform .3s;
}
.hcard-img:hover img { transform: scale(1.05); }
.story-hcard__body { display: flex; flex-direction: column; justify-content: space-between; }
.story-hcard h3 { font-size: 14px; font-weight: 700; line-height: 1.3; color: var(--brand-dark); }
.story-hcard h3 a:hover { color: var(--brand-red); }

/* ── Section blocks ── */
.news-section { margin-bottom: 28px; }
.section-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: var(--section-border);
}
.section-header h2 {
  font-size: 16px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .5px;
}
.section-header a { font-size: 12px; color: var(--brand-gray); margin-left: auto; }
.section-header a:hover { color: var(--brand-red); }

.section-header--business  { border-color: #1a6496; }
.section-header--business h2  { color: #1a6496; }
.section-header--technology { border-color: var(--accent-green); }
.section-header--technology h2 { color: var(--accent-green); }
.section-header--health { border-color: #c00; }
.section-header--health h2 { color: #c00; }
.section-header--education { border-color: var(--accent-purple); }
.section-header--education h2 { color: var(--accent-purple); }
.section-header--entertainment { border-color: var(--accent-orange); }
.section-header--entertainment h2 { color: var(--accent-orange); }
.section-header--sports { border-color: #155724; }
.section-header--sports h2 { color: #155724; }
.section-header--lifestyle { border-color: #8b4513; }
.section-header--lifestyle h2 { color: #8b4513; }
.section-header--world { border-color: #333; }
.section-header--world h2 { color: #333; }

.card-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.card-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }

/* ── Category badge ── */
.cat-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  padding: 2px 7px;
  border-radius: 3px;
}
.cat-badge--business      { background: #1a6496; color: #fff; }
.cat-badge--technology    { background: var(--accent-green); color: #fff; }
.cat-badge--health        { background: #c00; color: #fff; }
.cat-badge--education     { background: var(--accent-purple); color: #fff; }
.cat-badge--entertainment { background: var(--accent-orange); color: #fff; }
.cat-badge--sports        { background: #155724; color: #fff; }
.cat-badge--lifestyle     { background: #8b4513; color: #fff; }
.cat-badge--world         { background: #333; color: #fff; }
.cat-badge--politics      { background: #5c0a00; color: #fff; }
.cat-badge--science       { background: #0a3f5c; color: #fff; }
.cat-badge--default, .cat-badge--uncategorized { background: var(--brand-gray); color: #fff; }

/* ── Story meta ── */
.story-meta {
  font-size: 11px;
  color: var(--brand-gray);
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.source-name { font-weight: 700; color: #444; }
.dot { opacity: .4; }

/* ── Sidebar ── */
.sidebar { display: flex; flex-direction: column; gap: 18px; }

.widget-box {
  background: var(--brand-white);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
}
.widget-title {
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .7px;
  padding-bottom: 10px;
  margin-bottom: 12px;
  border-bottom: 2px solid var(--brand-red);
  color: var(--brand-dark);
}

.trending-list { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.trending-item { display: flex; gap: 10px; align-items: flex-start; }
.trending-num {
  font-size: 22px;
  font-weight: 900;
  color: #e5e5e5;
  line-height: 1;
  flex-shrink: 0;
  width: 26px;
}
.trending-item.top .trending-num { color: var(--brand-red); }
.trending-title { font-size: 13px; font-weight: 600; line-height: 1.3; }
.trending-title a:hover { color: var(--brand-red); }
.trending-meta { font-size: 11px; color: var(--brand-gray); margin-top: 2px; }

.latest-list { display: flex; flex-direction: column; gap: 12px; }
.latest-item { display: flex; gap: 10px; }
.latest-item img { width: 72px; height: 48px; object-fit: cover; border-radius: 4px; flex-shrink: 0; }
.latest-item__body { flex: 1; }
.latest-item__body h4 { font-size: 13px; font-weight: 700; line-height: 1.3; }
.latest-item__body h4 a:hover { color: var(--brand-red); }
.latest-item__body .story-meta { margin-top: 3px; }

.newsletter-box { text-align: center; }
.newsletter-box h3 { font-size: 15px; font-weight: 800; margin-bottom: 6px; }
.newsletter-box p { font-size: 12px; color: var(--brand-gray); margin-bottom: 12px; }
.newsletter-form { display: flex; flex-direction: column; gap: 8px; }
.newsletter-form input {
  border: 1px solid #ddd;
  border-radius: 4px;
  padding: 9px 12px;
  font-size: 13px;
  outline: none;
  width: 100%;
}
.newsletter-form input:focus { border-color: var(--brand-red); }
.newsletter-form button {
  background: var(--brand-red);
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 10px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.newsletter-form button:hover { background: #c00; }

/* ── Ad zones ── */
.ad-zone { width: 100%; overflow: hidden; line-height: 0; }
.ad-zone--leaderboard {
  display: flex; justify-content: center;
  padding: 8px 0; background: #f8f8f8;
  border-top: 1px solid #eee; border-bottom: 1px solid #eee;
}
.ad-zone--in-article { display: flex; justify-content: center; margin: 20px 0; }
.ad-zone--sidebar-top, .ad-zone--sidebar-mid { display: flex; justify-content: center; margin-bottom: 16px; }
.ad-zone--between-posts {
  display: flex; justify-content: center;
  margin: 24px 0; padding: 12px 0;
  background: #f8f8f8;
  border-top: 1px solid #eee; border-bottom: 1px solid #eee;
}
.ad-zone--footer {
  display: flex; justify-content: center;
  padding: 12px 0; background: #f2f2f2;
  border-top: 1px solid #e0e0e0;
}

/* ── Site footer ── */
.site-footer {
  background: var(--brand-dark);
  color: #ccc;
  margin-top: 40px;
  margin-bottom: 60px; /* above mobile bottom nav */
}
.footer-main {
  max-width: 1280px;
  margin: 0 auto;
  padding: 36px 16px 24px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
}
.footer-brand .site-logo { color: #fff; margin-bottom: 10px; font-size: 22px; }
.footer-brand p { font-size: 13px; line-height: 1.6; }
.footer-col h4 {
  color: #fff; font-size: 12px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .6px;
  margin-bottom: 12px;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.footer-col a { font-size: 13px; color: #aaa; }
.footer-col a:hover { color: var(--brand-red); }
.footer-bottom {
  border-top: 1px solid #333;
  padding: 14px 16px;
  text-align: center;
  font-size: 12px;
  color: #666;
}

/* ── Single post ── */
.single-header { max-width: 800px; margin: 0 auto 24px; }
.single-header .cat-badge { margin-bottom: 12px; }
.single-header h1 { font-size: 32px; font-weight: 900; line-height: 1.15; margin-bottom: 14px; }
.single-header .byline {
  font-size: 13px; color: var(--brand-gray);
  display: flex; gap: 12px; flex-wrap: wrap; align-items: center;
  margin-bottom: 20px; padding-bottom: 20px; border-bottom: 1px solid #eee;
}
.single-hero img { width: 100%; max-height: 520px; object-fit: cover; border-radius: var(--radius); margin-bottom: 28px; }
.single-body { max-width: 800px; margin: 0 auto; font-size: 16px; line-height: 1.75; }
.single-body p { margin-bottom: 18px; }
.single-body h2 { font-size: 22px; font-weight: 800; margin: 28px 0 12px; }
.single-body blockquote {
  border-left: 4px solid var(--brand-red);
  padding: 12px 20px; margin: 24px 0;
  background: var(--brand-light); font-style: italic;
}

.share-bar { display: flex; gap: 10px; align-items: center; margin: 28px 0; flex-wrap: wrap; }
.share-bar span { font-size: 13px; font-weight: 700; }
.share-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: 20px;
  font-size: 13px; font-weight: 600; cursor: pointer;
  border: none; color: #fff;
}
.share-btn--twitter  { background: #1da1f2; }
.share-btn--facebook { background: #1877f2; }
.share-btn--whatsapp { background: #25d366; }
.share-btn--copy     { background: var(--brand-gray); }

.related-posts { margin-top: 48px; padding-top: 24px; border-top: var(--section-border); }
.related-posts h2 { font-size: 18px; font-weight: 800; text-transform: uppercase; margin-bottom: 20px; }

/* ── Mobile hamburger ── */
.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  padding: 8px;
  margin-left: auto;
  background: none;
  border: none;
}
.mobile-menu-toggle span {
  width: 22px; height: 2px;
  background: var(--brand-dark);
  border-radius: 2px;
  transition: .25s;
}

/* ── Mobile bottom nav (Yahoo-style) ── */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: var(--brand-white);
  border-top: 1px solid #e5e5e5;
  z-index: 2000;
  height: 56px;
  box-shadow: 0 -2px 8px rgba(0,0,0,.08);
}
.mobile-bottom-nav ul {
  display: flex;
  list-style: none;
  height: 100%;
}
.mobile-bottom-nav li {
  flex: 1;
  display: flex;
}
.mobile-bottom-nav a {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .4px;
  color: var(--brand-gray);
  text-decoration: none;
  transition: color .15s;
}
.mobile-bottom-nav a:hover,
.mobile-bottom-nav a.active { color: var(--brand-red); }
.mobile-bottom-nav .nav-icon { font-size: 18px; line-height: 1; }

/* ── Countries section ── */
.countries-section { margin-top: 40px; padding-top: 24px; border-top: var(--section-border); }
.countries-section .section-header { justify-content: space-between; margin-bottom: 16px; }
.countries-section .section-header h2 { font-size: 16px; font-weight: 800; text-transform: uppercase; margin: 0; }
.countries-count { font-size: 12px; color: #888; font-weight: 600; }
.countries-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 8px;
}
.country-card {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 10px 6px;
  background: var(--brand-white);
  border-radius: 8px;
  border: 1px solid #e8e8e8;
  transition: background .2s, transform .15s, border-color .15s;
}
.country-card:hover {
  background: #fff0f0; transform: translateY(-2px); border-color: var(--brand-red);
}
.country-card__flag { font-size: 26px; line-height: 1; }
.country-card__name { font-size: 10px; font-weight: 600; color: var(--brand-dark); text-align: center; line-height: 1.2; }

/* ── Utility ── */
.live-badge {
  background: var(--brand-red); color: #fff;
  font-size: 10px; font-weight: 700;
  padding: 2px 6px; border-radius: 3px;
  text-transform: uppercase;
  animation: pulse 1.5s infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .6; } }

/* ══════════════════════════════
   RESPONSIVE
══════════════════════════════ */
@media (max-width: 1024px) {
  .content-grid { grid-template-columns: 1fr; }
  .sidebar { display: grid; grid-template-columns: repeat(2, 1fr); }
  .footer-main { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  body { font-size: 14px; }

  /* Show mobile bottom nav */
  .mobile-bottom-nav { display: block; }

  /* Collapse desktop nav */
  .primary-nav { display: none; }
  .primary-nav.open {
    display: flex; position: absolute;
    top: 60px; left: 0; right: 0;
    background: #fff; flex-direction: column;
    box-shadow: 0 8px 24px rgba(0,0,0,.12);
    padding: 12px 0; z-index: 999;
  }
  .primary-nav.open ul { flex-direction: column; }
  .mobile-menu-toggle { display: flex; }
  .header-search { display: none; }

  /* Hero stacks vertically */
  .hero-grid { grid-template-columns: 1fr; }
  .hero-stack { flex-direction: row; gap: 3px; }
  .story-card-sm { flex: 1; }
  .hero-img-link img { height: 220px; }
  .hero-text h2 { font-size: 18px; }

  /* Cards single column */
  .card-grid-3, .card-grid-2 { grid-template-columns: 1fr; }

  /* Sidebar single column */
  .sidebar { grid-template-columns: 1fr; }

  /* Footer */
  .footer-main { grid-template-columns: 1fr; gap: 20px; }
  .site-footer { margin-bottom: 56px; }

  /* Countries */
  .countries-grid { grid-template-columns: repeat(auto-fill, minmax(80px, 1fr)); gap: 6px; }
  .country-card__flag { font-size: 22px; }

  /* hcard smaller on mobile */
  .hcard-img img { width: 90px; height: 62px; }
}

@media (max-width: 480px) {
  .hero-stack { flex-direction: column; }
  .story-card-sm { flex: none; }
  .hero-img-link img { height: 200px; }
  .page-wrap { padding: 12px 10px; }
}
