:root {
  color-scheme: light;
  --paper: #f6f5ef;
  --clean: #fffefa;
  --ink: #171818;
  --muted: #4f514f;
  --line: #c5c4b9;
  --light-line: #d9d7ce;
  --blue: #242bc4;
  --pale-blue: #e6e7ff;
  --mono: ui-monospace, 'SFMono-Regular', Consolas, monospace;
  --sans: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 90px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.58 var(--sans); }
h1, h2, h3, h4, p, ul, ol, figure, dl, dd { margin: 0; }
h1, h2, h3, h4 { text-wrap: balance; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button { cursor: pointer; }
img { display: block; max-width: 100%; }
svg { display: block; flex: 0 0 auto; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 4px; }
::selection { color: #fff; background: var(--blue); }
.wrap { width: min(100% - 104px, 1320px); margin-inline: auto; }
.section { margin-block: clamp(65px, 7.4vw, 110px); }
.sr-only, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip:focus { position: fixed; z-index: 8; top: 9px; left: 12px; padding: .6rem .8rem; color: white; background: var(--blue); }

.header { position: sticky; top: 0; z-index: 3; border-bottom: 1px solid var(--line); background: #f6f5eff7; backdrop-filter: blur(12px); }
.header-inner { min-height: 64px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 20px; }
.brand { display: inline-flex; align-items: center; gap: 10px; justify-self: start; white-space: nowrap; font: 730 .91rem/1.2 var(--mono); letter-spacing: -.035em; }
.brand img { flex: 0 0 auto; }
.main-nav { display: flex; gap: clamp(15px, 3vw, 43px); align-items: center; }
.main-nav a { font-weight: 700; font-size: .89rem; padding-block: 7px; }
.main-nav a:hover, .footer a:hover { color: var(--blue); text-decoration: underline; text-underline-offset: 4px; }
.language-switch { display: flex; justify-self: end; align-items: center; gap: 0; border: 1px solid #a9a8aa; }
.language-switch a { display: grid; place-items: center; min-width: 36px; min-height: 31px; font: 730 .78rem/1 var(--mono); }
.language-switch a:hover { background: var(--pale-blue); }
.language-switch a[aria-current="page"] { background: var(--blue); color: #fff; }

.masthead { min-height: 302px; display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(270px, .73fr); align-items: end; gap: clamp(30px, 5vw, 75px); padding-block: clamp(37px, 4.3vw, 62px) 29px; }
.masthead h1 { color: var(--ink); font-weight: 780; font-size: clamp(4.6rem, 7.8vw, 8rem); line-height: .81; letter-spacing: -.075em; text-wrap: initial; }
.masthead h1 > span { display: block; color: var(--blue); margin-top: .1em; }
.masthead-period { letter-spacing: -.12em; }
.masthead-bio { margin-bottom: 5px; border-left: 1px solid var(--line); padding-left: clamp(19px, 3vw, 37px); }
.eyebrow { font: 700 .76rem/1.35 var(--mono); letter-spacing: .035em; text-transform: uppercase; color: var(--blue); }
.masthead-bio .eyebrow { display: flex; align-items: center; gap: 7px; }
.blue-block { width: 8px; height: 8px; background: var(--blue); flex: 0 0 auto; }
.masthead-bio h2 { margin-top: 8px; font-weight: 750; font-size: clamp(1.58rem, 2.75vw, 2.6rem); line-height: 1; letter-spacing: -.06em; text-wrap: initial; }
.masthead-bio > p:not(.eyebrow) { color: var(--muted); line-height: 1.51; margin-top: 9px; max-width: 42ch; }
.masthead-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 15px; margin-top: 18px; }
.masthead-actions a { min-height: 39px; display: inline-flex; align-items: center; gap: 7px; font-size: .86rem; font-weight: 740; color: var(--blue); }
.masthead-actions a:first-child { background: var(--blue); color: white; padding-inline: 12px; }
.masthead-actions a:first-child:hover { background: #171d99; }
.masthead-actions a:last-child:hover { text-decoration: underline; text-underline-offset: 4px; }
.masthead-actions svg { width: 16px; height: 16px; }

.feature-section { margin-top: 14px; }
.feature-heading { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px 15px; padding: 11px 0; border-block: 1px solid var(--line); }
.feature-heading h2 { font: 730 .82rem/1.25 var(--mono); text-transform: uppercase; letter-spacing: .038em; }
.feature-heading nav, .footer nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.feature-heading nav a, .footer nav a { display: inline-flex; align-items: center; gap: 3px; font-size: .82rem; font-weight: 680; }
.feature-heading nav a:hover { color: var(--blue); }
.feature-heading nav svg, .footer nav svg { width: 14px; height: 14px; }
.feature-grid { display: grid; grid-template-columns: 1fr 1.5fr 1fr; gap: 10px; padding-top: 10px; }
.feature { min-width: 0; display: block; border: 1px solid var(--line); background: var(--clean); transition: border-color .2s; }
.feature:hover { border-color: var(--blue); }
.feature-media { height: clamp(160px, 15.5vw, 233px); display: flex; justify-content: center; align-items: flex-end; position: relative; overflow: hidden; border-bottom: 1px solid var(--light-line); }
.feature-media img { transition: transform .24s; }
.feature-media.phone { gap: clamp(8px, 1.15vw, 17px); padding: 17px 10px 0; background: #f0e2ff; }
.feature-dijital .feature-media { background: #dcece3; }
.feature-media.phone img { width: auto; max-width: 41%; height: 98%; object-fit: contain; object-position: bottom; filter: drop-shadow(0 8px 10px #16161626); }
.feature-media.phone img:first-child { transform: translateY(7px) rotate(-4deg); }
.feature-media.phone img:nth-child(2) { transform: translateY(19px) rotate(5deg); }
.feature:hover .feature-media.phone img:first-child { transform: translateY(2px) rotate(-2deg); }
.feature:hover .feature-media.phone img:nth-child(2) { transform: translateY(13px) rotate(3deg); }
.feature-media.hybrid { background: #e4e8ff; align-items: center; justify-content: flex-start; padding: 15px 19px; }
.feature-media.hybrid img:first-child { width: 82%; height: auto; max-height: 100%; object-fit: contain; box-shadow: 0 8px 19px #20266626; }
.feature-media.hybrid img:nth-child(2) { width: auto; position: absolute; bottom: 7%; right: 7%; height: 71%; box-shadow: 0 5px 10px #20266636; }

.feature-meta { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; min-height: 83px; padding: 12px 14px; }
.feature-meta h3 { font-size: clamp(1.08rem, 1.65vw, 1.51rem); line-height: 1.08; font-weight: 760; letter-spacing: -.045em; text-wrap: initial; margin-top: 4px; }
.feature-meta > svg { color: var(--blue); }
.feature-meta .eyebrow { font-size: .7rem; }

.index-heading { display: flex; gap: 18px; align-items: flex-end; justify-content: space-between; padding-bottom: 17px; border-bottom: 2px solid var(--ink); }
.index-heading h2, .section-heading h2 { font-size: clamp(2.4rem, 5vw, 5.2rem); font-weight: 770; line-height: .97; letter-spacing: -.079em; }
.section-intro { color: var(--muted); max-width: 65ch; margin-top: 12px; }
.index-total { color: var(--blue); font: 650 clamp(1.7rem, 4vw, 3.2rem)/1 var(--mono); letter-spacing: -.09em; }
.index-controls { display: flex; justify-content: space-between; gap: 10px; align-items: center; min-height: 64px; border-bottom: 1px solid var(--line); }
.filters { display: flex; flex-wrap: wrap; gap: 5px; }
.filters button { border: 1px solid transparent; background: transparent; font: 670 .82rem/1.25 var(--sans); color: var(--ink); padding: 7px 9px; min-height: 35px; }
.filters button:hover { border-color: #a4a1b4; }
.filters button[aria-pressed="true"] { background: var(--pale-blue); color: var(--blue); border-color: #b5b7ed; }
.search-box { display: flex; min-width: 200px; align-items: center; gap: 6px; border: 1px solid #a7a5a1; padding: 0 7px; background: var(--clean); }
.search-box > svg { color: var(--blue); width: 17px; height: 17px; }
.search-box input { width: 100%; min-width: 0; border: 0; color: var(--ink); background: none; height: 36px; font-size: .87rem; }
.search-box input::-webkit-search-cancel-button { display: none; }
.search-box button { padding: 3px; border: 0; color: var(--blue); background: none; }
.search-box button svg { width: 17px; height: 17px; }
.index-row { display: grid; grid-template-columns: minmax(200px, 1fr) minmax(240px, 1.37fr) minmax(110px, .48fr) 29px; align-items: center; gap: clamp(9px, 2vw, 28px); position: relative; border-bottom: 1px solid var(--line); padding: 17px 9px; transition: background .18s; min-height: 102px; }
.index-row:hover { background: #ecebf6; }
.index-title h3 { font-size: clamp(1.3rem, 2.1vw, 2rem); font-weight: 755; line-height: 1.06; letter-spacing: -.05em; margin-top: 4px; text-wrap: initial; }
.index-title h3 a::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.index-row:focus-within { outline: 2px solid var(--blue); outline-offset: 0; }
.index-row h3 a:focus-visible { outline: none; }
.index-summary p { color: var(--muted); line-height: 1.45; font-size: .94rem; }
.index-summary .tags { margin-top: 7px; }
.tags { list-style: none; display: flex; flex-wrap: wrap; gap: 4px; padding: 0; }
.tags li { border: 1px solid var(--light-line); color: #454754; padding: 2px 6px; background: #f9f8f4; font: 560 .72rem/1.35 var(--mono); overflow-wrap: anywhere; }
.status { display: inline-flex; gap: 6px; align-items: baseline; font: 630 .79rem/1.35 var(--mono); color: #3d4052; }
.status i { width: 7px; height: 7px; border: 1px solid currentColor; border-radius: 50%; background: currentColor; flex: 0 0 auto; }
.status-live { color: #216046; }
.status-development { color: #78481e; }
.status-development i, .status-practice i { background: transparent; }
.status-open, .status-research { color: var(--blue); }
.index-icon { color: var(--blue); justify-self: end; }
.index-icon svg { width: 22px; height: 22px; }
.empty { padding: 30px 8px; color: var(--muted); border-bottom: 1px solid var(--line); }

.research-band { border-block: 1px solid #bec0df; background: #efeffc; padding-block: clamp(36px, 6vw, 82px); }
.research-layout, .about { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(25px, 7.5vw, 105px); }
.section-heading h2 { margin-top: 8px; }
.research-layout .section-intro, .about .section-intro { max-width: 54ch; font-size: 1.07rem; }
.research-list { border-top: 1px solid #bfc1de; }
.research-list article { padding: 14px 0; border-bottom: 1px solid #bfc1de; }
.research-list h3, .service-list h3, .timeline h3, .stack h3 { font-size: 1.19rem; font-weight: 750; line-height: 1.25; letter-spacing: -.034em; }
.research-list p, .service-list p { margin-top: 5px; color: var(--muted); }
.inline-link { color: var(--blue); font-size: .9rem; font-weight: 700; text-decoration: underline; text-underline-offset: 4px; }
.research-list a { display: inline-flex; align-items: center; gap: 4px; margin-top: 7px; }
.research-list a svg { width: 14px; height: 14px; }
.stack { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line); }
.stack > div { margin-top: 10px; }
.stack h4 { font-size: .89rem; margin-bottom: 4px; }
.timeline ol { list-style: none; padding: 0; margin-top: 11px; border-top: 1px solid var(--line); }
.timeline li { padding-block: 11px; border-bottom: 1px solid var(--line); }
.timeline li h4 { margin-top: 4px; font-size: 1.03rem; }
.timeline li p:not(.eyebrow) { color: var(--muted); font-size: .95rem; }
.timeline-role { font-weight: 670; }
.services .section-heading { margin-bottom: 19px; }
.service-list { border-top: 1px solid var(--line); }
.service-list a { display: grid; grid-template-columns: minmax(170px, 1fr) 1.4fr 20px; align-items: center; gap: 11px; padding: 13px 6px; border-bottom: 1px solid var(--line); }
.service-list a:hover { background: #ecebf6; }
.service-list p { margin: 0; }
.service-list svg { color: var(--blue); }
.contact-band { background: var(--blue); color: white; padding-block: clamp(30px, 5vw, 65px); }
.contact-band :focus-visible { outline-color: #fff; }
.contact-panel { display: grid; grid-template-columns: 1.25fr 1fr; align-items: center; gap: 35px; }
.contact-panel .eyebrow, .contact-panel .section-intro { color: #e7e7ff; }
.contact-form, .contact-topic { display: grid; gap: 7px; }
.contact-form { position: relative; max-width: 420px; width: 100%; justify-self: end; }
.contact-topic label { font-size: .88rem; font-weight: 670; }
.contact-topic select { width: 100%; min-width: 0; min-height: 43px; padding: 7px; border: 1px solid #9296f2; color: white; background: #2428a8; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 43px; padding: 7px 12px; border: 1px solid transparent; font-size: .89rem; font-weight: 715; text-align: center; line-height: 1.25; }
.button svg { width: 17px; height: 17px; }
.primary { color: white; background: var(--blue); }
.primary:hover { background: #171d99; }
.secondary { border-color: #9799bf; color: var(--blue); background: var(--clean); }
.secondary:hover { background: var(--pale-blue); }
.contact-form .primary { color: var(--blue); background: #fff; }
.contact-form .primary:hover { background: #e8e8ff; }
.email-row { display: flex; justify-content: center; align-items: center; gap: 9px; min-width: 0; }
.email-row a { font-size: .92rem; color: white; overflow-wrap: anywhere; text-decoration: underline; text-underline-offset: 4px; }
.copy-email { display: grid; place-items: center; width: 32px; height: 32px; padding: 0; color: white; border: 1px solid #9296f2; background: transparent; }
.copy-email:hover { background: #4048d5; }
.copy-email svg { width: 16px; height: 16px; }
.copy-status { position: absolute; bottom: -19px; left: 0; right: 0; font-size: .76rem; color: #e7e8ff; text-align: center; }

.footer { border-top: 1px solid var(--line); }
.footer-inner { min-height: 75px; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-block: 12px; }
.footer-inner > .brand { white-space: normal; }
.footer nav { color: var(--muted); }

.detail { padding-block: 23px 65px; }
.breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--muted); font-size: .86rem; }
.breadcrumb a { text-decoration: underline; text-underline-offset: 3px; }
.detail-header { display: grid; grid-template-columns: 1fr minmax(150px, 255px); align-items: end; gap: 20px; padding: clamp(24px, 4vw, 58px) 0 20px; border-bottom: 2px solid var(--ink); }
.detail-header h1 { margin-top: 9px; font-size: clamp(3rem, 7.1vw, 7rem); font-weight: 760; letter-spacing: -.071em; line-height: .94; overflow-wrap: anywhere; text-wrap: initial; }
.detail-intro { margin-top: 14px; max-width: 68ch; color: var(--muted); font-size: clamp(1.01rem, 1.8vw, 1.24rem); line-height: 1.5; }
.detail-meta { padding: 0 0 2px 14px; border-left: 1px solid var(--line); }
.detail-meta .tags { margin-top: 7px; }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-bottom: 1px solid var(--line); }
.facts div { min-width: 0; padding: 15px 11px; }
.facts div + div { border-left: 1px solid var(--line); }
.facts dt { color: var(--blue); font-weight: 740; letter-spacing: -.025em; line-height: 1.22; }
.facts dd { color: var(--muted); margin-top: 4px; font-size: .92rem; }
.gallery, .detail-visual, .flow, .technical, .sample, .detail-contact, .related { margin-top: clamp(34px, 5vw, 60px); }
.detail h2 { font-size: clamp(1.9rem, 4vw, 3.8rem); font-weight: 750; letter-spacing: -.065em; line-height: 1.02; }
.gallery-grid { display: grid; gap: 10px; margin-top: 12px; }
.gallery-grid.wide { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gallery-grid.wide figure:only-child { grid-column: 1 / -1; }
.gallery-grid.phone { grid-template-columns: repeat(auto-fit, minmax(min(205px, 100%), 1fr)); }
.gallery-grid.hybrid { grid-template-columns: 2.25fr .65fr .65fr; }
.gallery-grid figure { min-width: 0; align-self: stretch; display: flex; flex-direction: column; }
.gallery-grid figure a { flex: 1; display: grid; place-items: center; background: #eae9f1; border: 1px solid var(--light-line); min-width: 0; }
.gallery-grid figure a:hover { border-color: var(--blue); }
.gallery-grid img { width: 100%; height: auto; }
.gallery-grid.phone img, .gallery-grid.hybrid figure:not(:first-child) img { width: auto; max-height: 560px; }
.gallery-grid.phone figure a { padding: 15px; }
.gallery-grid figcaption { padding-block: 5px; font: 570 .77rem/1.45 var(--mono); color: var(--muted); }
.flow ol { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); list-style: none; gap: 7px; margin-top: 11px; padding: 0; }
.flow li { background: #eeeef9; border-top: 2px solid var(--blue); padding: 11px 10px; min-width: 0; }
.flow strong, .flow span { display: block; }
.flow span { font-size: .9rem; color: var(--muted); }
.technical-list { margin-top: 12px; border-top: 1px solid var(--line); }
.technical-list article { display: grid; grid-template-columns: 1fr 2fr; gap: 17px; border-bottom: 1px solid var(--line); padding: 13px 0; }
.technical-list h3, .sample h3 { font-size: 1.17rem; font-weight: 740; line-height: 1.25; letter-spacing: -.034em; }
.technical-list p { color: var(--muted); max-width: 83ch; }
.detail-actions { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 11px; }
.related { border-top: 1px solid var(--line); padding-top: 16px; }
.related ul { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 11px; padding: 0; }
.related a { display: inline-flex; align-items: center; gap: 4px; font-weight: 690; color: var(--blue); }
.related a:hover { text-decoration: underline; text-underline-offset: 4px; }
.related svg { width: 15px; height: 15px; }
.sample details { margin-top: 11px; padding: 12px; border: 1px solid var(--line); background: var(--clean); }
.sample summary { cursor: pointer; font-weight: 720; color: var(--blue); padding: 3px; }
.sample-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin-top: 10px; }
.sample h3 { margin-bottom: 5px; }
.sample-paper, .sample pre { min-height: 140px; margin: 0 0 5px; padding: 11px; border: 1px solid #d9d9ea; background: #f1f0fa; }
.sample table { border-collapse: collapse; margin-top: 6px; }
.sample td, .sample th { border: 1px solid #b5b4ca; padding: 2px 9px; text-align: left; font-size: .88rem; }
.sample pre { font: .86rem/1.5 var(--mono); color: #303276; overflow-x: auto; }

.viz { position: relative; overflow: hidden; display: flex; justify-content: center; align-items: center; min-height: 195px; padding: 18px; font-family: var(--mono); border: 1px solid var(--light-line); }
.viz-market { flex-direction: column; min-height: 310px; gap: 9px; background-color: #e9e9fa; background-image: linear-gradient(#fbfbff 1px, transparent 1px), linear-gradient(90deg, #fbfbff 1px, transparent 1px); background-size: 22px 22px; }
.board { width: min(100%, 625px); background: var(--clean); border: 1px solid #b9b8d8; box-shadow: 0 10px 24px #30337f17; font: .76rem/1.35 var(--sans); }
.board-top { display: flex; justify-content: space-between; align-items: center; gap: 6px; padding: 10px; border-bottom: 1px solid #ddddee; }
.board-top > span { color: #535470; white-space: nowrap; }
.board-dots { display: flex; gap: 3px; }
.board-dots i, .board-sources i { width: 5px; height: 5px; border-radius: 50%; background: #8384b1; display: inline-block; }
.board-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; margin: 8px 10px 0; }
.board-stats > div, .board-chart { padding: 6px 7px; background: #f1f1fb; border: 1px solid #ddddee; }
.board-stats span { color: #515373; }
.board-stats strong { display: block; font-size: 1.05rem; }
.board-chart { margin: 5px 10px 0; }
.bars { height: 74px; display: grid; grid-template-columns: repeat(12, 1fr); align-items: end; gap: 4px; margin-top: 4px; background: repeating-linear-gradient(0deg, #d9d9ee 0 1px, transparent 1px 17px); }
.bars i { height: var(--bar); background: #555bb7; }
.bars i:nth-child(2n) { background: #a4a8df; }
.board-sources { display: flex; gap: 10px; flex-wrap: wrap; margin: 6px 10px; color: #515373; font-size: .69rem; }
.board-sources i { margin-right: 4px; background: #bf784e; }
.board-sources span:last-child i { background: #676bb3; }
.viz-market figcaption { color: #535470; font-size: .72rem; text-align: center; }
.viz-ocr { background: #eeebf5; gap: 14px; }
.paper-sheet { width: 65px; height: 82px; padding: 12px 8px; border: 1px solid #b6aace; background: #fbf9ff; transform: rotate(-8deg); }
.paper-sheet i { display: block; height: 3px; background: #b4a8c8; margin-bottom: 5px; }
.paper-sheet i:nth-child(2) { width: 70%; }
.paper-sheet > div { height: 18px; border: 1px solid #b4a8c8; }
.paper-code { padding: 8px 10px; border: 1px solid #b6aace; background: #fcf9ff; color: #4c3b6a; font-size: .7rem; transform: rotate(5deg); }
.paper-code b, .paper-code small, .paper-code span { display: block; }
.paper-code span { white-space: nowrap; }
.viz-rag { background: #e5efea; }
.rag-file { display: grid; gap: 5px; width: 64px; padding: 8px; border: 1px solid #8ba99d; background: #f5fcf8; color: #335e4f; font-size: .75rem; }
.rag-file i { height: 3px; background: #9dbbae; }
.connector { width: clamp(13px, 5vw, 78px); height: 1px; background: repeating-linear-gradient(90deg, #829b8a 0 4px, transparent 4px 8px); }
.rag-outputs { display: grid; gap: 4px; }
.rag-outputs span { padding: 3px 7px; border: 1px solid #a5bfb3; color: #335e4f; background: #f4faf5; font-size: .7rem; }
.viz-pano { background: #f2ebdf; }
.pano-box { display: grid; justify-items: center; gap: 5px; color: #624d3e; font-size: .69rem; }
.pano-box i { width: 38px; height: 23px; border: 1px solid #a28372; background: #fdf8ee; }
.pano-relay { display: grid; place-items: center; width: 37px; height: 37px; margin: 0 4px 8px; border: 1px solid #a28372; color: #735541; background: #fdf7ef; }
.viz-pano .connector { margin-bottom: 8px; background: repeating-linear-gradient(90deg, #aa8e7c 0 4px, transparent 4px 8px); }

@media (max-width: 1100px) {
  .wrap { width: calc(100% - 70px); }
  .masthead { grid-template-columns: minmax(0, 1.5fr) minmax(250px, .85fr); gap: 28px; }
  .masthead h1 { font-size: clamp(3.8rem, 8.15vw, 6rem); }
}
@media (max-width: 820px) {
  .wrap { width: calc(100% - 42px); }
  .header-inner { gap: 10px; }
  .main-nav { gap: 13px; }
  .main-nav a { font-size: .83rem; }
  .masthead { min-height: 0; padding-block: 35px 19px; }
  .masthead h1 { font-size: clamp(3.2rem, 8.3vw, 4.7rem); }
  .masthead-bio { padding-left: 13px; }
  .index-row { grid-template-columns: minmax(155px, .82fr) minmax(180px, 1.2fr) minmax(85px, .45fr) 20px; gap: 10px; }
}
@media (max-width: 650px) {
  html { scroll-padding-top: 103px; }
  .wrap { width: calc(100% - 28px); }
  .header-inner { min-height: 0; padding-top: 6px; grid-template-columns: 1fr auto; row-gap: 2px; }
  .main-nav { grid-row: 2; grid-column: 1 / -1; justify-content: space-between; gap: 4px; }
  .language-switch a { min-height: 27px; min-width: 31px; }
  .masthead { grid-template-columns: 1fr; gap: 16px; padding-block: 24px 5px; }
  .masthead h1 { font-size: clamp(2.85rem, 10.9vw, 4.8rem); }
  .masthead-bio h2 { font-size: 1.66rem; }
  .masthead-actions { margin-top: 10px; }
  .feature-section { margin-top: 12px; }
  .feature-heading { gap: 6px; padding-block: 7px; }
  .feature-heading nav { gap: 6px 10px; }
  .feature-heading nav a { font-size: .75rem; }
  .feature-grid { grid-template-columns: 1fr 1fr; gap: 6px; padding-top: 6px; }
  .feature-afet { grid-row: 2; grid-column: 1 / -1; }
  .feature-media { height: clamp(122px, 32vw, 220px); }
  .feature-media.hybrid { height: clamp(154px, 42vw, 238px); }
  .feature-media.hybrid img:first-child { max-height: 94%; width: auto; }
  .feature-meta { padding: 7px; min-height: 58px; align-items: center; gap: 4px; }
  .feature-meta .eyebrow { font-size: .59rem; }
  .feature-meta svg { width: 15px; height: 15px; }
  .section { margin-block: 49px; }
  .index-controls { flex-wrap: wrap; padding-block: 7px; gap: 6px; }
  .search-box { width: 100%; }
  .index-row { min-height: 0; grid-template-columns: minmax(0, 1fr) 20px; gap: 6px; padding: 11px 3px; }
  .index-title { grid-column: 1; }
  .index-summary, .index-status { grid-column: 1 / -1; }
  .index-icon { grid-column: 2; grid-row: 1; align-self: center; }
  .research-layout, .about, .contact-panel { grid-template-columns: 1fr; gap: 16px; }
  .service-list a { grid-template-columns: 1fr 19px; }
  .service-list p { grid-row: 2; }
  .service-list svg { grid-column: 2; grid-row: 1; }
  .contact-form { max-width: none; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 6px; }
  .detail-header { grid-template-columns: 1fr; padding-top: 19px; }
  .detail-meta { padding: 0; border: 0; }
  .gallery-grid.wide, .sample-grid, .technical-list article { grid-template-columns: 1fr; gap: 5px; }
  .gallery-grid.hybrid { grid-template-columns: 1fr 1fr; }
  .gallery-grid.hybrid figure:first-child { grid-column: 1 / -1; }
  .facts { grid-template-columns: 1fr; }
  .facts div + div { border-left: 0; border-top: 1px solid var(--line); }
  .flow ol { grid-template-columns: 1fr 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}

.writing > h2 { font-size: clamp(2.4rem, 5vw, 5.2rem); font-weight: 770; line-height: .97; letter-spacing: -.079em; }
.writing-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 17px; }
.writing-card { position: relative; display: flex; flex-direction: column; padding: clamp(15px, 2.5vw, 27px); border: 1px solid var(--line); background: var(--clean); }
.writing-card:hover { border-color: var(--blue); }
.writing-card h3 { margin-block: 6px; color: var(--ink); font-size: clamp(1.26rem, 2.5vw, 2rem); font-weight: 740; letter-spacing: -.046em; line-height: 1.15; text-wrap: initial; }
.writing-card h3 a::after { content: ''; position: absolute; inset: 0; }
.writing-card > p:not(.eyebrow) { margin-bottom: 11px; color: var(--muted); }
.writing-card > span { margin-top: auto; color: var(--blue); font-size: .88rem; font-weight: 720; }
.note { width: min(100%, 840px); margin-inline: auto; }
.note-header { padding-block: clamp(23px, 4vw, 48px) 22px; border-bottom: 2px solid var(--ink); }
.note-header h1 { margin-top: 9px; font-size: clamp(2.42rem, 6vw, 5.1rem); font-weight: 760; letter-spacing: -.069em; line-height: .98; text-wrap: initial; }
.note-byline { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 12px; color: var(--muted); font: 620 .83rem/1.5 var(--mono); }
.note-byline a { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.note-lead { margin-top: 14px; font-size: clamp(1.04rem, 2vw, 1.24rem); }
.note-image { margin-top: 17px; }
.note-image img { width: 100%; height: auto; border: 1px solid var(--line); }
.note-image figcaption, .note-example figcaption { color: var(--muted); font: 560 .8rem/1.45 var(--mono); }
.note-image figcaption { margin-top: 4px; }
.note-body > section, .note-sources { margin-top: clamp(22px, 4vw, 42px); }
.note-body h2, .note-sources h2 { font-size: clamp(1.55rem, 3.2vw, 2.45rem); letter-spacing: -.045em; text-wrap: initial; }
.note-body p { margin-top: 9px; color: var(--muted); }
.note-example { margin-top: 12px; }
.note-example pre { margin: 5px 0 0; padding: 11px; border: 1px solid var(--light-line); color: var(--blue); background: #efeff9; font: .89rem/1.5 var(--mono); overflow-x: auto; }
.metrics { width: 100%; margin-top: 12px; border-collapse: collapse; font-size: .91rem; }
.metrics caption { padding-bottom: 4px; color: var(--muted); text-align: left; font-size: .85rem; }
.metrics th, .metrics td { padding: 6px 7px; border: 1px solid var(--line); text-align: left; }
.metrics th { font-weight: 660; background: #efede5; }
.metrics td { font-variant-numeric: tabular-nums; white-space: nowrap; }
.note-sources { padding-top: 11px; border-top: 1px solid var(--line); }
.note-sources ul { padding-left: 20px; margin-top: 7px; }
.article-related { margin-top: 10px; }

@media (max-width: 650px) {
  .writing-grid { grid-template-columns: 1fr; gap: 7px; }
}
