/*
Theme Name: Spitfire Astra
Template: astra
Description: Spitfire Polishing child theme for Astra. Colours and type live in the variables below.
Version: 2.1.1
Text Domain: spitfire-astra
*/

@font-face { font-family: "Barlow Condensed"; src: url("fonts/barlow-condensed-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Barlow Condensed"; src: url("fonts/barlow-condensed-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --sp-bg: #0c0d0f;
  --sp-panel: #131518;
  --sp-card: #1a1d21;
  --sp-line: rgba(255, 255, 255, .11);
  --sp-text: #f1efea;
  --sp-muted: #aeb2b8;
  --sp-ember: #f2601f;
  --sp-ember-hover: #ff7638;
  --sp-on-ember: #140d08;
  --sp-link: #ff9466;
  --sp-display: "Barlow Condensed", "Arial Narrow", Arial, sans-serif;
  --sp-body: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

body,
.ast-separate-container,
.ast-plain-container,
.ast-separate-container .ast-article-single,
.ast-separate-container .ast-article-post,
.ast-separate-container .site-main > .ast-row,
.ast-woocommerce-container,
.site-content {
  background: var(--sp-bg) !important;
  color: var(--sp-text);
  font-family: var(--sp-body);
}
body { font-size: 17px; line-height: 1.65; -webkit-font-smoothing: antialiased; }

h1, h2, h3, h4, h5, h6,
.entry-title, .entry-title a,
.woocommerce-products-header__title,
.product_title {
  color: #fff !important;
  font-family: var(--sp-display) !important;
  font-weight: 700 !important;
  letter-spacing: .005em;
  line-height: 1.05 !important;
}
h1, .woocommerce-products-header__title, .product_title { font-size: clamp(2.7rem, 6vw, 4.75rem) !important; text-transform: uppercase; }
h2 { font-size: clamp(2.1rem, 3.8vw, 3.1rem) !important; text-transform: uppercase; }
h3 { font-size: 1.6rem !important; font-weight: 600 !important; }

p, li, label { color: var(--sp-text); }
a { color: var(--sp-link); }
a:hover { color: #ffb08e; }
:focus-visible { outline: 2px solid var(--sp-ember-hover) !important; outline-offset: 3px; }

/* Header */
#masthead { position: sticky; top: 0; z-index: 100; }
.admin-bar #masthead { top: 32px; }
.main-header-bar,
.ast-primary-header-bar,
.site-primary-header-wrap,
#ast-desktop-header .ast-primary-header-bar,
#ast-mobile-header .ast-primary-header-bar,
.ast-mobile-header-content,
.ast-builder-menu-1 .main-header-menu {
  background: #08090a !important;
  border-bottom-color: var(--sp-line) !important;
}
.site-title a, .site-title {
  color: #fff !important;
  font-family: var(--sp-display) !important;
  font-size: 1.6rem !important;
  font-weight: 700;
  letter-spacing: .03em;
  text-transform: uppercase;
}
.site-description { display: none; }
.home .site-logo-img { display: none; }
.main-header-menu .menu-link, .ast-builder-menu-1 .menu-link {
  color: var(--sp-text) !important;
  font-size: .95rem;
  font-weight: 500;
}
.main-header-menu .menu-link:hover,
.main-header-menu .current-menu-item > .menu-link { color: var(--sp-link) !important; }
.main-header-menu .sp-nav-cta > .menu-link {
  background: var(--sp-ember);
  border-radius: 4px;
  color: var(--sp-on-ember) !important;
  font-weight: 700;
  line-height: 1;
  margin-left: 10px;
  padding: 12px 18px;
}
.main-header-menu .sp-nav-cta > .menu-link:hover { background: var(--sp-ember-hover); color: var(--sp-on-ember) !important; }
#ast-desktop-header .sp-nav-cta { align-self: center; }
.ast-mobile-menu-trigger-minimal { color: #fff !important; }
.ast-mobile-svg, .mobile-menu-toggle-icon svg { fill: #fff !important; }
.ast-mobile-header-content .main-header-menu .sp-nav-cta > .menu-link,
.ast-mobile-header-content .sp-nav-cta > .menu-link {
  background: var(--sp-ember) !important;
  border-radius: 4px;
  box-sizing: border-box;
  color: var(--sp-on-ember) !important;
  display: block;
  font-weight: 700;
  margin: 12px 20px 16px !important;
  padding: 14px 18px !important;
  text-align: center;
  width: calc(100% - 40px) !important;
}
.ast-mobile-header-content .menu-item { border-color: var(--sp-line) !important; }

/* Sections: applied to core blocks through "Additional CSS class" */
.sp-hero, .sp-band, .sp-head { padding: clamp(56px, 8vw, 110px) 24px; }
.sp-hero { background: #08090a; border-bottom: 1px solid var(--sp-line); }
.sp-hero p { margin-left: 0 !important; }
.sp-lead { color: #d9d9d6 !important; font-size: clamp(1.1rem, 1.6vw, 1.3rem); line-height: 1.55; margin-left: 0 !important; max-width: 38em; }
.page .site-content > .ast-container,
.page #primary,
.page .site-main,
.page .ast-article-single,
.page .entry-content { margin-bottom: 0 !important; padding-bottom: 0 !important; }
.page .entry-content > :last-child { margin-bottom: 0 !important; }
.woocommerce-cart .entry-content, .woocommerce-checkout .entry-content, .woocommerce-account .entry-content { padding-bottom: 64px !important; }
.sp-eyebrow {
  color: var(--sp-link) !important;
  font-family: var(--sp-display);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: .14em;
  margin-bottom: .6em !important;
  text-transform: uppercase;
}
.sp-hero-logo { margin: 0 !important; }
.sp-hero-logo img { border-radius: 6px; display: block; height: auto; margin-inline: auto; max-width: min(100%, 440px); }
.sp-head { background: #08090a; border-bottom: 1px solid var(--sp-line); padding-bottom: clamp(36px, 5vw, 64px); }
.sp-head p:last-child { margin-bottom: 0; }
.sp-head > .sp-lead { margin-inline: auto !important; max-width: var(--wp--style--global--content-size, 1200px) !important; }
.sp-band-alt { background: var(--sp-panel) !important; border-block: 1px solid var(--sp-line); }
.sp-band h2 { margin-bottom: .55em; }
.sp-band > .wp-block-columns { margin-bottom: 0; }
.sp-card {
  background: var(--sp-card);
  border: 1px solid var(--sp-line);
  border-radius: 6px;
  height: 100%;
  padding: 28px;
  transition: border-color .18s ease;
}
.sp-card:hover { border-color: rgba(255, 255, 255, .28); }
.sp-card h3 { margin-top: 0; margin-bottom: .5em; }
.sp-card p:last-child { margin-bottom: 0; }
.sp-muted { color: var(--sp-muted) !important; }

.sp-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  list-style: none !important;
  margin-block: 0 !important;
  padding: 0 !important;
}
@media (max-width: 720px) {
  .sp-chips { gap: 8px 22px; }
  .sp-chips li:not(:last-child)::after { content: none; }
}
.sp-chips li {
  color: var(--sp-text);
  font-family: var(--sp-display);
  font-size: 1.3rem;
  font-weight: 600;
  letter-spacing: .03em;
  margin: 0 !important;
  text-transform: uppercase;
}
.sp-chips li:not(:last-child)::after { color: var(--sp-ember); content: "/"; font-weight: 400; margin-left: 26px; }
.sp-strip { background: var(--sp-panel) !important; border-bottom: 1px solid var(--sp-line); padding: 26px 24px; }

.sp-steps { counter-reset: sp-step; }
.sp-steps h3::before {
  color: var(--sp-ember);
  content: counter(sp-step, decimal-leading-zero);
  counter-increment: sp-step;
  display: block;
  font-size: 2.4rem;
  line-height: 1;
  margin-bottom: 14px;
}
.sp-steps .sp-card { background: transparent; border-width: 1px 0 0; border-radius: 0; padding: 22px 0 0; }

.sp-cta { background: var(--sp-ember) !important; padding: clamp(48px, 6vw, 76px) 24px; }
.sp-cta h2, .sp-cta p { color: var(--sp-on-ember) !important; }
.sp-cta h2 { margin-bottom: .3em; }
.sp-cta .wp-block-button__link {
  background: #0c0d0f !important;
  border-color: #0c0d0f !important;
  color: #fff !important;
}
.sp-cta .wp-block-button__link:hover { background: #2a2d31 !important; border-color: #2a2d31 !important; }
.sp-cta :focus-visible { outline-color: #0c0d0f !important; }

.sp-list { list-style: none; margin: 0 !important; padding: 0 !important; }
.sp-list li { border-top: 1px solid var(--sp-line); margin: 0 !important; padding: 10px 0; }

/* Buttons */
.wp-block-button__link,
.button, a.button, button.button, input[type="submit"],
.woocommerce a.button, .woocommerce button.button,
.wc-block-components-button {
  background: var(--sp-ember) !important;
  border: 1px solid var(--sp-ember) !important;
  border-radius: 4px !important;
  color: var(--sp-on-ember) !important;
  font-family: var(--sp-body);
  font-size: 1rem !important;
  font-weight: 700 !important;
  padding: 14px 24px !important;
}
.wp-block-button__link:hover,
.button:hover, a.button:hover, button.button:hover, input[type="submit"]:hover,
.woocommerce a.button:hover, .woocommerce button.button:hover {
  background: var(--sp-ember-hover) !important;
  border-color: var(--sp-ember-hover) !important;
  color: var(--sp-on-ember) !important;
}
.is-style-outline .wp-block-button__link {
  background: transparent !important;
  border-color: rgba(255, 255, 255, .4) !important;
  color: #fff !important;
}
.is-style-outline .wp-block-button__link:hover { background: rgba(255, 255, 255, .08) !important; border-color: #fff !important; color: #fff !important; }

/* Forms */
input[type="text"], input[type="email"], input[type="tel"], input[type="search"],
input[type="password"], input[type="number"], select, textarea {
  background: #0e1012 !important;
  border: 1px solid #737980 !important;
  border-radius: 4px;
  color: var(--sp-text) !important;
  width: 100%;
}
.wpcf7 label { display: block; font-size: .95rem; font-weight: 600; }

/* Footer */
.sp-footer { background: #08090a; border-top: 1px solid var(--sp-line); padding: 56px 24px 40px; }
.sp-footer-grid { display: grid; gap: 36px; grid-template-columns: 2fr 1fr 1fr; margin: 0 auto; max-width: 1200px; }
.sp-footer h2 { font-size: 1.15rem !important; letter-spacing: .1em; margin: 0 0 12px; }
.sp-footer p, .sp-footer li { color: var(--sp-muted); font-size: .97rem; }
.sp-footer ul { list-style: none; margin: 0; padding: 0; }
.sp-footer li { margin-bottom: 6px; }
.sp-footer a { color: var(--sp-text); text-decoration: none; }
.sp-footer a:hover { color: var(--sp-link); text-decoration: underline; }
.sp-footer p.sp-footer-brand { color: #fff; font-family: var(--sp-display); font-size: 1.6rem; font-weight: 700; letter-spacing: .03em; line-height: 1.1; margin-bottom: .4em; text-transform: uppercase; }
@media (max-width: 720px) { .sp-footer-grid { grid-template-columns: 1fr; } }
.site-footer, .ast-footer-copyright, .site-below-footer-wrap, .site-primary-footer-wrap {
  background: #08090a !important;
  border-color: var(--sp-line) !important;
  color: var(--sp-muted) !important;
}
.site-footer { border-top: 0 !important; }
.ast-footer-copyright p { color: var(--sp-muted); font-size: .9rem; }

/* WooCommerce */
.woocommerce-products-header { padding-top: 12px; }
.woocommerce-products-header__description, .term-description { color: var(--sp-muted); max-width: 40em; }
.woocommerce ul.products li.product,
.woocommerce-page ul.products li.product {
  background: var(--sp-card);
  border: 1px solid var(--sp-line);
  border-radius: 6px;
  padding: 0 0 20px;
  transition: border-color .18s ease;
}
.woocommerce ul.products li.product:hover { border-color: rgba(255, 255, 255, .28); }
.woocommerce ul.products li.product img { border-radius: 6px 6px 0 0; margin-bottom: 14px; }
.woocommerce ul.products li.product .astra-shop-summary-wrap { padding-inline: 18px; }
.woocommerce ul.products li.product .woocommerce-loop-product__title,
.woocommerce ul.products li.product .price { padding-inline: 0; }
.woocommerce ul.products li.product .button { white-space: nowrap; }
.woocommerce-products-header .page-title,
.woocommerce-products-header__title { margin: 0 0 .25em !important; }
.woocommerce-products-header p { margin-top: 0; }
@media (max-width: 544px) {
  .woocommerce ul.products li.product .astra-shop-summary-wrap { padding-inline: 12px; }
  .woocommerce ul.products li.product .button { display: block; padding: 11px 8px !important; text-align: center; font-size: .92rem !important; }
  .woocommerce-loop-product__title { font-size: 1.25rem !important; }
  .sp-price-pending { font-size: .85rem; }
}
.woocommerce-loop-product__title {
  color: #fff !important;
  font-family: var(--sp-display) !important;
  font-size: 1.4rem !important;
  font-weight: 600 !important;
  line-height: 1.15 !important;
}
.ast-woo-product-category { display: none !important; }
.woocommerce .price, .woocommerce ul.products li.product .price,
.woocommerce-breadcrumb, .woocommerce-breadcrumb a { color: var(--sp-muted) !important; }
.woocommerce ul.products li.product .price { color: var(--sp-text) !important; font-weight: 600; }
.sp-price-pending { color: var(--sp-muted); font-size: .95rem; font-weight: 400; }
.woocommerce-info, .woocommerce-message, .woocommerce-error, .wc-empty-cart-message {
  background: var(--sp-card) !important;
  border-top-color: var(--sp-ember) !important;
  color: var(--sp-text) !important;
}
.woocommerce-info::before, .woocommerce-message::before { color: var(--sp-ember) !important; }
.single-product .product_title { font-size: clamp(2.3rem, 4vw, 3.4rem) !important; }
.single-product-category, .ast-woo-single-product-category { display: none !important; }
.single-product .product_meta { border-color: var(--sp-line) !important; color: var(--sp-muted); }

/* Equal card rows: the button sits at the bottom whatever the title length. */
.woocommerce ul.products li.product { display: flex; flex-direction: column; }
.woocommerce ul.products li.product .astra-shop-summary-wrap { display: flex; flex: 1; flex-direction: column; }
.woocommerce ul.products li.product .button { align-self: flex-start; margin-top: auto; min-height: 44px; }
.woocommerce ul.products li.product .price { margin-bottom: 14px; }
@media (max-width: 544px) {
  .woocommerce ul.products li.product .button { align-self: stretch; }
}
.single-product .summary p .button { display: inline-flex; align-items: center; min-height: 44px; margin-top: 4px; }
/* Keeps the placeholder from dominating; real product images use the full column. */
.single-product .woocommerce-product-gallery--without-images { max-width: 440px; }

/* Quote form photos */
.sp-photos { border: 1px solid var(--sp-line); border-radius: 6px; margin-bottom: 20px; padding: 18px; }
.sp-photos-title { font-size: .95rem; font-weight: 600; margin-bottom: 12px; }
.sp-photos-grid { display: grid; gap: 12px 18px; grid-template-columns: 1fr 1fr; }
.sp-photos-grid br { display: none; }
.sp-photos label { color: var(--sp-muted); font-weight: 400; }
.sp-photos input[type="file"] { color: var(--sp-text); display: block; font-size: .92rem; margin-top: 4px; max-width: 100%; width: 100%; }
.sp-photos input[type="file"]::file-selector-button { background: transparent; border: 1px solid #737980; border-radius: 4px; color: var(--sp-text); cursor: pointer; margin-right: 10px; padding: 8px 12px; }
.sp-hint { color: var(--sp-muted); font-size: .88rem; margin-top: 12px; }
.sp-hp { height: 0; left: -9999px; overflow: hidden; position: absolute; width: 0; }
@media (max-width: 544px) { .sp-photos-grid { grid-template-columns: 1fr; } }

/* ---- Colour pass: fire red, gold and denim blue, all taken from the logo ---- */
:root {
  --sp-red: #d9281c;
  --sp-gold: #f6b73c;
  --sp-navy: #10202f;
  --sp-navy-2: #18304a;
  --sp-fire: linear-gradient(90deg, #d9281c, #f2601f 55%, #f6b73c);
}
#masthead::after { background: var(--sp-fire); content: ""; display: block; height: 3px; }
.main-header-bar, .ast-primary-header-bar { border-bottom: 0 !important; }

.sp-hero, .sp-head {
  background:
    radial-gradient(760px 460px at 88% 30%, rgba(242, 96, 31, .34), transparent 68%),
    radial-gradient(620px 380px at 4% 100%, rgba(217, 40, 28, .22), transparent 70%),
    linear-gradient(135deg, #190b07, #08090a 62%) !important;
  border-bottom: 0;
}
.sp-hero-logo img { box-shadow: 0 18px 60px rgba(242, 96, 31, .35); }
.sp-eyebrow { color: var(--sp-gold) !important; }

.sp-strip { background: linear-gradient(90deg, #8f140c, #c2300f) !important; border-bottom: 0; padding-block: 20px; }
.sp-chips li { color: #fff; }
.sp-chips li:not(:last-child)::after { color: var(--sp-gold); }

.sp-hero, .sp-head, .sp-band { padding-block: clamp(48px, 6vw, 84px); }
.sp-head { padding-bottom: clamp(32px, 4vw, 52px); }

.sp-band > .wp-block-columns:not(.sp-steps) > .wp-block-column .sp-card { border-top: 3px solid var(--sp-red); }
.sp-band > .wp-block-columns:not(.sp-steps) > .wp-block-column:nth-child(2) .sp-card { border-top-color: var(--sp-ember); }
.sp-band > .wp-block-columns:not(.sp-steps) > .wp-block-column:nth-child(3) .sp-card { border-top-color: var(--sp-gold); }

.sp-band-alt { background: linear-gradient(135deg, var(--sp-navy), var(--sp-navy-2)) !important; border-block: 0; }
.sp-band-alt .sp-muted { color: #c9d3de !important; }
.sp-band-alt .sp-card { background: rgba(255, 255, 255, .05); }
.sp-steps .sp-card { background: transparent !important; border-top: 2px solid rgba(246, 183, 60, .55) !important; }
.sp-steps h3::before { color: var(--sp-gold); }

.sp-cta { background: linear-gradient(100deg, #e4391a, #f2601f 50%, #f6a52c) !important; }

.sp-footer { border-top: 0; position: relative; }
.sp-footer::before { background: var(--sp-fire); content: ""; height: 3px; left: 0; position: absolute; right: 0; top: 0; }
.sp-footer h2 { color: var(--sp-gold) !important; }

.woocommerce ul.products li.product:hover, .sp-card:hover { border-color: rgba(246, 183, 60, .6); }
.woocommerce-products-header__title::after {
  background: var(--sp-fire); content: ""; display: block; height: 4px; margin-top: 12px; width: 84px;
}

/* Quote form photos: core markup wraps the labels in a paragraph */
.sp-photos { background: rgba(255, 255, 255, .03); }
.sp-photos-grid > p { display: grid; gap: 12px 18px; grid-template-columns: 1fr 1fr; margin: 0; }
.sp-photos input[type="file"] { background: transparent !important; border: 0 !important; color: var(--sp-text) !important; padding: 0 !important; }
.sp-photos input[type="file"]::file-selector-button { background: #2a2e34; color: #fff; }
.wpcf7 textarea { height: 130px; }
@media (max-width: 544px) { .sp-photos-grid > p { grid-template-columns: 1fr; } }
.sp-photos-grid { display: block; }
@media (max-width: 720px) { .sp-chips li:not(:last-child)::after { content: none !important; } }
