/* Facundo Chambó: personal site styles. No build step, no framework. */

:root {
  --bg: #fbfaf7;
  --bg-alt: #f2efe8;
  --surface: #ffffff;
  --text: #16181d;
  --muted: #5a5f6b;
  --line: #e2ddd2;
  --accent: #1f5eff;
  --accent-ink: #ffffff;
  --accent-soft: #e7eeff;
  --warm: #c2410c;
  --radius: 14px;
  --maxw: 1120px;
  --font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: "Fraunces", ui-serif, Georgia, "Times New Roman", serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1015;
    --bg-alt: #151821;
    --surface: #181b24;
    --text: #eceef3;
    --muted: #a3a9b7;
    --line: #2a2f3c;
    --accent: #7aa2ff;
    --accent-ink: #0b0d12;
    --accent-soft: #1b2440;
    --warm: #fb923c;
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; background: var(--surface); padding: 8px 12px; z-index: 10; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 5;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; }
.brand { font-weight: 700; color: var(--text); text-decoration: none; letter-spacing: -0.01em; display: flex; align-items: center; gap: 10px; }
.brand-mark { width: 30px; height: 30px; border-radius: 8px; background: var(--text); color: var(--bg); display: grid; place-items: center; font-family: var(--serif); font-size: 16px; }
.nav { display: flex; gap: 22px; align-items: center; }
.nav a { color: var(--muted); text-decoration: none; font-size: 15px; font-weight: 500; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
.nav .btn { color: var(--accent-ink); }
.nav-links { display: flex; gap: 22px; }
@media (max-width: 860px) { .nav-links { display: none; } }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--accent); color: var(--accent-ink);
  padding: 12px 20px; border-radius: 999px; font-weight: 600; font-size: 15px;
  text-decoration: none; border: 1px solid transparent; transition: transform .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 20px -8px var(--accent); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line); }
.btn-ghost:hover { box-shadow: none; border-color: var(--text); }
.btn svg { width: 18px; height: 18px; }
.btn-sm { padding: 8px 14px; font-size: 14px; }

/* Typography */
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0 0 .5em; }
h1 { font-family: var(--serif); font-weight: 600; font-size: clamp(2.3rem, 5.4vw, 4rem); }
h2 { font-family: var(--serif); font-weight: 600; font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.2rem; font-weight: 650; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
.lede { font-size: clamp(1.1rem, 1.6vw, 1.3rem); color: var(--muted); max-width: 46rem; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: 12.5px; font-weight: 700; color: var(--warm); margin-bottom: 14px; display: block; }
.muted { color: var(--muted); }

/* Sections */
section { padding: 84px 0; }
section.alt { background: var(--bg-alt); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { max-width: 46rem; margin-bottom: 40px; }

/* Hero */
.hero { padding: 96px 0 72px; }
.hero-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 56px; align-items: center; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; gap: 36px; } }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 28px;
  box-shadow: 0 30px 60px -40px rgba(0,0,0,.35);
}
.hero-card .avatar { width: 72px; height: 72px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--warm)); color: #fff; display: grid; place-items: center; font-family: var(--serif); font-size: 28px; font-weight: 600; margin-bottom: 16px; }
.hero-card .portrait { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 14px; margin-bottom: 18px; background: var(--bg-alt); }
@media (max-width: 900px) { .hero-card .portrait { aspect-ratio: 1 / 1; object-position: 50% 20%; } }
.hero-card dl { margin: 18px 0 0; display: grid; grid-template-columns: auto 1fr; gap: 10px 16px; font-size: 15px; }
.hero-card dt { color: var(--muted); }
.hero-card dd { margin: 0; font-weight: 550; }

