/* inhabit.gallery — ritratto su commissione */
:root {
  --bg: #f7f4ef;
  --bg-card: #ffffff;
  --ink: #1a1816;
  --ink-muted: #5c5854;
  --accent: #8b6914;
  --accent-soft: #c4a35a;
  --border: #e5e0d8;
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "Source Sans 3", system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--ink);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(247, 244, 239, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ink);
}

.logo span {
  color: var(--accent);
  font-weight: 500;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  padding: 0.5rem 0.75rem;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.85rem;
  border-radius: 4px;
}

.nav-main ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 2rem;
}

.nav-main a {
  color: var(--ink-muted);
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.nav-main a:hover,
.nav-main a[aria-current="page"] {
  color: var(--ink);
}

.hero {
  min-height: 78vh;
  display: grid;
  align-items: center;
  max-width: 1120px;
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
  gap: 3rem;
}

@media (min-width: 900px) {
  .hero {
    grid-template-columns: 1fr 1fr;
    min-height: 85vh;
  }
}

.hero-copy h1 {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 3.75rem);
  font-weight: 500;
  line-height: 1.12;
  margin: 0 0 1.25rem;
  color: var(--ink);
}

.hero-copy .lead {
  font-size: 1.15rem;
  color: var(--ink-muted);
  max-width: 32ch;
  margin-bottom: 2rem;
}

.hero-visual {
  position: relative;
}

.hero-visual::before {
  content: "";
  position: absolute;
  inset: -8% 8% 8% -8%;
  border: 1px solid var(--accent-soft);
  pointer-events: none;
  z-index: 0;
}

.hero-visual img {
  position: relative;
  z-index: 1;
  width: 100%;
  aspect-ratio: 4/5;
  object-fit: cover;
  box-shadow: 0 24px 48px rgba(26, 24, 22, 0.12);
}

.btn {
  display: inline-block;
  padding: 0.85rem 1.75rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
  border-radius: 2px;
  transition: background 0.2s, color 0.2s;
}

.btn-primary {
  background: var(--ink);
  color: var(--bg);
}

.btn-primary:hover {
  background: var(--accent);
  color: var(--bg);
}

.btn-outline {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--ink);
  margin-left: 0.75rem;
}

.btn-outline:hover {
  background: var(--ink);
  color: var(--bg);
}

.section {
  max-width: 1120px;
  margin: 0 auto;
  padding: 4rem 1.5rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 3vw, 2.5rem);
  font-weight: 500;
  margin: 0 0 0.5rem;
  text-align: center;
}

.section-sub {
  text-align: center;
  color: var(--ink-muted);
  max-width: 42ch;
  margin: 0 auto 3rem;
}

.grid-preview {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

@media (min-width: 700px) {
  .grid-preview {
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
  }
}

.grid-preview a {
  overflow: hidden;
  aspect-ratio: 3/4;
}

.grid-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.grid-preview a:hover img {
  transform: scale(1.05);
}

.gallery-page .gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

@media (min-width: 640px) {
  .gallery-page .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 960px) {
  .gallery-page .gallery-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

.gallery-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  overflow: hidden;
}

.gallery-item figure {
  margin: 0;
}

.gallery-item img {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
}

.gallery-item figcaption {
  padding: 0.75rem 1rem;
  font-size: 0.85rem;
  color: var(--ink-muted);
  font-style: italic;
}

.two-col {
  display: grid;
  gap: 2.5rem;
  align-items: start;
}

@media (min-width: 800px) {
  .two-col {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }
}

.prose h2 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 500;
  margin-top: 0;
}

.prose ul {
  padding-left: 1.25rem;
  color: var(--ink-muted);
}

.form-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 2rem;
  box-shadow: 0 12px 40px rgba(26, 24, 22, 0.06);
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.4rem;
  color: var(--ink-muted);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: inherit;
  font-size: 1rem;
  border: 1px solid var(--border);
  background: var(--bg);
  border-radius: 2px;
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: 2px solid var(--accent-soft);
  outline-offset: 2px;
}

.contact-box {
  background: linear-gradient(145deg, var(--ink) 0%, #2d2824 100%);
  color: var(--bg);
  padding: 2.5rem;
  border-radius: 2px;
}

.contact-box h2 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 500;
  margin: 0 0 1rem;
}

.contact-box a {
  color: var(--accent-soft);
  font-size: 1.15rem;
  word-break: break-all;
}

.contact-box a:hover {
  color: #fff;
}

.contact-box p {
  margin: 0;
  opacity: 0.9;
  font-size: 0.95rem;
}

.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 2rem;
  padding: 2rem 1.5rem;
  text-align: center;
  font-size: 0.9rem;
  color: var(--ink-muted);
}

.site-footer a {
  color: var(--ink-muted);
}

.site-footer a:hover {
  color: var(--accent);
}

@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-main {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  .nav-main.is-open {
    max-height: 320px;
  }

  .nav-main ul {
    flex-direction: column;
    gap: 0;
    padding: 1rem 1.5rem 1.5rem;
  }

  .nav-main li {
    border-bottom: 1px solid var(--border);
  }

  .nav-main a {
    display: block;
    padding: 0.85rem 0;
  }

  .header-inner {
    position: relative;
  }

  .btn-outline {
    margin-left: 0;
    margin-top: 0.75rem;
    display: inline-block;
  }

  .hero-copy .btn-outline {
    margin-left: 0;
  }
}

.page-intro {
  text-align: center;
  padding: 3rem 1.5rem 1rem;
  max-width: 640px;
  margin: 0 auto;
}

.page-intro h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 500;
  margin: 0 0 1rem;
}

.page-intro p {
  color: var(--ink-muted);
  margin: 0;
}
