:root {
  --bg: #f7fafb;
  --surface: #ffffff;
  --surface-2: #edf4f6;
  --ink: #142b33;
  --muted: #60757d;
  --line: #d7e3e7;
  --brand: #123f4d;
  --brand-2: #1b5b6b;
  --accent: #f28f32;
  --accent-soft: #fff0df;
  --shadow: 0 22px 60px rgba(18, 63, 77, .12);
  --radius-lg: 30px;
  --radius-md: 20px;
  --container: 1180px;
}

html[data-theme="dark"] {
  --bg: #0e2027;
  --surface: #132a33;
  --surface-2: #17333d;
  --ink: #f2f7f8;
  --muted: #abc0c7;
  --line: #284650;
  --brand: #7ac5d3;
  --brand-2: #a3d9e2;
  --accent: #f4a14f;
  --accent-soft: #3d2d1c;
  --shadow: 0 22px 60px rgba(0,0,0,.28);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; }
button { color: inherit; }

.skip-link {
  position: fixed;
  left: 16px;
  top: -60px;
  z-index: 200;
  background: var(--accent);
  color: #1b2b31;
  padding: 10px 14px;
  border-radius: 10px;
  transition: .2s ease;
}
.skip-link:focus { top: 14px; }

.container { width: min(var(--container), calc(100% - 40px)); margin-inline: auto; }
.section-pad { padding: 104px 0; }
.section { position: relative; }
.section-alt { background: var(--surface-2); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid color-mix(in srgb, var(--line) 72%, transparent);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(18px);
}
.nav-wrap { min-height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 12px; font-weight: 800; letter-spacing: -.02em; }
.brand-mark {
  width: 38px; height: 38px; display: grid; place-items: center;
  background: var(--brand); color: var(--bg); border-radius: 12px;
  font-size: .82rem; letter-spacing: .06em;
}
html[data-theme="dark"] .brand-mark { color: #10242b; }
.brand-text { font-size: .98rem; }
.main-nav { display: flex; align-items: center; gap: 24px; font-size: .9rem; font-weight: 700; color: var(--muted); }
.main-nav a { position: relative; transition: color .2s ease; }
.main-nav a:hover, .main-nav a.active { color: var(--ink); }
.main-nav a.active::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -10px;
  height: 2px; border-radius: 999px; background: var(--accent);
}
.theme-toggle {
  width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 12px;
  background: var(--surface); cursor: pointer; transition: transform .2s ease, border-color .2s ease;
}
.theme-toggle:hover { transform: translateY(-2px); border-color: var(--accent); }
.nav-toggle { display: none; border: 0; background: transparent; width: 42px; height: 42px; padding: 8px; }
.nav-toggle span { display: block; height: 2px; background: var(--ink); margin: 6px 0; border-radius: 99px; transition: .2s; }

.hero { overflow: hidden; position: relative; min-height: 720px; display: flex; align-items: center; }
.hero::before {
  content: ""; position: absolute; width: 560px; height: 560px; border-radius: 50%;
  right: -140px; top: 40px; background: radial-gradient(circle, color-mix(in srgb, var(--accent) 18%, transparent), transparent 68%);
  pointer-events: none;
}
.hero-grid { display: grid; grid-template-columns: 1.35fr .65fr; gap: 80px; align-items: center; }
.eyebrow { margin: 0 0 16px; color: var(--accent); text-transform: uppercase; letter-spacing: .13em; font-size: .76rem; font-weight: 900; }
.hero h1 { margin: 0; max-width: 850px; font-size: clamp(3rem, 6vw, 5.7rem); line-height: .98; letter-spacing: -.055em; }
.hero h1 span { display: block; color: var(--brand-2); }
.hero-lead { max-width: 750px; margin: 30px 0 0; font-size: 1.16rem; color: var(--muted); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 52px;
  padding: 0 20px; border-radius: 14px; font-weight: 800; transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--accent); color: #1f2b30; box-shadow: 0 12px 30px rgba(242, 143, 50, .24); }
