/* Local webfont: Tomatoes */
@font-face {
  font-family: 'Tomatoes';
  src: url('/fonts/Tomatoes-O8L8.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@import url('https://fonts.googleapis.com/css2?family=Great+Vibes&display=swap');
 
/* System font stack, dark theme baseline */
:root {
  --bg: #1E2128;
  --fg: #ffffff;
  --muted: rgba(255,255,255,0.72);
  --link: #4693D1;
  --brand: #1878B9; /* primary */
  --brand-2: #4693D1; /* accent/link */
  --card: #252831;
  --card-border: #343741;
  --border: var(--card-border);
  --maxw: 1120px;
  /* Offset for sticky header (64px) + strap (~40-48px) */
  --anchor-offset: 112px;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
/* Smooth in-page anchor scrolling */
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--fg);
  background: var(--bg);
  font: 16px/1.6 system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; border-radius: 8px; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* Accessible focus rings */
:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }

/* Skip link */
.skip { position: absolute; left: -9999px; top: 0; background: var(--card); color: var(--fg); padding: 8px 12px; border-radius: 6px; }
.skip:focus { left: 12px; top: 12px; z-index: 1000; }

/* Screen-reader only utility */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* Header */
.site-header { position: sticky; top: 0; backdrop-filter: none; background: var(--bg); border-bottom: 1px solid var(--border); z-index: 10; }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: 0.2px; }
.nav-links { display: flex; gap: 16px; align-items: center; }

/* Hero */
.hero { padding: 28px 0 32px; }
.hero .container { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 28px; align-items: center; }
.hero-copy h1 { font-size: clamp(28px, 4vw, 44px); line-height: 1.15; margin: 0 0 12px; }
.hero-copy p { margin: 0 0 16px; color: var(--muted); }
.hero-copy blockquote { margin: 0 0 16px; padding: 12px 16px; background: #2C332F; color: var(--muted); font-style: italic; border-radius: 10px; box-shadow: inset 0 1px 0 rgba(255,255,255,0.04), inset 0 -1px 0 rgba(0,0,0,0.25); }
.subtle-links { margin: 0 0 8px; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.subtle-links a { color: inherit; text-decoration: underline; }
.subtle-links a:hover { filter: brightness(1.1); }
.cta .btn.primary { background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; }

/* Strap line bar */
.strap { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 5px 16px; background: #7B6A58; color: #fff; border-radius: 8px; font-weight: 700; letter-spacing: 0.3px; margin: 0 0 14px; }
/* Full-bleed variant */
.strap.full-bleed { width: 100vw; margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); border-radius: 0; position: sticky; top: 64px; z-index: 9; border-bottom: 1px solid var(--border); }

/* Buttons (touch targets >= 48px) */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 12px 16px; border: 1px solid var(--border); border-radius: 10px; font-weight: 600; }
.btn:hover { text-decoration: none; filter: brightness(0.98); }
.btn.primary { border-color: transparent; }

/* Features */
.features { padding: 28px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--card); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.features h3 { margin: 0 0 6px; font-size: 18px; }
.features p { margin: 0; color: var(--muted); }
/* Card styling for services */
.features .grid-3 > article { background: color-mix(in oklab, var(--card) 88%, white 12%); border: 1px solid var(--border); border-radius: 10px; padding: 16px; box-shadow: 0 1px 0 rgba(255,255,255,0.03), 0 6px 16px rgba(0,0,0,0.18); }

/* Ensure anchored sections are not hidden under sticky header/strap */
#about, #contact { scroll-margin-top: var(--anchor-offset); }

/* Gallery */
.gallery { padding: 24px 0; overflow: visible; }
.gallery .container { overflow: visible; }
.gallery .gallery-grid { overflow: visible; }
/* Two-pane grid: left founder, right 2x2 site images */
.gallery-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 16px; align-items: stretch; }
.gallery-left { grid-row: 1 / span 2; }
.gallery-right { display: grid; grid-template-columns: repeat(2, 1fr); grid-auto-rows: minmax(140px, 1fr); gap: 16px; }
/* Tile card */
.tile { background: var(--card); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; display: grid; place-items: center; position: relative; }
.gallery-left .tile { overflow: visible; }
.tile .tile-frame { width: 100%; height: 100%; border-radius: inherit; overflow: hidden; position: relative; }
.tile picture, .tile img:not(.signature-img) { width: 100%; height: 100%; }
.tile img:not(.signature-img) { object-fit: contain; border-radius: 0; }
.tile.empty { background: transparent; border-style: dashed; opacity: 0.25; }

/* Signature overlay (text) */
.tile .signature { position: absolute; right: -20px; left: auto; bottom: 13px; color: rgba(255,255,255,0.98); font-family: 'Tomatoes', 'Great Vibes', cursive; font-size: 24px; font-weight: 400; letter-spacing: 0.5px; text-shadow: 0 4px 12px rgba(0,0,0,0.65); transform: rotate(-8deg); transform-origin: 100% 100%; pointer-events: none; z-index: 3; }
.tile .signature-img { position: absolute; right: -220px; left: auto; bottom: 22px; width: clamp(260px, 44%, 420px); height: auto; opacity: 1; filter: drop-shadow(0 4px 12px rgba(0,0,0,0.65)); mix-blend-mode: normal; pointer-events: none; z-index: 3; }

/* About */
.about { padding: 36px 0; background: rgba(255, 255, 255, 0.02); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.narrow { max-width: 760px; }
.about h2, .contact h2 { margin-top: 0; }

/* Contact */
.contact { padding: 24px 0 56px; background: var(--card); border-top: 1px solid var(--border); }
.contact .contact-card { background: color-mix(in oklab, var(--card) 88%, white 12%); border: 1px solid var(--border); border-radius: 10px; padding: 16px; box-shadow: 0 1px 0 rgba(255,255,255,0.03), 0 6px 16px rgba(0,0,0,0.18); }

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 16px 0; background: var(--card); }
.foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.foot a { color: inherit; text-decoration: underline; }
.foot small { display: inline-flex; align-items: center; gap: 8px; }
.foot small img { display: inline-block; }
/* Top link as subtle circular button */
.foot a.top-btn { 
  display: inline-flex; align-items: center; justify-content: center;
  padding: 8px 12px; min-height: 40px; min-width: 40px;
  border: 1px solid var(--border); border-radius: 999px;
  background: color-mix(in oklab, var(--card) 88%, white 12%);
  text-decoration: none; font-weight: 600;
  box-shadow: 0 1px 0 rgba(255,255,255,0.03), 0 4px 10px rgba(0,0,0,0.18);
}
.foot a.top-btn:hover { filter: brightness(1.04); text-decoration: none; }
.foot a.top-btn:active { transform: translateY(1px); }

@media (max-width: 960px) {
  .foot a.top-btn { min-height: 48px; min-width: 48px; padding: 0 14px; }
}

/* Responsive */
@media (max-width: 960px) {
  .hero .container { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: 1fr; }
  .gallery-left { grid-row: auto; }
  .gallery-right { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: 1fr; }
}

/* Emphasize first gallery tile (founder) on larger screens */
@media (min-width: 961px) {
  /* Desktop handled by gallery-grid above */
}
