:root {
  color-scheme: light;
  --planetary: #334eac;
  --venus: #bad6eb;
  --universe: #7096d1;
  --meteor: #f7f2eb;
  --galaxy: #081f5c;
  --sky: #d0e3ff;
  --bg: #f7f2eb;
  --paper: rgba(255, 255, 255, 0.72);
  --ink: #081f5c;
  --muted: rgba(8, 31, 92, 0.58);
  --soft: rgba(208, 227, 255, 0.56);
  --line: rgba(8, 31, 92, 0.14);
  --line-strong: rgba(51, 78, 172, 0.34);
  --glass: rgba(255, 255, 255, 0.46);
  --shadow: 0 26px 76px rgba(51, 78, 172, 0.14);
  --glass-shadow: 0 18px 56px rgba(8, 31, 92, 0.11);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 6%, rgba(186, 214, 235, 0.74), transparent 330px),
    radial-gradient(circle at 78% 10%, rgba(208, 227, 255, 0.72), transparent 380px),
    linear-gradient(180deg, #fffaf3 0, #f7f2eb 34%, #eef6ff 66%, #ffffff 100%);
}

body.cursor-ready,
body.cursor-ready a,
body.cursor-ready button {
  cursor: none;
}

body.modal-open,
body.modal-open a,
body.modal-open button {
  cursor: auto !important;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  cursor: pointer;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid rgba(51, 78, 172, 0.42);
  outline-offset: 3px;
}

h1,
h2,
h3,
p {
  margin: 0;
  letter-spacing: 0;
}

.section-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  width: min(1180px, calc(100% - 32px));
  height: 64px;
  position: sticky;
  top: 12px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 12px auto 0;
  padding: 0 14px 0 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(208, 227, 255, 0.34)),
    rgba(255, 255, 255, 0.42);
  backdrop-filter: blur(26px) saturate(1.35);
  box-shadow: var(--glass-shadow);
}

.brand {
  font-size: 18px;
  font-weight: 780;
  line-height: 1;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-links a {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 760;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--galaxy);
  background: rgba(208, 227, 255, 0.62);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.hero {
  padding: 60px 0 80px;
}

#home,
#work,
#about {
  scroll-margin-top: 100px;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 40px;
  align-items: start;
}

.section-kicker {
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 780;
  line-height: 1.2;
}

.hero h1 {
  max-width: 850px;
  font-size: 112px;
  font-weight: 920;
  line-height: 0.9;
}

.profile-panel {
  min-height: 318px;
  display: grid;
  align-content: space-between;
  justify-items: end;
  gap: 28px;
  padding-top: 8px;
}

.portrait-block {
  display: grid;
  justify-items: center;
  gap: 12px;
}

.portrait {
  width: 136px;
  height: 136px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 18px 54px rgba(17, 19, 22, 0.12);
  object-fit: cover;
}

.profile-name {
  font-size: 26px;
  font-weight: 360;
  line-height: 1;
}

.profile-role {
  margin-bottom: 10px;
  font-size: 20px;
  font-weight: 830;
  text-align: right;
}

.profile-line {
  max-width: 320px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.65;
  text-align: right;
}

.nowrap {
  white-space: nowrap;
}

.hero-bottom {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 36px;
  align-items: start;
  margin-top: 70px;
}

.contact-link,
.site-footer a {
  width: fit-content;
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid var(--ink);
  font-size: 17px;
  font-weight: 760;
}

.contact-email::before,
.contact-phone::before {
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(51, 78, 172, 0.24);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--planetary);
  font-size: 12px;
  line-height: 1;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.74);
}

.contact-email::before {
  content: "@";
}

.contact-phone::before {
  content: "☎";
}

.intro-text {
  max-width: 640px;
  justify-self: start;
  font-size: 24px;
  font-weight: 780;
  line-height: 1.22;
  text-align: left;
}

.hero-bottom .contact-link {
  justify-self: end;
  text-align: right;
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 54px;
}

