/*
Theme Name: TrendyPulse Pro
Author: Branky
Description: A fast, dark, editorial music & entertainment theme in the style of notjustok.com. No jQuery, no icon fonts, no carousels, no page-builder bloat — built to pass Core Web Vitals and to play nicely with LiteSpeed Cache.
Version: 3.2.3
Requires at least: 6.3
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: trendypulse
*/

/* ==== Reset ==== */
*,*::before,*::after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0}
img,svg,video,iframe{max-width:100%;display:block}
img,video{height:auto}
a{color:inherit;text-decoration:none}
ul,ol{margin:0;padding:0;list-style:none}
button{font:inherit;background:none;border:0;padding:0;cursor:pointer;color:inherit}
input,textarea,select{font:inherit;color:inherit}
h1,h2,h3,h4{margin:0}
[hidden]{display:none!important}

/* ==== Tokens ====
   Dark is the default (matches the reference design); light is opt-in
   via the toggle. Both are CSS-only so cached HTML is identical for all. */
:root,[data-theme="dark"]{
  --bg:#231f20;
  --surface:#2c2729;
  --line:#6b6466;        /* section rules, button borders */
  --line-soft:#3d3739;   /* list dividers, header border */
  --text:#fff;
  --muted:#b3adaf;
  --accent:#ff3b41;
  color-scheme:dark;
}
[data-theme="light"]{
  --bg:#fff;
  --surface:#f4f2f2;
  --line:#231f20;
  --line-soft:#e4e0e1;
  --text:#231f20;
  --muted:#5f595b;
  --accent:#d3151c;
  color-scheme:light;
}
:root{
  --radius:6px;
  --container:1200px;
  --header-h:64px;
  /* Fallback is metric-adjusted toward Epilogue so the font swap barely moves text. */
  --font:"Epilogue","Epilogue Fallback",system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;
}
@font-face{font-family:"Epilogue Fallback";src:local("Arial");size-adjust:104%}

