/* ── Theme tokens ── */
.portfolio-theme {
  --pf-bg: #1a1a1a;
  --pf-text: #ffffff;
  --pf-muted: #c7c7c7;
  --pf-muted-2: rgba(255, 255, 255, 0.65);
  --pf-muted-3: rgba(255, 255, 255, 0.4);
  --pf-border: rgba(255, 255, 255, 0.1);
  --pf-border-strong: rgba(255, 255, 255, 0.35);
  --pf-surface: #191919;
  --pf-surface-2: #252525;
  --pf-sticky-bg: rgba(26, 26, 26, 0.92);
  --pf-btn-hover-bg: #ffffff;
  --pf-btn-hover-text: #1a1a1a;
  --pf-overlay: rgba(0, 0, 0, 0.62);
}

.portfolio-theme[data-theme="light"] {
  --pf-bg: #f4f4f5;
  --pf-text: #111111;
  --pf-muted: #52525b;
  --pf-muted-2: rgba(17, 17, 17, 0.65);
  --pf-muted-3: rgba(17, 17, 17, 0.45);
  --pf-border: rgba(17, 17, 17, 0.1);
  --pf-border-strong: rgba(17, 17, 17, 0.25);
  --pf-surface: #ffffff;
  --pf-surface-2: #e4e4e7;
  --pf-sticky-bg: rgba(244, 244, 245, 0.92);
  --pf-btn-hover-bg: #111111;
  --pf-btn-hover-text: #ffffff;
  --pf-overlay: rgba(0, 0, 0, 0.45);
}

/* ── Reset & base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  background-color: #1a1a1a;
  scroll-behavior: smooth;
}

html[data-portfolio-theme="light"] {
  background-color: #f4f4f5;
  --pf-bg: #f4f4f5;
  --pf-text: #111111;
  --pf-muted: #52525b;
  --pf-muted-2: rgba(17, 17, 17, 0.65);
  --pf-muted-3: rgba(17, 17, 17, 0.45);
  --pf-border: rgba(17, 17, 17, 0.1);
  --pf-border-strong: rgba(17, 17, 17, 0.25);
  --pf-surface: #ffffff;
  --pf-surface-2: #e4e4e7;
  --pf-btn-hover-bg: #111111;
  --pf-btn-hover-text: #ffffff;
  --pf-overlay: rgba(0, 0, 0, 0.45);
}

html[data-portfolio-theme="dark"] {
  background-color: #1a1a1a;
  --pf-bg: #1a1a1a;
  --pf-text: #ffffff;
  --pf-muted: #c7c7c7;
  --pf-muted-2: rgba(255, 255, 255, 0.65);
  --pf-muted-3: rgba(255, 255, 255, 0.4);
  --pf-border: rgba(255, 255, 255, 0.1);
  --pf-border-strong: rgba(255, 255, 255, 0.35);
  --pf-surface: #191919;
  --pf-surface-2: #252525;
  --pf-btn-hover-bg: #ffffff;
  --pf-btn-hover-text: #1a1a1a;
  --pf-overlay: rgba(0, 0, 0, 0.62);
}

body {
  font-family: 'Manrope', ui-sans-serif, system-ui, sans-serif;
  min-height: 100dvh;
  background-color: inherit;
  color: var(--pf-text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

.portfolio-theme {
  background-color: var(--pf-bg);
  color: var(--pf-text);
  transition: background-color 0.3s ease, color 0.3s ease;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
ul { list-style: none; }

.container {
  max-width: 80rem;
  margin: 0 auto;
  padding: 0 1.5rem;
}

@media (min-width: 640px) {
  .container { padding: 0 2.5rem; }
}

.hidden { display: none !important; }

/* ── Navigation ── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  padding: max(1rem, env(safe-area-inset-top)) 1.5rem 0;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 80rem;
  margin: 0 auto;
}

.nav-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.lang-switcher {
  display: flex;
  align-items: center;
  gap: 0.125rem;
  padding: 0.125rem;
  border-radius: 0.5rem;
  background-color: var(--pf-surface-2);
}

.lang-btn {
  padding: 0.375rem 0.625rem;
  border-radius: 0.375rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--pf-muted-2);
  transition: background-color 0.15s, color 0.15s;
}

.lang-btn--active,
.lang-btn[aria-pressed="true"] {
  background-color: var(--pf-surface);
  color: var(--pf-text);
}

.lang-btn:hover:not(.lang-btn--active) {
  color: var(--pf-text);
}

.nav-logo {
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--pf-text);
  transition: opacity 0.2s;
}

.nav-logo:hover { opacity: 0.7; }


.nav-theme-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.5rem;
  color: var(--pf-muted);
  transition: background-color 0.15s, color 0.15s;
}

.nav-theme-btn:hover {
  background-color: var(--pf-surface-2);
  color: var(--pf-text);
}

/* ── Hero ── */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100dvh;
  text-align: center;
  position: relative;
  padding: 6rem 1.5rem 5rem;
}

