/* ============================================================
   Rehman Michael Accountants — design tokens & shared styles
   Palette: deep navy (trust/authority) + muted brass (premium,
   finance) on a warm paper ground — the classic professional-
   services register, tuned for a Leeds chartered accountancy
   practice that leads with tax investigation expertise.
   ============================================================ */

:root {
  --navy-950: #0a1c2c;
  --navy-900: #12293e;
  --navy-800: #1b3a56;
  --navy-700: #274d6e;
  --brass-600: #a8793a;
  --brass-500: #bd8f4f;
  --brass-100: #f1e3cc;
  --paper: #f7f4ee;
  --paper-raised: #ffffff;
  --ink: #1c2430;
  --ink-soft: #52596a;
  --ink-faint: #7c8296;
  --line: #e2dcca;
  --line-dark: #2a3f57;
  --danger: #9c3b2e;

  --font-display: 'Spectral', 'Iowan Old Style', 'Palatino Linotype', Georgia, serif;
  --font-body: 'Public Sans', 'Segoe UI', system-ui, -apple-system, sans-serif;

  --container: 1120px;
  --radius: 4px;
  --shadow-card: 0 1px 2px rgba(10, 28, 44, 0.06), 0 8px 24px -12px rgba(10, 28, 44, 0.18);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 0.5em;
  color: var(--navy-950);
  text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 4.2vw, 3.4rem); font-weight: 500; }
h2 { font-size: clamp(1.6rem, 2.6vw, 2.2rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; max-width: 68ch; }
p.lede { font-size: 1.15rem; color: var(--ink-soft); max-width: 56ch; }

a { color: var(--navy-800); }
a.plain { color: inherit; text-decoration: none; }

.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--brass-600);
  margin-bottom: 0.9em;
}

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

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--brass-600); color: #fff; }
.btn-primary:hover { background: var(--brass-500); box-shadow: 0 8px 20px -8px rgba(168, 121, 58, 0.6); }
.btn-outline { background: transparent; border-color: rgba(255,255,255,0.35); color: #fff; }
.btn-outline:hover { border-color: #fff; background: rgba(255,255,255,0.08); }
.btn-outline-dark { background: transparent; border-color: var(--navy-800); color: var(--navy-900); }
.btn-outline-dark:hover { background: var(--navy-950); color: #fff; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(247, 244, 238, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  height: 84px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-mark {
  width: 40px; height: 40px; border-radius: 3px;
  background: linear-gradient(155deg, var(--navy-900), var(--navy-950));
  display: flex; align-items: center; justify-content: center;
  color: var(--brass-500); font-family: var(--font-display); font-weight: 600; font-size: 1.15rem;
  flex-shrink: 0;
}
.brand-text { line-height: 1.2; }
.brand-text .name { display: block; font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; color: var(--navy-950); }
.brand-text .sub { display: block; font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-faint); }

nav.main-nav { display: flex; align-items: center; gap: 34px; }
nav.main-nav a {
  font-size: 0.94rem; font-weight: 500; text-decoration: none; color: var(--ink);
  position: relative; padding: 4px 0;
}
nav.main-nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px;
  background: var(--brass-600); transform: scaleX(0); transform-origin: left; transition: transform 0.2s ease;
}
nav.main-nav a:hover::after, nav.main-nav a[aria-current="page"]::after { transform: scaleX(1); }
nav.main-nav a[aria-current="page"] { color: var(--navy-950); font-weight: 600; }

.header-cta { display: flex; align-items: center; gap: 18px; }
.header-phone { display: none; font-size: 0.92rem; font-weight: 600; color: var(--navy-900); text-decoration: none; }
.header-phone svg { vertical-align: -3px; margin-right: 6px; }

/* Client portal login — a call-to-action inside the nav list itself (not just the header-cta
   row) so it's reachable from the hamburger menu on mobile too, not only on wide screens. */
