/*
Theme Name: Ironclad Truck Wash
Theme URI: https://example.com/
Author: Your Name
Author URI: https://example.com/
Description: A theme for multi-location commercial truck wash and fleet service businesses. Includes a Locations custom post type with structured address, hours, and per-site service fields; a Services post type; and page templates for services, locations, charge accounts with a credit application section, and contact. Built for speed with no page-builder dependency.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: truckwash
Tags: business, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready, block-styles, wide-blocks

Ironclad Truck Wash is distributed under the terms of the GNU GPL v2 or later.

Rebranding: change the custom properties in :root below. Every color in the theme
derives from them, so one edit restyles the whole site.
*/

/* =========================================================
   Ironclad Truck Wash — stylesheet
   Replace the brand colors in :root to rebrand the whole site.
   ========================================================= */

:root {
  --navy:        #0f1c2e;
  --navy-light:  #1c2f47;
  --steel:       #43586f;
  --accent:      #f26b1d;   /* safety orange — primary CTA */
  --accent-dark: #d1550c;
  --ink:         #16202c;
  --body:        #4a5765;
  --line:        #dde3ea;
  --wash:        #f5f7fa;
  --white:       #ffffff;
  --ok:          #1f7a4d;

  --wrap: 1180px;
  --radius: 6px;
  --shadow: 0 1px 3px rgba(15,28,46,.08), 0 8px 24px rgba(15,28,46,.06);
  --font: "Helvetica Neue", Helvetica, Arial, system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--body);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  color: var(--ink);
  line-height: 1.2;
  margin: 0 0 .6em;
  font-weight: 700;
  letter-spacing: -.02em;
}

h1 { font-size: clamp(2rem, 5vw, 3.1rem); }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.2rem); }
h3 { font-size: 1.2rem; }

p { margin: 0 0 1.1em; }