.hero-content {
  max-width: 100%;
  overflow: hidden;
}

.hero-name {
  font-size: clamp(1.875rem, 8.5vw, 7.5rem);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  color: var(--pf-text);
}

.hero-name-line {
  display: block;
}

.hero-role {
  margin-top: 1.25rem;
  font-size: clamp(0.875rem, 2.5vw, 1.125rem);
  font-weight: 400;
  color: var(--pf-muted-2);
  letter-spacing: 0.01em;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 2rem;
}

.hero-shortcut {
  min-width: 8rem;
  justify-content: center;
}

.hero-shortcut-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 9999px;
  background-color: var(--pf-surface-2);
  color: var(--pf-muted-2);
  transition: background-color 0.2s, color 0.2s;
}

.hero-shortcut-icon:hover {
  background-color: var(--pf-btn-hover-bg);
  color: var(--pf-btn-hover-text);
}

.hero-scroll {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  color: var(--pf-muted-3);
  transition: color 0.2s;
}

.hero-scroll:hover { color: var(--pf-muted-2); }

.pf-scroll-chevron {
  animation: pf-scroll-chevron 1.6s ease-in-out infinite;
}

.pf-scroll-chevron:nth-child(2) { animation-delay: 0.18s; }
.pf-scroll-chevron:nth-child(3) { animation-delay: 0.36s; }

@keyframes pf-scroll-chevron {
  0%, 100% { transform: translateY(0); opacity: 0.3; }
  50% { transform: translateY(5px); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .pf-scroll-chevron { animation: none; opacity: 0.65; }
}

/* ── Sections ── */
.section {
  padding: 5rem 0;
}

@media (min-width: 640px) {
  .section { padding: 6rem 0; }
}

/* ── About ── */
.about-body {
  max-width: 42rem;
}

.about-body p {
  font-size: 1rem;
  line-height: 1.625;
  font-weight: 300;
  color: var(--pf-muted-2);
  margin-bottom: 1rem;
}

@media (min-width: 640px) {
  .about-body p { font-size: 1.125rem; }
}

.about-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.5rem;
}

/* ── Buttons ── */
.btn-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 500;
  background-color: var(--pf-surface-2);
  color: var(--pf-muted-2);
  border: 1px solid transparent;
  transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}

.btn-pill:hover {
  background-color: var(--pf-btn-hover-bg);
  color: var(--pf-btn-hover-text);
}

/* ── Two-column layout ── */
.two-col {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 1024px) {
  .two-col {
    grid-template-columns: 12rem minmax(0, 1fr);
    gap: 4rem;
    align-items: start;
  }
}

.section-label {
  font-size: 1rem;
  font-weight: 600;
  color: var(--pf-text);
  letter-spacing: -0.025em;
}

@media (min-width: 640px) {
  .section-label { font-size: 1.125rem; }
}

/* ── Expertise list ── */
.expertise-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.expertise-list li {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  font-size: 1rem;
  font-weight: 300;
  color: var(--pf-muted-2);
  line-height: 1.5;
}

@media (min-width: 640px) {
  .expertise-list li { font-size: 1.125rem; }
}

.expertise-list .arrow {
  color: var(--pf-muted-3);
  flex-shrink: 0;
}

/* ── Timeline ── */
.timeline-section .section-label {
  margin-bottom: 2.5rem;
}

.timeline-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.tl-entry {
  display: grid;
  grid-template-columns: 3.5rem 1fr;
  gap: 0 1.5rem;
  min-height: 1px;
}

.tl-line-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
}

.tl-logo-wrap {
  width: 3rem;
  height: 3rem;
  border-radius: 0.75rem;
  border: 1px solid var(--pf-border);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

.tl-logo {
  width: 80%;
  height: 80%;
  object-fit: contain;
}

.tl-line-segment {
  flex: 1;
  width: 1px;
  background-color: var(--pf-border);
  margin-top: 0.5rem;
  min-height: 1.5rem;
}

.tl-entry:last-child .tl-line-segment {
  display: none;
}

.tl-content {
  padding-bottom: 2.5rem;
}

.tl-entry:last-child .tl-content {
  padding-bottom: 0;
}

.tl-company-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 3rem;
  flex-wrap: wrap;
}

