/* michaelaortega.pro — hybrid layout (pinned profile sidebar + case studies) */

:root {
  --bg: #ffffff;
  --surface: #f5f6f8;
  --ink: #1b1f24;
  --muted: #474e57;
  --line: #d9dde3;
  --accent: #2f5fd0;
  --accent-ink: #ffffff;
  --side-bg: #171a1f;
  --side-ink: #ffffff;
  --side-muted: #b9c0c9;
  --side-line: #4a525c;
  --radius: 12px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1216;
    --surface: #1a1e24;
    --ink: #e8ebef;
    --muted: #a3acb7;
    --line: #2c323a;
    --accent: #7ea2ff;
    --accent-ink: #0f1216;
    --side-bg: #0a0c0f;
    --side-line: #3a414a;
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }


body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--accent); }
h1, h2, h3 { line-height: 1.15; margin: 0; }
ul { margin: 0; padding-left: 1.2em; }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 10;
  background: var(--accent); color: var(--accent-ink);
  padding: 10px 16px; border-radius: 6px; font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: 12px; }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

/* ---------- Layout ---------- */

.layout {
  display: flex;
  flex-wrap: wrap;
}

.sidebar {
  flex: 1 1 300px;
  max-width: 100%;
  background: var(--side-bg);
  color: var(--side-ink);
  padding: 40px 28px;
}

.content {
  flex: 999 1 560px;
  min-width: 0;
  max-width: 1060px;
  padding: 56px clamp(16px, 5vw, 64px) 0;
}

@media (min-width: 900px) {
  .sidebar {
    flex: 0 0 320px;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    padding: 32px 28px;
  }
}

/* ---------- Sidebar ---------- */

.avatar {
  width: 132px; height: 132px; border-radius: 50%;
  object-fit: cover; border: 3px solid var(--side-line);
  filter: brightness(1.06) saturate(1.12); /* closer to the brighter case-study photo */
}

.sidebar h1 { margin-top: 22px; font-size: 28px; font-weight: 800; letter-spacing: -0.01em; }
.sidebar .role { margin: 8px 0 0; color: var(--side-muted); font-size: 15px; line-height: 1.5; }

