/*
Theme Name: Trailers For All Dispatch
Theme URI: https://trailersforall.com/
Author: ChatGPT
Author URI: https://openai.com/
Description: A media-forward WordPress theme for trailer dealers, trailer buyers, dealer spotlights, industry news, and practical trailer buying guides. Built with SEO structure, schema support, custom post types, and a bold dispatch-board layout.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 7.4
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: trailers-for-all-dispatch
Tags: blog, news, custom-logo, custom-menu, featured-images, wide-blocks, block-styles
*/

:root {
  --tfa-ink: #111827;
  --tfa-road: #1f2937;
  --tfa-steel: #334155;
  --tfa-blue: #2563eb;
  --tfa-orange: #f97316;
  --tfa-yellow: #facc15;
  --tfa-sand: #f8f4ea;
  --tfa-card: #ffffff;
  --tfa-muted: #6b7280;
  --tfa-line: rgba(17, 24, 39, .12);
  --tfa-radius: 22px;
  --tfa-shadow: 0 24px 70px rgba(17, 24, 39, .12);
  --tfa-max: 1180px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--tfa-sand);
  color: var(--tfa-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--tfa-orange); }

img { max-width: 100%; height: auto; }

.tfa-container {
  width: min(var(--tfa-max), calc(100% - 40px));
  margin-inline: auto;
}

.tfa-skip-link {
  position: absolute;
  left: -999px;
  top: 8px;
  z-index: 1000;
  background: var(--tfa-orange);
  color: #111827;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 800;
}
.tfa-skip-link:focus { left: 8px; }

.tfa-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid rgba(255,255,255,.12);
  background: rgba(17, 24, 39, .94);
  backdrop-filter: blur(16px);
  color: #fff;
}

.tfa-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  min-height: 72px;
}

.tfa-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 220px;
}

.tfa-logo-mark {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--tfa-orange), var(--tfa-yellow));
  color: var(--tfa-ink);
  display: grid;
  place-items: center;
  font-weight: 950;
  letter-spacing: -.08em;
  box-shadow: 0 10px 28px rgba(249,115,22,.28);
}

.tfa-site-title {
  display: block;
  font-weight: 900;
  letter-spacing: -.035em;
  font-size: 1.05rem;
  line-height: 1.1;
}

.tfa-site-tagline {
  display: block;
  color: rgba(255,255,255,.72);
  font-size: .78rem;
  margin-top: 2px;
}

.tfa-nav { display: flex; align-items: center; gap: 18px; }
.tfa-nav ul { list-style: none; display: flex; gap: 18px; padding: 0; margin: 0; align-items: center; }
.tfa-nav a { color: rgba(255,255,255,.86); font-weight: 750; font-size: .92rem; }
.tfa-nav a:hover { color: var(--tfa-yellow); }

.tfa-menu-toggle {
  display: none;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.08);
  color: #fff;
  border-radius: 999px;
  padding: 10px 14px;
  font-weight: 850;
}

.tfa-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  background: var(--tfa-orange);
  color: #111827;
  padding: 12px 18px;
  font-weight: 900;
  border: 2px solid rgba(0,0,0,.08);
  box-shadow: 0 12px 30px rgba(249,115,22,.26);
}
.tfa-cta:hover { color: #111827; transform: translateY(-1px); }

.tfa-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 75% 25%, rgba(249,115,22,.28), transparent 26%),
    linear-gradient(135deg, #0f172a 0%, #1f2937 48%, #111827 100%);
}
.tfa-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(90deg, rgba(250,204,21,.08) 1px, transparent 1px), linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 78px 78px;
  mask-image: linear-gradient(to bottom, #000, transparent 86%);
}
.tfa-hero-inner {
  position: relative;
  padding: clamp(62px, 9vw, 118px) 0 54px;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, .9fr);
  gap: 36px;
  align-items: center;
}
.tfa-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 999px;
  color: rgba(255,255,255,.82);
  background: rgba(255,255,255,.06);
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: .76rem;
}
.tfa-kicker::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--tfa-orange);
  box-shadow: 0 0 0 6px rgba(249,115,22,.16);
}
.tfa-hero h1 {
  max-width: 870px;
  margin: 18px 0;
  font-size: clamp(3rem, 8vw, 6.6rem);
  line-height: .88;
  letter-spacing: -.075em;
}
.tfa-hero p {
  max-width: 680px;
  margin: 0 0 24px;
  color: rgba(255,255,255,.76);
  font-size: clamp(1.05rem, 1.7vw, 1.28rem);
}
.tfa-hero-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.tfa-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #fff;
  border: 1px solid rgba(255,255,255,.22);
  padding: 12px 18px;
  font-weight: 850;
  background: rgba(255,255,255,.06);
}
.tfa-secondary:hover { color: var(--tfa-yellow); }

