/* index.php — page-specific styles */
/* ════════════════════════════════════════
   HOMEPAGE — Editorial newspaper style
   Rounded cards, warm paper tones,
   structured grid like Times of India / Dainik Jagran
════════════════════════════════════════ */

body { background: var(--smoke); }

.main-wrap { padding: 20px 0 50px; }
.page-grid  {
  display: grid;
  grid-template-columns: 1fr 290px;
  gap: 26px; align-items: start;
}
@media(max-width: 960px) { .page-grid { grid-template-columns: 1fr; } }

/* ── DATE DIVIDER ── */
.date-divider {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 20px; color: var(--muted);
  font-size: .72rem; text-transform: uppercase; letter-spacing: 1px; font-weight: 600;
}
.date-divider::before, .date-divider::after {
  content: ''; flex: 1; height: 1px; background: var(--border);
}

/* ════════════════════════
   HERO SECTION
════════════════════════ */
.hero-section { margin-bottom: 28px; }

.hero-wrap {
  display: grid;
  grid-template-columns: 1.85fr 1fr;
  gap: 14px;
}
@media(max-width: 720px) { .hero-wrap { grid-template-columns: 1fr; } }

/* Big hero card */
.hero-main-card {
  position: relative; overflow: hidden;
  border-radius: var(--r-xl);
  min-height: 400px;
  box-shadow: var(--shadow-md);
}
@media(max-width: 480px) { .hero-main-card { min-height: 260px; border-radius: var(--r-lg); } }

.hero-main-card img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .5s ease;
}
.hero-main-card:hover img { transform: scale(1.04); }
.hero-main-card .hero-gradient {
  position: absolute; inset: 0;
  background: linear-gradient(
    to top,
    rgba(8,8,8,.93) 0%,
    rgba(8,8,8,.5) 40%,
    rgba(0,0,0,.1) 70%,
    transparent 100%
  );
}
.hero-main-card .hero-content {
  position: absolute; bottom: 0; left: 0; right: 0;
  padding: 24px 22px 22px;
}
.hero-main-card .hero-content .cat-badge {
  margin-bottom: 10px; font-size: .64rem;
}
.hero-main-card h2 {
  font-family: var(--font-hindi);
  font-size: clamp(1.15rem, 2.5vw, 1.65rem);
  line-height: 1.42; color: #fff;
  margin-bottom: 10px;
  text-shadow: 0 1px 6px rgba(0,0,0,.5);
}
.hero-main-card h2 a { color: #fff; }
.hero-main-card h2 a:hover { color: var(--accent); }
.hero-main-card .hero-meta {
  display: flex; gap: 14px; flex-wrap: wrap;
  font-size: .7rem; color: rgba(255,255,255,.65);
  align-items: center;
}
.hero-main-card .hero-meta .read-time {
  background: rgba(255,255,255,.15);
  padding: 2px 9px; border-radius: 20px;
  font-size: .64rem; color: rgba(255,255,255,.8);
  backdrop-filter: blur(4px);
}

/* Right stacked stories */
.hero-stack { display: flex; flex-direction: column; gap: 14px; }

.hero-stack-item {
  display: flex; gap: 0; background: var(--white);
  border-radius: var(--r-md); overflow: hidden;
  box-shadow: var(--shadow-sm); transition: all .22s;
  border: 1px solid var(--border-light);
}
.hero-stack-item:hover { transform: translateX(3px); box-shadow: var(--shadow-md); }
.hero-stack-item .hs-img {
  flex: 0 0 110px; overflow: hidden;
}
@media(max-width: 420px) { .hero-stack-item .hs-img { flex: 0 0 80px; } }
.hero-stack-item .hs-img img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .3s;
}
.hero-stack-item:hover .hs-img img { transform: scale(1.07); }
.hero-stack-item .hs-body {
  flex: 1; padding: 12px 14px;
  display: flex; flex-direction: column; justify-content: center; gap: 6px;
}
.hero-stack-item h3 {
  font-family: var(--font-hindi);
  font-size: .88rem; line-height: 1.42; color: var(--dark);
  font-weight: 700;
}
.hero-stack-item h3 a:hover { color: var(--primary); }
.hero-stack-item .hs-meta {
  font-size: .67rem; color: var(--muted); display: flex; gap: 8px; align-items: center;
}
.hero-stack-item .hs-meta .cat-badge { font-size: .58rem; }