.tl-company-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.tl-info-wrap {
  position: relative;
  display: inline-flex;
}

.tl-info-btn {
  width: 1.625rem;
  height: 1.625rem;
  border-radius: 9999px;
  border: 1px solid var(--pf-border);
  background: transparent;
  font-size: 0.75rem;
  font-weight: 700;
  font-style: italic;
  color: var(--pf-muted-2);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s, color 0.2s, background-color 0.2s;
  cursor: pointer;
}

.tl-info-open .tl-info-btn,
.tl-info-btn:focus {
  border-color: var(--pf-border-strong);
  color: var(--pf-text);
  background-color: var(--pf-surface-2);
}

/* Backdrop */
.tl-info-card {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  z-index: 200;
  padding: 1rem;
}

.tl-info-open .tl-info-card {
  opacity: 1;
  pointer-events: auto;
}

/* Inner panel */
.tl-info-card-inner {
  position: relative;
  width: 100%;
  max-width: 44rem;
  max-height: 85vh;
  overflow-y: auto;
  padding: 2rem 2.25rem;
  background-color: var(--pf-bg);
  border: 1px solid var(--pf-border);
  border-radius: 1.25rem;
  box-shadow: 0 16px 48px rgba(0,0,0,0.22);
  text-align: left;
  transform: translateY(12px) scale(0.98);
  transition: transform 0.2s;
}

.tl-info-open .tl-info-card-inner {
  transform: translateY(0) scale(1);
}

.tl-info-card-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 2rem;
  height: 2rem;
  border-radius: 9999px;
  border: 1px solid var(--pf-border);
  background: transparent;
  color: var(--pf-muted-2);
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.15s, color 0.15s;
}

.tl-info-card-close:hover {
  background-color: var(--pf-surface-2);
  color: var(--pf-text);
}

.tl-tip-section {
  font-size: 0.8125rem;
  color: var(--pf-muted-2);
  line-height: 1.55;
  margin-bottom: 0.75rem;
}

.tl-tip-section:last-child { margin-bottom: 0; }

.tl-tip-section strong {
  font-weight: 600;
  color: var(--pf-text);
  display: block;
  margin-bottom: 0.2rem;
}

.tl-tip-projects {
  list-style: none;
  margin-top: 0.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.tl-tip-project {
  font-size: 0.8125rem;
  color: var(--pf-muted-2);
  line-height: 1.5;
  padding-left: 0.75rem;
  position: relative;
}

.tl-tip-project::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--pf-muted-3);
}

.tl-tip-project strong {
  font-weight: 600;
  color: var(--pf-text);
  display: inline;
}

.tl-tip-project-link {
  font-weight: 600;
  color: var(--pf-accent);
  text-decoration: none;
  transition: opacity 0.15s;
}

.tl-tip-project-link:hover {
  opacity: 0.75;
  text-decoration: underline;
}

.tl-company {
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--pf-text);
  letter-spacing: -0.01em;
}

.tl-view-btn {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--pf-muted-2);
  border: 1px solid var(--pf-border);
  border-radius: 9999px;
  padding: 0.3125rem 0.875rem;
  transition: color 0.2s, border-color 0.2s, background-color 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}

.tl-view-btn:hover {
  color: var(--pf-text);
  border-color: var(--pf-border-strong);
  background-color: var(--pf-surface-2);
}

.tl-role {
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--pf-border);
}

.tl-role:first-of-type {
  border-top: none;
  margin-top: 0;
  padding-top: 0;
}

.tl-role-header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.25rem 0.75rem;
  margin-bottom: 0.35rem;
}

.tl-role-title {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--pf-text);
}

.tl-role-period {
  font-size: 0.8125rem;
  font-weight: 300;
  color: var(--pf-muted-3);
}

.tl-role-desc {
  font-size: 0.875rem;
  font-weight: 300;
  color: var(--pf-muted-2);
  line-height: 1.55;
}

.tl-role + .tl-role {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--pf-border);
}

/* ── Projects ── */
.projects-title {
  font-size: clamp(2.5rem, 8vw, 5rem);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.04em;
  line-height: 0.95;
  color: var(--pf-text);
  text-align: center;
  margin-bottom: 2.5rem;
}

.filter-area {
  margin-bottom: 2.5rem;
}

.filter-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.filter-group-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--pf-muted-3);
  margin-right: 0.25rem;
  white-space: nowrap;
}

