/* Julien Delvat Consulting — shared site styles.
   Loaded by every page before its own <style>; page-specific rules stay in the page.
   Cache: /assets/*.css is served immutable for a year, so bump ?v= in every page's <link> after editing. */

    /* Julien Delvat Consulting — Global Styles */

/* ===== CSS Variables (Design Tokens) ===== */
:root {
  /* Colors */
  --color-bg: #fffbf8; /* same as --color-bg-secondary: one cream for the whole page */
  --color-bg-secondary: #fffbf8;
  --color-text: #2d2d2d;
  --color-text-light: #666666;
  --color-text-lighter: #999999;
  --color-accent: #0f766e;
  --color-accent-light: #14b8a6;
  --color-border: #e0dcd9;
  --color-white: #ffffff;
  --color-error: #dc2626;
  --color-success: #16a34a;

  /* Typography */
  --font-serif: "Crimson Text", Georgia, serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Monaco", "Menlo", "Ubuntu Mono", monospace;

  /* Scale */
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 1.875rem;
  --text-4xl: 2.25rem;
  --text-5xl: 3rem;

  /* Line Heights */
  --leading-tight: 1.4;
  --leading-normal: 1.6;
  --leading-relaxed: 1.75;

  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 0.75rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;

  /* Border Radius */
  --radius-sm: 0.25rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
}

/* ===== Reset & Base Styles ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-serif);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--color-accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
}

/* ===== Typography ===== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: var(--leading-tight);
  color: var(--color-text);
}

h1 { font-size: var(--text-4xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-2xl); }
h4 { font-size: var(--text-xl); }
h5 { font-size: var(--text-lg); }
h6 { font-size: var(--text-base); }

p {
  margin: var(--space-md) 0;
}

strong {
  font-weight: 600;
}

/* ===== Layout ===== */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.py-sm { padding-top: var(--space-sm); padding-bottom: var(--space-sm); }
.py-md { padding-top: var(--space-md); padding-bottom: var(--space-md); }
.py-lg { padding-top: var(--space-lg); padding-bottom: var(--space-lg); }
.py-xl { padding-top: var(--space-xl); padding-bottom: var(--space-xl); }
.py-2xl { padding-top: var(--space-2xl); padding-bottom: var(--space-2xl); }
.py-3xl { padding-top: var(--space-3xl); padding-bottom: var(--space-3xl); }
.py-4xl { padding-top: var(--space-4xl); padding-bottom: var(--space-4xl); }

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

header nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: calc(1200px - 2 * var(--space-lg)); /* = .container content width */
  margin: 0 auto;
  padding: var(--space-sm) var(--space-lg);
  background-color: rgba(249, 247, 244, 0.9);
  border-radius: var(--radius-md);
}

.nav-brand:hover {
  text-decoration: none;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: var(--space-xl);
}

.nav-links a:hover {
  color: var(--color-accent);
  text-decoration: none;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: var(--text-xl);
  cursor: pointer;
  color: var(--color-text);
  padding: var(--space-sm);
}

/* ===== Buttons ===== */
.btn {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-base);
}

.btn-primary {
  background-color: var(--color-accent);
  color: var(--color-white);
  border: 2px solid var(--color-accent);
}

.btn-primary:hover {
  background-color: var(--color-accent-light);
  border-color: var(--color-accent-light);
}

.btn-secondary:hover {
  background-color: var(--color-accent);
  color: var(--color-white);
}

/* ===== Credibility Bar ===== */
.credibility-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--space-3xl);
  flex-wrap: wrap;
}

.credibility-item {
  text-align: center;
  padding: var(--space-sm);
}

.credibility-item img {
  height: 40px;
  width: auto;
  max-width: 120px;
  object-fit: contain;
  filter: grayscale(20%);
  opacity: 0.85;
  transition: filter var(--transition-base), opacity var(--transition-base);
}

.credibility-item img:hover {
  filter: grayscale(0%);
  opacity: 1;
}

.credibility-item .cred-label {
  font-size: var(--text-xs);
  color: var(--color-text-light);
  margin-top: var(--space-xs);
}

.card {
  background-color: var(--color-white);
  padding: var(--space-xl);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.card h3 {
  font-size: var(--text-xl);
  margin-bottom: var(--space-md);
  color: var(--color-accent);
}

.card p {
  font-family: var(--font-serif);
  font-size: var(--text-base);
  color: var(--color-text-light);
  margin-bottom: var(--space-lg);
}

.article-link {
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.article-link:hover {
  color: var(--color-accent-light);
  text-decoration: none;
}

/* ===== Footer ===== */
footer {
  background-color: var(--color-bg-secondary);
  padding: var(--space-3xl) 0 var(--space-xl);
  border-top: 1px solid var(--color-border);
}

.footer-bottom p:last-child {
  margin-bottom: 0;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr));
  gap: var(--space-3xl);
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.footer-section h4 {
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-text);
  margin-bottom: var(--space-md);
}