.metric-strip div {
  position: relative;
  min-height: 108px;
  display: grid;
  align-content: space-between;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(208, 227, 255, 0.24)),
    rgba(255, 255, 255, 0.38);
  backdrop-filter: blur(22px) saturate(1.26);
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.62);
  transition:
    border-color 260ms ease,
    color 260ms ease,
    transform 260ms ease;
}

.metric-strip div::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(135deg, rgba(112, 150, 209, 0.92), rgba(51, 78, 172, 0.86));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 320ms ease;
}

.metric-strip div:hover {
  color: #ffffff;
  border-color: rgba(51, 78, 172, 0.28);
  transform: translateY(-4px);
}

.metric-strip div:hover::before {
  transform: scaleX(1);
}

.metric-strip span {
  position: relative;
  z-index: 1;
  font-size: 28px;
  font-weight: 900;
  line-height: 1;
}

.metric-strip strong {
  position: relative;
  z-index: 1;
  color: var(--muted);
  font-size: 13px;
  transition: color 260ms ease;
}

.metric-strip div:hover strong {
  color: rgba(255, 255, 255, 0.72);
}

.case-section {
  margin-top: 72px;
}

.section-heading {
  margin-bottom: 26px;
}

.compact-heading {
  display: block;
}

.section-heading h2 {
  max-width: 850px;
  font-size: 50px;
  font-weight: 860;
  line-height: 1.08;
}

.compact-heading h2 {
  max-width: 760px;
  font-size: 42px;
}

.case-grid,
.work-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.case-card,
.work-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(208, 227, 255, 0.18)),
    rgba(255, 255, 255, 0.42);
  box-shadow: var(--glass-shadow);
  backdrop-filter: blur(22px) saturate(1.2);
  outline: none;
  text-align: left;
  transition:
    transform 220ms ease,
    border-color 220ms ease,
    box-shadow 220ms ease,
    background 220ms ease;
}

.case-card {
  min-height: 334px;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  gap: 15px;
  align-content: space-between;
  padding: 18px;
  isolation: isolate;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.76), rgba(208, 227, 255, 0.24)),
    rgba(255, 255, 255, 0.42);
}

.case-card:hover {
  transform: translateY(-5px);
  border-color: rgba(51, 78, 172, 0.34);
  background:
    linear-gradient(135deg, rgba(186, 214, 235, 0.72), rgba(208, 227, 255, 0.5)),
    rgba(255, 255, 255, 0.66);
  box-shadow: 0 28px 78px rgba(51, 78, 172, 0.18);
}

.case-card:hover .case-category,
.case-card:hover .case-tags span {
  color: #ffffff;
  background: rgba(51, 78, 172, 0.72);
}

.case-card:hover .case-card-copy p,
.case-card:hover h3 small {
  color: rgba(8, 31, 92, 0.68);
}

.work-card:hover {
  border-color: rgba(51, 78, 172, 0.32);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.84), rgba(186, 214, 235, 0.58)),
    rgba(255, 255, 255, 0.5);
  box-shadow: 0 28px 78px rgba(51, 78, 172, 0.2);
}

.work-card:hover img {
  filter: saturate(0.42) contrast(1.03);
}

.work-card:hover .work-metric span {
  color: #ffffff;
  background: rgba(51, 78, 172, 0.82);
}

.work-card:hover .card-index {
  color: var(--planetary);
}

.work-card:hover h3 {
  color: var(--galaxy);
}

.work-card:hover p {
  color: rgba(8, 31, 92, 0.62);
}

.work-card:hover .work-card-body {
  background: rgba(255, 255, 255, 0.14);
}

.work-card:hover .work-metric {
  color: #ffffff;
}

.work-card:hover .work-metric span {
  transform: translateY(-1px);
}

.work-card:hover,
.work-card:focus-visible {
  transform: translateY(-6px);
}

