:root,[data-theme="light"]{
  --color-bg:#f5f4f0;--color-surface:#ffffff;--color-surface-2:#f9f8f5;
  --color-surface-offset:#eeecea;--color-border:rgba(0,0,0,0.09);
  --color-text:#1a1814;--color-text-muted:#6b6a66;--color-text-faint:#b0afab;
  --color-primary:#2563eb;--color-primary-hover:#1d4ed8;--color-accent:#f59e0b;
  --shadow-sm:0 1px 3px rgba(0,0,0,0.06);--shadow-md:0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg:0 12px 40px rgba(0,0,0,0.12);
  --radius-sm:6px;--radius-md:10px;--radius-lg:16px;--radius-xl:24px;
  --font-display:'Syne',sans-serif;--font-body:'Inter',sans-serif;
  --text-xs:clamp(.75rem,.7rem + .25vw,.875rem);
  --text-sm:clamp(.875rem,.8rem + .35vw,1rem);
  --text-base:clamp(1rem,.95rem + .25vw,1.125rem);
  --text-lg:clamp(1.125rem,1rem + .75vw,1.5rem);
  --text-xl:clamp(1.5rem,1.2rem + 1.25vw,2.25rem);
  --text-2xl:clamp(2rem,1.2rem + 2.5vw,3.5rem);
  --space-1:.25rem;--space-2:.5rem;--space-3:.75rem;--space-4:1rem;
  --space-5:1.25rem;--space-6:1.5rem;--space-8:2rem;--space-10:2.5rem;
  --space-12:3rem;--space-16:4rem;--transition:200ms cubic-bezier(.16,1,.3,1);
}
[data-theme="dark"]{
  --color-bg:#0d0d0c;--color-surface:#161614;--color-surface-2:#1c1b19;
  --color-surface-offset:#242320;--color-border:rgba(255,255,255,0.07);
  --color-text:#e8e7e4;--color-text-muted:#7a7975;--color-text-faint:#4a4946;
  --color-primary:#60a5fa;--color-primary-hover:#93c5fd;--color-accent:#fbbf24;
  --shadow-sm:0 1px 3px rgba(0,0,0,0.35);--shadow-md:0 4px 16px rgba(0,0,0,0.45);
  --shadow-lg:0 12px 40px rgba(0,0,0,0.55);
}
@media(prefers-color-scheme:dark){:root:not([data-theme]){
  --color-bg:#0d0d0c;--color-surface:#161614;--color-surface-2:#1c1b19;
  --color-surface-offset:#242320;--color-border:rgba(255,255,255,0.07);
  --color-text:#e8e7e4;--color-text-muted:#7a7975;--color-text-faint:#4a4946;
  --color-primary:#60a5fa;--color-primary-hover:#93c5fd;--color-accent:#fbbf24;
  --shadow-sm:0 1px 3px rgba(0,0,0,0.35);--shadow-md:0 4px 16px rgba(0,0,0,0.45);
  --shadow-lg:0 12px 40px rgba(0,0,0,0.55);
}}
*,*::before,*::after{box-sizing:border-box;margin:0;padding:0}
html{scroll-behavior:smooth;scroll-padding-top:72px;-webkit-font-smoothing:antialiased}
body{font-family:var(--font-body);font-size:var(--text-base);color:var(--color-text);background:var(--color-bg);min-height:100dvh;line-height:1.65}
img,picture,video,canvas,svg{display:block;max-width:100%;height:auto}
ul{list-style:none}
input,button,textarea,select{font:inherit;color:inherit}
h1,h2,h3,h4,h5,h6{text-wrap:balance;line-height:1.15}
p,li{text-wrap:pretty}
::selection{background:color-mix(in oklch,var(--color-primary) 22%,transparent);color:var(--color-text)}
:focus-visible{outline:2px solid var(--color-primary);outline-offset:3px;border-radius:var(--radius-sm)}
a,button,[role="button"],input{transition:color var(--transition),background var(--transition),border-color var(--transition),box-shadow var(--transition),transform var(--transition),opacity var(--transition)}
button{cursor:pointer;background:none;border:none}