body{font-family:var(--font);background:var(--bg);color:var(--text);line-height:1.55;font-size:16px;-webkit-font-smoothing:antialiased}
.container{max-width:var(--container);margin:0 auto;padding:0 16px}
@media(min-width:768px){.container{padding:0 24px}}
.screen-reader-text{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.skip-link:focus{position:fixed!important;top:8px;left:8px;width:auto;height:auto;clip:auto;z-index:200;background:var(--text);color:var(--bg);padding:10px 14px;border-radius:4px}
:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
svg{width:20px;height:20px;flex:none}

/* ==== Header ==== */
.site-header{position:sticky;top:0;z-index:50;background:var(--bg);border-bottom:1px solid var(--line-soft)}
.header-bar{height:var(--header-h);display:flex;align-items:center;gap:12px}
.logo{font-weight:900;font-style:italic;font-size:1.45rem;text-transform:uppercase;letter-spacing:-.03em;line-height:1;white-space:nowrap}
.custom-logo-link{display:block;flex:none}
.custom-logo{height:28px;width:auto}
.primary-nav{display:none;margin-left:28px;min-width:0}
.primary-nav ul{display:flex;gap:20px;white-space:nowrap}
.primary-nav a{display:block;font-size:.8rem;font-weight:700;text-transform:uppercase;letter-spacing:.02em;padding:8px 0}
.primary-nav a:hover,.primary-nav .current-menu-item>a{color:var(--accent)}
@media(min-width:1024px){.primary-nav{display:block}}
.header-actions{margin-left:auto;display:flex;align-items:center;gap:2px}
.icon-btn{width:40px;height:40px;display:inline-flex;align-items:center;justify-content:center;border-radius:50%}
.icon-btn:hover{color:var(--accent)}
.socials{display:flex;align-items:center;gap:14px}
.socials a:hover{color:var(--accent)}
.header-socials{display:none;margin:0 10px 0 6px}
@media(min-width:1200px){.header-socials{display:flex}}

/* ==== Drawer (hamburger menu) — transform-only animation, no layout shift ==== */
.drawer{position:fixed;top:0;bottom:0;left:0;width:min(360px,88vw);background:var(--bg);border-right:1px solid var(--line-soft);z-index:100;padding:12px 24px 32px;overflow-y:auto;overscroll-behavior:contain;transform:translateX(-100%);visibility:hidden;transition:transform .25s ease,visibility 0s linear .25s}
.drawer.is-open{transform:none;visibility:visible;transition:transform .25s ease}
.drawer-top{display:flex;align-items:center;justify-content:space-between;height:52px;margin-bottom:12px}
.drawer nav a{display:block;padding:12px 0;font-weight:700;font-size:1.05rem;text-transform:uppercase;border-bottom:1px solid var(--line-soft)}
.drawer nav a:hover{color:var(--accent)}
.drawer .sub-menu a{font-size:.9rem;font-weight:500;text-transform:none;color:var(--muted);padding:10px 0 10px 14px}
.drawer-socials{margin-top:24px}
.scrim{position:fixed;inset:0;background:rgba(0,0,0,.6);z-index:99;opacity:0;visibility:hidden;transition:opacity .25s,visibility 0s linear .25s}
.drawer-open .scrim{opacity:1;visibility:visible;transition:opacity .25s}
.drawer-open{overflow:hidden}

/* ==== Search overlay ==== */
.search-overlay{position:fixed;inset:0;background:rgba(0,0,0,.75);z-index:90;padding-top:110px}
.search-overlay input{width:100%;padding:18px 20px;border-radius:var(--radius);border:1px solid var(--line);font-size:1.2rem;background:var(--bg)}

/* ==== Sections ==== */
.section{padding-top:40px;padding-bottom:40px}
.site-main>.section+.section{border-top:1px solid var(--line-soft)}
.sec-head{display:flex;align-items:center;justify-content:space-between;gap:16px;padding-bottom:14px;border-bottom:2px solid var(--line);margin-bottom:24px}
.sec-title{font-size:clamp(1.65rem,3.2vw,2.4rem);font-weight:800;text-transform:uppercase;letter-spacing:-.01em;line-height:1.05}
.sec-aside{font-style:italic;font-weight:600;font-size:clamp(.95rem,1.6vw,1.2rem);text-align:right}
.more-btn{display:inline-flex;align-items:center;gap:10px;padding:10px 14px;border:1px solid var(--line);border-radius:var(--radius);font-size:.8rem;font-weight:700;text-transform:uppercase;letter-spacing:.02em;white-space:nowrap}
.more-btn:hover{border-color:var(--text)}
.page-lede{color:var(--muted);font-size:1.02rem;max-width:680px;margin:-8px 0 24px}

/* ==== Cards ====
   Every image sits in a fixed-ratio box, so nothing moves as images load (CLS). */
.card{min-width:0}
.pill{display:inline-block;font-size:.66rem;font-weight:700;line-height:1;padding:4px 6px;border:1px solid var(--line);border-radius:4px;margin-bottom:8px;white-space:nowrap}
.media{display:block;position:relative;overflow:hidden;border-radius:var(--radius);background:var(--surface);aspect-ratio:16/9}
.media--list{aspect-ratio:4/3}
.media--sq{aspect-ratio:1/1}
.media img{width:100%;height:100%;object-fit:cover}
.c-title{font-size:1.05rem;font-weight:600;line-height:1.3;letter-spacing:-.005em}
.c-title a:hover{color:var(--accent)}
.c-body{padding-top:12px}

.card--lead .c-body{padding:0 0 18px}
.card--lead .c-title{font-size:clamp(1.55rem,2.6vw,2rem);line-height:1.2}
.card--feature .c-title{font-size:clamp(1.45rem,2.4vw,2rem);line-height:1.2}
.card--pick{border:1px solid var(--line-soft);border-radius:8px;overflow:hidden;background:var(--surface)}
.card--pick .media{border-radius:0}
.card--pick .c-body{padding:14px 16px 20px}
.card--pick .c-title{font-size:1.35rem;line-height:1.25}

.card--list{display:grid;grid-template-columns:120px minmax(0,1fr);gap:14px;align-items:start;padding:16px 0;border-bottom:1px solid var(--line-soft)}
.card--list .c-body{padding:0}
.card--list .c-title{font-size:1rem}
.card--list:first-of-type{padding-top:0}
@media(min-width:1024px){.card--list{grid-template-columns:150px minmax(0,1fr)}.card--list .c-title{font-size:1.05rem}}

.card--album .c-title{font-size:1.15rem;margin-top:12px}
.artist{margin:4px 0 0;color:var(--accent);font-weight:700;font-size:.85rem}

/* ==== Homepage hero: lead · Hot Stories · pick ==== */
.hero{display:grid;gap:36px}
.hot-title{font-size:clamp(1.65rem,3vw,2.3rem);font-weight:800;text-transform:uppercase;line-height:1;padding-bottom:14px;margin-bottom:16px;border-bottom:1px solid var(--line)}
@media(min-width:768px){.hero{grid-template-columns:1fr 1fr}.hero-pick{grid-column:1/-1;max-width:420px}}
@media(min-width:1100px){.hero{grid-template-columns:1.05fr 1fr .8fr;gap:32px}.hero-pick{grid-column:auto;max-width:none}.hero-hot{margin-top:28px}}

/* ==== Horizontal rails (Latest / Best New Music) — CSS scroll-snap, no slider JS ==== */
.rail-wrap{position:relative}
.rail{display:grid;grid-auto-flow:column;grid-auto-columns:72%;gap:20px;overflow-x:auto;scroll-snap-type:x mandatory;scrollbar-width:none;overscroll-behavior-x:contain;padding-bottom:4px}
.rail::-webkit-scrollbar{display:none}
.rail>*{scroll-snap-align:start}
.rail--albums{grid-auto-columns:44%}
@media(min-width:640px){.rail,.rail--albums{grid-auto-columns:calc((100% - 40px)/3)}}
@media(min-width:1024px){.rail,.rail--albums{grid-auto-columns:calc((100% - 80px)/5)}}
.rail-btns{display:none}
@media(min-width:1024px) and (hover:hover){
  .rail-btns{display:flex;gap:8px;justify-content:flex-end;margin-top:18px}
  .rail-btn{width:38px;height:38px;border:1px solid var(--line);border-radius:50%;display:flex;align-items:center;justify-content:center}
  .rail-btn:hover{border-color:var(--text)}
  .rail-btn svg{width:16px;height:16px}
}

/* ==== Category blocks: big feature + list ==== */
.block{display:grid;gap:28px}
@media(min-width:900px){
  .block{grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:40px}
  .block--flip{grid-template-columns:minmax(0,1fr) minmax(0,1.2fr)}
  .block--flip .block-feature{order:2}
}

/* ==== Listing / single layout with sidebar ==== */
.layout{display:grid;gap:48px}
@media(min-width:1024px){.layout{grid-template-columns:minmax(0,1fr) 300px}}
.rows{display:grid}
@media(min-width:700px){
  .rows{grid-template-columns:1fr 1fr;column-gap:28px}
  .rows .card--list:nth-of-type(2){padding-top:0}
}
.empty{color:var(--muted)}
.sidebar{display:flex;flex-direction:column;gap:32px}
@media(min-width:1024px){.sidebar{position:sticky;top:calc(var(--header-h) + 24px);align-self:start}}
.side-title,.widget-title{font-size:1.25rem;font-weight:800;text-transform:uppercase;padding-bottom:10px;margin-bottom:14px;border-bottom:2px solid var(--line)}
.side-links a{display:flex;justify-content:space-between;align-items:center;padding:10px 0;border-bottom:1px solid var(--line-soft);font-weight:600}
.side-links a:hover{color:var(--accent)}
.side-links svg{width:14px;height:14px}
.trend-list{counter-reset:t}
.trend-list li{counter-increment:t;display:grid;grid-template-columns:34px 1fr;gap:8px;padding:12px 0;border-bottom:1px solid var(--line-soft)}
.trend-list li::before{content:counter(t,decimal-leading-zero);font-weight:800;font-size:1.1rem;color:var(--accent);line-height:1.3}
.trend-list a{font-weight:600;line-height:1.3}
.trend-list a:hover{color:var(--accent)}

/* Pagination */
.pagination{margin-top:32px}
.pagination .nav-links{display:flex;gap:8px;flex-wrap:wrap}
.pagination .page-numbers{min-width:40px;height:40px;padding:0 8px;display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--line-soft);border-radius:var(--radius);font-weight:700;font-size:.88rem}
.pagination .page-numbers.current{background:var(--text);color:var(--bg);border-color:var(--text)}
.pagination a.page-numbers:hover{border-color:var(--text)}
.pagination svg{width:16px;height:16px}