.card-index {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.case-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.case-category {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border-radius: 999px;
  color: rgba(51, 78, 172, 0.82);
  background: rgba(208, 227, 255, 0.56);
  font-size: 12px;
  font-weight: 780;
  white-space: nowrap;
  transition:
    color 220ms ease,
    background 220ms ease;
}

.case-card-title {
  padding-top: 10px;
}

.case-card-copy {
  align-self: end;
}

.case-card h3 {
  font-size: 27px;
  font-weight: 900;
  line-height: 1.08;
  overflow-wrap: anywhere;
  text-align: left;
}

.case-card h3 small {
  display: block;
  margin-top: 8px;
  color: rgba(8, 31, 92, 0.56);
  font-size: 13px;
  font-weight: 620;
  line-height: 1.15;
}

.case-card p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.case-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.case-tags span {
  min-height: 27px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border-radius: 999px;
  color: rgba(8, 31, 92, 0.62);
  background: rgba(255, 255, 255, 0.62);
  font-size: 12px;
  font-weight: 760;
  transition:
    color 220ms ease,
    background 220ms ease;
}

.work-section {
  width: 100%;
  padding: 96px 0 92px;
  color: var(--galaxy);
  background:
    radial-gradient(circle at 18% 18%, rgba(208, 227, 255, 0.92), transparent 350px),
    radial-gradient(circle at 84% 8%, rgba(112, 150, 209, 0.3), transparent 340px),
    linear-gradient(135deg, #f7f2eb 0%, #d0e3ff 48%, #bad6eb 100%);
}

.work-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(260px, 0.55fr);
  column-gap: 48px;
  row-gap: 12px;
  align-items: end;
}

.work-heading .section-kicker {
  grid-column: 1 / -1;
  color: rgba(8, 31, 92, 0.54);
}

.work-heading h2 {
  color: var(--galaxy);
}

.work-heading p:not(.section-kicker) {
  color: rgba(8, 31, 92, 0.62);
  font-size: 18px;
  line-height: 1.55;
  text-align: right;
}

.work-card {
  min-height: 448px;
  display: grid;
  grid-template-rows: 220px minmax(0, 1fr);
  cursor: pointer;
  border-color: rgba(255, 255, 255, 0.62);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.7), rgba(247, 242, 235, 0.45)),
    rgba(255, 255, 255, 0.42);
  color: var(--galaxy);
}

.work-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.16);
  background: #f3f5f7;
}

.work-card-body {
  display: grid;
  align-content: space-between;
  gap: 18px;
  padding: 16px;
}

.work-card .card-index {
  color: rgba(51, 78, 172, 0.58);
}

.work-card h3 {
  font-size: 24px;
  font-weight: 850;
  line-height: 1.1;
}

.work-card p {
  margin-top: 10px;
  color: rgba(8, 31, 92, 0.62);
  font-size: 14px;
  line-height: 1.5;
}

.work-metric {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.work-metric span {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(208, 227, 255, 0.56);
  color: rgba(8, 31, 92, 0.66);
  font-size: 12px;
  font-weight: 780;
}

.about-section {
  padding: 90px 0 90px;
}

.about-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  column-gap: 60px;
  row-gap: 18px;
  align-items: end;
}

.about-heading .section-kicker {
  grid-column: 1 / -1;
}

.about-heading p:not(.section-kicker) {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.timeline {
  position: relative;
  display: grid;
  gap: 12px;
  margin-top: 44px;
  padding-left: 22px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 6px;
  bottom: 6px;
  width: 1px;
  background: var(--line);
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 34px;
  min-height: 138px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(208, 227, 255, 0.22)),
    rgba(255, 255, 255, 0.42);
  backdrop-filter: blur(22px) saturate(1.2);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.62);
  cursor: pointer;
  transition:
    color 220ms ease,
    border-color 220ms ease,
    transform 220ms ease,
    background 220ms ease;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -22px;
  top: 27px;
  width: 10px;
  height: 10px;
  border: 2px solid var(--paper);
  border-radius: 999px;
  background: var(--ink);
  box-shadow: 0 0 0 1px var(--line-strong);
}