/* NAVBAR */
.navbar{position:fixed;top:0;left:0;right:0;z-index:100;background:color-mix(in oklch,var(--color-bg) 82%,transparent);backdrop-filter:blur(20px);-webkit-backdrop-filter:blur(20px);border-bottom:1px solid var(--color-border)}
.nav-inner{max-width:1160px;margin:0 auto;padding:0 var(--space-6);height:64px;display:flex;align-items:center;gap:var(--space-6)}
.nav-logo{display:flex;align-items:center;gap:var(--space-3);text-decoration:none;color:var(--color-text);font-family:var(--font-display);font-weight:700;font-size:var(--text-sm);flex-shrink:0}
.nav-logo:hover{color:var(--color-primary)}
.nav-links{display:flex;align-items:center;gap:var(--space-1);margin-left:auto}
.nav-link{text-decoration:none;font-size:var(--text-sm);color:var(--color-text-muted);font-weight:500;padding:6px 12px;border-radius:var(--radius-sm)}
.nav-link:hover,.nav-link.active{color:var(--color-primary);background:color-mix(in oklch,var(--color-primary) 10%,transparent)}
.theme-toggle{display:flex;align-items:center;justify-content:center;width:36px;height:36px;border-radius:var(--radius-sm);color:var(--color-text-muted);border:1px solid var(--color-border);margin-left:var(--space-2)}
.theme-toggle:hover{color:var(--color-primary);border-color:color-mix(in oklch,var(--color-primary) 50%,transparent)}
.nav-toggle{display:none;align-items:center;justify-content:center;width:40px;height:40px;margin-left:auto;color:var(--color-text);border-radius:var(--radius-sm);border:1px solid var(--color-border)}

/* HERO */
.hero{min-height:100dvh;display:flex;align-items:center;padding:calc(64px + var(--space-16)) var(--space-6) var(--space-16)}
.hero-inner{max-width:1160px;margin:0 auto;width:100%;display:grid;grid-template-columns:1fr 400px;gap:var(--space-16);align-items:center}
.hero-badge{display:inline-flex;align-items:center;gap:var(--space-2);background:color-mix(in oklch,var(--color-primary) 12%,transparent);border:1px solid color-mix(in oklch,var(--color-primary) 28%,transparent);color:var(--color-primary);font-size:var(--text-xs);font-weight:600;padding:4px 14px;border-radius:9999px;letter-spacing:.06em;text-transform:uppercase;margin-bottom:var(--space-6)}
.status-dot{width:7px;height:7px;border-radius:50%;background:#22c55e;animation:pulse 2s infinite}
@keyframes pulse{0%,100%{opacity:1}50%{opacity:.4}}
.hero-name{font-family:var(--font-display);font-size:var(--text-2xl);font-weight:800;line-height:1.05;margin-bottom:var(--space-6)}
.hero-name .accent{color:var(--color-primary)}
.hero-desc{font-size:var(--text-base);color:var(--color-text-muted);margin-bottom:var(--space-8);max-width:54ch;line-height:1.75}
.hero-desc strong{color:var(--color-text);font-weight:600}
.hero-btns{display:flex;gap:var(--space-4);flex-wrap:wrap;margin-bottom:var(--space-8)}
.btn{display:inline-flex;align-items:center;gap:var(--space-2);padding:10px 22px;border-radius:var(--radius-md);font-size:var(--text-sm);font-weight:600;text-decoration:none;line-height:1}
.btn svg{width:15px;height:15px}
.btn-primary{background:var(--color-primary);color:#fff}
.btn-primary:hover{background:var(--color-primary-hover);transform:translateY(-2px);box-shadow:var(--shadow-md)}
.btn-ghost{border:1px solid var(--color-border);color:var(--color-text)}
.btn-ghost:hover{border-color:var(--color-primary);color:var(--color-primary);background:color-mix(in oklch,var(--color-primary) 7%,transparent)}
.hero-tags{display:flex;flex-wrap:wrap;gap:var(--space-2)}
.tag{background:var(--color-surface-offset);color:var(--color-text-muted);font-size:var(--text-xs);padding:4px 12px;border-radius:9999px;font-weight:500;border:1px solid var(--color-border)}

/* PHOTO */
.hero-photo{position:relative;display:flex;justify-content:center;align-items:center}
.photo-wrap{position:relative;z-index:1}
.photo-frame{border-radius:var(--radius-xl);overflow:hidden;width:340px;height:430px;box-shadow:var(--shadow-lg)}
.photo-frame img{width:100%;height:100%;object-fit:cover;object-position:center top}
.deco-border{position:absolute;width:340px;height:430px;border:2px solid var(--color-primary);border-radius:var(--radius-xl);top:14px;left:14px;z-index:0;opacity:.3}
.deco-blob{position:absolute;width:140px;height:140px;background:color-mix(in oklch,var(--color-accent) 18%,transparent);border-radius:var(--radius-xl);bottom:-16px;right:-16px;z-index:0}

/* STATS */
.stats-section{padding:var(--space-12) var(--space-6);border-top:1px solid var(--color-border);border-bottom:1px solid var(--color-border);background:var(--color-surface)}
.stats-grid{max-width:1160px;margin:0 auto;display:grid;grid-template-columns:repeat(4,1fr);gap:var(--space-4)}
.stat-card{text-align:center;padding:var(--space-8) var(--space-4)}
.stat-num{display:block;font-family:var(--font-display);font-size:var(--text-2xl);font-weight:800;color:var(--color-primary);line-height:1}
.stat-suffix{font-size:var(--text-xl);font-family:var(--font-display);font-weight:800;color:var(--color-primary)}
.stat-label{display:block;font-size:var(--text-sm);color:var(--color-text-muted);margin-top:var(--space-2)}

/* SECTIONS */
.section{padding:clamp(var(--space-12),7vw,var(--space-16)) var(--space-6)}
.bg-alt{background:var(--color-surface)}
.container{max-width:1160px;margin:0 auto;width:100%}
.section-title{font-family:var(--font-display);font-size:var(--text-xl);font-weight:800;margin-bottom:var(--space-10)}
.section-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:var(--space-10)}
.section-header .section-title{margin-bottom:0}
.see-all{display:inline-flex;align-items:center;gap:var(--space-2);font-size:var(--text-sm);color:var(--color-primary);font-weight:600;text-decoration:none}
.see-all svg{width:14px;height:14px;transition:transform var(--transition)}
.see-all:hover svg{transform:translateX(3px)}

/* RESEARCH CARDS */
.cards-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:var(--space-5)}
.research-card{background:var(--color-surface);border:1px solid var(--color-border);border-radius:var(--radius-lg);padding:var(--space-7,1.75rem) var(--space-6);box-shadow:var(--shadow-sm);transition:transform var(--transition),box-shadow var(--transition),border-color var(--transition)}
.research-card:hover{transform:translateY(-4px);box-shadow:var(--shadow-md);border-color:color-mix(in oklch,var(--color-primary) 30%,transparent)}
.card-icon{width:42px;height:42px;display:flex;align-items:center;justify-content:center;background:color-mix(in oklch,var(--color-primary) 12%,transparent);border-radius:var(--radius-md);color:var(--color-primary);margin-bottom:var(--space-4)}
.card-icon svg{width:20px;height:20px}
.research-card h3{font-family:var(--font-display);font-size:var(--text-base);font-weight:700;margin-bottom:var(--space-3)}
.research-card p{font-size:var(--text-sm);color:var(--color-text-muted);line-height:1.65}

