:root {
  --bg: #0b1020;
  --card: #111933;
  --card-2: #162042;
  --text: #eaf0ff;
  --muted: #9fb1d9;
  --accent: #18e2b2;
  --live: #ff3b3b;
  --ft: #6e7ea8;
  --ht: #ffb648;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Inter, Pretendard, -apple-system, BlinkMacSystemFont, sans-serif;
  background: linear-gradient(180deg, #090d1a, #0f1730);
  color: var(--text);
}
.top-utility {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 20px; border-bottom: 1px solid #22305c;
}
.logo { font-weight: 800; letter-spacing: 0.5px; }
.utility-actions { display: flex; gap: 10px; }
.utility-actions input { background: #0c1328; border: 1px solid #2a3b6f; color: var(--text); padding: 8px 10px; border-radius: 8px; }
.utility-actions button { background: #263b7b; color: #fff; border: 0; padding: 8px 12px; border-radius: 8px; }

.primary-nav, .sports-tabs {
  display: flex; gap: 16px; padding: 12px 20px; overflow-x: auto;
}
.primary-nav { border-bottom: 1px solid #1d2a50; }
.primary-nav a { color: var(--muted); text-decoration: none; font-weight: 600; }
.primary-nav a:hover { color: #fff; }
.sports-tabs { position: sticky; top: 0; background: #0f1730; border-bottom: 1px solid #283a6d; z-index: 2; }
.sports-tabs .tab-link { background: transparent; border: 1px solid #304983; color: var(--muted); border-radius: 20px; padding: 6px 12px; text-decoration: none; display: inline-block; font-size: 14px; }
.sports-tabs .active { color: #fff; border-color: var(--accent); }

main { padding: 20px; max-width: 1200px; margin: 0 auto; }
.live-strip h2 { margin: 0 0 12px; }
.live-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.live-card { background: var(--card); border: 1px solid #253869; border-radius: 12px; padding: 12px; }
.live-card .teams { font-weight: 700; }
.live-card .score { font-size: 1.4rem; margin: 6px 0; }
.status { font-size: 0.8rem; color: #fff; padding: 2px 8px; border-radius: 999px; }
.status.live { background: var(--live); }
.status.ft { background: var(--ft); }
.status.ht { background: var(--ht); color: #2a1800; }

.main-grid { margin-top: 20px; display: grid; grid-template-columns: 2fr 1fr; gap: 14px; }
.content-left, .content-right > section, .league-blocks article { background: var(--card); border: 1px solid #263d74; border-radius: 14px; }
.content-left { padding: 16px; }
.lead-story h1 { margin: 6px 0 8px; font-size: 1.8rem; }
.tag { font-size: .75rem; color: var(--accent); font-weight: 700; }
.headlines ul, .content-right ul { margin: 0; padding-left: 18px; color: var(--muted); line-height: 1.7; }
.content-right { display: flex; flex-direction: column; gap: 12px; }
.content-right > section { padding: 14px; }
.badge { padding: 2px 6px; border-radius: 8px; font-size: 0.75rem; font-weight: 700; }
.badge.live { background: rgba(255,59,59,.2); color: #ff7878; }
.badge.ft { background: rgba(110,126,168,.2); color: #bdcaeb; }
.badge.ht { background: rgba(255,182,72,.2); color: #ffd08b; }

.league-blocks { margin-top: 16px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.league-blocks article { padding: 14px; }
footer { text-align: center; color: var(--muted); padding: 24px 0 32px; }

/* Article layout (ESPN-like) */
.article-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.article-layout-3col {
  grid-template-columns: 260px minmax(0, 1fr) 300px;
}
.article-sidebar {
  position: sticky;
  top: 64px;
  background: var(--card);
  border: 1px solid #263d74;
  border-radius: 12px;
  padding: 12px;
  max-height: calc(100vh - 90px);
  overflow: auto;
}
.article-sidebar ul { list-style: none; padding: 0; margin: 0; }
.article-sidebar li { border-bottom: 1px solid #22345f; }
.article-sidebar a {
  display: block;
  text-decoration: none;
  color: #c7d8ff;
  padding: 10px 4px;
  line-height: 1.4;
}
.article-sidebar a:hover { color: #fff; }
.article-main {
  background: var(--card);
  border: 1px solid #263d74;
  border-radius: 12px;
  padding: 26px;
  line-height: 1.95;
  color: #d6e3ff;
}
.article-main h1 { margin: 8px 0; font-size: 2.35rem; line-height: 1.15; }
.article-main p { font-size: 18px; letter-spacing: -0.01em; }
.article-meta { color: #9eb1db; margin-bottom: 16px; }
.next-feed { margin-top: 28px; border-top: 1px solid #25396a; padding-top: 14px; }
.next-card {
  border: 1px solid #274177;
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 10px;
  background: var(--card-2);
}
.feed-sentinel { text-align: center; color: #9cb2df; padding: 12px 0; }
.article-right-rail {
  position: sticky;
  top: 64px;
  display: grid;
  gap: 10px;
  align-self: start;
}
.article-right-rail ul { margin: 8px 0 0; padding-left: 18px; line-height: 1.6; color: #334155; }

.embed-tool {
  border: 1px solid #274177;
  border-radius: 12px;
  padding: 12px;
  margin: 12px 0 18px;
  background: #111a35;
}
.embed-tool textarea {
  width: 100%;
  background: #0b132a;
  color: #dbe8ff;
  border: 1px solid #2b4277;
  border-radius: 8px;
  padding: 10px;
  margin-bottom: 8px;
}
.embed-tool button {
  background: #1e4bd8;
  color: #fff;
  border: 0;
  border-radius: 8px;
  padding: 8px 12px;
  cursor: pointer;
}
.embed-output { margin-top: 10px; display: grid; gap: 10px; }
.embed-card {
  border: 1px solid #2c457d;
  border-radius: 10px;
  overflow: hidden;
  background: #0f1730;
  padding: 8px;
}
.embed-card iframe,
.embed-card video,
.embed-card img {
  width: 100%;
  min-height: 260px;
  border: 0;
  border-radius: 8px;
  object-fit: cover;
}

/* ESPN-like homepage */
.espn-body {
  --espn-bg: #f2f3f5;
  --espn-card: #ffffff;
  --espn-border: #d8dde3;
  --espn-text: #111827;
  --espn-muted: #4b5563;
  --espn-accent: #1967ff;
  --espn-danger: #c90000;
  --espn-gap: 14px;
  background: var(--espn-bg);
  color: var(--espn-text);
  font-family: Inter, Pretendard, -apple-system, BlinkMacSystemFont, sans-serif;
}
.score-ticker { position: sticky; top: 0; z-index: 5; background: var(--espn-card); border-bottom: 1px solid var(--espn-border); overflow-x: auto; }
.ticker-track { display: flex; gap: 8px; padding: 8px 12px; min-width: max-content; }
.ticker-item { background: #f8f8f8; border: 1px solid var(--espn-border); border-radius: 8px; padding: 6px 10px; font-size: 12px; white-space: nowrap; color: var(--espn-muted); }
.espn-nav { display: flex; align-items: center; gap: 14px; background: #111; color: #fff; padding: 10px 14px; }
.espn-nav .logo { background: var(--espn-danger); padding: 4px 8px; border-radius: 4px; font-weight: 800; }
.espn-nav a { color: #fff; text-decoration: none; font-size: 14px; font-weight: 600; }
.espn-layout { max-width: 1280px; margin: 12px auto; padding: 0 12px; display: grid; grid-template-columns: 240px 1fr 280px; gap: var(--espn-gap); }
.card { background: var(--espn-card); border: 1px solid var(--espn-border); border-radius: 10px; padding: 12px; box-shadow: 0 1px 0 rgba(17,24,39,.03); }
.card h3 { margin: 0 0 8px; font-size: 16px; letter-spacing: -0.01em; color: var(--espn-text); }
.left-rail ul, .right-rail ul { margin: 8px 0 0; padding-left: 18px; line-height: 1.65; color: #334155; font-size: 14px; }
.cta { width: 100%; padding: 10px; background: var(--espn-accent); color: #fff; border: none; border-radius: 20px; margin-bottom: 8px; font-weight: 700; }
.hero-score .hero-meta { text-align: center; color: var(--espn-muted); font-size: 12px; font-weight: 700; }
.live-dot { display:inline-block; width:8px; height:8px; background:#e60012; border-radius:50%; margin-right:6px; }
.hero-score .match { font-size: 34px; text-align: center; margin: 8px 0 4px; letter-spacing:-0.02em; }
.hero-score .hero-sub { text-align:center; font-size:12px; color:var(--espn-muted); margin-bottom:8px; }
.hero-score .actions { display: flex; justify-content: center; gap: 8px; }
.hero-score button, .scoreboard button { border: 1px solid #2b66d8; background: #fff; color: #2b66d8; border-radius: 20px; padding: 6px 12px; font-weight: 600; }
.scoreboard .rows { display: grid; gap: 8px; }
.scoreboard .row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; align-items: center; border-top: 1px solid #edf0f4; padding-top: 8px; font-size: 14px; }
.feature-story img { width: 100%; border-radius: 8px; height: 300px; object-fit: cover; }
.feature-story h2 { margin: 10px 0 0; color: var(--espn-text); font-size: 34px; line-height: 1.08; letter-spacing:-0.02em; }
.feature-dek { color:var(--espn-muted); margin-top:8px; font-size:15px; line-height:1.45; }
.video-card img { width: 100%; border-radius: 8px; }
.video-caption { font-size: 13px; color:var(--espn-muted); margin-top:8px; line-height:1.4; }
.right-mini ul { margin-top: 6px; }
.ad-slot {
  background: repeating-linear-gradient(45deg,#f7f7f7,#f7f7f7 10px,#efefef 10px,#efefef 20px);
  border: 1px dashed #bcbcbc;
  border-radius: 10px;
  color: #666;
  font-size: 12px;
  text-align: center;
  padding: 18px 10px;
}
.ad-top { max-width: 1280px; margin: 10px auto 0; }
.ad-inline { margin: 8px 0; }

/* ESPN-like article detail */
.article-espn { background:#e9eaec; }
.article-shell {
  max-width: 1280px;
  margin: 0 auto;
  padding: 14px 10px 20px;
  display: grid;
  grid-template-columns: 280px minmax(0, 760px);
  gap: 16px;
  justify-content: center;
}
.story-list-panel {
  background:#f3f4f6;
  border:1px solid var(--espn-border);
  border-radius: 8px;
}
.story-list-panel ul { list-style:none; margin:0; padding:0; }
.story-list-panel li { border-bottom:1px solid #e1e4e8; }
.story-list-panel a {
  display:block; padding:10px 12px;
  text-decoration:none; color:var(--espn-text);
  font-size:14px; line-height:1.4; letter-spacing:-0.01em;
}
.story-list-panel a:hover { background:#eceff3; }
.article-paper {
  background:#fff;
  border:1px solid var(--espn-border);
  border-radius: 8px;
  padding:32px 36px;
  color:#24292f;
  line-height:1.9;
}
.article-head h1 { font-size:56px; line-height:1.02; margin:0 0 14px; letter-spacing:-0.025em; }
.byline-row { display:flex; gap:10px; align-items:center; margin-bottom:10px; }
.author-avatar { width:36px; height:36px; border-radius:50%; object-fit:cover; }
.author-name { font-weight:700; }
.article-actions { border-top:1px solid #eceef1; border-bottom:1px solid #eceef1; padding:10px 0; margin:10px 0 16px; color:var(--espn-muted); font-size:14px; }
.article-paper p { font-family: Georgia, 'Times New Roman', serif; font-size:21px; line-height:1.78; margin:0 0 17px; }
.article-hero-image { width:100%; border-radius:4px; margin-top:16px; }

@media (max-width: 900px) {
  .main-grid { grid-template-columns: 1fr; }
  .league-blocks { grid-template-columns: 1fr; }
  .article-layout,
  .article-layout-3col,
  .article-shell { grid-template-columns: 1fr; }
  .article-sidebar, .story-list-panel { position: static; max-height: none; }
  .article-right-rail { position: static; }
  .article-main, .article-paper { padding: 18px; }
  .article-main h1, .article-head h1 { font-size: 34px; }
  .article-main p { font-size: 16px; }
  .article-paper p { font-size: 19px; }
  .feature-story h2 { font-size: 26px; }
  .feature-story img { height: 220px; }
  .espn-layout { grid-template-columns: 1fr; gap: 10px; }
  .card { padding: 10px; }
}
