/* granadalab.org — layout and look of the original (dark bands, white content,
   magenta links), typeset in Inter like granadascientific.com. No JavaScript. */
:root {
  --band: #15131c;        /* dark header/hero band (original #2b2b2b, slightly violet) */
  --band-2: #0b0a10;
  --ink: #14121c;         /* headings */
  --body: #4a4857;         /* running text, softer like granadascientific.com */
  --muted: #6b6878;
  --line: #e4e2ea;
  --soft: #f6f5f9;
  --accent: #c8177c;      /* original link magenta */
  --accent-ink: #a01263;
  --violet: #7a5cf0;      /* logo violet */
  --wrap: 1120px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: #fff; color: var(--body);
  font: 400 17px/1.8 'Inter', -apple-system, 'Segoe UI', sans-serif;
  font-feature-settings: 'cv11', 'ss01';
}
img, video { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:visited { color: #9b1d68; }
.site-header a:visited, .card:visited, .avatars a:visited { color: inherit; }
:focus-visible { outline: 2px solid var(--violet); outline-offset: 3px; }
a:hover { color: var(--accent-ink); text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3, h4 { line-height: 1.2; color: var(--ink); text-wrap: balance; }
p, li, figcaption { text-wrap: pretty; }
h2 { font-size: 2rem; font-weight: 300; letter-spacing: -.03em; margin: 3.6rem 0 1rem; }
h3 { font-size: 1.06rem; font-weight: 600; letter-spacing: -.015em; margin: 2.2rem 0 .55rem; }
h4 { font-size: 1.02rem; font-weight: 600; margin: 0 0 .4rem; }
p { margin: 0 0 1.15rem; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 44rem; }  /* ~66 characters per line */
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; background: #fff; padding: 8px 12px; z-index: 10; }

/* ---------- header ---------- */
.site-header {
  background: var(--band); color: #fff;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px clamp(16px, 4vw, 48px);
}
.brand img { width: 120px; height: auto; }
.main-nav { display: flex; gap: clamp(14px, 2vw, 30px); flex-wrap: wrap; justify-content: flex-end; }
.main-nav a, .menu nav a { color: #f1eff6; font-size: .92rem; }
.main-nav a:hover, .menu nav a:hover { color: #fff; text-decoration: none; opacity: .75; }
.main-nav a[aria-current], .menu nav a[aria-current] { color: #9d98ad; }
.menu { display: none; }
@media (max-width: 900px) {
  .main-nav { display: none; }
  .menu { display: block; }
  .menu summary { display: flex; flex-direction: column; gap: 5px; cursor: pointer; list-style: none; padding: 8px; }
  .menu summary::-webkit-details-marker { display: none; }
  .menu summary span { width: 24px; height: 2px; background: #fff; }
  .menu nav { position: absolute; right: 0; left: 0; top: 92px; background: var(--band); display: flex; flex-direction: column; padding: 8px 24px 20px; z-index: 5; }
  .menu nav a { padding: 10px 0; border-bottom: 1px solid #2a2733; font-size: 1rem; }
}

/* ---------- hero bands ---------- */
.hero { background: linear-gradient(180deg, var(--band), #23202b); color: #fff; text-align: center; padding: clamp(44px, 6vw, 72px) 24px clamp(40px, 5.5vw, 66px); }
.hero h1 { color: #fff; margin: 0 auto; max-width: 900px; font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 300; letter-spacing: -.035em; }
.hero-sub { margin: 14px auto 0; max-width: 560px; font-weight: 500; color: #e7e4ef; }
.hero.image { background: linear-gradient(rgba(25, 10, 35, .55), rgba(25, 10, 35, .55)), url(/assets/img/hero-research.jpg) center / cover; }

/* ---------- home ---------- */
.page-home { background: var(--band-2); }
.home {
  position: relative; min-height: calc(100vh - 92px); display: grid; place-items: center;
  color: #fff; text-align: center; padding: 48px 24px 64px; overflow: hidden;
}
.home video.bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .85; }
.home::after { content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 55% 50% at 50% 50%, rgba(11,10,16,.66), rgba(11,10,16,.28) 72%, rgba(11,10,16,.45)); }
.home .inner { z-index: 1; }
.home .inner { position: relative; max-width: 940px; }
.home h1 { color: #fff; font-size: clamp(2.75rem, 6.7vw, 4.9rem); font-weight: 300; letter-spacing: -.035em; margin: 0 auto; line-height: 1.1; max-width: 17ch; }
.home .eyebrow { text-transform: uppercase; letter-spacing: .18em; font-size: .78rem; font-weight: 600; color: #c9a6e8; margin: 0 0 22px; }
.home .lead { color: rgba(255,255,255,.72); font-weight: 400; font-size: 1.08rem; line-height: 1.75; max-width: 36rem; margin: 28px auto 0; }
.home .cta { display: flex; gap: 12px; justify-content: center; margin: 34px 0 0; }
.home .cta a { color: #fff; border: 1px solid rgba(255,255,255,.35); border-radius: 6px; padding: 11px 20px; font-weight: 500; font-size: .95rem; }
.home .cta a:first-child { background: var(--accent); border-color: var(--accent); }
.home .cta a:hover { text-decoration: none; border-color: #fff; }
.home .updated { margin-top: 48px; font-size: .82rem; font-style: italic; color: #bdb8cc; }
.page-home .site-footer { background: var(--band-2); border-top-color: #1f1d27; }

/* ---------- content blocks ---------- */
main > section { padding: 56px 0 8px; }
.intro { font-size: 1.12rem; line-height: 1.65; }
.rule { width: 72px; height: 2px; background: var(--ink); border: 0; margin: 0 0 22px; }
.figure { margin: 28px 0 36px; }
.figure figcaption, .caption { font-size: .9rem; color: var(--muted); margin-top: 10px; }
.figure.center { text-align: center; }
.figure.center img, .figure.center video { margin: 0 auto; }
.refs { padding-left: 1.1rem; font-size: .95rem; color: var(--muted); }
.refs li { margin-bottom: .45rem; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.grid2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.tile { border: 1px solid var(--line); background: #fff; }
.tile video, .tile img { width: 100%; }
.tile p { text-align: center; margin: 10px 0; font-size: .95rem; }
.split { display: grid; grid-template-columns: 1.4fr 1fr; gap: 36px; align-items: start; }
@media (max-width: 760px) { .grid3, .grid2, .split, .cards { grid-template-columns: 1fr; } }

/* ---------- people ---------- */
.group-photo { max-width: 640px; margin: 0 auto; }
.avatars { display: flex; flex-wrap: wrap; justify-content: center; gap: 22px 28px; margin: 18px 0 8px; }
.avatars a { width: 128px; text-align: center; color: var(--ink); }
.avatars a:hover { text-decoration: none; color: var(--accent); }
.avatars img { width: 112px; height: 112px; border-radius: 50%; object-fit: cover; margin: 0 auto 10px; }
.avatars b { display: block; font-weight: 600; font-size: .95rem; line-height: 1.3; }
.avatars span { font-size: .82rem; color: var(--muted); }
.person { display: grid; grid-template-columns: 200px 1fr; gap: 32px; padding: 30px 0; max-width: 54rem; margin: 0 auto; border-top: 1px solid var(--line); align-items: start; }
.person img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.person h3 { margin-top: 0; }
.person .role { font-weight: 600; color: var(--muted); margin-bottom: .6rem; }
.alumni { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 26px 22px; }
.alumni article img { width: 100%; aspect-ratio: 1; object-fit: cover; margin-bottom: 12px; }
.alumni p { font-size: .92rem; color: var(--muted); }
@media (max-width: 760px) { .person { grid-template-columns: 1fr; } .person img { max-width: 320px; } }

/* ---------- publications ---------- */
.pubs { list-style: none; padding: 0; margin: 0; }
.pub { padding: 26px 0; border-top: 1px solid var(--line); }
.pub.with-fig { display: grid; grid-template-columns: 1fr 220px; gap: 28px; align-items: start; }
.pub h4 { color: var(--ink); font-weight: 600; letter-spacing: -.01em; }
.pub .authors { color: var(--muted); font-size: .95rem; margin: .2rem 0 .3rem; }
.pub .venue { font-weight: 500; font-size: .95rem; color: var(--ink); }
.pub .links { font-size: .95rem; margin-top: .3rem; line-height: 2; }
.pub .links a + a::before { content: '·'; color: var(--muted); margin: 0 .5rem; }
.pub img { border: 1px solid var(--line); }
.press { columns: 2; font-size: .95rem; margin: .5rem 0 0; padding-left: 1.1rem; }
.pubs.compact .pub { padding: 16px 0; }
.pubs.compact h4 { font-weight: 500; }
@media (max-width: 760px) { .pub.with-fig { grid-template-columns: 1fr; } .pub img { max-width: 220px; } .press { columns: 1; } }

/* ---------- resources ---------- */
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin: 18px 0; }
.card { display: block; border: 1px solid var(--line); padding: 20px; background: var(--soft); color: var(--ink); }
.card:hover { text-decoration: none; border-color: var(--accent); }
.card b { display: block; margin-bottom: 4px; }
.card span { font-size: .9rem; color: var(--muted); }
.card .go { color: var(--accent); font-weight: 600; font-size: .9rem; margin-top: 10px; display: block; }

.note { background: var(--soft); border-left: 3px solid var(--accent); padding: 14px 18px; font-weight: 500; }

@media (prefers-reduced-motion: reduce) { .home video.bg { display: none; } }

/* ---------- footer ---------- */
.site-footer { margin-top: 72px; border-top: 1px solid var(--line); padding: 26px 0; font-size: .88rem; color: var(--muted); }
.page-home .site-footer { margin-top: 0; color: #8f8a9e; }
.footer-grid { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px 24px; }
.footer-grid p { margin: 0; }
.social a { margin-left: 18px; }
.social a:first-child { margin-left: 0; }
