/*
Theme Name: Auto Presswire
Theme URI: https://autopresswire.com
Author: Triforce Media
Description: Bespoke automotive news + press-release aggregation theme for Auto Presswire — a hub for publicly traded auto-industry companies. Light newsroom design system (2026-07-15 redesign).
Version: 0.9.0
License: GPL-2.0
*/

:root {
  /* Auto Presswire design system (mockup-driven, 2026-07-15) */
  --bg: #FFFFFF;            /* primary content surface */
  --bg-2: #F6F8FA;          /* Cloud — alternating section background */
  --surface: #FFFFFF;       /* cards */
  --surface-2: #F6F8FA;     /* secondary surfaces */
  --line: #E8EDF1;          /* Alloy — borders/dividers */
  --ink: #091018;           /* Carbon Ink — headings/strong text */
  --text: #1B2733;          /* body text (near-carbon) */
  --muted: #66727F;         /* Steel — metadata/supporting copy */
  --brand: #10263D;         /* Press Navy — hero/dark section bands */
  --brand-2: #0C1A2C;       /* deeper navy */
  --carbon: #091018;        /* footer/darkest */
  --accent: #E8353A;        /* Signal Red — CTAs/alerts/active */
  --blue: #2E77F7;          /* Electric Blue — links/accents/icons */
  --link: #2E77F7;
  --up: #16a34a;            /* stock up (green) */
  --down: #E8353A;          /* stock down (red — on-brand) */
  --gold: #b8860b;
  --radius: 14px;
  --shadow: 0 1px 3px rgba(16, 38, 61, .06), 0 8px 24px rgba(16, 38, 61, .06);
  --shadow-hover: 0 2px 6px rgba(16, 38, 61, .08), 0 14px 34px rgba(16, 38, 61, .10);
  --f-display: "Roboto Condensed", "Arial Narrow", Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-body: Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-family: var(--f-body);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  font-variant-numeric: tabular-nums;
}
html { scroll-behavior: smooth; }
::selection { background: var(--accent); color: #fff; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; border-radius: 4px; }
a { color: var(--link); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--ink); text-decoration: underline; }
h1, h2, h3, h4 { font-family: var(--f-display); line-height: 1.12; margin: 0 0 .4em; letter-spacing: -.01em; color: var(--ink); font-weight: 700; }
h1 { font-size: clamp(30px, 4.4vw, 48px); }
h2 { font-size: clamp(24px, 3vw, 34px); }
h3 { font-size: 20px; }
p { margin: 0 0 1em; }
img { max-width: 100%; }

.wrap { max-width: 1220px; margin: 0 auto; padding: 0 32px; }