nav.main-nav a.nav-login {
  background: var(--brass-600);
  color: #fff;
  padding: 10px 20px;
  border-radius: 6px;
  font-weight: 600;
  border-bottom: none;
  text-align: center;
  white-space: nowrap;
}
nav.main-nav a.nav-login:hover { background: var(--brass-500); color: #fff; }
nav.main-nav a.nav-login::after { content: none; }

.nav-toggle {
  display: none; background: none; border: 1px solid var(--line); border-radius: var(--radius);
  width: 42px; height: 42px; align-items: center; justify-content: center; cursor: pointer;
}

@media (min-width: 860px) {
  .header-phone { display: inline-flex; align-items: center; }
}
@media (max-width: 859px) {
  nav.main-nav {
    /* top+height (not bottom/inset) because .site-header's backdrop-filter makes it the
       containing block for this fixed element — "bottom: 0" would resolve against the
       84px-tall header box, not the viewport, collapsing the panel's height. */
    position: fixed; top: 84px; left: 0; right: 0; height: calc(100vh - 84px);
    background: var(--paper);
    flex-direction: column; align-items: flex-start; gap: 4px; padding: 20px 24px;
    overflow-y: auto;
    transform: translateY(-8px); opacity: 0; pointer-events: none; transition: all 0.18s ease;
    border-top: 1px solid var(--line);
  }
  nav.main-nav.open { transform: translateY(0); opacity: 1; pointer-events: auto; }
  nav.main-nav a { width: 100%; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav-toggle { display: flex; }
}

/* ---------- Hero ---------- */
.hero {
  background: radial-gradient(1100px 480px at 82% -10%, rgba(189, 143, 79, 0.18), transparent 60%), var(--navy-950);
  color: #fff;
  padding: 96px 0 84px;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(180deg, transparent, rgba(0,0,0,0.5) 40%, transparent);
  pointer-events: none;
}
.hero .container { position: relative; z-index: 1; }
.hero-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 56px; align-items: center; }
.hero .eyebrow { color: var(--brass-500); }
.hero h1 { color: #fff; }
.hero p.lede { color: rgba(255,255,255,0.78); }
.hero-actions { display: flex; gap: 14px; margin-top: 30px; flex-wrap: wrap; }

.hero-panel {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 6px;
  padding: 28px;
}
.hero-panel h3 { color: #fff; font-size: 1rem; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 18px; }
.hero-fact { display: flex; justify-content: space-between; padding: 12px 0; border-top: 1px solid rgba(255,255,255,0.12); }
.hero-fact:first-of-type { border-top: none; }
.hero-fact .label { color: rgba(255,255,255,0.65); font-size: 0.88rem; }
.hero-fact .value { color: #fff; font-weight: 600; font-family: var(--font-display); }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
}

/* ---------- Page hero (inner pages) ---------- */
.page-hero { background: var(--navy-950); color: #fff; padding: 64px 0 56px; }
.page-hero .eyebrow { color: var(--brass-500); }
.page-hero h1 { color: #fff; }
.page-hero p.lede { color: rgba(255,255,255,0.78); }
.breadcrumb { font-size: 0.85rem; color: rgba(255,255,255,0.55); margin-bottom: 18px; }
.breadcrumb a { color: rgba(255,255,255,0.75); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

/* ---------- Sections ---------- */
section { padding: 88px 0; }
section.tight { padding: 56px 0; }
section.alt { background: var(--paper-raised); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
section.navy { background: var(--navy-950); color: #fff; }
section.navy h2, section.navy .eyebrow { color: #fff; }
section.navy .eyebrow { color: var(--brass-500); }
section.navy p { color: rgba(255,255,255,0.78); }

.section-head { max-width: 640px; margin-bottom: 48px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

/* ---------- Trust bar ---------- */
.trust-bar { background: var(--paper-raised); border-bottom: 1px solid var(--line); }
.trust-bar .container { display: flex; flex-wrap: wrap; gap: 36px; align-items: center; justify-content: space-between; padding: 22px 24px; }
.trust-item { display: flex; align-items: center; gap: 10px; font-size: 0.88rem; color: var(--ink-soft); font-weight: 600; }
.trust-item svg { color: var(--brass-600); flex-shrink: 0; }

/* ---------- Cards / grid ---------- */
.grid { display: grid; gap: 28px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 860px) { .grid-3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 30px;
  box-shadow: var(--shadow-card);
}
.card .icon {
  width: 46px; height: 46px; border-radius: 6px;
  background: var(--brass-100); color: var(--brass-600);
  display: flex; align-items: center; justify-content: center; margin-bottom: 18px;
}
.card h3 { margin-bottom: 8px; }
.card p { margin-bottom: 0; font-size: 0.95rem; color: var(--ink-soft); }
.card a.card-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 14px; font-size: 0.9rem; font-weight: 600; text-decoration: none; color: var(--navy-800); }

/* ---------- Spotlight (Tax Investigations callout) ---------- */
.spotlight {
  display: grid; grid-template-columns: 1fr 1fr; gap: 0;
  border-radius: 8px; overflow: hidden; border: 1px solid var(--line-dark);
}
.spotlight-copy { background: var(--navy-950); color: #fff; padding: 52px; display: flex; flex-direction: column; justify-content: center; }
.spotlight-copy .eyebrow { color: var(--brass-500); }
.spotlight-copy h2 { color: #fff; }
.spotlight-copy p { color: rgba(255,255,255,0.78); }
.spotlight-visual {
  background:
    radial-gradient(420px 320px at 30% 20%, rgba(189,143,79,0.35), transparent 60%),
    linear-gradient(160deg, var(--navy-800), var(--navy-950));
  position: relative; min-height: 320px;
  display: flex; align-items: center; justify-content: center;
}
.spotlight-visual .badge-ring {
  width: 180px; height: 180px; border-radius: 50%;
  border: 1.5px solid rgba(189,143,79,0.55);
  display: flex; align-items: center; justify-content: center;
  color: var(--brass-500);
}
.spotlight-visual .badge-ring .inner {
  width: 130px; height: 130px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.25);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  font-family: var(--font-display); text-align: center;
}
.spotlight-visual .inner strong { font-size: 1.8rem; color: #fff; }
.spotlight-visual .inner span { font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase; color: rgba(255,255,255,0.6); }
@media (max-width: 780px) { .spotlight { grid-template-columns: 1fr; } .spotlight-copy { padding: 40px 28px; } }

/* ---------- Photo placeholder (no stock photography used — see README) ---------- */
.photo-placeholder {
  border-radius: 6px;
  min-height: 320px;
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.035) 0 2px, transparent 2px 26px),
    linear-gradient(150deg, var(--navy-800), var(--navy-950));
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.55);
  text-align: center; padding: 24px;
  border: 1px solid var(--line-dark);
}
.photo-placeholder .tag {
  font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase;
  border: 1px solid rgba(255,255,255,0.3); border-radius: 999px; padding: 6px 14px;
}

/* ---------- Process / numbered steps ---------- */
.steps { counter-reset: step; display: grid; gap: 22px; }
.step { display: grid; grid-template-columns: 56px 1fr; gap: 20px; padding: 24px 0; border-top: 1px solid var(--line); }
.step:first-child { border-top: none; padding-top: 0; }
.step .num {
  counter-increment: step; font-family: var(--font-display); font-size: 1.4rem; color: var(--brass-600); font-weight: 600;
}
.step .num::before { content: counter(step, decimal-leading-zero); }

/* ---------- Team ---------- */
.person { display: flex; gap: 18px; align-items: flex-start; }
.person .avatar {
  width: 64px; height: 64px; border-radius: 50%; flex-shrink: 0;
  background: linear-gradient(160deg, var(--navy-700), var(--navy-950));
  color: var(--brass-500); display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 600; font-size: 1.15rem;
}
.person .role { font-size: 0.85rem; color: var(--brass-600); font-weight: 600; margin-bottom: 4px; }

/* ---------- Quote / value strip ---------- */
.value-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; text-align: center; }
.value-strip .stat { font-family: var(--font-display); font-size: 2.1rem; color: var(--navy-950); font-weight: 600; }
.value-strip .label { font-size: 0.85rem; color: var(--ink-soft); }
section.navy .value-strip .stat { color: #fff; }
@media (max-width: 760px) { .value-strip { grid-template-columns: 1fr 1fr; } }

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(120deg, var(--brass-600), var(--brass-500));
  color: #fff; border-radius: 8px; padding: 48px 52px;
  display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap;
}
.cta-band h2 { color: #fff; margin-bottom: 6px; }
.cta-band p { color: rgba(255,255,255,0.9); margin-bottom: 0; }
.cta-band .btn-primary { background: var(--navy-950); }
.cta-band .btn-primary:hover { background: var(--navy-900); }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.contact-detail { display: flex; gap: 16px; padding: 18px 0; border-top: 1px solid var(--line); }
.contact-detail:first-child { border-top: none; }
.contact-detail .icon { width: 40px; height: 40px; border-radius: 6px; background: var(--brass-100); color: var(--brass-600); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.contact-detail h4 { margin: 0 0 4px; font-family: var(--font-body); font-size: 0.95rem; }
.contact-detail p { margin: 0; font-size: 0.95rem; }
.map-frame { border-radius: 6px; overflow: hidden; border: 1px solid var(--line); }
.map-frame iframe { display: block; width: 100%; height: 100%; min-height: 320px; border: 0; }

form.enquiry { display: grid; gap: 16px; }
form.enquiry label { font-size: 0.85rem; font-weight: 600; color: var(--ink-soft); display: block; margin-bottom: 6px; }
form.enquiry input, form.enquiry select, form.enquiry textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius);
  font-family: var(--font-body); font-size: 0.95rem; background: #fff; color: var(--ink);
}
form.enquiry input:focus, form.enquiry select:focus, form.enquiry textarea:focus {
  outline: 2px solid var(--brass-500); outline-offset: 1px;
}
form.enquiry .row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 620px) { .contact-grid, form.enquiry .row-2 { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
footer.site-footer { background: var(--navy-950); color: rgba(255,255,255,0.75); padding: 64px 0 28px; }
footer.site-footer h4 { color: #fff; font-family: var(--font-body); font-size: 0.85rem; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 16px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,0.12); }
.footer-grid a { color: rgba(255,255,255,0.75); text-decoration: none; font-size: 0.92rem; display: block; margin-bottom: 10px; }
.footer-grid a:hover { color: #fff; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 22px; font-size: 0.82rem; color: rgba(255,255,255,0.5); flex-wrap: wrap; gap: 12px; }
.footer-bottom a { color: rgba(255,255,255,0.5); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- Utility ---------- */
.mt-0 { margin-top: 0; }
.text-center { text-align: center; margin-left: auto; margin-right: auto; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link {
  position: absolute; left: -9999px; top: 0; background: var(--navy-950); color: #fff; padding: 12px 18px; z-index: 100;
}
.skip-link:focus { left: 12px; top: 12px; }

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