.footer-section ul {
  list-style: none;
}

.footer-nav-columns {
  columns: 2;
  column-gap: var(--space-xl);
}

.footer-nav-columns li {
  break-inside: avoid;
}

.footer-section li {
  margin-bottom: var(--space-sm);
}

.footer-section a {
  font-family: var(--font-serif);
  font-size: var(--text-sm);
  color: var(--color-text-light);
}

.footer-section a:hover {
  color: var(--color-accent);
  text-decoration: none;
}

.footer-bottom {
  max-width: 1200px;
  margin: var(--space-2xl) auto 0;
  padding: 0 var(--space-lg);
  padding-top: var(--space-xl);
  border-top: 1px solid var(--color-border);
  text-align: center;
  font-family: var(--font-serif);
  font-size: var(--text-sm);
  color: var(--color-text-lighter);
}

@media (max-width: 480px) {

  header nav {
    padding: 0 var(--space-md);
  }
  
  .container {
    padding: 0 var(--space-md);
  }
}

/* ===== Mobile menu (issue #38) =====
   Below 768px the page CSS hides .nav-links and shows the toggle; the toggle script adds
   .nav-open to the nav, which drops the links down over the page as an extension of the
   nav panel (no layout shift, the header keeps its height). */
@media (max-width: 768px) {
  header nav { position: relative; }
  header nav.nav-open {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
  }
  header nav.nav-open .nav-links {
    display: flex;
    flex-direction: column;
    gap: 0;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 100;
    padding: var(--space-xs) 0 var(--space-sm);
    background-color: rgb(249, 247, 244);
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.08);
    text-align: center;
  }
  header nav.nav-open .nav-links a {
    display: block;
    padding: var(--space-sm) 0;
  }
}

/* BEGIN generated header-strip (website/scripts/build-bg-images.py) -- do not edit by hand */
/* Inner-page header strip: the same slice of the skyline photo as the homepage's collapsed strip
   (Specs 001 and 002). Image size and position are computed from the homepage hero height E per
   viewport range; regenerate with the build script after changing the photo, crops or the hero. */
.header-strip {
  background-color: #81afd7; /* sky blue while the image loads */
  background-repeat: no-repeat;
  background-image: url('/assets/bg/strip-desktop.v1.webp'); background-size: 2561.76px 173.30px; background-position: center -1.95px;
}

@media (max-width: 768px) {
  .header-strip { background-image: url('/assets/bg/strip-desktop.v1.webp'); background-size: 2689.02px 181.90px; background-position: center -5.56px; }
}

@media (max-width: 716px) {
  .header-strip { background-image: url('/assets/bg/strip-desktop.v1.webp'); background-size: 2861.45px 193.57px; background-position: center -11.83px; }
}

@media (max-width: 596px) {
  .header-strip { background-image: url('/assets/bg/strip-desktop.v1.webp'); background-size: 2976.40px 201.34px; background-position: center -15.35px; }
}

@media (max-width: 482px) {
  .header-strip { background-image: url('/assets/bg/strip-desktop.v1.webp'); background-size: 3095.46px 209.40px; background-position: center -19.57px; }
}

@media (max-width: 480px) {
  .header-strip { background-image: url('/assets/bg/strip-phone.v1.webp'); background-size: 523.21px 152.60px; background-position: center -3.90px; }
}

@media (max-width: 470px) {
  .header-strip { background-image: url('/assets/bg/strip-phone.v1.webp'); background-size: 546.13px 159.29px; background-position: center -7.48px; }
}

@media (max-width: 402px) {
  .header-strip { background-image: url('/assets/bg/strip-phone.v1.webp'); background-size: 579.32px 168.97px; background-position: center -12.84px; }
}

@media (max-width: 378px) {
  .header-strip { background-image: url('/assets/bg/strip-phone.v1.webp'); background-size: 602.24px 175.65px; background-position: center -15.41px; }
}

@media (max-width: 328px) {
  .header-strip { background-image: url('/assets/bg/strip-phone.v1.webp'); background-size: 625.16px 182.34px; background-position: center -18.99px; }
}

@media (max-width: 324px) {
  .header-strip { background-image: url('/assets/bg/strip-phone.v1.webp'); background-size: 658.35px 192.02px; background-position: center -24.34px; }
}

@media (min-width: 2562px) {
  .header-strip { background-size: 100% auto; background-position: center calc(84px - 3.3380vw); }
}
/* END generated header-strip */
