/* Tilghman Rail. Graphite and signal orange (the logo's #e26700), condensed industrial type, a rail-and-sleeper rule as the recurring motif. */
:root {
  --ink: #16191c;
  --body: #383e44;
  --muted: #646b72;
  --paper: #f6f5f2;
  --panel: #ecebe6;
  --line: #d6d4cd;
  --card: #ffffff;
  --orange: #e26700;
  --orange-ink: #b45200;     /* text-safe orange on light ground */
  --graphite: #1c2024;
  --on-dark: #f2f1ee;
  --on-dark-muted: #b9bdc1;
  --display: "Barlow Condensed", "Arial Narrow", "Roboto Condensed", sans-serif;
  --sans: "Barlow", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #eeedea; --body: #c9ccd0; --muted: #9aa0a6; --paper: #121416; --panel: #1a1d20; --line: #2c3135;
    --card: #181b1e; --orange: #f07a16; --orange-ink: #ff9a45; --graphite: #0b0d0f; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ink: #eeedea; --body: #c9ccd0; --muted: #9aa0a6; --paper: #121416; --panel: #1a1d20; --line: #2c3135;
  --card: #181b1e; --orange: #f07a16; --orange-ink: #ff9a45; --graphite: #0b0d0f; color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--body); font: 400 1.0625rem/1.65 var(--sans); overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--orange-ink); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }
h1, h2, h3, h4 { color: var(--ink); font-family: var(--display); font-weight: 700; line-height: 1.05; text-wrap: balance; margin: 0; }
h1 { font-size: clamp(2.5rem, 6vw, 4.4rem); text-transform: uppercase; letter-spacing: 0.01em; }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.7rem); text-transform: uppercase; letter-spacing: 0.01em; }
h3, .h3 { font-size: 1.5rem; text-transform: none; letter-spacing: 0; }
p { margin: 0; max-width: 70ch; }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.eyebrow { font: 600 0.8rem/1.3 var(--sans); letter-spacing: 0.14em; text-transform: uppercase; color: var(--orange-ink); display: inline-flex; align-items: center; gap: 10px; }
.eyebrow::before { content: ""; width: 22px; height: 3px; background: var(--orange); flex: none; }
.eyebrow.on-dark { color: #ffb070; }
.lead { font-size: 1.2rem; }
.stack { display: grid; gap: 1.1rem; align-content: start; min-width: 0; }
.narrow { max-width: 760px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; background: var(--card); padding: 8px 12px; z-index: 50; }

/* Rail motif: two rails with sleepers */
.rail-line { height: 14px; background:
  linear-gradient(var(--orange), var(--orange)) 0 2px / 100% 2px no-repeat,
  linear-gradient(var(--orange), var(--orange)) 0 10px / 100% 2px no-repeat,
  repeating-linear-gradient(90deg, var(--on-dark-muted) 0 4px, transparent 4px 22px) 0 0 / 100% 14px no-repeat; opacity: .9; }

/* Top bar + header */
.topbar { background: var(--graphite); color: var(--on-dark-muted); font-size: 0.88rem; }
.topbar .wrap { display: flex; justify-content: space-between; gap: 1rem; min-height: 34px; align-items: center; flex-wrap: wrap; }
.topbar a { color: var(--on-dark); text-decoration: none; }
.topbar a:hover { color: #ffb070; }
.site-header { position: sticky; top: 0; z-index: 20; background: var(--paper); border-bottom: 3px solid var(--orange); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 72px; }
.brand { display: flex; align-items: center; text-decoration: none; }
.logo { width: auto; height: 34px; }
.nav { display: flex; align-items: center; gap: 1.4rem; }
.nav > a, .has-menu > a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 0.98rem; padding: 6px 0; }
.nav a[aria-current="page"], .has-menu.is-active > a { color: var(--orange-ink); box-shadow: inset 0 -2px 0 var(--orange); }
.has-menu { position: relative; }
.has-menu > a::after { content: " ▾"; font-size: 0.75em; }
.menu { position: absolute; left: -14px; top: 100%; min-width: 290px; background: var(--card); border: 1px solid var(--line); border-top: 3px solid var(--orange);
  box-shadow: 0 12px 30px rgba(0,0,0,.12); padding: 8px; display: none; }
.menu a { display: block; padding: 9px 12px; color: var(--ink); text-decoration: none; font-weight: 500; }
.menu a:hover, .menu a[aria-current="page"] { background: var(--panel); color: var(--orange-ink); box-shadow: none; }
.has-menu:hover .menu, .has-menu:focus-within .menu { display: block; }
.menu-toggle { display: none; background: none; border: 2px solid var(--ink); color: var(--ink); font: 600 0.95rem var(--sans); padding: 7px 14px; cursor: pointer; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--orange); color: #fff; border: 0; text-decoration: none;
  font: 700 1.05rem/1 var(--display); letter-spacing: 0.06em; text-transform: uppercase; padding: 15px 24px; cursor: pointer;
  clip-path: polygon(0 0, 100% 0, calc(100% - 10px) 100%, 0 100%); }