.tfa-dispatch-card {
  border: 1px solid rgba(255,255,255,.16);
  background: rgba(255,255,255,.08);
  border-radius: 28px;
  padding: 22px;
  box-shadow: 0 30px 90px rgba(0,0,0,.24);
  backdrop-filter: blur(16px);
}
.tfa-dispatch-card h2 { margin: 0 0 14px; font-size: 1.4rem; letter-spacing: -.04em; }
.tfa-yard-lines { display: grid; gap: 12px; }
.tfa-yard-line {
  display: grid;
  grid-template-columns: 40px 1fr auto;
  align-items: center;
  gap: 12px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 18px;
  padding: 12px;
}
.tfa-yard-icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: var(--tfa-yellow);
  color: var(--tfa-ink);
  font-weight: 950;
}
.tfa-yard-line strong { display: block; line-height: 1.15; }
.tfa-yard-line span { color: rgba(255,255,255,.7); font-size: .84rem; }
.tfa-yard-pill {
  color: #111827;
  background: var(--tfa-orange);
  border-radius: 999px;
  padding: 6px 9px;
  font-weight: 900;
  font-size: .72rem;
}

.tfa-search-panel {
  position: relative;
  margin-top: -34px;
  z-index: 5;
}
.tfa-search-box {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  padding: 12px;
  background: #fff;
  border-radius: 22px;
  box-shadow: var(--tfa-shadow);
  border: 1px solid var(--tfa-line);
}
.tfa-search-box input[type="search"] {
  border: 0;
  background: #f3f4f6;
  border-radius: 16px;
  padding: 16px;
  font-size: 1rem;
  width: 100%;
}
.tfa-search-box button {
  border: 0;
  border-radius: 16px;
  background: var(--tfa-ink);
  color: #fff;
  padding: 0 22px;
  font-weight: 900;
  cursor: pointer;
}

.tfa-section { padding: clamp(48px, 7vw, 86px) 0; }
.tfa-section-tight { padding: clamp(30px, 5vw, 56px) 0; }
.tfa-section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
}
.tfa-section-head h2 {
  margin: 0;
  font-size: clamp(2rem, 4.6vw, 4.2rem);
  line-height: .95;
  letter-spacing: -.065em;
}
.tfa-section-head p {
  margin: 0;
  max-width: 460px;
  color: var(--tfa-muted);
  font-weight: 650;
}

.tfa-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.tfa-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }

.tfa-card {
  background: var(--tfa-card);
  border: 1px solid var(--tfa-line);
  border-radius: var(--tfa-radius);
  overflow: hidden;
  box-shadow: 0 14px 40px rgba(17, 24, 39, .07);
}
.tfa-card:hover { transform: translateY(-2px); box-shadow: var(--tfa-shadow); }
.tfa-card-media {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #cbd5e1, #f8fafc);
  overflow: hidden;
}
.tfa-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tfa-card-body { padding: 22px; }
.tfa-card h3 { margin: 0 0 10px; line-height: 1.08; font-size: 1.35rem; letter-spacing: -.035em; }
.tfa-card p { margin: 0 0 16px; color: var(--tfa-muted); }
.tfa-meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; color: var(--tfa-muted); font-size: .86rem; font-weight: 700; }
.tfa-chip {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 10px;
  background: #eef2ff;
  color: #1e40af;
  font-size: .78rem;
  font-weight: 900;
}
.tfa-chip.orange { background: #ffedd5; color: #9a3412; }
.tfa-chip.dark { background: #111827; color: #fff; }
.tfa-link { font-weight: 950; color: var(--tfa-blue); }
.tfa-link:hover { color: var(--tfa-orange); }

.tfa-route-card {
  position: relative;
  min-height: 245px;
  color: #fff;
  background: linear-gradient(135deg, #1f2937, #0f172a);
  padding: 24px;
  border-radius: 28px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.1);
}
.tfa-route-card::after {
  content: "";
  position: absolute;
  width: 160px;
  height: 160px;
  right: -42px;
  bottom: -42px;
  border-radius: 999px;
  border: 18px solid rgba(250,204,21,.22);
}
.tfa-route-card h3 { position: relative; margin: 0 0 12px; font-size: 1.55rem; line-height: 1.05; letter-spacing: -.05em; }
.tfa-route-card p { position: relative; margin: 0 0 18px; color: rgba(255,255,255,.74); }
.tfa-route-card a { position: relative; color: var(--tfa-yellow); font-weight: 950; }

.tfa-featured {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 22px;
  align-items: stretch;
}
.tfa-featured-main {
  min-height: 430px;
  position: relative;
  overflow: hidden;
  border-radius: 32px;
  background: #111827;
  color: #fff;
  display: flex;
  align-items: flex-end;
  padding: 28px;
  border: 1px solid rgba(255,255,255,.12);
}
.tfa-featured-main img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .58;
}
.tfa-featured-main::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(17,24,39,.92), rgba(17,24,39,.08));
}
.tfa-featured-content { position: relative; z-index: 2; max-width: 700px; }
.tfa-featured-content h2 { margin: 12px 0; font-size: clamp(2rem, 4vw, 4rem); line-height: .95; letter-spacing: -.06em; }
.tfa-featured-content p { color: rgba(255,255,255,.78); font-size: 1.05rem; }
.tfa-sidebar-list { display: grid; gap: 14px; }
.tfa-mini-card {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 14px;
  padding: 12px;
  background: #fff;
  border-radius: 20px;
  border: 1px solid var(--tfa-line);
}
.tfa-mini-card img { width: 96px; height: 82px; object-fit: cover; border-radius: 14px; background: #e5e7eb; }
.tfa-mini-card h3 { margin: 0 0 6px; font-size: 1rem; line-height: 1.12; letter-spacing: -.025em; }
.tfa-mini-card span { color: var(--tfa-muted); font-size: .82rem; font-weight: 750; }

.tfa-content-wrap {
  display: grid;
  grid-template-columns: minmax(0, 760px) 320px;
  gap: 46px;
  align-items: start;
}
.tfa-main-content {
  background: #fff;
  border: 1px solid var(--tfa-line);
  border-radius: 30px;
  padding: clamp(24px, 4vw, 44px);
  box-shadow: 0 14px 44px rgba(17,24,39,.06);
}
.tfa-main-content h1 { margin-top: 0; font-size: clamp(2.25rem, 5vw, 4.5rem); line-height: .95; letter-spacing: -.07em; }
.tfa-main-content h2 { margin-top: 1.7em; line-height: 1.05; letter-spacing: -.04em; }
.tfa-main-content p, .tfa-main-content li { font-size: 1.06rem; }
.tfa-main-content a { color: var(--tfa-blue); font-weight: 800; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }

.tfa-sidebar { position: sticky; top: 100px; display: grid; gap: 16px; }
.tfa-widget {
  background: #fff;
  border: 1px solid var(--tfa-line);
  border-radius: 24px;
  padding: 20px;
  box-shadow: 0 12px 32px rgba(17,24,39,.05);
}
.tfa-widget h3 { margin: 0 0 10px; letter-spacing: -.03em; }
.tfa-widget ul { padding-left: 18px; margin: 10px 0 0; }
.tfa-widget li { margin-bottom: 8px; }

.tfa-page-hero {
  background: linear-gradient(135deg, #111827, #334155);
  color: #fff;
  padding: 74px 0 58px;
}
.tfa-page-hero h1 { margin: 0 0 12px; font-size: clamp(2.5rem, 6vw, 5.2rem); line-height: .94; letter-spacing: -.07em; }
.tfa-page-hero p { margin: 0; max-width: 720px; color: rgba(255,255,255,.74); font-size: 1.1rem; }

.tfa-footer {
  color: #fff;
  background: #111827;
  padding: 48px 0 28px;
  margin-top: 40px;
}
.tfa-footer-grid { display: grid; grid-template-columns: 1.2fr repeat(3, 1fr); gap: 30px; }
.tfa-footer h2, .tfa-footer h3 { margin: 0 0 12px; letter-spacing: -.04em; }
.tfa-footer p, .tfa-footer a { color: rgba(255,255,255,.72); }
.tfa-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.tfa-footer-bottom { margin-top: 34px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.1); color: rgba(255,255,255,.58); font-size: .9rem; }

.tfa-pagination { display: flex; gap: 10px; justify-content: center; margin-top: 32px; }
.tfa-pagination .page-numbers { padding: 10px 14px; border-radius: 12px; background: #fff; border: 1px solid var(--tfa-line); font-weight: 900; }
.tfa-pagination .current { background: var(--tfa-ink); color: #fff; }

.wp-block-image img { border-radius: 22px; }
.alignwide { max-width: 1100px; }
.alignfull { margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); width: 100vw; max-width: 100vw; }

@media (max-width: 920px) {
  .tfa-menu-toggle { display: inline-flex; }
  .tfa-nav {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: #111827;
    border-top: 1px solid rgba(255,255,255,.1);
    display: none;
    padding: 16px 20px 20px;
  }
  body.tfa-menu-open .tfa-nav { display: block; }
  .tfa-nav ul { display: grid; gap: 12px; }
  .tfa-header .tfa-cta { display: none; }
  .tfa-hero-inner,
  .tfa-featured,
  .tfa-content-wrap,
  .tfa-footer-grid { grid-template-columns: 1fr; }
  .tfa-grid-3, .tfa-grid-2 { grid-template-columns: 1fr; }
  .tfa-section-head { display: block; }
  .tfa-section-head p { margin-top: 12px; }
  .tfa-sidebar { position: static; }
}

@media (max-width: 560px) {
  .tfa-container { width: min(100% - 26px, var(--tfa-max)); }
  .tfa-search-box { grid-template-columns: 1fr; }
  .tfa-search-box button { min-height: 48px; }
  .tfa-yard-line { grid-template-columns: 40px 1fr; }
  .tfa-yard-pill { grid-column: 2; width: max-content; }
}

.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  word-wrap: normal !important;
}
.screen-reader-text:focus {
  background: #fff;
  clip: auto !important;
  clip-path: none;
  color: #111827;
  display: block;
  height: auto;
  left: 12px;
  padding: 12px;
  top: 12px;
  width: auto;
  z-index: 100000;
}