.timeline-item:hover,
.timeline-item.expanded {
  transform: translateX(4px);
  color: var(--galaxy);
  border-color: rgba(51, 78, 172, 0.28);
  background:
    linear-gradient(135deg, rgba(208, 227, 255, 0.72), rgba(112, 150, 209, 0.36)),
    rgba(255, 255, 255, 0.58);
  box-shadow: 0 22px 62px rgba(51, 78, 172, 0.15);
}

.timeline-item:hover::before,
.timeline-item.expanded::before {
  background: var(--planetary);
  box-shadow: 0 0 0 6px rgba(208, 227, 255, 0.9);
}

.timeline-date {
  display: grid;
  gap: 6px;
  color: rgba(51, 78, 172, 0.82);
  font-weight: 820;
  line-height: 1.2;
  transition: color 220ms ease;
}

.timeline-date .date-start {
  font-size: 30px;
  font-weight: 900;
  line-height: 1;
}

.timeline-date .date-end {
  color: rgba(8, 31, 92, 0.5);
  font-size: 13px;
  font-weight: 780;
}

.timeline-content h3 {
  font-size: 22px;
  font-weight: 850;
  line-height: 1.2;
}

.timeline-role {
  margin-top: 7px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 760;
  transition: color 220ms ease;
}

.timeline-summary {
  margin-top: 12px;
  color: #33383d;
  font-size: 15px;
  line-height: 1.65;
  transition: color 220ms ease;
}

.timeline-more {
  display: none;
  gap: 8px;
  margin-top: 14px;
  padding-left: 18px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
  transition: color 220ms ease;
}

.timeline-item:hover .timeline-date,
.timeline-item.expanded .timeline-date,
.timeline-item:hover .timeline-role,
.timeline-item.expanded .timeline-role,
.timeline-item:hover .timeline-more,
.timeline-item.expanded .timeline-more {
  color: rgba(8, 31, 92, 0.62);
}

.timeline-item:hover .timeline-summary,
.timeline-item.expanded .timeline-summary {
  color: rgba(8, 31, 92, 0.78);
}

.timeline-item.expanded .timeline-more {
  display: grid;
}

.timeline-toggle {
  width: fit-content;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  margin-top: 14px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: var(--paper);
  font-size: 12px;
  font-weight: 820;
  transition:
    color 180ms ease,
    background 180ms ease,
    border-color 180ms ease;
}

.timeline-toggle:hover {
  background: var(--soft);
}

.timeline-item:hover .timeline-toggle,
.timeline-item.expanded .timeline-toggle {
  color: var(--planetary);
  background: rgba(255, 255, 255, 0.76);
  border-color: rgba(51, 78, 172, 0.24);
}

.site-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 44px;
  align-items: stretch;
  margin-bottom: 20px;
  padding: 34px;
  border-top: 1px solid var(--line);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  border-left: 1px solid var(--line);
  border-radius: 0 0 8px 8px;
  color: var(--ink);
  background:
    radial-gradient(circle at 80% 22%, rgba(186, 214, 235, 0.72), transparent 280px),
    linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(208, 227, 255, 0.32)),
    rgba(255, 255, 255, 0.44);
  backdrop-filter: blur(24px) saturate(1.25);
  box-shadow: var(--glass-shadow);
}

.footer-main {
  display: grid;
  align-content: space-between;
  min-height: 220px;
}

.footer-main h2 {
  max-width: 660px;
  font-size: 52px;
  font-weight: 860;
  line-height: 1.02;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.site-footer a {
  color: var(--ink);
}

.footer-side {
  display: grid;
  gap: 14px;
}

.footer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.footer-meta span {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.58);
  font-size: 12px;
  font-weight: 800;
}

