/* ============================================================
   DailyTips Child Theme — assets/css/main.css
   ============================================================ */

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

:root {
  --ink: #0f0f0f;
  --ink2: #2a2a2a;
  --ink3: #555;
  --ink4: #888;
  --paper: #faf8f4;
  --paper2: #f2efe8;
  --paper3: #e8e4da;
  --accent: #d4341a;
  --accent2: #e84e20;
  --gold: #c9922a;
  --teal: #1a7a6e;
  --blue: #1a4fa0;
  --border: rgba(15,15,15,0.10);
  --border2: rgba(15,15,15,0.06);
  --ff-head: 'Playfair Display', Georgia, serif;
  --ff-display: 'DM Serif Display', Georgia, serif;
  --ff-body: 'DM Sans', sans-serif;
  --radius: 3px;
}

html { scroll-behavior: smooth; }
body {
  font-family: var(--ff-body);
  background: var(--paper);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; height: auto; display: block; }

/* ── TICKER ───────────────────────────────────────────────────── */
.ticker-bar {
  background: var(--accent);
  color: white;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  overflow: hidden;
  height: 32px;
}
.ticker-label {
  background: var(--ink);
  color: white;
  padding: 0 14px;
  height: 100%;
  display: flex;
  align-items: center;
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
}
.ticker-track { flex:1; overflow:hidden; position:relative; height:100%; display:flex; align-items:center; }
.ticker-inner { display:flex; gap:0; white-space:nowrap; animation: ticker 40s linear infinite; }
.ticker-inner span { padding: 0 28px; }
.ticker-inner span::before { content:'◆'; margin-right:28px; font-size:8px; opacity:0.5; }
.ticker-inner a { color: white; }
@keyframes ticker { from{transform:translateX(0)} to{transform:translateX(-50%)} }

/* ── MASTHEAD ─────────────────────────────────────────────────── */
.masthead {
  border-bottom: 1px solid var(--border);
  background: var(--paper);
  position: sticky;
  top: 0;
  z-index: 100;
}
.masthead-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.logo { display:flex; flex-direction:column; line-height:1; cursor:pointer; }
.logo-main { font-family:var(--ff-head); font-size:26px; font-weight:900; color:var(--ink); letter-spacing:-0.02em; }
.logo-main span { color:var(--accent); }
.logo-sub { font-size:9px; letter-spacing:0.18em; text-transform:uppercase; color:var(--ink4); font-weight:500; margin-top:1px; }
.masthead-right { display:flex; align-items:center; gap:16px; }
.date-pill { font-size:11px; color:var(--ink4); }
.btn-subscribe {
  background:var(--accent); color:white; border:none;
  padding:7px 16px; font-family:var(--ff-body); font-size:12px;
  font-weight:600; letter-spacing:0.04em; cursor:pointer;
  border-radius:var(--radius); transition:background 0.2s;
}
.btn-subscribe:hover { background:var(--accent2); }
.masthead-menu { display:flex; list-style:none; gap:4px; }
.masthead-menu li a { font-size:12px; font-weight:500; padding:4px 8px; color:var(--ink3); transition:color 0.15s; }
.masthead-menu li a:hover { color:var(--ink); }

/* ── NAV TABS ─────────────────────────────────────────────────── */
.nav-tabs { background:var(--paper); border-bottom:2px solid var(--border); }
.nav-tabs-inner {
  max-width:1200px; margin:0 auto; padding:0 24px;
  display:flex; gap:0; overflow-x:auto; scrollbar-width:none;
}
.nav-tabs-inner::-webkit-scrollbar { display:none; }
.tab {
  padding:12px 18px 11px; font-size:12.5px; font-weight:600;
  letter-spacing:0.04em; text-transform:uppercase; color:var(--ink3);
  cursor:pointer; border-bottom:2px solid transparent; margin-bottom:-2px;
  white-space:nowrap; transition:color 0.15s,border-color 0.15s; user-select:none;
}
.tab:hover { color:var(--ink); }
.tab.active { color:var(--accent); border-bottom-color:var(--accent); }

/* ── MAIN LAYOUT ──────────────────────────────────────────────── */
.dt-main-wrap {
  max-width:1200px; margin:0 auto; padding:32px 24px 0;
  display:grid; grid-template-columns:1fr 300px; gap:40px;
}
.dt-main { min-width:0; }

