/* Lucy Carroll Consulting — shared styles */

@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@500;600;700;800&family=Inter:wght@300;400;500;600&display=swap');

:root{
  /* Brand palette (unchanged) */
  --navy: #1e3a5f;
  --navy-2: #2c5382;
  --blue-mid: #4a7aa8;
  --blue-pale: #eef4fa;
  --ink: #1f2d3d;
  --muted: #5c6b7a;
  --paper: #ffffff;
  --line: #dde5ee;

  /* Accessibility companions to the palette:
     same blue, slightly deeper, for small text (meets 4.5:1 on white and pale blue)
     and a visible border colour for form fields (meets 3:1) */
  --blue-text: #3b6a96;
  --field-border: #7a90a8;
  --focus: #2c5382;
  --focus-on-dark: #ffffff;

  --max: 1160px;
  --header-h: 72px;
  --radius: 8px;
  --radius-sm: 4px;
  --shadow-soft: 0 1px 2px rgba(30,58,95,.06), 0 6px 18px rgba(30,58,95,.07);
}

*, *::before, *::after{ box-sizing:border-box; }
html{
  scroll-behavior:smooth;
  -webkit-text-size-adjust:100%;
  color-scheme:light;
}
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior:auto; }
  *, *::before, *::after{ animation-duration:.001ms !important; transition-duration:.001ms !important; }
}

body{
  margin:0;
  background:var(--paper);
  color:var(--ink);
  font-family:'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size:17px;
  line-height:1.65;
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}
img{ max-width:100%; }
p{ text-wrap:pretty; }

/* Anchors land below the sticky header */
[id]{ scroll-margin-top:calc(var(--header-h) + 16px); }

/* ---------- Accessibility helpers ---------- */
.sr-only{
  position:absolute !important;
  width:1px; height:1px;
  margin:-1px; padding:0;
  overflow:hidden;
  clip:rect(0,0,0,0);
  white-space:nowrap;
  border:0;
}
.skip{
  position:absolute; left:16px; top:-100px;
  background:var(--navy); color:#fff;
  padding:12px 18px; z-index:200;
  border-radius:var(--radius-sm);
  font-weight:600;
  text-decoration:none;
}
.skip:focus{ top:16px; }

:focus{ outline:none; }
:focus-visible{
  outline:3px solid var(--focus);
  outline-offset:3px;
  border-radius:2px;
}
.site-footer :focus-visible,
.nav-cta:focus-visible,
.hero-banner :focus-visible,
.button:focus-visible{
  outline-color:var(--focus-on-dark);
}
.button:focus-visible,
.nav-cta:focus-visible{
  /* white ring with a navy halo so it reads on any background */
  box-shadow:0 0 0 3px var(--navy-2);
  outline-offset:2px;
}

.container{
  max-width:var(--max);
  margin:0 auto;
  padding:0 clamp(20px, 4vw, 28px);
}

h1,h2,h3{
  font-family:'Manrope', system-ui, sans-serif;
  font-weight:700;
  margin:0;
  color:var(--ink);
  letter-spacing:-0.01em;
  line-height:1.2;
  text-wrap:balance;
}

a{ color:var(--navy-2); text-underline-offset:3px; }
a:hover{ color:var(--navy); }

.eyebrow{
  font-family:'Inter', sans-serif;
  font-size:15px;
  font-weight:600;
  letter-spacing:0.1em;
  text-transform:uppercase;
  color:var(--blue-text);
  margin:0 0 10px;
  line-height:1.4;
}
.eyebrow-big{
  font-family:'Manrope', sans-serif;
  font-size:clamp(26px, 3.2vw, 32px);
  font-weight:800;
  letter-spacing:0.005em;
  text-transform:none;
  color:var(--navy);
  margin:0 0 6px;
  line-height:1.2;
}

