/*
Theme Name: Trailer Smart
Theme URI: https://trailersmart.net/
Author: Trailer Smart
Description: A custom one-page WordPress theme for the Trailer Smart Bluetooth wheel hub temperature monitoring product.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
Text Domain: trailersmart
*/

:root {
  color-scheme: light;
  --ink: #101827;
  --muted: #5c6676;
  --navy: #112240;
  --blue: #1d3557;
  --amber: #b5651d;
  --amber-light: #f5c06f;
  --green: #157347;
  --red: #b91c1c;
  --paper: #f7f8fb;
  --white: #ffffff;
  --line: #d9dee8;
  --shadow: 0 20px 50px rgba(16, 24, 39, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 72px;
  padding: 14px clamp(18px, 4vw, 56px);
  color: var(--white);
  transition: background 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

body.admin-bar .site-header {
  top: 32px;
}

.site-header.is-scrolled,
.site-header.is-open {
  background: rgba(17, 34, 64, 0.96);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 8px 30px rgba(17, 34, 64, 0.25);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand img {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 32px);
  color: rgba(255, 255, 255, 0.84);
  font-size: 0.96rem;
  font-weight: 650;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--amber-light);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.nav-toggle span:not(.sr-only) {
  width: 18px;
  height: 2px;
  background: currentColor;
}

.hero {
  position: relative;
  min-height: 86vh;
  display: grid;
  align-items: center;
  overflow: hidden;
  color: var(--white);
  isolation: isolate;
}

.hero-media,
.hero-shade {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.hero-media {
  background-image: url("assets/hero-trailer-smart.png");
  background-size: cover;
  background-position: center right;
}

.hero-shade {
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(8, 15, 28, 0.92) 0%, rgba(8, 15, 28, 0.72) 34%, rgba(8, 15, 28, 0.2) 72%),
    linear-gradient(0deg, rgba(8, 15, 28, 0.32), rgba(8, 15, 28, 0.14));
}

.hero-content {
  width: min(720px, calc(100% - 36px));
  margin-left: clamp(18px, 7vw, 96px);
  padding-top: 96px;
  padding-bottom: 48px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--amber-light);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.eyebrow.dark {
  color: var(--amber);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 18px;
  font-size: clamp(3.5rem, 9vw, 8.4rem);
  line-height: 0.92;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 18px;
  font-size: clamp(2rem, 4vw, 4rem);
  line-height: 1.04;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 8px;
  font-size: 1.1rem;
  line-height: 1.2;
}

.hero-copy {
  max-width: 620px;
  margin-bottom: 28px;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(1.05rem, 2vw, 1.35rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 42px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 800;
  cursor: pointer;
}

.button.primary {
  background: var(--amber);
  color: var(--white);
}

.button.primary:hover,
.button.primary:focus-visible {
  background: #9a5517;
}

.button.secondary {
  border-color: rgba(255, 255, 255, 0.48);
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.button.secondary:hover,
.button.secondary:focus-visible {
  border-color: var(--amber-light);
  color: var(--amber-light);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  max-width: 680px;
  margin: 0;
}

.hero-stats div {
  min-height: 92px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
}

.hero-stats dt {
  margin-bottom: 5px;
  color: var(--amber-light);
  font-weight: 800;
}

.hero-stats dd {
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
}

.section {
  padding: clamp(58px, 8vw, 108px) clamp(18px, 4vw, 56px);
}

.section-inner {
  width: min(1180px, 100%);
  margin: 0 auto;
}

.intro-band {
  padding-top: 40px;
  padding-bottom: 44px;
  background: var(--white);
  border-bottom: 1px solid var(--line);
}

.split,
.safety-layout,
.contact-layout,
.app-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: clamp(28px, 6vw, 72px);
  align-items: center;
}

.split p,
.contact-layout p,
.app-copy > p,
.safety-points p {
  color: var(--muted);
  font-size: 1.08rem;
}

.section-heading {
  max-width: 740px;
  margin-bottom: 32px;
}

.steps,
.use-grid,
.feature-grid {
  display: grid;
  gap: 14px;
}

.steps {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.step-card,
.use-grid article,
.feature-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.step-card {
  min-height: 236px;
  padding: 24px;
  box-shadow: 0 12px 32px rgba(16, 24, 39, 0.06);
}

.step-number {
  display: inline-block;
  margin-bottom: 34px;
  color: var(--amber);
  font-size: 0.85rem;
  font-weight: 900;
}

.step-card p,
.use-grid p,
.feature-grid p {
  color: var(--muted);
}

.product-band {
  background: var(--navy);
  color: var(--white);
}

.app-layout {
  grid-template-columns: minmax(280px, 410px) minmax(0, 1fr);
}

.phone-shell {
  width: min(100%, 380px);
  margin: 0 auto;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 28px;
  background: #070b13;
  box-shadow: var(--shadow);
}

.phone-screen {
  min-height: 620px;
  overflow: hidden;
  border-radius: 22px;
  background: #f6f7fb;
  color: var(--ink);
}

.phone-top {
  padding: 24px 20px;
  background: linear-gradient(135deg, var(--navy), var(--blue), var(--amber));
  color: var(--white);
}

.phone-top span,
.phone-top em {
  display: block;
  color: #f7e7ce;
  font-style: normal;
  font-weight: 700;
}

.phone-top strong {
  display: block;
  margin: 8px 0;
  font-size: 1.85rem;
  line-height: 1.08;
}

.status-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 14px;
}

.status-row span,
.reading {
  border: 1px solid #e3e7ef;
  border-radius: 8px;
  background: var(--white);
}

.status-row span {
  padding: 12px;
  color: var(--muted);
  font-weight: 750;
}

.reading {
  margin: 0 14px 12px;
  padding: 16px;
}

.reading span,
.reading em {
  display: block;
  color: var(--muted);
  font-style: normal;
  font-weight: 750;
}

.reading strong {
  display: block;
  margin: 8px 0 4px;
  font-size: 2.25rem;
  line-height: 1;
}

.reading.warm strong,
.reading.warm em {
  color: var(--amber);
}

.reading.normal strong,
.reading.normal em {
  color: var(--green);
}

.app-copy .eyebrow,
.safety-band .eyebrow {
  color: var(--amber-light);
}

.app-copy p {
  color: rgba(255, 255, 255, 0.78);
}

.feature-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 26px;
}

.feature-grid article {
  padding: 18px;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.16);
}

.feature-grid p {
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.7);
}

