:root {
  --bg:#F8F7F4;     /* clean warm white */
  --ink:#1A1916;    /* soft near-black */
  --muted:#6A6760;  /* warm gray */
  --line:#E7E2DA;   /* warm line */
  --alt:#FFFFFF;    /* crisp alt section */
  --max:1100px;
}

* {
  box-sizing:border-box;
}

/* Base */
body {
  margin:0;
  font-family:'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  color:var(--ink);
  background:var(--bg);
  line-height:1.55;
}

a {
  color:inherit;
  text-decoration:none;
}

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

/* ===== Header / Nav ===== */
.header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--alt);
  border-bottom: 1px solid var(--line);

  /* Keep the logo clear of the iOS/Chrome top bar when sticky */
  padding-top: env(safe-area-inset-top, 0px);
  padding-top: constant(safe-area-inset-top); /* older iOS fallback */
}

.nav {
  height:70px; /* slightly taller to give the logo breathing room */
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:0 0;
}

/* logo image */
.logo img {
  height:70px;
  opacity:.95;
  display:block;
}

/* Desktop menu */
.menu a {
  margin-left:18px;
  font-size:14px;
  color:var(--muted);
}

/* ===== Hero Image ===== */
.hero-image {
  width:100%;
  max-width:var(--max);
  margin:0 auto 12px;
  padding:0;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}

.hero-image img {
  max-width:100%;
  max-height:70vh;
  width:auto;
  height:auto;
  display:block;
  object-fit:contain;
}

/* ===== Hero Text ===== */
.hero {
  padding:0;
}

.hero-inner {
  max-width:100%;
  width:100%;
  text-align:center;
  padding:32px 20px;
}

.hero h1,
.hero .lead {
  margin-left:auto;
  margin-right:auto;
}

/* Typography */
h1,
h2,
h3 {
  font-family:'Cormorant Garamond', Georgia, serif;
  font-weight:500;
  letter-spacing:.02em;
}

h1 {
  font-size:44px;
  line-height:1.05;
  margin:0 0 16px;
}

h2 {
  font-size:28px;
  margin-bottom:12px;
}

h3 {
  font-size:18px;
  margin-bottom:8px;
}

.lead {
  font-size:18px;
  color:var(--muted);
  margin-bottom:18px;
}

.hero h1 { max-width:900px; }
.hero .lead { max-width:760px; }

/* Buttons */
.btn {
  display:inline-block;
  padding:12px 18px;
  border:1px solid var(--ink);
  border-radius:999px;
  background:var(--ink);
  color:#fff;
  font-size:14px;
}

.meta {
  font-size:14px;
  color:var(--muted);
}

/* ===== Sections ===== */
.section {
  padding:72px 0;
  border-top:1px solid var(--line);
}

.section:first-of-type {
  padding-top:48px;
}

.section.alt {
  background:var(--alt);
}

.subhead {
  color:var(--muted);
  margin-bottom:32px;
}

/* Normalize spacing between sections slightly */
.section + .section {
  padding-top:64px;
}

/* ===== Grid / Cards ===== */
.grid {
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:20px;
}

.card {
  border:1px solid var(--line);
  padding:20px;
  background:var(--alt);
}

.card h3 { margin-top:0; }

.card p {
  color:var(--muted);
  font-size:14px;
}

/* ===== Gallery ===== */
.gallery-minimal {
  display:grid;
  grid-template-columns:repeat(2,1fr);
  gap:40px;
}

.gallery-minimal img {
  width:100%;
  height:340px;
  object-fit:cover;
  display:block;
}

.image-placeholder {
  height:340px;
  background:#EEE9E2;
}

figcaption {
  margin-top:10px;
  font-size:13px;
  color:var(--muted);
  letter-spacing:.02em;
}

/* ===== About ===== */
.about {
  padding:72px 0;
}

.about p {
  max-width:var(--max);
  width:100%;
  line-height:1.7;
  margin-bottom:1.25rem;
  margin-left:auto;
  margin-right:auto;
}

/* ===== Footer ===== */
.footer {
  padding:32px 0;
  border-top:1px solid var(--line);
  font-size:14px;
  color:var(--muted);
}

/* ===== Responsive (mobile & tablet) ===== */
@media (max-width:900px) {

  .container {
    padding:0 16px;
  }

  .nav {
    height:auto;
    padding:10px 0;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    gap:10px;
    text-align:center;
  }

  .logo img {
    height:52px;
  }

  .menu {
    display:flex;
    justify-content:center;
    align-items:center;
    flex-wrap:wrap;
    gap:12px;
    width:100%;
  }

  .menu a {
    margin:0 !important;
    font-size:13px;
    color:var(--muted);
    display:inline-block;
  }

  .hero-image {
    margin:4px auto 20px;
  }

  .hero-image img {
    max-height:55vh;
  }

  .hero {
    padding:32px 0 32px;
  }

  h1 {
    font-size:34px;
    line-height:1.08;
  }

  .lead {
    font-size:16px;
    line-height:1.6;
  }

  .section {
    padding:56px 0;
  }

  .section:first-of-type {
    padding-top:40px;
  }

  .section + .section {
    padding-top:48px;
  }

  .about {
    padding:56px 0;
  }

  .grid {
    grid-template-columns:1fr;
  }

  .card {
    padding:18px;
  }

  .gallery-minimal {
    grid-template-columns:1fr;
    gap:28px;
  }

  .gallery-minimal img,
  .image-placeholder {
    height:280px;
  }

  /* Anchor scroll fix ONLY on mobile:
     make section headings land nicely below the sticky nav */
  #services,
  #portfolio,
  #about,
  #contact {
    scroll-margin-top: 140px;
  }
}
