@import url("https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,600;9..144,700&family=Space+Grotesk:wght@400;500;600&display=swap");

:root {
  color-scheme: light;
  --ink: #1c2722;
  --ink-muted: #4a5a50;
  --accent: #c48b43;
  --accent-deep: #7b4c18;
  --accent-cool: #4f7d73;
  --accent-cool-soft: rgba(79, 125, 115, 0.18);
  --paper: #f8f2e8;
  --paper-2: #f2ece2;
  --surface: #ffffff;
  --surface-alt: #f3efe6;
  --surface-strong: #e7dfd2;
  --border: #d9d3c6;
  --shadow: 0 24px 56px rgba(20, 28, 24, 0.14);
  --shadow-soft: 0 14px 28px rgba(20, 28, 24, 0.08);
  --radius: 22px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Space Grotesk", system-ui, sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at top, #f9f2e8 0%, #efe9de 45%, #e7dfd1 100%);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

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

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.page {
  min-height: 100vh;
  position: relative;
  overflow: visible;
}

.page::before {
  content: "";
  position: absolute;
  inset: -10% -10% auto -10%;
  height: 55%;
  background:
    radial-gradient(circle at 12% 18%, rgba(196, 139, 67, 0.22), transparent 60%),
    radial-gradient(circle at 70% 28%, rgba(90, 120, 96, 0.18), transparent 55%);
  z-index: 0;
  pointer-events: none;
}

.page::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(
      90deg,
      rgba(28, 39, 34, 0.03) 0,
      rgba(28, 39, 34, 0.03) 1px,
      transparent 1px,
      transparent 10px
    ),
    linear-gradient(
      180deg,
      rgba(28, 39, 34, 0.02) 0,
      rgba(28, 39, 34, 0.02) 1px,
      transparent 1px,
      transparent 10px
    );
  opacity: 0.5;
  pointer-events: none;
  z-index: 0;
}

.nav,
.hero,
main,
.footer {
  position: relative;
  z-index: 1;
  width: min(1120px, 100%);
  margin: 0 auto;
  padding: 0 clamp(20px, 6vw, 88px);
}

.hero {
  padding-top: clamp(36px, 6vw, 64px);
  padding-bottom: clamp(70px, 10vw, 110px);
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-soft);
  margin-bottom: 48px;
  position: sticky;
  top: 18px;
  z-index: 10;
  transition: background 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.nav--scrolled {
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(216, 168, 94, 0.35);
  box-shadow: 0 18px 40px rgba(20, 28, 24, 0.18);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.logo {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--ink);
  color: #f7f2e7;
  display: grid;
  place-items: center;
  font-family: "Fraunces", serif;
  font-size: 18px;
  letter-spacing: 1px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.2);
}

.nav-links {
  display: flex;
  gap: 24px;
  font-weight: 500;
  color: var(--ink-muted);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.7);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
}

.lang-btn {
  border: none;
  background: transparent;
  color: var(--ink-muted);
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.18em;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.lang-btn.is-active,
.lang-btn:hover {
  background: var(--ink);
  color: #f7f2e7;
}

.nav-links a {
  position: relative;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 100%;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.nav-links a:hover::after {
  transform: scaleX(1);
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 42px;
  align-items: center;
}

.hero-copy {
  max-width: 560px;
}

.hero-photo-card {
  width: 100%;
  min-height: 360px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  background: linear-gradient(160deg, #ffffff 0%, #f3eadf 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(18px, 4vw, 28px);
}

.hero-photo-frame {
  width: 100%;
  height: 100%;
  border-radius: 16px;
  overflow: hidden;
  background: #ffffff;
  display: grid;
  place-items: center;
  box-shadow: inset 0 0 0 1px rgba(28, 39, 34, 0.08);
}

.hero-photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  background: transparent;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.3em;
  font-size: 11px;
  color: var(--accent-deep);
  margin-bottom: 18px;
}

h1,
h2 {
  font-family: "Fraunces", serif;
}

h1 {
  font-size: clamp(36px, 5.4vw, 58px);
  line-height: 1.05;
  margin-bottom: 18px;
}

h1 span {
  display: block;
  font-size: clamp(18px, 2.4vw, 26px);
  font-weight: 600;
  color: var(--ink-muted);
  margin-top: 12px;
}

.lead {
  font-size: 18px;
  max-width: 560px;
  margin-bottom: 28px;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}

.button {
  padding: 14px 22px;
  border-radius: 999px;
  font-weight: 600;
  border: 1px solid transparent;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease,
    border-color 0.2s ease;
}

.button.primary {
  background: var(--ink);
  color: #f8f2e8;
  box-shadow: 0 18px 32px rgba(29, 42, 36, 0.2);
}

.button.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 28px 36px rgba(29, 42, 36, 0.26);
}

.button.ghost {
  border-color: var(--border);
  color: var(--ink);
  background: rgba(255, 255, 255, 0.8);
}

.button.ghost:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--ink-muted);
  font-weight: 500;
}