/* ==== Single ==== */
.article{min-width:0}
.article-head{max-width:760px}
.entry-title{font-size:clamp(1.75rem,3.6vw,2.3rem);font-weight:600;line-height:1.2;letter-spacing:-.01em;margin:6px 0 12px}
.entry-subtitle{font-size:1.1rem;color:var(--muted);margin:0 0 14px}
.entry-bar{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px 20px;padding-bottom:18px;border-bottom:1px solid var(--line-soft)}
.entry-meta{display:flex;flex-wrap:wrap;gap:8px 18px;color:var(--muted);font-size:.85rem}
.entry-meta span{display:inline-flex;align-items:center;gap:6px}
.entry-meta svg{width:15px;height:15px}
.entry-meta a{color:var(--text);font-weight:600}
.entry-thumb{display:flex;justify-content:center;margin:24px 0}
.entry-thumb img{width:100%;height:auto;border-radius:var(--radius)}
.entry-thumb.is-capped{background:var(--surface);border-radius:var(--radius);padding:16px}
.entry-content{font-size:1.1rem;line-height:1.75;max-width:760px;overflow-wrap:break-word}
.entry-content>*{margin-top:0;margin-bottom:1.15em}
.entry-content h2{font-size:1.5rem;line-height:1.3;margin-top:1.6em}
.entry-content h3{font-size:1.25rem;line-height:1.3;margin-top:1.4em}
.entry-content a{color:var(--accent);text-decoration:underline;text-underline-offset:2px}
.entry-content ul,.entry-content ol{padding-left:1.3em;list-style:revert}
.entry-content li{margin-bottom:.4em}
.entry-content img{border-radius:var(--radius)}
.entry-content blockquote{margin-left:0;padding:4px 0 4px 20px;border-left:3px solid var(--accent);font-size:1.15rem;font-weight:500}
.entry-content figure{margin-left:0;margin-right:0}
.entry-content figcaption,.wp-caption-text{color:var(--muted);font-size:.85rem;margin-top:8px}
.entry-content table{width:100%;border-collapse:collapse;font-size:.95rem}
.entry-content td,.entry-content th{border:1px solid var(--line-soft);padding:8px 10px}
.entry-content pre{overflow-x:auto;background:var(--surface);padding:14px;border-radius:var(--radius);font-size:.9rem}
.aligncenter{margin-left:auto;margin-right:auto}
.alignleft{float:left;margin:0 1em 1em 0}
.alignright{float:right;margin:0 0 1em 1em}
/* Minimal block styles (core block library CSS is not loaded) */
.wp-block-image img{height:auto}
.wp-block-embed{margin-left:0;margin-right:0}
.wp-block-embed__wrapper{position:relative}
.wp-block-gallery,.blocks-gallery-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(160px,1fr));gap:10px;padding:0;list-style:none}
.wp-block-columns{display:flex;flex-wrap:wrap;gap:1.5em}
.wp-block-column{flex:1 1 240px;min-width:0}
.wp-block-button__link{display:inline-block;padding:12px 20px;border-radius:var(--radius);background:var(--accent);color:#fff!important;text-decoration:none!important;font-weight:700}
.wp-block-separator{border:0;border-top:1px solid var(--line-soft)}

/* Video embeds: fixed 16:9 box + YouTube click-to-load facade */
.embed{position:relative;aspect-ratio:16/9;border-radius:var(--radius);overflow:hidden;background:#000;margin-bottom:1.15em}
.embed iframe,.yt-facade{position:absolute;inset:0;width:100%;height:100%;border:0}
.yt-facade{background:linear-gradient(135deg,#0d0d0f,#2b1418);color:#fff}
.yt-facade img{width:100%;height:100%;object-fit:cover;border-radius:0}
.yt-label{position:absolute;left:16px;bottom:14px;font-size:.85rem;font-weight:700;letter-spacing:.02em}
.yt-play{position:absolute;top:50%;left:50%;width:68px;height:48px;margin:-24px 0 0 -34px;border-radius:12px;background:rgba(20,20,20,.8);color:#fff;display:flex;align-items:center;justify-content:center;transition:background .15s}
.yt-facade:hover .yt-play,.yt-facade:focus-visible .yt-play{background:#cc0000}
.yt-play svg{width:28px;height:28px}

/* Stream on Digital Stores: player + branded buttons */
.stream{margin:36px 0;max-width:760px}
.stream-title{text-align:center;font-size:1.3rem;font-weight:800;text-transform:uppercase;letter-spacing:-.005em;border-bottom:1px solid var(--line-soft);margin-bottom:22px}
.stream-title span{display:inline-block;padding-bottom:12px;margin-bottom:-1px;border-bottom:3px solid var(--accent)}
.store-embed{margin-bottom:18px}
.store-embed iframe{width:100%;border:0;border-radius:12px;background:var(--surface)}
.store-embed--audiomack iframe{height:252px}
.store-embed--spotify iframe{height:152px}
.store-embed--apple iframe{height:175px}
.embed iframe{border-radius:12px}
.stream-grid{display:flex;flex-wrap:wrap;justify-content:center;gap:14px}
.store-btn{display:inline-flex;align-items:center;gap:12px;min-width:200px;justify-content:center;padding:10px 22px;border-radius:12px;color:#fff;transition:transform .15s,filter .15s}
.store-btn:hover{transform:translateY(-2px);filter:brightness(1.08)}
.store-btn svg{width:26px;height:26px}
.store-text{display:flex;flex-direction:column;line-height:1.15;text-align:left}
.store-text small{font-size:.7rem;font-weight:700;text-transform:uppercase;letter-spacing:.03em}
.store-text strong{font-size:1.05rem;font-weight:800}
.store-btn--youtube{background:#cc0000}
.store-btn--spotify{background:#1db954;color:#000}
.store-btn--audiomack{background:#ffa200;color:#000}
.store-btn--apple{background:#c8102e}
@media(max-width:600px){.stream-grid{flex-direction:column;align-items:stretch}.store-btn{width:100%}}

/* Share buttons */
.share-icons{display:flex;align-items:center;gap:8px}
.share-btn{width:40px;height:40px;border-radius:50%;border:1px solid var(--line-soft);display:inline-flex;align-items:center;justify-content:center;transition:background .15s,color .15s,border-color .15s}
.share-btn svg{width:18px;height:18px}
.share-btn--facebook:hover{background:#1877f2;border-color:#1877f2;color:#fff}
.share-btn--x:hover{background:#000;border-color:#000;color:#fff}
.share-btn--linkedin:hover{background:#0a66c2;border-color:#0a66c2;color:#fff}
.share-btn--whatsapp:hover{background:#25d366;border-color:#25d366;color:#fff}
.share-btn--link:hover{background:var(--text);border-color:var(--text);color:var(--bg)}
.share-btn.is-copied{background:#1db954;border-color:#1db954;color:#fff}

/* Post footer: country/artist chips left, share right */
.post-foot{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:16px 24px;margin:32px 0;padding:20px 0;border-top:1px solid var(--line-soft);border-bottom:1px solid var(--line-soft)}
.chips{display:flex;flex-wrap:wrap;gap:10px}
.chips a{padding:8px 16px;border-radius:999px;background:var(--text);color:var(--bg);font-weight:700;font-size:.85rem}
.chips a:hover{background:var(--accent);color:#fff}
.share-foot{display:flex;align-items:center;gap:12px;margin-left:auto}
.share-label{font-size:.85rem;font-weight:800}
.related{margin-top:40px}
.grid-tiles{display:grid;gap:24px;grid-template-columns:1fr 1fr}
@media(min-width:900px){.grid-tiles{grid-template-columns:repeat(4,1fr)}}

/* Comments */
.comments-area{margin-top:40px;max-width:760px}
.comment-list{margin:0 0 24px}
.comment-list .children{padding-left:20px}
.comment-body{padding:14px 0;border-bottom:1px solid var(--line-soft)}
.comment-author{font-weight:700;font-size:.92rem}
.comment-author img{display:none}
.comment-metadata{color:var(--muted);font-size:.78rem;margin-bottom:6px}
.comment-respond{margin-top:16px}
.comment-form p{margin:0 0 12px}
.comment-form label{display:block;font-size:.85rem;font-weight:600;margin-bottom:4px}
.comment-form input[type=text],.comment-form input[type=email],.comment-form input[type=url],.comment-form textarea{width:100%;padding:11px 12px;border:1px solid var(--line-soft);border-radius:var(--radius);background:var(--surface)}
.comment-form .submit{padding:11px 20px;border:0;border-radius:var(--radius);background:var(--text);color:var(--bg);font-weight:700;cursor:pointer}

/* ==== Categories page / 404 ==== */
.cat-grid{display:grid;gap:24px;grid-template-columns:repeat(2,minmax(0,1fr))}
@media(min-width:900px){.cat-grid{grid-template-columns:repeat(4,minmax(0,1fr))}}
.cat-tile-name{display:block;margin-top:10px;font-weight:700;font-size:1.1rem}
.cat-tile:hover .cat-tile-name{color:var(--accent)}
.cat-tile-count{color:var(--muted);font-size:.85rem}
.not-found{text-align:center;padding-top:72px;padding-bottom:72px}
.not-found .page-lede{margin:0 auto 24px}
.nf-code{font-size:5rem;font-weight:900;font-style:italic;line-height:1;margin:0 0 12px;color:var(--accent)}
.search-form{display:flex;gap:8px;max-width:440px;margin:0 auto 20px}
.search-form input{flex:1;padding:10px 14px;border:1px solid var(--line);border-radius:var(--radius);background:var(--bg)}

/* ==== Footer ==== */
.site-footer{border-top:1px solid var(--line-soft);margin-top:24px}
.footer-grid{display:grid;gap:32px;padding-top:40px;padding-bottom:40px;grid-template-columns:repeat(2,minmax(0,1fr))}
.footer-brand{grid-column:1/-1}
.footer-brand p{margin:12px 0 18px}
@media(min-width:900px){.footer-grid{grid-template-columns:1.6fr repeat(4,minmax(0,1fr))}.footer-brand{grid-column:auto}}
.footer-col h2{font-size:.95rem;font-weight:700;margin-bottom:12px}
.footer-col a{display:block;padding:4px 0;font-size:.86rem}
.footer-col a:hover{color:var(--accent)}
.footer-bottom{border-top:1px solid var(--line-soft);padding:18px 0;text-align:center;font-size:.86rem}

/* ==== Widgets (sidebar-1) ==== */
.widget{min-width:0}
.widget ul li a{display:block;padding:8px 0;border-bottom:1px solid var(--line-soft)}

@media(prefers-reduced-motion:reduce){*,*::before,*::after{transition:none!important;scroll-behavior:auto!important}}

/* Breadcrumbs */
.breadcrumbs{margin:0 0 14px;font-size:.8rem;color:var(--muted)}
.breadcrumbs ol{display:flex;flex-wrap:wrap;gap:4px 8px}
.breadcrumbs li:not(:last-child)::after{content:"›";margin-left:8px;opacity:.6}
.breadcrumbs a:hover{color:var(--accent)}
.breadcrumbs [aria-current]{color:var(--text);opacity:.85}