.qr-card {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr);
  gap: 14px;
  align-items: stretch;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.7), rgba(208, 227, 255, 0.28)),
    rgba(255, 255, 255, 0.42);
  backdrop-filter: blur(20px) saturate(1.2);
}

.qr-image {
  width: 118px;
  height: 118px;
  object-fit: cover;
  border: 8px solid #ffffff;
  border-radius: 8px;
  background: #ffffff;
  box-shadow:
    0 12px 28px rgba(8, 31, 92, 0.1),
    inset 0 0 0 1px var(--line);
}

.qr-copy {
  min-height: 118px;
  display: grid;
  align-content: space-between;
  gap: 16px;
}

.qr-label {
  display: block;
  transform: translateY(8px);
}

.qr-label strong,
.qr-label small {
  display: block;
}

.qr-label strong {
  color: var(--ink);
  font-size: 15px;
  font-weight: 850;
  line-height: 1.15;
}

.qr-label small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 760;
}

.qr-card p {
  color: var(--muted);
  font-size: 14px;
  font-weight: 760;
  line-height: 1.55;
  transform: translateY(-8px);
}

.case-dialog {
  width: min(720px, calc(100% - 32px));
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(24px);
  box-shadow: var(--shadow);
}

.case-dialog::backdrop {
  background: rgba(8, 10, 12, 0.32);
  backdrop-filter: blur(8px);
}

.dialog-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 1;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  padding: 0;
  border-radius: 999px;
  background: rgba(208, 227, 255, 0.5);
  color: var(--muted);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
  transition:
    background 180ms ease,
    transform 180ms ease;
}

.dialog-close:hover {
  background: rgba(186, 214, 235, 0.78);
  transform: rotate(90deg);
}

.dialog-close span,
.dialog-close span::before {
  width: 14px;
  height: 2px;
  display: block;
  border-radius: 999px;
  background: var(--planetary);
}

.dialog-close span {
  transform: rotate(45deg);
}

.dialog-close span::before {
  content: "";
  transform: rotate(90deg);
}

.dialog-body {
  padding: 24px 28px 30px;
}

.dialog-body .section-kicker {
  margin-bottom: 10px;
  padding-right: 48px;
}

.dialog-body h2 {
  max-width: 520px;
  font-size: 34px;
  font-weight: 880;
  line-height: 1.08;
}

.dialog-body h2 small {
  display: block;
  margin-top: 8px;
  color: rgba(8, 31, 92, 0.5);
  font-size: 15px;
  font-weight: 620;
}

.dialog-body p {
  margin-top: 14px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.dialog-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 22px;
}

.dialog-metric-grid span {
  min-height: 86px;
  display: grid;
  align-content: center;
  padding: 12px;
  border: 1px solid rgba(51, 78, 172, 0.18);
  border-radius: 8px;
  color: var(--galaxy);
  background:
    linear-gradient(135deg, rgba(208, 227, 255, 0.72), rgba(255, 255, 255, 0.64)),
    rgba(255, 255, 255, 0.54);
  font-size: 22px;
  font-weight: 900;
  line-height: 1.05;
  text-align: left;
}

.dialog-list {
  display: grid;
  gap: 10px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.dialog-list li {
  padding: 12px 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(208, 227, 255, 0.28);
  color: rgba(8, 31, 92, 0.78);
  font-size: 14px;
  line-height: 1.55;
}

.dialog-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.dialog-meta span {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(51, 78, 172, 0.84);
  color: #ffffff;
  font-size: 12px;
  font-weight: 780;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 30;
  min-height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.84);
  color: var(--ink);
  box-shadow: 0 12px 34px rgba(17, 19, 22, 0.1);
  font-size: 13px;
  font-weight: 780;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 12px);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.toast.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.cursor-glass {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 100;
  pointer-events: none;
  opacity: 0;
  transform: translate3d(-50%, -50%, 0);
  width: 30px;
  height: 30px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 999px;
  background:
    radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.38) 34%, rgba(208, 227, 255, 0.18) 70%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.48), rgba(186, 214, 235, 0.2));
  box-shadow:
    0 8px 24px rgba(8, 31, 92, 0.12),
    inset 0 1px 1px rgba(255, 255, 255, 0.9),
    inset 0 -8px 18px rgba(112, 150, 209, 0.12);
  contain: layout paint style;
  will-change: transform, width, height, opacity;
  transition:
    opacity 160ms ease,
    width 180ms ease,
    height 180ms ease,
    background 180ms ease;
}