.btn:hover { background: var(--ink); color: var(--paper); }
.btn-sm { padding: 11px 20px 11px 16px; font-size: 0.98rem; }
.nav .btn { color: #fff; }
.nav .btn:hover { color: var(--paper); }
.btn-ghost { background: transparent; color: var(--on-dark); box-shadow: inset 0 0 0 2px var(--on-dark); clip-path: none; }
.btn-ghost:hover { background: var(--on-dark); color: var(--graphite); }
.btn[disabled] { opacity: .6; cursor: wait; }

/* Hero */
.hero { position: relative; background: var(--graphite); color: var(--on-dark); overflow: hidden; isolation: isolate; }
.hero-media, .hero-img { position: absolute; inset: 0; margin: 0; }
.hero-img img { width: 100%; height: 100%; object-fit: cover; object-position: 70% 40%; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: 0;
  background: linear-gradient(90deg, rgba(16,18,20,.94) 0%, rgba(16,18,20,.82) 42%, rgba(16,18,20,.25) 75%, rgba(16,18,20,.1) 100%); }
.hero-inner { position: relative; z-index: 1; padding-block: clamp(72px, 12vw, 150px); display: grid; gap: 1.3rem; }
.hero h1 { color: #fff; max-width: 16ch; }
.hero .lead { color: var(--on-dark-muted); max-width: 54ch; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: .4rem; }

/* Page head */
.page-head { background: var(--graphite); color: var(--on-dark); padding-block: clamp(44px, 7vw, 84px); position: relative; isolation: isolate; overflow: hidden; }
.page-head.has-photo::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--hero) center/cover no-repeat; opacity: .28; }
.page-head .wrap { display: grid; gap: 1rem; }
.page-head h1 { color: #fff; }
.page-head .lead { color: var(--on-dark-muted); max-width: 60ch; }
.page-head .eyebrow { color: #ffb070; }
.crumbs { font-size: 0.9rem; color: var(--on-dark-muted); }
.crumbs a { color: var(--on-dark); }

/* Sections */
.section { padding-block: clamp(56px, 8vw, 100px); }
.section.alt { background: var(--panel); }
.section-head { display: grid; gap: .7rem; margin-bottom: 2rem; }
.split { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.grid-2 { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 64px); }
.three { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(18px, 3vw, 32px); }
.types { margin-top: 2.2rem; }
.pillar { display: grid; gap: .7rem; align-content: start; padding-top: 1rem; border-top: 3px solid var(--ink); }
.pillar .num { font: 700 1rem var(--display); color: var(--orange-ink); letter-spacing: .1em; }
.arrow { font-weight: 600; text-decoration: none; }
.arrow::after { content: " →"; }

.photo { margin: 0; }
.photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--panel); }
.photo.tall img { aspect-ratio: 4 / 5; }
.photo figcaption { font-size: 0.88rem; color: var(--muted); margin-top: .5rem; }
.card-img { margin: 0; }
.card-img img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; background: var(--panel); }

.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 28px); }
.card { background: var(--card); border: 1px solid var(--line); text-decoration: none; color: var(--body); display: grid; grid-template-rows: auto 1fr; transition: transform .15s, box-shadow .15s; }
.card:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(0,0,0,.12); color: var(--body); }
.card-body { padding: 18px 20px 22px; display: grid; gap: .55rem; align-content: start; border-top: 3px solid var(--orange); }
.more { font-weight: 600; color: var(--orange-ink); }
.more::after { content: " →"; }

.spec-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 28px); }
.spec-card { background: var(--card); border: 1px solid var(--line); display: grid; grid-template-columns: 40% 1fr; }
.spec-img { margin: 0; }
.spec-img img { width: 100%; height: 100%; object-fit: cover; min-height: 200px; }
.spec-body { padding: 18px 20px; display: grid; gap: .7rem; align-content: start; }
.gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(12px, 2vw, 20px); margin-top: 2rem; }

.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: .55rem; }
.ticks li { position: relative; padding-left: 1.6rem; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .62em; width: 12px; height: 6px; border-left: 3px solid var(--orange); border-bottom: 3px solid var(--orange); transform: rotate(-45deg); }