/* ════════════════════════
   LATEST NEWS BAND
════════════════════════ */
.latest-section { margin-bottom: 32px; }
.latest-header {
  display: flex; align-items: center;
  justify-content: space-between; margin-bottom: 18px;
  padding-bottom: 10px; border-bottom: 1px solid var(--border);
}
.latest-header .sec-title { margin-bottom: 0; }
.see-all {
  font-size: .72rem; font-weight: 700; color: var(--primary);
  padding: 5px 14px; border: 1.5px solid var(--primary);
  border-radius: 20px; transition: all .18s; white-space: nowrap;
  text-transform: uppercase; letter-spacing: .5px;
}
.see-all:hover { background: var(--primary); color: #fff; }

/* 4-column grid on desktop, 2 on tablet, 1 on mobile */
.latest-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
@media(max-width: 900px) { .latest-grid { grid-template-columns: repeat(2,1fr); } }
@media(max-width: 440px)  { .latest-grid { grid-template-columns: 1fr; } }

/* First card in latest — spans 2 cols and rows */
.latest-grid .card-featured {
  grid-column: span 2; grid-row: span 2;
}
.latest-grid .card-featured .news-card { height: 100%; }
.latest-grid .card-featured .news-card .thumb { padding-top: 0; flex: 1; min-height: 200px; }
.latest-grid .card-featured .news-card h3 { font-size: 1.1rem; }
@media(max-width: 900px) {
  .latest-grid .card-featured { grid-column: span 2; grid-row: span 1; }
  .latest-grid .card-featured .news-card .thumb { padding-top: 54%; flex: none; }
}
@media(max-width: 440px) { .latest-grid .card-featured { grid-column: span 1; } }

/* ════════════════════════
   CATEGORY SECTION
════════════════════════ */
.cat-section { margin-bottom: 32px; }
.cat-section-header {
  display: flex; align-items: center;
  justify-content: space-between;
  margin-bottom: 16px; padding-bottom: 10px;
  border-bottom: 2px solid var(--border);
}
.cat-section-header .sec-title { margin-bottom: 0; }
.cat-view-all {
  font-size: .7rem; font-weight: 700; color: var(--muted);
  padding: 4px 12px; border: 1.5px solid var(--border);
  border-radius: 20px; transition: all .18s; white-space: nowrap;
}
.cat-view-all:hover { border-color: var(--primary); color: var(--primary); }

/* Cat layout: big left + list right */
.cat-layout { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; }
@media(max-width: 640px) { .cat-layout { grid-template-columns: 1fr; } }

.cat-main .news-card .thumb { padding-top: 65%; }
.cat-main .news-card h3 { font-size: 1.02rem; }

.cat-list { display: flex; flex-direction: column; gap: 2px; }

/* List-style article row */
.list-item {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 11px 14px; background: var(--white);
  border-radius: var(--r-md); border: 1px solid var(--border-light);
  transition: all .18s; box-shadow: var(--shadow-xs);
}
.list-item:hover { background: var(--paper); transform: translateX(3px); box-shadow: var(--shadow-sm); }
.list-item .li-num {
  font-family: var(--font-head); font-size: 1.35rem;
  color: var(--border); line-height: 1; flex-shrink: 0;
  width: 24px; padding-top: 2px; transition: color .18s;
}
.list-item:hover .li-num { color: var(--primary); }
.list-item .li-body { flex: 1; }
.list-item .li-body h4 {
  font-family: var(--font-hindi); font-size: .86rem;
  line-height: 1.42; color: var(--dark); margin-bottom: 4px;
}
.list-item .li-body h4 a:hover { color: var(--primary); }
.list-item .li-meta { font-size: .65rem; color: var(--muted); display: flex; gap: 8px; align-items: center; }
.list-item .li-thumb {
  flex: 0 0 68px; height: 52px; overflow: hidden;
  border-radius: var(--r-sm);
}
.list-item .li-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.list-item:hover .li-thumb img { transform: scale(1.08); }

/* ════════════════════════
   OPINION / EDITOR'S PICK
════════════════════════ */
.picks-section { margin-bottom: 32px; }
.picks-grid {
  display: grid; grid-template-columns: repeat(4,1fr); gap: 16px;
}
@media(max-width: 900px) { .picks-grid { grid-template-columns: repeat(2,1fr); } }
@media(max-width: 440px)  { .picks-grid { grid-template-columns: 1fr 1fr; gap: 10px; } }

.pick-card {
  background: var(--white); border-radius: var(--r-lg);
  overflow: hidden; box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  transition: transform .22s, box-shadow .22s;
}
.pick-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.pick-card .pc-img {
  position: relative; padding-top: 62%; overflow: hidden;
}
.pick-card .pc-img img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; transition: transform .35s;
}
.pick-card:hover .pc-img img { transform: scale(1.07); }
.pick-card .pc-body { padding: 12px 14px 14px; }
.pick-card .pc-cat { font-size: .6rem; font-weight: 700; color: var(--primary); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 5px; }
.pick-card h4 { font-family: var(--font-hindi); font-size: .86rem; line-height: 1.44; color: var(--dark); }
.pick-card h4 a:hover { color: var(--primary); }
.pick-card .pc-meta { font-size: .63rem; color: var(--muted); margin-top: 7px; display: flex; gap: 8px; }