body.cursor-ready .cursor-glass {
  opacity: 1;
}

body.cursor-hover .cursor-glass {
  width: 40px;
  height: 40px;
  background:
    radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.42) 34%, rgba(186, 214, 235, 0.24) 72%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.56), rgba(112, 150, 209, 0.18));
}

body.modal-open .cursor-glass {
  display: none !important;
  opacity: 0 !important;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 520ms ease,
    transform 520ms ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 980px) {
  .hero {
    padding-top: 46px;
  }

  .hero-grid,
  .about-heading {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    font-size: 78px;
  }

  .profile-panel {
    min-height: auto;
    grid-template-columns: 120px minmax(0, 1fr);
    align-items: center;
    justify-items: start;
  }

  .portrait {
    width: 120px;
    height: 120px;
  }

  .profile-role,
  .profile-line {
    text-align: left;
  }

  .profile-line {
    max-width: 460px;
  }

  .hero-bottom {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-top: 46px;
  }

  .hero-bottom .contact-link {
    justify-self: start;
    text-align: left;
  }

  .intro-text {
    font-size: 22px;
  }

  .metric-strip,
  .case-grid,
  .work-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .work-heading,
  .site-footer {
    grid-template-columns: 1fr;
  }

  .work-heading p:not(.section-kicker) {
    text-align: left;
  }

  .section-heading h2 {
    font-size: 40px;
  }
}