/* ── REGION FILTER ────────────────────────────────────────────── */
.region-row { display:flex; gap:8px; flex-wrap:wrap; margin-bottom:28px; padding-bottom:20px; border-bottom:1px solid var(--border); }
.region-chip {
  font-size:11px; font-weight:600; padding:5px 12px; border-radius:99px;
  background:var(--paper2); border:1px solid var(--border); color:var(--ink3);
  cursor:pointer; transition:all 0.15s; letter-spacing:0.03em;
}
.region-chip:hover, .region-chip.active { background:var(--ink); color:white; border-color:var(--ink); }

/* ── SECTION SHOW/HIDE ────────────────────────────────────────── */
.section-content { display:none; }
.section-content.active { display:block; }

/* ── HERO ─────────────────────────────────────────────────────── */
.hero {
  display:grid; grid-template-columns:1fr 1fr;
  grid-template-rows:auto auto; gap:1px;
  background:var(--border); border:1px solid var(--border);
  margin-bottom:36px;
}
.hero-main { grid-row:1/3; position:relative; overflow:hidden; background:var(--ink); cursor:pointer; }
.hero-main-img-wrap { width:100%; height:340px; overflow:hidden; }
.hero-main-img-wrap img { width:100%; height:100%; object-fit:cover; filter:brightness(0.55); transition:filter 0.4s; }
.hero-main:hover .hero-main-img-wrap img { filter:brightness(0.45); }
.hero-overlay {
  position:absolute; bottom:0; left:0; right:0; padding:20px 22px;
  background:linear-gradient(to top,rgba(0,0,0,0.92),rgba(0,0,0,0));
}
.hero-overlay .cat-tag { margin-bottom:8px; }
.hero-headline { font-family:var(--ff-head); font-size:22px; font-weight:700; color:white; line-height:1.25; margin-bottom:8px; }
.hero-meta { font-size:11px; color:rgba(255,255,255,0.6); }
.hero-sub { background:var(--paper); padding:16px 18px; cursor:pointer; transition:background 0.15s; display:flex; flex-direction:column; justify-content:space-between; }
.hero-sub:hover { background:var(--paper2); }
.hero-sub-headline { font-family:var(--ff-display); font-size:16px; line-height:1.3; color:var(--ink); margin:8px 0 10px; font-style:italic; }
.hero-sub-desc { font-size:13px; color:var(--ink3); line-height:1.5; }

