/*
Theme Name: The Machine Man
Theme URI: https://themachineman.co.uk
Author: The Machine Man
Description: A premium, accessible theme for a nationwide sewing machine repair specialist.
Version: 1.0.0
Text Domain: the-machine-man
*/

:root {
  --brand-black: #06080b;
  --brand-charcoal: #121820;
  --brand-blue: #075cff;
  --brand-cyan: #00d8ff;
  --brand-silver: #b9c3cf;
  --brand-white: #f7f9fc;
  --text-primary: #f7f9fc;
  --text-secondary: #c0cad6;
  --line: rgba(185, 195, 207, .24);
  --shadow: 0 18px 54px rgba(0, 0, 0, .28);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--brand-black); color: var(--text-primary); font-family: "Arial", "Helvetica Neue", sans-serif; font-size: 18px; line-height: 1.55; }
a { color: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid var(--brand-cyan); outline-offset: 3px; }
.screen-reader-text { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
.site-shell { overflow: hidden; }
.wrap { width: min(1180px, calc(100% - 48px)); margin: 0 auto; }

.site-header { position: relative; z-index: 2; background: rgba(6, 8, 11, .97); border-bottom: 1px solid var(--line); }
.header-inner { min-height: 104px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 15px; color: var(--brand-white); text-decoration: none; font-weight: 800; letter-spacing: .035em; }
.custom-logo-link { display: block; width: 76px; height: 76px; border-radius: 50%; padding: 3px; background: #1d242d; flex: 0 0 auto; }
.custom-logo { width: 100%; height: 100%; object-fit: contain; display: block; }
.brand-fallback { width: 76px; height: 76px; display: grid; place-items: center; border: 1px solid var(--brand-blue); border-radius: 50%; color: var(--brand-cyan); font-size: 13px; line-height: 1.1; text-align: center; }
.brand-title { font-size: 16px; text-transform: uppercase; }
.brand-title small { display: block; margin-top: 2px; font-size: 11px; color: var(--text-secondary); letter-spacing: .12em; }
.menu { display: flex; gap: 26px; list-style: none; padding: 0; margin: 0; }
.menu a { color: var(--text-secondary); text-decoration: none; font-size: 15px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.menu a:hover, .menu .current-menu-item a { color: var(--brand-cyan); }
.menu-toggle { display: none; }

.hero { background: linear-gradient(116deg, #080b10 0%, #111925 100%); border-bottom: 1px solid var(--line); }
.hero-grid { min-height: 620px; display: grid; align-items: center; grid-template-columns: 1.05fr .95fr; gap: clamp(40px, 7vw, 100px); }
.eyebrow { display: inline-flex; align-items: center; gap: 11px; color: var(--brand-cyan); font-weight: 800; font-size: 13px; letter-spacing: .13em; text-transform: uppercase; }
.eyebrow::before { content: ""; width: 34px; height: 2px; background: var(--brand-blue); }
h1, h2, h3 { margin: 0; line-height: 1.08; letter-spacing: -.025em; }
h1 { margin-top: 15px; font-size: clamp(48px, 6vw, 78px); }
h2 { font-size: clamp(34px, 4vw, 52px); }
h3 { font-size: 25px; }
.hero-subtitle { margin: 18px 0 0; color: var(--brand-silver); font-size: clamp(20px, 2.1vw, 26px); font-weight: 600; }
.hero-copy { max-width: 580px; margin: 20px 0 0; color: var(--text-secondary); }
.button-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.button { display: inline-flex; min-height: 55px; align-items: center; justify-content: center; padding: 13px 24px; border: 1px solid var(--brand-blue); background: var(--brand-blue); color: white; text-decoration: none; text-transform: uppercase; letter-spacing: .08em; font-size: 14px; font-weight: 800; transition: background .18s ease, border-color .18s ease; }
.button:hover { background: #004ada; border-color: #004ada; }
.button--secondary { background: transparent; color: var(--brand-white); border-color: #52606e; }
.button--secondary:hover { border-color: var(--brand-cyan); background: rgba(0, 216, 255, .08); }
.hero-media { min-height: 430px; position: relative; background: #0c1118; border: 1px solid #344151; box-shadow: var(--shadow); }
.hero-media::before { content: ""; position: absolute; width: 62px; height: 62px; border-top: 3px solid var(--brand-cyan); border-left: 3px solid var(--brand-cyan); top: -1px; left: -1px; }
.hero-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.media-empty { display: grid; place-items: center; min-height: 100%; padding: 30px; color: #7d8b9a; text-align: center; font-size: 14px; letter-spacing: .07em; text-transform: uppercase; }
.media-empty span { border: 1px dashed #4b5967; padding: 14px 18px; }

.trust-strip { padding: 19px 0; background: var(--brand-blue); color: white; text-align: center; font-size: clamp(15px, 2vw, 20px); font-weight: 800; letter-spacing: .11em; }
.section { padding: clamp(68px, 9vw, 120px) 0; }
.section--light { background: #f4f7fa; color: #101820; }
.section--light .eyebrow { color: #0458e9; }
.section--light .section-intro, .section--light .service-card p { color: #4c5866; }
.section-intro { max-width: 650px; color: var(--text-secondary); margin: 20px 0 0; font-size: 19px; }
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 48px; }
.service-card { padding: 32px 26px; border-top: 3px solid var(--brand-blue); background: white; box-shadow: 0 8px 20px rgba(19, 31, 42, .08); }
.service-number { color: var(--brand-blue); font-size: 13px; font-weight: 800; letter-spacing: .13em; }
.service-card h3 { margin-top: 18px; }
.service-card p { margin: 12px 0 0; font-size: 16px; }
.nationwide { background: var(--brand-charcoal); border-block: 1px solid var(--line); }
.two-column { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 8vw, 120px); align-items: center; }
.check-list { list-style: none; padding: 0; margin: 28px 0 0; }
.check-list li { position: relative; padding: 12px 0 12px 32px; border-bottom: 1px solid var(--line); }
.check-list li::before { content: "✓"; position: absolute; left: 0; color: var(--brand-cyan); font-weight: 900; }
.contact-panel { background: #0f151d; border: 1px solid #344151; padding: clamp(30px, 5vw, 54px); }
.contact-panel h2 { font-size: clamp(31px, 4vw, 45px); }
.contact-email { display: inline-block; margin-top: 22px; color: var(--brand-cyan); font-size: clamp(21px, 3vw, 29px); font-weight: 700; }
.contact-panel p { color: var(--text-secondary); }

.page-header { padding: 90px 0 62px; background: #0d131b; border-bottom: 1px solid var(--line); }
.page-header p { max-width: 650px; margin: 16px 0 0; color: var(--text-secondary); }
.entry-content { padding: 72px 0; }
.entry-content > * { max-width: 820px; }
.entry-content a { color: var(--brand-blue); }
.blog-list { display: grid; gap: 18px; }
.post-card { padding: clamp(25px, 4vw, 42px); background: white; border-left: 3px solid var(--brand-blue); box-shadow: 0 8px 20px rgba(19, 31, 42, .08); }
.post-card h2 { margin: 6px 0 14px; font-size: clamp(27px, 3vw, 39px); }
.post-card h2 a { color: #101820; text-decoration: none; }
.post-card h2 a:hover, .post-link { color: var(--brand-blue); }
.post-card p, .post-card div { color: #4c5866; }
.post-meta { margin: 0; color: #607080 !important; font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.post-link { display: inline-block; margin-top: 18px; font-size: 14px; font-weight: 800; text-decoration: none; text-transform: uppercase; letter-spacing: .06em; }
.post-content { color: var(--text-primary); }
.blog-hero { background: linear-gradient(116deg, #080b10 0%, #111925 100%); border-bottom: 1px solid var(--line); }
.blog-hero-grid { min-height: 390px; display: grid; grid-template-columns: 1.15fr .85fr; align-items: center; gap: clamp(40px, 7vw, 100px); padding: 65px 0; }
.blog-hero h1 { margin-top: 15px; font-size: clamp(43px, 5.5vw, 68px); }
.blog-hero p { max-width: 670px; margin: 20px 0 0; color: var(--text-secondary); font-size: 19px; }
.blog-hero-media { min-height: 260px; position: relative; border: 1px solid #344151; box-shadow: var(--shadow); }
.blog-hero-media::before { content: ""; position: absolute; z-index: 1; width: 52px; height: 52px; border-top: 3px solid var(--brand-cyan); border-left: 3px solid var(--brand-cyan); top: -1px; left: -1px; }
.blog-hero-media img { display: block; width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }
.blog-empty { margin-top: 32px; padding: 28px; border-left: 3px solid var(--brand-blue); background: white; color: #4c5866; }
.form-layout { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 34px; }
.form-field { display: grid; gap: 7px; }
.form-field--full { grid-column: 1 / -1; }
label, legend { font-weight: 700; font-size: 15px; }
input, textarea, select { width: 100%; min-height: 50px; padding: 12px 14px; border: 1px solid #abb8c5; background: white; color: #101820; font: inherit; font-size: 16px; }
textarea { min-height: 150px; resize: vertical; }
fieldset { grid-column: 1 / -1; border: 0; padding: 0; margin: 4px 0; }
.radios { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 8px; }
.radios label { display: flex; align-items: center; gap: 7px; font-weight: 400; }
.radios input { width: 18px; min-height: auto; accent-color: var(--brand-blue); }
.form-notice { padding: 13px 16px; margin-bottom: 22px; background: #e7f8ed; color: #154a28; border-left: 4px solid #168442; }
.form-notice--error { background: #fff0f0; color: #812d2d; border-color: #d73e3e; }

.site-footer { padding: 60px 0 26px; background: #050608; border-top: 1px solid var(--line); }
.footer-grid { display: grid; grid-template-columns: 1.2fr .8fr .8fr; gap: 40px; }
.footer-brand .custom-logo-link { width: 100px; height: 100px; }
.footer-brand p, .footer-nav a { color: var(--text-secondary); font-size: 16px; }
.footer-nav { list-style: none; padding: 0; margin: 0; }
.footer-nav li { margin: 7px 0; }
.footer-nav a { text-decoration: none; }
.socials { display: flex; flex-wrap: wrap; gap: 10px; }
.socials a { display: grid; place-items: center; width: 42px; height: 42px; border: 1px solid #506070; color: var(--brand-white); }
.socials a:hover { color: var(--brand-cyan); border-color: var(--brand-cyan); }
.socials svg { width: 19px; height: 19px; fill: currentColor; }
.copyright { margin-top: 48px; padding-top: 20px; border-top: 1px solid var(--line); color: #8895a3; font-size: 13px; }

@media (max-width: 760px) {
  body { font-size: 17px; }
  .wrap { width: min(100% - 32px, 1180px); }
  .header-inner { min-height: 90px; }
  .custom-logo-link { width: 62px; height: 62px; }
  .brand-title { font-size: 13px; }
  .menu-toggle { display: block; border: 1px solid #52606e; background: transparent; color: white; padding: 10px 12px; font: inherit; font-size: 13px; font-weight: 700; text-transform: uppercase; }
  .main-navigation { display: none; position: absolute; top: 90px; left: 0; width: 100%; padding: 12px 16px 20px; background: #080b10; border-bottom: 1px solid var(--line); }
  .main-navigation.is-open { display: block; }
  .menu { display: grid; gap: 0; }
  .menu a { display: block; padding: 13px 0; }
  .hero-grid, .two-column, .footer-grid, .blog-hero-grid { grid-template-columns: 1fr; }
  .hero-grid { padding: 62px 0; }
  .hero-media { min-height: 290px; }
  .services-grid { grid-template-columns: 1fr; }
  .form-layout { grid-template-columns: 1fr; }
}