/* Page hero (service pages) */
.page-hero { padding: 72px 0 56px; border-bottom: 1px solid var(--line); }
.crumbs { font-size: 14px; color: var(--muted); margin-bottom: 18px; }
.crumbs a { color: var(--muted); }
.crumbs ol { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.crumbs li + li::before { content: "/"; margin-right: 8px; opacity: .6; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.stat { padding: 24px; border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stat strong { display: block; font-family: var(--serif); font-size: 2.2rem; line-height: 1; margin-bottom: 8px; letter-spacing: -0.02em; }
.stat span { color: var(--muted); font-size: 14.5px; }
@media (max-width: 760px) {
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}

/* Cards */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (max-width: 900px) { .grid-3 { grid-template-columns: 1fr; } }
@media (max-width: 720px) { .grid-2 { grid-template-columns: 1fr; } }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px;
  display: flex; flex-direction: column;
}
.card p { color: var(--muted); }
.card ul { padding-left: 1.1em; margin: 0 0 1.2em; color: var(--muted); }
.card ul li { margin-bottom: 4px; }
.card .more { margin-top: auto; font-weight: 600; text-decoration: none; }
.card .more::after { content: " →"; }
.service-card { transition: border-color .15s ease, transform .15s ease; }
.service-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.icon { width: 44px; height: 44px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; margin-bottom: 18px; }
.icon svg { width: 22px; height: 22px; }
.for { font-size: 13px; font-weight: 600; color: var(--warm); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 8px; }

/* Lists */
.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.checklist li { padding-left: 32px; position: relative; }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: 5px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--accent-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f5eff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center/12px no-repeat;
}

/* Steps */
.steps { counter-reset: step; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; list-style: none; padding: 0; margin: 0; }
@media (max-width: 900px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }
.steps li { counter-increment: step; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.steps li::before { content: counter(step, decimal-leading-zero); font-family: var(--serif); font-size: 1.6rem; color: var(--accent); display: block; margin-bottom: 10px; }
.steps h3 { margin-bottom: .35em; }
.steps p { color: var(--muted); font-size: 15.5px; margin: 0; }

/* Two-column prose */
.split { display: grid; grid-template-columns: 1fr 1.3fr; gap: 56px; align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; gap: 24px; } }
.prose { max-width: 44rem; }
.prose h3 { margin-top: 1.6em; }

/* Quotes */
blockquote { margin: 0; }
.quote { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.quote p { font-family: var(--serif); font-size: 1.2rem; line-height: 1.5; color: var(--text); }
.quote footer { color: var(--muted); font-size: 15px; }

/* Credentials */
.badges { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 0; }
.badges li { border: 1px solid var(--line); background: var(--surface); padding: 8px 14px; border-radius: 999px; font-size: 14.5px; font-weight: 550; }

/* FAQ */
.faq { max-width: 52rem; }
.faq details { border-bottom: 1px solid var(--line); padding: 18px 0; }
.faq summary { cursor: pointer; font-weight: 650; font-size: 1.08rem; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.4rem; line-height: 1; color: var(--accent); transition: transform .2s ease; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 12px 0 0; color: var(--muted); }

/* CTA */
.cta {
  background: var(--text); color: var(--bg); border-radius: 24px; padding: 56px;
  display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: center;
}
.cta h2 { color: var(--bg); }
.cta p { color: color-mix(in srgb, var(--bg) 78%, transparent); }
.cta ol { margin: 0; padding-left: 1.2em; color: color-mix(in srgb, var(--bg) 85%, transparent); }
.cta ol li { margin-bottom: 8px; }
.cta .btn { background: var(--bg); color: var(--text); }
.cta .note { font-size: 14px; margin-top: 14px; }
@media (max-width: 860px) { .cta { grid-template-columns: 1fr; padding: 36px 24px; } }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 40px 0; color: var(--muted); font-size: 15px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 20px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 18px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* Trust line */
.trust { margin-top: 18px; font-size: 15px; color: var(--muted); }
.trust strong { color: var(--text); font-weight: 650; }

/* Experience timeline */
.timeline { list-style: none; padding: 0; margin: 0; border-left: 2px solid var(--line); }
.timeline > li { display: grid; grid-template-columns: 150px 1fr; gap: 24px; padding: 0 0 36px 28px; position: relative; }
.timeline > li::before { content: ""; position: absolute; left: -7px; top: 6px; width: 12px; height: 12px; border-radius: 50%; background: var(--bg); border: 2px solid var(--accent); }
.timeline > li:last-child { padding-bottom: 0; }
.timeline .when { font-weight: 650; color: var(--muted); font-size: 15px; padding-top: 2px; }
.timeline h3 { margin-bottom: .2em; }
.timeline .where { color: var(--warm); font-size: 14px; font-weight: 600; margin-bottom: .6em; }
.timeline p:last-child { color: var(--muted); margin: 0; max-width: 46rem; }
@media (max-width: 720px) { .timeline > li { grid-template-columns: 1fr; gap: 4px; padding-left: 20px; } }