@media (max-width: 640px) {
  .section-shell,
  .site-header {
    width: min(100% - 20px, 1180px);
  }

  .site-header {
    top: 8px;
    height: auto;
    display: grid;
    grid-template-columns: 1fr;
    align-items: flex-start;
    gap: 11px;
    margin-top: 8px;
    padding: 12px;
    border-radius: 12px;
  }

  .brand {
    font-size: 17px;
    line-height: 1.15;
  }

  .nav-links {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
  }

  .nav-links a {
    min-height: 36px;
    padding: 0 6px;
    justify-content: center;
    border-radius: 10px;
    font-size: 12px;
  }

  .hero {
    padding: 34px 0 58px;
  }

  #home,
  #work,
  #about {
    scroll-margin-top: 38px;
  }

  .hero-grid {
    gap: 24px;
  }

  .section-kicker {
    margin-bottom: 10px;
    font-size: 11px;
    line-height: 1.35;
  }

  .hero h1 {
    max-width: 100%;
    font-size: clamp(48px, 15vw, 64px);
    line-height: 0.92;
  }

  .hero-bottom {
    grid-template-columns: 1fr;
    gap: 14px;
    margin-top: 30px;
  }

  .profile-panel {
    width: 100%;
    grid-template-columns: 1fr;
    gap: 18px;
    justify-items: start;
    padding-top: 0;
  }

  .portrait-block {
    justify-items: start;
    gap: 10px;
  }

  .portrait {
    width: 92px;
    height: 92px;
  }

  .profile-name {
    font-size: 21px;
    text-align: left;
  }

  .profile-role {
    margin-bottom: 7px;
    font-size: 19px;
    text-align: left;
  }

  .profile-line {
    max-width: 100%;
    font-size: 14px;
    line-height: 1.55;
    text-align: left;
  }

  .intro-text {
    max-width: 100%;
    font-size: 19px;
    line-height: 1.42;
    text-align: left;
  }

  .contact-link,
  .site-footer a {
    max-width: 100%;
    min-height: 32px;
    font-size: 15px;
    overflow-wrap: anywhere;
  }

  .metric-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 34px;
  }

  .metric-strip div {
    min-height: 92px;
    padding: 14px;
    border-radius: 12px;
  }

  .metric-strip span {
    font-size: 24px;
  }

  .metric-strip strong {
    font-size: 12px;
  }

  .case-section {
    margin-top: 54px;
  }

  .section-heading {
    margin-bottom: 18px;
  }

  .case-grid,
  .work-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .case-card {
    min-height: auto;
    gap: 28px;
    padding: 18px;
    border-radius: 14px;
  }

  .case-card-title {
    padding-top: 0;
  }

  .case-card h3 {
    font-size: 31px;
    line-height: 1.06;
  }

  .case-card h3 small {
    margin-top: 7px;
    font-size: 13px;
  }

  .case-card-copy {
    align-self: start;
  }

  .case-card p {
    font-size: 14px;
    line-height: 1.58;
  }

  .work-section {
    padding: 66px 0 68px;
    background:
      radial-gradient(circle at 20% 8%, rgba(255, 255, 255, 0.9), transparent 220px),
      linear-gradient(160deg, #f7f2eb 0%, #d0e3ff 58%, #bad6eb 100%);
  }

  .work-heading {
    row-gap: 8px;
  }

  .work-heading p:not(.section-kicker) {
    max-width: 260px;
    font-size: 14px;
    line-height: 1.5;
    text-align: left;
  }

  .work-card {
    min-height: auto;
    grid-template-rows: auto auto;
    border-radius: 14px;
  }

  .work-card img {
    order: 2;
    height: auto;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    object-position: center top;
    filter: saturate(0.55) contrast(1.03);
  }

  .work-card-body {
    order: 1;
    gap: 18px;
    padding: 17px;
  }

  .work-card h3 {
    margin-top: 7px;
    font-size: 24px;
    line-height: 1.15;
  }

  .work-card p {
    margin-top: 9px;
    font-size: 14px;
    line-height: 1.6;
  }

  .work-metric {
    gap: 7px;
  }

  .work-metric span {
    min-height: 29px;
    font-size: 12px;
  }

  .section-heading h2,
  .compact-heading h2 {
    font-size: 34px;
    line-height: 1.08;
  }

  .compact-heading {
    display: block;
  }

  .timeline {
    gap: 10px;
    margin-top: 30px;
    padding-left: 16px;
  }

  .timeline-item {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 16px;
    border-radius: 14px;
  }

  .timeline-item::before {
    left: -19px;
  }

  .timeline-date {
    gap: 4px;
  }

  .timeline-date .date-start {
    font-size: 25px;
  }

  .timeline-content h3 {
    font-size: 19px;
  }

  .timeline-summary {
    font-size: 14px;
    line-height: 1.6;
  }

  .site-footer {
    gap: 26px;
    padding: 22px;
    border-radius: 14px;
  }

  .footer-main h2 {
    font-size: 31px;
    line-height: 1.08;
  }

  .footer-main {
    min-height: 190px;
    gap: 26px;
  }

  .footer-links {
    display: grid;
    gap: 12px;
  }

  .qr-card {
    grid-template-columns: 104px minmax(0, 1fr);
    gap: 12px;
    padding: 12px;
    border-radius: 14px;
  }

  .qr-image {
    width: 104px;
    height: 104px;
  }

  .qr-copy {
    min-height: 104px;
  }

  .dialog-body {
    padding: 22px 18px 22px;
  }

  .dialog-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dialog-metric-grid span {
    min-height: 72px;
    font-size: 18px;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}

@media (pointer: coarse), (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  body.cursor-ready,
  body.cursor-ready a,
  body.cursor-ready button {
    cursor: auto;
  }

  .cursor-glass {
    display: none;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