.filter-divider {
  height: 1px;
  background-color: var(--pf-border);
  margin: 0.75rem 0;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.pf-filter-chip {
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 500;
  border: 1px solid transparent;
  background-color: var(--pf-surface-2);
  color: var(--pf-muted-2);
  transition: background-color 0.2s, color 0.2s, border-color 0.2s, opacity 0.2s;
}

.pf-filter-chip[aria-pressed="true"] {
  background-color: var(--pf-btn-hover-bg);
  color: var(--pf-btn-hover-text);
  box-shadow: inset 0 0 0 1px var(--pf-border-strong);
}

@media (hover: hover) {
  .pf-filter-chip[aria-pressed="false"]:hover {
    border-color: var(--pf-border-strong);
    color: var(--pf-muted);
  }
  .pf-filter-chip[aria-pressed="true"]:hover { opacity: 0.88; }
}

.pf-filter-chip:active { opacity: 0.82; }

.projects-list {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--pf-border);
}

.project-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--pf-border);
  transition: opacity 0.2s;
}

.project-row:hover { opacity: 0.85; }

.project-row.hidden-card { display: none; }

.project-row-main {
  min-width: 0;
  flex: 1;
}

.project-row-company {
  display: block;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pf-muted-3);
  margin-bottom: 0.375rem;
}

.project-row-title {
  font-size: 1.0625rem;
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--pf-text);
  line-height: 1.35;
  margin-bottom: 0.375rem;
}

@media (min-width: 640px) {
  .project-row-title { font-size: 1.125rem; }
}

.project-row-segment {
  font-size: 0.875rem;
  font-weight: 300;
  color: var(--pf-muted-2);
  line-height: 1.45;
}

.project-row-arrow {
  flex-shrink: 0;
  font-size: 1.125rem;
  color: var(--pf-muted-3);
  transition: transform 0.2s, color 0.2s;
}

.project-row:hover .project-row-arrow {
  color: var(--pf-text);
  transform: translateX(3px);
}

/* ── Password gate ── */
.gate {
  max-width: 28rem;
  margin: 0 auto;
  text-align: center;
  padding: 2rem 0 3rem;
}

.gate-label {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--pf-muted-3);
  margin-bottom: 1rem;
}

.gate-title {
  font-size: clamp(1.75rem, 5vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--pf-text);
  margin-bottom: 0.75rem;
}

.gate-desc {
  font-size: 0.9375rem;
  font-weight: 300;
  color: var(--pf-muted-2);
  line-height: 1.5;
  margin-bottom: 2rem;
}

.gate-form {
  text-align: left;
}

.gate-field-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--pf-muted);
  margin-bottom: 0.5rem;
}

.gate-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  border: 1px solid var(--pf-border-strong);
  background-color: var(--pf-surface);
  color: var(--pf-text);
  font-size: 1rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.gate-input:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.25);
}

.gate-error {
  margin-top: 0.5rem;
  font-size: 0.875rem;
  color: #ef4444;
}

.gate-hint {
  margin-top: 0.5rem;
  font-size: 0.8125rem;
  font-weight: 300;
  color: var(--pf-muted-3);
  line-height: 1.45;
}

.gate-submit {
  width: 100%;
  margin-top: 1.25rem;
  padding: 0.875rem 1.5rem;
  border-radius: 9999px;
  font-size: 0.9375rem;
  font-weight: 500;
  background-color: var(--pf-surface-2);
  color: var(--pf-text);
  border: 1px solid var(--pf-border);
  transition: background-color 0.2s, color 0.2s;
}

.gate-submit:hover {
  background-color: var(--pf-btn-hover-bg);
  color: var(--pf-btn-hover-text);
}

.gate-request {
  margin-top: 1rem;
  text-align: center;
}

.gate-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--pf-muted-2);
  text-decoration: underline;
  text-underline-offset: 0.2em;
  transition: color 0.2s;
}

.gate-link:hover {
  color: var(--pf-text);
}

.gate--modal {
  padding: 0;
  max-width: none;
}

/* ── Modal ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background-color: var(--pf-overlay);
  backdrop-filter: blur(4px);
}

.modal-panel {
  position: relative;
  width: 100%;
  max-width: 28rem;
  padding: 2rem 1.5rem;
  border-radius: 1.25rem;
  background-color: var(--pf-bg);
  border: 1px solid var(--pf-border);
}

.modal-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--pf-muted-2);
  border-radius: 0.375rem;
  transition: color 0.2s, background-color 0.2s;
}

.modal-close:hover {
  color: var(--pf-text);
  background-color: var(--pf-surface-2);
}

/* ── Project page ── */
.project-page {
  padding: 7rem 0 4rem;
  min-height: 80vh;
}

.project-back {
  display: inline-block;
  font-size: 0.875rem;
  color: var(--pf-muted-2);
  margin-bottom: 2.5rem;
  transition: color 0.2s;
}