/* PUBLICATIONS */
.pub-list{display:flex;flex-direction:column;gap:var(--space-4)}
.pub-item{background:var(--color-surface-2);border:1px solid var(--color-border);border-radius:var(--radius-lg);padding:var(--space-6);transition:border-color var(--transition),box-shadow var(--transition)}
.pub-item:hover{border-color:color-mix(in oklch,var(--color-primary) 35%,transparent);box-shadow:var(--shadow-sm)}
.pub-venue{display:flex;align-items:center;gap:var(--space-3);margin-bottom:var(--space-3)}
.badge{font-size:10px;font-weight:700;padding:3px 10px;border-radius:9999px;letter-spacing:.05em;text-transform:uppercase}
.badge-conf{background:color-mix(in oklch,var(--color-primary) 15%,transparent);color:var(--color-primary)}
.badge-journal{background:color-mix(in oklch,var(--color-accent) 18%,transparent);color:var(--color-accent)}
.pub-year{font-size:var(--text-xs);color:var(--color-text-faint);font-weight:600}
.pub-title{font-size:var(--text-base);font-weight:600;line-height:1.4;margin-bottom:var(--space-2)}
.pub-authors{font-size:var(--text-sm);color:var(--color-text-muted);margin-bottom:var(--space-1)}
.pub-meta{font-size:var(--text-xs);color:var(--color-text-faint);margin-bottom:var(--space-3)}
.pub-doi{display:inline-flex;align-items:center;gap:4px;font-size:var(--text-xs);color:var(--color-primary);font-weight:600;text-decoration:none}
.pub-doi:hover{text-decoration:underline}
.pub-doi svg{width:11px;height:11px}

