/*
Theme Name: Bilieter Editorial
Theme URI: https://bilieter.co.uk/
Description: Lightweight magazine layout with editable homepage, featured stories, popular stories and latest articles.
Version: 1.6.0
Requires at least: 6.2
Requires PHP: 7.4
Author: Bilieter
Text Domain: bilieter-editorial
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
*/
:root{--ink:#17202b;--muted:#58616d;--accent:#245b78;--bg:#f4f6f7;--line:#e0e5e8;--white:#fff}*{box-sizing:border-box}body{margin:0;color:var(--ink);background:var(--bg);font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;font-size:16px;line-height:1.65;overflow-wrap:anywhere}a{color:var(--accent);text-underline-offset:3px}a:hover{text-decoration:underline}a:focus-visible,button:focus-visible,input:focus-visible,textarea:focus-visible,summary:focus-visible{outline:3px solid #b16a13;outline-offset:3px}img{max-width:100%;height:auto;vertical-align:middle}button,input,textarea{font:inherit;max-width:100%}button{cursor:pointer}.shell{max-width:1200px;margin:auto;padding:0 24px}.skip{position:absolute;left:12px;top:-100px;background:white;padding:12px;z-index:99}.skip:focus{top:12px}.masthead{background:#fff;border-bottom:1px solid var(--line)}.brandrow{display:flex;align-items:center;justify-content:space-between;gap:24px;min-height:92px}.brand{font-size:clamp(29px,4vw,43px);font-weight:850;letter-spacing:-.06em;text-decoration:none;color:var(--ink);line-height:1.1}.custom-logo{max-width:210px;max-height:74px;width:auto}.tagline{font-size:13px;color:var(--muted);margin:3px 0}.searchform{display:flex;align-items:center;gap:6px}.searchform input[type=search]{border:1px solid var(--line);border-radius:4px;padding:8px 10px;min-width:0;width:180px}.button,button,input[type=submit]{background:var(--accent);color:white;border:0;border-radius:4px;padding:9px 14px}.menu-bar{border-top:1px solid var(--line);background:#fff}.menu-bar ul,.footer-nav ul{list-style:none;margin:0;padding:0;display:flex;gap:0;flex-wrap:wrap}.menu-bar li{position:relative}.menu-bar a{display:block;color:var(--ink);text-decoration:none;font-weight:650;font-size:14px;padding:13px 15px}.menu-bar a:hover,.menu-bar .current-menu-item>a{color:var(--accent);text-decoration:underline}.menu-bar .sub-menu{display:none;position:absolute;top:100%;left:0;min-width:180px;background:white;z-index:5;box-shadow:0 5px 18px #0002}.menu-bar li:hover>.sub-menu,.menu-bar li:focus-within>.sub-menu{display:block}.nav-toggle{display:none;margin:8px 0}.paper{background:white;min-height:60vh;padding:28px 24px 56px}.section{margin:0 0 44px}.section-title{font-size:15px;font-weight:800;text-transform:uppercase;letter-spacing:.08em;text-align:left;margin:0 0 22px}.section-title:after{content:"";display:block;width:32px;height:2px;background:var(--accent);margin:8px 0 0}.hero-grid{display:grid;grid-template-columns:2fr 1fr 1fr;grid-template-rows:180px 180px;gap:4px}.hero-card{position:relative;min-width:0;overflow:hidden;background:#253846;display:flex;align-items:flex-end;isolation:isolate}.hero-card:first-child{grid-row:span 2}.hero-card:nth-child(4){grid-column:span 2}.hero-card img,.hero-card .placeholder{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;z-index:-2}.hero-card:after{content:"";position:absolute;inset:0;background:linear-gradient(0deg,#000d 0%,#0008 45%,#0000 100%);z-index:-1;pointer-events:none}.hero-card a{color:white;text-decoration:none;display:block;width:100%;padding:16px}.hero-card h2{font-size:16px;line-height:1.35;margin:5px 0 8px}.hero-card:first-child h2{font-size:clamp(21px,2.6vw,30px)}.hero-card:hover h2{text-decoration:underline}.category{font-size:11px;letter-spacing:.06em;font-weight:750;text-transform:uppercase;color:var(--accent)}.hero-card .category{color:white;background:var(--accent);display:inline-block;padding:3px 6px}.meta{font-size:12px;color:var(--muted)}.hero-card .meta{color:#f2f2f2}.placeholder{display:block;background:linear-gradient(135deg,#b1c5ce,#355a70);aspect-ratio:16/10}.cards{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:20px}.card{min-width:0}.card a{color:var(--ink);text-decoration:none}.card a:hover{text-decoration:underline}.card-media{display:block;aspect-ratio:16/10;background:#e4ebee;overflow:hidden}.card-media img{width:100%;height:100%;object-fit:cover}.card h3{font-size:17px;line-height:1.35;margin:6px 0}.card .category{display:block;margin:10px 0 4px}.card p{font-size:14px;color:var(--muted);margin:8px 0}.article{width:100%;max-width:none;margin:0;font-size:18px;line-height:1.72;text-align:left}.article h1{font-size:clamp(30px,4.4vw,46px);line-height:1.12;letter-spacing:-.035em;margin:12px 0 16px}.article h2{font-size:clamp(22px,3vw,29px);line-height:1.3;margin-top:1.65em}.article h3{line-height:1.4}.article p,.article li{margin-bottom:1em}.article figure{margin:24px 0}.article table{display:block;max-width:100%;overflow-x:auto;border-collapse:collapse}.article td,.article th{border:1px solid var(--line);padding:8px}.article pre{max-width:100%;overflow:auto;background:#f2f4f5;padding:12px}.article .wp-block-image img{height:auto}.article input:not([type=submit]),.article textarea{border:1px solid #adb6bf;padding:8px;border-radius:4px}.article textarea{width:100%}.crumbs{font-size:13px;color:var(--muted);margin-bottom:18px}.feature-img{width:100%;height:auto;margin:18px 0}.related{border-top:1px solid var(--line);padding-top:24px;margin-top:32px}.footer{background:#162735;color:#e5edf1;padding:36px 0 20px}.footer a{color:#e5edf1}.footer-inner{display:grid;grid-template-columns:1fr 2fr;gap:28px}.footer-nav ul{gap:10px 20px}.footer-nav a{font-size:14px}.copyright{border-top:1px solid #ffffff30;padding-top:16px;margin-top:24px;font-size:13px}.screen-reader-text{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(1px,1px,1px,1px)}.pagination{margin:30px 0}.pagination .page-numbers{padding:8px}.archive-title{font-size:30px;margin-top:0}.wp-caption,.alignwide,.alignfull{max-width:100%}.alignleft{float:left;margin:0 20px 12px 0}.alignright{float:right;margin:0 0 12px 20px}.aligncenter{display:block;margin-left:auto;margin-right:auto}.contact-hp{position:absolute;left:-9999px}.notice{padding:12px;border:1px solid var(--line);background:#f4f6f7}.hero-grid.few{grid-template-rows:auto;grid-template-columns:repeat(auto-fit,minmax(min(100%,250px),1fr))}.hero-grid.few .hero-card{min-height:260px;grid-row:auto;grid-column:auto}.wp-block-embed iframe{max-width:100%}
@media(max-width:850px){.cards{grid-template-columns:repeat(2,minmax(0,1fr))}.hero-grid{grid-template-columns:1fr 1fr;grid-template-rows:auto}.hero-card{min-height:180px}.hero-card:first-child{grid-column:span 2;grid-row:auto;min-height:280px}.hero-card:nth-child(4){grid-column:span 2}.footer-inner{grid-template-columns:1fr}.shell{padding-left:18px;padding-right:18px}}
@media(max-width:550px){.brandrow{min-height:76px;gap:12px;flex-wrap:wrap;padding-top:12px;padding-bottom:12px}.brandrow .searchform{width:100%}.brandrow .searchform input[type=search]{flex:1;width:auto}.paper{padding:18px 14px 36px}.shell{padding-left:14px;padding-right:14px}.hero-grid{display:grid;grid-template-columns:1fr;gap:8px}.hero-card,.hero-card:first-child,.hero-card:nth-child(4){grid-column:auto;min-height:200px}.hero-card:first-child{min-height:250px}.cards{gap:14px}.card h3{font-size:15px}.nav-toggle{display:block}.js .menu-bar ul.menu{display:none}.js .menu-bar ul.menu.open{display:flex;flex-direction:column}.menu-bar .sub-menu{position:static;box-shadow:none;display:block;padding-left:15px}.article{font-size:17px;line-height:1.7}.section{margin-bottom:32px}.footer-inner{gap:16px}}

/* Keep media and flexible columns inside their containers on narrow screens. */
.brandrow>div,.brandrow form,.article,.card,.hero-card{min-width:0}.custom-logo-link{display:inline-block;max-width:100%}.custom-logo{display:block;width:210px;max-width:100%;height:auto;max-height:none}.searchform,.wp-block-search__inside-wrapper{max-width:100%}.article iframe,.article video{max-width:100%}

/* Homepage editorial introduction: broader reading column, distinct from single-post layout. */
.home .home-editorial{width:100%;max-width:none;margin:0;padding:30px 0 12px;border-top:1px solid var(--line);font-size:18px;line-height:1.72;overflow-wrap:break-word}
.home .home-editorial h1{font-size:clamp(30px,3.4vw,44px);line-height:1.18;letter-spacing:-.035em;margin:0 0 20px}
.home .home-editorial h2{font-size:clamp(23px,2.4vw,28px);line-height:1.3;margin:30px 0 12px}
.home .home-editorial h3{font-size:20px;margin:22px 0 8px}
.home .home-editorial p{margin:0 0 16px}.home .home-editorial>p:first-of-type{font-size:19px;color:var(--ink)}
.home .browse-articles{text-align:left;margin:22px 0 0}.home .browse-articles a{display:inline-block;padding:10px 16px;border:1px solid var(--line);border-radius:4px;text-decoration:none;font-weight:650}.home .browse-articles a:hover{border-color:var(--accent);text-decoration:underline}
@media(max-width:850px){.home .home-editorial{padding:26px 0 8px}}
@media(max-width:550px){.home .home-editorial{font-size:17px;line-height:1.7;padding:24px 0 4px}.home .home-editorial h1{font-size:29px}.home .home-editorial h2{font-size:23px;margin-top:26px}.home .home-editorial>p:first-of-type{font-size:18px}}

/* Shared editorial reading layout: content follows the same left edge as the magazine grid. */
.article h1,.article h2,.article h3,.article h4,.entry-content p,.entry-content li{text-align:left}
.article h1{margin:0 0 18px;font-size:clamp(30px,3.6vw,44px);line-height:1.16;overflow-wrap:break-word}
.article h2{font-size:clamp(23px,2.5vw,29px);line-height:1.3;margin:32px 0 12px}
.article h3{font-size:20px;line-height:1.38;margin:24px 0 8px}
.article h4{font-size:18px;line-height:1.4;margin:20px 0 8px}
.entry-content{display:flow-root;min-width:0;max-width:100%;overflow-wrap:break-word}
.entry-content p{margin:0 0 17px}.entry-content>p:last-child{margin-bottom:0}
.entry-content ul,.entry-content ol{padding-inline-start:1.5em;margin:0 0 20px}.entry-content li{margin-bottom:8px}
.entry-content blockquote{border-inline-start:3px solid var(--accent);margin:24px 0;padding:5px 0 5px 18px;color:var(--muted)}
.entry-content figure{max-width:100%}.entry-content figcaption{font-size:14px;color:var(--muted);margin-top:8px}
.entry-content .wp-block-table{max-width:100%;overflow-x:auto}.entry-content .wp-block-table table{display:table;width:100%;border-collapse:collapse}
.entry-content .wp-block-columns,.entry-content .wp-block-column{min-width:0}.entry-content .wp-block-image img{max-width:100%;height:auto}
.article .meta{margin:0 0 18px;font-size:14px}.feature-img{display:block;width:100%;height:auto;margin:20px 0 26px;border-radius:4px}
.crumbs{margin-bottom:14px}.related .cards{grid-template-columns:repeat(3,minmax(0,1fr))}.related .card h3{font-size:17px;margin:6px 0}
@media(max-width:850px){.article{font-size:17px}.related .cards{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:550px){.article h1{font-size:30px;line-height:1.2}.article h2{font-size:23px;margin-top:26px}.article h3{font-size:19px}.article .meta{font-size:13px}.entry-content p{margin-bottom:15px}.feature-img{margin:16px 0 20px}.related .cards{gap:14px}}

/* Editorial footer only: preserve the page and header layouts. */
.footer-editorial{background:#162735;color:#e5edf1;padding:50px 0 22px;border-top:4px solid var(--accent)}
.footer-editorial .footer-inner{grid-template-columns:minmax(0,1.35fr) minmax(0,.85fr) minmax(0,1fr) minmax(0,1.2fr);gap:32px;align-items:start}
.footer-editorial .footer-inner>*{min-width:0}
.footer-editorial .footer-wordmark{font-size:36px;line-height:1.1;letter-spacing:-.05em;font-weight:850;text-decoration:none;color:#fff;display:inline-block;margin:0 0 14px}
.footer-editorial .footer-wordmark span{color:#9bd0e6}
.footer-editorial h2{font-size:15px;font-weight:750;color:#fff;margin:4px 0 15px;line-height:1.4;letter-spacing:.01em}
.footer-editorial p{font-size:14px;line-height:1.65;color:#c8d6df;margin:0 0 16px}
.footer-editorial .footer-market-label{font-size:12px;color:#c8d6df;font-weight:650;margin-bottom:7px}
.footer-editorial ul{list-style:none;padding:0;margin:0}
.footer-editorial .footer-markets{display:flex;flex-wrap:wrap;gap:6px}
.footer-editorial .footer-markets li{font-size:12px;font-weight:650;color:#e5edf1;border:1px solid #617685;border-radius:4px;padding:3px 8px}
.footer-editorial .footer-links,.footer-editorial .footer-nav ul{display:grid;gap:5px;align-items:start}
.footer-editorial .footer-links a,.footer-editorial .footer-nav a{font-size:14px;line-height:1.5;color:#d7e3ea;text-decoration:none;display:inline-block;padding:3px 0}
.footer-editorial a:hover{color:#fff;text-decoration:underline}
.footer-editorial a:focus-visible{outline:3px solid #f4cc7c;outline-offset:3px}
.footer-editorial .footer-cta{display:inline-flex;flex-wrap:wrap;align-items:center;gap:8px;background:#e7f0f5;color:#172b39;padding:10px 14px;border-radius:5px;font-size:14px;font-weight:700;line-height:1.4;text-decoration:none;max-width:100%}
.footer-editorial .footer-cta:hover{background:#fff;color:#172b39;text-decoration:underline}
.footer-editorial .footer-bottom{display:flex;align-items:center;justify-content:space-between;gap:14px;flex-wrap:wrap;margin-top:32px;padding-top:18px;color:#bdccd6;font-size:13px}
.footer-editorial .footer-top{font-size:13px;font-weight:600;text-decoration:none}
@media(max-width:900px){.footer-editorial .footer-inner{grid-template-columns:repeat(2,minmax(0,1fr));gap:28px}.footer-editorial{padding-top:36px}}
@media(max-width:480px){.footer-editorial .footer-inner{grid-template-columns:1fr 1fr;gap:24px 16px}.footer-editorial .footer-brand,.footer-editorial .footer-partner{grid-column:1/-1}.footer-editorial .footer-wordmark{font-size:32px}.footer-editorial .footer-bottom{align-items:flex-start;flex-direction:column;margin-top:26px}.footer-editorial h2{margin-top:0}}

/* Mobile-first magazine refinement. Desktop styles and content stay intact. */
@media(max-width:767px){
 .shell{padding-inline:16px}.paper{padding:18px 16px 28px}.brandrow{min-height:0;display:grid;grid-template-columns:minmax(0,1fr);gap:12px;padding-block:14px}.custom-logo{width:150px}.tagline{font-size:12px;line-height:1.45;margin:5px 0 0}.brandrow .searchform{width:100%;gap:8px}.brandrow .searchform input[type=search]{flex:1;width:0;min-height:44px;font-size:16px;border-radius:7px}.brandrow .searchform button,.brandrow .searchform input[type=submit]{min-height:44px;border-radius:7px}.nav-toggle{display:block;min-height:44px;margin:6px 0;width:100%;text-align:left;border-radius:6px;background:#f0f4f6;color:var(--ink);font-weight:700}.nav-toggle:before{content:"☰";margin-right:10px}.nav-toggle[aria-expanded=true]:before{content:"×"}.js .menu-bar ul.menu{display:none}.js .menu-bar ul.menu.open{display:flex;flex-direction:column}.menu-bar .menu>li>a{padding:12px 10px;min-height:44px}.menu-bar .sub-menu{position:static;box-shadow:none;display:block;padding-left:15px}.menu-bar .menu>li+li{border-top:1px solid var(--line)}
 .hero-grid,.hero-grid.few{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto;gap:12px}.hero-grid .hero-card:first-child{grid-column:auto;grid-row:auto;min-height:0;aspect-ratio:4/3;border-radius:12px}.hero-card:first-child a{padding:18px}.hero-card:first-child h2{font-size:clamp(20px,5.6vw,27px);line-height:1.22}.hero-grid .hero-card:not(:first-child){display:grid;grid-template-columns:minmax(0,34%) minmax(0,1fr);align-items:center;grid-column:auto;grid-row:auto;min-height:0;background:#fff;border:1px solid var(--line);border-radius:9px;padding:10px;gap:12px;isolation:auto}.hero-card:not(:first-child):after{display:none}.hero-card:not(:first-child) img,.hero-card:not(:first-child) .placeholder{position:static;inset:auto;width:100%;height:auto;aspect-ratio:4/3;object-fit:cover;z-index:auto;border-radius:6px}.hero-card:not(:first-child) a{padding:0;color:var(--ink);min-width:0}.hero-card:not(:first-child) .category{color:var(--accent);background:none;padding:0;font-size:10px;letter-spacing:.03em}.hero-card:not(:first-child) h2{font-size:15px;line-height:1.32;margin:3px 0 5px}.hero-card:not(:first-child) .meta{color:var(--muted);font-size:11px}.section{margin-bottom:26px}.section-title{margin-bottom:16px}.home .browse-articles{margin-top:12px}.home .browse-articles a{display:flex;justify-content:center;min-height:44px;align-items:center;border-radius:7px}
 .home .home-editorial{padding:22px 0 0;font-size:16px;line-height:1.7}.home .home-editorial h1,.article h1{font-size:clamp(27px,6.5vw,34px);line-height:1.18;margin-bottom:14px}.home .home-editorial h2,.article h2{font-size:22px;line-height:1.3;margin:24px 0 10px}.home .home-editorial h3,.article h3{font-size:18px;line-height:1.4;margin:20px 0 8px}.home .home-editorial>p:first-of-type,.home .entry-content>p:first-child{font-size:17px}.article{font-size:16px;line-height:1.7}.entry-content p{margin-bottom:14px}.entry-content .wp-block-columns{display:grid!important;grid-template-columns:minmax(0,1fr)!important;gap:10px!important;margin:12px 0 22px;align-items:stretch}.entry-content .wp-block-columns>.wp-block-column{width:100%!important;min-width:0;flex-basis:auto!important;margin:0!important;padding:16px!important}.entry-content .wp-block-column h3{margin:0 0 6px}.entry-content .wp-block-column p{margin:0 0 10px}.entry-content .wp-block-column p:last-child{margin:0}.entry-content .wp-block-column a{display:inline-flex;align-items:center;min-height:44px}.home .bilieter-pre-footer{margin-top:24px!important;margin-bottom:0!important}.home .bilieter-pre-footer>h2{margin-top:0}.home .bilieter-pre-footer .wp-block-columns{margin-bottom:0}.home .bilieter-pre-footer .wp-block-column{border-left:3px solid var(--accent)!important}.cards,.related .cards{grid-template-columns:repeat(2,minmax(0,1fr));gap:16px 12px}.card-media{border-radius:7px}.card h3,.related .card h3{font-size:15px;line-height:1.35}.card .category{font-size:10px}.feature-img{margin:16px 0 20px;border-radius:8px}.crumbs{font-size:12px;line-height:1.5}.article .wp-block-table{overflow-x:auto;max-width:100%}.article .wp-block-table table{min-width:400px;font-size:14px}.article .wp-block-table td,.article .wp-block-table th{padding:9px}.archive-title{font-size:27px}
 .footer-editorial{padding:28px 0 16px}.footer-editorial .footer-inner{grid-template-columns:repeat(2,minmax(0,1fr));gap:20px 14px}.footer-editorial .footer-brand,.footer-editorial .footer-partner{grid-column:1/-1}.footer-editorial .footer-brand{padding-bottom:16px;border-bottom:1px solid #ffffff26}.footer-editorial .footer-wordmark{font-size:30px;margin-bottom:10px}.footer-editorial .footer-links,.footer-editorial .footer-nav ul{gap:0}.footer-editorial .footer-links a,.footer-editorial .footer-nav a{display:flex;align-items:center;min-height:40px;padding:6px 0;font-size:13px}.footer-editorial h2{margin:0 0 6px}.footer-editorial .footer-partner{padding:16px;border:1px solid #ffffff26;border-radius:8px}.footer-editorial .footer-cta{min-height:44px}.footer-editorial .footer-bottom{gap:6px;margin-top:20px;padding-top:12px}.footer-editorial .footer-top{display:inline-flex;align-items:center;min-height:44px}
}
@media(max-width:359px){.shell,.paper{padding-inline:12px}.hero-grid .hero-card:not(:first-child){grid-template-columns:minmax(0,30%) minmax(0,1fr);gap:9px}.cards,.related .cards{grid-template-columns:1fr}.footer-editorial .footer-inner{gap:16px 10px}}

/* Homepage international editorial markets: additive section only. */
.bilieter-audience{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.4fr);align-items:center;gap:24px;margin:0 0 28px;padding:26px 28px;background:#172a3b;color:#fff;border-radius:10px;border:1px solid #345065}
.bilieter-audience-intro{min-width:0}.bilieter-audience h2{color:#fff;font-size:clamp(22px,2.3vw,30px);line-height:1.2;margin:0 0 8px;letter-spacing:-.025em}.bilieter-audience p{color:#d2dfe8;font-size:14px;line-height:1.6;margin:0}.bilieter-audience-markets{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;list-style:none;margin:0;padding:0}.bilieter-audience-markets li{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;min-width:0;padding:12px 8px;background:#20384c;border:1px solid #567084;border-radius:7px;text-align:center;font-size:13px;line-height:1.35;font-weight:600;color:#f3f7fa}.bilieter-market-code{display:block;font-size:22px;font-weight:800;line-height:1.1;letter-spacing:.04em;color:#d2ebf8}
@media(max-width:850px){.bilieter-audience{grid-template-columns:1fr;gap:16px;padding:22px}.bilieter-audience-intro{text-align:center}}
@media(max-width:550px){.bilieter-audience{padding:18px 12px;margin-bottom:22px;border-radius:9px;gap:14px}.bilieter-audience h2{font-size:23px}.bilieter-audience p{font-size:13px}.bilieter-audience-markets{gap:6px}.bilieter-audience-markets li{padding:11px 4px;font-size:11px}.bilieter-market-code{font-size:19px}}
