/* Jorge Johnson — one-page portfolio/storefront.
   No framework: modern CSS grid + custom properties. */

:root {
  --ink: #1a1a1a;
  --paper: #ffffff;
  --muted: #6b6b6b;
  --line: #dcdcdc;
  --accent: #b3001b; /* red of the Escote cover */
  --measure: 62ch;   /* max text width on large screens */
  --gap: 1rem;
  /* Century Gothic is the PDF's face; free geometric fallbacks after it. */
  --sans: "Century Gothic", "CenturyGothic", "Avant Garde", Futura,
          "Trebuchet MS", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
}

/* ---------- Header / navigation ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--paper);
  border-bottom: 1px solid var(--ink);
}

.topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.25rem 1.5rem;
  padding: 0.6rem 1.25rem 0.2rem;
}

.brand {
  font-size: 1.25rem;
  letter-spacing: 0.18em;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
}

.topbar-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
  font-size: 0.85rem;
}

.topbar-contact a {
  color: var(--muted);
  text-decoration: none;
}
.topbar-contact a:hover { color: var(--accent); }

.site-nav {
  display: flex;
  gap: 1.4rem;
  padding: 0.35rem 1.25rem 0.65rem;
  overflow-x: auto;          /* single scrollable line on narrow screens */
  white-space: nowrap;
  scrollbar-width: thin;
}

.site-nav a {
  color: var(--ink);
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-bottom: 2px solid transparent;
  padding-bottom: 2px;
}
.site-nav a:hover { border-bottom-color: var(--accent); }

/* ---------- Sections ---------- */

main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

section {
  padding: 3rem 0 1rem;
  scroll-margin-top: 6.5rem; /* anchors land below the sticky header */
}

h2 {
  font-size: 1.4rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
  margin: 0 0 1.25rem;
}

/* Text never spans the full width on large displays. */
.prose {
  max-width: var(--measure);
  margin: 1.25rem 0;
}

address.prose { font-style: normal; }
.contact a { color: var(--ink); }
.contact a:hover { color: var(--accent); }

/* ---------- Hero ---------- */

.hero {
  text-align: center;
  padding-top: 3.5rem;
}

.hero .logo {
  width: min(320px, 70vw);
  height: auto;
}

.hero .intro {
  margin: 2rem auto;
  text-align: center;
}

.hero .portrait {
  width: min(420px, 90vw);
  height: auto;
}

/* ---------- Image grids ---------- */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr));
  gap: var(--gap);
  margin: 1.5rem 0;
}

/* Larger cells for artworks (dessins, peintures, collages, bijoux). */
.grid-large {
  grid-template-columns: repeat(auto-fill, minmax(min(380px, 100%), 1fr));
}

.grid img {
  width: 100%;
  height: auto;
  display: block;
}

/* Panoramic pieces span the whole row. */
.grid .wide { grid-column: 1 / -1; }

/* ---------- Films ---------- */

.film {
  margin: 0;
  min-width: 0;
}

.film video {
  width: 100%;
  height: auto;
  display: block;
  background: #000;
}

.film figcaption {
  margin-top: 0.4rem;
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------- Featured figure (bague, livre) ---------- */

.feature {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
  margin: 2rem 0;
}

.feature img {
  flex: 1 1 320px;
  min-width: 0;
  max-width: 560px;
  height: auto;
}

.feature figcaption {
  flex: 1 1 240px;
  max-width: 34ch;
  font-size: 0.95rem;
  color: var(--muted);
}

/* ---------- Contact / footer ---------- */

.contact {
  border-top: 1px solid var(--line);
  margin-top: 3rem;
}

.site-footer {
  border-top: 1px solid var(--ink);
  margin-top: 3rem;
  padding: 1rem 1.25rem 2rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--muted);
}

/* ---------- Narrow screens ---------- */

@media (max-width: 640px) {
  section { scroll-margin-top: 8.5rem; }
  /* Deterministic wrap: email on its own line, the two phones side by side. */
  .topbar-contact {
    font-size: 0.78rem;
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, max-content);
    gap: 0.1rem 1.25rem;
  }
  .topbar-contact a:first-child { grid-column: 1 / -1; }
  /* Text flows edge to edge with the single-column images. */
  .prose { max-width: none; }
}