.customers { background: var(--graphite); color: var(--on-dark); padding-block: 30px; }
.customers .wrap { display: grid; gap: 14px; }
.customers .eyebrow { color: var(--on-dark-muted); letter-spacing: .1em; }
.customers ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px 34px; }
.customers li { font: 700 1.35rem/1.2 var(--display); text-transform: uppercase; letter-spacing: .04em; color: var(--on-dark); }

.faq { display: grid; gap: 10px; }
.faq details { background: var(--card); border: 1px solid var(--line); padding: 14px 18px; }
.faq summary { cursor: pointer; font-weight: 600; color: var(--ink); }
.faq details p { margin-top: .6rem; }

.map iframe { width: 100%; aspect-ratio: 4 / 3; border: 0; background: var(--panel); }

/* Enquiry */
.cta-band { background: var(--graphite); color: var(--on-dark); padding-block: clamp(56px, 8vw, 96px); }
.cta-band .wrap { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 64px); }
.cta-band h2 { color: #fff; }
.cta-band p { color: var(--on-dark-muted); }
.cta-band .eyebrow { color: #ffb070; }
.cta-band a { color: #ffb070; }
.contact-lines { display: grid; gap: .7rem; margin: .4rem 0 0; }
.contact-lines div { display: grid; grid-template-columns: 90px 1fr; gap: 10px; }
.contact-lines dt { font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; color: var(--on-dark-muted); padding-top: .2em; }
.contact-lines dd { margin: 0; }
.section .contact-lines dt { color: var(--muted); }
.contact-lines.big dd { font-size: 1.15rem; color: var(--ink); }
.enquiry { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; background: var(--card); color: var(--body); padding: clamp(18px, 3vw, 30px); border-top: 4px solid var(--orange); min-width: 0; }
.enquiry label { display: grid; gap: 6px; font-weight: 600; font-size: .92rem; color: var(--ink); min-width: 0; }
.enquiry .full { grid-column: 1 / -1; }
.enquiry input, .enquiry select, .enquiry textarea { font: 400 1rem var(--sans); color: var(--ink); background: var(--paper); border: 1px solid var(--line); padding: 11px 12px; width: 100%; border-radius: 0; }
.enquiry textarea { min-height: 130px; resize: vertical; }
.enquiry .btn { grid-column: 1 / -1; justify-self: start; }
.enquiry .hp { position: absolute; left: -9999px; }
.form-status { grid-column: 1 / -1; font-weight: 600; color: var(--ink); }

/* Footer */
.site-footer { background: var(--graphite); color: var(--on-dark-muted); border-top: 1px solid #2c3135; }
.site-footer .cols { display: grid; grid-template-columns: 1.4fr 1fr .8fr 1fr; gap: 32px; padding-block: 48px; }
.site-footer h4 { color: var(--on-dark); font-size: 1.1rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: .8rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: .45rem; }
.site-footer a { color: var(--on-dark); text-decoration: none; }
.site-footer a:hover { color: #ffb070; }
.site-footer .logo { height: 30px; }
.legal { border-top: 1px solid #2c3135; font-size: .88rem; }
.legal .wrap { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding-block: 18px; }

@media (max-width: 980px) {
  .menu-toggle { display: inline-block; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--paper); border-bottom: 3px solid var(--orange);
    flex-direction: column; align-items: stretch; gap: 0; padding: 8px var(--gutter) 18px; max-height: calc(100vh - 110px); overflow: auto; }
  .nav.open { display: flex; }
  .nav > a, .has-menu > a { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .has-menu > a::after { content: ""; }
  .menu { position: static; display: block; border: 0; box-shadow: none; padding: 0 0 6px 14px; min-width: 0; background: transparent; }
  .menu a { padding: 8px 0; }
  .nav .btn { margin-top: 14px; align-self: flex-start; }
  .site-header .wrap { position: relative; }
  .cards, .three { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .site-footer .cols { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .split, .grid-2, .cta-band .wrap, .spec-grid { grid-template-columns: 1fr; }
  .cards, .three, .gallery { grid-template-columns: 1fr; }
  .spec-card { grid-template-columns: 1fr; }
  .spec-img img { aspect-ratio: 3 / 2; min-height: 0; }
  .enquiry { grid-template-columns: 1fr; }
  .site-footer .cols { grid-template-columns: 1fr; }
  .topbar .wrap > span:first-child { display: none; }
  .hero::after { background: linear-gradient(180deg, rgba(16,18,20,.75), rgba(16,18,20,.92)); }
  .photo.tall img { aspect-ratio: 4 / 3; }
  .logo { height: 28px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
