/* NovarumHomes.com — design system
   Historical Concepts bones (editorial, photography-forward, generous whitespace)
   with the Novarum brand palette + type (brand.json). No JS anywhere. */

/* ---------- fonts (self-hosted, subset woff2) ---------- */
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 300; font-display: swap; src: url('../fonts/cormorant-garamond-300.woff2') format('woff2'); }
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/cormorant-garamond-400.woff2') format('woff2'); }
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/cormorant-garamond-500.woff2') format('woff2'); }
@font-face { font-family: 'Cormorant Garamond'; font-style: italic; font-weight: 400; font-display: swap; src: url('../fonts/cormorant-garamond-italic-400.woff2') format('woff2'); }
@font-face { font-family: 'EB Garamond'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/eb-garamond-400.woff2') format('woff2'); }
@font-face { font-family: 'EB Garamond'; font-style: italic; font-weight: 400; font-display: swap; src: url('../fonts/eb-garamond-italic-400.woff2') format('woff2'); }
@font-face { font-family: 'EB Garamond'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/eb-garamond-500.woff2') format('woff2'); }

/* ---------- tokens ---------- */
:root {
  --paper:    #FEFEFF;
  --slate:    #64646C;
  --charcoal: #36363D;
  --powder:   #C7D5E2;
  --greyline: #C6C4C4;
  --ink:      #3A3A40;
  --font-display: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --font-body:    'EB Garamond', Georgia, 'Times New Roman', serif;
  --track: 0.22em;          /* editorial letterspacing for labels/nav */
  --measure: 38rem;         /* comfortable text column */
  --gutter: clamp(1.25rem, 4vw, 3rem);
}

/* ---------- reset-lite ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.1875rem;      /* 19px — Garamonds run small */
  line-height: 1.65;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }

/* ---------- type scale ---------- */
h1, h2, h3 { font-family: var(--font-display); font-weight: 400; line-height: 1.12; margin: 0; color: var(--charcoal); }
h1 { font-size: clamp(2.4rem, 6vw, 4.2rem); font-weight: 300; }
h2 { font-size: clamp(1.9rem, 4vw, 2.8rem); font-weight: 300; }
h3 { font-size: clamp(1.35rem, 2.4vw, 1.7rem); }
p  { margin: 0 0 1.2em; }

.label {                                  /* small letterspaced caps — section markers, nav */
  font-family: var(--font-body);
  font-size: 0.78rem;
  letter-spacing: var(--track);
  text-transform: uppercase;
  color: var(--slate);
}
.location { font-style: italic; color: var(--slate); }  /* project locations, HC-style */

.lede {                                   /* big serif statement, home intro */
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 300;
  line-height: 1.4;
  color: var(--charcoal);
}
.rule { border: 0; border-top: 1px solid var(--powder); width: 5rem; margin: 2.5rem auto; }

/* ---------- header / nav ---------- */
.site-header {
  position: absolute; top: 0; left: 0; right: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.4rem var(--gutter);
}
.site-header.solid { position: static; background: var(--paper); border-bottom: 1px solid var(--greyline); }
.brand { display: flex; align-items: center; gap: 0.7rem; text-decoration: none; }
.brand img { height: 44px; width: auto; }
.brand span { font-family: var(--font-body); font-size: 0.95rem; letter-spacing: 0.26em; text-transform: uppercase; white-space: nowrap; }
.on-hero .brand span { color: var(--paper); text-shadow: 0 1px 8px rgba(0,0,0,0.35); }
.solid .brand span { color: var(--charcoal); }
@media (max-width: 760px) {
  .brand span { color: var(--paper) !important; text-shadow: none; font-size: 0.74rem; letter-spacing: 0.16em; }
  .brand img { height: 34px; }
  .site-header { padding: 1rem 1.1rem; }
}
html, body { overflow-x: clip; }
.site-footer img { height: 90px; }
.nav { display: flex; gap: clamp(1rem, 3vw, 2.4rem); }
.nav a { text-decoration: none; font-size: 0.78rem; letter-spacing: var(--track); text-transform: uppercase; font-family: var(--font-body); padding: 0.4rem 0; border-bottom: 1px solid transparent; }
.nav a:hover, .nav a[aria-current="page"] { border-bottom-color: currentColor; }
/* over-hero variant: white */
.on-hero .nav a { color: var(--paper); text-shadow: 0 1px 8px rgba(0,0,0,0.35); }
.solid .nav a { color: var(--slate); }
.solid .nav a:hover, .solid .nav a[aria-current="page"] { color: var(--charcoal); }

/* mobile nav — pure CSS (checkbox), no JS */
.nav-toggle-box { display: none; }
.nav-toggle { display: none; cursor: pointer; padding: 0.5rem; }
.nav-toggle span { display: block; width: 26px; height: 1px; background: currentColor; margin: 7px 0; }
.on-hero .nav-toggle { color: var(--paper); }
.solid .nav-toggle { color: var(--charcoal); }
@media (max-width: 760px) {
  .nav-toggle { display: block; }
  .nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: var(--charcoal); flex-direction: column; gap: 0;
    padding: 1rem var(--gutter) 1.5rem;
  }
  .nav a { color: var(--paper) !important; padding: 0.8rem 0; border-bottom: 1px solid rgba(255,255,255,0.12); text-shadow: none; }
  .nav-toggle-box:checked ~ .nav { display: flex; }
  .site-header { position: relative; background: var(--charcoal); }
  .nav-toggle { color: var(--paper) !important; }
}

