@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500&display=swap");

:root {
  --background: #f5f7fa;
  --surface: #ffffff;
  --surface-muted: #eef2f6;
  --text: #172033;
  --muted: #637083;
  --subtle: #8d98a8;
  --line: #dce2e9;
  --line-strong: #c9d2dd;
  --blue: #2156a5;
  --blue-dark: #17427f;
  --blue-soft: #eaf1fb;
  --green: #23845d;
  --page: min(1120px, calc(100vw - 64px));
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; background: var(--background); }
body { margin: 0; overflow-x: hidden; background: var(--background); color: var(--text); font-family: var(--sans); line-height: 1.6; }
body.menu-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }
::selection { background: #cfe0f7; color: var(--text); }

.skip-link { position: fixed; top: -80px; left: 16px; z-index: 100; padding: 10px 16px; background: var(--blue); color: white; }
.skip-link:focus { top: 16px; }
.site-header { position: sticky; z-index: 50; top: 0; border-bottom: 1px solid transparent; background: rgba(245, 247, 250, .9); backdrop-filter: blur(16px); transition: border-color .2s ease, box-shadow .2s ease; }
.site-header.is-scrolled { border-color: var(--line); box-shadow: 0 4px 18px rgba(20, 32, 51, .04); }
.header-inner { width: var(--page); height: 72px; margin: 0 auto; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 12px; justify-self: start; }
.brand-mark { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 8px; background: var(--text); color: white; font-size: 11px; font-weight: 700; letter-spacing: -.04em; }
.brand-name { font-size: 13px; font-weight: 600; }
.desktop-nav { display: flex; align-items: center; gap: 28px; }
.desktop-nav a { color: var(--muted); font-size: 12px; font-weight: 500; transition: color .2s ease; }
.desktop-nav a:hover { color: var(--text); }
.header-actions { justify-self: end; display: flex; align-items: center; gap: 10px; }
.print-button { display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: 7px; background: transparent; color: var(--muted); cursor: pointer; font-size: 11px; font-weight: 500; }
.print-button:hover { border-color: var(--text); color: var(--text); }
.print-button svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.contact-button { display: grid; place-items: center; height: 38px; padding: 0 15px; border-radius: 7px; background: var(--blue); color: white; font-size: 11px; font-weight: 600; transition: background .2s ease; }
.contact-button:hover { background: var(--blue-dark); }
.menu-button { display: none; justify-self: end; width: 40px; height: 40px; padding: 10px; border: 0; background: transparent; cursor: pointer; }
.menu-button span { display: block; width: 20px; height: 1px; margin: 5px 0; background: var(--text); transition: transform .2s ease; }
.menu-button[aria-expanded="true"] span:first-child { transform: translateY(3px) rotate(45deg); }
.menu-button[aria-expanded="true"] span:last-child { transform: translateY(-3px) rotate(-45deg); }
.mobile-menu { display: none; }

.page-section { width: var(--page); margin-inline: auto; scroll-margin-top: 90px; }
.hero { min-height: 620px; padding: 110px 0 92px; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(340px, .75fr); gap: clamp(60px, 10vw, 130px); align-items: center; }
.overline { margin: 0 0 15px; color: var(--blue); font: 500 10px var(--mono); letter-spacing: .1em; text-transform: uppercase; }
.hero h1 { max-width: 760px; margin: 0; font-size: clamp(48px, 6vw, 76px); font-weight: 600; line-height: 1.07; letter-spacing: -.047em; }
.role { margin: 18px 0 0; color: var(--blue); font-size: 19px; font-weight: 600; }
.summary { max-width: 720px; margin: 29px 0 0; color: var(--muted); font-size: 15px; line-height: 1.78; }
.hero-actions { display: flex; gap: 10px; margin-top: 36px; }
.primary-button, .secondary-button { display: inline-grid; place-items: center; min-height: 44px; padding: 0 18px; border-radius: 7px; font-size: 12px; font-weight: 600; }
.primary-button { background: var(--blue); color: white; }.primary-button:hover { background: var(--blue-dark); }
.secondary-button { border: 1px solid var(--line-strong); background: white; }.secondary-button:hover { border-color: var(--text); }
.profile-card { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: 0 12px 35px rgba(24, 42, 68, .055); }
.profile-card-header { min-height: 54px; padding: 0 20px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 10px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.status { color: var(--green); font-size: 9px; }.status i { display: inline-block; width: 6px; height: 6px; margin-right: 5px; border-radius: 50%; background: var(--green); }
.profile-card dl { margin: 0; padding: 4px 20px; }.profile-card dl div { padding: 17px 0; border-bottom: 1px solid var(--line); }.profile-card dl div:last-child { border-bottom: 0; }
.profile-card dt { color: var(--subtle); font-size: 10px; }.profile-card dd { margin: 4px 0 0; font-size: 13px; font-weight: 600; }
.stack-strip { border-block: 1px solid var(--line); background: var(--surface); }
.stack-strip-inner { width: var(--page); min-height: 62px; margin: 0 auto; display: flex; justify-content: space-between; align-items: center; gap: 25px; overflow: hidden; }
.stack-strip span { color: var(--muted); font: 500 10px var(--mono); text-transform: uppercase; white-space: nowrap; }

.skills, .experience, .projects, .development, .education, .contact { padding: 105px 0; }
.section-heading { display: grid; grid-template-columns: 80px 1fr; margin-bottom: 48px; }
.section-number { margin: 4px 0 0; color: var(--subtle); font: 10px var(--mono); }
.section-heading .overline { margin-bottom: 10px; }
.section-heading h2, .development h2, .contact h2 { margin: 0; font-size: clamp(36px, 4.5vw, 52px); font-weight: 600; line-height: 1.12; letter-spacing: -.04em; }

.skills-grid { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--surface); }
.skill-group { min-height: 230px; padding: 26px; border-right: 1px solid var(--line); }.skill-group:last-child { border-right: 0; }
.skill-icon { width: 42px; height: 34px; display: grid; place-items: center; border-radius: 6px; background: var(--blue-soft); color: var(--blue); font: 500 10px var(--mono); }
.skill-group h3 { margin: 51px 0 9px; font-size: 16px; }.skill-group p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.7; }

