:root {
  --paper: #f9f8f5;
  --paper-2: #f1f0eb;
  --ink: #222b34;
  --muted: #646f7a;
  --blue: #4777b8;
  --blue-strong: #285b9c;
  --line: #e2e2df;
  --white: #ffffff;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, a { -webkit-tap-highlight-color: transparent; }
a:focus-visible { outline: 3px solid var(--blue); outline-offset: 5px; border-radius: 4px; }
::selection { background: #d4e6f9; color: var(--ink); }
.container { width: min(1184px, calc(100% - 88px)); margin-inline: auto; }
.skip-link { position: fixed; z-index: 100; top: 10px; left: 10px; transform: translateY(-160%); background: var(--ink); color: white; padding: 12px 17px; border-radius: 8px; }
.skip-link:focus { transform: translateY(0); }
.site-header { height: 96px; border-bottom: 1px solid var(--line); background: var(--paper); }
.nav-wrap { height: 100%; display: flex; align-items: center; justify-content: space-between; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-weight: 750; letter-spacing: -.075em; }
.brand-mark { display: inline-grid; place-items: center; font-size: 29px; line-height: 1; letter-spacing: -.06em; width: 42px; height: 42px; background: var(--blue); color: #fff; border-radius: 13px; padding-bottom: 5px; padding-right: 1px; }
.brand-name { font-size: 25px; }
.brand-period, .title-dot { color: var(--blue); }
.site-nav { display: flex; align-items: center; gap: 36px; color: #46535d; font-size: 14px; font-weight: 600; }
.site-nav a:hover, .footer-links a:hover, .text-link:hover { color: var(--blue-strong); }
.nav-contact { border: 1px solid #d9dad9; padding: 12px 16px; border-radius: 999px; }
.nav-contact:hover { border-color: var(--blue); }
.hero { min-height: 630px; display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); align-items: center; gap: 35px; padding-block: 72px 84px; }
.hero-copy { padding-bottom: 18px; }
.eyebrow, .kicker { text-transform: uppercase; font-weight: 780; letter-spacing: .145em; font-size: 11px; }
.eyebrow { color: #576574; display: flex; gap: 11px; align-items: center; margin: 0 0 26px; }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #81a97b; box-shadow: 0 0 0 5px #e7eee4; }
h1,h2,h3,p { margin-top: 0; }
.hero h1 { font-size: clamp(50px, 5.5vw, 79px); line-height: 1.09; letter-spacing: -.075em; font-weight: 750; margin: 0 0 27px; }
.hero h1 span { color: var(--blue); }
.hero-lede { max-width: 515px; color: var(--muted); font-size: 18px; line-height: 1.75; margin-bottom: 31px; }
.hero-actions { display: flex; align-items: center; gap: 28px; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: 20px; border-radius: 10px; min-height: 54px; padding: 0 21px; font-size: 14px; font-weight: 700; }
.button-primary { color: #fff; background: var(--ink); transition: transform .18s ease, background .18s ease; }
.button-primary:hover { background: var(--blue-strong); transform: translateY(-2px); }
.text-link { display: inline-flex; align-items: center; gap: 9px; font-size: 14px; font-weight: 720; transition: color .2s; }
.tiny-note { margin-top: 49px; font-size: 12px; letter-spacing: .025em; color: #91979c; }
.hero-art { height: 475px; position: relative; display: flex; justify-content: center; align-items: center; isolation: isolate; overflow: clip; }
.hero-art::before { content: ''; position: absolute; inset: 2% 5%; border-radius: 50%; border: 1px dashed #dbdedf; transform: rotate(-16deg); }
.art-disc { position: absolute; border-radius: 50%; }
.art-disc-one { width: 360px; height: 360px; background: #eaf0f7; top: 64px; left: 13%; z-index: -2; }
.art-disc-two { width: 160px; height: 160px; background: #f2e6d2; right: 12%; bottom: 42px; z-index: -3; }
.art-label { position: absolute; font-size: 10px; color: #8c96a2; text-transform: uppercase; letter-spacing: .17em; font-weight: 700; }
.art-label-top { top: 15px; right: 4%; }
.art-label-bottom { bottom: 2%; left: 11%; }
.art-card { position: absolute; display: flex; box-shadow: 0 22px 65px rgba(31,48,68,.10); border: 1px solid rgba(39,56,73,.06); }
.art-card-back, .art-card-mid { width: 220px; height: 75px; padding: 17px 19px; border-radius: 14px; align-items: center; gap: 12px; font-size: 15px; font-weight: 750; background: white; }
.art-card-back { transform: rotate(13deg); right: 6%; top: 105px; }
.art-card-mid { transform: rotate(-13deg); left: 1%; bottom: 97px; }
.mini-mini { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; color: #fff; background: #5175a1; font-weight: 750; }
.art-card-mid .mini-mini { background: #d28160; }
.art-arrow { margin-left: auto; color: #9ba4ad; }
.art-card-front { width: 280px; height: 330px; padding: 24px; background: #fff; border-radius: 20px; left: calc(50% - 140px); top: calc(50% - 165px); z-index: 2; flex-direction: column; align-items: flex-start; justify-content: space-between; transform: rotate(-3deg); }
.art-card-index { font-size: 10px; letter-spacing: .14em; font-weight: 780; color: #8995a1; }
.art-big-h { font-size: 188px; line-height: .8; font-weight: 790; letter-spacing: -.1em; color: var(--blue); padding-left: 35px; }
.art-big-h span { color: #d7a25d; }
.art-card-foot { font-size: 11px; color: #74808b; width: 100%; display: flex; justify-content: space-between; align-items: center; }
.art-card-foot span { color: var(--blue); font-size: 20px; }
.section-work { padding-block: 102px 110px; background: #fff; border-top: 1px solid #efefec; border-bottom: 1px solid #efefec; scroll-margin-top: 20px; }
.section-intro { display: flex; justify-content: space-between; gap: 25px; align-items: end; margin-bottom: 38px; }
.kicker { color: var(--blue-strong); margin-bottom: 20px; }
.section-intro h2, .about-text h2 { font-size: clamp(38px, 4.3vw, 57px); letter-spacing: -.065em; line-height: 1.08; margin-bottom: 0; }
.section-intro > p { max-width: 295px; color: var(--muted); font-size: 15px; line-height: 1.7; margin-bottom: 4px; }
.app-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 22px; }
.app-card { border: 1px solid var(--line); border-radius: 17px; overflow: hidden; display: flex; flex-direction: column; min-width: 0; transition: transform .22s, box-shadow .22s; }
.app-card:hover { transform: translateY(-4px); box-shadow: 0 18px 35px rgba(23,44,66,.07); }
.app-card-top { position: relative; min-height: 292px; display: grid; place-items: center; padding: 48px 20px; overflow: hidden; }
.app-card-top-matrix { background: #edf1fa; }
.app-card-top-chess { background: #f0ede7; }
.app-card-top-law { background: #eaf0f9; }
.app-card-top-deep { background: #eaf1ec; }
.app-art { width: min(170px, 58%); height: auto; aspect-ratio: 1/1; filter: drop-shadow(0 14px 13px rgba(28,41,53,.10)); }
.top-corner, .top-caption { position: absolute; left: 20px; font-size: 10px; letter-spacing: .12em; font-weight: 790; color: #65727a; }
.top-corner { top: 21px; }
.top-caption { bottom: 19px; }
.app-card-body { padding: 25px 25px 24px; display: flex; flex: 1; flex-direction: column; }
.app-subrow { display: flex; gap: 9px; align-items: center; text-transform: uppercase; color: #7d8790; font-size: 10px; font-weight: 740; letter-spacing: .1em; }
.app-subrow span + span::before { content: '·'; margin-right: 9px; }
.app-card h3 { font-size: 24px; letter-spacing: -.045em; margin: 13px 0 10px; }
.app-card-body p { font-size: 14px; line-height: 1.75; color: var(--muted); margin-bottom: 28px; }
.app-link { margin-top: auto; display: flex; justify-content: space-between; gap: 10px; align-items: center; border-top: 1px solid #e9eae8; padding-top: 19px; font-weight: 740; font-size: 13px; }
.app-link span { display: grid; place-items: center; width: 31px; height: 31px; background: #f3f5f7; border-radius: 50%; color: var(--blue-strong); font-size: 18px; }
.app-link:hover { color: var(--blue-strong); }
.portfolio-strip { margin-top: 28px; padding: 28px 0 0; border-top: 1px solid #ededed; display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.portfolio-strip > div { display: flex; align-items: center; gap: 15px; }
.portfolio-star { font-size: 37px; color: #ca9c5c; line-height: 1; }
.portfolio-strip strong { font-size: 16px; }
.portfolio-strip p { font-size: 13px; color: var(--muted); margin: 7px 0 0; }
.about-section { display: grid; grid-template-columns: .42fr .58fr; gap: 65px; padding-block: 118px 130px; scroll-margin-top: 50px; }
.about-glyph { font-size: 175px; line-height: 1; font-weight: 750; color: #e6e6e1; letter-spacing: -.13em; }
.about-glyph span { color: #c9d9ec; }
.about-text h2 { margin-bottom: 24px; }
.about-text p { font-size: 16px; line-height: 1.9; color: var(--muted); max-width: 580px; }
.about-text .text-link { margin-top: 15px; }
.closing-band { background: #243544; color: #fff; }
.closing-inner { min-height: 232px; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.closing-inner span { color: #a4b1be; letter-spacing: .1em; font-size: 10px; font-weight: 800; }
.closing-inner strong { font-size: clamp(25px,3vw,43px); letter-spacing: -.055em; font-weight: 700; }
.closing-inner strong span { color: #e1ae65; font-size: inherit; letter-spacing: 0; }
.site-footer { background: var(--paper); }
.footer-top { display: flex; justify-content: space-between; align-items: center; padding-block: 62px 46px; }
.footer-top p { font-size: 14px; color: var(--muted); margin: 0; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; gap: 20px; border-top: 1px solid var(--line); padding-block: 27px 35px; color: #7c858d; font-size: 12px; }
.footer-links { display: flex; gap: 25px; flex-wrap: wrap; }
.legal-main { max-width: 810px; padding-block: 100px 130px; }
.legal-main h1 { font-size: clamp(38px,6vw,65px); letter-spacing: -.07em; margin-bottom: 28px; }
.legal-main h2 { font-size: 22px; letter-spacing: -.035em; margin: 44px 0 14px; }
.legal-main p { color: var(--muted); line-height: 1.83; }
.legal-main a:not(.text-link) { color: var(--blue-strong); text-decoration: underline; text-underline-offset: 3px; }
.legal-intro { font-size: 19px; }
.legal-updated { font-size: 12px; margin-top: 45px; }
@media (max-width: 1020px) {
  .container { width: min(100% - 56px, 1184px); }
  .hero { min-height: 600px; gap: 5px; }
  .hero h1 { font-size: clamp(45px, 6.2vw, 68px); }
  .hero-lede { font-size: 16px; }
  .art-card-front { transform: scale(.85) rotate(-3deg); }
  .art-card-mid { left: -5%; }
  .art-card-back { right: -3%; }
  .app-card-top { min-height: 250px; }
  .app-card-body { padding: 21px; }
  .closing-inner { flex-wrap: wrap; justify-content: center; column-gap: 32px; }
}
@media (max-width: 760px) {
  .container { width: calc(100% - 36px); }
  .site-header { height: 78px; }
  .brand-mark { width: 38px; height: 38px; border-radius: 11px; font-size: 25px; }
  .brand-name { font-size: 23px; }
  .site-nav { gap: 18px; font-size: 13px; }
  .site-nav .nav-contact { display: none; }
  .hero { padding-block: 67px 68px; grid-template-columns: 1fr; gap: 8px; }
  .hero-copy { padding: 0; }
  .hero h1 { font-size: clamp(46px, 10.2vw, 69px); }
  .hero-lede { max-width: 590px; }
  .tiny-note { margin-top: 38px; }
  .hero-art { height: 390px; max-width: 520px; width: 100%; margin-inline: auto; }
  .art-disc-one { width: 310px; height: 310px; }
  .section-work { padding-block: 72px 82px; }
  .section-intro { display: block; }
  .section-intro > p { max-width: 500px; margin-top: 17px; }
  .app-grid { grid-template-columns: 1fr; gap: 24px; }
  .app-card { display: grid; grid-template-columns: .83fr 1.17fr; }
  .app-card-top { min-height: 275px; }
  .app-card-body { padding: 25px; }
  .portfolio-strip { align-items: start; flex-direction: column; gap: 20px; }
  .about-section { padding-block: 85px; grid-template-columns: 1fr; gap: 16px; }
  .about-glyph { display: none; }
  .closing-inner { min-height: 185px; }
  .closing-inner span { display: none; }
  .closing-inner strong { text-align: center; }
  .footer-top { padding-block: 49px 35px; }
}
@media (max-width: 530px) {
  .nav-wrap { gap: 8px; }
  .site-nav { gap: 14px; }
  .hero-actions { gap: 23px; flex-wrap: wrap; }
  .hero h1 { font-size: clamp(43px, 10vw, 56px); }
  .hero-lede { font-size: 16px; }
  .hero-art { height: 330px; }
  .hero-art::before { inset: 6% 8%; }
  .art-disc-one { width: 245px; height: 245px; top: 35px; }
  .art-disc-two { width: 108px; height: 108px; }
  .art-card-front { transform: scale(.70) rotate(-3deg); }
  .art-card-back { transform: scale(.75) rotate(13deg); right: -12%; top: 55px; }
  .art-card-mid { transform: scale(.72) rotate(-13deg); left: -14%; bottom: 57px; }
  .art-label-top { right: 0; }
  .app-card { display: flex; }
  .app-card-top { min-height: 255px; }
  .app-art { width: 145px; }
  .app-card-body { min-height: 242px; }
  .about-text p { font-size: 15px; }
  .footer-top { align-items: start; flex-direction: column; gap: 15px; }
  .footer-bottom { align-items: start; flex-direction: column; gap: 17px; }
  .footer-links { gap: 18px; }
  .legal-main { padding-block: 67px 90px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; } }

/* V2: All Apps catalog, mobile-first */
.all-apps { padding-top: 78px; scroll-margin-top: 80px; }
.all-apps-head {margin-bottom:30px;}
.catalog-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:15px; }
.catalog-card { min-width:0; background:#fff; border:1px solid #e8e6e1; border-radius:17px; display:flex; align-items:center; gap:14px; padding:17px; text-decoration:none; color:#212b36; transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease; }
.catalog-card:hover,.catalog-card:focus-visible {border-color:#9dacc2;transform:translateY(-2px);box-shadow:0 12px 20px rgba(34,54,82,.07);}
.catalog-icon { display:block; width:60px;height:60px;object-fit:cover; flex:none; border-radius:15px; background:#ecf0f4; }
.catalog-initial { display:grid;place-items:center; font-size:23px; font-weight:800; color:#4777b8; }
.catalog-info {min-width:0;display:flex;flex-direction:column;gap:5px;}
.catalog-info strong {font-size:14px;line-height:1.34;white-space:normal;}
.catalog-info small {color:#65717e;font-size:12px;line-height:1.45;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;}
.catalog-arrow {margin-left:auto;align-self:flex-start;color:#4777b8;flex:none;font-weight:bold;}
.catalog-note {display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-top:23px;color:#667180;font-size:13px;}
.catalog-note a {color:#315e96;text-decoration:underline;text-underline-offset:3px;}
@media(max-width:1000px){.catalog-grid{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(max-width:660px){.catalog-grid{grid-template-columns:1fr;gap:11px}.catalog-card{padding:13px}.catalog-icon{width:54px;height:54px}.all-apps{padding-top:52px}.catalog-note{font-size:12px}}
@media(prefers-reduced-motion:reduce){.catalog-card{transition:none}.catalog-card:hover{transform:none}}

/* V2.1 • Accessible app description dialog */
.app-card-top { isolation:isolate; }
.app-open-cover { position:absolute; inset:0; border:0; padding:0; background:transparent; cursor:pointer; z-index:2; }
.app-open-cover:focus-visible { outline:3px solid #345fa9; outline-offset:-5px; border-radius:12px; }
.app-card {cursor:pointer;}
.app-title-button { background:none; color:inherit; border:0; padding:0; font:inherit; letter-spacing:inherit; text-align:left; cursor:pointer; }
.app-title-button:hover { color:#4777b8; }
.app-title-button:focus-visible { outline:3px solid #4777b8; outline-offset:4px; border-radius:3px; }
.catalog-card { width:100%; text-align:left; font:inherit; cursor:pointer; appearance:none; -webkit-appearance:none; }
.catalog-card:focus-visible { outline:3px solid #4777b8; outline-offset:3px; }
.app-dialog { width:min(736px,calc(100% - 32px)); max-width:none; max-height:min(89vh,860px); height:auto; border:1px solid #e8e7e2; border-radius:19px; background:#fff; color:#222b36; padding:0; box-shadow:0 30px 90px rgba(19,32,48,.27); overflow:hidden; }
.app-dialog::backdrop { background:rgba(15,25,38,.63); backdrop-filter:blur(2px); }
.dialog-frame { display:flex; flex-direction:column; max-height:min(89vh,860px); }
.dialog-head { display:flex;justify-content:space-between;align-items:center;gap:16px;padding:22px 28px;background:#fff;border-bottom:1px solid #ecedea;flex-shrink:0; }
.dialog-identity { display:flex;align-items:center;gap:17px;min-width:0; }
.dialog-icon-holder { display:grid;place-items:center;flex-shrink:0; width:65px;height:65px;border-radius:16px;background:#f0f2f5;overflow:hidden; }
.dialog-icon-holder img { width:100%;height:100%;object-fit:cover; }
.dialog-icon-holder span { font-size:32px;color:#5977b5;font-weight:800; }
.dialog-names h2 {font-size:23px;line-height:1.2;letter-spacing:-.035em;margin:0 0 5px;}
.dialog-names p { font-size:13px;color:#64717e;margin:0;line-height:1.4; }
.dialog-close { display:grid;place-items:center;width:42px;height:42px;background:#f3f4f6;color:#46515e;border:0;border-radius:50%;font-size:28px;cursor:pointer;flex-shrink:0; }
.dialog-close:hover {background:#e7eaf0;color:#202d3c;}
.dialog-close:focus-visible {outline:3px solid #4777b8;outline-offset:3px;}
.dialog-body { overflow-y:auto;overscroll-behavior:contain;padding:25px 31px 32px;min-height:90px; }
.dialog-source {margin:0 0 22px;font-size:12px;color:#5c6f92;line-height:1.6;font-weight:700;}
.dialog-source.missing { color:#99663b; }
.dialog-description { white-space:pre-wrap; overflow-wrap:anywhere; line-height:1.85;color:#49535f;font-size:15px; }
.dialog-foot { border-top:1px solid #ecedea;background:#fff;padding:15px 25px;display:flex;justify-content:flex-end;align-items:center;gap:14px;flex-shrink:0; }
.dialog-locale {font-size:12px;color:#687583;}
.dialog-play {padding:12px 17px;border-radius:10px;background:#263746;color:#fff;font-weight:700;font-size:13px;white-space:nowrap;}
.dialog-play:hover {background:#415b7a;color:#fff;}
.dialog-play:focus-visible {outline:3px solid #4777b8;outline-offset:3px;}
@media(max-width:600px){
 .app-dialog {width:calc(100% - 20px);max-height:92dvh;border-radius:16px;}
 .dialog-frame {max-height:92dvh;}
 .dialog-head {padding:17px 18px;}
 .dialog-icon-holder{width:54px;height:54px;border-radius:12px;}
 .dialog-names h2 {font-size:19px;}
 .dialog-close {width:37px;height:37px;font-size:25px;}
 .dialog-body {padding:18px 20px 25px;}
 .dialog-description {font-size:14px;line-height:1.8;}
 .dialog-foot {padding:12px 16px;}
 .dialog-play {padding:11px 12px;font-size:12px;}
}
@media(prefers-reduced-motion:reduce){.app-dialog::backdrop{backdrop-filter:none}}
