/* =========================================
   Fieldnote Studio — Shared Styles
   Palette: warm paper + forest green ink + terracotta accent
   Every colour and font lives in :root below. To re-brand, swap tokens only.
   ========================================= */

:root {
  /* Surfaces */
  --bg:           #f7f4ec;   /* warm paper */
  --bg-alt:       #eeeadd;   /* deeper paper for alternate sections */
  --surface:      #fffdf8;   /* cards, inputs */
  --nav-bg:       color-mix(in srgb, var(--bg) 92%, transparent);

  /* Text */
  --ink:          #1e2b22;   /* deep forest ink, near-black */
  --ink-soft:     #4a5649;   /* secondary text */
  --muted:        #676a5c;   /* captions, meta (meets WCAG AA 4.5:1 on all backgrounds) */
  --line:         #dcd5c4;   /* hairline divider */
  --on-primary:   #fffdf8;   /* text on primary fills */

  /* Brand */
  --primary:      #3e5a43;   /* forest green (primary accent) */
  --primary-deep: #2a3f2e;   /* darker green on hover */
  --primary-soft: #c8d3c1;   /* sage tint for backgrounds */
  --accent:       #c26a43;   /* terracotta highlight */
  --accent-deep:  #9c5031;

  /* Placeholder blocks */
  --placeholder:  #d9d2c0;
  --placeholder-2:#cbc2ad;

  /* Status */
  --danger:       #a5432f;
  --danger-bg:    #f8ece7;
  --no-post:      #7a3226;   /* red-brown, "do not post" */
  --amber:        #8a6136;
  --amber-line:   #c9a27a;
  --amber-bg:     #fbf4ea;
  --success:      #4f6a4c;
  --success-line: #8fa58c;
  --success-dot:  #5f8a5a;
  --minor:        #5a4a75;
  --minor-line:   #6b5a86;
  --minor-bg:     #f3f0f7;

  /* Overlays */
  --scrim:        #121a14;   /* lightbox / dark overlay base */

  --serif: "Fraunces", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans:  "DM Sans", "Helvetica Neue", Arial, sans-serif;

  --maxw: 1280px;
  --gutter: clamp(20px, 4vw, 56px);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.2s ease;
}
a:hover { color: var(--primary-deep); }

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 0 0 0.4em;
}

h1 { font-size: clamp(2.2rem, 6vw, 4.5rem); line-height: 1.05; }
h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); line-height: 1.15; }
h3, .h3 { font-size: clamp(1.3rem, 2.2vw, 1.6rem); }
h4, .h4 { font-size: 1.05rem; font-family: var(--sans); font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--primary); }

p { margin: 0 0 1em; color: var(--ink-soft); }

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

.eyebrow {
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 1rem;
  display: inline-block;
}

/* ----------- Navigation ----------- */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px var(--gutter);
  max-width: var(--maxw);
  margin: 0 auto;
}
.brand {
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  color: var(--ink);
  text-transform: uppercase;
}
.brand span { color: var(--accent); }

.nav-links {
  display: flex;
  gap: clamp(18px, 3vw, 40px);
  list-style: none;
  margin: 0;
  padding: 0;
  align-items: center;
}
.nav-links a {
  color: var(--ink);
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 8px 0;
  border-bottom: 1px solid transparent;
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}
.nav-toggle {
  display: none;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--ink);
  margin: 5px 0;
}

@media (max-width: 720px) {
  .nav-toggle { display: block; }
  .nav-links {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    flex-direction: column;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    padding: 18px var(--gutter);
    gap: 18px;
    display: none;
  }
  .nav-links.open { display: flex; }
}

/* ----------- Buttons ----------- */
.btn {
  display: inline-block;
  padding: 14px 30px;
  font-size: 0.78rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  border: 1px solid var(--primary);
  color: var(--primary);
  background: transparent;
  transition: all 0.25s ease;
  cursor: pointer;
}
.btn:hover {
  background: var(--primary);
  color: var(--bg);
}
.btn.solid {
  background: var(--primary);
  color: var(--bg);
}
.btn.solid:hover {
  background: var(--primary-deep);
  border-color: var(--primary-deep);
  color: var(--bg);
}

