/* Historic Ferguson  -  site.css */
:root {
  --paper: #F5EFE3; --paper2: #EDE4D2; --card: #FFFDF8; --line: #D9CDB6; --line2: #ECE3D1;
  --ink: #1E2622; --ink2: #3D443F; --muted: #5A5F58;
  --green: #2E4636; --green2: #24382B; --brick: #8A3324; --brick2: #5E2016; --gold: #E7C9A0;
  --blue: #2B6CB0;
  --serif: 'Fraunces', Georgia, serif;
  --plaque: 'Libre Caslon Text', Georgia, serif;
  --sans: 'Source Sans 3', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 18px/1.6 var(--sans); }
img { max-width: 100%; }
a { color: var(--brick); }
a:hover { color: var(--brick2); }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.1; margin: 0; }
p { margin: 0 0 1em; }
.wrap { max-width: 1240px; margin: 0 auto; padding: 0 32px; }
@media (max-width: 640px) { .wrap { padding: 0 18px; } body { font-size: 17px; } }
.skip { position: absolute; left: -9999px; } .skip:focus { left: 12px; top: 12px; z-index: 100; background: #fff; padding: 8px 14px; }
.kicker { font-size: 13px; font-weight: 700; letter-spacing: .24em; text-transform: uppercase; color: var(--brick); margin-bottom: 10px; }
.lead { font-size: 20px; color: var(--ink2); }
.muted { color: var(--muted); }
.small { font-size: 15px; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 24px; border-radius: 99px; font-weight: 700; text-decoration: none; border: 2px solid var(--green); background: var(--green); color: #fff; cursor: pointer; font: 700 17px var(--sans); }
.btn:hover { background: var(--green2); color: #fff; }
.btn.ghost { background: transparent; color: var(--green); }
.btn.ghost:hover { background: var(--green); color: #fff; }
.btn.small { min-height: 40px; padding: 0 18px; font-size: 15px; }
.btnrow { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* header */
.top { border-bottom: 1px solid var(--line); background: var(--paper); }
.top .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; padding-top: 14px; padding-bottom: 14px; }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--ink); }
.brand img { height: 58px; width: auto; }
.brand .mark { width: 52px; height: 52px; border-radius: 50%; border: 2px solid var(--green); display: flex; align-items: center; justify-content: center; font: 700 20px var(--serif); color: var(--green); }
.brand b { display: block; font: 700 24px/1.1 var(--serif); }
.brand small { display: block; font-size: 12px; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.mainnav { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 24px; font-weight: 600; font-size: 16px; }
.mainnav a { color: var(--ink); text-decoration: none; }
.mainnav a:hover, .mainnav a.on { color: var(--brick); }
.mainnav a.tourbtn { color: #fff; background: var(--green); padding: 6px 16px; border-radius: 99px; }
.mainnav a.tourbtn:hover { background: var(--green2); }

/* sections */
.section { padding: 64px 0 40px; }
.section h2 { font-size: 44px; margin-bottom: 14px; }
@media (max-width: 700px) { .section { padding: 44px 0 24px; } .section h2 { font-size: 34px; } }
.band { background: var(--paper2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.dark { background: var(--green); color: var(--paper); }
.dark .kicker { color: var(--gold); }
.dark a { color: var(--paper); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 10px; }
.ph { background: #CDBB9A; border-radius: 6px; display: flex; align-items: flex-end; padding: 12px; color: #3B3123; font-size: 14px; font-weight: 600; }

/* home */
.hero { display: flex; flex-wrap: wrap; gap: 56px; align-items: center; padding: 64px 0 52px; }
.hero > div { flex: 1 1 440px; min-width: 0; }
.hero h1 { font-size: 64px; line-height: 1.04; letter-spacing: -.01em; margin: 0 0 20px; }
@media (max-width: 700px) { .hero h1 { font-size: 44px; } .hero { padding: 40px 0; gap: 32px; } }
.herogrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.herogrid a, .herogrid div { display: block; border-radius: 6px; overflow: hidden; background: #CDBB9A; }
.herogrid img { width: 100%; height: 100%; object-fit: cover; display: block; }
.herogrid .big { grid-row: span 2; height: 440px; }
.herogrid .sm { height: 213px; }
@media (max-width: 700px) { .herogrid .big { height: 300px; } .herogrid .sm { height: 143px; } }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; padding: 28px 0; }
.stats b { display: block; font: 600 40px/1.1 var(--serif); color: var(--green); }
.stats span { font-size: 15px; color: #4A504B; }
@media (max-width: 700px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .stats b { font-size: 32px; } }
.tours { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; }
.tourcard { overflow: hidden; display: flex; flex-direction: column; }
.tourcard .map { height: 180px; background: #C9D3C4; }
.tourcard .body { padding: 24px 28px 28px; }
.tourcard h3 { font-size: 30px; }
.stories { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 22px; }
.story { text-decoration: none; color: var(--ink); display: flex; flex-direction: column; gap: 10px; }
.story .pic { aspect-ratio: 4 / 3; border-radius: 6px; overflow: hidden; background: #CDBB9A; }
.story .pic img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s; }
.story:hover .pic img { transform: scale(1.04); }
.story small { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.story h3 { font-size: 22px; line-height: 1.2; }
.story p { margin: 0; font-size: 16px; color: var(--ink2); }
.story:hover h3 { color: var(--brick); }
.plaquebox { padding: 44px; display: flex; flex-wrap: wrap; gap: 44px; align-items: center; }
.plaquebox > div:last-child { flex: 1 1 420px; min-width: 0; }
@media (max-width: 640px) { .plaquebox { padding: 26px; gap: 24px; } }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { display: inline-flex; align-items: baseline; gap: 8px; text-decoration: none; color: var(--ink); background: var(--card); border: 1px solid var(--line); border-radius: 99px; padding: 8px 18px; font-weight: 600; }
.chip span { color: #6A6F68; font-weight: 400; font-size: 15px; }
.chip:hover, .chip.on { border-color: var(--green); color: var(--green); }
.chip.on { background: var(--green); color: #fff; } .chip.on span { color: #DCE3DA; }
.people { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 22px; }
.people a { text-decoration: none; border-top: 2px solid var(--gold); padding-top: 16px; display: flex; flex-direction: column; gap: 6px; }
.people b { font: 600 24px/1.2 var(--serif); }
.people span { font-size: 16px; color: #DCE3DA; }
.light .people a { color: var(--ink); border-top-color: var(--brick); } .light .people span { color: var(--ink2); }

/* plaques */
.plaque { position: relative; flex: none; width: 156px; box-shadow: 0 4px 14px rgba(30,38,34,.22); line-height: 0; }
.plaque img { width: 100%; height: auto; display: block; }
.plaque span { position: absolute; left: 0; right: 0; top: 81%; transform: translateY(-50%); text-align: center; font: 400 34px/1 var(--plaque); color: #111; }
.plaque.large { width: 220px; } .plaque.large span { font-size: 48px; }
.plaque.tiny { width: 64px; box-shadow: 0 1px 4px rgba(30,38,34,.25); } .plaque.tiny span { font-size: 14px; }
.nrbadge { width: 156px; flex: none; background: #6E5230; border: 3px solid #4E3920; border-radius: 8px; padding: 16px 12px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-align: center; color: #F3E6CC; font-family: var(--plaque); line-height: 1.15; box-shadow: 0 4px 12px rgba(30,38,34,.18); }
.nrbadge small { font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.nrbadge b { font-size: 19px; }
.plaques { display: flex; flex-wrap: wrap; gap: 16px; align-items: stretch; }
@media (max-width: 560px) { .plaque, .nrbadge { width: 120px; } .plaque span { font-size: 26px; } .nrbadge b { font-size: 15px; } }

/* house page */
.crumbs { font-size: 15px; color: var(--muted); padding: 28px 0 14px; }
.househead { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 30px; }
.househead > div:first-child { flex: 1 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.househead h1 { font-size: 60px; line-height: 1.05; }
@media (max-width: 700px) { .househead h1 { font-size: 40px; } }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pill { background: var(--paper2); color: #3B3123; font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 3px 12px; border-radius: 99px; border: 1px solid var(--line); text-decoration: none; }
a.pill:hover { border-color: var(--green); color: var(--green); }
.gallery { margin-bottom: 44px; }
.gallery .main { border-radius: 6px; overflow: hidden; background: #B9A57F; max-height: 620px; display: flex; align-items: center; justify-content: center; }
.gallery .main img { width: 100%; max-height: 620px; object-fit: contain; display: block; background: #1E2622; }
.gallery .main .ph { height: 420px; width: 100%; }
.gallery figcaption { font-size: 15px; color: var(--muted); margin-top: 8px; }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 12px; margin-top: 12px; }
.thumbs button { border: 0; padding: 0; background: none; text-align: left; font: inherit; color: var(--ink); cursor: pointer; display: flex; flex-direction: column; gap: 6px; }
.thumbs img { width: 100%; height: 100px; object-fit: cover; border-radius: 6px; display: block; outline: 3px solid transparent; outline-offset: 2px; }
.thumbs button[aria-current="true"] img { outline-color: var(--green); }
.thumbs span { font-size: 14px; color: #4A504B; line-height: 1.3; }
.twocol { display: flex; flex-wrap: wrap; gap: 56px; align-items: flex-start; padding-bottom: 72px; }
.twocol > article { flex: 999 1 560px; min-width: 0; }
.twocol > aside { flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.story-text p:first-child { font-size: 21px; line-height: 1.55; color: var(--ink); }
.story-text p { color: var(--ink2); }
article h2 { font-size: 34px; margin: 0 0 16px; }
article h3 { font-size: 24px; margin: 26px 0 10px; }
.facts { padding: 24px 26px; }
.facts h2 { font-size: 22px; margin-bottom: 10px; }
.facts dl { margin: 0; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); font-size: 16px; }
.facts dt { color: var(--muted); padding: 8px 8px 8px 0; border-bottom: 1px solid var(--line2); }
.facts dd { margin: 0; font-weight: 600; padding: 8px 0; border-bottom: 1px solid var(--line2); }
.minimap { height: 220px; background: #C9D3C4; border-radius: 10px 10px 0 0; }
.tournav { padding: 18px 22px; display: flex; flex-direction: column; gap: 10px; }
.tournav a { text-decoration: none; color: var(--ink); }
.sharebox { margin-top: 30px; background: var(--paper2); border-radius: 10px; padding: 20px 22px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; }
.sharebox b { display: block; font: 600 20px var(--serif); }
.linkcard { display: flex; gap: 16px; align-items: center; text-decoration: none; color: var(--ink); padding: 14px; margin-top: 18px; }
.linkcard img, .linkcard .ph { width: 110px; height: 80px; flex: none; object-fit: cover; border-radius: 6px; }
.linkcard small { display: block; font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--brick); }
.linkcard b { font: 600 21px var(--serif); }

/* before / after */
.compare { position: relative; overflow: hidden; border-radius: 6px; background: #E3DACB; user-select: none; touch-action: pan-y; }
.compare img { display: block; width: 100%; height: auto; }
.compare .after { position: absolute; inset: 0; clip-path: inset(0 50% 0 0); }
.compare .after img { width: 100%; height: 100%; object-fit: cover; }
.compare .bar { position: absolute; top: 0; bottom: 0; left: 50%; width: 3px; margin-left: -1px; background: #fff; pointer-events: none; }
.compare .knob { position: absolute; top: 50%; left: 50%; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.3); display: flex; align-items: center; justify-content: center; color: var(--green); font-weight: 700; pointer-events: none; }
.compare input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.compare .lbl { position: absolute; bottom: 10px; padding: 3px 10px; border-radius: 99px; background: rgba(30,38,34,.75); color: #fff; font-size: 13px; font-weight: 700; pointer-events: none; }
.compare .lbl.l { left: 10px; } .compare .lbl.r { right: 10px; }
.restored { padding: 26px 28px 28px; margin-bottom: 44px; }
.restored h2 { font-size: 28px; margin: 2px 0 16px; }

/* lists */
.filters { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: end; margin-bottom: 26px; }
.filters label { display: grid; gap: 4px; font-size: 14px; font-weight: 600; color: var(--muted); }
.filters select, .filters input[type=search] { min-height: 44px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--line); background: var(--card); font: 400 16px var(--sans); color: var(--ink); }
.homegrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 24px; }
.homecard { text-decoration: none; color: var(--ink); display: flex; flex-direction: column; gap: 8px; }
.homecard .pic { aspect-ratio: 4 / 3; border-radius: 6px; overflow: hidden; background: #DCD0B8; position: relative; }
.homecard .pic img.photo { width: 100%; height: 100%; object-fit: cover; display: block; }
.homecard .pic .noimg { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #8A7E66; font: 600 15px var(--sans); }
.homecard .marks { position: absolute; right: 8px; bottom: 8px; display: flex; gap: 6px; }
.homecard h3 { font-size: 22px; line-height: 1.2; }
.homecard small { color: var(--muted); font-size: 15px; }
.homecard:hover h3 { color: var(--brick); }
.streethead { font-size: 30px; margin: 40px 0 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.count { color: var(--muted); font: 400 18px var(--sans); }

/* photo archive */
.photogrid { columns: 4 240px; column-gap: 16px; }
.photogrid a { display: block; break-inside: avoid; margin-bottom: 16px; text-decoration: none; color: var(--ink); }
.photogrid img { width: 100%; height: auto; display: block; border-radius: 6px; background: #DCD0B8; }
.photogrid span { display: block; font-size: 14px; color: #4A504B; line-height: 1.35; margin-top: 6px; }
.photogrid em { font-style: normal; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--brick); }

/* forms */
.form { display: grid; gap: 16px; max-width: 680px; }
.form label { display: grid; gap: 6px; font-weight: 600; }
.form label small { font-weight: 400; color: var(--muted); }
.form input[type=text], .form input[type=email], .form input[type=tel], .form textarea, .form select { width: 100%; padding: 12px 14px; border-radius: 8px; border: 1px solid var(--line); background: var(--card); font: 400 17px var(--sans); color: var(--ink); }
.form input:focus, .form textarea:focus, .form select:focus { outline: 2px solid var(--green); outline-offset: 1px; }
.form .two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 600px) { .form .two { grid-template-columns: 1fr; } }
.hp { position: absolute; left: -9999px; }
.msg { background: #E6EFE2; border: 1px solid #8DB386; border-radius: 10px; padding: 14px 18px; margin-bottom: 20px; }
.msg.bad { background: #F6E1DC; border-color: #D08A7C; }

/* footer */
.foot { background: var(--ink); color: #C9CEC6; font-size: 15px; margin-top: 40px; }
.foot .wrap { padding-top: 40px; padding-bottom: 40px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 20px; }
.foot b { display: block; font: 600 20px var(--serif); color: var(--paper); }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.foot a { color: var(--gold); }
.foot .fine { width: 100%; border-top: 1px solid #3A443E; padding-top: 16px; color: #9AA197; font-size: 14px; }

/* the lightbox for the photo archive */
#lb { position: fixed; inset: 0; z-index: 50; background: rgba(15,20,17,.94); display: none; align-items: center; justify-content: center; padding: 60px 20px 90px; }
#lb.open { display: flex; }
#lb img { max-width: 100%; max-height: 100%; object-fit: contain; }
#lb .cap { position: absolute; left: 20px; right: 20px; bottom: 20px; text-align: center; color: #E3E7E1; font-size: 16px; }
#lb button { position: absolute; width: 48px; height: 48px; border-radius: 50%; border: 0; background: rgba(255,255,255,.14); color: #fff; font-size: 28px; cursor: pointer; }
#lb .x { top: 14px; right: 14px; } #lb .pv { left: 14px; top: 50%; } #lb .nx { right: 14px; top: 50%; }
