:root {
  --bg: #ffffff;
  --text: #242424;
  --muted: #595959;
  --border: #E3E3E3;
  --accent: #40A9CF;
  --accent-dark: #009EB1;
  --accent-light: #E7FDFD;
  --accent-xlight: #D5FAFF;
  --shadow: 0 8px 30px rgba(0,0,0,.06);
  --radius: 16px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

/* ── Hero ─────────────────────────────── */
.hero {
  background: #242424;
  color: #fff;
  padding: 80px 24px 72px;
  text-align: center;
}

.hero-inner {
  max-width: 680px;
  margin: 0 auto;
}

.hero-name {
  font-size: clamp(28px, 5vw, 52px);
  font-weight: 800;
  margin: 0 0 14px;
  letter-spacing: -1px;
  line-height: 1.1;
}

.hero-title {
  font-size: clamp(13px, 2.2vw, 17px);
  color: #B8E0EF;
  margin: 0 0 8px;
  font-weight: 500;
  letter-spacing: .2px;
}

.hero-tagline {
  font-size: clamp(12px, 1.8vw, 15px);
  color: #475569;
  margin: 0 0 36px;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 1.2px;
}

.hero-links {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 25px;
}

/* ── Buttons ──────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity .15s, transform .15s;
}

.btn:hover { opacity: .85; transform: translateY(-1px); }

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

.btn-hero-outline {
  background: transparent;
  color: #cbd5e1;
  border: 2px solid #334155;
}

.btn-hero-outline:hover { border-color: #94a3b8; color: #fff; opacity: 1; }

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

.btn-outline {
  background: transparent;
  color: #111827;
  border: 2px solid var(--border);
}

/* ── Layout ───────────────────────────── */
.container {
  max-width: 980px;
  margin: 0 auto;
  padding: 28px 18px 60px;
}

.section {
  margin-top: 22px;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.section h2 {
  margin: 0 0 16px;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--accent-dark);
}

.section-intro {
  margin: -8px 0 20px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
}

/* ── About / CV ───────────────────────── */
.about-layout {
  display: flex;
  gap: 28px;
  align-items: flex-start;
}

.about-photo {
  width: 300px;
  flex-shrink: 0;
  border-radius: 14px;
  object-fit: cover;
  object-position: center top;
}

.about-body {
  flex: 1;
}

@media (max-width: 620px) {
  .about-layout {
    flex-direction: column;
    align-items: center;
  }
  .about-photo {
    width: 140px;
  }
}


.bio-text {
  margin: 0 0 14px;
  font-size: 15px;
  line-height: 1.7;
  color: var(--text);
}

.bio-text:last-of-type { margin-bottom: 0; }

.bio-link {
  color: var(--accent-dark);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.bio-link:hover { opacity: .7; }

.cvActions {
  margin-top: 20px;
  display: flex;
  gap: 12px;
  justify-content: center;
}

.cvActions .btn { min-width: 160px; }

/* ── Video grid ───────────────────────── */
.videoGrid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

@media (max-width: 640px) {
  .videoGrid { grid-template-columns: 1fr; }
}

.videoCard {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  background: #fff;
  transition: transform .15s, box-shadow .15s;
}

.videoCard:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(0,0,0,.1);
}

.videoCard iframe {
  width: 100%;
  aspect-ratio: 16/9;
  border: 0;
  display: block;
}

.videoInfo {
  padding: 10px 14px 12px;
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.videoTitle {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}

.videoRole {
  font-size: 12px;
  color: var(--muted);
  font-weight: 400;
}

.videoDesc {
  margin: 8px 0 0;
  padding: 0 0 0 16px;
  font-size: 11px;
  color: var(--muted);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.videoDesc li {
  list-style: disc;
}

/* ── Methodology ──────────────────────── */
.method-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.method-card {
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--accent-xlight);
  display: flex;
  flex-direction: column;
}

.method-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--muted);
  margin-bottom: 8px;
}

.method-card h3 {
  margin: 0 0 10px;
  font-size: 18px;
  font-weight: 700;
}

.method-card p {
  margin: 0 0 16px;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.6;
}

.method-logos {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: auto;
}

.method-logo {
  display: block;
  height: 28px;
  width: auto;
  object-fit: contain;
  object-position: left center;
  opacity: .75;
}

.method-logos .method-logo {
  height: 96px;
}

.method-logo-expert {
  height: 80px !important;
}

.method-logo-claude {
  height: 30px;
  margin-top: auto;
  margin-bottom: 30px;
}

@media (max-width: 620px) {
  .method-grid { grid-template-columns: 1fr; }
}

/* ── AI Games grid ────────────────────── */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}

.card.square {
  position: relative;
  overflow: hidden;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  aspect-ratio: 1 / 1;
  display: block;
  transition: transform .15s, border-color .15s;
}

.card.square:hover {
  transform: translateY(-2px);
  border-color: #cbd5e1;
}

.cardImg {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
  transform: scale(1.02);
  transition: transform .18s ease;
}

.card.square:hover .cardImg { transform: scale(1.06); }

.cardOverlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.6), rgba(0,0,0,0) 55%);
  display: flex;
  align-items: flex-end;
  padding: 12px;
}

.cardTitle {
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: .2px;
  line-height: 1.3;
}

/* ── Companies grid ──────────────────── */
.companies-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 24px 32px;
  align-items: center;
  justify-items: center;
}

.company-logo {
  height: 40px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  transition: transform .2s ease;
}

.company-logo:hover {
  transform: scale(1.5);
}

@media (max-width: 640px) {
  .companies-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ── Teaching grid ───────────────────── */
.teaching-grid {
  display: flex;
  gap: 48px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  padding: 8px 0;
}

.teaching-logo {
  height: 56px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  transition: transform .2s ease;
}

.teaching-logo:hover {
  transform: scale(1.5);
}

/* ── Footer ───────────────────────────── */
.footer {
  margin-top: 18px;
  text-align: center;
  color: var(--muted);
}

.footer a {
  text-decoration: underline;
  color: var(--muted);
}

.footer a:hover { color: var(--text); }

/* ── Responsive ───────────────────────── */
@media (max-width: 900px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 620px) {
  .grid { grid-template-columns: 1fr; }
  .hero { padding: 56px 20px 52px; }
}