.experience { border-top: 1px solid var(--line); }
.experience-list { border-top: 1px solid var(--line-strong); }
.job { display: grid; grid-template-columns: 230px 1fr; gap: 55px; padding: 50px 0; border-bottom: 1px solid var(--line-strong); }
.job-aside p { margin: 0; }.job-period { color: var(--muted); font: 10px/1.6 var(--mono); }.job-location { margin-top: 25px !important; font-size: 15px; font-weight: 700; }.job-project { margin-top: 3px !important; color: var(--muted); font-size: 12px; }
.job-heading { display: flex; justify-content: space-between; align-items: start; gap: 20px; }.job-heading h3 { margin: 0; font-size: 27px; font-weight: 600; letter-spacing: -.025em; }.job-heading p { margin: 5px 0 0; color: var(--blue); font-size: 11px; font-weight: 600; }
.current-badge { padding: 5px 8px; border-radius: 5px; background: #e8f5ef; color: var(--green); font: 500 8px var(--mono); text-transform: uppercase; white-space: nowrap; }
.job-intro { max-width: 760px; margin: 23px 0 0; color: var(--muted); font-size: 13px; line-height: 1.75; }
.achievement-list { max-width: 820px; margin: 27px 0 0; padding: 0; list-style: none; }.achievement-list li { position: relative; padding-left: 22px; color: #354156; font-size: 13px; line-height: 1.68; }.achievement-list li + li { margin-top: 12px; }.achievement-list li::before { content: ""; position: absolute; left: 2px; top: .75em; width: 5px; height: 5px; border-radius: 50%; background: var(--blue); }
.compact-list { margin-top: 23px; }.more-details { margin-top: 25px; }.more-details summary { width: fit-content; color: var(--blue); cursor: pointer; font-size: 11px; font-weight: 600; }.more-details ul { margin: 18px 0 0; padding-left: 20px; color: var(--muted); font-size: 12px; }.more-details li + li { margin-top: 7px; }
.tag-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 28px; }.tag-list span { padding: 5px 8px; border: 1px solid var(--line); border-radius: 5px; background: var(--surface); color: var(--muted); font: 9px var(--mono); }

.projects { border-top: 1px solid var(--line); }
.project-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.project-card { min-height: 370px; padding: 28px; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); transition: border-color .2s ease, box-shadow .2s ease; }
.project-card:hover { border-color: var(--line-strong); box-shadow: 0 10px 30px rgba(26, 43, 67, .045); }
.project-type { margin: 0; color: var(--blue); font: 500 9px var(--mono); text-transform: uppercase; letter-spacing: .08em; }.project-card h3 { margin: 14px 0 12px; font-size: 21px; }.project-card > p:not(.project-type) { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.7; }.project-card ul { margin: 25px 0 0; padding-left: 18px; color: #465268; font-size: 11px; }.project-card li + li { margin-top: 8px; }.project-card .tag-list { margin-top: auto; padding-top: 25px; }

.development { border-top: 1px solid var(--line); }
.development-card { display: grid; grid-template-columns: 1.15fr .85fr; gap: 75px; padding: 52px; border: 1px solid #ccd9e9; border-radius: 12px; background: #edf3fa; }
.development h2 { font-size: clamp(30px, 3.5vw, 42px); }.development-copy > p:last-child { max-width: 620px; margin: 22px 0 0; color: var(--muted); font-size: 13px; line-height: 1.75; }
.roadmap { align-self: center; border: 1px solid #ccd8e7; border-radius: 9px; background: rgba(255,255,255,.72); }.roadmap-item { min-height: 52px; display: grid; grid-template-columns: 10px 1fr auto; align-items: center; gap: 10px; padding: 0 16px; border-bottom: 1px solid #d6e0ec; font-size: 11px; }.roadmap-item:last-child { border: 0; }.roadmap-item i { width: 7px; height: 7px; border: 1px solid var(--subtle); border-radius: 50%; }.roadmap-item strong { color: var(--subtle); font: 500 8px var(--mono); text-transform: uppercase; }.roadmap-item.complete i { border-color: var(--green); background: var(--green); }.roadmap-item.complete strong { color: var(--green); }

.education { border-top: 1px solid var(--line); }
.education-grid { display: grid; grid-template-columns: 1.25fr .75fr .9fr; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--surface); }
.education-card, .language-card, .practice-card { min-height: 280px; padding: 30px; border-right: 1px solid var(--line); }.education-grid article:last-child { border-right: 0; }
.education-year { margin: 0; color: var(--blue); font: 500 10px var(--mono); }.education-card h3, .language-card h3, .practice-card h3 { margin: 37px 0 0; font-size: 20px; }.education-card > p:not(.education-year) { margin: 4px 0 23px; color: var(--muted); font-size: 12px; }.education-card strong { display: block; font-size: 13px; }.education-card span { display: block; margin-top: 6px; color: var(--muted); font-size: 11px; }
.language-card h3, .practice-card h3 { margin-top: 0; }.language-card dl { margin: 34px 0 0; }.language-card dl div { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 11px; }.language-card dd { margin: 0; color: var(--muted); }.language-card p, .practice-card p { margin: 21px 0 0; color: var(--muted); font-size: 11px; line-height: 1.7; }.leetcode-identity { margin-top: 22px; padding: 12px; display: flex; justify-content: space-between; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface-muted); }.leetcode-identity span { color: var(--subtle); font: 9px var(--mono); text-transform: uppercase; }.leetcode-identity strong { overflow-wrap: anywhere; color: var(--text); font: 500 10px var(--mono); }.practice-card a { display: inline-block; margin-top: 18px; color: var(--blue); font-size: 11px; font-weight: 600; }.practice-card > span { display: block; margin-top: 32px; color: var(--subtle); font: 9px var(--mono); }

.contact { display: grid; grid-template-columns: 1fr 360px; gap: 80px; align-items: center; border-top: 1px solid var(--line); }.contact h2 { font-size: clamp(34px, 4.2vw, 50px); }.contact-panel { padding: 28px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }.contact-panel > p { margin: 0; color: var(--muted); font-size: 11px; }.contact-links { display: flex; flex-direction: column; gap: 8px; margin-top: 20px; }.contact-links a { display: flex; justify-content: space-between; align-items: center; padding: 11px 12px; border-radius: 6px; background: var(--surface-muted); color: var(--blue); font-size: 11px; font-weight: 600; }.contacts-note { margin: 0; color: var(--subtle); font: 9px/1.6 var(--mono); }
.site-footer { border-top: 1px solid var(--line); background: var(--surface); }.footer-inner { width: var(--page); min-height: 100px; margin: 0 auto; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; color: var(--muted); font-size: 10px; }.footer-inner p:last-of-type { justify-self: center; }.footer-inner a { justify-self: end; color: var(--blue); font-weight: 600; }

@media (max-width: 1000px) {
  :root { --page: min(100% - 48px, 850px); }
  .header-inner { grid-template-columns: 1fr auto; }.desktop-nav, .header-actions { display: none; }.menu-button { display: block; }
  .mobile-menu { position: fixed; z-index: 40; inset: 72px 0 0; display: grid; place-items: start center; padding-top: 80px; background: rgba(245,247,250,.98); opacity: 0; visibility: hidden; transition: opacity .2s ease, visibility .2s ease; }.mobile-menu[aria-hidden="false"] { opacity: 1; visibility: visible; }.mobile-menu nav { display: flex; flex-direction: column; align-items: center; gap: 24px; }.mobile-menu a { font-size: 23px; font-weight: 600; }.mobile-menu button { margin-top: 12px; padding: 10px 15px; border: 1px solid var(--line-strong); border-radius: 6px; background: white; color: var(--muted); }
  .hero { grid-template-columns: 1fr; padding-top: 90px; }.profile-card { width: min(100%, 560px); }
  .skills-grid { grid-template-columns: repeat(2, 1fr); }.skill-group:nth-child(2) { border-right: 0; }.skill-group:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .project-grid { grid-template-columns: 1fr; }.project-card { min-height: 300px; }
  .development-card { grid-template-columns: 1fr; gap: 40px; }
  .education-grid { grid-template-columns: 1fr 1fr; }.education-card { grid-column: span 2; border-right: 0; border-bottom: 1px solid var(--line); }.language-card { border-right: 1px solid var(--line); }
  .contact { grid-template-columns: 1fr; }.contact-panel { width: min(100%, 520px); }
}

@media (max-width: 680px) {
  :root { --page: calc(100% - 32px); }
  .header-inner { height: 64px; }.brand-name { font-size: 12px; }.mobile-menu { inset: 64px 0 0; }
  .hero { min-height: 0; padding: 72px 0; gap: 50px; }.hero h1 { font-size: 42px; line-height: 1.08; overflow-wrap: normal; word-break: normal; }.role { font-size: 16px; }.summary { font-size: 14px; }.hero-actions { flex-direction: column; }.primary-button, .secondary-button { width: 100%; }
  .profile-card-header { align-items: flex-start; flex-direction: column; justify-content: center; gap: 4px; }
  .stack-strip-inner { justify-content: flex-start; overflow-x: auto; scrollbar-width: none; }.stack-strip-inner::-webkit-scrollbar { display: none; }
  .skills, .experience, .projects, .development, .education, .contact { padding: 75px 0; }.section-heading { grid-template-columns: 45px 1fr; margin-bottom: 36px; }.section-heading h2, .contact h2 { font-size: 38px; overflow-wrap: anywhere; }
  .skills-grid { grid-template-columns: 1fr; }.skill-group { min-height: 190px; border-right: 0; border-bottom: 1px solid var(--line); }.skill-group:nth-child(2) { border-right: 0; }.skill-group:last-child { border-bottom: 0; }.skill-group h3 { margin-top: 35px; }
  .job { grid-template-columns: 1fr; gap: 27px; padding: 40px 0; }.job-location { margin-top: 13px !important; }.job-heading { flex-direction: column; }.job-heading h3 { font-size: 24px; }.current-badge { order: -1; }.achievement-list li { font-size: 12px; }
  .project-card { min-height: 330px; padding: 24px; }
  .development { width: 100%; }.development-card { padding: 40px 16px; border-radius: 0; border-inline: 0; }.development h2 { font-size: 32px; }.roadmap-item { grid-template-columns: 10px 1fr; padding-block: 12px; }.roadmap-item strong { grid-column: 2; }
  .education-grid { grid-template-columns: 1fr; }.education-card { grid-column: auto; }.education-card, .language-card, .practice-card { min-height: 250px; border-right: 0; border-bottom: 1px solid var(--line); }.practice-card { border-bottom: 0; }
  .contact { gap: 36px; }.contact h2 br { display: none; }
  .footer-inner { min-height: 150px; padding: 25px 0; grid-template-columns: 1fr; justify-items: start; gap: 12px; }.footer-inner p { margin: 0; }.footer-inner p:last-of-type, .footer-inner a { justify-self: start; }
}

@media print {
  @page { size: A4; margin: 15mm; }
  :root { --page: 100%; }
  body { background: white; color: #111; font-size: 10pt; }
  .site-header, .mobile-menu, .stack-strip, .hero-actions, .development, .contact, .site-footer, .more-details { display: none !important; }
  .page-section { width: 100%; padding: 0; margin: 0; }
  .hero { min-height: 0; padding: 0 0 12mm; grid-template-columns: 1fr 70mm; gap: 10mm; border-bottom: 1px solid #ccc; }
  .hero h1 { font-size: 28pt; }.role { font-size: 12pt; }.summary { font-size: 9pt; line-height: 1.5; }.profile-card { box-shadow: none; }
  .skills, .experience, .projects, .education { padding-top: 10mm; }
  .section-heading { margin-bottom: 5mm; }.section-heading h2 { font-size: 18pt; }
  .skills-grid { break-inside: avoid; }.skill-group { min-height: 36mm; padding: 5mm; }.skill-group h3 { margin-top: 6mm; }
  .job { grid-template-columns: 42mm 1fr; gap: 7mm; padding: 7mm 0; break-inside: avoid; }.job-heading h3 { font-size: 14pt; }.achievement-list li, .job-intro { font-size: 8.5pt; }
  .project-grid { grid-template-columns: repeat(3, 1fr); }.project-card { min-height: 0; padding: 5mm; break-inside: avoid; }.project-card h3 { font-size: 12pt; }
  .education-grid { grid-template-columns: repeat(3, 1fr); break-inside: avoid; }.education-card { grid-column: auto; border-right: 1px solid var(--line); border-bottom: 0; }.education-card, .language-card, .practice-card { min-height: 45mm; padding: 5mm; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
