/*
Theme Name: BeconomyTv
Theme URI: https://beconomytv.com
Author: BeconomyTv
Description: Tema TV/streaming per BeconomyTv — economia e cultura. Home video-centrica con video in evidenza e righe di puntate per rubrica.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 8.0
Text Domain: beconomytv
*/

:root{
  --acc:#D85A30;
  --acc-dark:#993C1D;
  --frame:#191826;
  --bg:#ffffff;
  --fg:#16161a;
  --muted:#6b6b73;
  --line:#ececec;
  --maxw:1200px;
}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;font-family:system-ui,-apple-system,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;color:var(--fg);background:var(--bg);line-height:1.5}
img{max-width:100%;height:auto;display:block}
a{color:inherit;text-decoration:none}
.container{max-width:var(--maxw);margin:0 auto;padding:0 20px}

/* header */
.site-header{border-bottom:1px solid var(--line);position:sticky;top:0;background:rgba(255,255,255,.97);backdrop-filter:saturate(1.2) blur(6px);z-index:50}
.admin-bar .site-header{top:32px}
@media (max-width:782px){.admin-bar .site-header{top:46px}}
.header-inner{display:flex;align-items:center;gap:22px;padding:14px 20px}
.logo{flex:none;font-size:27px;font-weight:800;letter-spacing:-.6px;line-height:1}
.logo span{color:var(--acc)}
.custom-logo-link{flex:none;display:inline-flex;align-items:center;line-height:0}
.site-header img.custom-logo{height:42px!important;width:auto!important;max-width:170px}
.site-header nav{flex:1 1 auto;min-width:0;position:relative}
.site-header nav::after{content:"";position:absolute;top:0;right:0;bottom:0;width:40px;background:linear-gradient(to right,rgba(255,255,255,0),rgba(255,255,255,.97));pointer-events:none}
.nav{list-style:none;display:flex;gap:18px;margin:0;padding:0;flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;-ms-overflow-style:none}
.nav::-webkit-scrollbar{display:none}
.nav li{flex:none}
.nav a{font-size:14px;color:var(--muted);white-space:nowrap}
.nav a:hover,.nav .current-menu-item>a{color:var(--fg)}
.header-right{flex:none;display:flex;align-items:center;gap:12px}
.live-badge{display:inline-flex;align-items:center;gap:6px;background:#fdecec;color:#a32d2d;font-size:13px;padding:4px 11px;border-radius:20px;font-weight:500}
.live-dot{width:7px;height:7px;border-radius:50%;background:#e24b4a;display:inline-block}
.search-form{display:flex}
.search-form input[type=search]{border:1px solid var(--line);border-radius:20px;padding:6px 12px;font-size:13px;width:150px;outline:none}
.search-form input[type=search]:focus{border-color:var(--acc)}

/* hero */
.hero{margin:22px 0 8px}
.hero-frame{position:relative;aspect-ratio:2.2/1;background:var(--frame);border-radius:14px;overflow:hidden;display:flex;align-items:center;justify-content:center}
.hero-frame img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;opacity:.82}
.hero-overlay{position:absolute;left:20px;right:20px;bottom:18px;color:#fff;z-index:2}
.hero-title{font-size:26px;font-weight:700;line-height:1.2;margin:8px 0 0;max-width:820px}
.hero-meta{font-size:13px;color:#dcdce0;margin-top:6px}
.tag{display:inline-block;background:var(--acc);color:#fff;font-size:12px;font-weight:500;padding:3px 9px;border-radius:5px}
.play{position:relative;z-index:2;width:44px;height:44px;border-radius:50%;background:rgba(255,255,255,.18);color:#fff;display:flex;align-items:center;justify-content:center;font-size:18px}
.play-lg{width:58px;height:58px;font-size:24px}

/* rows */
.row{margin-top:30px}
.row-head{display:flex;justify-content:space-between;align-items:baseline;margin-bottom:14px}
.row-head h2{font-size:19px;margin:0;font-weight:700}
.row-head a{font-size:13px;color:var(--muted)}
.row-head a:hover{color:var(--acc)}
.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:18px}

/* video card */
.vcard{display:block}
.thumb{position:relative;aspect-ratio:16/9;background:var(--frame);border-radius:10px;overflow:hidden;display:flex;align-items:center;justify-content:center}
.thumb img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.thumb .play{background:rgba(0,0,0,.35)}
.vcard:hover .thumb .play{background:var(--acc)}
.dur{position:absolute;bottom:7px;right:7px;background:rgba(0,0,0,.75);color:#fff;font-size:11px;padding:1px 6px;border-radius:4px;z-index:2}
.ct{font-size:15px;font-weight:600;margin:9px 0 3px;line-height:1.35}
.vcard:hover .ct{color:var(--acc-dark)}
.cm{font-size:12px;color:var(--muted)}

/* single / archive */
.page-head{margin:26px 0 18px}
.page-head h1{font-size:26px;margin:0}
.entry{font-size:18px;line-height:1.75;max-width:none}
.entry h2{font-size:22px}
.entry a{color:var(--acc-dark);text-decoration:underline}
.entry img{border-radius:10px}
/* video/embed: grandi e centrati, 16:9 */
.entry .wp-block-embed,.entry figure.wp-block-embed{margin:1.6em 0;max-width:none}
.entry .wp-block-embed__wrapper{position:relative;width:100%}
.entry .wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper::before{content:"";display:block;padding-top:56.25%}
.entry .wp-block-embed.wp-has-aspect-ratio iframe{position:absolute;inset:0;width:100%!important;height:100%!important;border:0;border-radius:12px;background:var(--frame)}
/* iframe/video "nudi" senza wrapper aspect-ratio */
.entry > iframe,.entry p > iframe,.entry video{display:block;width:100%;aspect-ratio:16/9;height:auto;margin:1.6em auto;border:0;border-radius:12px;background:var(--frame)}
.entry figure{margin:1.4em auto;text-align:center}
.single-meta{color:var(--muted);font-size:13px}
.single-hero{aspect-ratio:16/9;background:var(--frame);border-radius:14px;overflow:hidden;margin:14px 0 22px;max-width:900px}
.single-hero img{width:100%;height:100%;object-fit:cover}
.pagination{margin-top:26px}
.pagination .page-numbers{display:inline-block;padding:6px 11px;border:1px solid var(--line);border-radius:8px;margin-right:6px;font-size:14px}
.pagination .current{background:var(--acc);color:#fff;border-color:var(--acc)}

/* podcast card */
.pcard{display:flex;gap:12px;align-items:center}
.pcard .cover{width:56px;height:56px;border-radius:10px;background:var(--frame);color:#fff;flex:none;display:flex;align-items:center;justify-content:center;font-size:20px}

/* footer */
.site-footer{border-top:1px solid var(--line);margin-top:50px}
.footer-inner{display:flex;justify-content:space-between;align-items:center;padding:22px 20px;color:var(--muted);font-size:14px;flex-wrap:wrap;gap:10px;min-width:0}
.site-footer nav{min-width:0;max-width:100%}
.site-footer .nav{flex-wrap:wrap;overflow:visible}
.site-footer .nav::after{display:none}
.footer-inner .nav a{font-size:13px}

/* responsive */
@media (max-width:640px){
  .header-inner{flex-wrap:wrap;gap:12px}
  .site-header nav{order:3;flex-basis:100%}
  .site-header img.custom-logo{height:36px!important}
  .hero-title{font-size:20px}
  .row-head h2{font-size:17px}
  .grid{grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:14px}
  .ct{font-size:14px}
  .entry{font-size:17px}
  .search-form input[type=search]{width:120px}
}