/* ----------- Hero ----------- */
.hero {
  padding: clamp(60px, 10vw, 120px) 0 clamp(40px, 6vw, 80px);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(30px, 6vw, 80px);
  align-items: center;
}
@media (max-width: 820px) {
  .hero-grid { grid-template-columns: 1fr; }
}
.hero-text h1 {
  margin-bottom: 0.3em;
}
.hero-text .btn { margin-bottom: 10px; }
.hero-text .accent-line {
  width: 60px;
  height: 2px;
  background: var(--accent);
  margin: 24px 0;
}
.hero-image {
  aspect-ratio: 4 / 5;
  position: relative;
}
.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 2px;
  display: block;
}

/* ----------- Placeholder image styling ----------- */
.ph {
  background: var(--placeholder);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-soft);
  font-family: var(--sans);
  font-size: 0.82rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  overflow: hidden;
}
.ph::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.18), rgba(0,0,0,0.04));
  pointer-events: none;
}
.ph.alt  { background: var(--placeholder-2); }
.ph.blue { background: var(--primary-soft); color: var(--primary-deep); }

/* Real images inside a placeholder fill the container */
.ph img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  z-index: 1;
}

/* Modifier: transparent / cutout images — no placeholder bg or gradient,
   show the whole figure rather than cropping it */
.ph.cutout { background: transparent; }
.ph.cutout::before { display: none; }
.ph.cutout img { object-fit: contain; }

/* ----------- Sections ----------- */
.section {
  padding: clamp(60px, 8vw, 110px) 0;
}
.section.alt { background: var(--bg-alt); }

.section-head {
  text-align: center;
  max-width: 720px;
  margin: 0 auto clamp(40px, 6vw, 70px);
}
.section-head h2 { margin-bottom: 0.3em; }
.section-head p { color: var(--ink-soft); font-size: 1.05rem; }

/* ----------- Featured grid (Home) ----------- */
.featured-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.featured-grid .ph { aspect-ratio: 3 / 4; }
.featured-grid .tall { grid-row: span 2; aspect-ratio: 3 / 5; }
@media (max-width: 820px) {
  .featured-grid { grid-template-columns: repeat(2, 1fr); }
  .featured-grid .tall { grid-row: auto; aspect-ratio: 3 / 4; }
}

/* ----------- Portfolio grid ----------- */
.portfolio-filters {
  display: flex;
  justify-content: center;
  gap: clamp(14px, 3vw, 36px);
  margin-bottom: 50px;
  flex-wrap: wrap;
}
.portfolio-filters button {
  background: none;
  border: 0;
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-soft);
  cursor: pointer;
  padding: 8px 0;
  border-bottom: 1px solid transparent;
  transition: all 0.2s ease;
}
.portfolio-filters button:hover,
.portfolio-filters button.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-flow: dense;
  gap: 16px;
}
.gallery .ph { aspect-ratio: 3 / 4; }
.gallery .wide { grid-column: span 2; aspect-ratio: 16 / 10; }
@media (max-width: 820px) {
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .gallery .wide { grid-column: span 2; aspect-ratio: 4 / 3; }
}
@media (max-width: 520px) {
  .gallery { grid-template-columns: 1fr; }
  .gallery .wide { grid-column: span 1; aspect-ratio: 4 / 3; }
}

/* ----------- Service cards ----------- */
.services-list {
  display: grid;
  gap: clamp(40px, 6vw, 90px);
}
.service-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(30px, 5vw, 70px);
  align-items: center;
}
.service-row.reverse { direction: rtl; }
.service-row.reverse > * { direction: ltr; }
.service-row .ph { aspect-ratio: 4 / 5; }
.service-row h3, .service-row .h3 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
.service-row .price {
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--primary);
  margin-top: 18px;
  letter-spacing: 0.06em;
}
.service-row ul {
  list-style: none;
  padding: 0;
  margin: 16px 0;
  color: var(--ink-soft);
}
.service-row li {
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.95rem;
}
.service-row li:last-child { border-bottom: 0; }