.hero-card {
  background: linear-gradient(160deg, #ffffff 0%, #f6f1e8 100%);
  padding: 30px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  backdrop-filter: blur(6px);
  animation: floatIn 0.9s ease both;
  margin-top: 28px;
}

.card-top {
  margin-bottom: 20px;
}

.card-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--accent-deep);
  margin-bottom: 10px;
}

.card-subtitle {
  font-family: "Fraunces", serif;
  font-size: 22px;
}

.focus-list {
  list-style: none;
  display: grid;
  gap: 18px;
}

.project-list {
  gap: 14px;
}

.focus-list li {
  padding: 0;
}

.project-link {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid transparent;
  background: rgba(255, 255, 255, 0.5);
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.project-link strong {
  font-size: 16px;
}

.project-link span {
  color: var(--ink-muted);
  font-size: 14px;
}

.project-link:hover {
  border-color: var(--accent);
  background: rgba(255, 255, 255, 0.85);
  transform: translateY(-1px);
}

.focus-list strong {
  font-size: 16px;
}

.focus-list span {
  color: var(--ink-muted);
  font-size: 14px;
}

.section {
  padding: clamp(50px, 7vw, 90px) 0;
  border-top: 1px solid var(--border);
  scroll-margin-top: 120px;
}

.js [data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
  transition-delay: var(--reveal-delay, 0ms);
}

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

.section:first-of-type {
  border-top: none;
}

.section:target {
  border-top-color: var(--accent);
}

.section:target .section-title::after {
  width: 64px;
}

.section-header {
  margin-bottom: 32px;
}

.section-title {
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 11px;
  color: var(--accent-deep);
  margin-bottom: 12px;
  position: relative;
}

.section-title::after {
  content: "";
  display: block;
  width: 44px;
  height: 2px;
  background: var(--accent);
  margin-top: 10px;
}

.project-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.project-card {
  display: grid;
  gap: 12px;
  padding: 20px;
  border-radius: 18px;
  border: 1px solid var(--border);
  background: linear-gradient(140deg, #ffffff 0%, #f6f0e6 100%);
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  position: relative;
  overflow: hidden;
}

.project-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 18px;
  right: 18px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0.6;
}

.project-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}

.project-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--accent-deep);
}

.project-tag {
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(196, 139, 67, 0.15);
}

.project-tag.is-data {
  background: rgba(196, 139, 67, 0.2);
}

.project-tag.is-ops {
  background: rgba(123, 76, 24, 0.14);
}

.project-tag.is-live {
  background: var(--accent-cool-soft);
}

.project-index {
  font-weight: 600;
}

.project-card h3 {
  font-family: "Fraunces", serif;
  font-size: 20px;
}

.project-card p {
  color: var(--ink-muted);
  font-size: 14px;
}

.project-card.is-live {
  border-color: rgba(79, 125, 115, 0.45);
}

.project-card.is-live::before {
  background: linear-gradient(90deg, transparent, var(--accent-cool), transparent);
  opacity: 0.8;
}

.about-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  color: var(--ink-muted);
  font-size: 17px;
}

.experience-grid,
.education-grid,
.cert-grid,
.language-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.card {
  background: var(--surface);
  padding: 24px;
  border-radius: 18px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.card.small {
  background: var(--surface-alt);
}

.card-role {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 6px;
}

.card-company {
  color: var(--ink-muted);
  margin-bottom: 4px;
}

.card-time {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent-deep);
  margin-bottom: 14px;
}

.card-body {
  color: var(--ink-muted);
  font-size: 15px;
}

.chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.chip-grid span {
  background: var(--surface-strong);
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 13px;
}

.contact {
  padding-bottom: clamp(70px, 9vw, 120px);
}

.contact-card {
  background: linear-gradient(130deg, #1d2a24 0%, #2a3b31 100%);
  color: #f7f2e7;
  padding: 36px;
  border-radius: var(--radius);
  box-shadow: 0 28px 50px rgba(24, 32, 28, 0.35);
}

.contact-card p {
  font-size: 18px;
  margin-bottom: 20px;
}

.contact-card .button.primary {
  background: var(--accent);
  color: #1c1407;
}

.contact-card .button.ghost {
  border-color: rgba(255, 255, 255, 0.4);
  color: #f7f2e7;
  background: transparent;
}

.footer {
  padding: 30px 0 50px;
  color: var(--ink-muted);
  font-size: 14px;
}

@keyframes floatIn {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 720px) {
  .nav {
    flex-direction: column;
    align-items: flex-start;
    padding: 14px 18px;
    border-radius: 18px;
  }

  .nav-right {
    width: 100%;
    justify-content: flex-start;
  }

  .nav-links {
    flex-wrap: wrap;
    gap: 14px;
  }

  .meta-row {
    flex-direction: column;
  }

  .contact-card {
    padding: 28px;
  }

}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

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