/* vil4max.com, direction A (owner, 2026-10-20): warm paper, a serif for headings, one blue accent,
   a single essay column. Every colour is a token; the dark theme redefines the tokens only. */
:root {
  --paper: #faf9f5;
  --ink: #1f1e1b;
  --muted: #625f57;
  --rule: #e4e0d5;
  --card: #f2f0e9;
  --accent: #2556c4;
  --accent-ink: #faf9f5;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "IBM Plex Sans", "Helvetica Neue", Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
  --measure: 720px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #1c1b19;
    --ink: #ece9e1;
    --muted: #aaa59b;
    --rule: #36342f;
    --card: #252421;
    --accent: #85a6ff;
    --accent-ink: #1c1b19;
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 17px/1.65 var(--sans); }
img { max-width: 100%; height: auto; }
a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 16px; top: 16px; background: var(--paper); padding: 8px 12px; z-index: 10; }

.col { max-width: var(--measure); margin-inline: auto; padding-left: max(20px, env(safe-area-inset-left, 0px)); padding-right: max(20px, env(safe-area-inset-right, 0px)); }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; line-height: 1.15; text-wrap: balance; margin: 0; }
h2 { font-size: clamp(26px, 4vw, 32px); margin-bottom: 18px; }
h3 { font-size: 22px; margin-bottom: 8px; }
p { margin: 0 0 14px; }
ul, ol { margin: 0 0 16px; }

/* Header */
.site-header { border-bottom: 1px solid var(--rule); }
.site-header__row { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 20px; padding-block: 16px; }
.site-header__name { font: 600 18px/1.2 var(--serif); color: var(--ink); text-decoration: none; }
.site-header nav { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 15px; }
.site-header nav a { color: var(--muted); text-decoration: none; }
.site-header nav a:hover, .site-header nav a[aria-current="page"] { color: var(--ink); }