@media (max-width: 820px) {
  .service-row,
  .service-row.reverse { grid-template-columns: 1fr; direction: ltr; }
}

/* ----------- About page ----------- */
.about-grid {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: clamp(30px, 6vw, 80px);
  align-items: start;
}
.about-grid .ph { aspect-ratio: 4 / 5; }
.about-text p { font-size: 1.05rem; }
.about-text .signature {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.6rem;
  color: var(--accent-deep);
  margin-top: 30px;
}
@media (max-width: 820px) {
  .about-grid { grid-template-columns: 1fr; }
}

/* ----------- Contact ----------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(30px, 6vw, 80px);
  align-items: center;
}
.contact-info p { font-size: 1.05rem; }
.contact-info .info-block {
  margin: 30px 0;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}
.contact-info .info-block:last-child { border-bottom: 0; }
.contact-info .label {
  font-size: 0.75rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 8px;
  display: block;
}
.contact-info .value {
  font-family: var(--serif);
  font-size: 1.4rem;
  color: var(--ink);
}
.contact-grid .ph { aspect-ratio: 4 / 5; }
@media (max-width: 820px) {
  .contact-grid { grid-template-columns: 1fr; }
}

/* ----------- CTA Banner ----------- */
.cta {
  background: var(--primary);
  color: var(--bg);
  text-align: center;
  padding: clamp(60px, 8vw, 100px) 0;
}
.cta h2 { color: var(--bg); }
.cta p { color: var(--bg); max-width: 560px; margin: 0 auto 30px; }
.cta .btn {
  border-color: var(--bg);
  color: var(--bg);
}
.cta .btn:hover {
  background: var(--bg);
  color: var(--primary);
}

/* ----------- Footer ----------- */
.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--line);
  padding: 50px 0 30px;
  color: var(--ink-soft);
  font-size: 0.9rem;
}
.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 30px;
}
.footer-inner h4, .footer-inner .h4 {
  color: var(--primary);
  margin-bottom: 14px;
}
.footer-inner a { color: var(--ink-soft); }
.footer-inner a:hover { color: var(--primary); }
.footer-inner ul { list-style: none; padding: 0; margin: 0; }
.footer-inner li { padding: 4px 0; }
.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--muted);
}
@media (max-width: 720px) {
  .footer-inner { grid-template-columns: 1fr; gap: 30px; }
  .footer-bottom { flex-direction: column; gap: 10px; }
}

/* ----------- Page header (inner pages) ----------- */
.page-header {
  text-align: center;
  padding: clamp(70px, 9vw, 130px) var(--gutter) clamp(40px, 5vw, 60px);
}
.page-header h1 { margin-bottom: 0.2em; }
.page-header p { color: var(--ink-soft); max-width: 600px; margin: 0 auto; font-size: 1.05rem; }
.page-header .accent-line {
  width: 60px;
  height: 2px;
  background: var(--accent);
  margin: 26px auto 0;
}

/* Subtle fade-in */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}
.fade-up { animation: fadeUp 0.7s ease both; }

/* ----------- Booking (Cal.com embed) ----------- */
.booking .section-head p { max-width: 600px; margin-left: auto; margin-right: auto; }
.booking-embed {
  max-width: 1040px;
  margin: 0 auto;
  min-height: 640px;
  background: var(--surface);
  border: 1px solid var(--line);
  overflow: hidden;
}

/* ----------- Demo notice ----------- */
.demo-note { color: var(--accent-deep); }

