/*
Theme Name: Better Broadcast
Theme URI: https://example.com
Author: Better Broadcast
Description: A broadcasting-equipment publication and Amazon affiliate theme: equipment categories, buying guides, product reviews, studio builds, comparison tables and affiliate-link management. Install, import the content file, then run Appearance > Better Broadcast Setup.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPLv2 or later
Text Domain: better-broadcast
*/

:root {
	--ink: #0F1B2D; --ink2: #182A43; --paper: #F3F5F8; --line: #D5DCE5; --mute: #566478;
	--tally: #C8202B; --tally-dark: #A8171F;
	--serif: "Newsreader", Georgia, serif; --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 5rem; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--sans); color: var(--ink); background: #fff; line-height: 1.6; -webkit-font-smoothing: antialiased; }
img, svg { max-width: 100%; height: auto; }
h1, h2, h3, h4 { font-family: var(--serif); letter-spacing: -0.01em; line-height: 1.15; margin: 0 0 .5em; font-weight: 600; }
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2rem); }
h3 { font-size: 1.3rem; }
h4 { font-family: var(--sans); font-size: .95rem; margin-bottom: .25em; }
p { margin: 0 0 1em; }
a { color: inherit; text-underline-offset: 4px; }
a:hover { text-decoration: none; }
:focus-visible { outline: 3px solid var(--tally); outline-offset: 2px; }
ul, ol { padding-left: 1.2rem; }
.plain { list-style: none; padding: 0; margin: 0; }
.spaced li { margin-bottom: .6rem; }
.muted { color: var(--mute); }
.small { font-size: .875rem; }
.op { opacity: .78; }
.accent { color: var(--tally); }
.screen-reader-text, .sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 0; background: #fff; padding: .6rem 1rem; z-index: 100; }
.skip-link:focus { left: .75rem; top: .75rem; }
.hp { position: absolute; left: -9999px; }