/* ---------- Header ---------- */
.site-header{
  position:sticky;
  top:0;
  z-index:100;
  background:#fff;   /* no backdrop-filter: it would trap the fixed mobile menu inside the header */
  border-bottom:1px solid var(--line);
}
.nav{
  display:flex;
  align-items:center;
  justify-content:space-between;
  min-height:var(--header-h);
  gap:16px;
}
.brand{
  display:flex;
  align-items:center;
  gap:12px;
  text-decoration:none;
  color:var(--ink);
  font-family:'Manrope', sans-serif;
  font-size:18px;
  font-weight:700;
  min-height:44px;
}
.brand:hover{ color:var(--navy); }
.brand-mark{
  height:36px;
  width:auto;
  display:block;
}
.nav-links{
  display:flex;
  align-items:center;
  gap:6px;
}
.nav-links a{
  display:inline-flex;
  align-items:center;
  min-height:44px;
  padding:0 14px;
  font-size:15.5px;
  font-weight:500;
  color:var(--ink);
  border-radius:var(--radius-sm);
  text-decoration-line:underline;
  text-decoration-color:transparent;
  text-decoration-thickness:2px;
  text-underline-offset:8px;
  transition:color .15s ease, text-decoration-color .15s ease, background-color .15s ease;
}
.nav-links a:hover{ color:var(--navy-2); text-decoration-color:var(--navy-2); }
.nav-links a.current,
.nav-links a[aria-current="page"]{ color:var(--navy-2); text-decoration-color:var(--navy-2); }