/* ---------- Ticker tape (kept for reference; not rendered in redesigned header) ---------- */
.tape { background: var(--carbon); border-bottom: 1px solid var(--line); overflow: hidden; }
.tape-track { display: inline-flex; white-space: nowrap; padding: 8px 0; will-change: transform; animation: tkscroll 70s linear infinite; }
.tape:hover .tape-track { animation-play-state: paused; }
.tk-item { display: inline-flex; align-items: center; gap: 6px; padding: 0 18px; border-right: 1px solid #1f2a36; font-size: 13px; }
.tk-item a { color: #cfd8e0; display: inline-flex; gap: 6px; }
.tk-item a:hover { text-decoration: none; opacity: .9; }
.tk-item b { color: #fff; font-weight: 700; }
.tk-item .tp { color: #8fa0b3; }
.tk-item .tpp { font-weight: 700; }
.tk-item.up .tpp { color: var(--up); }
.tk-item.down .tpp { color: var(--down); }
.tk-item.flat .tpp { color: var(--muted); }
@keyframes tkscroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .tape-track { animation: none; flex-wrap: wrap; } }

/* ---------- Utility bar (red strip above header) ---------- */
.utility-bar { background: var(--accent); color: #fff; font-size: 12.5px; }
.utility-bar .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 7px; padding-bottom: 7px; }
.utility-bar a { color: #fff; opacity: .95; }
.utility-bar a:hover { opacity: 1; text-decoration: underline; color: #fff; }
.utility-bar .ub-links { display: flex; gap: 18px; flex-wrap: wrap; }
.utility-bar .ub-note { opacity: .9; }
@media (max-width: 720px) { .utility-bar .ub-note { display: none; } .utility-bar .ub-links { gap: 14px; } }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.96); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 28px; padding-top: 14px; padding-bottom: 14px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 20px; letter-spacing: -.01em; color: var(--ink); font-family: var(--f-display); }
.brand img { height: 40px; width: auto; display: block; }
.brand small { display: block; font-size: 10px; font-weight: 600; color: var(--muted); letter-spacing: .12em; text-transform: uppercase; }
nav.primary { margin-left: auto; }
nav.primary ul { list-style: none; display: flex; gap: 4px; margin: 0; padding: 0; }
nav.primary a { display: block; padding: 8px 12px; border-radius: 8px; color: var(--ink); font-weight: 600; font-size: 13.5px; letter-spacing: .02em; }
nav.primary a:hover { background: var(--bg-2); color: var(--accent); text-decoration: none; }
.header-search { display: flex; align-items: stretch; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: var(--bg); }
.header-search .hs-input { border: 0; background: transparent; padding: 8px 10px; font: inherit; font-size: 13.5px; width: 150px; outline: none; color: var(--ink); }
.header-search .hs-btn { border: 0; background: var(--bg-2); padding: 8px 11px; cursor: pointer; color: var(--muted); font-size: 13px; line-height: 1; }
.header-search .hs-btn:hover { color: var(--accent); }
@media (max-width: 1080px) { .header-search { display: none; } }
.header-cta { display: inline-block; padding: 9px 16px; border-radius: 7px; font-weight: 700; font-size: 13.5px; background: var(--accent); color: #fff; }
.header-cta:hover { background: #d4252b; transform: translateY(-1px); text-decoration: none; color: #fff; }
.nav-toggle { display: none; background: none; border: 0; color: var(--ink); font-size: 26px; line-height: 1; cursor: pointer; padding: 4px 10px; margin-left: auto; border-radius: 8px; }
.nav-toggle:hover { background: var(--bg-2); }

/* ---------- Buttons / chips ---------- */
.btn { display: inline-block; padding: 13px 24px; border-radius: 7px; font-weight: 700; font-size: 15px; background: var(--accent); color: #fff; transition: transform .12s, background .15s; border: 0; cursor: pointer; }
.btn:hover { transform: translateY(-1px); text-decoration: none; background: #d4252b; color: #fff; }
.btn.ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn.ghost:hover { border-color: var(--accent); color: var(--accent); background: var(--bg); }
.btn.navy { background: var(--brand); color: #fff; }
.btn.navy:hover { background: var(--brand-2); color: #fff; }
.chip { display: inline-block; padding: 4px 11px; border-radius: 999px; font-size: 11.5px; font-weight: 700; background: var(--bg-2); color: var(--muted); letter-spacing: .03em; }
.chip.red { background: rgba(232,53,58,.10); color: var(--accent); }
.chip.blue { background: rgba(46,119,247,.10); color: var(--blue); }
.chip.navy { background: rgba(16,38,61,.08); color: var(--brand); }
.badge { display: inline-block; background: var(--brand); color: #fff; border-radius: 6px; padding: 2px 8px; font-weight: 800; font-size: 12px; letter-spacing: .03em; }
.up { color: var(--up); } .down { color: var(--down); }

/* ---------- Section ---------- */
.section { padding: 64px 0; }
.section.tight { padding: 40px 0; }
.section.alt { background: var(--bg-2); }
.section.navy { background: var(--brand); color: #cdd8e3; }
.section.navy h2, .section.navy h3 { color: #fff; }
.section h2 { font-size: clamp(22px, 2.6vw, 30px); display: flex; align-items: center; gap: 12px; }
.section h2 .more { margin-left: auto; font-size: 13px; font-weight: 600; color: var(--muted); font-family: var(--f-body); }
.section-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 22px; border-bottom: 1px solid var(--line); padding-bottom: 12px; }
.section-head .sub { color: var(--muted); font-size: 14px; font-weight: 500; }
.eyebrow { display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin-bottom: 10px; }

/* ---------- Card / grid ---------- */
.grid { display: grid; gap: 18px; }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 980px) { .grid.cols-4, .grid.cols-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid.cols-4, .grid.cols-3, .grid.cols-2 { grid-template-columns: 1fr; } }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); transition: transform .18s cubic-bezier(.2,.7,.2,1), box-shadow .18s ease, border-color .18s ease; }
.card:hover { transform: translateY(-2px); border-color: #d6dee6; box-shadow: var(--shadow-hover); }
.card.flush { box-shadow: none; }

/* company mini card */
.stock-card { display: block; color: var(--text); }
.stock-card:hover { text-decoration: none; }
.stock-card .row1 { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.stock-card .name { font-weight: 700; font-size: 15px; color: var(--ink); }
.stock-card .price { font-size: 22px; font-weight: 800; margin-top: 8px; color: var(--ink); font-family: var(--f-display); }
.stock-card .meta { color: var(--muted); font-size: 12.5px; }

/* movers */
.movers-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 700px) { .movers-grid { grid-template-columns: 1fr; } }
.mover-list { list-style: none; margin: 0; padding: 0; }
.mover-list li { padding: 0; }
.mover-list a { display: flex; align-items: center; gap: 10px; padding: 9px 0; color: var(--text); flex: 1 1 auto; border-bottom: 1px solid var(--line); }
.mover-list li:last-child a { border-bottom: 0; }
.mover-list a:hover { text-decoration: none; background: var(--bg-2); }
.mover-list .tk { font-weight: 800; width: 64px; color: var(--ink); }
.mover-list .nm { color: var(--muted); font-size: 13px; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mover-list .pc { font-weight: 700; width: 82px; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }

/* vertical tiles */
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@media (max-width: 980px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .tiles { grid-template-columns: 1fr 1fr; } }
.tile { display: block; padding: 22px 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); color: var(--text); text-align: left; transition: transform .18s cubic-bezier(.2,.7,.2,1), border-color .18s ease, box-shadow .18s ease; }
.tile:hover { text-decoration: none; border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow-hover); }
.tile .ic { font-size: 22px; color: var(--blue); }
.tile .nm { font-weight: 700; margin-top: 10px; color: var(--ink); font-size: 15.5px; }
.tile .ct { color: var(--muted); font-size: 12.5px; }

/* news list */
.news-card { color: var(--text); display: flex; flex-direction: column; gap: 8px; }
.news-card:hover { text-decoration: none; }
.news-card .when { color: var(--muted); font-size: 12px; }
.news-card h3 { font-size: 16.5px; margin: 0; color: var(--ink); }
.news-card:hover h3 { color: var(--accent); }
.news-card .tag { align-self: flex-start; }

/* ---------- Static / resource page prose ---------- */
.page-prose { padding: 36px 0 60px; }
.page-prose h1 { font-size: clamp(26px, 4vw, 38px); }
.page-prose .lead { color: var(--muted); font-size: 18px; max-width: 740px; }
.page-prose .body { max-width: 800px; font-size: 16.5px; line-height: 1.75; }
.page-prose .body h2 { font-size: 22px; margin-top: 1.5em; }
.page-prose .body p { margin: 0 0 1em; }
.page-prose .body a { color: var(--link); }
.page-prose .body ul { margin: 0 0 1em 1.2em; }
.page-prose .body li { margin: 0 0 .5em; }
.page-prose .glossary { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 28px; }
@media (max-width: 700px) { .page-prose .glossary { grid-template-columns: 1fr; } }
.page-prose .glossary dt { font-weight: 800; color: var(--ink); margin-top: 10px; }
.page-prose .glossary dd { margin: 0 0 4px; color: var(--muted); font-size: 14px; }

/* ---------- Company page ---------- */
.company { padding: 30px 0 56px; }
.company .head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.company .head h1 { font-size: 32px; margin: 0; }
.company .sub { color: var(--muted); margin: 4px 0 18px; font-size: 14px; }
.chart-box { background: var(--surface); border-radius: var(--radius); padding: 16px; border: 1px solid var(--line); }
.company-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 18px; }
@media (max-width: 820px) { .company-grid { grid-template-columns: 1fr; } }
.dl { display: grid; grid-template-columns: auto 1fr; gap: 7px 16px; font-size: 14px; }
.dl dt { color: var(--muted); }
.dl dd { margin: 0; color: var(--ink); font-weight: 500; }
.list { list-style: none; margin: 0; padding: 0; }
.list li { padding: 9px 0; border-bottom: 1px solid var(--line); }
.list li:last-child { border-bottom: 0; }

/* ---------- Article ---------- */
.article { padding: 30px 0 64px; }
.article .crumb { color: var(--muted); font-size: 13px; margin-bottom: 10px; }
.article h1 { font-size: clamp(26px, 4vw, 40px); }
.article .meta { color: var(--muted); font-size: 13px; margin-bottom: 22px; }
.article .body { font-size: 17px; line-height: 1.78; max-width: 770px; color: #23303d; }
.article .body h2 { font-size: 23px; margin-top: 1.5em; }
.article .body p { margin: 0 0 1.1em; }
.article .body a { color: var(--link); }
.article .src { font-size: 13px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 14px; margin-top: 26px; max-width: 770px; }

/* ---------- Directory ---------- */
.dir-group { margin-bottom: 30px; }
.dir-group h2 { font-size: 19px; text-transform: capitalize; border-bottom: 2px solid var(--line); padding-bottom: 8px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--carbon); color: #9aa7b4; margin-top: 40px; padding: 44px 0 0; font-size: 14px; }
.site-footer a { color: #c4cfda; display: block; padding: 4px 0; font-size: 13.5px; transition: color .15s ease; }
.site-footer a:hover { color: #fff; text-decoration: none; }
.site-footer .fcols { display: grid; grid-template-columns: 1.8fr 1fr 1fr 1fr; gap: 32px; padding-bottom: 30px; }
@media (max-width: 800px) { .site-footer .fcols { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .site-footer .fcols { grid-template-columns: 1fr; } }
.site-footer .fbrand img { height: 40px; width: auto; margin-bottom: 14px; filter: brightness(0) invert(1); }
.site-footer h4 { color: #fff; font-size: 12.5px; text-transform: uppercase; letter-spacing: .12em; margin: 0 0 10px; font-family: var(--f-body); }
.site-footer .fdisc { background: rgba(255,255,255,.04); border: 1px solid #1c2733; border-radius: 10px; padding: 12px 14px; font-size: 12px; margin-top: 16px; color: #8b97a4; }
.site-footer .fsocial { display: flex; gap: 12px; margin-top: 14px; }
.site-footer .fsocial a { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 8px; background: rgba(255,255,255,.06); color: #c4cfda; font-size: 13px; font-weight: 700; padding: 0; }
.site-footer .fsocial a:hover { background: var(--accent); color: #fff; }
.site-footer .fbottom { border-top: 1px solid #1c2733; padding: 16px 0; font-size: 12px; display: flex; gap: 10px; flex-wrap: wrap; align-items: center; justify-content: space-between; color: #6f7d8b; }
.site-footer .fbottom a { display: inline; color: var(--accent); padding: 0; font-weight: 600; }

.empty { color: var(--muted); font-style: italic; padding: 14px 0; }

/* alpha-stock widget readability on light bg */
.alpha-stock-card, .asw-card, .asw-mini, .asw-micro { color: #111; }

/* ---------- Market leaders ranking ---------- */
.leader-table { width: 100%; border-collapse: collapse; }
.leader-table th, .leader-table td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); font-size: 14px; }
.leader-table th { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .05em; }
.leader-table .rk { color: var(--muted); width: 30px; }
.leader-table td.cap { text-align: right; font-weight: 700; white-space: nowrap; color: var(--ink); }
.leader-table a { color: var(--ink); font-weight: 600; }
.leader-table a:hover { color: var(--accent); }
.leader-table tr:hover td { background: var(--bg-2); }

/* ---------- Byline on news cards ---------- */
.news-card .by { color: var(--muted); font-size: 12px; }
.news-card .by b { color: var(--ink); font-weight: 600; }

/* ---------- Featured lead (home) ---------- */
.lead-wrap { display: grid; grid-template-columns: 2fr 1fr; gap: 18px; }
@media (max-width: 900px) { .lead-wrap { grid-template-columns: 1fr; } }
.lead-main { background: var(--brand); color: #cdd8e3; border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; justify-content: flex-end; min-height: 320px; background-size: cover; background-position: center; position: relative; overflow: hidden; }
.lead-main::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(16,38,61,.25) 0%, rgba(16,38,61,.92) 100%); }
.lead-main > * { position: relative; z-index: 1; }
.lead-main h2 { color: #fff; font-size: 26px; margin: 10px 0 6px; }
.lead-main:hover h2 { color: #fff; }
.lead-side { display: grid; grid-template-rows: 1fr 1fr; gap: 18px; }
.lead-side .card { padding: 18px; }

/* ---------- Press release row ---------- */
.pr-row { display: flex; gap: 16px; align-items: flex-start; padding: 16px 0; border-bottom: 1px solid rgba(255,255,255,.10); }
.section.navy .pr-row:last-child { border-bottom: 0; }
.pr-row .pr-time { color: #8fa0b3; font-size: 12px; width: 70px; flex: 0 0 auto; font-variant-numeric: tabular-nums; }
.pr-row .pr-title { color: #fff; font-weight: 600; font-size: 15px; line-height: 1.4; }
.pr-row a:hover .pr-title { color: #fff; text-decoration: underline; }
.pr-row .pr-more { color: var(--blue); font-size: 12.5px; margin-top: 4px; display: inline-block; }

/* ---------- Stats band ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
@media (max-width: 760px) { .stats { grid-template-columns: repeat(2, 1fr); } }
.stat .n { font-family: var(--f-display); font-size: 44px; font-weight: 700; color: var(--blue); line-height: 1; }
.stat .l { color: var(--muted); font-size: 13.5px; margin-top: 6px; }

/* ---------- Audience cards ---------- */
.audience { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
@media (max-width: 760px) { .audience { grid-template-columns: 1fr; } }
.audience .card .idx { font-family: var(--f-display); font-size: 22px; font-weight: 700; color: var(--blue); }
.audience .card h3 { margin: 4px 0 6px; font-size: 17px; }
.audience .card p { margin: 0; color: var(--muted); font-size: 14px; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--accent); color: #fff; padding: 48px 0; text-align: center; }
.cta-band h2 { color: #fff; font-size: clamp(24px, 3.2vw, 36px); margin-bottom: 18px; }
.cta-band .btn { background: var(--ink); color: #fff; }
.cta-band .btn:hover { background: #000; color: #fff; }

/* ============================================
   MOBILE RESPONSIVE
   ============================================ */
@media (max-width: 900px) {
	.wrap { padding: 0 20px; }
	.site-header .wrap { gap: 14px; padding-top: 11px; padding-bottom: 11px; }
	.brand img { height: 34px; }
	.header-search { display: none; }
	.nav-toggle { display: block; }
	nav.primary { position: absolute; top: 100%; left: 0; right: 0; margin: 0; background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-hover); padding: 8px 20px 16px; max-height: 86vh; overflow-y: auto; display: none; }
	nav.primary.open { display: block; }
	nav.primary ul { flex-direction: column; flex-wrap: nowrap; gap: 0; }
	nav.primary li { width: 100%; }
	nav.primary a { padding: 13px 6px; white-space: normal; border-bottom: 1px solid var(--line); border-radius: 0; }
	nav.primary li:last-child a { border-bottom: 0; }
	.header-cta { display: none; }
	.section { padding: 44px 0; }
	.section h2 { font-size: 22px; }
	.card { padding: 16px; }
	.stock-card .price { font-size: 19px; }
	.company .head h1 { font-size: 25px; }
	.article h1 { font-size: 25px; }
	.article .body { font-size: 16px; }
	.tk-item { padding: 0 12px; font-size: 12px; }
}

/* ---------- Company chart: full width, financials below ---------- */
.chart-box .asw-chart__body { grid-template-columns: 1fr !important; }
.chart-box .asw-chart__canvas-wrap { border-right: 0 !important; border-bottom: 1px solid var(--line); }
.chart-box .asw-chart__financials { max-height: none !important; overflow: visible !important; padding: 16px 6px 4px; }

/* ---------- External links (company page) ---------- */
.extlinks { display: flex; flex-wrap: wrap; gap: 8px; }
.extlink { display: inline-block; padding: 8px 13px; border-radius: 8px; background: var(--bg-2); border: 1px solid var(--line); color: var(--ink); font-size: 13px; font-weight: 600; transition: transform .15s ease, border-color .15s ease; }
.extlink:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; transform: translateY(-1px); }

/* ---------- Section heading bar accent ---------- */
.section-head { border-bottom-color: var(--line); }
.section h2::before {
  content: ""; display: inline-block; width: 4px; height: .92em;
  background: var(--accent); border-radius: 3px; margin-right: 4px;
}