.btn-secondary { background: var(--surface); border: 1px solid var(--line); }
.quick-info { list-style: none; padding: 0; margin: 46px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.quick-info li { padding-top: 14px; border-top: 1px solid var(--line); }
.quick-info strong, .quick-info span { display: block; }
.quick-info strong { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; }
.quick-info span { margin-top: 4px; color: var(--muted); font-size: .88rem; }

.hero-visual { display: flex; justify-content: center; }
.portrait-shell { position: relative; width: min(100%, 380px); aspect-ratio: 1; display: grid; place-items: center; }
.portrait-shell::before {
  content: ""; position: absolute; inset: 10%; border-radius: 50%;
  background: linear-gradient(145deg, var(--brand), var(--brand-2)); box-shadow: var(--shadow);
}
.portrait-shell::after {
  content: ""; position: absolute; inset: 0; border: 1px solid var(--line); border-radius: 50%;
}
.portrait-shell img { position: relative; z-index: 2; width: 66%; height: auto; filter: drop-shadow(0 18px 18px rgba(0,0,0,.18)); }
.portrait-glow { position: absolute; inset: 22%; border-radius: 50%; background: color-mix(in srgb, var(--accent) 36%, transparent); filter: blur(38px); }
.status-card {
  position: absolute; z-index: 4; right: -14px; bottom: 42px; display: flex; align-items: center; gap: 9px;
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: 999px; padding: 10px 14px;
  color: var(--muted); font-size: .78rem; font-weight: 700;
}
.status-dot { width: 9px; height: 9px; border-radius: 50%; background: #37b26c; box-shadow: 0 0 0 5px rgba(55,178,108,.13); }

.about-strip { padding: 30px 0; background: var(--brand); color: #fff; }
html[data-theme="dark"] .about-strip { color: #10242b; }
.about-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.stat { padding: 8px 0; }
.stat strong, .stat span { display: block; }
.stat strong { font-size: 1.45rem; letter-spacing: -.035em; }
.stat span { margin-top: 3px; opacity: .74; font-size: .85rem; }

.section-heading { max-width: 760px; margin-bottom: 42px; }
.section-heading h2, .volunteer-copy h2, .contact-copy h2 { margin: 0; font-size: clamp(2.15rem, 4.1vw, 4.15rem); line-height: 1.03; letter-spacing: -.045em; }
.section-heading > p:last-child { margin: 20px 0 0; color: var(--muted); font-size: 1.04rem; }

.skills-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.skill-panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 34px; box-shadow: 0 12px 35px rgba(18,63,77,.04); }
.panel-icon { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 15px; background: var(--accent-soft); color: var(--accent); font-weight: 900; }
.skill-panel h3 { margin: 22px 0 20px; font-size: 1.35rem; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 9px; }
.tag-cloud span, .project-tags span, .mini-tags span {
  display: inline-flex; align-items: center; min-height: 34px; padding: 0 12px; border-radius: 999px;
  background: var(--accent-soft); color: color-mix(in srgb, var(--accent) 74%, var(--ink)); border: 1px solid color-mix(in srgb, var(--accent) 26%, transparent);
  font-size: .82rem; font-weight: 800;
}
.tag-cloud-soft span { background: var(--surface-2); color: var(--ink); border-color: var(--line); }

.timeline { position: relative; display: grid; gap: 28px; }
.timeline::before { content: ""; position: absolute; left: 9px; top: 16px; bottom: 16px; width: 1px; background: var(--line); }
.timeline-item { position: relative; display: grid; grid-template-columns: 200px 1fr; gap: 36px; padding-left: 44px; }
.timeline-marker { position: absolute; top: 10px; left: 0; width: 19px; height: 19px; border-radius: 50%; background: var(--accent); border: 5px solid var(--surface-2); box-shadow: 0 0 0 1px var(--accent); }
.timeline-meta { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; color: var(--muted); font-size: .85rem; }
.date-pill { display: inline-flex; padding: 7px 11px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--ink); font-weight: 800; white-space: nowrap; }
.timeline-content { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 28px 30px; }
.company { margin: 0; color: var(--accent); font-size: .82rem; font-weight: 900; text-transform: uppercase; letter-spacing: .08em; }
.timeline-content h3 { margin: 5px 0 14px; font-size: 1.45rem; }
.timeline-content ul { margin: 0; padding-left: 20px; color: var(--muted); }
.timeline-content li + li { margin-top: 7px; }
.timeline-note { margin: -4px 0 14px; color: var(--muted); font-style: italic; }

.projects-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.project-card { overflow: hidden; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); transition: transform .25s ease, box-shadow .25s ease; }
.project-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.project-visual { position: relative; height: 245px; overflow: hidden; display: grid; place-items: center; }
.visual-web { background: linear-gradient(145deg, #133f4d, #247181); }
.visual-mobile { background: linear-gradient(145deg, #f4a14e, #db7a20); }
.visual-admin { background: linear-gradient(145deg, #dcebef, #f6fafb); }
.mock-window { width: 78%; height: 62%; background: #fff; border-radius: 13px; box-shadow: 0 20px 40px rgba(0,0,0,.2); padding: 14px; }
.mock-window > span { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #d5dde0; margin-right: 4px; }
.mock-lines { margin-top: 17px; height: 70%; border-radius: 8px; background: linear-gradient(#e9f1f3 0 0) 0 0/100% 16% no-repeat, linear-gradient(#e9f1f3 0 0) 0 45%/62% 10% no-repeat, linear-gradient(#f6aa62 0 0) 0 72%/42% 14% no-repeat; }
.phone-mock { width: 105px; height: 194px; border-radius: 25px; padding: 8px; background: #102e39; box-shadow: 0 20px 38px rgba(0,0,0,.2); }
.phone-screen { height: 100%; border-radius: 19px; background: #f8fbfc; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #18343d; gap: 12px; text-align: center; padding: 12px; }
.phone-screen span { font-size: .68rem; text-transform: uppercase; letter-spacing: .1em; }
.phone-screen strong { font-size: 1.15rem; color: #e8882d; }
.phone-screen small { font-size: .65rem; color: #667e86; }
.admin-mock { width: 78%; height: 64%; background: #fff; border-radius: 14px; box-shadow: 0 20px 40px rgba(26,75,89,.15); display: grid; grid-template-columns: 24% 1fr; overflow: hidden; }
.admin-side { background: #123f4d; }
.admin-main { padding: 18px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; align-content: start; }
.admin-main i { display: block; height: 32px; border-radius: 7px; background: #eef4f6; }
.admin-main b { display: block; grid-column: 1 / -1; height: 54px; border-radius: 7px; background: #fff0df; }
.project-body { padding: 28px; }
.project-kicker { margin: 0; color: var(--accent); text-transform: uppercase; letter-spacing: .1em; font-size: .72rem; font-weight: 900; }
.project-body h3 { margin: 7px 0 12px; font-size: 1.45rem; line-height: 1.12; }
.project-body > p:not(.project-kicker) { color: var(--muted); margin: 0; }
.project-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 20px; }
.project-tags span { min-height: 30px; font-size: .72rem; }

.volunteer-section { background: var(--brand); color: #fff; overflow: hidden; }
html[data-theme="dark"] .volunteer-section { color: #10242b; }
.volunteer-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 74px; align-items: center; }
.volunteer-copy .eyebrow { color: #ffc98f; }
.volunteer-copy > p:not(.eyebrow):not(.volunteer-role) { max-width: 740px; opacity: .78; }
.volunteer-role { margin: 15px 0 8px; font-weight: 800; }
.check-list { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 13px; }
.check-list li { position: relative; padding-left: 30px; opacity: .92; }
.check-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: #ffc98f; font-weight: 900; }
.volunteer-card { border-radius: var(--radius-lg); padding: 30px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.22); backdrop-filter: blur(10px); }
html[data-theme="dark"] .volunteer-card { background: rgba(255,255,255,.28); border-color: rgba(16,36,43,.16); }
.card-label { margin: 0 0 20px; text-transform: uppercase; letter-spacing: .1em; font-size: .72rem; font-weight: 900; opacity: .72; }
.impact-list { display: grid; gap: 12px; }
.impact-list > div { display: grid; grid-template-columns: 48px 1fr; gap: 14px; align-items: start; padding: 14px 0; border-top: 1px solid rgba(255,255,255,.18); }
.impact-list > div:first-child { border-top: 0; }
.impact-list span { font-size: 1.4rem; font-weight: 900; color: #ffc98f; }
.impact-list p { margin: 0; }
.impact-list strong { display: block; }
.impact-list p { font-size: .88rem; opacity: .82; }

.education-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.education-card { position: relative; min-height: 190px; padding: 28px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); }
.education-card > span { display: inline-flex; width: 38px; height: 38px; align-items: center; justify-content: center; border-radius: 12px; background: var(--accent-soft); color: var(--accent); font-size: .8rem; font-weight: 900; }
.education-card h3 { margin: 35px 0 5px; font-size: 1.25rem; }
.education-card p { margin: 0; color: var(--muted); }

.contact { position: relative; overflow: hidden; }
.contact::after { content: ""; position: absolute; right: -100px; bottom: -100px; width: 420px; height: 420px; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--accent) 18%, transparent), transparent 68%); pointer-events: none; }
.contact-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 60px; align-items: center; }
.contact-copy > p:not(.eyebrow) { max-width: 670px; color: var(--muted); }
.contact-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; margin-top: 28px; }
.text-link { font-weight: 900; border-bottom: 2px solid var(--accent); padding-bottom: 3px; }
.contact-card { position: relative; z-index: 2; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow); }
.contact-card > p { margin: 0; color: var(--accent); text-transform: uppercase; letter-spacing: .1em; font-size: .72rem; font-weight: 900; }
.contact-card h3 { font-size: 1.55rem; line-height: 1.18; margin: 12px 0 22px; }
.contact-card > a { display: inline-block; margin-top: 22px; font-weight: 900; }
.mini-tags { display: flex; flex-wrap: wrap; gap: 7px; }
.mini-tags span { min-height: 30px; font-size: .72rem; }

.site-footer { padding: 28px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: .86rem; }
.footer-inner { display: flex; justify-content: space-between; gap: 20px; align-items: center; }
.footer-inner p { margin: 0; }
.footer-inner a { font-weight: 800; color: var(--ink); }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 58%, transparent); outline-offset: 3px; border-radius: 6px; }

@media (max-width: 1020px) {
  .hero-grid { grid-template-columns: 1fr; gap: 42px; }
  .hero { min-height: auto; }
  .hero-visual { max-width: 420px; margin-inline: auto; width: 100%; }
  .projects-grid { grid-template-columns: 1fr 1fr; }
  .project-card:last-child { grid-column: 1 / -1; }
  .volunteer-grid, .contact-grid { grid-template-columns: 1fr; gap: 42px; }
  .main-nav { gap: 16px; }
}

@media (max-width: 820px) {
  .section-pad { padding: 80px 0; }
  .brand-text { display: none; }
  .nav-toggle { display: block; cursor: pointer; }
  .main-nav {
    position: absolute; left: 20px; right: 20px; top: calc(100% + 8px); display: none;
    flex-direction: column; align-items: stretch; gap: 0; padding: 14px;
    background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow);
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 12px 10px; }
  .main-nav a.active::after { display: none; }
  .theme-toggle { margin: 8px 10px; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
  .quick-info, .about-grid, .skills-grid, .education-grid { grid-template-columns: 1fr 1fr; }
  .timeline-item { grid-template-columns: 1fr; gap: 14px; }
  .timeline-meta { flex-direction: row; flex-wrap: wrap; align-items: center; }
}

@media (max-width: 620px) {
  .container { width: min(100% - 28px, var(--container)); }
  .section-pad { padding: 68px 0; }
  .hero { padding-top: 70px; }
  .hero h1 { font-size: clamp(2.7rem, 15vw, 4rem); }
  .hero-lead { font-size: 1rem; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .quick-info, .about-grid, .skills-grid, .education-grid, .projects-grid { grid-template-columns: 1fr; }
  .project-card:last-child { grid-column: auto; }
  .about-grid { gap: 4px; }
  .stat { padding: 15px 0; border-bottom: 1px solid rgba(255,255,255,.15); }
  .stat:last-child { border-bottom: 0; }
  .skill-panel, .timeline-content, .project-body, .contact-card, .volunteer-card { padding: 24px; }
  .timeline-item { padding-left: 34px; }
  .timeline::before { left: 7px; }
  .timeline-marker { width: 15px; height: 15px; left: 0; border-width: 4px; }
  .date-pill { white-space: normal; }
  .status-card { right: 0; bottom: 18px; max-width: 90%; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* Portfolio projects — real project captures */
.projects-grid-featured {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}
.project-card-featured {
  display: flex;
  flex-direction: column;
}
.project-card-featured .project-body {
  display: flex;
  flex-direction: column;
  flex: 1;
}
.project-shot {
  position: relative;
  height: 245px;
  overflow: hidden;
  background: var(--surface-2);
  border-bottom: 1px solid var(--line);
}
.project-shot::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 -26px 36px rgba(9, 28, 35, .08);
}
.project-shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transition: transform .45s ease;
}
.project-card-featured:hover .project-shot img {
  transform: scale(1.025);
}
.project-shot-volee img {
  object-position: center 37%;
}
.project-points {
  margin: 18px 0 0;
  padding-left: 19px;
  color: var(--muted);
  font-size: .92rem;
}
.project-points li + li { margin-top: 6px; }
.project-card-featured .project-tags { margin-top: auto; padding-top: 22px; }

@media (max-width: 1020px) {
  .projects-grid-featured { grid-template-columns: 1fr 1fr; }
  .projects-grid-featured .project-card:last-child { grid-column: 1 / -1; }
  .projects-grid-featured .project-card:last-child .project-shot { height: 330px; }
}

@media (max-width: 620px) {
  .projects-grid-featured { grid-template-columns: 1fr; }
  .projects-grid-featured .project-card:last-child { grid-column: auto; }
  .projects-grid-featured .project-card:last-child .project-shot,
  .project-shot { height: 220px; }
}