a { color: var(--accent-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

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

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: .74rem;
  font-weight: 700;
  color: var(--accent-dark);
  margin-bottom: .8em;
}

.lede { font-size: 1.12rem; color: var(--steel); }

/* ---------- Skip link (accessibility) ---------- */
.skip {
  position: absolute; left: -9999px;
  background: var(--accent); color: #fff;
  padding: 12px 20px; z-index: 200;
}
.skip:focus { left: 12px; top: 12px; }

/* ---------- Utility bar ---------- */
.utility {
  background: var(--navy);
  color: #a8bbd0;
  font-size: .82rem;
}
.utility .wrap {
  display: flex; justify-content: space-between;
  align-items: center; gap: 16px;
  min-height: 40px; flex-wrap: wrap;
}
.utility a { color: #cfdcea; }
.utility strong { color: #fff; }
.utility-links { display: flex; gap: 20px; }

/* ---------- Header / nav ---------- */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 100;
}
.site-header .wrap {
  display: flex; align-items: center;
  justify-content: space-between; gap: 24px;
  min-height: 78px;
}

.logo {
  display: flex; align-items: center; gap: 11px;
  font-weight: 800; font-size: 1.16rem;
  color: var(--ink); letter-spacing: -.03em;
  text-decoration: none; flex-shrink: 0;
}
.logo:hover { text-decoration: none; }
.logo-mark {
  width: 38px; height: 38px; border-radius: 5px;
  background: var(--accent);
  display: grid; place-items: center;
  color: #fff; font-size: 1.02rem; font-weight: 800;
  flex-shrink: 0;
}
.logo small {
  display: block; font-size: .62rem; font-weight: 600;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--steel);
}

nav.main { display: flex; align-items: center; gap: 4px; }
nav.main a {
  color: var(--ink); font-size: .92rem; font-weight: 600;
  padding: 9px 13px; border-radius: var(--radius);
}
nav.main a:hover { background: var(--wash); text-decoration: none; }
nav.main a[aria-current="page"] {
  color: var(--accent-dark);
  box-shadow: inset 0 -2px 0 var(--accent);
  border-radius: 0;
}

.nav-toggle {
  display: none; background: none; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 9px 12px;
  font-size: 1.1rem; cursor: pointer; color: var(--ink);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; padding: 13px 26px;
  border-radius: var(--radius); font-weight: 700;
  font-size: .95rem; border: 2px solid transparent;
  cursor: pointer; text-align: center;
  transition: background .15s, color .15s;
  font-family: var(--font);
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); color: #fff; }
.btn-outline { border-color: var(--steel); color: var(--ink); background: transparent; }
.btn-outline:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
.btn-ghost-light { border-color: rgba(255,255,255,.45); color: #fff; }
.btn-ghost-light:hover { background: #fff; color: var(--navy); border-color: #fff; }
.btn-sm { padding: 9px 18px; font-size: .87rem; }

/* ---------- Hero ---------- */
.hero {
  background:
    linear-gradient(115deg, rgba(15,28,46,.94) 0%, rgba(28,47,71,.86) 100%),
    url("assets/img/hero.jpg") center/cover no-repeat, var(--navy);
  color: #e8eef5;
  padding: 92px 0 84px;
}
.hero h1 { color: #fff; max-width: 15ch; }
.hero p { font-size: 1.16rem; max-width: 54ch; color: #c6d4e3; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 30px; }

.hero-stats {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 28px; margin-top: 58px; padding-top: 34px;
  border-top: 1px solid rgba(255,255,255,.16);
}
.hero-stats .n {
  font-size: 2rem; font-weight: 800; color: #fff;
  letter-spacing: -.03em; line-height: 1;
}
.hero-stats .l {
  font-size: .78rem; text-transform: uppercase;
  letter-spacing: .1em; color: #93a8bf; margin-top: 8px;
}

/* ---------- Sections ---------- */
section { padding: 76px 0; }
section.tint { background: var(--wash); }
section.dark { background: var(--navy); color: #c6d4e3; }
section.dark h2, section.dark h3 { color: #fff; }

.section-head { max-width: 620px; margin-bottom: 44px; }
.section-head.center { margin-inline: auto; text-align: center; }

/* ---------- Cards ---------- */
.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }

.card {
  background: var(--white); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 30px;
  box-shadow: var(--shadow);
}
.card h3 { margin-bottom: .45em; }
.card p:last-child { margin-bottom: 0; }
.card .icon {
  width: 46px; height: 46px; border-radius: var(--radius);
  background: #fdeee4; color: var(--accent-dark);
  display: grid; place-items: center;
  font-size: 1.35rem; margin-bottom: 18px;
}
.card-link { font-weight: 700; font-size: .9rem; }

/* ---------- Numbered steps ---------- */
.steps { counter-reset: step; }
.step { position: relative; padding-left: 62px; margin-bottom: 34px; }
.step:last-child { margin-bottom: 0; }
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 42px; height: 42px; border-radius: 50%;
  background: var(--accent); color: #fff;
  display: grid; place-items: center;
  font-weight: 800; font-size: 1.05rem;
}
.step h3 { margin-bottom: .3em; }
.step p { margin-bottom: 0; }

/* ---------- Tables ---------- */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.data {
  width: 100%; border-collapse: collapse;
  background: #fff; font-size: .93rem;
  border: 1px solid var(--line); border-radius: var(--radius);
}
table.data th, table.data td {
  padding: 14px 16px; text-align: left;
  border-bottom: 1px solid var(--line);
}
table.data th {
  background: var(--wash); color: var(--ink);
  font-size: .76rem; text-transform: uppercase;
  letter-spacing: .08em; white-space: nowrap;
}
table.data tbody tr:last-child td { border-bottom: none; }
table.data tbody tr:hover { background: #fafbfd; }

/* ---------- Locations ---------- */
.loc-card {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px;
  border-top: 3px solid var(--accent);
}
.loc-card h3 { margin-bottom: .2em; }
.loc-card .state {
  font-size: .74rem; text-transform: uppercase;
  letter-spacing: .1em; color: var(--steel);
  font-weight: 700; margin-bottom: 14px;
}
.loc-card address {
  font-style: normal; font-size: .93rem;
  margin-bottom: 14px; color: var(--body);
}
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.tag {
  font-size: .72rem; font-weight: 700; padding: 4px 10px;
  border-radius: 20px; background: var(--wash);
  color: var(--steel); border: 1px solid var(--line);
  text-transform: uppercase; letter-spacing: .05em;
}
.tag.hot { background: #fdeee4; color: var(--accent-dark); border-color: #f8d5c0; }

/* ---------- Forms ---------- */
.form-card {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 38px;
  box-shadow: var(--shadow);
}
fieldset {
  border: none; padding: 0; margin: 0 0 34px;
}
fieldset legend {
  font-weight: 800; font-size: 1.02rem; color: var(--ink);
  padding: 0 0 8px; margin-bottom: 20px; width: 100%;
  border-bottom: 2px solid var(--accent);
}
.field-row {
  display: grid; gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  margin-bottom: 18px;
}
.field { display: flex; flex-direction: column; }
.field label {
  font-size: .84rem; font-weight: 700;
  color: var(--ink); margin-bottom: 6px;
}
.field .hint {
  font-size: .78rem; color: var(--steel);
  font-weight: 400; margin-top: 5px;
}
.field .req { color: var(--accent-dark); }
input, select, textarea {
  font-family: var(--font); font-size: .95rem;
  padding: 11px 13px; border: 1px solid #c2ccd8;
  border-radius: var(--radius); background: #fff;
  color: var(--ink); width: 100%;
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(242,107,29,.15);
}
textarea { resize: vertical; min-height: 110px; }
.check {
  display: flex; gap: 11px; align-items: flex-start;
  margin-bottom: 14px; font-size: .92rem;
}
.check input { width: auto; margin-top: 4px; flex-shrink: 0; }
.legal {
  background: var(--wash); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px;
  font-size: .85rem; max-height: 210px; overflow-y: auto;
  margin-bottom: 20px; color: var(--steel);
}
.legal p:last-child { margin-bottom: 0; }
.form-note {
  font-size: .85rem; color: var(--steel);
  border-left: 3px solid var(--accent); padding-left: 14px;
}

/* ---------- Callout / CTA band ---------- */
.cta-band {
  background: var(--accent); color: #fff;
  padding: 58px 0; text-align: center;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: #ffe9dc; max-width: 56ch; margin-inline: auto; }
.cta-band .btn-white { background: #fff; color: var(--accent-dark); }
.cta-band .btn-white:hover { background: var(--navy); color: #fff; }

.notice {
  background: #fff8e6; border: 1px solid #f0dca8;
  border-left: 4px solid #e0a800; border-radius: var(--radius);
  padding: 18px 20px; font-size: .9rem; margin-bottom: 28px;
}
.notice strong { color: var(--ink); }

/* ---------- Footer ---------- */
footer.site-footer {
  background: var(--navy); color: #93a8bf;
  padding: 60px 0 26px; font-size: .9rem;
}
footer.site-footer h4 {
  color: #fff; font-size: .78rem; text-transform: uppercase;
  letter-spacing: .11em; margin-bottom: 16px;
}
footer.site-footer a { color: #c6d4e3; }
.footer-grid {
  display: grid; gap: 36px;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 9px; }
.footer-bottom {
  margin-top: 44px; padding-top: 22px;
  border-top: 1px solid rgba(255,255,255,.13);
  display: flex; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; font-size: .83rem;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 820px) {
  .nav-toggle { display: block; }
  nav.main {
    display: none; position: absolute;
    top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch;
    background: #fff; border-bottom: 1px solid var(--line);
    padding: 12px; gap: 2px;
    box-shadow: 0 12px 24px rgba(15,28,46,.1);
  }
  nav.main.open { display: flex; }
  nav.main a { padding: 13px; }
  nav.main .btn { margin-top: 8px; }
  .site-header .wrap { position: relative; }
  .utility-links { display: none; }
  .hero { padding: 62px 0 56px; }
  section { padding: 56px 0; }
  .form-card { padding: 24px; }
}
@media (max-width: 560px) {
  .footer-grid { grid-template-columns: 1fr; }
  body { font-size: 16px; }
}

@media print {
  .site-header, .utility, footer.site-footer, .cta-band { display: none; }
}


/* =========================================================
   WordPress core classes — required for theme review and for
   the block editor's alignment and caption output to render.
   ========================================================= */

.screen-reader-text {
  border: 0; clip-path: inset(50%); height: 1px; margin: -1px;
  overflow: hidden; padding: 0; position: absolute;
  white-space: nowrap; width: 1px;
}
.screen-reader-text:focus {
  background-color: #fff; border-radius: 3px;
  box-shadow: 0 0 2px 2px rgba(0,0,0,.6);
  clip-path: none; color: var(--accent-dark);
  display: block; font-size: .9rem; font-weight: 700;
  height: auto; left: 5px; line-height: normal;
  padding: 15px 23px 14px; text-decoration: none;
  top: 5px; width: auto; z-index: 100000;
}

.alignleft   { float: left;  margin: .4em 1.6em 1em 0; }
.alignright  { float: right; margin: .4em 0 1em 1.6em; }
.aligncenter { clear: both; display: block; margin: 1em auto; }
.alignwide   { max-width: calc(var(--wrap) + 160px); margin-inline: auto; }
.alignfull   { max-width: none; }

.wp-caption { margin-bottom: 1.6em; max-width: 100%; }
.wp-caption img[class*="wp-image-"] { display: block; margin: 0 auto; }
.wp-caption-text, .wp-element-caption, .gallery-caption {
  font-size: .85rem; color: var(--steel); text-align: center;
  margin: .7em 0 0;
}
.sticky { position: relative; }
.bypostauthor > article { border-left: 3px solid var(--accent); }

.wp-block-image img { height: auto; border-radius: var(--radius); }
.wp-block-table table { width: 100%; border-collapse: collapse; }
.wp-block-quote {
  border-left: 3px solid var(--accent); padding-left: 20px;
  margin-left: 0; font-style: italic; color: var(--ink);
}
.wp-block-button__link {
  background: var(--accent); color: #fff; padding: 13px 26px;
  border-radius: var(--radius); font-weight: 700; text-decoration: none;
}
.wp-block-button__link:hover { background: var(--accent-dark); color: #fff; }

/* Admin bar offset so the sticky header doesn't hide under it */
.admin-bar .site-header { top: 32px; }
@media screen and (max-width: 782px) {
  .admin-bar .site-header { top: 46px; }
}

/* =========================================================
   Editorial content (pages, posts, news)
   ========================================================= */

.entry-content > * { max-width: 760px; }
.entry-content > .alignwide,
.entry-content > .alignfull,
.entry-content > .wp-block-table,
.entry-content > .wp-block-columns { max-width: none; }
.entry-content h2 { margin-top: 1.8em; }
.entry-content h3 { margin-top: 1.5em; }
.entry-content ul, .entry-content ol { padding-left: 22px; }
.entry-content li { margin-bottom: .45em; }
.entry-content img { border-radius: var(--radius); }

.entry-meta {
  font-size: .84rem; color: var(--steel);
  margin-bottom: 1.6em;
}
.post-card {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); display: flex; flex-direction: column;
}
.post-card .thumb { aspect-ratio: 16/9; overflow: hidden; background: var(--wash); }
.post-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.post-card .body { padding: 24px; flex: 1; display: flex; flex-direction: column; }
.post-card h3 { margin-bottom: .4em; }
.post-card h3 a { color: var(--ink); }
.post-card .body > :last-child { margin-top: auto; margin-bottom: 0; }

.pagination {
  display: flex; gap: 8px; flex-wrap: wrap;
  margin-top: 40px; justify-content: center;
}
.pagination .page-numbers {
  padding: 9px 15px; border: 1px solid var(--line);
  border-radius: var(--radius); color: var(--ink);
  font-weight: 600; font-size: .9rem; text-decoration: none;
}
.pagination .page-numbers:hover { background: var(--wash); }
.pagination .page-numbers.current {
  background: var(--accent); color: #fff; border-color: var(--accent);
}

/* Comments — present so threaded-comments support is real */
.comment-list { list-style: none; padding: 0; }
.comment-list ol.children { list-style: none; padding-left: 28px; }
.comment-body {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px; margin-bottom: 18px;
}
.comment-author { font-weight: 700; color: var(--ink); }
.comment-metadata { font-size: .8rem; color: var(--steel); margin-bottom: .8em; }
.comment-respond input[type="text"],
.comment-respond input[type="email"],
.comment-respond input[type="url"],
.comment-respond textarea {
  font-family: var(--font); font-size: .95rem; padding: 11px 13px;
  border: 1px solid #c2ccd8; border-radius: var(--radius); width: 100%;
}
.comment-form-cookies-consent { display: flex; gap: 10px; align-items: baseline; }
.comment-form-cookies-consent input { width: auto; }

/* Widgets, if a sidebar is ever added */
.widget { margin-bottom: 32px; }
.widget ul { list-style: none; padding: 0; }
.widget li { margin-bottom: 8px; }

/* 404 / search results */
.page-hero {
  background: var(--navy); color: #c6d4e3;
  padding: 62px 0 56px;
}
.page-hero h1, .page-hero h2 { color: #fff; }
.page-hero .lede { color: #c6d4e3; max-width: 60ch; }