/* ----------- Legal pages (privacy) ----------- */
.legal-section { padding-top: 10px; }
.legal { max-width: 720px; }
.legal h2 { font-size: clamp(1.35rem, 2.4vw, 1.7rem); margin: 2.2em 0 0.5em; }
.legal p, .legal li { color: var(--ink-soft); line-height: 1.7; }
.legal ul { padding-left: 1.2em; margin: 0 0 1em; display: grid; gap: 0.55em; }
.legal strong { color: var(--ink); font-weight: 500; }
.legal-updated { font-size: 0.85rem; color: var(--muted) !important; letter-spacing: 0.04em; }
.footer-bottom a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }

/* ----------- Accessibility ----------- */
/* Links inside running text are underlined, so they don't rely on color alone. */
p a:not(.btn), .legal a, .info-block p a { text-decoration: underline; text-underline-offset: 2px; }
/* Clear keyboard focus everywhere (including on dark buttons). */
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
/* Comfortable tap targets for footer links. */
.footer-inner li { padding: 0; }
.footer-inner li a { display: inline-block; padding: 7px 0; }

/* ----------- First screen fits without scrolling (laptops/desktops) ----------- */
:root { --nav-h: 76px; }
@media (min-width: 821px) {
  .hero { min-height: calc(100svh - var(--nav-h)); display: flex; align-items: center; padding: 24px 0; }
  .hero > .container { width: 100%; }
  .hero-image { aspect-ratio: auto; height: min(calc(100svh - var(--nav-h) - 48px), 760px); }

  .about-hero { padding-top: 32px; }
  .about-grid .ph { aspect-ratio: auto; height: min(calc(100svh - var(--nav-h) - 64px), 720px); position: sticky; top: calc(var(--nav-h) + 24px); }
}
@media (max-width: 820px) {
  .hero { padding: 36px 0 24px; }
  .hero-image { aspect-ratio: auto; height: 52svh; }
  .about-hero { padding-top: 28px; }
  .about-grid .ph { aspect-ratio: auto; height: 40svh; }
}
.about-intro { margin-bottom: 36px; }
.about-intro h1 { margin: 6px 0 0.3em; }
.about-intro .lead { font-size: 1.15rem; color: var(--ink-soft); max-width: 34em; }
.about-intro .accent-line { width: 60px; height: 1px; background: var(--primary); margin-top: 24px; }

/* Featured: the tall photo fills both rows (no blank space under it) */
.featured-grid .tall { aspect-ratio: auto; }
@media (max-width: 820px) {
  /* Two columns on phones: the tall photo goes full width on top, then a 2x2 grid. */
  .featured-grid .tall { grid-column: 1 / -1; aspect-ratio: 4 / 3; }
}

/* Hero buttons: side by side with a gap (replaces &nbsp; spacing) */
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

/* ----------- Phone hero: photo in an arch, centered text, full-width buttons ----------- */
@media (max-width: 820px) {
  .hero { padding: 20px 0 32px; }
  .hero-grid { gap: 20px; }
  .hero-image {
    order: -1;
    width: min(78vw, 330px);
    height: min(37svh, 340px);
    margin: 0 auto;
    background: var(--bg-alt);
    border-radius: 999px 999px 0 0;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    justify-content: center;
  }
  .hero-image img { object-position: center bottom; border-radius: 0; }
  .hero-text { text-align: center; }
  .hero-text .accent-line { margin: 16px auto; }
  .hero-text p { margin-left: auto; margin-right: auto; max-width: 34em; }
  .hero-actions { flex-direction: column; gap: 10px; margin-top: 24px; }
  .hero-actions .btn { width: 100%; text-align: center; }
}
@media (max-width: 420px) {
  /* Keep the site name on one line on narrow phones */
  .site-nav .brand { font-size: 1.15rem; letter-spacing: 0.12em; white-space: nowrap; }
  .hero-text .eyebrow { letter-spacing: 0.16em; }
}

/* Photo frames: neutral while a photo loads (lazy-loaded photos arrive as you scroll). */
.ph, .ph.alt, .ph.blue { background: var(--bg-alt); color: var(--muted); }