/* Hero */
.hero { padding-block: 56px 24px; }
.hero__who { display: flex; align-items: center; gap: 16px; margin-bottom: 28px; }
.hero__photo { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; flex: none; }
.hero__who p { margin: 0; font-weight: 500; line-height: 1.35; }
.hero__who span { color: var(--muted); font-weight: 400; font-size: 15px; }
.hero h1 { font-size: clamp(36px, 7vw, 54px); letter-spacing: -.01em; margin-bottom: 18px; }
.lede { font-size: 20px; line-height: 1.55; margin-bottom: 22px; }
.proof { list-style: none; padding: 0; display: grid; gap: 8px; margin-bottom: 28px; }
.proof li { position: relative; padding-left: 20px; }
.proof li::before { content: ""; position: absolute; left: 0; top: .68em; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.actions, .email { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 22px; }
.button { display: inline-block; padding: 11px 22px; border-radius: 8px; background: var(--accent); color: var(--accent-ink); font-weight: 500; text-decoration: none; }
.button:hover { opacity: .9; }

/* Sections */
.section { padding-block: 48px 8px; border-top: 1px solid var(--rule); margin-top: 32px; }
.highlights { list-style: none; padding: 0; display: grid; gap: 22px; }
.highlights__company { margin-bottom: 4px; font-weight: 600; }
.highlights__company a { color: var(--ink); text-decoration: none; }
.highlights__company span { color: var(--muted); font: 400 13px/1 var(--mono); margin-left: 8px; }
.more { color: var(--muted); }

/* Product cards: each app gets its own tint, a row of real screens, what was built and the stack. */
.products { display: grid; gap: 28px; }
.product {
  --tint: var(--accent);
  border-radius: 20px; padding: 26px;
  background: linear-gradient(160deg, color-mix(in srgb, var(--tint) 16%, var(--card)) 0%, var(--card) 62%);
  border: 1px solid color-mix(in srgb, var(--tint) 22%, var(--rule));
}
.product__head { display: grid; grid-template-columns: 64px minmax(0, 1fr); align-items: center; gap: 12px 16px; margin-bottom: 22px; }
.product__icon { width: 64px; height: 64px; border-radius: 15px; box-shadow: 0 6px 16px -8px color-mix(in srgb, var(--tint) 70%, #000); }
.product__head h3 { font-size: 28px; margin-bottom: 2px; }
.product__tagline { margin: 0; font-size: 17px; color: var(--muted); }
.product__stores { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; }
.store { display: inline-block; padding: 8px 14px; border-radius: 999px; font-size: 14px; font-weight: 500; text-decoration: none; color: var(--paper); background: var(--ink); white-space: nowrap; }
.store--quiet { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 25%, transparent); }
.product__shots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; align-items: start; }
.product__wide { margin: 0 0 22px; }
.product__wide img { display: block; width: 100%; border-radius: 16px; border: 1px solid color-mix(in srgb, var(--ink) 12%, transparent); }
.product__wide figcaption { font: 13px/1.4 var(--mono); color: var(--muted); margin-top: 8px; }
.product__shots img { display: block; width: 100%; border-radius: 22px; box-shadow: 0 14px 30px -18px color-mix(in srgb, var(--tint) 60%, #000); border: 1px solid color-mix(in srgb, var(--ink) 10%, transparent); }
.product__points { padding-left: 20px; display: grid; gap: 8px; margin-bottom: 18px; }
.product__points li::marker { color: var(--tint); }
.chips { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 16px; }
.chips li { font: 13px/1 var(--mono); padding: 6px 10px; border-radius: 999px; background: color-mix(in srgb, var(--tint) 12%, var(--paper)); border: 1px solid color-mix(in srgb, var(--tint) 25%, transparent); }
.product__links { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 15px; margin: 0; }
.product--soon { background: var(--card); }
.product--soon h3 { font-size: 22px; }
.soon { font: 500 12px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--accent); margin-left: 8px; vertical-align: middle; }
@media (max-width: 520px) {
  .product { padding: 18px; border-radius: 16px; }
  .product__shots { grid-template-columns: repeat(3, 70%); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; }
  .product__shots img { scroll-snap-align: start; }
}

.loop { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; counter-reset: step; }
.loop li { counter-increment: step; font: 14px/1.3 var(--mono); padding: 8px 12px; border: 1px solid var(--rule); border-radius: 999px; background: var(--card); }
.loop li::before { content: counter(step) " "; color: var(--accent); }
.evidence { padding: 14px 16px; background: var(--card); border-radius: 10px; margin-bottom: 28px; }

.offers { padding-left: 20px; display: grid; gap: 4px; }
.email span { font-family: var(--mono); font-size: 15px; user-select: all; }
.cover-contact { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 18px; font-size: 15px; }

/* Experience page: three periods, newest first; early roles in a tighter list */
.page-lede { color: var(--muted); font-size: 18px; margin-bottom: 8px; }
.period { padding-top: 36px; }
.period h2 { display: flex; align-items: baseline; gap: 12px; padding-bottom: 10px; border-bottom: 1px solid var(--rule); }
.period h2 span { font: 400 14px/1 var(--mono); color: var(--muted); }
.experience-year-scale { display: none; }
.experience-stack { display: grid; gap: 30px; }
.experience-stack--compact { gap: 22px; }
.experience-stack--compact .experience-entry__skills { display: none; }
.experience-entry__rail { display: none; }
.experience-entry__company { font-size: 21px; margin-bottom: 2px; }
.experience-entry__role { margin: 0; font-weight: 500; }
.experience-entry__dates { margin: 0 0 8px; color: var(--muted); font: 13px/1.5 var(--mono); }
.experience-entry__product { color: var(--muted); margin-bottom: 8px; }
.experience-entry__bullets { padding-left: 20px; display: grid; gap: 4px; }
.experience-entry__skills { color: var(--muted); font-size: 14px; }

/* Projects page */
.page-title { font-size: clamp(34px, 6vw, 46px); padding-top: 48px; margin-bottom: 8px; }
.projects-main section { padding-top: 28px; }
.projects-group-title { font: 500 13px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding-bottom: 10px; border-bottom: 1px solid var(--rule); margin-bottom: 8px; }
.case-study { padding-block: 26px; border-bottom: 1px solid var(--rule); display: grid; gap: 18px; }
.case-study > * { min-width: 0; }
.case-title { font-size: 26px; margin-bottom: 4px; }
.case-era { color: var(--muted); font-size: 15px; }
.case-signals { padding-left: 20px; display: grid; gap: 4px; }
.case-stack { color: var(--muted); font-size: 14px; }
.case-links { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.case-study__media { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 6px; }
.case-study__media img { border-radius: 14px; max-height: 420px; width: auto; flex: none; }

.site-footer { border-top: 1px solid var(--rule); margin-top: 56px; padding-block: 24px 40px; color: var(--muted); font-size: 15px; }
.site-footer p { margin: 0; }

@media (prefers-reduced-motion: no-preference) { .button { transition: opacity .15s ease; } }