/* ── CAT TAGS ─────────────────────────────────────────────────── */
.cat-tag {
  display:inline-block; font-size:10px; font-weight:700;
  letter-spacing:0.1em; text-transform:uppercase;
  padding:3px 7px; border-radius:2px;
}
.cat-tag.business { background:#fff4e0; color:#a06010; }
.cat-tag.sports   { background:#e8f5e9; color:#2e7d32; }
.cat-tag.entertainment { background:#fce4ec; color:#880e4f; }
.cat-tag.tech     { background:#e3f2fd; color:#0d47a1; }
.cat-tag.culture  { background:#f3e5f5; color:#6a1b9a; }
.cat-tag.science  { background:#e8eaf6; color:#283593; }
.cat-tag.travel   { background:#e8f4f8; color:#006494; }
.cat-tag.gaming   { background:#ede7f6; color:#4527a0; }
.cat-tag.startups { background:#fff8e1; color:#e65100; }
.cat-tag.food     { background:#fbe9e7; color:#bf360c; }

.cat-tag-white {
  display:inline-block; font-size:10px; font-weight:700;
  letter-spacing:0.1em; text-transform:uppercase;
  padding:3px 8px; border-radius:2px; color:white;
}
.cat-tag-white.business { background:var(--gold); }
.cat-tag-white.sports   { background:var(--teal); }
.cat-tag-white.entertainment { background:#b5246e; }
.cat-tag-white.tech     { background:var(--blue); }
.cat-tag-white.culture  { background:#7b1fa2; }
.cat-tag-white.science  { background:#283593; }
.cat-tag-white.travel   { background:#006494; }
.cat-tag-white.gaming   { background:#4527a0; }
.cat-tag-white.startups { background:#e65100; }
.cat-tag-white.food     { background:#bf360c; }

/* ── SECTION HEADER ───────────────────────────────────────────── */
.section-header {
  display:flex; align-items:baseline; gap:14px;
  margin-bottom:18px; padding-bottom:10px; border-bottom:2px solid var(--ink);
}
.section-title { font-family:var(--ff-head); font-size:19px; font-weight:700; color:var(--ink); }
.section-more { font-size:11px; font-weight:600; letter-spacing:0.06em; text-transform:uppercase; color:var(--accent); cursor:pointer; margin-left:auto; }
.section-block { margin-bottom:40px; }

/* ── STORY GRIDS ──────────────────────────────────────────────── */
.story-grid-4 { display:grid; grid-template-columns:repeat(4,1fr); gap:20px; }
.story-grid-3 { display:grid; grid-template-columns:repeat(3,1fr); gap:20px; }
.two-col-sections { display:grid; grid-template-columns:1fr 1fr; gap:40px; }

.story-card { cursor:pointer; }
.story-card:hover .story-headline { color:var(--accent); }
.story-thumb { width:100%; aspect-ratio:16/9; overflow:hidden; margin-bottom:10px; background:var(--paper3); position:relative; }
.story-thumb img { width:100%; height:100%; object-fit:cover; transition:transform 0.4s; }
.story-card:hover .story-thumb img { transform:scale(1.04); }
.story-thumb-placeholder { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:32px; opacity:0.25; }
.story-headline { font-family:var(--ff-display); font-size:15px; font-weight:400; line-height:1.35; color:var(--ink); margin:6px 0 5px; transition:color 0.15s; font-style:italic; }
.story-deck { font-size:12.5px; color:var(--ink3); line-height:1.5; }
.story-meta { font-size:11px; color:var(--ink4); margin-top:7px; }

/* ── STORY LIST ROWS ──────────────────────────────────────────── */
.story-list { display:flex; flex-direction:column; gap:0; }
.story-row { display:flex; gap:14px; padding:14px 0; border-bottom:1px solid var(--border2); cursor:pointer; }
.story-row:first-child { padding-top:0; }
.story-row:last-child { border-bottom:none; }
.story-row:hover .story-row-headline { color:var(--accent); }
.story-row-thumb { width:90px; height:64px; flex-shrink:0; background:var(--paper3); overflow:hidden; }
.story-row-thumb img { width:100%; height:100%; object-fit:cover; transition:transform 0.3s; }
.story-row:hover .story-row-thumb img { transform:scale(1.06); }
.story-row-body { flex:1; }
.story-row-headline { font-family:var(--ff-display); font-size:14px; font-style:italic; line-height:1.35; color:var(--ink); transition:color 0.15s; margin:4px 0 5px; }
.story-row-meta { font-size:11px; color:var(--ink4); }

/* ── DIVIDER ──────────────────────────────────────────────────── */
.divider { height:1px; background:var(--border); margin:4px 0 32px; }

/* ── LOAD MORE ────────────────────────────────────────────────── */
.load-more-wrap { text-align:center; margin-top:28px; }
.btn-load-more {
  background:transparent; border:1.5px solid var(--ink); color:var(--ink);
  padding:10px 32px; font-family:var(--ff-body); font-size:12px; font-weight:600;
  letter-spacing:0.06em; text-transform:uppercase; cursor:pointer;
  transition:all 0.2s; border-radius:var(--radius);
}
.btn-load-more:hover { background:var(--ink); color:white; }
.no-posts { color:var(--ink4); font-size:14px; padding:40px 0; text-align:center; }

/* ── SIDEBAR ──────────────────────────────────────────────────── */
.dt-sidebar { padding-top:0; }
.trending-box { background:var(--paper2); border:1px solid var(--border); padding:20px; margin-bottom:28px; }
.trending-header { display:flex; align-items:center; gap:8px; margin-bottom:16px; padding-bottom:12px; border-bottom:2px solid var(--ink); }
.trending-label { font-size:13px; font-weight:700; letter-spacing:0.05em; text-transform:uppercase; color:var(--ink); }
.trending-dot { width:7px; height:7px; border-radius:50%; background:var(--accent); animation:pulse 1.8s ease-in-out infinite; }
@keyframes pulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:0.5;transform:scale(0.8)} }
.trending-item { display:flex; gap:12px; align-items:flex-start; padding:10px 0; border-bottom:1px solid var(--border2); cursor:pointer; }
.trending-item:last-child { border-bottom:none; padding-bottom:0; }
.trending-item:hover .trending-headline { color:var(--accent); }
.trending-num { font-family:var(--ff-head); font-size:22px; font-weight:900; color:var(--paper3); line-height:1; flex-shrink:0; width:26px; margin-top:1px; }
.trending-content { flex:1; }
.trending-headline { font-size:13px; font-weight:500; line-height:1.4; color:var(--ink); transition:color 0.15s; margin-bottom:3px; }
.trending-meta { font-size:11px; color:var(--ink4); }

/* ── MUST READ ────────────────────────────────────────────────── */
.must-read-box { border:1px solid var(--border); margin-bottom:28px; overflow:hidden; }
.must-read-header { background:var(--ink); color:white; padding:10px 16px; font-size:10px; font-weight:700; letter-spacing:0.14em; text-transform:uppercase; }
.must-read-item { padding:12px 16px; border-bottom:1px solid var(--border2); cursor:pointer; transition:background 0.15s; }
.must-read-item:last-child { border-bottom:none; }
.must-read-item:hover { background:var(--paper2); }
.must-read-item:hover .must-read-title { color:var(--accent); }
.must-read-title { font-size:13px; font-weight:500; line-height:1.4; color:var(--ink); transition:color 0.15s; }
.must-read-cat { font-size:10px; color:var(--ink4); margin-top:4px; font-weight:500; letter-spacing:0.04em; text-transform:uppercase; }

/* ── AD SLOT ──────────────────────────────────────────────────── */
.ad-slot-wrap { margin-bottom:28px; }
.ad-slot { background:var(--paper2); border:1px dashed var(--paper3); height:250px; display:flex; align-items:center; justify-content:center; flex-direction:column; gap:6px; }
.ad-slot-label { font-size:10px; color:var(--ink4); letter-spacing:0.1em; text-transform:uppercase; }

/* ── NEWSLETTER ───────────────────────────────────────────────── */
.newsletter-box { background:var(--ink); padding:20px; margin-bottom:28px; }
.newsletter-title { font-family:var(--ff-head); font-size:17px; font-weight:700; color:white; margin-bottom:6px; }
.newsletter-desc { font-size:12px; color:rgba(255,255,255,0.5); margin-bottom:14px; line-height:1.5; }
.newsletter-form { display:flex; flex-direction:column; gap:8px; }
.newsletter-form input {
  width:100%; padding:9px 12px; font-family:var(--ff-body); font-size:13px;
  border:none; border-radius:2px; background:rgba(255,255,255,0.1); color:white; outline:none;
}
.newsletter-form input::placeholder { color:rgba(255,255,255,0.35); }
.newsletter-form button {
  width:100%; padding:9px; background:var(--accent); color:white; border:none;
  font-family:var(--ff-body); font-size:12px; font-weight:700; letter-spacing:0.05em;
  cursor:pointer; border-radius:2px; text-transform:uppercase; transition:background 0.2s;
}
.newsletter-form button:hover { background:var(--accent2); }

/* ── OPINION STRIP ────────────────────────────────────────────── */
.opinion-strip { background:var(--ink); padding:28px 0; margin:40px 0; }
.opinion-inner { max-width:1200px; margin:0 auto; padding:0 24px; }
.opinion-strip .section-title { color:white; }
.opinion-strip .section-header { border-bottom-color:var(--accent); }
.opinion-strip .section-more { color:rgba(255,255,255,0.5); }
.opinion-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:24px; }
.opinion-card { cursor:pointer; }
.opinion-card:hover .opinion-title { color:var(--gold); }
.opinion-author-row { display:flex; align-items:center; gap:10px; margin-bottom:10px; }
.opinion-avatar { width:36px; height:36px; border-radius:50%; background:var(--ink2); border:1px solid rgba(255,255,255,0.1); display:flex; align-items:center; justify-content:center; font-size:14px; color:rgba(255,255,255,0.5); font-weight:700; font-family:var(--ff-head); flex-shrink:0; overflow:hidden; }
.opinion-avatar img { width:100%; height:100%; object-fit:cover; }
.opinion-author { font-size:12px; color:rgba(255,255,255,0.5); }
.opinion-author strong { display:block; color:rgba(255,255,255,0.85); font-size:13px; margin-bottom:1px; }
.opinion-title { font-family:var(--ff-head); font-size:17px; font-weight:700; line-height:1.3; color:white; transition:color 0.15s; margin-bottom:8px; }
.opinion-excerpt { font-size:12.5px; color:rgba(255,255,255,0.45); line-height:1.55; }

/* ── FOOTER ───────────────────────────────────────────────────── */
.dt-footer { background:var(--ink2); color:rgba(255,255,255,0.55); padding:36px 24px 20px; }
.footer-inner { max-width:1200px; margin:0 auto; }
.footer-top { display:flex; justify-content:space-between; align-items:flex-start; padding-bottom:24px; border-bottom:1px solid rgba(255,255,255,0.08); gap:32px; flex-wrap:wrap; }
.footer-brand p { font-size:12px; margin-top:8px; max-width:240px; line-height:1.55; }
.footer-links { display:flex; gap:40px; flex-wrap:wrap; }
.footer-col h4 { font-size:11px; letter-spacing:0.1em; text-transform:uppercase; color:rgba(255,255,255,0.8); font-weight:700; margin-bottom:12px; }
.footer-col a { display:block; font-size:13px; color:rgba(255,255,255,0.45); margin-bottom:7px; cursor:pointer; transition:color 0.15s; }
.footer-col a:hover { color:white; }
.footer-bottom { padding-top:16px; display:flex; justify-content:space-between; font-size:11px; flex-wrap:wrap; gap:8px; }

/* ── SINGLE ARTICLE ───────────────────────────────────────────── */
.single-wrap { max-width:1200px; margin:0 auto; padding:32px 24px; display:grid; grid-template-columns:1fr 300px; gap:40px; }
.single-main { min-width:0; }
.single-article { max-width:720px; }
.single-meta-top { margin-bottom:12px; }
.single-headline { font-family:var(--ff-head); font-size:34px; font-weight:900; line-height:1.2; color:var(--ink); margin-bottom:14px; letter-spacing:-0.01em; }
.single-deck { font-size:18px; color:var(--ink3); line-height:1.6; margin-bottom:20px; font-family:var(--ff-display); font-style:italic; }
.single-byline { display:flex; justify-content:space-between; align-items:center; padding:14px 0; border-top:1px solid var(--border); border-bottom:1px solid var(--border); margin-bottom:24px; }
.byline-author { display:flex; align-items:center; gap:10px; font-size:13px; }
.byline-author img { border-radius:50%; width:36px; height:36px; }
.byline-author strong { display:block; font-size:14px; color:var(--ink); }
.byline-author span { color:var(--ink4); font-size:12px; }
.share-btn { background:transparent; border:1px solid var(--border); padding:6px 14px; font-family:var(--ff-body); font-size:12px; font-weight:600; cursor:pointer; border-radius:var(--radius); color:var(--ink3); transition:all 0.15s; }
.share-btn:hover { background:var(--ink); color:white; border-color:var(--ink); }
.single-hero-img { margin-bottom:28px; border-radius:var(--radius); overflow:hidden; }
.single-hero-img img { width:100%; }
.single-body { font-size:16px; line-height:1.8; color:var(--ink2); }
.single-body p { margin-bottom:20px; }
.single-body h2 { font-family:var(--ff-head); font-size:22px; font-weight:700; margin:32px 0 14px; }
.single-body h3 { font-family:var(--ff-head); font-size:18px; font-weight:700; margin:24px 0 10px; }
.single-body blockquote { border-left:3px solid var(--accent); padding:12px 20px; margin:24px 0; color:var(--ink3); font-family:var(--ff-display); font-style:italic; font-size:18px; }
.single-tags { margin-top:32px; display:flex; flex-wrap:wrap; gap:8px; }
.tag-chip { font-size:11px; padding:5px 12px; background:var(--paper2); border:1px solid var(--border); border-radius:99px; color:var(--ink3); transition:all 0.15s; }
.tag-chip:hover { background:var(--ink); color:white; }
.related-block { margin-top:40px; padding-top:32px; border-top:2px solid var(--ink); }

/* ── ANIMATIONS ───────────────────────────────────────────────── */
@keyframes fadeUp { from{opacity:0;transform:translateY(14px)} to{opacity:1;transform:translateY(0)} }
.fade-in   { animation:fadeUp 0.5s ease both; }
.fade-in-1 { animation-delay:0.05s; }
.fade-in-2 { animation-delay:0.1s; }
.fade-in-3 { animation-delay:0.15s; }
.fade-in-4 { animation-delay:0.2s; }

/* ── RESPONSIVE ───────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .dt-main-wrap, .single-wrap { grid-template-columns:1fr; }
  .dt-sidebar { display:grid; grid-template-columns:1fr 1fr; gap:20px; }
  .story-grid-4 { grid-template-columns:repeat(2,1fr); }
  .opinion-grid { grid-template-columns:1fr 1fr; }
}
@media (max-width: 768px) {
  .hero { grid-template-columns:1fr; grid-template-rows:auto; }
  .hero-main { grid-row:auto; }
  .story-grid-3 { grid-template-columns:1fr 1fr; }
  .story-grid-4 { grid-template-columns:1fr 1fr; }
  .two-col-sections { grid-template-columns:1fr; }
  .opinion-grid { grid-template-columns:1fr; }
  .dt-sidebar { grid-template-columns:1fr; }
  .masthead-inner { height:52px; }
  .logo-main { font-size:20px; }
  .single-headline { font-size:24px; }
}
@media (max-width: 480px) {
  .story-grid-3, .story-grid-4 { grid-template-columns:1fr; }
  .footer-top { flex-direction:column; }
  .footer-links { gap:24px; }
  .dt-main-wrap { padding:16px 16px 0; }
}
