/* Arham Hussain — Kevin Mathew inspired editorial portfolio, 2026.
   All layout values are fluid; no fixed page widths or viewport-height traps. */
:root{color-scheme:light;--ink:#161616;--muted:#5a5955;--paper:#f2f0e9;--cream:#e9e6df;--white:#fff;--yellow:#facc00;--line:#cbc8bf;--shadow:4px 4px 0 var(--ink);--max:1320px;--gutter:clamp(18px,4.2vw,64px);--font:'Space Grotesk',system-ui,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif}
*,*::before,*::after{box-sizing:border-box}
html{scroll-behavior:smooth;scroll-padding-top:100px}
body{margin:0;min-width:280px;overflow-x:clip;background:var(--paper);color:var(--ink);font:400 16px/1.65 var(--font);-webkit-font-smoothing:antialiased}
::selection{background:var(--yellow);color:var(--ink)}
img,svg{display:block;max-width:100%}
a{color:inherit;text-decoration:none}button,input,textarea{font:inherit}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.55}
:focus-visible{outline:3px solid #a47c00;outline-offset:4px}
img{object-fit:cover}h1,h2,h3,h4,p,blockquote{margin:0}h1,h2,h3,h4{line-height:1.05}p{max-width:75ch}
.container{width:min(100% - var(--gutter)*2,var(--max));margin-inline:auto;min-width:0}
.sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
.skip-link{position:fixed;top:-100px;left:16px;z-index:10000;padding:12px 18px;background:var(--yellow);color:var(--ink);font-weight:700}
.skip-link:focus{top:16px}
.eyebrow{display:inline-block;font-size:11px;font-weight:700;line-height:1.4;letter-spacing:.15em;text-transform:uppercase}
.rule{height:1px;background:var(--line);flex:1;min-width:30px}
.accent-dot,.hero-period{color:var(--yellow);-webkit-text-stroke:1.5px var(--ink)}
.inline-link{display:inline-flex;align-items:center;gap:6px;border-bottom:2px solid var(--ink);font-size:14px;font-weight:700;padding-bottom:4px;transition:transform .18s ease}
.inline-link:hover{transform:translateY(-2px)}
/* Navigation */
.site-header{position:sticky;top:0;z-index:1000;background:rgba(242,240,233,.96);border-bottom:1px solid rgba(22,22,22,.12);backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px)}
.nav-shell{height:74px;display:flex;align-items:center;justify-content:space-between;gap:24px;position:relative}
.wordmark{width:42px;height:42px;flex:none;display:grid;place-items:center;background:var(--yellow);border:2px solid var(--ink);font-size:23px;line-height:1;letter-spacing:-.1em;font-weight:700;transition:transform .18s,box-shadow .18s}
.wordmark:hover{transform:translate(-2px,-2px);box-shadow:3px 3px var(--ink)}
.wordmark-dot{color:var(--ink)}
.nav-links{display:flex;align-items:center;justify-content:center;gap:clamp(16px,2.2vw,36px);margin-left:auto}
.nav-links>a{font-size:13px;font-weight:600;white-space:nowrap;transition:background .18s,transform .18s}
.nav-links>a:not(.nav-mobile-cta):hover,.nav-links>a[aria-current="page"]{box-shadow:inset 0 -5px 0 var(--yellow)}
.nav-actions{display:flex;align-items:center;gap:16px}
.nav-mobile-cta,.menu-toggle{display:none!important}
/* Buttons */
.btn{position:relative;display:inline-flex;align-items:center;justify-content:center;gap:14px;min-height:50px;max-width:100%;padding:9px 18px;border:2px solid var(--ink);border-radius:999px;font-size:14px;font-weight:700;line-height:1.3;text-align:center;white-space:normal;background:var(--white);color:var(--ink);box-shadow:var(--shadow);transition:transform .18s ease,box-shadow .18s ease,background .18s ease;appearance:none}
.btn:hover{transform:translate(-2px,-2px);box-shadow:6px 6px 0 var(--ink)}
.btn:active{transform:translate(2px,2px);box-shadow:1px 1px 0 var(--ink)}
.btn-primary{background:var(--yellow)}
.btn-outline{background:var(--white)}
.btn-small{min-height:42px;padding:7px 15px;box-shadow:2px 2px 0 var(--ink);font-size:13px}
.btn-small:hover{box-shadow:4px 4px var(--ink)}
.btn-arrow{width:27px;height:27px;display:grid;place-items:center;flex:none;border:1px solid var(--ink);border-radius:50%;font-size:17px;line-height:1;background:var(--white)}
/* Hero: visible blueprint grid and huge typographic hierarchy */
.grid-paper{background-image:radial-gradient(circle at 16% 3%,rgba(250,204,0,.2),transparent 31%),linear-gradient(to right,rgba(22,22,22,.073) 1px,transparent 1px),linear-gradient(to bottom,rgba(22,22,22,.073) 1px,transparent 1px);background-size:auto,48px 48px,48px 48px;background-position:0 0,center top,center top}
.hero{border-bottom:1px solid var(--line);position:relative;overflow:hidden}
.hero-inner{padding-top:clamp(45px,7vw,106px);padding-bottom:24px}
.hero-kicker{display:flex;justify-content:space-between;gap:16px;align-items:center;margin-bottom:30px}
.availability{font-size:10px;letter-spacing:.1em;font-weight:700;display:flex;align-items:center;gap:9px;text-align:right}
.availability-dot,.chat-online{width:9px;height:9px;flex:none;background:var(--yellow);border:1px solid var(--ink);border-radius:50%}
.hero-name{font-size:clamp(3.55rem,12.3vw,11.7rem);font-weight:700;line-height:.78;letter-spacing:-.094em;text-transform:uppercase;overflow-wrap:normal;white-space:nowrap;padding-bottom:.075em}
.hero-name .hero-period{letter-spacing:-.07em}
.hero-after{display:flex;justify-content:space-between;gap:40px;align-items:end;margin-top:clamp(26px,5vw,66px)}
.hero-intro{max-width:750px}
.hero-intro h2{font-size:clamp(24px,3.8vw,52px);font-weight:600;line-height:1.12;letter-spacing:-.045em;max-width:730px}
.hero-intro h2 span{background:linear-gradient(transparent 72%,var(--yellow) 0);white-space:normal}
.hero-intro p{font-size:clamp(15px,1.3vw,18px);line-height:1.6;max-width:580px;margin-top:16px;color:#353535}
.hero-buttons{display:flex;flex-wrap:wrap;gap:15px;margin-top:28px}
.hero-aside{align-self:stretch;display:flex;min-width:170px;flex-direction:column;align-items:flex-end;justify-content:space-between;padding-top:10px;gap:30px;color:var(--muted)}
.tiny-topline,.tiny-bottomline{font-size:10px;line-height:1.4;text-align:right;font-weight:700;letter-spacing:.13em}
.hero-scribble{font-size:86px;line-height:1;color:var(--ink);font-weight:400;transform:rotate(-20deg);font-family:var(--font)}
.stat-strip{display:flex;gap:0;border-top:1px solid var(--line);margin-top:clamp(48px,7vw,100px);padding-top:22px;max-width:700px}
.stat-strip>div{flex:1;min-width:0;padding:0 18px;border-right:1px solid var(--line);display:flex;flex-direction:column;align-items:flex-start;gap:3px}
.stat-strip>div:first-child{padding-left:0}.stat-strip>div:last-child{border-right:0}
.stat-strip strong{font-size:clamp(26px,3vw,43px);line-height:1;font-weight:700;letter-spacing:-.07em}
.stat-strip strong span{font-weight:500;color:#b78c00}
.stat-strip>div>span{font-size:9px;line-height:1.5;letter-spacing:.12em;font-weight:700}
/* Universal content sections */
.section{padding-block:clamp(70px,9vw,134px)}
.section-label{display:flex;align-items:center;gap:20px;margin-bottom:clamp(32px,4.5vw,65px)}
.section-title{font-size:clamp(2.45rem,5.8vw,5.2rem);line-height:.99;letter-spacing:-.067em;font-weight:700;text-transform:uppercase;text-wrap:balance}
.section-top{display:flex;align-items:end;justify-content:space-between;gap:32px;margin-bottom:48px}
.section-top>p{color:var(--muted);font-size:15px;max-width:350px;line-height:1.6}
/* About */
.about-section{background:#fff}
.about-grid{display:grid;grid-template-columns:minmax(0,.98fr) minmax(0,1.07fr);align-items:start;gap:clamp(34px,6vw,90px)}
.about-photo-frame{position:relative;margin-top:32px;width:100%;max-width:520px;aspect-ratio:1/1.02;background:#ddd5c7;border:2px solid var(--ink);box-shadow:7px 7px 0 var(--ink);overflow:hidden}
.about-photo-frame img{width:100%;height:100%;object-fit:cover;object-position:center 35%;filter:saturate(.9)}
.portrait-label{position:absolute;bottom:0;left:0;padding:10px 15px;background:var(--yellow);border-top:2px solid var(--ink);border-right:2px solid var(--ink);font-size:11px;font-weight:700;letter-spacing:.04em}
.about-copy{padding-top:clamp(0px,4vw,70px)}
.about-lead{font-weight:700;font-size:clamp(23px,2.45vw,34px);line-height:1.17;letter-spacing:-.035em;margin-bottom:27px}
.about-copy>p:not(.about-lead){margin-bottom:19px;font-size:16px;line-height:1.8;color:#33312f}
.about-actions{display:flex;gap:22px;flex-wrap:wrap;align-items:center;margin-top:34px}
/* Skills */
.skills-section{background:#e7e5dd}
.skill-groups{border-top:1px solid #bbb8ad}
.skill-group{display:grid;grid-template-columns:minmax(155px,.3fr) minmax(0,1fr);gap:32px;align-items:start;border-bottom:1px solid #bbb8ad;padding:25px 0}
.skill-group-name{display:flex;align-items:center;gap:14px;padding-top:7px}
.skill-group-name span{font-size:10px;letter-spacing:.13em;color:#65615b}
.skill-group-name h3{font-size:12px;letter-spacing:.1em;font-weight:700}
.skill-pills{display:flex;align-items:center;flex-wrap:wrap;gap:9px}
.skill-pill{min-height:37px;display:inline-flex;align-items:center;justify-content:center;gap:8px;max-width:100%;padding:7px 12px;border:1px solid #c1beb6;background:#fff;border-radius:5px;font-size:12px;font-weight:700;line-height:1.25;transition:transform .2s,border-color .2s}
.skill-pill:hover{transform:translateY(-3px);border-color:var(--ink)}
.skill-pill img{height:18px;width:18px;object-fit:contain}
.capabilities{border-top:1px solid #bbb8ad;margin-top:80px;padding-top:35px;display:grid;grid-template-columns:1fr 1fr;gap:44px}
.capabilities h3{font-size:clamp(26px,3vw,42px);letter-spacing:-.055em;line-height:1.07;max-width:550px;margin-top:20px}
.capability-list p{padding:14px 0;border-bottom:1px solid #bbb8ad;display:flex;align-items:start;gap:14px;font-size:15px}
.capability-list p span{font-size:20px;line-height:1.1}
/* Experience */
.experience-section{background:#fff}
.experience-grid{display:grid;grid-template-columns:minmax(200px,.36fr) minmax(0,1fr);gap:clamp(42px,6vw,92px);margin-top:55px}
.experience-sidebar{border-top:1px solid var(--line);padding-top:25px;align-self:start;position:sticky;top:110px}
.experience-mark{font-size:clamp(70px,10vw,150px);line-height:1;color:var(--yellow);-webkit-text-stroke:2px var(--ink);display:block;margin-bottom:26px}
.experience-sidebar p{max-width:230px;font-size:16px;line-height:1.55;margin-bottom:24px}
.experience-list{display:flex;flex-direction:column;gap:17px}
.experience-item{border:2px solid var(--ink);border-radius:6px;padding:clamp(22px,3.5vw,34px);background:#fff;box-shadow:5px 5px 0 var(--ink);transition:transform .2s,box-shadow .2s}
.experience-item:hover{transform:translate(-2px,-2px);box-shadow:7px 7px 0 var(--ink)}
.experience-meta{display:flex;gap:12px;justify-content:space-between;align-items:center;flex-wrap:wrap;margin-bottom:18px;font-size:10px;letter-spacing:.1em;font-weight:700;color:#5e5b56}
.experience-item h3{font-size:clamp(20px,2.2vw,27px);letter-spacing:-.04em;margin-bottom:12px}
.experience-item p{font-size:14px;line-height:1.7;color:#3c3a37;max-width:750px}
/* Projects */
.projects-section{background:#f4f4f3}
.project-heading{margin-bottom:clamp(48px,7vw,90px)}
.project-heading .section-title{margin-top:15px}
.projects-list{display:grid;gap:clamp(75px,10vw,140px)}
.project-feature{display:grid;grid-template-columns:minmax(0,1.13fr) minmax(0,.87fr);gap:clamp(30px,5vw,80px);align-items:center}
.project-feature:nth-child(even) .project-visual{order:2}.project-feature:nth-child(even) .project-copy{order:1}
.project-visual{display:block;position:relative;background:#dedcd7;overflow:hidden;border:2px solid var(--ink);border-radius:6px;box-shadow:7px 7px 0 var(--ink);aspect-ratio:1.42;transition:transform .2s,box-shadow .2s}
.project-visual:hover{transform:translate(-3px,-3px);box-shadow:10px 10px 0 var(--ink)}
.project-visual-top{position:absolute;z-index:2;top:0;left:0;right:0;height:36px;display:flex;align-items:center;gap:5px;border-bottom:1px solid rgba(22,22,22,.18);background:#ebe8e1;padding:0 12px}
.mock-dot{width:7px;height:7px;border-radius:50%;border:1px solid var(--ink);background:#d9d6ce}
.mock-dot:first-child{background:var(--yellow)}
.project-url{margin:auto;text-align:center;min-width:0;max-width:calc(100% - 75px);font-size:10px;line-height:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#4e4c47}
.project-visual>img{width:100%;height:100%;object-fit:cover;object-position:center;transition:transform .5s ease;padding-top:36px}
.project-visual:hover>img{transform:scale(1.04)}
.visual-corner{position:absolute;z-index:2;bottom:15px;right:15px;display:grid;place-items:center;width:44px;height:44px;background:var(--yellow);border:2px solid var(--ink);border-radius:100%;font-size:25px;line-height:1}
.project-copy .eyebrow{color:#6b685f}
.project-copy h3{font-size:clamp(40px,5.8vw,82px);letter-spacing:-.072em;margin-top:15px;margin-bottom:16px;overflow-wrap:anywhere}
.project-copy h4{font-size:clamp(18px,2vw,27px);letter-spacing:-.04em;line-height:1.22;margin-bottom:16px;font-weight:500}
.project-copy p{font-size:15px;line-height:1.75;color:#4e4d4a;max-width:510px}
.tag-list{display:flex;flex-wrap:wrap;gap:7px;margin:24px 0 29px}
.tag-list span{display:inline-block;border:1px solid #bcbab4;padding:5px 11px;border-radius:999px;font-size:11px;font-weight:600;background:white;line-height:1.3}
.other-work{margin-top:clamp(100px,12vw,160px);border-top:2px solid var(--ink);padding-top:35px}
.other-work-title{display:flex;align-items:end;justify-content:space-between;gap:22px;margin-bottom:25px}
.other-work-title h3{font-size:clamp(26px,3.3vw,50px);letter-spacing:-.06em}
.extra-projects{border-top:1px solid var(--line)}
.extra-project{display:grid;grid-template-columns:36px minmax(0,1fr) minmax(0,175px) 22px;align-items:center;gap:25px;padding:17px 8px;border-bottom:1px solid var(--line);transition:background .18s,padding .18s}
.extra-project:hover{background:#ebe8dc;padding-inline:18px}
.extra-index{font-size:11px;font-weight:700;color:#73716c}
.extra-project-main{display:flex;flex-direction:column;gap:4px;min-width:0}
.extra-project-main strong{font-size:clamp(17px,2vw,23px);line-height:1.2;letter-spacing:-.04em}
.extra-project-main small{font-size:12px;color:#686762;line-height:1.4}
.extra-type{font-size:12px;text-align:right;color:#64605a}
.extra-arrow{font-size:20px}
/* Testimonials */
.proof-section{background:white}
.quote-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px;margin-top:48px}
.quote-grid blockquote{border:1px solid var(--ink);padding:clamp(22px,3vw,35px);background:#f5f3ed;display:flex;flex-direction:column;min-height:300px;gap:18px}
.quote-mark{font-weight:700;font-size:62px;line-height:.7;color:#bd9300}
.quote-grid blockquote p{font-size:15px;line-height:1.7;flex:1}
.quote-grid footer{border-top:1px solid var(--line);padding-top:15px;display:flex;flex-direction:column;font-size:12px}
.quote-grid footer strong{font-size:14px}.quote-grid footer span{color:#65605b}
/* Contact/footer */
.contact-band{background:#d7d4cb;padding-top:clamp(70px,9vw,120px);border-top:2px solid var(--ink)}
.contact-band h2{font-size:clamp(3rem,8vw,8.8rem);line-height:.9;letter-spacing:-.085em;margin:20px 0 25px;text-wrap:balance}
.contact-band h2 span{color:var(--ink)}
.footer-note{max-width:590px;color:#3d3b37;font-size:16px}
.footer-contact-row{display:flex;align-items:center;gap:20px;flex-wrap:wrap;margin-top:34px;max-width:100%}
.email-link{font-size:clamp(16px,2.5vw,29px);line-height:1.3;font-weight:700;letter-spacing:-.035em;text-decoration:underline;text-decoration-color:#b89000;text-underline-offset:8px;overflow-wrap:anywhere}
.copy-email{min-height:40px;background:transparent;border:0;border-bottom:1px solid var(--ink);font-size:12px;font-weight:700}
.footer-actions{display:flex;gap:15px;flex-wrap:wrap;margin-top:42px;padding-bottom:clamp(85px,10vw,145px)}
.footer-bottom{border-top:1px solid #aaa69e;display:flex;gap:20px;align-items:center;justify-content:space-between;padding:25px 0 32px;color:#514f4b;font-size:12px}
.footer-bottom>div{display:flex;align-items:center;flex-wrap:wrap;gap:clamp(12px,2vw,30px)}
.footer-bottom a:hover{text-decoration:underline;text-underline-offset:4px}
/* CV modal: native accessible dialog with a downloadable fallback */
.cv-dialog{position:fixed;inset:0;width:min(1100px,calc(100% - 26px));height:min(88dvh,1100px);min-height:300px;max-height:calc(100dvh - 24px);margin:auto;padding:0;border:2px solid var(--ink);background:var(--white);color:var(--ink);box-shadow:10px 10px 0 var(--ink);overflow:hidden}
.cv-dialog::backdrop{background:rgba(22,22,22,.73)}
.cv-dialog-header{height:72px;display:flex;justify-content:space-between;align-items:center;gap:12px;padding:12px 20px;border-bottom:2px solid var(--ink)}
.cv-dialog-header strong{font-size:13px;letter-spacing:.04em}
.cv-dialog-header>div{display:flex;align-items:center;gap:15px}
.dialog-close{width:38px;height:38px;display:grid;place-items:center;border:2px solid var(--ink);border-radius:50%;background:white}
.cv-dialog-body{height:calc(100% - 72px);display:flex;flex-direction:column;min-height:0}
.cv-dialog-body iframe{height:100%;width:100%;border:0;flex:1;min-height:0;background:#e9e9e9}
.cv-dialog-body p{flex:none;padding:9px 15px;font-size:11px;text-align:center;color:var(--muted)}
.cv-dialog-body p a{text-decoration:underline}
/* Assistant: visible on desktop, safe mobile viewport sizing */
.chat-widget{position:fixed;bottom:max(22px,env(safe-area-inset-bottom));right:max(22px,env(safe-area-inset-right));z-index:1020;font-family:var(--font)}
.chat-toggle{display:flex;align-items:center;gap:10px;min-height:54px;padding:0 18px 0 11px;border:2px solid var(--ink);border-radius:999px;background:var(--yellow);box-shadow:var(--shadow);font-size:14px;font-weight:700;transition:transform .18s,box-shadow .18s}
.chat-toggle:hover{transform:translate(-2px,-2px);box-shadow:6px 6px var(--ink)}
.chat-toggle-spark{display:grid;place-items:center;width:34px;height:34px;border-radius:50%;background:var(--white);border:1px solid var(--ink);font-size:23px;line-height:1}
.chat-window{position:absolute;right:0;bottom:calc(100% + 13px);width:min(375px,calc(100vw - 28px));height:min(525px,calc(100dvh - 120px));min-height:280px;display:flex;flex-direction:column;background:var(--paper);border:2px solid var(--ink);border-radius:8px;box-shadow:6px 6px 0 var(--ink);overflow:hidden}
.chat-window[hidden]{display:none}
.chat-header{display:flex;justify-content:space-between;align-items:center;gap:10px;background:var(--yellow);padding:14px 17px;border-bottom:2px solid var(--ink)}
.chat-header>div{display:flex;flex-direction:column;gap:3px}.chat-header strong{font-size:15px;letter-spacing:.04em;display:flex;align-items:center;gap:8px}
.chat-header small{font-size:11px;line-height:1.3}
.chat-online{background:#fff;width:8px;height:8px}
.chat-header button{width:35px;height:35px;border:1px solid var(--ink);background:#fff;border-radius:50%;font-size:15px}
.chat-messages{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:17px;display:flex;flex-direction:column;align-items:flex-start;gap:12px}
.chat-msg{max-width:95%;padding:12px 14px;line-height:1.55;font-size:13px;overflow-wrap:anywhere;white-space:pre-wrap;border:1px solid #bcb6a9;border-radius:8px;background:#fff}
.chat-msg.user{align-self:flex-end;background:var(--yellow);border-color:var(--ink)}
.chat-input-row{display:flex;gap:7px;padding:10px 12px 0;border-top:1px solid #c4c0b8;background:#fff}
.chat-input-row input{flex:1;min-width:0;padding:10px;background:#f7f5ee;border:1px solid #aaa599;border-radius:5px;font-size:13px;outline-offset:1px}
.chat-input-row button{width:42px;height:42px;flex:none;border:1px solid var(--ink);background:var(--yellow);border-radius:6px;font-size:22px;line-height:1}
.chat-disclaimer{font-size:9px;text-align:center;padding:4px 10px 8px;background:#fff;color:#77726c}
/* Subpages: same design language */
.subpage-hero{border-bottom:1px solid var(--line);padding:clamp(75px,10vw,150px) 0 clamp(50px,6vw,90px)}
.subpage-hero h1{font-size:clamp(3.5rem,12vw,10rem);line-height:.79;letter-spacing:-.085em;font-weight:700;margin:29px 0 42px;white-space:normal;text-wrap:balance}
.subpage-hero-bottom{display:flex;align-items:end;justify-content:space-between;gap:25px}
.subpage-hero-bottom p{font-size:clamp(18px,2.4vw,27px);max-width:740px;line-height:1.3;font-weight:500;letter-spacing:-.027em}
.awards-section{background:#fff}.award-experience-list{margin-top:55px;display:grid;gap:15px}
.award-experience{padding:clamp(22px,3vw,35px);background:#f9f8f3;border:1px solid #c5c1b9;border-left:5px solid var(--yellow);transition:transform .18s,box-shadow .18s}
.award-experience:hover{transform:translate(-2px,-2px);box-shadow:4px 4px var(--ink)}
.award-experience h3{font-size:clamp(21px,2.4vw,32px);letter-spacing:-.04em;margin-bottom:14px}
.award-experience h3 a:hover{text-decoration:underline;text-underline-offset:4px}
.award-experience p{font-size:14px;line-height:1.8;color:#4c4842;max-width:980px}
.education-section{background:#e7e5dd}.edu-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:25px;margin-top:50px}
.edu-card{position:relative;min-height:270px;border:2px solid var(--ink);padding:30px;background:white;overflow:hidden;display:flex;flex-direction:column;align-items:start}
.edu-card h3{font-size:clamp(23px,2.7vw,38px);letter-spacing:-.055em;margin-top:22px;max-width:460px;z-index:1}
.edu-card p{margin-top:auto;padding-top:25px;font-size:15px;color:#55514b;z-index:1}
.edu-asterisk{position:absolute;right:-12px;bottom:-38px;font-size:200px;line-height:1;color:#f6d63d;opacity:.5}
.certificate-section{background:#fff}.cert-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:15px}
.cert-card{min-width:0;display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:4px 7px;background:#f6f5f0;padding:9px;border:1px solid var(--line);transition:transform .2s,box-shadow .2s}
.cert-card:hover{transform:translate(-2px,-2px);box-shadow:3px 3px var(--ink)}
.cert-thumb{grid-column:1/-1;display:block;aspect-ratio:1.45;background:#ece9df;overflow:hidden}
.cert-thumb img{width:100%;height:100%;object-fit:contain}
.cert-card strong{font-size:12px;line-height:1.35;padding:8px 4px}
.cert-card>span:last-child{font-size:20px}
.contact-page-section{background:#fff}.contact-page-grid{display:grid;grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);gap:clamp(35px,7vw,100px)}
.contact-side>p{margin-top:30px;max-width:440px;font-size:16px;color:#53504a}
.contact-inline-email{display:inline-block;margin-top:32px;font-weight:700;font-size:clamp(14px,1.6vw,21px);text-decoration:underline;text-underline-offset:5px;overflow-wrap:anywhere}
.contact-side-links{display:flex;gap:22px;margin-top:38px;font-weight:700;font-size:13px}.contact-side-links a:hover{text-decoration:underline}
.contact-form{padding:clamp(20px,3.8vw,42px);border:2px solid var(--ink);box-shadow:7px 7px var(--ink);background:#f5f3ed;min-width:0}
.field{margin-bottom:23px}.field label{display:block;font-size:11px;letter-spacing:.12em;font-weight:700;margin-bottom:9px}
.field input,.field textarea{display:block;width:100%;min-width:0;background:#fff;color:var(--ink);border:1px solid #b9b5aa;border-radius:0;padding:14px;font-size:15px;line-height:1.5;transition:border-color .15s;resize:vertical}
.field input:focus,.field textarea:focus{outline:2px solid var(--yellow);outline-offset:0;border-color:var(--ink)}
.field input::placeholder,.field textarea::placeholder{color:#827c73}
.form-bottom{display:flex;align-items:center;justify-content:space-between;gap:20px;flex-wrap:wrap}
.form-status{font-size:12px;color:#555;max-width:350px;line-height:1.5}
.form-status.success{color:#236128;font-weight:700}.form-status.error{color:#993522;font-weight:700}
/* Responsive — tablet and compact laptop */
@media(max-width:1050px){.hero-aside{min-width:120px}.hero-scribble{font-size:60px}.section-title{font-size:clamp(2.4rem,6.4vw,4.8rem)}.project-feature{gap:34px}.project-copy h3{font-size:clamp(38px,5.3vw,65px)}.nav-links{gap:18px}}
@media(max-width:900px){.nav-shell{height:68px}.nav-links{display:none;position:absolute;top:calc(100% + 1px);left:calc(var(--gutter)*-1);right:calc(var(--gutter)*-1);background:var(--paper);border-bottom:2px solid var(--ink);padding:14px var(--gutter) 25px;box-shadow:0 8px 0 rgba(22,22,22,.08);flex-direction:column;align-items:stretch;gap:0;max-height:calc(100dvh - 68px);overflow-y:auto}.nav-links.open{display:flex}.nav-links>a{font-size:19px;padding:12px 0;border-bottom:1px solid var(--line)}.nav-mobile-cta{display:block!important;font-weight:700!important}.nav-hire{display:none}.menu-toggle{display:flex!important;flex-direction:column;justify-content:center;align-items:center;gap:5px;width:44px;height:44px;border:2px solid var(--ink);border-radius:6px;background:#fff}.menu-toggle span{display:block;width:19px;height:2px;background:var(--ink);transition:transform .18s,opacity .18s}.menu-toggle[aria-expanded="true"] span:first-child{transform:translateY(7px) rotate(45deg)}.menu-toggle[aria-expanded="true"] span:nth-child(2){opacity:0}.menu-toggle[aria-expanded="true"] span:last-child{transform:translateY(-7px) rotate(-45deg)}.hero-name{font-size:clamp(3.5rem,13vw,9.3rem)}.about-grid{grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);gap:35px}.about-copy{padding-top:0}.project-feature{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.project-visual{aspect-ratio:1.04}.quote-grid{grid-template-columns:1fr 1fr}.quote-grid blockquote:last-child{grid-column:1/-1;min-height:180px}.cert-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:720px){.section{padding-block:70px}.hero-inner{padding-top:45px}.hero-after{gap:25px}.hero-aside{display:none}.hero-intro{max-width:610px}.hero-name{font-size:clamp(3.6rem,13.2vw,6rem)}.about-grid,.experience-grid,.contact-page-grid{grid-template-columns:minmax(0,1fr)}.about-photo-frame{max-width:450px}.about-copy{padding-top:0}.section-top{display:block}.section-top>p{margin-top:22px;max-width:580px}.skill-group{grid-template-columns:1fr;gap:12px;padding:22px 0}.capabilities{grid-template-columns:1fr;gap:22px;margin-top:60px}.experience-grid{margin-top:35px;gap:25px}.experience-sidebar{position:static;display:flex;flex-wrap:wrap;align-items:center;gap:20px}.experience-mark{font-size:80px;margin:0}.experience-sidebar p{flex:1;min-width:180px}.experience-sidebar .inline-link{width:max-content}.project-feature{display:grid;grid-template-columns:1fr;gap:25px}.project-feature:nth-child(even) .project-visual,.project-feature:nth-child(even) .project-copy{order:initial}.project-visual{aspect-ratio:1.5}.project-copy h3{font-size:clamp(40px,9vw,64px)}.projects-list{gap:85px}.quote-grid{grid-template-columns:1fr}.quote-grid blockquote:last-child{grid-column:auto}.quote-grid blockquote{min-height:200px}.cert-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.subpage-hero-bottom{align-items:start;flex-direction:column}.edu-grid{grid-template-columns:1fr}.contact-side>p{margin-top:20px}}
@media(max-width:480px){:root{--gutter:18px}.nav-shell{height:62px}.nav-links{max-height:calc(100dvh - 62px)}.wordmark{height:39px;width:39px}.hero-kicker{margin-bottom:22px;align-items:start}.availability{max-width:135px;font-size:9px;line-height:1.3;letter-spacing:.04em}.hero-name{font-size:clamp(3.2rem,13.6vw,4.8rem);letter-spacing:-.092em}.hero-after{margin-top:20px}.hero-intro h2{font-size:clamp(24px,7vw,34px)}.hero-intro p{font-size:15px}.hero-buttons{gap:12px}.hero-buttons .btn{min-height:46px;font-size:12px;padding:7px 12px;gap:7px}.hero-buttons .btn-arrow{width:23px;height:23px}.stat-strip{margin-top:55px}.stat-strip>div{padding-inline:10px}.stat-strip strong{font-size:27px}.stat-strip>div>span{font-size:8px;letter-spacing:.055em}.section-title{font-size:clamp(2.4rem,10.5vw,3.5rem)}.section-label{margin-bottom:34px;gap:14px}.about-photo-frame{margin-top:25px}.about-actions{gap:20px}.skill-pill{font-size:11px;padding:7px 10px}.skill-pills{gap:7px}.experience-item{padding:22px;box-shadow:3px 3px var(--ink)}.experience-meta{font-size:9px}.project-copy h3{font-size:46px}.project-visual{aspect-ratio:1.3;box-shadow:4px 4px var(--ink)}.extra-project{grid-template-columns:24px minmax(0,1fr) 18px;gap:9px;padding:15px 0}.extra-type{display:none}.extra-project-main small{font-size:11px}.other-work-title{align-items:start;flex-direction:column}.contact-band h2{font-size:clamp(2.75rem,12vw,4rem);overflow-wrap:anywhere}.footer-contact-row{gap:10px}.email-link{font-size:clamp(15px,4.5vw,20px)}.footer-bottom{flex-direction:column;align-items:flex-start}.footer-actions{padding-bottom:75px}.cv-dialog{height:calc(100dvh - 12px);max-height:none;width:calc(100% - 12px);box-shadow:none}.cv-dialog-header{padding:10px;height:64px}.cv-dialog-header strong{font-size:11px}.cv-dialog-header .btn{font-size:11px;min-height:38px;padding:5px 10px}.cv-dialog-body{height:calc(100% - 64px)}.chat-widget{bottom:max(14px,env(safe-area-inset-bottom));right:max(14px,env(safe-area-inset-right))}.chat-toggle{min-height:46px;padding:0 12px 0 8px;font-size:12px}.chat-toggle-spark{height:29px;width:29px}.chat-window{height:min(520px,calc(100dvh - 95px));width:calc(100vw - 28px)}.subpage-hero{padding-top:65px}.subpage-hero h1{font-size:clamp(3.3rem,14vw,5.7rem)}.cert-grid{gap:10px}.cert-card{padding:6px}.cert-card strong{font-size:11px}.contact-form{padding:20px;box-shadow:4px 4px var(--ink)}.form-bottom .btn{width:100%}}
@media(max-width:340px){.hero-name{font-size:clamp(2.9rem,13.4vw,3.25rem)}.availability{max-width:113px}.stat-strip>div>span{font-size:7px}.stat-strip strong{font-size:24px}.btn{min-height:44px}.hero-buttons{flex-direction:column;align-items:flex-start}.email-link{font-size:14px}.section-title{font-size:2.35rem}.cert-grid{grid-template-columns:1fr 1fr}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}*,*::before,*::after{animation-duration:.01ms!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}
@media(hover:none){.skill-pill:hover,.experience-item:hover,.project-visual:hover,.cert-card:hover,.extra-project:hover{transform:none}.btn:hover,.chat-toggle:hover{transform:none}}


/* ─────────────────── 2026 motion & CV integration upgrade ─────────────────── */
@view-transition { navigation:auto; }
:root { --ease-smooth:cubic-bezier(.22,1,.36,1); --motion-medium:460ms; }
html { scroll-padding-top:100px }
body { animation:site-arrive .55s var(--ease-smooth) both }
@keyframes site-arrive { from { opacity:.7; transform:translateY(6px) } to { opacity:1; transform:none } }
/* The enlarged mathematical graph-paper grid shifts slowly behind the content. */
.grid-paper {
  --grid-step:88px;
  isolation:isolate;
  background-size:auto,var(--grid-step) var(--grid-step),var(--grid-step) var(--grid-step);
  animation:grid-travel 32s linear infinite;
}
@keyframes grid-travel {
  from{background-position:0 0,0 0,0 0}
  to{background-position:0 0,88px 88px,88px 88px}
}
.hero-inner,.subpage-hero>.container{position:relative;z-index:1}
.math-scene{position:absolute;z-index:0;inset:0;pointer-events:none;overflow:hidden}
.math-tile { position:absolute;display:grid;place-items:center;width:clamp(70px,9vw,128px);height:clamp(70px,9vw,128px);
  color:rgba(22,22,22,.18);border:1px solid rgba(22,22,22,.17);background:rgba(255,255,255,.09);
  font-weight:700;font-size:clamp(32px,5vw,64px);line-height:1;letter-spacing:-.06em;
  animation:math-drift 10s ease-in-out infinite alternate;transform:translate3d(var(--px,0),var(--py,0),0) rotate(var(--angle,0deg));
  will-change:transform;
}
.math-tile-1{top:12%;right:4%;--angle:8deg;animation-delay:-2.5s}
.math-tile-2{top:38%;right:18%;--angle:-7deg;animation-delay:-6s}
.math-tile-3{top:13%;left:45%;--angle:4deg;animation-delay:-3s}
.math-tile-4{bottom:10%;right:7%;--angle:-6deg;animation-delay:-8s}
@keyframes math-drift{from{translate:0 -10px;rotate:-1.5deg}to{translate:0 12px;rotate:2.5deg}}
.hero .math-tile {opacity:.65}
.subpage-hero .math-tile{opacity:.38}
/* Restful navigation from the supplied screenshot: softly filled pills and a yellow dot. */
.site-header{transition:background .5s var(--ease-smooth),box-shadow .4s var(--ease-smooth)}
.site-header.is-scrolled{box-shadow:0 8px 26px rgba(22,22,22,.07);background:rgba(248,247,243,.98)}
.nav-shell{min-height:76px;height:auto;padding-block:7px}
.wordmark{width:53px;height:53px;border-radius:10px;font-size:27px;letter-spacing:-.09em;transition:transform .45s var(--ease-smooth),box-shadow .45s var(--ease-smooth)}
.nav-links{gap:clamp(3px,.55vw,11px)}
.nav-links>a:not(.nav-mobile-cta){position:relative;display:inline-flex;min-height:48px;align-items:center;justify-content:center;
  padding:8px clamp(10px,1vw,19px);border-radius:13px;font-size:clamp(13px,1.08vw,18px);font-weight:500;
  transition:background .45s var(--ease-smooth),transform .45s var(--ease-smooth),color .3s}
.nav-links>a:not(.nav-mobile-cta)::after{content:'';position:absolute;bottom:8px;left:50%;width:9px;height:9px;
  background:var(--yellow);border:1.3px solid var(--ink);border-radius:50%;opacity:0;
  transform:translate(-50%,11px) scale(.3);transition:transform .42s var(--ease-smooth),opacity .32s}
.nav-links>a:not(.nav-mobile-cta):hover,.nav-links>a:not(.nav-mobile-cta).is-active,.nav-links>a:not(.nav-mobile-cta)[aria-current="page"]{
  background:#e9e7de;box-shadow:none;transform:translateY(-1px)}
.nav-links>a:not(.nav-mobile-cta):hover::after,.nav-links>a:not(.nav-mobile-cta).is-active::after,.nav-links>a:not(.nav-mobile-cta)[aria-current="page"]::after{
  opacity:1;transform:translate(-50%,2px) scale(1)}
.nav-actions .nav-hire{font-size:clamp(12px,1vw,16px);min-height:50px;padding:10px 20px}
.scroll-progress{position:absolute;left:0;bottom:0;width:100%;height:3px;background:var(--yellow);transform:scaleX(0);transform-origin:left;pointer-events:none}
.btn,.chat-toggle{transition:transform .45s var(--ease-smooth),box-shadow .45s var(--ease-smooth),background .4s,color .4s}
.btn .btn-arrow{transition:transform .5s var(--ease-smooth),background .5s var(--ease-smooth)}
.btn:hover .btn-arrow{transform:rotate(43deg)}
.inline-link{transition:transform .4s var(--ease-smooth),text-decoration-color .4s}
/* Motion is progressively enhanced. Without JS or IntersectionObserver, content is always visible. */
.motion-enabled .reveal-up:not(.is-visible){opacity:0;transform:translate3d(0,35px,0)}
.reveal-up {transition:opacity .75s var(--ease-smooth),transform .85s var(--ease-smooth);}
.motion-enabled .reveal-up.is-visible{opacity:1;transform:translate3d(0,0,0)}
/* Skills: actual 20px SVG artwork on larger, touch-friendly pills. */
.skill-pill{display:inline-flex;align-items:center;gap:9px;min-height:43px;padding:8px 14px;
  transition:background .42s var(--ease-smooth),border-color .42s var(--ease-smooth),box-shadow .42s var(--ease-smooth),transform .42s var(--ease-smooth)}
.skill-pill img{display:block;width:21px;height:21px;flex:none;object-fit:contain}
.skill-pill:hover{transform:translate3d(0,-3px,0);box-shadow:0 4px 0 rgba(22,22,22,.15);background:#fffdf7}
.skill-pills{gap:10px}
/* Project gallery richer transitions and a real screenshot first. */
.project-feature{position:relative}
.project-visual{isolation:isolate;overflow:hidden;transition:transform .6s var(--ease-smooth),box-shadow .6s var(--ease-smooth),border-color .5s}
.project-visual img{transition:transform 1.1s var(--ease-smooth),filter 1.1s var(--ease-smooth)}
.project-visual:hover img{transform:scale(1.055)}
.project-maplecake .project-visual-maplecake{background:#f8f4eb}
.project-maplecake .project-visual img{object-fit:contain;object-position:center;background:#fbf7ed}
.feature-stamp{position:absolute;bottom:18px;left:18px;display:inline-flex;gap:12px;align-items:center;padding:10px 13px;
  background:var(--yellow);border:2px solid var(--ink);font-size:10px;font-weight:700;letter-spacing:.11em;box-shadow:3px 3px 0 var(--ink)}
.feature-stamp b{border-left:1px solid var(--ink);padding-left:10px;font-size:14px}
.project-detail{margin-top:2px;max-width:100%}
.project-detail>summary{list-style:none;width:max-content;cursor:pointer}
.project-detail>summary::-webkit-details-marker{display:none}
.project-detail[open]>summary{background:var(--yellow)}
.project-detail-panel{border:1px solid var(--ink);background:#fff;padding:20px;margin-top:15px;box-shadow:4px 4px var(--ink);
 animation:detail-enter .45s var(--ease-smooth) both}
.project-detail-panel ul{padding-left:20px;margin:0 0 15px;font-size:13px;line-height:1.7}
.project-detail-panel li+li{margin-top:8px}
.project-detail-panel>a{display:inline-flex;border-bottom:1px solid var(--ink);font-size:13px;font-weight:700}
@keyframes detail-enter{from{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:none}}
.project-visual-mandage{background:#e9eae9}
.mandage-illustration{height:calc(100% - 44px);min-height:230px;padding:clamp(16px,3vw,35px);display:flex;flex-direction:column;justify-content:center;gap:22px}
.mandage-heading{display:flex;align-items:center;gap:12px}
.mandage-badge{display:grid;place-items:center;width:50px;height:50px;background:#272e45;color:#fff;border-radius:9px;font-weight:700;font-size:28px}
.mandage-heading>div{display:flex;flex-direction:column;min-width:0}
.mandage-heading strong{font-size:clamp(17px,2vw,25px);line-height:1.2;letter-spacing:-.04em}
.mandage-heading small{font-size:12px;color:#555e65}
.mandage-state{margin-left:auto;border-radius:999px;color:#26734d;background:#d6f4e5;font-size:11px;padding:7px 11px}
.mandage-table{background:#fff;border:1px solid #c9ced3;box-shadow:6px 6px 0 #c7cdd0;border-radius:8px;overflow:hidden}
.mandage-line{display:grid;grid-template-columns:20px 1fr 60px;gap:14px;align-items:center;border-bottom:1px solid #e3e6e9;padding:14px}
.mandage-line:last-child{border:0}.mandage-line i{display:block;width:20px;height:20px;background:#d5dfec;border-radius:50%}
.mandage-line b{display:block;height:8px;background:#e7e9ed;border-radius:6px;width:80%}
.mandage-line em{display:block;width:55px;height:19px;background:#d6f4e5;border-radius:10px}
.mandage-footnote{font-size:11px;color:#60666d;text-align:right}
.extra-project{transition:background .44s var(--ease-smooth),padding .44s var(--ease-smooth),transform .4s}
.experience-item,.award-experience,.cert-card{transition:transform .55s var(--ease-smooth),box-shadow .55s var(--ease-smooth),background .55s}
/* Recognition is sourced from the new CV. */
.recognition-section{background:#f3f0e6;border-top:1px solid #d4d0c6}
.recognition-heading{display:flex;gap:30px;align-items:end;justify-content:space-between}
.recognition-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:17px;margin-top:40px}
.recognition-card{min-height:240px;background:#fff;border:2px solid var(--ink);padding:clamp(20px,3vw,35px);display:flex;align-items:start;flex-direction:column;
 transition:transform .6s var(--ease-smooth),box-shadow .6s var(--ease-smooth)}
.recognition-card:hover{transform:translate(-3px,-4px);box-shadow:5px 6px 0 var(--ink)}
.recognition-card>span{font-size:11px;letter-spacing:.13em;font-weight:700;color:#6c675d}
.recognition-card strong{margin-top:auto;font-size:clamp(25px,3vw,42px);letter-spacing:-.05em;line-height:1.05}
.recognition-card p{margin-top:9px;color:#605b53;font-size:14px;line-height:1.5}
.cv-certs{margin-top:40px;padding-top:25px;border-top:1px solid var(--line);display:flex;gap:12px;align-items:center;flex-wrap:wrap}
.cv-certs h3{font-size:19px;margin-right:12px}.cv-certs span{padding:10px 14px;background:white;border:1px solid var(--ink);font-size:12px;border-radius:999px}
/* Keep motion low-cost and never animate layout properties for reduced motion users. */
@media (max-width:1120px){
 .nav-links>a:not(.nav-mobile-cta){font-size:13px;padding-inline:10px}
 .nav-shell{gap:12px}.nav-actions{gap:8px}
}
@media (max-width:900px){
 .nav-shell{min-height:68px;padding-block:6px}
 .nav-links{display:flex;visibility:hidden;opacity:0;pointer-events:none;transform:translate3d(0,-14px,0);
   max-height:min(78dvh,650px);overflow-y:auto;overscroll-behavior:contain;transition:opacity .38s var(--ease-smooth),transform .45s var(--ease-smooth),visibility .45s}
 .nav-links.open{visibility:visible;opacity:1;pointer-events:auto;transform:none}
 .nav-links>a:not(.nav-mobile-cta){min-height:47px;width:100%;justify-content:flex-start;font-size:17px;padding:10px 15px;border-radius:9px}
 .nav-links>a:not(.nav-mobile-cta)::after{left:auto;right:16px;bottom:19px}
 .nav-links>a:not(.nav-mobile-cta):hover::after,.nav-links>a:not(.nav-mobile-cta).is-active::after,.nav-links>a:not(.nav-mobile-cta)[aria-current="page"]::after{transform:translate(0,0) scale(1)}
 .nav-mobile-cta{display:block!important;padding:15px!important;background:var(--yellow);border:2px solid var(--ink)!important;border-radius:10px;margin-top:10px}
 .menu-toggle{border-radius:8px;transition:background .4s,transform .4s var(--ease-smooth)}
 .menu-toggle:hover{background:var(--yellow)}
 .math-tile-2,.math-tile-3{display:none}
 .recognition-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width:720px){
 .grid-paper{--grid-step:64px;background-size:auto,var(--grid-step) var(--grid-step),var(--grid-step) var(--grid-step);animation-name:grid-travel-mobile}
 @keyframes grid-travel-mobile{from{background-position:0 0,0 0,0 0}to{background-position:0 0,64px 64px,64px 64px}}
 .math-tile{width:70px;height:70px;font-size:36px;opacity:.2!important}
 .math-tile-1{right:-23px;top:18%}.math-tile-4{right:3%;bottom:13%}
 .mandage-illustration{min-height:220px}
 .recognition-grid{grid-template-columns:minmax(0,1fr)}.recognition-card{min-height:170px}
 .recognition-heading{align-items:flex-start;flex-direction:column}
 .cv-certs{align-items:flex-start;flex-direction:column}
}
@media(max-width:480px){
 .nav-shell{min-height:62px}.wordmark{width:42px;height:42px;font-size:22px}
 .nav-links{top:calc(100% + 1px)}
 .hero-inner{padding-top:35px}.math-tile-4{display:none}
 .feature-stamp{font-size:8px;padding:7px 9px;bottom:12px;left:12px}
 .mandage-state{font-size:9px;padding:5px 8px}
 .mandage-illustration{gap:14px;padding:14px;min-height:200px}
 .mandage-line{padding:11px}
 .skill-pills{gap:8px}.skill-pill{padding:7px 10px;min-height:40px}.skill-pill img{width:19px;height:19px}
 .project-detail-panel{padding:14px;box-shadow:2px 2px 0 var(--ink)}
}
@media(prefers-reduced-motion: reduce){
 .grid-paper,.math-tile,body{animation:none!important}
 .reveal-up,.motion-enabled .reveal-up:not(.is-visible){opacity:1!important;transform:none!important}
 .scroll-progress{display:none}
}
@media(hover:none){
 .skill-pill:hover,.recognition-card:hover,.project-visual:hover{transform:none;box-shadow:none}
 .project-visual:hover img{transform:none}
}

/* Constrain decorative math layer to each subpage, including very narrow devices. */
.subpage-hero{position:relative;overflow:hidden}
@media(max-width:320px){.math-tile-1{right:-38px}}
@media(max-width:720px){.math-tile-1{right:12px!important}}
@media(max-width:320px){.subpage-hero h1{font-size:clamp(2.55rem,11.8vw,3rem);letter-spacing:-.065em;overflow-wrap:anywhere}}
@media(max-width:320px){.section-title{font-size:2rem;letter-spacing:-.065em}}


/* === Reviewer-first refinement: restrained proof, confident typography, no fake logo badges. === */
/* Navigation: soft animated pill without the formerly distracting yellow dot. */
.nav-links>a:not(.nav-mobile-cta)::after{display:none!important;content:none!important}
.nav-links>a:not(.nav-mobile-cta){transition:background-color .35s cubic-bezier(.22,1,.36,1),color .35s,transform .4s cubic-bezier(.22,1,.36,1),box-shadow .35s}
.nav-links>a:not(.nav-mobile-cta):hover,.nav-links>a:not(.nav-mobile-cta).is-active,.nav-links>a:not(.nav-mobile-cta)[aria-current="page"]{background-color:#e9e7de!important;box-shadow:none!important;transform:translateY(-1px)}
/* Large dynamic "design tiles" rather than mathematical glyphs. Their visuals are pure CSS. */
.math-tile{width:clamp(120px,14vw,205px);height:clamp(120px,14vw,205px);font-size:initial;overflow:hidden;border:1.4px solid rgba(22,22,22,.22);border-radius:8px;background:rgba(255,255,255,.16);box-shadow:0 9px 25px rgba(22,22,22,.045);animation-duration:6.4s;animation-timing-function:cubic-bezier(.45,0,.55,1)}
.hero .math-tile{opacity:.65}
.math-tile-1{right:3%;top:8%}.math-tile-2{right:19%;top:41%}.math-tile-3{left:49%;top:10%}.math-tile-4{right:2%;bottom:5%}
.tile-art{position:relative;display:flex;width:60%;height:54%;align-items:center;justify-content:center;gap:7%;opacity:.62}
.tile-art i,.tile-art b{display:block;position:relative;flex-shrink:0;background:rgba(22,22,22,.28)}
.tile-art-window{height:54%;border:2px solid rgba(22,22,22,.3);border-radius:6px;align-items:flex-start;padding:15% 9% 7%;gap:6%}
.tile-art-window:before{content:"";position:absolute;top:0;left:0;right:0;height:24%;border-bottom:2px solid rgba(22,22,22,.28);background:rgba(250,204,0,.3)}
.tile-art-window i{width:22%;height:65%;border-radius:2px}.tile-art-window i:nth-child(2){height:86%;background:rgba(250,204,0,.75)}.tile-art-window i:nth-child(3){height:45%}.tile-art-window b{position:absolute;right:8%;bottom:10%;width:31%;height:9%;background:rgba(22,22,22,.2)}
.tile-art-graph{align-items:flex-end;gap:10%;height:60%;border-bottom:2px solid rgba(22,22,22,.2)}
.tile-art-graph i{width:16%;height:42%;border-radius:3px 3px 0 0}.tile-art-graph i:nth-child(2){height:78%;background:rgba(250,204,0,.8)}.tile-art-graph i:nth-child(3){height:55%}.tile-art-graph i:nth-child(4){height:95%}
.tile-art-stack{flex-direction:column;gap:15%;justify-content:center}
.tile-art-stack i{width:94%;height:20%;border-radius:3px}.tile-art-stack i:nth-child(2){width:65%;margin-right:auto;background:rgba(250,204,0,.7)}.tile-art-stack i:nth-child(3){width:81%;margin-right:auto}
.tile-art-flow{gap:9%;flex-wrap:wrap;width:58%;height:58%;align-content:center;justify-content:space-around}
.tile-art-flow i{border:2px solid rgba(22,22,22,.35);background:transparent;width:37%;height:36%;border-radius:5px}.tile-art-flow i:nth-child(2){background:rgba(250,204,0,.32)}
@keyframes math-drift{from{translate:-6px -15px;rotate:-2deg}to{translate:8px 17px;rotate:2deg}}
.grid-paper{animation-duration:24s}
/* About: confident but approachable; no tall empty space after removing the metrics. */
.hero-inner{padding-bottom:clamp(55px,7vw,105px)}
.about-copy>p{max-width:62ch}
.about-copy>p:not(.about-lead){line-height:1.8}
/* Brand logos and engineering practices are intentionally distinguished. */
.skill-pill{min-height:47px;padding:10px 14px;gap:10px;font-size:13px;white-space:nowrap}
.skill-pill img{width:24px;height:24px;object-fit:contain}
.skill-pill img[hidden]{display:none!important}
.skill-practice{border-style:dashed;border-color:#8c8880;background:transparent;color:#373430;font-weight:600}
.skill-practice::before{content:"";display:inline-block;width:5px;height:5px;flex:none;border-radius:50%;background:#8a806e}
.project-live-cta{margin:2px 15px 20px 0;vertical-align:middle}
.project-detail>summary{min-width:130px;display:inline-flex}
.project-detail{margin-top:2px}
.cert-linkedin{white-space:normal}
.certificate-section .section-top{align-items:flex-end}
.cv-dialog-body p{line-height:1.4}
@media (max-width:900px){.math-tile{width:clamp(105px,16vw,160px);height:clamp(105px,16vw,160px)}.nav-links>a:not(.nav-mobile-cta){transform:none!important}.nav-links>a:not(.nav-mobile-cta):hover{background:#e9e7de!important}}
@media (max-width:720px){.grid-paper{animation-duration:18s}.math-tile{width:112px;height:112px;opacity:.35!important;animation-duration:6.8s}.math-tile-1{right:12px!important;top:8%}.math-tile-4{right:3%;bottom:12%}}
@media (max-width:480px){.math-tile{width:100px;height:100px}.math-tile-1{right:8px!important;top:16%}.math-tile-2,.math-tile-3,.math-tile-4{display:none}.skill-pill{font-size:12px;min-height:44px;max-width:100%;white-space:normal}.project-live-cta{margin:2px 10px 16px 0}.certificate-section .section-top{align-items:flex-start;flex-direction:column;gap:18px}}
@media(prefers-reduced-motion: reduce){.grid-paper,.math-tile{animation:none!important}}
/* The mobile menu must become keyboard/touch actionable immediately on open;
   only opacity and translate animate, never its visibility state. */
@media(max-width:900px){
  .nav-links{transition:opacity .34s cubic-bezier(.22,1,.36,1),transform .43s cubic-bezier(.22,1,.36,1)!important}
  .nav-links.open{visibility:visible!important}
}

/* ── Revision 4: quiet animated grid, editorial scroll, and polished interactions ── */
:root { --motion-ease:cubic-bezier(.16,1,.3,1); }
html { scrollbar-width:thin; scrollbar-color:#666159 #f2f0e9; scroll-behavior:smooth; }
body { scrollbar-width:thin; }
::-webkit-scrollbar{width:10px;height:9px}
::-webkit-scrollbar-track{background:#e9e6df}
::-webkit-scrollbar-thumb{background:#716d63;border:2px solid #e9e6df;border-radius:999px}
::-webkit-scrollbar-thumb:hover{background:#161616}
::selection { background:#ffe369; color:#161616; }
/* Never imply an action exists by showing the pointer on decorative-only blocks. */
a[href],button:not(:disabled),summary,[data-open-cv],[data-copy-email] { cursor:pointer; }
.eyebrow,.availability,.rule,.accent-dot,.hero-period,.section-label,.scroll-progress,.skill-pill,.portrait-label,.project-url,.project-visual-top,.project-copy .eyebrow,.form-seal,.cv-page figcaption { user-select:none;-webkit-user-select:none; }
.grid-paper{
  --grid-step:128px;
  background-image:radial-gradient(circle at 18% 6%,rgba(250,204,0,.11),transparent 34%),
    linear-gradient(90deg,rgba(22,22,22,.083) 1px,transparent 1px),
    linear-gradient(0deg,rgba(22,22,22,.083) 1px,transparent 1px);
  background-size:auto,var(--grid-step) var(--grid-step),var(--grid-step) var(--grid-step);
  animation:blueprint-move 11s linear infinite;
}
@keyframes blueprint-move{
  0%{background-position:0 0,0 0,0 0}
  100%{background-position:0 0,128px 128px,128px 128px}
}
.math-scene,.math-tile,.hero-scribble{display:none!important}
/* Only whisper-light patterns in quiet supporting sections. */
.skills-section{background-color:#e7e5dd;background-image:radial-gradient(rgba(22,22,22,.065) .75px,transparent .85px);background-size:30px 30px}
.proof-section{background-color:#fff;background-image:linear-gradient(90deg,transparent 96%,rgba(22,22,22,.018) 96%),linear-gradient(transparent 96%,rgba(22,22,22,.018) 96%);background-size:57px 57px}
.contact-page-section{background-color:#fdfcf8;background-image:radial-gradient(rgba(22,22,22,.038) .75px,transparent .85px);background-size:36px 36px}
/* Long, graceful reveals without reflow. */
.reveal-up{transition:opacity .9s var(--motion-ease),transform 1.05s var(--motion-ease)}
.motion-enabled .reveal-up:not(.is-visible){opacity:0;transform:translate3d(0,38px,0)}
/* Non-tilted, larger arrowheads with soft forward motion. */
.btn-arrow,.visual-corner,.extra-arrow{font-family:Arial,system-ui,sans-serif;font-size:clamp(20px,1.8vw,27px);font-weight:900;line-height:1}
.btn .btn-arrow{width:31px;height:31px;transition:transform .55s var(--motion-ease),background .55s var(--motion-ease)}
.btn:hover .btn-arrow{transform:translateX(4px)!important}
.inline-link:hover,.extra-project:hover .extra-arrow{transform:translateX(4px)}
.visual-corner{width:48px;height:48px}
/* Sticky-split editorial storytelling. It degrades gracefully on smaller viewports. */
@media(min-width:961px){
  .about-grid{align-items:start;min-height:clamp(590px,70vh,790px)}
  .about-grid>div:first-child{position:sticky;top:112px;align-self:start}
  .experience-grid{align-items:start}
  .experience-sidebar{top:114px}
  .projects-list .project-feature{align-items:start;min-height:clamp(600px,73vh,820px)}
  .projects-list .project-visual{position:sticky;top:118px;align-self:start;max-height:calc(100vh - 144px)}
  .project-copy{padding-top:clamp(20px,4vw,75px)}
  .contact-page-grid{align-items:start}
  .contact-side{position:sticky;top:112px}
}
.experience-list .experience-item:first-child{background:#fffdf5;border-left:4px solid var(--yellow)}
/* Natural scrolling across input types; respect touch momentum. */
[data-lenis-prevent]{overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
html.lenis,html.lenis body{height:auto}
.lenis.lenis-smooth{scroll-behavior:auto!important}
.lenis.lenis-stopped{overflow:hidden}
.lenis.lenis-smooth [data-lenis-prevent]{overscroll-behavior:contain}
/* CV: custom locally rendered PDF pages, no browser PDF toolbar. */
.cv-dialog{width:min(900px,calc(100vw - 32px));height:min(94dvh,1140px);background:#e6e4de;box-shadow:9px 9px 0 #161616}
.cv-dialog::backdrop{background:rgba(10,10,10,.77);backdrop-filter:blur(4px)}
.cv-dialog[open]{animation:cv-rise .45s var(--motion-ease) both}
@keyframes cv-rise{from{opacity:0;transform:translateY(24px) scale(.975)}to{opacity:1;transform:translateY(0) scale(1)}}
.cv-dialog-header{height:76px;flex:none;position:relative;z-index:2;background:#fff;box-shadow:0 5px 18px rgba(22,22,22,.09);padding:10px clamp(12px,2vw,22px);gap:12px}
.cv-dialog-header strong{font-size:clamp(13px,1.5vw,18px);font-weight:700;white-space:normal;line-height:1.2}
.cv-dialog-header strong span{color:#c8a000;margin-inline:3px}
.cv-dialog-actions{display:flex;align-items:center;gap:clamp(8px,1.4vw,20px)}
.cv-pagecount{font-size:10px;letter-spacing:.14em;font-weight:700;color:#6a665e;white-space:nowrap}
.dialog-close{width:43px;height:43px;border-radius:50%;font-size:30px;font-weight:400;line-height:1;background:#f2f0e9;flex:none;transition:transform .35s var(--motion-ease),background .35s}
.dialog-close:hover{transform:rotate(90deg);background:var(--yellow)}
.cv-dialog-body{display:block;height:calc(100% - 76px);overflow-y:auto;overflow-x:hidden;background:#deddd8;scrollbar-width:thin;scrollbar-color:#8b867e #deddd8}
.cv-pages{display:grid;justify-items:center;gap:24px;padding:clamp(12px,3vw,28px)}
.cv-page{margin:0;width:min(100%,730px);background:white;box-shadow:0 10px 30px rgba(22,22,22,.18);min-width:0}
.cv-page img{width:100%;height:auto;display:block;object-fit:contain}
.cv-page figcaption{font-size:10px;letter-spacing:.2em;text-align:center;background:#fff;border-top:1px solid #eee;padding:8px}
/* Awwwards-inspired two-stroke mobile toggle and full-height staggered menu. */
@media(max-width:900px){
  .nav-shell{z-index:3}
  body.menu-open{overflow:hidden;touch-action:pan-x}
  .menu-toggle{display:inline-flex!important;width:auto!important;min-width:105px;height:48px!important;gap:12px!important;border:2px solid #161616!important;border-radius:999px!important;background:#161616!important;color:#fff;align-items:center;justify-content:center;flex-direction:row!important;padding:0 15px!important;box-shadow:3px 3px 0 var(--yellow);transition:color .35s,background .4s,box-shadow .4s,transform .4s var(--motion-ease)!important}
  .menu-toggle:hover{background:var(--yellow)!important;color:#161616;transform:translateY(-2px)}
  .menu-toggle[aria-expanded="true"]{background:var(--yellow)!important;color:#161616;box-shadow:1px 1px 0 var(--ink)}
  .menu-toggle span,.menu-toggle[aria-expanded="true"] span:first-child,.menu-toggle[aria-expanded="true"] span:last-child{width:auto!important;height:auto!important;background:transparent!important;transform:none!important;opacity:1!important}
  .menu-toggle .menu-label{display:block!important;font-size:12px;font-weight:700;letter-spacing:.11em;line-height:1;white-space:nowrap}
  .menu-toggle .menu-lines{position:relative;display:block!important;width:25px!important;height:22px!important;flex:none}
  .menu-toggle .menu-lines i{position:absolute;display:block;width:23px;height:2.5px;background:currentColor;border-radius:2px;left:1px;transform-origin:center;transition:top .45s var(--motion-ease),transform .45s var(--motion-ease),width .45s var(--motion-ease)}
  .menu-toggle .menu-lines i:first-child{top:6px}
  .menu-toggle .menu-lines i:last-child{top:14px;width:15px;left:auto;right:1px}
  .menu-toggle:hover .menu-lines i:last-child{width:23px}
  .menu-toggle[aria-expanded="true"] .menu-lines i:first-child{top:10px;transform:rotate(45deg)}
  .menu-toggle[aria-expanded="true"] .menu-lines i:last-child{top:10px;width:23px;transform:rotate(-45deg)}
  .nav-links{display:flex!important;position:absolute!important;top:calc(100% + 1px)!important;left:calc(var(--gutter)*-1)!important;right:calc(var(--gutter)*-1)!important;min-height:calc(100dvh - 73px);max-height:calc(100dvh - 73px)!important;padding:clamp(25px,6vw,60px) var(--gutter)!important;gap:0!important;background:#f2f0e9!important;border-top:1px solid #cbc8bf;border-bottom:0;box-shadow:0 18px 40px rgba(22,22,22,.11)!important;overflow-y:auto!important;overscroll-behavior:contain;scrollbar-width:thin;
    visibility:hidden;pointer-events:none;opacity:0;transform:translateY(-24px);transition:opacity .45s var(--motion-ease),transform .65s var(--motion-ease),visibility .65s!important}
  .nav-links.open{visibility:visible;pointer-events:auto;opacity:1;transform:translateY(0)}
  .nav-links>a:not(.nav-mobile-cta){min-height:clamp(61px,10vh,86px)!important;display:flex!important;justify-content:space-between!important;gap:16px;border-bottom:1px solid #c7c2b8!important;border-radius:0!important;padding:12px 4px!important;background:transparent!important;font-size:clamp(26px,6vw,50px)!important;font-weight:700;letter-spacing:-.05em;line-height:1.1;white-space:normal;transform:none!important}
  .nav-links>a:not(.nav-mobile-cta)::before{content:attr(data-index);font-size:12px;letter-spacing:0;align-self:center;order:-1;color:#77736a;margin-right:auto;flex:0 0 35px}
  .nav-links>a:not(.nav-mobile-cta):hover{color:#7b6500;box-shadow:none!important;padding-left:9px!important}
  .nav-links>a:not(.nav-mobile-cta):focus-visible{outline:3px solid #ae8700;outline-offset:-3px}
  .nav-links.open>a{animation:menu-link-enter .65s var(--motion-ease) backwards;animation-delay:calc(var(--nav-i,1)*44ms)}
  @keyframes menu-link-enter{from{opacity:0;transform:translate3d(0,28px,0)}to{opacity:1;transform:translate3d(0,0,0)}}
  .nav-links .nav-mobile-cta{display:flex!important;align-items:center;justify-content:center;min-height:53px;margin-top:24px;background:var(--yellow);border:2px solid var(--ink)!important;border-radius:999px;padding:10px 18px!important;font-size:17px;font-weight:700}
}
@media(max-width:480px){
  .menu-toggle{min-width:95px;height:43px!important;padding:0 12px!important;gap:10px!important}
  .nav-links{min-height:calc(100dvh - 64px)!important;max-height:calc(100dvh - 64px)!important}
  .nav-links>a:not(.nav-mobile-cta){min-height:62px!important;font-size:clamp(25px,8vw,36px)!important}
  .nav-links>a:not(.nav-mobile-cta)::before{flex-basis:28px}
  .cv-dialog{width:calc(100vw - 12px);height:calc(100dvh - 12px);max-height:none;box-shadow:none}
  .cv-dialog-header{height:66px;padding:7px 10px}
  .cv-dialog-header strong{font-size:11px}
  .cv-dialog-header .btn{min-height:39px;padding:7px 10px;font-size:11px}
  .cv-dialog-actions{gap:7px}
  .cv-pagecount{display:none}
  .cv-dialog-body{height:calc(100% - 66px)}
  .cv-pages{gap:12px;padding:8px}
  .dialog-close{width:37px;height:37px;font-size:25px}
  .grid-paper{--grid-step:108px;animation:blueprint-move-small 9s linear infinite}
  @keyframes blueprint-move-small{from{background-position:0 0,0 0,0 0}to{background-position:0 0,108px 108px,108px 108px}}
}
@media(max-width:320px){.nav-links>a:not(.nav-mobile-cta){font-size:24px!important}.menu-toggle{min-width:87px}}
/* Contact form: an editable paper note, structured like a carefully designed letter. */
.contact-page-grid{gap:clamp(35px,7vw,105px)}
.contact-form{position:relative;isolation:isolate;overflow:hidden;border:2px solid #161616;background:#fffef9;box-shadow:9px 9px 0 var(--ink);padding:clamp(20px,3.4vw,48px);border-radius:0}
.contact-form::before{content:"";position:absolute;z-index:-1;inset:0;background:repeating-linear-gradient(to bottom,transparent 0,transparent 42px,rgba(22,22,22,.046) 43px,transparent 44px);pointer-events:none}
.contact-form::after{content:"";position:absolute;right:0;top:0;width:70px;height:70px;background:linear-gradient(225deg,#e7e5dd 0 50%,transparent 50%);pointer-events:none;opacity:.66}
.contact-form-top{display:flex;align-items:center;gap:22px;margin-bottom:38px;padding-bottom:26px;border-bottom:1px solid #bbb6ad}
.form-seal{width:72px;height:72px;display:grid;place-content:center;flex:none;background:var(--yellow);border:2px solid var(--ink);box-shadow:3px 3px 0 var(--ink);font-size:28px;font-weight:700;line-height:1;transform:rotate(-5deg)}
.form-seal span{font-size:15px;justify-self:end;margin-top:5px}
.contact-form-top h3{font-size:clamp(29px,3.3vw,45px);line-height:1.02;letter-spacing:-.07em;margin:8px 0 10px;text-wrap:balance}
.contact-form-top p{font-size:13px;line-height:1.5;color:#5c564d}
.contact-form .field{position:relative;margin:0 0 31px}
.contact-form .field label{display:block;margin-bottom:9px;font-size:11px;letter-spacing:.15em;font-weight:700;line-height:1.5}
.contact-form .field input,.contact-form .field textarea{position:relative;border:none;border-bottom:2px solid #beb8aa!important;border-radius:0;background:rgba(255,255,255,.8);padding:13px 13px 13px 2px;min-height:56px;line-height:1.4;color:#1b1716;box-shadow:none;outline:none;transition:border-color .3s var(--motion-ease),background .3s,box-shadow .3s}
.contact-form .field input:focus,.contact-form .field textarea:focus{border-color:#161616!important;background:#fffdfa;outline:none;box-shadow:0 3px 0 var(--yellow)}
.contact-form .field input:not(:placeholder-shown),.contact-form .field textarea:not(:placeholder-shown){border-color:#94866b}
.contact-form .field input.handwritten-entry,.contact-form .field textarea.handwritten-entry{font-family:'Patrick Hand','Segoe Print','Comic Sans MS',cursive;font-size:clamp(23px,2vw,28px);font-weight:400;letter-spacing:.015em}
.contact-form .field input::placeholder,.contact-form .field textarea::placeholder{font-family:var(--font);font-size:15px;color:#89857d;letter-spacing:0}
.contact-form .field textarea{min-height:165px;resize:none;overflow-y:auto;max-height:340px}
.message-count{display:block;text-align:right;font-size:10px;line-height:1.4;color:#827b70;margin-top:7px;font-variant-numeric:tabular-nums;letter-spacing:.05em}
.contact-form .form-bottom{gap:15px;border-top:1px solid #ccc6bc;padding-top:25px;margin-top:15px}
.contact-form .form-bottom .btn{min-height:56px;font-size:14px}
.contact-form:focus-within{box-shadow:11px 11px 0 var(--ink)}
/* Connor: smooth entrance/exit, with actual inert and aria-hidden state. */
.chat-window{display:flex!important;visibility:hidden;opacity:0;pointer-events:none;transform:translateY(25px) scale(.955);transform-origin:bottom right;transition:transform .55s var(--motion-ease),opacity .36s ease,visibility .55s;will-change:opacity,transform}
.chat-window.is-open{visibility:visible;opacity:1;pointer-events:auto;transform:translateY(0) scale(1)}
.chat-toggle-spark{transition:transform .5s var(--motion-ease)}
.chat-toggle.is-open .chat-toggle-spark{transform:rotate(90deg)}
.chat-window .chat-msg{animation:chat-bubble-enter .4s var(--motion-ease) both}
@keyframes chat-bubble-enter{from{opacity:0;transform:translateY(12px) scale(.97)}to{opacity:1;transform:none}}
/* Keyboard, touch and reduced-motion guardrails. */
@media(hover:none){.project-visual:hover,.recognition-card:hover,.cert-card:hover,.skill-pill:hover{transform:none!important}}
@media(prefers-reduced-motion:reduce){
  .grid-paper,.nav-links.open>a,.chat-msg,.cv-dialog[open]{animation:none!important}
  .chat-window,.menu-toggle .menu-lines i,.nav-links,.btn,.btn-arrow,.reveal-up{transition:none!important}
  .motion-enabled .reveal-up:not(.is-visible){opacity:1!important;transform:none!important}
}
/* Finishing touches from the responsive recruiter pass. */
.project-arno .project-visual>img{object-fit:contain;background:#0d1017}
.cv-dialog-header .btn{flex-shrink:0;white-space:nowrap}
.cv-zoom-controls{position:absolute;right:20px;bottom:18px;z-index:5;display:flex;align-items:center;gap:0;background:rgba(255,255,255,.96);border:2px solid var(--ink);border-radius:999px;box-shadow:3px 3px 0 var(--ink);overflow:hidden;backdrop-filter:blur(10px)}
.cv-zoom-controls button{display:grid;place-items:center;width:44px;height:43px;border:0;background:transparent;color:var(--ink);font-size:24px;font-weight:700;transition:background .25s}
.cv-zoom-controls button:hover:not(:disabled){background:var(--yellow)}
.cv-zoom-controls button:disabled{opacity:.3;cursor:not-allowed}
.cv-zoom-controls output{width:57px;text-align:center;font-size:12px;letter-spacing:.02em;font-weight:700;font-variant-numeric:tabular-nums;user-select:none}
.cv-dialog-body{overflow-x:auto}
.cv-dialog.is-zoomed .cv-page{width:100%;max-width:none}
@media(max-width:480px){.cv-zoom-controls{right:13px;bottom:13px}.cv-zoom-controls button{height:39px;width:41px}.cv-dialog-header .btn{font-size:11px;letter-spacing:-.02em}}
@media(max-width:320px){.cv-dialog-header strong{font-size:10px;max-width:88px}.cv-dialog-header .btn{font-size:10px;min-height:35px;padding:5px 8px}.cv-zoom-controls output{width:49px}}


/* === WALKTHROUGH-MATCHED EDITORIAL REFINEMENTS (2026-11-07) === */
:root{--ref-ease:cubic-bezier(.22,1,.36,1);--ref-ink:#161616;--ref-line:#d5d2c8}
/* Font Awesome Free arrow-right (classic solid, properly licensed). Keep icon geometry consistent. */
.fa-arrow-icon{display:inline-block!important;width:15px!important;height:15px!important;min-width:15px!important;max-width:15px!important;max-height:15px!important;object-fit:contain!important;vertical-align:-.13em;flex:none;user-select:none;pointer-events:none;transform:none;transition:transform .42s var(--ref-ease)}
.btn .fa-arrow-icon,.inline-link .fa-arrow-icon{margin-left:2px}
.btn-arrow{display:inline-grid;place-items:center;font-size:0!important}
.btn-arrow .fa-arrow-icon{width:13px!important;height:13px!important;min-width:13px!important}
.btn:hover .btn-arrow{transform:translateX(3px)!important}
a:hover>.fa-arrow-icon,button:hover>.fa-arrow-icon,.inline-link:hover .fa-arrow-icon,.extra-project:hover .fa-arrow-icon{transform:translateX(3px)}
.visual-corner .fa-arrow-icon{width:17px!important;height:17px!important;min-width:17px!important;transition:transform .55s var(--ref-ease)}
.project-visual:hover .visual-corner .fa-arrow-icon{transform:translateX(3px)}
.extra-arrow .fa-arrow-icon{width:16px!important;height:16px!important;min-width:16px!important}
/* Floating vertical affordance adapted from the recorded reference. */
.to-top{position:fixed;right:24px;bottom:105px;z-index:1019;display:grid;place-items:center;width:48px;height:48px;background:#fff;border:2px solid var(--ink);border-radius:50%;box-shadow:3px 3px 0 var(--ink);opacity:0;visibility:hidden;transform:translateY(14px);pointer-events:none;transition:opacity .35s ease,visibility .35s,transform .5s var(--ref-ease),background .3s}
.to-top.is-visible{opacity:1;visibility:visible;transform:none;pointer-events:auto}
.to-top .fa-arrow-icon{transform:rotate(-90deg);width:15px!important;height:15px!important;min-width:15px!important}
.to-top:hover{background:var(--yellow);transform:translateY(-3px)}
.to-top:hover .fa-arrow-icon{transform:rotate(-90deg) translateX(3px)}
/* Reference nav uses a single smoothly travelling neutral selection, not a flashing yellow underline. */
.nav-links{position:relative;isolation:isolate;gap:4px}
.nav-slide{position:absolute;z-index:-1;top:50%;left:0;height:46px;border-radius:9px;background:#e8e6df;opacity:0;visibility:hidden;transform:translate3d(0,-50%,0);pointer-events:none;transition:transform .58s var(--ref-ease),width .58s var(--ref-ease),opacity .3s ease,visibility .3s}
.nav-slide.has-target{opacity:1;visibility:visible}
.nav-links>a:not(.nav-mobile-cta){font-size:clamp(13px,1vw,15px);font-weight:500;letter-spacing:-.015em;min-height:46px;padding-inline:clamp(12px,1.15vw,19px);background:transparent!important;box-shadow:none!important;transform:none!important}
.nav-links>a:not(.nav-mobile-cta):hover,.nav-links>a:not(.nav-mobile-cta).is-active,.nav-links>a:not(.nav-mobile-cta)[aria-current="page"]{background:transparent!important;box-shadow:none!important;transform:none!important}
.nav-shell{min-height:70px;padding-block:7px}
.wordmark{width:44px;height:44px;border-radius:7px;font-size:23px}
.site-header{background:rgba(247,246,240,.96);border-bottom:1px solid rgba(22,22,22,.19)}
.site-header.is-scrolled{box-shadow:0 7px 22px rgba(22,22,22,.035)}
.scroll-progress{height:2px;opacity:.85}
/* Reference video: faint geometric paper, restrained warm bloom, fine rules. */
.grid-paper{background-image:radial-gradient(circle at 23% 5%,rgba(250,204,0,.13),transparent 27%),linear-gradient(90deg,rgba(22,22,22,.065) 1px,transparent 1px),linear-gradient(0deg,rgba(22,22,22,.065) 1px,transparent 1px)}
.hero-inner{padding-top:clamp(44px,5.3vw,74px);padding-bottom:clamp(45px,5vw,74px)}
.hero-kicker{margin-bottom:clamp(22px,3vw,42px)}
.hero-name{letter-spacing:-.089em;line-height:.79}
.hero-after{margin-top:clamp(28px,3.8vw,52px)}
.hero-intro h2{font-size:clamp(26px,3.35vw,46px);letter-spacing:-.05em}
.hero-intro p{max-width:55ch}
/* The reference separates sections with precise horizontal borders and less unused padding. */
.section{padding-block:clamp(66px,7vw,104px)}
.section-label{margin-bottom:clamp(26px,3vw,45px)}
.section-top{margin-bottom:clamp(30px,4vw,55px)}
.skills-section .section-title,.experience-section .section-title{font-size:clamp(31px,3.4vw,49px);line-height:1.08;letter-spacing:-.052em;text-transform:none}
.projects-section .section-title{font-size:clamp(34px,4vw,57px);line-height:1.06;letter-spacing:-.05em;text-transform:none}
.skills-section,.experience-section,.projects-section,.education-section{border-top:1px solid rgba(22,22,22,.17)}
/* Quiet typography in the toolkit; compact, uniform labels and badges from the video. */
.skill-group{grid-template-columns:minmax(190px,.32fr) minmax(0,1fr);padding:22px 0;gap:25px}
.skill-group-name{padding-top:7px}
.skill-pill{min-height:37px;padding:7px 11px;gap:7px;font-size:11.5px;border:1px solid #d0cdc3;border-radius:5px;box-shadow:none;transition:transform .5s var(--ref-ease),background .4s,border-color .4s,box-shadow .4s}
.skill-pill img{width:19px;height:19px}
.skill-pill:hover{transform:translateY(-2px);background:#fff;box-shadow:2px 3px 0 rgba(22,22,22,.1);border-color:#99958b}
.skill-practice{border-style:dashed}
.capabilities{margin-top:55px}
/* Reference scroll storytelling: left timeline follows viewport, right detail becomes active. */
.experience-grid{grid-template-columns:minmax(240px,.42fr) minmax(0,.9fr);gap:clamp(34px,5vw,75px);margin-top:34px;align-items:start}
.experience-sidebar{position:sticky;top:108px;border-top:1px solid var(--line);padding-top:22px}
.experience-rail-title{font-size:clamp(24px,2.5vw,35px);font-weight:700;letter-spacing:-.055em;margin:13px 0 27px}
.experience-rail{display:flex;flex-direction:column;gap:7px}
.experience-rail-link{position:relative;display:grid;grid-template-columns:18px minmax(0,1fr);align-items:start;gap:9px;min-height:63px;padding:12px 12px 12px 10px;background:transparent;border-radius:6px;transition:background .45s var(--ref-ease),color .45s var(--ref-ease),transform .45s var(--ref-ease)}
.experience-rail-link:hover,.experience-rail-link.is-current{background:#eae9e4}
.experience-rail-link:hover{transform:translateX(3px)}
.experience-rail-copy{display:flex;flex-direction:column;gap:3px;min-width:0}
.experience-rail-copy strong{font-size:13px;line-height:1.3;font-weight:500;overflow-wrap:anywhere}
.experience-rail-copy small{font-size:11px;line-height:1.5;color:#706d67}
.experience-rail-link.is-current strong{font-weight:700}
.experience-rail-dot{width:8px;height:8px;margin-top:5px;border:1.5px solid #8f8c83;border-radius:50%;background:transparent;transition:background .4s,border-color .4s,box-shadow .4s}
.experience-rail-link.is-current .experience-rail-dot{background:var(--yellow);border-color:var(--ink);box-shadow:0 0 0 2px #f4f3ee}
.experience-rail-footer{font-size:12px;color:#68645b;line-height:1.6;max-width:34ch;margin-top:22px;padding-top:15px;border-top:1px solid var(--line)}
.experience-item{border:1.5px solid #bbb8af;border-radius:8px;box-shadow:none;opacity:.72;background:#fbfaf7;min-height:230px;transition:opacity .7s var(--ref-ease),background .7s var(--ref-ease),box-shadow .7s var(--ref-ease),border-color .7s var(--ref-ease),transform .7s var(--ref-ease)}
.experience-item.is-current{border-color:var(--ink);box-shadow:4px 5px 0 var(--ink);opacity:1;background:#fff;transform:translate(-1px,-1px)}
.experience-item:hover{opacity:1;box-shadow:4px 5px 0 var(--ink);transform:translate(-1px,-1px)}
.experience-list .experience-item:first-child{background:#fbfaf7;border-left:1.5px solid #bbb8af}
.experience-list .experience-item:first-child.is-current{background:#fff;border-left:1.5px solid var(--ink)}
.experience-item h3{font-size:clamp(23px,2.3vw,32px)}
.experience-item p{font-size:14px;line-height:1.75}
/* Project rows: alternating image/text composition and shorter gaps, as seen in walkthrough. */
.projects-list{gap:clamp(55px,7vw,105px)}
.project-feature{grid-template-columns:minmax(0,1fr) minmax(0,.88fr);gap:clamp(32px,5.4vw,76px)}
.project-copy{padding-top:0!important}
.project-copy h3{font-size:clamp(38px,4.2vw,61px);line-height:1.04;letter-spacing:-.062em;margin:10px 0 12px}
.project-copy h4{font-size:clamp(17px,1.7vw,23px);line-height:1.3;margin-bottom:13px}
.project-copy p{font-size:14px;line-height:1.75}
.tag-list{margin:18px 0 22px;gap:5px}
.tag-list span{font-size:10px;border-radius:6px;padding:5px 9px}
.project-visual{border:1.5px solid var(--ink);border-radius:9px;box-shadow:4px 5px 0 var(--ink);aspect-ratio:1.46;transition:transform .65s var(--ref-ease),box-shadow .65s var(--ref-ease)}
.project-visual:hover{transform:translate(-2px,-3px);box-shadow:6px 7px 0 var(--ink)}
.project-visual img{transition:transform 1.15s var(--ref-ease),filter 1s var(--ref-ease)}
.visual-corner{width:35px;height:35px;bottom:12px;right:12px}
.feature-stamp{font-size:9px;padding:7px 9px;bottom:12px;left:12px;letter-spacing:.06em;box-shadow:2px 2px 0 var(--ink)}
.project-detail-panel{border-radius:4px}
@media(min-width:961px){
  .projects-list .project-feature{min-height:clamp(470px,60vh,660px)}
  .projects-list .project-visual{top:112px;max-height:calc(100vh - 144px)}
  .about-grid{min-height:clamp(540px,67vh,740px)}
}
/* Gentle image focus, typographic hierarchy and page links. */
.about-photo-frame{border-radius:8px;box-shadow:5px 6px 0 var(--ink)}
.about-photo-frame img{transition:filter .75s var(--ref-ease),transform 1.25s var(--ref-ease)}
.about-photo-frame:hover img{filter:saturate(1);transform:scale(1.022)}
.inline-link{transition:transform .48s var(--ref-ease),border-color .48s var(--ref-ease)}
.btn{transition:background .48s var(--ref-ease),transform .5s var(--ref-ease),box-shadow .5s var(--ref-ease)}
.btn:hover{transform:translate(-1px,-2px);box-shadow:5px 6px 0 var(--ink)}
.btn:active{transform:translate(2px,2px);box-shadow:1px 1px 0 var(--ink)}
/* Reveals are gentle, quick to register and stagger within the work section. */
.reveal-up{transition:opacity .85s var(--ref-ease),transform 1s var(--ref-ease);transition-delay:var(--reveal-delay,0ms)}
.motion-enabled .reveal-up:not(.is-visible){transform:translate3d(0,24px,0)}
/* Avoid a stuck invisible panel if browser skips animation events or fonts arrive late. */
@media(max-width:900px){
  .nav-slide{display:none}
  .nav-shell{min-height:68px}
  .experience-grid{grid-template-columns:1fr;gap:30px}
  .experience-sidebar{position:static;padding-top:15px}
  .experience-rail{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
  .experience-rail-link{min-height:62px;padding:10px}
  .experience-rail-title{margin-bottom:14px}
  .experience-rail-footer{max-width:none}
  .experience-item{opacity:1;min-height:0}
  .project-feature{grid-template-columns:repeat(2,minmax(0,1fr))}
  .projects-list .project-feature{min-height:0}
}
@media(max-width:720px){
  .experience-rail{grid-template-columns:1fr}
  .experience-rail-link{min-height:52px}
  .project-feature{grid-template-columns:1fr}
  .project-feature .project-visual{position:relative;top:auto}
  .project-feature:nth-child(even) .project-visual{order:0}
  .project-feature:nth-child(even) .project-copy{order:1}
  .project-copy{padding-top:0!important}
  .projects-list{gap:75px}
  .skills-section .section-title,.experience-section .section-title{font-size:clamp(29px,7vw,41px)}
  .projects-section .section-title{font-size:clamp(32px,8.3vw,44px)}
  .skill-group{grid-template-columns:1fr;gap:12px}
  .to-top{right:14px;bottom:86px;width:42px;height:42px}
}
@media(max-width:480px){
  .nav-shell{min-height:62px}
  .wordmark{width:39px;height:39px}
  .skill-pill{min-height:37px;padding:7px 10px;white-space:normal}
  .skill-pill img{height:18px;width:18px}
  .experience-rail-link strong{font-size:12px}
  .project-copy h3{font-size:clamp(36px,10vw,47px)}
  .to-top{right:14px;bottom:83px}
}
@media(hover:none){
  .skill-pill:hover,.project-visual:hover,.experience-item:hover,.about-photo-frame:hover img{transform:none!important}
  .to-top:hover{transform:none}
}
@media(prefers-reduced-motion:reduce){
  .nav-slide,.to-top,.fa-arrow-icon,.experience-item,.experience-rail-link,.about-photo-frame img{transition:none!important}
  .motion-enabled .reveal-up:not(.is-visible){opacity:1!important;transform:none!important}
}

/* Final accessibility and animation polish from real browser screenshots. */
.menu-toggle[aria-expanded="true"]{background:var(--ink)!important;border-color:var(--ink)!important;color:#fff!important;box-shadow:3px 3px 0 var(--yellow)!important}
.menu-toggle[aria-expanded="true"] .menu-label{color:#fff!important}
.menu-toggle[aria-expanded="true"] .menu-lines i{background:#fff!important}
.nav-mobile-cta{gap:11px}
.nav-mobile-cta .fa-arrow-icon{margin-left:7px}
body.menu-open .chat-widget,body.menu-open .to-top{opacity:0!important;visibility:hidden!important;pointer-events:none!important}
body:has(.cv-dialog[open]) .to-top{opacity:0!important;visibility:hidden!important;pointer-events:none!important}
/* Frame-by-frame hero entrance, measured in short readable stages. */
@media(prefers-reduced-motion:no-preference){
  .hero .hero-kicker{animation:hero-stage .65s .06s var(--ref-ease) both}
  .hero .hero-name{animation:hero-stage 1s .16s var(--ref-ease) both}
  .hero .hero-intro h2{animation:hero-stage .95s .3s var(--ref-ease) both}
  .hero .hero-intro p{animation:hero-stage .9s .44s var(--ref-ease) both}
  .hero .hero-buttons{animation:hero-stage .85s .56s var(--ref-ease) both}
}
@keyframes hero-stage{from{opacity:0;transform:translate3d(0,20px,0)}to{opacity:1;transform:none}}
@media(max-width:900px){
  .nav-links.open .nav-mobile-cta .fa-arrow-icon{max-width:16px!important}
}

/* Last visual pass: remove duplicate section label and mirror reference's focused tool hover. */
.project-heading .section-title{margin-top:0}
.skill-pill:hover{border-color:#bb9b19;box-shadow:inset 0 0 0 1px rgba(250,204,0,.35),2px 3px 0 rgba(22,22,22,.1)}
@media(prefers-reduced-motion:reduce){.experience-rail-link,.skill-pill{transition:none!important}}


/* === Navigation, readable chronology and persistent assistant, 2026-11-07 === */
:root{--fixed-header-height:68px;--section-rule:#bdb9af}
/* Visible section divisions match the editorial reference without adding extra UI. */
main > section + section{border-top:2px solid var(--section-rule)!important}
.section-label .rule,.skill-groups,.skill-group,.capabilities,.capability-list p{border-color:var(--section-rule)}
.section-label .rule{height:2px}
.site-header{border-bottom:2px solid var(--section-rule)}
/* Cards contain only details supported by the user's current CV. */
.experience-item{min-height:285px;padding:clamp(25px,3.5vw,42px);overflow-wrap:anywhere}
.experience-highlights{padding:0;margin:20px 0 0;list-style:none;display:grid;gap:13px}
.experience-highlights li{position:relative;padding-left:20px;font-size:clamp(14px,1.1vw,16px);line-height:1.65;color:#3d3b37}
.experience-highlights li::before{content:'';position:absolute;top:.65em;left:1px;width:7px;height:7px;border-radius:50%;background:var(--yellow);border:1px solid var(--ink)}
.experience-item.is-current .experience-highlights li::before{background:var(--yellow)}
/* Connor floats over all sections, but below dialogs and an expanded menu. */
.chat-widget{position:fixed!important;right:max(16px,env(safe-area-inset-right))!important;bottom:max(17px,env(safe-area-inset-bottom))!important;z-index:1200!important;isolation:isolate}
.chat-window{width:min(395px,calc(100vw - 32px));height:min(525px,calc(100dvh - 120px));max-height:calc(100dvh - 105px)}
/* Smaller pen typography in the message editor and user's bubble. */
.chat-input-row input{font-family:'Patrick Hand','Segoe Print',cursive;font-size:19px;letter-spacing:.012em;line-height:1.28;min-height:45px}
.chat-input-row input::placeholder{font-family:var(--font);font-size:12px;letter-spacing:0}
.chat-msg.user{font-family:'Patrick Hand','Segoe Print',cursive;font-size:17px;line-height:1.45;letter-spacing:.006em}
.chat-header{position:relative;isolation:isolate}
.chat-header::after{content:'';position:absolute;left:0;right:0;bottom:-2px;height:3px;background:linear-gradient(90deg,#161616 0%,#fff 45%,#161616 100%);background-size:200% 100%;opacity:.22;pointer-events:none}
.chat-window[aria-busy='true'] .chat-header::after{opacity:1;animation:connor-live-progress 1.6s linear infinite}
@keyframes connor-live-progress{to{background-position:-200% 0}}
.chat-input-row{position:relative}
.chat-input-row::after{content:'';position:absolute;bottom:0;left:12px;width:0;height:2px;background:#161616;transition:width .4s cubic-bezier(.22,1,.36,1);pointer-events:none}
.chat-input-row:focus-within::after{width:calc(100% - 76px)}
/* Compact screens: fixed header + overlay always reachable from any scroll position. */
@media(max-width:900px){
  body{padding-top:var(--fixed-header-height)!important}
  .site-header,.site-header.is-scrolled{position:fixed!important;top:0!important;left:0!important;right:0!important;width:100%;z-index:2000!important;backdrop-filter:none!important;-webkit-backdrop-filter:none!important;transform:none!important;filter:none!important}
  .nav-shell{position:relative!important;isolation:auto!important;z-index:auto!important}
  .menu-toggle{position:relative;z-index:2100!important;flex-shrink:0;touch-action:manipulation}
  .menu-toggle .menu-lines{position:relative!important;display:block!important;width:25px!important;height:22px!important;background:none!important;transform:none!important}
  .menu-toggle .menu-lines i{background:currentColor!important;left:1px!important;right:auto!important;height:2.5px!important;top:6px;transform:none!important;transition:top .32s cubic-bezier(.16,1,.3,1),transform .4s cubic-bezier(.16,1,.3,1),width .3s!important}
  .menu-toggle .menu-lines i:last-child{left:1px!important;right:auto!important;width:15px!important;top:14px}
  .menu-toggle.is-open .menu-lines i:first-child{top:10px!important;transform:rotate(45deg)!important;width:23px!important}
  .menu-toggle.is-open .menu-lines i:last-child{top:10px!important;transform:rotate(-45deg)!important;width:23px!important}
  .menu-toggle.is-open .menu-label{color:#fff!important}
  /* The overlay is fixed to the viewport, not absolutely positioned in a scrolling nav. */
  #siteMenu.nav-links{position:fixed!important;inset:var(--fixed-header-height) 0 0!important;top:var(--fixed-header-height)!important;left:0!important;right:0!important;bottom:0!important;width:100vw!important;height:calc(100dvh - var(--fixed-header-height))!important;min-height:0!important;max-height:none!important;margin:0!important;padding:clamp(24px,5vw,45px) max(var(--gutter),env(safe-area-inset-left)) calc(35px + env(safe-area-inset-bottom))!important;overflow-x:hidden!important;overflow-y:auto!important;overscroll-behavior:contain!important;-webkit-overflow-scrolling:touch;touch-action:pan-y;z-index:2050!important;border-top:2px solid var(--ink);box-shadow:none!important;transform:translate3d(0,-12px,0);opacity:0;visibility:hidden;pointer-events:none;transition:opacity .28s ease,transform .38s cubic-bezier(.16,1,.3,1),visibility .38s!important}
  #siteMenu.nav-links.open{visibility:visible!important;opacity:1!important;pointer-events:auto!important;transform:translate3d(0,0,0)!important}
  #siteMenu.nav-links:not(.open) *{pointer-events:none!important}
  #siteMenu.nav-links{justify-content:flex-start!important}
  #siteMenu.nav-links > a:not(.nav-mobile-cta){flex-shrink:0!important;justify-content:flex-start!important;text-align:left;gap:clamp(12px,4vw,22px)}
  #siteMenu.nav-links > a:not(.nav-mobile-cta)::before{display:inline-block!important;flex:0 0 28px!important;margin:0!important;font-size:12px!important;line-height:1.4;align-self:center;order:-1}

  html.nav-is-open{overflow:hidden!important;overscroll-behavior:none}
  body.menu-open{overflow:hidden!important;touch-action:auto!important}
  body.menu-open .chat-widget{visibility:hidden!important;pointer-events:none!important;opacity:0!important}
  .nav-slide{display:none!important}
  .experience-item{min-height:0}
}
@media(max-width:480px){
  .chat-widget{bottom:max(12px,env(safe-area-inset-bottom))!important;right:max(12px,env(safe-area-inset-right))!important}
  .chat-window{width:min(395px,calc(100vw - 24px));height:min(520px,calc(100dvh - 94px));min-height:0}
  .chat-input-row input{font-size:18px}
  .experience-item{padding:25px 19px}
}
@media(max-height:510px){
  .chat-window{height:calc(100dvh - 92px);min-height:0}
  #siteMenu.nav-links{padding-top:12px!important}
  #siteMenu.nav-links>a:not(.nav-mobile-cta){min-height:46px!important;font-size:clamp(20px,4vw,28px)!important}
}
@media(prefers-reduced-motion:reduce){
  .chat-header::after{animation:none!important}
  .menu-toggle .menu-lines i,#siteMenu.nav-links{transition:none!important}
  .chat-input-row::after{transition:none!important}
}


/* v7: fixed, always-reachable navigation and persistent Connor. */
:root { --fixed-header-height: 74px; }
html { scroll-padding-top: calc(var(--fixed-header-height) + 18px); }
body { padding-top: var(--fixed-header-height) !important; }
.site-header, .site-header.is-scrolled {
  position: fixed !important;
  inset: 0 0 auto !important;
  width: 100% !important;
  z-index: 2000 !important;
  transform: none !important;
  backface-visibility: visible;
}
/* Keep the assistant viewport-anchored regardless of what section is scrolling. */
body > .chat-widget {
  position: fixed !important;
  inset: auto max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) auto !important;
  z-index: 2100 !important;
  transform: none !important;
  opacity: 1;
  visibility: visible;
}
body.menu-open > .chat-widget { opacity: 0 !important; visibility: hidden !important; pointer-events: none !important; }
.chat-toggle { min-height: 50px; padding: 5px 16px 5px 8px; }
/* Clean composer: one outline on the complete input group, no nested focus boxes. */
.chat-input-row {
  display: grid !important;
  grid-template-columns: minmax(0,1fr) 46px;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 12px 13px 9px;
  border-top: 1px solid var(--line);
  background: #fff;
  position: relative;
}
.chat-input-row::after { content: none !important; }
.chat-input-row input,
.chat-input-row input:focus,
.chat-input-row input:focus-visible {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 46px;
  height: 46px;
  padding: 0 14px;
  margin: 0;
  background: #f7f6f0;
  color: var(--ink);
  border: 1.5px solid #a7a399;
  border-radius: 8px;
  box-shadow: none !important;
  outline: 0 !important;
  font-family: 'Patrick Hand','Segoe Print',cursive;
  font-size: 16px !important;
  font-weight: 400;
  line-height: 1.3;
  letter-spacing: .005em;
  transition: border-color .25s ease,background .25s ease;
  -webkit-appearance: none;
  appearance: none;
}
.chat-input-row input:focus { border-color: #161616; background: #fffdf5; }
.chat-input-row input::placeholder { font: 400 12px/1.3 var(--font); color: #77736c; opacity: 1; }
.chat-input-row button {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  min-width: 46px;
  padding: 0;
  border: 1.5px solid var(--ink);
  border-radius: 8px;
  background: var(--yellow);
  box-shadow: none;
  transition: background .25s ease, transform .25s ease;
}
.chat-input-row button:not(:disabled):hover { background: #ffdb38; transform: translateX(2px); }
.chat-input-row button:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.chat-input-row button .fa-arrow-icon { width: 17px !important; height: 17px !important; min-width: 17px !important; max-width: 17px !important; max-height: 17px !important; }
.chat-disclaimer { margin: 0; padding: 0 16px 13px; line-height: 1.5; }
.chat-window { max-height: min(600px, calc(100dvh - 100px)); }
@media(max-width:900px) {
  .site-header, .site-header.is-scrolled { z-index: 2000 !important; }
  body > .chat-widget { right: max(12px,env(safe-area-inset-right)) !important; bottom: max(12px,env(safe-area-inset-bottom)) !important; z-index: 2100 !important; }
  body.menu-open > .chat-widget { opacity: 0 !important; visibility: hidden !important; }
}
@media(max-width:480px) {
  .chat-window { width: calc(100vw - 24px); max-height: calc(100dvh - 89px); height: min(520px,calc(100dvh - 89px)); }
  .chat-input-row { padding: 10px 11px 8px; grid-template-columns: minmax(0,1fr) 44px; }
  .chat-input-row input, .chat-input-row input:focus { font-size: 15px !important; height: 44px; min-height: 44px; }
  .chat-input-row button { width: 44px; height: 44px; min-width: 44px; }
  .chat-disclaimer { font-size: 9px; }
}
@media(max-height:420px) { .chat-window { height: calc(100dvh - 72px); max-height: calc(100dvh - 72px); } .chat-header { padding: 8px 13px; } }
@media(prefers-reduced-motion:reduce) { .chat-input-row input, .chat-input-row button { transition: none !important; } }
/* Show the composer immediately during open, while allowing the panel to animate out. */
.chat-window.is-open { visibility:visible!important; transition:transform .45s var(--motion-ease), opacity .3s ease, visibility 0s linear 0s!important; }
.chat-window:not(.is-open) { transition:transform .45s var(--motion-ease), opacity .3s ease, visibility 0s linear .45s!important; }

/* Moving graph-paper background: slightly stronger lines, drifting toward top-left. */
.grid-paper {
  background-image:
    radial-gradient(circle at 23% 5%,rgba(250,204,0,.13),transparent 27%),
    linear-gradient(90deg,rgba(22,22,22,.105) 1px,transparent 1px),
    linear-gradient(0deg,rgba(22,22,22,.105) 1px,transparent 1px);
  animation-name: blueprint-drift-up-left;
}
@keyframes blueprint-drift-up-left {
  from { background-position: 0 0,0 0,0 0; }
  to { background-position: 0 0,-128px -128px,-128px -128px; }
}
@media (max-width:720px) {
  .grid-paper { animation-name: blueprint-drift-up-left-small; }
  @keyframes blueprint-drift-up-left-small {
    from { background-position: 0 0,0 0,0 0; }
    to { background-position: 0 0,-108px -108px,-108px -108px; }
  }
}
@media (prefers-reduced-motion:reduce) {
  .grid-paper { animation:none!important; }
}


/* v8: viewport anchored header and assistant; keep these rules LAST. */
html,body{transform:none!important;filter:none!important;perspective:none!important;contain:none!important;}
body{animation:none!important;will-change:auto!important;}
:root{--fixed-header-height:74px;}
@media(max-width:480px){:root{--fixed-header-height:62px;}}
html{scroll-padding-top:calc(var(--fixed-header-height) + 18px)!important;}
body{padding-top:var(--fixed-header-height)!important;}
body>.site-header,body>.site-header.is-scrolled{
 position:fixed!important;top:0!important;left:0!important;right:0!important;bottom:auto!important;
 width:100%!important;max-width:none!important;margin:0!important;
 z-index:3000!important;transform:none!important;filter:none!important;
 opacity:1!important;visibility:visible!important;animation:none!important;
 background:rgba(247,246,240,.98)!important;
}
body>.chat-widget{
 position:fixed!important;top:auto!important;left:auto!important;
 right:max(16px,env(safe-area-inset-right))!important;
 bottom:max(16px,env(safe-area-inset-bottom))!important;
 z-index:2500!important;transform:none!important;filter:none!important;
 animation:none!important;will-change:auto!important;
}
body.menu-open>.chat-widget{opacity:0!important;visibility:hidden!important;pointer-events:none!important;}
@media(max-width:900px){
 body>.site-header{z-index:3000!important;}
 body>.chat-widget{right:max(12px,env(safe-area-inset-right))!important;bottom:max(12px,env(safe-area-inset-bottom))!important;}
 #siteMenu.nav-links{z-index:3010!important;}
 .menu-toggle{z-index:3020!important;}
}
@media(prefers-reduced-motion:reduce){body>.site-header,body>.chat-widget{transition:none!important;}}

/* Mobile menu: hide the two strokes while open; never morph into an X. */
@media (max-width: 900px) {
  .menu-toggle .menu-lines i,
  .menu-toggle .menu-lines i:first-child,
  .menu-toggle .menu-lines i:last-child,
  .menu-toggle.is-open .menu-lines i,
  .menu-toggle[aria-expanded="true"] .menu-lines i,
  .menu-toggle.is-open .menu-lines i:first-child,
  .menu-toggle.is-open .menu-lines i:last-child,
  .menu-toggle[aria-expanded="true"] .menu-lines i:first-child,
  .menu-toggle[aria-expanded="true"] .menu-lines i:last-child {
    transform: none !important;
    rotate: 0deg !important;
  }
  .menu-toggle .menu-lines i:first-child { top: 6px !important; width: 23px !important; }
  .menu-toggle .menu-lines i:last-child { top: 14px !important; width: 15px !important; }
  .menu-toggle:is(.is-open, [aria-expanded="true"]) .menu-lines i {
    opacity: 0 !important;
    visibility: hidden !important;
  }
  .menu-toggle:not(.is-open):not([aria-expanded="true"]) .menu-lines i {
    opacity: 1 !important;
    visibility: visible !important;
  }
  .menu-toggle .menu-lines i {
    transition: opacity .18s ease, visibility .18s ease !important;
  }
}
@media (prefers-reduced-motion: reduce) {
  .menu-toggle .menu-lines i { transition: none !important; }
}