/* PAGE HEADER */
.page-header{padding:calc(64px + var(--space-12)) var(--space-6) var(--space-10);border-bottom:1px solid var(--color-border)}
.page-header-inner{max-width:1160px;margin:0 auto}
.breadcrumb{display:flex;align-items:center;gap:var(--space-2);font-size:var(--text-xs);color:var(--color-text-faint);margin-bottom:var(--space-4)}
.breadcrumb a{color:var(--color-primary);text-decoration:none}
.breadcrumb svg{width:11px;height:11px}
.page-header h1{font-family:var(--font-display);font-size:var(--text-2xl);font-weight:800;margin-bottom:var(--space-4)}
.page-header p{font-size:var(--text-base);color:var(--color-text-muted);max-width:60ch;line-height:1.7}

/* RESEARCH PAGE */
.thesis-box{background:color-mix(in oklch,var(--color-primary) 6%,var(--color-surface));border:1px solid color-mix(in oklch,var(--color-primary) 20%,transparent);border-radius:var(--radius-lg);padding:var(--space-8);margin-bottom:var(--space-10)}
.thesis-box h3{font-family:var(--font-display);font-size:var(--text-lg);font-weight:700;margin-bottom:var(--space-4);color:var(--color-primary)}
.thesis-box p{color:var(--color-text-muted);line-height:1.75;margin-bottom:var(--space-4)}
.thesis-meta{display:flex;flex-wrap:wrap;gap:var(--space-3);margin-top:var(--space-4)}
.thesis-meta-item{display:flex;align-items:center;gap:var(--space-2);font-size:var(--text-sm);color:var(--color-text-muted)}
.thesis-meta-item svg{width:14px;height:14px;color:var(--color-primary)}
.skills-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:var(--space-4)}
.skill-group{background:var(--color-surface);border:1px solid var(--color-border);border-radius:var(--radius-md);padding:var(--space-5)}
.skill-group h4{font-size:var(--text-sm);font-weight:700;color:var(--color-primary);margin-bottom:var(--space-3);text-transform:uppercase;letter-spacing:.05em}
.skill-tags{display:flex;flex-wrap:wrap;gap:var(--space-2)}
.skill-tag{background:var(--color-surface-offset);color:var(--color-text-muted);font-size:var(--text-xs);padding:3px 10px;border-radius:9999px;border:1px solid var(--color-border)}

/* TEACHING PAGE */
.teaching-section{margin-bottom:var(--space-10)}
.teaching-section h2{font-family:var(--font-display);font-size:var(--text-lg);font-weight:700;margin-bottom:var(--space-6);padding-bottom:var(--space-3);border-bottom:1px solid var(--color-border)}
.teaching-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:var(--space-5)}
.teaching-card{background:var(--color-surface);border:1px solid var(--color-border);border-radius:var(--radius-lg);padding:var(--space-6);box-shadow:var(--shadow-sm)}
.teaching-card .tc-header{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:var(--space-4)}
.teaching-card .tc-role{font-family:var(--font-display);font-size:var(--text-base);font-weight:700}
.teaching-card .tc-year{font-size:var(--text-xs);color:var(--color-primary);font-weight:600;background:color-mix(in oklch,var(--color-primary) 12%,transparent);padding:3px 10px;border-radius:9999px;white-space:nowrap}
.teaching-card .tc-inst{font-size:var(--text-sm);color:var(--color-text-muted);margin-bottom:var(--space-4)}
.course-list{display:flex;flex-direction:column;gap:var(--space-2)}
.course-item{display:flex;align-items:flex-start;gap:var(--space-3);font-size:var(--text-sm);color:var(--color-text-muted);padding:var(--space-3);background:var(--color-surface-offset);border-radius:var(--radius-sm);line-height:1.5}
.course-item svg{flex-shrink:0;width:13px;height:13px;margin-top:3px;color:var(--color-primary)}