.container { width: 100%; max-width: 72rem; margin: 0 auto; padding: 0 1.25rem; }
@media (min-width: 640px) { .container { padding: 0 2rem; } }
.section { padding-top: 3rem; padding-bottom: 3rem; }
.container.section { padding-top: 3rem; padding-bottom: 3rem; }
.section-ink { background: var(--ink); color: #fff; }
.section-paper { background: var(--paper); }
.pad-top { padding-top: 1.5rem; } .pad-bottom { padding-bottom: 3rem; }
.block { margin-top: 3rem; }
.narrow { max-width: 48rem; }
.prose-width { max-width: 42rem; }
.lead { font-size: 1.15rem; line-height: 1.7; opacity: .85; max-width: 38rem; }
.lead-dark { font-size: 1.1rem; line-height: 1.7; }
.head-row { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: .5rem; margin-bottom: 1.5rem; }
.more { color: var(--tally); font-weight: 600; font-size: .9rem; }
.underline { text-decoration: underline; text-underline-offset: 4px; font-weight: 600; font-size: .9rem; }
.stack > * + * { margin-top: 2.5rem; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; padding: .75rem 1.25rem; font: 600 .9rem/1.2 var(--sans); border-radius: 2px; border: 1px solid transparent; text-decoration: none; cursor: pointer; transition: background .15s, color .15s; }
.btn-primary { background: var(--tally); color: #fff; }
.btn-primary:hover { background: var(--tally-dark); }
.btn-ghost { border-color: currentColor; background: transparent; }
.btn-ghost:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
.btn-ghost-light { border-color: #fff; color: #fff; }
.btn-ghost-light:hover { background: #fff; color: var(--ink); }
.btn-link { padding: 0; color: var(--tally); text-decoration: underline; text-underline-offset: 4px; }
.btn-link:hover { color: var(--tally-dark); }
.btn-block { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: .75rem 1rem; align-items: center; margin: 2rem 0 1.5rem; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.96); border-bottom: 1px solid var(--line); backdrop-filter: blur(6px); }
.admin-bar .site-header { top: 32px; }
.header-row { display: flex; align-items: center; gap: 1rem; min-height: 4rem; }
.brand { display: flex; align-items: center; gap: .5rem; font: 600 1.25rem var(--serif); text-decoration: none; margin-right: auto; }
.dot { width: .75rem; height: .75rem; border-radius: 50%; background: var(--tally); display: inline-block; }
.header-panel { display: none; }
.menu-toggle { border: 1px solid var(--line); background: #fff; padding: .5rem; cursor: pointer; line-height: 0; }
.find-btn { display: none; }
.main-nav .menu { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .25rem; }
.main-nav a { display: block; padding: .5rem 0; font-weight: 500; text-decoration: none; }
.main-nav a:hover { text-decoration: underline; text-underline-offset: 4px; }
.site-header.is-open .header-panel { display: block; position: absolute; top: 100%; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line); padding: 1rem 1.25rem 1.25rem; }
.site-header.is-open .header-panel .search-form { margin-bottom: 1rem; }
@media (min-width: 640px) { .find-btn { display: inline-flex; } }
@media (min-width: 960px) {
	.menu-toggle { display: none; }
	.header-panel, .site-header.is-open .header-panel { display: block; position: static; padding: 0; border: 0; background: none; margin-right: 1rem; }
	.header-panel .search-form { display: none; }
	.main-nav .menu { flex-direction: row; gap: 1.5rem; }
	.main-nav a { font-size: .9rem; padding: 0; }
	.brand { margin-right: 1.5rem; }
	.header-row { gap: 0; } .header-panel { margin-right: auto; }
}

/* Search form */
.search-form { display: flex; max-width: 32rem; }
.search-form input[type=search] { flex: 1; min-width: 0; border: 1px solid var(--line); padding: .6rem .75rem; font: inherit; font-size: .9rem; background: #fff; color: var(--ink); }
.search-form button { background: var(--ink); color: #fff; border: 0; padding: .6rem 1rem; font: 600 .9rem var(--sans); cursor: pointer; }
.search-form button:hover { background: var(--ink2); }

/* Hero */
.hero-grid { display: grid; gap: 3rem; padding-top: 4rem; padding-bottom: 4rem; align-items: center; }
@media (min-width: 800px) { .hero-grid { grid-template-columns: 1.1fr .9fr; padding-top: 6rem; padding-bottom: 6rem; } }
.hero h1 { margin-bottom: .4em; }
.hero-visual { display: block; width: 100%; }
@keyframes tally { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
.tally-pulse { animation: tally 2.4s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) { .tally-pulse { animation: none; } }

/* Grids and cards */
.grid { display: grid; gap: 1rem; }
.gap-lg { gap: 1.5rem; }
@media (min-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-4 { grid-template-columns: repeat(4, 1fr); } }
.two-col { display: grid; gap: 1.5rem; }
@media (min-width: 640px) { .two-col { grid-template-columns: 1fr 1fr; gap: 2.5rem; } }
.center { align-items: center; }
.card { display: flex; flex-direction: column; border: 1px solid var(--line); background: #fff; }
.card-body { padding: 1.25rem; display: flex; flex-direction: column; flex: 1; }
a.card { text-decoration: none; padding: 1.25rem; transition: border-color .15s; }
a.card:hover { border-color: var(--ink); }
.cat-card h3 { margin-bottom: .3rem; } .cat-card p { flex: 1; font-size: .9rem; }
.card h3 a { text-decoration: none; } .card h3 a:hover { text-decoration: underline; }
.badges { display: flex; flex-wrap: wrap; gap: .4rem; margin: 0 0 .6rem; font-size: .75rem; }
.badge { display: inline-block; padding: .2rem .5rem; font-weight: 600; font-size: .75rem; }
.badge-ink { background: var(--ink); color: #fff; }
.badge-warn { border: 1px solid var(--tally); color: var(--tally); }
.product-img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: contain; background: var(--paper); }
.product-img.placeholder { display: flex; align-items: center; justify-content: center; color: var(--mute); }
.product-img.placeholder svg { width: 50%; height: 50%; }
.specs-mini { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem 1rem; border-top: 1px solid var(--line); padding-top: 1rem; margin: 1rem 0; font-size: .875rem; }
.specs-mini dt { color: var(--mute); } .specs-mini dd { margin: 0; font-weight: 600; }
.tbv { font-style: italic; color: var(--mute); font-weight: 400 !important; }
.price-note { margin: auto 0 .6rem; padding-top: 1rem; font-size: .875rem; }
.product-card h4 { margin-top: 0; }
.product-card ul { padding-left: 1rem; font-size: .875rem; margin: 0; }
.bf-item { border-top: 2px solid var(--ink); padding-top: .75rem; }
.bf-item h3 a { text-decoration: none; } .bf-item h3 a:hover { text-decoration: underline; }
.build-card { display: block; border: 1px solid rgba(255,255,255,.25); padding: 1.25rem; text-decoration: none; }
.build-card:hover { border-color: #fff; }
.article-card { border-top: 2px solid var(--ink); padding-top: 1rem; }
.article-card h3 a { text-decoration: none; } .article-card h3 a:hover { text-decoration: underline; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1.25rem 0 0; }
.chips a { border: 1px solid var(--line); padding: .25rem .75rem; font-size: .875rem; text-decoration: none; }
.chips a:hover { border-color: var(--ink); }

/* Breadcrumbs, disclosure, notices */
.breadcrumbs { font-size: .875rem; color: var(--mute); margin-bottom: 1.5rem; }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: .25rem .5rem; list-style: none; margin: 0; padding: 0; }
.breadcrumbs a { text-decoration: none; } .breadcrumbs a:hover { text-decoration: underline; }
.breadcrumbs [aria-current] { color: var(--ink); }
.disclosure { border-left: 4px solid var(--tally); background: var(--paper); padding: .75rem 1rem; font-size: .875rem; line-height: 1.6; }
.notice-box { border-left: 4px solid var(--tally); background: #fff; color: var(--ink); padding: .6rem .8rem; font-size: .875rem; margin-top: .75rem; }

/* Definitions / lists */
.defs { margin: 0; }
.defs > div { border-top: 1px solid var(--line); padding: .75rem 0; }
.defs dt { font-weight: 600; } .defs dd { margin: .25rem 0 0; }
dl.grid.defs { gap: 0 2rem; }

/* Comparison table */
.compare-wrap { border: 1px solid var(--line); }
.compare { width: 100%; border-collapse: collapse; text-align: left; font-size: .9rem; }
.compare caption { text-align: left; padding: .75rem 1rem; font-weight: 600; background: var(--paper); border-bottom: 1px solid var(--line); }
.compare thead { display: none; }
.compare tbody, .compare tr, .compare th, .compare td { display: block; }
.compare tr { border-top: 1px solid var(--line); padding: .5rem 0; }
.compare tr:first-child { border-top: 0; }
.compare th, .compare td { padding: .4rem 1rem; }
.compare th[data-label]::before, .compare td[data-label]::before { content: attr(data-label); display: block; font-size: .75rem; font-weight: 600; color: var(--mute); }
.compare tbody th a { font-weight: 600; text-decoration: none; } .compare tbody th a:hover { text-decoration: underline; }
@media (min-width: 768px) {
	.compare thead { display: table-header-group; background: var(--paper); }
	.compare tbody { display: table-row-group; } .compare tr { display: table-row; padding: 0; }
	.compare th, .compare td { display: table-cell; padding: .75rem 1rem; vertical-align: top; }
	.compare th[data-label]::before, .compare td[data-label]::before { display: none; }
	.compare tbody tr { border-top: 1px solid var(--line); }
}
.spec-table { width: 100%; border: 1px solid var(--line); border-collapse: collapse; font-size: .9rem; text-align: left; }
.spec-table th { width: 34%; background: var(--paper); padding: .6rem 1rem; font-weight: 600; }
.spec-table td { padding: .6rem 1rem; }
.spec-table tr + tr { border-top: 1px solid var(--line); }

/* FAQ */
.faq { margin-top: 2rem; }
.faq details { border-bottom: 1px solid var(--line); padding: 1rem 0; }
.faq details:first-of-type { border-top: 1px solid var(--line); }
.faq summary { cursor: pointer; font-weight: 600; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "›"; color: var(--tally); display: inline-block; width: 1.1rem; transition: transform .15s; }
.faq details[open] summary::before { transform: rotate(90deg); }
.faq p { margin: .5rem 0 0 1.1rem; color: var(--mute); max-width: 42rem; }

/* Product / guide pages */
.product-top { display: grid; gap: 2rem; margin-top: 1rem; }
@media (min-width: 768px) { .product-top { grid-template-columns: 360px 1fr; gap: 2.5rem; } }
.product-media .product-img { border: 1px solid var(--line); }
.quick-box { border: 1px solid var(--line); background: var(--paper); padding: 1.5rem; margin-top: 2rem; }
.quick-box li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: .5rem; border-top: 1px solid var(--line); padding: .75rem 0; }
.quick-box li:first-child { border-top: 0; padding-top: 0; }
.pick { display: grid; gap: 1.5rem; border-top: 1px solid var(--line); padding-top: 2rem; margin-top: 2rem; }
@media (min-width: 768px) { .pick { grid-template-columns: 240px 1fr; } }
.closing { border-top: 2px solid var(--ink); padding-top: 1.5rem; }
.alt-list { list-style: none; padding: 0; margin: 0; }
.alt-list li { padding: .75rem 0; border-top: 1px solid var(--line); }
.build-list li { display: grid; gap: .75rem; padding: 1.25rem 0; border-top: 1px solid var(--line); align-items: center; }
.build-list li:last-child { border-bottom: 1px solid var(--line); }
@media (min-width: 640px) { .build-list li { grid-template-columns: 1fr auto; } }
.prose p, .prose li { max-width: 68ch; line-height: 1.75; }
.prose h2 { margin-top: 2.25rem; } .prose h3 { margin-top: 1.5rem; }
.results li { border-top: 1px solid var(--line); padding: 1rem 0; max-width: 48rem; }
.results h3 { margin: .1rem 0; } .results h3 a { text-decoration: none; } .results h3 a:hover { text-decoration: underline; }

/* Newsletter, contact */
.newsletter { padding: 3.5rem 0; margin-top: 3rem; }
.newsletter.section-paper { border: 1px solid var(--line); }
.newsletter h2 { font-size: clamp(1.8rem, 4vw, 2.5rem); }
.inline-form { display: flex; flex-direction: column; gap: .75rem; margin-top: .5rem; }
@media (min-width: 640px) { .inline-form { flex-direction: row; } }
.inline-form input, .contact-form input, .contact-form textarea { width: 100%; border: 1px solid var(--line); background: #fff; color: var(--ink); padding: .7rem .8rem; font: inherit; }
.inline-form input { flex: 1; min-width: 0; }
.contact-form { max-width: 36rem; }
.contact-form label { display: block; margin-bottom: .25rem; }

/* Footer */
.site-footer { background: var(--ink); color: rgba(255,255,255,.8); margin-top: 0; }
.footer-grid { display: grid; gap: 2.5rem; padding-top: 3.5rem; padding-bottom: 3.5rem; font-size: .9rem; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: repeat(4, 1fr); } }
.site-footer h2 { font: 600 1rem var(--sans); color: #fff; margin: 0 0 .75rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; } .site-footer li { margin-bottom: .5rem; }
.site-footer a { text-decoration: none; } .site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-brand { font: 600 1.25rem var(--serif); color: #fff; margin-bottom: .75rem; }
.footer-legal { border-top: 1px solid rgba(255,255,255,.12); font-size: .75rem; line-height: 1.6; color: rgba(255,255,255,.6); padding: 1.5rem 0; }

/* Pagination */
.pagination { margin-top: 2.5rem; } .pagination .nav-links { display: flex; flex-wrap: wrap; gap: .5rem; }
.pagination a, .pagination span { border: 1px solid var(--line); padding: .35rem .8rem; text-decoration: none; font-size: .9rem; }
.pagination .current { background: var(--ink); color: #fff; border-color: var(--ink); }

/* WordPress core alignment */
.alignleft { float: left; margin: 0 1rem 1rem 0; } .alignright { float: right; margin: 0 0 1rem 1rem; } .aligncenter { display: block; margin: 0 auto 1rem; }
.wp-caption-text { font-size: .85rem; color: var(--mute); }