.side-actions { display: flex; flex-direction: column; gap: 10px; margin-top: 24px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 20px; border-radius: 8px;
  font-weight: 600; font-size: 15px; text-decoration: none;
  transition: background-color .15s, color .15s, border-color .15s;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-light { background: #ffffff; color: #171a1f; }
.btn-light:hover { background: #dfe6ff; color: #171a1f; }
.btn-ghost { border: 1.5px solid #ffffff; color: #ffffff; }
.btn-ghost:hover { background: rgba(255,255,255,.12); color: #ffffff; }

.side-nav { margin-top: 32px; display: flex; flex-direction: column; }
.side-nav a {
  color: var(--side-muted); text-decoration: none; font-size: 15px;
  padding: 9px 0 9px 14px; border-left: 2px solid var(--side-line);
}
.side-nav a:hover { color: #ffffff; }
.side-nav a.active { color: #ffffff; font-weight: 700; border-left-color: #9db7ff; }

.side-label {
  margin-top: 32px; font-size: 12px; font-weight: 700;
  letter-spacing: .08em; text-transform: uppercase; color: var(--side-muted);
}
.skills { display: flex; flex-direction: column; gap: 18px; margin: 14px 0 0; padding: 0; list-style: none; }
.skills li { display: flex; gap: 14px; align-items: flex-start; }
.skill-icon {
  flex: none; width: 36px; height: 36px; border-radius: 10px; background: #242a33; color: #9db7ff;
  display: flex; align-items: center; justify-content: center;
}
.skill-icon svg { width: 18px; height: 18px; }
.skills strong { font-size: 15px; }
.skills p { margin: 2px 0 0; font-size: 13px; line-height: 1.55; color: var(--side-muted); }

@media (max-width: 899px) {
  .side-nav { flex-direction: row; flex-wrap: wrap; gap: 4px 18px; }
  .side-nav a { border-left: 0; padding: 0; min-height: 44px; display: inline-flex; align-items: center; }
}

/* Compact sidebar so it fits a 1440x900 screen without scrolling */
@media (min-width: 900px) {
  .avatar { width: 96px; height: 96px; }
  .sidebar h1 { margin-top: 16px; font-size: 26px; }
  .side-actions { margin-top: 20px; }
  .side-nav { margin-top: 24px; }
  .side-nav a { padding: 6px 0 6px 14px; }
  .side-label { margin-top: 24px; }
}

/* ---------- Content ---------- */

section { scroll-margin-top: 24px; }
.section { margin-top: 72px; }

.eyebrow {
  font-size: 13px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--accent); margin: 0 0 12px;
}
.section h2 { font-size: 24px; font-weight: 800; letter-spacing: -0.01em; margin-bottom: 24px; }

.pitch {
  font-size: clamp(32px, 4.4vw, 46px); font-weight: 800;
  letter-spacing: -0.025em; max-width: 780px; margin: 0; line-height: 1.15;
}
.lede { margin: 18px 0 0; font-size: 18px; color: var(--muted); max-width: 680px; }

.stats {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 20px;
  margin: 36px 0 0; padding: 24px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.stat-num { font-size: 24px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; }
.stat-label { font-size: 14px; color: var(--muted); margin-top: 4px; }
.stats > div { display: flex; flex-direction: column; }
.stats dd { order: -1; margin: 0; }

/* Case studies */
.cases { display: flex; flex-direction: column; gap: 20px; }
.case-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 20px; }

.case {
  border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; background: var(--bg);
}
.case-media { aspect-ratio: 16 / 7; overflow: hidden; background: var(--surface); }
.case-media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.case-body { padding: 24px 28px 28px; }
.case-meta { font-size: 13px; color: var(--muted); }
.case h3 { font-size: 18px; margin-top: 6px; }
.case-num { font-size: 24px; font-weight: 800; letter-spacing: -0.02em; margin-top: 8px; }
.case-num span { font-size: 15px; font-weight: 500; color: var(--muted); letter-spacing: 0; }

.car { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 18px; margin: 18px 0 0; }
.car dt { font-weight: 700; font-size: 14px; }
.car dd { margin: 4px 0 0; color: var(--muted); line-height: 1.55; }
.case-grid .car { grid-template-columns: 1fr; gap: 12px; }

/* Result tiles */
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; margin: 0; padding: 0; list-style: none; }
.tile { background: var(--surface); border-radius: 10px; padding: 20px; }
.tile-num { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; }
.tile p { margin: 6px 0 0; color: var(--muted); line-height: 1.5; }

/* Experience */
.jobs { border-top: 1px solid var(--line); }
.job { border-bottom: 1px solid var(--line); }
.job summary {
  list-style: none; cursor: pointer;
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 6px 16px;
  padding: 18px 0; min-height: 44px;
}
.job summary::-webkit-details-marker { display: none; }
.job-title { font-weight: 700; }
.job-co { font-size: 14px; color: var(--muted); }
.job-when { font-size: 14px; color: var(--muted); display: flex; align-items: center; gap: 10px; }
.job-when svg { width: 16px; height: 16px; transition: transform .2s; }
.job[open] .job-when svg { transform: rotate(180deg); }
.job summary:hover .job-title { color: var(--accent); }
.job ul { padding-bottom: 20px; color: var(--muted); }
.job li + li { margin-top: 6px; }
.earlier { padding: 18px 0; color: var(--muted); }
.earlier strong { color: var(--ink); }

/* Credentials */
.creds { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 32px 48px; }
.creds h3 { font-size: 18px; margin-bottom: 6px; }
.cred-rows { list-style: none; padding: 0; }
.cred-rows li {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 12px;
  padding: 10px 0; border-bottom: 1px solid var(--line);
}
.cred-rows li:last-child { border-bottom: 0; }
.cred-rows li > span:last-child { font-size: 14px; color: var(--muted); }
.cred-stack li { flex-direction: column; }
.cred-past { color: var(--muted); }

.speaking { margin-top: 32px; padding-top: 28px; border-top: 1px solid var(--line); }
.speaking h3 { font-size: 18px; }
.speaking-events { margin: 12px 0 0; font-size: 24px; font-weight: 800; letter-spacing: -0.015em; line-height: 1.3; text-wrap: balance; }
.speaking-events span { color: var(--muted); }
.speaking p:last-child { margin: 12px 0 0; color: var(--muted); }

/* Contact band */
.contact {
  margin: 80px 0 0;
  padding: 40px clamp(20px, 4vw, 40px);
  border-radius: var(--radius);
  background: var(--accent); color: var(--accent-ink);
  display: flex; flex-wrap: wrap; gap: 20px; align-items: center; justify-content: space-between;
}
.contact h2 { font-size: 24px; font-weight: 800; max-width: 520px; }
.contact .btn { background: var(--accent-ink); color: var(--accent); }
.contact .btn:hover { opacity: .9; }
.contact .btn:focus-visible { outline-color: var(--accent-ink); }

.footer {
  padding: 24px 0 32px; font-size: 13px; color: var(--muted);
}