/* CONTACT PAGE */
.contact-layout{display:grid;grid-template-columns:1fr 1.2fr;gap:var(--space-12);align-items:start}
.contact-block h3{font-family:var(--font-display);font-size:var(--text-lg);font-weight:700;margin-bottom:var(--space-2)}
.contact-block .sub{color:var(--color-text-muted);font-size:var(--text-sm);margin-bottom:var(--space-8);line-height:1.6}
.contact-items{display:flex;flex-direction:column;gap:var(--space-3);margin-bottom:var(--space-8)}
.contact-item{display:flex;align-items:center;gap:var(--space-4);padding:var(--space-4) var(--space-5);background:var(--color-surface);border:1px solid var(--color-border);border-radius:var(--radius-md);text-decoration:none;color:var(--color-text)}
.contact-item:hover{border-color:color-mix(in oklch,var(--color-primary) 40%,transparent);background:color-mix(in oklch,var(--color-primary) 5%,var(--color-surface))}
.contact-item svg{width:17px;height:17px;color:var(--color-primary);flex-shrink:0}
.contact-item-text .label{font-size:var(--text-xs);color:var(--color-text-faint);font-weight:500}
.contact-item-text .value{font-size:var(--text-sm);font-weight:500}
.contact-refs h4{font-family:var(--font-display);font-size:var(--text-base);font-weight:700;margin-bottom:var(--space-4)}
.ref-item{padding:var(--space-3) var(--space-4);background:var(--color-surface);border:1px solid var(--color-border);border-radius:var(--radius-md);margin-bottom:var(--space-3)}
.ref-name{font-size:var(--text-sm);font-weight:600;margin-bottom:2px}
.ref-email{font-size:var(--text-xs);color:var(--color-primary)}
.contact-form-wrap{background:var(--color-surface);border:1px solid var(--color-border);border-radius:var(--radius-xl);padding:var(--space-8)}
.contact-form-wrap h3{font-family:var(--font-display);font-size:var(--text-lg);font-weight:700;margin-bottom:var(--space-6)}
.form-row{display:grid;grid-template-columns:1fr 1fr;gap:var(--space-4)}
.form-group{display:flex;flex-direction:column;gap:var(--space-2);margin-bottom:var(--space-5)}
.form-group label{font-size:var(--text-sm);font-weight:500}
.form-group input,.form-group textarea{background:var(--color-surface-offset);border:1px solid var(--color-border);border-radius:var(--radius-md);padding:10px 14px;font-size:var(--text-sm);outline:none}
.form-group input:focus,.form-group textarea:focus{border-color:var(--color-primary);box-shadow:0 0 0 3px color-mix(in oklch,var(--color-primary) 12%,transparent)}
.form-group textarea{min-height:130px;resize:vertical}
.btn-submit{width:100%;justify-content:center}
.form-success{display:none;padding:var(--space-4);background:color-mix(in oklch,#22c55e 12%,transparent);border:1px solid color-mix(in oklch,#22c55e 30%,transparent);border-radius:var(--radius-md);font-size:var(--text-sm);color:#16a34a;text-align:center;margin-top:var(--space-4)}

/* FOOTER */
.footer{border-top:1px solid var(--color-border);padding:var(--space-8) var(--space-6);background:var(--color-surface)}
.footer-inner{max-width:1160px;margin:0 auto;display:flex;justify-content:space-between;align-items:center;flex-wrap:wrap;gap:var(--space-4)}
.footer p{font-size:var(--text-sm);color:var(--color-text-muted)}
.footer-links{display:flex;gap:var(--space-4)}
.footer-links a{color:var(--color-text-muted);display:flex;align-items:center}
.footer-links a:hover{color:var(--color-primary)}
.footer-links svg{width:18px;height:18px}

/* ANIMATIONS */
.reveal,.reveal-right{opacity:0;transform:translateY(28px);transition:opacity .65s ease,transform .65s ease}
.reveal-right{transform:translateX(28px)}
.revealed{opacity:1!important;transform:none!important}
.stagger-1{transition-delay:.1s}.stagger-2{transition-delay:.2s}.stagger-3{transition-delay:.3s}.stagger-4{transition-delay:.4s}

/* RESPONSIVE */
@media(max-width:900px){
  .hero-inner{grid-template-columns:1fr;text-align:center}
  .hero-photo{order:-1}
  .photo-frame{width:240px;height:300px}
  .deco-border{width:240px;height:300px}
  .hero-btns,.hero-tags{justify-content:center}
  .hero-desc{margin-inline:auto}
  .stats-grid{grid-template-columns:repeat(2,1fr)}
  .contact-layout{grid-template-columns:1fr}
  .form-row{grid-template-columns:1fr}
}
@media(max-width:640px){
  .nav-links{display:none;position:fixed;top:64px;left:0;right:0;flex-direction:column;background:var(--color-surface);border-bottom:1px solid var(--color-border);padding:var(--space-4);gap:4px;box-shadow:var(--shadow-md)}
  .nav-links.open{display:flex}
  .nav-toggle{display:flex}
  .stats-grid{grid-template-columns:repeat(2,1fr)}
  .section-header{flex-direction:column;align-items:flex-start;gap:var(--space-3)}
}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation-duration:.01ms!important;transition-duration:.01ms!important}}