/* ---------- hero ---------- */
.hero { position: relative; min-height: 92svh; display: grid; grid-template-columns: minmax(0, 1fr); place-items: end center; isolation: isolate; }
.hero-copy { width: 100%; max-width: 100%; box-sizing: border-box; }
.hero picture, .hero > img { position: absolute; inset: 0; z-index: -1; }
.hero picture img, .hero > img { width: 100%; height: 100%; object-fit: cover; }
.hero::after { content: ''; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(to bottom, rgba(30,30,35,0.30), rgba(30,30,35,0) 30%, rgba(30,30,35,0) 55%, rgba(30,30,35,0.45)); }
.hero-copy { text-align: center; color: var(--paper); padding: 0 var(--gutter) clamp(3rem, 8vh, 5.5rem); }
.hero-copy h1 { color: var(--paper); text-shadow: 0 2px 18px rgba(0,0,0,0.35); }
.hero-copy .label { color: var(--paper); opacity: 0.92; margin-bottom: 1rem; display: block; }
.hero-mini { min-height: 46svh; }        /* interior-page banner */

/* ---------- sections ---------- */
.section { padding: clamp(3.5rem, 9vw, 7rem) var(--gutter); }
.section-tight { padding-top: clamp(2rem, 5vw, 3.5rem); }
.center { text-align: center; }
.narrow { max-width: var(--measure); margin-inline: auto; }
.wide { max-width: 74rem; margin-inline: auto; }
.band { background: var(--charcoal); color: #DDDDE2; }
.band h2, .band .lede { color: var(--paper); }
.band .label { color: var(--powder); }
.band-powder { background: var(--powder); color: var(--charcoal); }

/* ---------- project cards ---------- */
.cards { display: grid; gap: clamp(2rem, 5vw, 4rem); }
@media (min-width: 761px) { .cards-2 { grid-template-columns: 1fr 1fr; } .cards-3 { grid-template-columns: repeat(3, 1fr); } }
.card { text-decoration: none; }
.card figure { margin: 0; overflow: hidden; }
.card img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; transition: transform 1.2s ease; }
.card:hover img { transform: scale(1.03); }
.card h3 { margin-top: 1.1rem; }
.card .location { font-size: 0.95rem; }

/* ---------- galleries (project pages) ---------- */
.gallery { display: grid; gap: 1.6rem; grid-template-columns: repeat(auto-fill, minmax(min(380px, 100%), 1fr)); }
.gallery img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.gallery .tall img { aspect-ratio: 3 / 4; }
.gallery .wide-slot { grid-column: 1 / -1; }
.gallery .wide-slot img { aspect-ratio: 16 / 9; }

/* alternating editorial rows (about page) */
.row { display: grid; gap: clamp(1.5rem, 4vw, 4rem); align-items: center; }
@media (min-width: 761px) {
  .row { grid-template-columns: 1fr 1fr; }
  .row.flip > figure { order: 2; }
}
.row figure { margin: 0; }

/* ---------- footer ---------- */
.site-footer { background: var(--charcoal); color: #B9B9C0; padding: clamp(3rem, 6vw, 4.5rem) var(--gutter) 2rem; }
.site-footer .cols { display: grid; gap: 2rem; max-width: 74rem; margin: 0 auto; }
@media (min-width: 761px) { .site-footer .cols { grid-template-columns: 2fr 1fr 1fr; } }
.site-footer img { height: 60px; width: auto; margin-bottom: 1rem; }
.site-footer a { color: #DDDDE2; text-decoration: none; }
.site-footer a:hover { color: var(--paper); }
.site-footer .label { color: var(--powder); margin-bottom: 0.8rem; display: block; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: 0.45rem 0; }
.fineprint { max-width: 74rem; margin: 2.5rem auto 0; padding-top: 1.2rem; border-top: 1px solid rgba(255,255,255,0.14); font-size: 0.85rem; display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; }

/* ---------- misc ---------- */
.btn {
  display: inline-block; text-decoration: none;
  font-size: 0.78rem; letter-spacing: var(--track); text-transform: uppercase;
  border: 1px solid var(--slate); color: var(--charcoal);
  padding: 0.9rem 2.2rem; transition: background 0.3s, color 0.3s;
}
.btn:hover { background: var(--charcoal); color: var(--paper); border-color: var(--charcoal); }
.band .btn { border-color: var(--powder); color: var(--paper); }
.band .btn:hover { background: var(--powder); color: var(--charcoal); }

.contact-lines { font-family: var(--font-display); font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 300; line-height: 1.7; }
.contact-lines a { text-decoration: none; border-bottom: 1px solid var(--powder); }
.contact-lines a:hover { border-bottom-color: var(--slate); }

@media (prefers-reduced-motion: reduce) {
  .card img { transition: none; }
}