.project-back:hover { color: var(--pf-text); }

.project-article {
  max-width: 42rem;
  margin: 0 auto;
}

.case-body {
  color: var(--pf-muted-2);
  font-weight: 300;
  line-height: 1.625;
}

.case-body h1 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--pf-text);
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.case-body h2 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--pf-text);
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
  letter-spacing: -0.025em;
}

.case-body p {
  margin-bottom: 1rem;
  font-size: 1rem;
  line-height: 1.625;
}

@media (min-width: 640px) {
  .case-body p { font-size: 1.0625rem; }
}

.case-body strong {
  font-weight: 600;
  color: var(--pf-text);
}

.case-body ul {
  margin-bottom: 1rem;
  padding-left: 0;
  list-style: none;
}

.case-body li {
  position: relative;
  padding-left: 1rem;
  margin-bottom: 0.5rem;
  font-size: 1rem;
  line-height: 1.5;
}

.case-body li::before {
  content: "·";
  position: absolute;
  left: 0;
  color: var(--pf-muted-3);
}

/* ── Contact ── */
.contact {
  text-align: center;
  padding-bottom: 6rem;
}

.contact-title {
  font-size: clamp(2.5rem, 8vw, 5rem);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.04em;
  line-height: 0.95;
  color: var(--pf-text);
  margin-bottom: 2rem;
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}

/* ── Footer ── */
.footer {
  border-top: 1px solid var(--pf-border);
  padding: 2.5rem 0 max(2rem, env(safe-area-inset-bottom));
}

.footer-nav {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.footer-link {
  font-size: 0.875rem;
  color: var(--pf-muted-2);
  transition: color 0.2s;
}

.footer-link:hover { color: var(--pf-text); }

.footer-location,
.footer-copy {
  font-size: 0.875rem;
  color: var(--pf-muted-3);
  margin-top: 0.25rem;
}

/* ── Site lock & onboarding ── */
.site-lock {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background-color: var(--pf-bg);
  color: var(--pf-text);
  overflow-y: auto;
}

.site-lock.hidden { display: none; }

body.site-locked { overflow: hidden; }

.site-content--locked {
  pointer-events: none;
}

.site-lock:not(.hidden) ~ .portfolio-theme,
.portfolio-theme:not(.site-content--locked) {
  pointer-events: auto;
}

#portfolio-root.site-content--locked {
  visibility: hidden;
}

.gate--fullscreen {
  max-width: 32rem;
  width: 100%;
  margin: auto;
}

.onboarding-step--wide {
  max-width: 40rem;
}

.onboard-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.onboard-mode-cards {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

.onboard-mode-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
  width: 100%;
  padding: 1.125rem 1.25rem;
  border-radius: 1rem;
  border: 1px solid var(--pf-border);
  background-color: var(--pf-surface);
  text-align: left;
  transition: border-color 0.2s, background-color 0.2s;
  cursor: pointer;
}

.onboard-mode-card:hover {
  border-color: var(--pf-border-strong);
  background-color: var(--pf-surface-2);
}

.onboard-mode-card-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--pf-text);
}

.onboard-mode-card-desc {
  font-size: 0.8125rem;
  font-weight: 300;
  color: var(--pf-muted-2);
  line-height: 1.45;
}

.lang-pick-title {
  margin-bottom: 0.5rem;
}

.lang-pick-desc {
  margin-top: 0;
  font-weight: 400;
}

.gate-submit--secondary {
  background-color: transparent;
  border: 1px solid var(--pf-border-strong);
}

.gate-submit--secondary:hover {
  background-color: var(--pf-surface-2);
  color: var(--pf-text);
}

.onboard-tag-groups {
  text-align: left;
  margin-bottom: 1.5rem;
}

.onboard-tag-group + .onboard-tag-group {
  margin-top: 1.5rem;
}

.onboard-tag-group-title {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pf-muted-3);
  margin-bottom: 0.75rem;
}

.tag-chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag-chip {
  padding: 0.5rem 0.875rem;
  border-radius: 9999px;
  font-size: 0.8125rem;
  font-weight: 500;
  border: 1px solid var(--pf-border-strong);
  background-color: var(--pf-surface);
  color: var(--pf-muted-2);
  transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}

.tag-chip:hover {
  border-color: var(--pf-muted-3);
  color: var(--pf-text);
}

.tag-chip--active,
.tag-chip[aria-pressed="true"] {
  background-color: var(--pf-btn-hover-bg);
  color: var(--pf-btn-hover-text);
  border-color: transparent;
}
