/* ankushyadav.in — one stylesheet. Colours are the variables below. */

@font-face { font-family: "Caladea"; src: local("Caladea"), url("../fonts/caladea-regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Caladea"; src: local("Caladea Italic"), url("../fonts/caladea-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Caladea"; src: local("Caladea Bold"), url("../fonts/caladea-bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Noto Serif Devanagari"; src: url("../fonts/noto-serif-devanagari-500.woff2") format("woff2"); font-weight: 400 700; font-display: swap; unicode-range: U+0900-097F, U+1CD0-1CFF, U+A8E0-A8FF; }

:root {
  --navy: #16203A;
  --saffron: #E8731A;
  --saffron-deep: #A84A0C;
  --gold: #B5850F;
  --wash: #F3F6FB;
  --rule: #DCE2EC;
  --muted: #4B556A;
  --paper: #FFFFFF;
  --serif: Cambria, "Caladea", "Noto Serif Devanagari", Georgia, serif;
  --measure: 40rem;
  --wrap: 72rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 6rem; }
body { margin: 0; background: var(--paper); color: var(--navy); font-family: var(--serif); font-size: 1.125rem; line-height: 1.68; font-kerning: normal; font-variant-numeric: oldstyle-nums; }
img, video, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--saffron-deep); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { color: var(--navy); }
:focus-visible { outline: 3px solid var(--saffron); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3 { line-height: 1.15; margin: 0; font-weight: 700; letter-spacing: -0.005em; font-variant-numeric: lining-nums; }
h1 { font-size: clamp(2.6rem, 5.4vw, 4.4rem); }
h2 { font-size: clamp(1.75rem, 3vw, 2.25rem); }
h3 { font-size: 1.35rem; }
p { margin: 0; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 1.5rem; }
.skip { position: absolute; left: -999px; top: 0; background: var(--navy); color: #fff; padding: 0.6rem 1rem; z-index: 99; }
.skip:focus { left: 1rem; top: 1rem; }
.lede { font-size: 1.3rem; line-height: 1.55; color: var(--muted); max-width: var(--measure); }
.muted { color: var(--muted); }
.prose { max-width: var(--measure); }
.prose p + p { margin-top: 1rem; }

/* ---------------------------------------------------------------- header */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(255,255,255,0.96); border-bottom: 1px solid var(--rule); backdrop-filter: blur(6px); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 4.5rem; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 0.75rem; text-decoration: none; color: var(--navy); }
.brand img { width: 2.6rem; height: 2.6rem; }
.brand span { font-size: 1.2rem; font-weight: 700; letter-spacing: 0.02em; }
.nav { display: flex; gap: 0.25rem 1.4rem; flex-wrap: wrap; }
.nav a { color: var(--navy); text-decoration: none; font-size: 1.02rem; padding: 0.55rem 0.05rem; border-bottom: 2px solid transparent; }
.nav a:hover { border-bottom-color: var(--rule); }
.nav a[aria-current="page"] { border-bottom-color: var(--saffron); }

/* ---------------------------------------------------------------- buttons */
.btn { display: inline-block; font-size: 1.05rem; font-weight: 700; text-decoration: none; padding: 0.8rem 1.5rem; border-radius: 3px; border: 2px solid var(--saffron); background: var(--saffron); color: var(--navy); }
.btn:hover { background: #F08A3A; border-color: #F08A3A; color: var(--navy); }
.btn.quiet { background: transparent; border-color: var(--navy); }
.btn.quiet:hover { background: var(--navy); color: #fff; }
.actions { display: flex; flex-wrap: wrap; gap: 0.8rem; }

/* ---------------------------------------------------------------- hero + watermark */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--rule); }
.hero-inner { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 1.4rem; padding: 4.5rem 1.5rem 5rem; max-width: 40rem; margin: 0 auto; }
.hero-mark { width: 11rem; height: 11rem; }
.hero .lede { margin: 0 auto; }
.hero .actions { justify-content: center; margin-top: 0.4rem; }
.wm { position: absolute; inset: 0; display: grid; grid-template-columns: 1fr minmax(34rem, 38rem) 1fr; pointer-events: none; user-select: none; }
.wm-col { display: flex; flex-direction: column; justify-content: space-around; padding: 2.5rem 1.5rem; }
.wm-gita { text-align: right; }
.wm-row { display: flex; flex-direction: column; gap: 0.15rem; }
.wm-line { font-size: clamp(1.05rem, 1.55vw, 1.55rem); line-height: 1.3; color: rgba(22, 32, 58, 0.17); white-space: nowrap; }
.wm-gita .wm-line { font-family: "Noto Serif Devanagari", var(--serif); font-size: clamp(1rem, 1.45vw, 1.45rem); white-space: normal; }
.wm-mech .wm-line { font-style: italic; }
.wm-gloss { font-size: clamp(0.78rem, 0.95vw, 0.9rem); color: rgba(22, 32, 58, 0.24); }
.wm sub, .wm sup { font-size: 0.65em; }

/* ---------------------------------------------------------------- sections */
.section { padding: 5rem 0; }
.section.tint { background: var(--wash); }
.section-head { display: flex; flex-direction: column; gap: 0.6rem; margin-bottom: 2.6rem; max-width: var(--measure); }

.trio { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.6rem; }
.trio h3 { font-size: 1.6rem; padding-top: 1rem; border-top: 3px solid var(--saffron); display: inline-block; }
.trio p { margin-top: 0.7rem; color: var(--muted); }

.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1.4rem; counter-reset: step; }
.steps li { position: relative; padding-top: 2.6rem; }
.steps li::before { counter-increment: step; content: counter(step); position: absolute; top: 0; left: 0; width: 1.9rem; height: 1.9rem; border-radius: 50%; background: var(--paper); border: 2px solid var(--saffron); color: var(--saffron-deep); font-weight: 700; font-size: 1rem; line-height: 1.75rem; text-align: center; font-variant-numeric: lining-nums; }
.steps li::after { content: ""; position: absolute; top: 0.95rem; left: 2.3rem; right: -1.2rem; height: 2px; background: var(--rule); }
.steps li:last-child::after { display: none; }
.steps strong { display: block; font-size: 1.25rem; }
.steps span { color: var(--muted); font-size: 1rem; line-height: 1.5; }

.news { list-style: none; margin: 0; padding: 0; max-width: 52rem; }
.news li { display: grid; grid-template-columns: 7.5rem 1fr; gap: 1.5rem; padding: 1.1rem 0; border-top: 1px solid var(--rule); }
.news li:last-child { border-bottom: 1px solid var(--rule); }
.news time { color: var(--muted); font-variant-numeric: lining-nums; white-space: nowrap; }

/* ---------------------------------------------------------------- contact */
.contact { display: flex; flex-direction: column; gap: 1.2rem; }
.contact .email { font-size: clamp(1.25rem, 2.6vw, 1.7rem); font-weight: 700; color: var(--navy); text-decoration: none; display: inline-flex; align-items: center; gap: 0.7rem; overflow-wrap: anywhere; }
.contact .email:hover { color: var(--saffron-deep); }
.contact .email svg { width: 1.4rem; height: 1.4rem; flex: none; color: var(--saffron-deep); }
.profiles { display: flex; flex-wrap: wrap; gap: 0.8rem; }
.profiles a { display: inline-flex; align-items: center; gap: 0.55rem; text-decoration: none; color: var(--navy); border: 1px solid var(--rule); background: var(--paper); padding: 0.6rem 1rem; border-radius: 3px; font-size: 1rem; min-height: 2.75rem; }
.profiles a:hover { border-color: var(--navy); color: var(--navy); }
.profiles svg { width: 1.3rem; height: 1.3rem; flex: none; }
.profiles .li svg { color: #0A66C2; }
.profiles .gs svg { color: #4285F4; }
.profiles .orcid svg { color: #A6CE39; }

/* ---------------------------------------------------------------- page head */
.page-head { background: var(--wash); border-bottom: 1px solid var(--rule); }
.page-head .wrap { padding-top: 4rem; padding-bottom: 3.4rem; display: flex; flex-direction: column; gap: 1rem; }

/* ---------------------------------------------------------------- research */
.study { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 3rem; align-items: center; padding: 3.4rem 0; border-top: 1px solid var(--rule); }
.study:first-of-type { border-top: 0; }
.study.flip > .study-media { order: -1; }
.study-text { display: flex; flex-direction: column; gap: 0.9rem; }
.study-text .src { font-size: 1rem; color: var(--muted); }
.study-media figure { margin: 0; }
.study-media video, .study-media img { width: 100%; border: 1px solid var(--rule); border-radius: 3px; background: var(--paper); }
figcaption { font-size: 0.95rem; color: var(--muted); margin-top: 0.6rem; line-height: 1.5; }
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.4rem; }
.plans h3 { margin-bottom: 0.6rem; }
.plans p { color: var(--muted); }
.tags { display: flex; flex-wrap: wrap; gap: 0.6rem; list-style: none; margin: 0; padding: 0; }
.tags li { border: 1px solid var(--rule); background: var(--paper); padding: 0.4rem 0.9rem; border-radius: 3px; font-size: 1rem; }

/* ---------------------------------------------------------------- publications */
.pubs { list-style: none; margin: 0; padding: 0; }
.pubs li { display: grid; grid-template-columns: 4.5rem 1fr; gap: 1.4rem; padding: 1.3rem 0; border-top: 1px solid var(--rule); }
.pubs li:last-child { border-bottom: 1px solid var(--rule); }
.pubs .yr { font-weight: 700; color: var(--saffron-deep); font-variant-numeric: lining-nums; }
.pubs .t { font-weight: 700; display: block; }
.pubs .a, .pubs .v { display: block; color: var(--muted); font-size: 1.02rem; }
.pubs .a b { color: var(--navy); }
.pub-group + .pub-group { margin-top: 3.4rem; }
.pub-group h2 { margin-bottom: 1rem; }

/* ---------------------------------------------------------------- applications */
.app { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 3rem; align-items: center; padding: 3.6rem 0; border-top: 1px solid var(--rule); }
.app:first-of-type { border-top: 0; }
.app.flip > figure { order: 1; }
.app figure { margin: 0; }
.app figure img { width: 100%; border: 1px solid var(--rule); border-radius: 3px; background: var(--paper); }
.app-text { display: flex; flex-direction: column; gap: 0.9rem; }
.app-domain { font-size: 1.05rem; color: var(--saffron-deep); font-weight: 700; }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 0.35rem 1.2rem; margin: 0.4rem 0 0; }
.facts dt { font-weight: 700; }
.facts dd { margin: 0; color: var(--muted); }

/* ---------------------------------------------------------------- about */
.intro { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 3.5rem; align-items: center; }
.intro .mark { width: 100%; max-width: 19rem; justify-self: center; }
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { display: grid; grid-template-columns: 11rem 1fr; gap: 1.5rem; padding: 1.2rem 0; border-top: 1px solid var(--rule); }
.timeline li:last-child { border-bottom: 1px solid var(--rule); }
.timeline time { color: var(--muted); font-variant-numeric: lining-nums; }
.timeline strong { display: block; }
.timeline .sub { display: block; color: var(--muted); }
.timeline ul { margin: 0.5rem 0 0; padding-left: 1.1rem; color: var(--muted); }
.timeline ul li { display: list-item; border: 0; padding: 0.15rem 0; }
.cols-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3rem; }
.meaning { width: 100%; border-collapse: collapse; font-size: 1.02rem; }
.meaning th, .meaning td { text-align: left; vertical-align: top; padding: 0.9rem 1rem; border-top: 1px solid var(--rule); }
.meaning thead th { border-top: 0; border-bottom: 2px solid var(--navy); font-size: 1.05rem; }
.meaning tbody th { width: 16%; }
.meaning td { color: var(--muted); }
.table-scroll { overflow-x: auto; }
.motto { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 0.4rem; }
.motto .deva { font-family: "Noto Serif Devanagari", var(--serif); font-size: clamp(1.8rem, 4vw, 2.6rem); color: var(--saffron-deep); line-height: 1.4; }

/* ---------------------------------------------------------------- notes / opinion */
.post { max-width: var(--measure); padding: 2.6rem 0; border-top: 1px solid var(--rule); }
.post:first-of-type { border-top: 0; }
.post time { color: var(--muted); font-size: 1rem; }
.post h2 { margin: 0.3rem 0 1rem; font-size: 1.8rem; }
.post p + p { margin-top: 1rem; }
.empty { max-width: var(--measure); border: 1px dashed #B4BED0; background: var(--paper); padding: 2rem; border-radius: 3px; }

/* ---------------------------------------------------------------- footer */
.site-footer { background: var(--navy); color: #fff; }
.site-footer .wrap { padding-top: 3rem; padding-bottom: 3rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 2rem; }
.foot-brand { display: flex; align-items: center; gap: 1rem; }
.foot-brand img { width: 3.6rem; height: 3.6rem; }
.foot-brand strong { display: block; letter-spacing: 0.02em; }
.foot-brand span { color: #C9D2E2; font-size: 1rem; }
.foot-gita { text-align: right; display: flex; flex-direction: column; gap: 0.15rem; }
.foot-gita .deva { font-family: "Noto Serif Devanagari", var(--serif); color: var(--gold); font-size: 1.35rem; }
.foot-gita span { color: #C9D2E2; font-size: 0.98rem; }
.site-footer a { color: #fff; }
.foot-links { display: flex; gap: 1rem; }
.foot-links a { display: inline-flex; width: 2.75rem; height: 2.75rem; align-items: center; justify-content: center; border: 1px solid rgba(255,255,255,0.25); border-radius: 3px; }
.foot-links a:hover { border-color: #fff; }
.foot-links svg { width: 1.25rem; height: 1.25rem; color: #fff; }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 72rem) {
  .wm { grid-template-columns: 1fr; }
  .wm-mech { display: none; }
  .wm-gita { text-align: center; align-items: center; }
  .wm-line { color: rgba(22, 32, 58, 0.075); }
  .wm-gloss { display: none; }
  .steps { grid-template-columns: 1fr; gap: 1.2rem; }
  .steps li { padding: 0 0 0 3rem; }
  .steps li::after { top: 2.2rem; bottom: -1.2rem; left: 0.9rem; right: auto; width: 2px; height: auto; }
}
@media (max-width: 52rem) {
  .trio, .plans, .cols-2 { grid-template-columns: 1fr; gap: 2.2rem; }
  .study, .app, .intro { grid-template-columns: 1fr; gap: 1.8rem; }
  .study.flip > .study-media, .app.flip > figure { order: 0; }
  .intro .mark { max-width: 12rem; order: -1; }
  .news li, .timeline li { grid-template-columns: 1fr; gap: 0.2rem; }
  .pubs li { grid-template-columns: 1fr; gap: 0.2rem; }
  .section { padding: 3.6rem 0; }
  .foot-gita { text-align: left; }
  .site-header { position: static; }
  .nav { gap: 0.1rem 1.1rem; }
}
@media (max-width: 30rem) { .hero .actions { flex-direction: column; width: 100%; } .hero .actions .btn { text-align: center; } }
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; } }
@media print { .site-header, .wm, .site-footer { display: none; } }