/* ════════════════════════
   VIDEOS SECTION
════════════════════════ */
.video-section { margin-bottom: 32px; }
.video-grid {
  display: grid; grid-template-columns: repeat(4,1fr); gap: 16px;
}
@media(max-width: 900px) { .video-grid { grid-template-columns: repeat(2,1fr); } }
@media(max-width: 440px)  { .video-grid { grid-template-columns: 1fr; } }

.video-card {
  background: var(--white); border-radius: var(--r-lg);
  overflow: hidden; box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  transition: transform .22s, box-shadow .22s;
}
.video-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.video-card .vc-thumb { position: relative; padding-top: 56.25%; overflow: hidden; }
.video-card .vc-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.video-card:hover .vc-thumb img { transform: scale(1.05); }
.video-card .play-ring {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.25);
}
.play-ring .ring {
  width: 48px; height: 48px; border-radius: 50%;
  background: rgba(255,255,255,.2); backdrop-filter: blur(4px);
  border: 2px solid rgba(255,255,255,.6);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; color: #fff; transition: all .2s;
  padding-left: 3px;
}
.video-card:hover .ring { background: var(--primary); border-color: var(--primary); transform: scale(1.1); }
.video-card .vc-body { padding: 11px 14px 14px; }
.video-card h4 { font-family: var(--font-hindi); font-size: .85rem; color: var(--dark); line-height: 1.4; }

/* ════════════════════════
   SIDEBAR SPECIFIC
════════════════════════ */
.sw-must-read .mr-item { padding: 10px 14px; }
.sw-must-read .mr-num { font-size: 1.4rem; }

/* Ad placeholder */
.ad-placeholder {
  border: 2px dashed var(--border); border-radius: var(--r-lg);
  background: var(--paper); padding: 24px 16px;
  text-align: center; color: var(--muted); font-size: .75rem;
}
.ad-placeholder i { font-size: 1.8rem; color: var(--border); display: block; margin-bottom: 8px; }

/* Weather widget */
.weather-widget { padding: 16px; }
.weather-main { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.weather-icon { font-size: 2.8rem; color: var(--accent); line-height: 1; }
.weather-temp { font-family: var(--font-head); font-size: 2.4rem; color: var(--dark); line-height: 1; }
.weather-loc { font-size: .75rem; color: var(--muted); }
.weather-desc { font-size: .8rem; color: var(--ink-light); font-family: var(--font-hindi); }
.weather-row { display: flex; gap: 0; }
.weather-cell { flex: 1; text-align: center; padding: 8px 4px; font-size: .68rem; color: var(--muted); border-right: 1px solid var(--border-light); }
.weather-cell:last-child { border-right: none; }
.weather-cell .wc-val { font-weight: 700; color: var(--ink); font-size: .8rem; display: block; }