/* Contact button: flex-centred so the label sits exactly in the middle */
.nav-links a.nav-cta{
  justify-content:center;
  margin-left:10px;
  padding:0 22px;
  min-height:44px;
  background:var(--navy);
  color:#fff;
  text-decoration:none;
  border-radius:var(--radius-sm);
  line-height:1;
}
.nav-links a.nav-cta:hover{ background:var(--navy-2); color:#fff; }

.menu{
  display:none;
  background:none;
  border:1px solid var(--field-border);
  border-radius:var(--radius-sm);
  font-size:20px;
  line-height:1;
  min-width:44px;
  min-height:44px;
  padding:0 12px;
  cursor:pointer;
  color:var(--ink);
}
.menu:hover{ background:var(--blue-pale); }

@media (max-width:860px){
  .menu{ display:inline-flex; align-items:center; justify-content:center; }
  .nav-links{
    position:fixed;
    top:var(--header-h); right:0; bottom:0; left:0;
    background:#fff;
    flex-direction:column;
    align-items:stretch;
    padding:20px clamp(20px, 4vw, 28px);
    gap:4px;
    border-top:1px solid var(--line);
    transform:translateY(-8px);
    opacity:0;
    visibility:hidden;            /* hidden links can't be tabbed to */
    pointer-events:none;
    transition:opacity .18s ease, transform .18s ease, visibility 0s linear .18s;
    overflow-y:auto;
  }
  .nav-links.open{
    opacity:1;
    transform:translateY(0);
    visibility:visible;
    pointer-events:auto;
    transition:opacity .18s ease, transform .18s ease, visibility 0s;
  }
  .nav-links a{
    min-height:52px;
    font-size:18px;
    padding:0 8px;
    border-bottom:1px solid var(--line);
    border-radius:0;
    text-underline-offset:6px;
  }
  .nav-links a.nav-cta{
    align-self:flex-start;
    margin:16px 0 0;
    padding:0 28px;
    border-bottom:0;
    border-radius:var(--radius-sm);
  }
}
@media (max-width:420px){
  .brand{ font-size:16px; gap:10px; }
  .brand-mark{ height:32px; }
}

/* ---------- Hero (photo banner) ---------- */
.hero-banner{
  position:relative;
  height:clamp(260px, 34vw, 420px);
  width:100%;
  overflow:hidden;
  background:var(--navy);
}
.hero-banner img{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  max-width:none;
  object-fit:cover;
  object-position:center 60%;
  filter:saturate(0.92);
}
.hero-banner::after{
  content:"";
  position:absolute;
  inset:0;
  background:
    linear-gradient(180deg, rgba(20,38,63,0.32) 0%, rgba(20,38,63,0.55) 65%, rgba(15,29,48,0.72) 100%);
  mix-blend-mode:multiply;
}
.hero-banner::before{
  content:"";
  position:absolute;
  inset:0;
  background:rgba(30,58,95,0.28);
  z-index:1;
}
.hero-text{
  position:absolute;
  inset:0;
  left:50%;
  transform:translateX(-50%);
  width:100%;
  max-width:var(--max);
  z-index:2;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
  padding:0 clamp(20px, 4vw, 28px) clamp(26px, 4vw, 44px);
}
.hero-text h1{
  color:#fff;
  font-size:clamp(2.3rem, 5.4vw, 4.25rem);
  line-height:1.05;
  letter-spacing:-0.02em;
  text-shadow:0 2px 18px rgba(10,22,40,.45);
}

.hero-copy-block{
  padding-top:clamp(32px, 5vw, 52px);
  padding-bottom:8px;
}
.hero-lede{
  font-family:'Manrope', system-ui, sans-serif;
  font-size:clamp(20px, 2.4vw, 24px);
  font-weight:600;
  line-height:1.4;
  color:var(--navy);
  max-width:34ch;
  margin:0 0 18px;
  text-wrap:balance;
}
.hero-copy{
  font-size:18px;
  color:var(--muted);
  max-width:68ch;
  margin:0;
}

/* ---------- Section shell ---------- */
.section{ padding:clamp(52px, 7vw, 88px) 0; }
.section.alt{ background:var(--blue-pale); }
.section-head{ margin-bottom:clamp(24px, 4vw, 36px); }
.section-subhead{
  font-size:17px;
  color:var(--muted);
  max-width:58ch;
  margin-top:12px;
}

.text-link{
  display:inline-block;
  margin-top:32px;
  padding:6px 0 4px;
  font-size:19px;
  font-weight:600;
  line-height:1.4;
  color:var(--navy);
  text-decoration:none;
  border-bottom:2px solid var(--navy);
  transition:color .15s ease, border-color .15s ease;
}
.text-link:hover{ color:var(--navy-2); border-color:var(--navy-2); }
.text-link:focus-visible{ border-radius:2px; }

/* ---------- Tiles (deliverables) ---------- */
.tiles{
  display:grid;
  grid-template-columns:repeat(2, 1fr);
  gap:24px;
}
.tile{
  background:var(--paper);
  border:1px solid var(--line);
  border-radius:var(--radius);
  padding:clamp(24px, 3vw, 32px);
  box-shadow:var(--shadow-soft);
}
.tile h3{
  font-size:clamp(19px, 2vw, 21px);
  margin-bottom:10px;
}
.tile p{
  margin:0;
  color:var(--muted);
  font-size:16px;
  line-height:1.6;
}
@media (max-width:700px){
  .tiles{ grid-template-columns:1fr; }
}

/* ---------- Services list (homepage partial) ---------- */
.services-list{
  display:grid;
  grid-template-columns:repeat(2, 1fr);
  gap:0 40px;
}
.service{
  padding:18px 0;
  border-bottom:1px solid var(--line);
  font-size:17px;
  line-height:1.5;
}
.section.alt .service{ border-bottom-color:#cddae8; }
@media (max-width:700px){
  .services-list{ grid-template-columns:1fr; }
}

/* ---------- Full services page list ---------- */
.services-full{
  display:grid;
  grid-template-columns:repeat(2, 1fr);
  gap:0 40px;
}
.services-full .service{ font-size:18px; }
@media (max-width:700px){
  .services-full{ grid-template-columns:1fr; }
}

/* CTA block (services page) */
.cta-text{ max-width:62ch; margin:0 0 24px; font-size:18px; color:var(--ink); }

/* ---------- About ---------- */
.about-grid{
  display:grid;
  grid-template-columns:minmax(0, 340px) 1fr;
  gap:clamp(32px, 5vw, 56px);
  align-items:start;
}
.about-photo{
  width:100%;
  height:auto;
  aspect-ratio:3/4;
  object-fit:cover;
  border-radius:var(--radius);
  display:block;
}
.about-photo-wrap{
  position:relative;
  border-radius:var(--radius);
  overflow:hidden;
  box-shadow:var(--shadow-soft);
}
.about-photo-wrap::after{
  content:"";
  position:absolute;
  inset:0;
  background:linear-gradient(180deg, rgba(44,83,130,0.38) 0%, rgba(30,58,95,0.55) 100%);
  mix-blend-mode:multiply;
  pointer-events:none;
}
.about-single{ max-width:var(--max); }
.about-copy p{
  color:var(--muted);
  max-width:66ch;
  margin:0;
}
.about-copy p + p{ margin-top:18px; }
.about-copy p.about-links{ margin-top:12px; }
.about-links .text-link{ margin-top:8px; font-size:17px; }
@media (max-width:820px){
  .about-grid{ grid-template-columns:1fr; }
  .about-photo-wrap{ max-width:340px; }
}

/* ---------- Work page ---------- */
.work-list{ display:flex; flex-direction:column; }
.work-item{
  display:grid;
  grid-template-columns:200px 1fr;
  gap:clamp(20px, 3vw, 32px);
  padding:clamp(24px, 3vw, 34px) 0;
  border-top:1px solid var(--line);
  align-items:start;
}
.work-item:last-child{ border-bottom:1px solid var(--line); }
.work-sector{
  font-size:14px;
  font-weight:600;
  letter-spacing:0.08em;
  text-transform:uppercase;
  color:var(--blue-text);
  padding-top:6px;
  line-height:1.4;
}
.work-body h2,
.work-body h3{ font-size:clamp(19px, 2.2vw, 22px); margin-bottom:10px; }
.work-body p{ margin:0; color:var(--muted); font-size:16px; max-width:64ch; }
.work-body p + p{ margin-top:12px; }
.work-link{
  display:inline-block;
  margin-top:14px;
  padding:6px 0 2px;
  font-size:16px;
  font-weight:600;
  color:var(--navy);
  text-decoration:none;
  border-bottom:2px solid var(--navy);
}
.work-link:hover{ color:var(--navy-2); border-color:var(--navy-2); }
.work-item.has-media{ grid-template-columns:200px 1fr 190px; }
.work-thumb{
  width:100%;
  height:auto;
  display:block;
  border:1px solid var(--line);
  border-radius:var(--radius-sm);
  box-shadow:var(--shadow-soft);
}
.work-item.has-media.wide{ grid-template-columns:200px 1fr 300px; }
@media (max-width:900px){
  .work-item.has-media, .work-item.has-media.wide{ grid-template-columns:200px 1fr; }
  .work-item.has-media .work-thumb{ grid-column:2; max-width:220px; }
  .work-item.has-media.wide .work-thumb{ max-width:420px; }
}
@media (max-width:700px){
  .work-item, .work-item.has-media, .work-item.has-media.wide{ grid-template-columns:1fr; gap:10px; }
  .work-item.has-media .work-thumb{ grid-column:auto; max-width:220px; margin-top:10px; }
  .work-item.has-media.wide .work-thumb{ max-width:100%; }
  .work-sector{ padding-top:0; }
}

/* ---------- Contact ---------- */
.contact-grid{
  display:grid;
  grid-template-columns:1fr 1.2fr;
  gap:clamp(32px, 5vw, 56px);
  align-items:start;
}
.contact-intro h2{ max-width:14ch; font-size:clamp(1.9rem, 3.6vw, 2.5rem); }
form{ display:flex; flex-direction:column; gap:20px; }
.form-row{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:20px;
}
label{
  display:flex;
  flex-direction:column;
  gap:8px;
  font-size:15px;
  font-weight:600;
  color:var(--ink);
}
input, textarea{
  font-family:'Inter', sans-serif;
  font-size:16px;              /* 16px+ stops iOS zooming on focus */
  font-weight:400;
  line-height:1.4;
  min-height:48px;
  padding:12px 14px;
  border:1px solid var(--field-border);
  border-radius:var(--radius-sm);
  background:#fff;
  color:var(--ink);
  width:100%;
  transition:border-color .15s ease, box-shadow .15s ease;
}
input:hover, textarea:hover{ border-color:var(--navy-2); }
input:focus-visible, textarea:focus-visible{
  outline:3px solid var(--focus);
  outline-offset:1px;
  border-color:var(--navy-2);
}
textarea{ min-height:150px; resize:vertical; }
.hp{ position:absolute; left:-9999px; width:1px; height:1px; opacity:0; }
.button{
  align-self:flex-start;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:48px;
  background:var(--navy);
  color:#fff;
  border:none;
  font-family:'Inter', sans-serif;
  font-size:16px;
  font-weight:600;
  line-height:1;
  padding:0 28px;
  border-radius:var(--radius-sm);
  cursor:pointer;
  transition:background-color .15s ease;
}
.button:hover{ background:var(--navy-2); color:#fff; }
.button[disabled]{ opacity:.7; cursor:progress; }
.button-link{ text-decoration:none; }
@media (max-width:760px){
  .contact-grid{ grid-template-columns:1fr; }
  .form-row{ grid-template-columns:1fr; }
}

/* ---------- Footer ---------- */
.site-footer{
  border-top:1px solid var(--line);
  padding:36px 0;
  background:var(--navy);
}
.footer-inner{
  display:flex;
  align-items:center;
  gap:20px;
  flex-wrap:wrap;
  color:#cfe0f2;
  font-size:14.5px;
}
.footer-brand{
  font-family:'Manrope', sans-serif;
  font-size:17px;
  color:#fff;
}

/* ---------- Simple page hero (for about/work pages) ---------- */
.page-hero{
  padding:clamp(40px, 6vw, 68px) 0 clamp(20px, 3vw, 28px);
  border-bottom:1px solid var(--line);
  background:var(--blue-pale);
}
.page-hero h1{
  font-size:clamp(2rem, 4.2vw, 3rem);
  letter-spacing:-0.02em;
}
.page-hero p{
  margin-top:14px;
  color:var(--muted);
  font-size:18px;
  max-width:62ch;
}

/* ---------- Formspree messages ---------- */
.contact-form-wrap{ min-width:0; }
.form-banner{
  margin-bottom:20px;
  padding:14px 16px;
  border-radius:var(--radius-sm);
  font-size:16px;
  background:var(--blue-pale);
  color:var(--navy);
  border:1px solid var(--line);
  border-left:4px solid var(--navy-2);
}
.form-banner:not([data-fs-active]){ display:none; }
.form-banner-error{
  background:#fbeeee;
  color:#8a2b2b;
  border-color:#efcaca;
  border-left-color:#8a2b2b;
}
.field-error{
  font-size:14px;
  font-weight:500;
  color:#8a2b2b;
}
.field-error:empty{ display:none; }
[data-fs-field][aria-invalid="true"]{ border-color:#b94a4a; border-width:2px; }

/* ---------- Print ---------- */
@media print{
  .site-header, .menu, .skip, .hero-banner::before, .hero-banner::after, #contact form{ display:none !important; }
  body{ font-size:12pt; color:#000; }
  .section, .section.alt{ padding:18pt 0; background:#fff; }
  a{ color:#000; }
}

#main:focus-visible{ outline:none; }