.use-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.use-grid article {
  min-height: 172px;
  padding: 22px;
}

.safety-band {
  background: #173c34;
  color: var(--white);
}

.safety-points {
  display: grid;
  gap: 16px;
}

.safety-points p {
  margin: 0;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.17);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.82);
}

.contact-form {
  display: grid;
  gap: 14px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 16px 40px rgba(16, 24, 39, 0.08);
}

.contact-form label {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-weight: 800;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  border: 1px solid #c7cedb;
  border-radius: 8px;
  padding: 12px 13px;
  background: #fbfcfe;
  color: var(--ink);
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: 3px solid rgba(181, 101, 29, 0.24);
  border-color: var(--amber);
}

.contact-form .button {
  width: 100%;
}

.form-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.site-footer {
  padding: 28px clamp(18px, 4vw, 56px);
  background: var(--ink);
  color: var(--white);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.footer-inner p {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
}

.footer-brand img {
  width: 36px;
  height: 36px;
}

@media (max-width: 900px) {
  body.admin-bar .site-header {
    top: 46px;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    position: absolute;
    top: 72px;
    left: 18px;
    right: 18px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 8px;
    background: rgba(17, 34, 64, 0.98);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 13px 10px;
  }

  .hero {
    min-height: 84vh;
  }

  .hero-media {
    background-position: 66% center;
  }

  .hero-shade {
    background:
      linear-gradient(90deg, rgba(8, 15, 28, 0.94) 0%, rgba(8, 15, 28, 0.76) 58%, rgba(8, 15, 28, 0.32) 100%),
      linear-gradient(0deg, rgba(8, 15, 28, 0.34), rgba(8, 15, 28, 0.18));
  }

  .hero-content {
    margin: 0 auto;
  }

  .hero-stats,
  .steps,
  .use-grid,
  .feature-grid,
  .split,
  .safety-layout,
  .contact-layout,
  .app-layout {
    grid-template-columns: 1fr;
  }

  .phone-screen {
    min-height: 560px;
  }
}

@media (max-width: 560px) {
  .site-header {
    min-height: 66px;
    padding: 12px 16px;
  }

  .brand span {
    font-size: 0.98rem;
  }

  .brand img {
    width: 36px;
    height: 36px;
  }

  .site-nav {
    top: 66px;
    left: 12px;
    right: 12px;
  }

  .hero-content {
    width: min(100% - 28px, 720px);
    padding-top: 92px;
    padding-bottom: 34px;
  }

  h1 {
    font-size: clamp(3.1rem, 18vw, 5rem);
  }

  h2 {
    font-size: clamp(1.85rem, 10vw, 2.65rem);
  }

  .hero-actions .button {
    width: 100%;
  }

  .hero-stats {
    gap: 8px;
  }

  .hero-stats div {
    min-height: 0;
  }

  .section {
    padding-left: 16px;
    padding-right: 16px;
  }

  .phone-shell {
    padding: 8px;
  }

  .phone-screen {
    min-height: 520px;
  }

  .phone-top strong {
    font-size: 1.5rem;
  }

  .reading strong {
    font-size: 1.85rem;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }
}
