:root {
  --cream:   #F1EAD8;
  --tan:     #D5C7AD;
  --sage:    #BEC5A4;
  --olive:   #BABE75;
  --brown:   #68604D;
  --shadow:  0 16px 40px rgba(104, 96, 77, 0.18);
  --radius:  10px;
}

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

html, body {
  width: 100%; height: 100%;
  font-family: 'DM Mono', monospace;
  color: var(--brown);
  background: var(--brown);
  overflow: hidden;
  cursor: default;
}

/* GRID BG */
body::before {
  content: "";
  position: fixed; inset: 0;
  background-image:
    linear-gradient(rgba(186,190,117,0.1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(186,190,117,0.1) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  z-index: 0;
}

/* Warm glow blobs */
body::after {
  content: "";
  position: fixed; inset: 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(186,190,117,0.12), transparent 35%),
    radial-gradient(circle at 75% 70%, rgba(213,199,173,0.12), transparent 35%);
  pointer-events: none;
  z-index: 0;
}

/* NAV */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  background: rgba(104, 96, 77, 0.7);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(186,190,117,0.25);
}

.nav-name {
  font-family: 'DM Serif Display', serif;
  font-size: 1.4rem;
  color: var(--cream);
  letter-spacing: 0.05em;
}

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

.nav-btn {
  background: rgba(241,234,216,0.08);
  border: 1px solid rgba(186,190,117,0.3);
  color: var(--tan);
  font-family: 'DM Mono', monospace;
  font-size: 0.78rem;
  padding: 7px 14px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 180ms ease;
  letter-spacing: 0.03em;
}

.nav-btn:hover {
  background: var(--olive);
  color: var(--brown);
  border-color: var(--olive);
}

.nav-btn.active {
  background: var(--cream);
  color: var(--brown);
  border-color: var(--cream);
}

/* VIEWPORT & WORLD */
#viewport {
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: 1;
  padding-top: 56px;
}

#world {
  position: absolute;
  width: 4800px;
  height: 4200px;
  left: 0; top: 0;
  transform: translate(0px, 0px);
  transition: transform 850ms cubic-bezier(0.22, 1, 0.36, 1);
  transform-origin: top left;
}

/* SECTIONS */
.section {
  position: absolute;
  width: 480px;
  background: var(--cream);
  border: 1.5px solid var(--olive);
  border-radius: var(--radius);
  padding: 32px 30px 30px;
  box-shadow: var(--shadow);
  transition: border-color 500ms ease, box-shadow 500ms ease, opacity 500ms ease, transform 500ms ease;
}

.section.active {
  border-color: var(--olive);
  box-shadow: 0 20px 60px rgba(104,96,77,0.25), 0 0 0 3px rgba(186,190,117,0.2);
  opacity: 1;
  transform: scale(1);
}

.section.dim {
  opacity: 0.22;
  transform: scale(0.97);
}

.skills-section {
  width: 340px;
}

.contact-section {
  width: 420px;
}

/* TAG */
.tag {
  display: inline-block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--brown);
  background: var(--sage);
  border: 1px solid var(--olive);
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 16px;
  font-weight: 500;
}

/* HERO */
.hero-name {
  font-family: 'DM Serif Display', serif;
  font-size: 4.5rem;
  line-height: 1;
  color: var(--brown);
  margin-bottom: 10px;
}

.hero-sub {
  font-family: 'DM Serif Display', serif;
  font-size: 1.2rem;
  line-height: 1.5;
  color: var(--brown);
  margin-bottom: 16px;
}

.hero-sub em {
  font-style: italic;
  color: var(--brown);
  opacity: 0.75;
}

.hero-body {
  font-size: 0.88rem;
  line-height: 1.65;
  color: rgba(104,96,77,0.8);
  margin-bottom: 24px;
}

.hero-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.pill-btn {
  font-family: 'DM Mono', monospace;
  font-size: 0.8rem;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1.5px solid var(--olive);
  background: transparent;
  color: var(--brown);
  cursor: pointer;
  transition: all 180ms ease;
}

.pill-btn:hover {
  background: var(--olive);
  color: var(--brown);
}

.pill-btn.primary {
  background: var(--olive);
  color: var(--brown);
}

.pill-btn.primary:hover {
  background: var(--brown);
  color: var(--cream);
  border-color: var(--brown);
}

/* SECTION TITLES */
.section-title {
  font-family: 'DM Serif Display', serif;
  font-size: 2rem;
  color: var(--brown);
  margin-bottom: 10px;
  line-height: 1.1;
}

.section-body {
  font-size: 0.87rem;
  line-height: 1.65;
  color: rgba(104,96,77,0.8);
  margin-bottom: 22px;
}

/* PROJECT CARDS */
.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

.project-card {
  background: var(--tan);
  border: 1px solid rgba(186,190,117,0.5);
  border-radius: 8px;
  padding: 14px 16px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.project-card-body {
  flex: 1;
  min-width: 0;
}

.project-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 24px rgba(104,96,77,0.15);
}

.project-card.coming-soon {
  opacity: 0.55;
}

.card-label {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--brown);
  background: var(--sage);
  display: inline-block;
  padding: 3px 8px;
  border-radius: 999px;
  margin-bottom: 10px;
}

.project-card h3 {
  font-family: 'DM Serif Display', serif;
  font-size: 1rem;
  color: var(--brown);
  margin-bottom: 6px;
}

.project-card p {
  font-size: 0.78rem;
  line-height: 1.5;
  color: rgba(104,96,77,0.75);
  margin-bottom: 10px;
}

.card-link {
  font-size: 0.76rem;
  color: var(--brown);
  text-decoration: none;
  border-bottom: 1px solid var(--olive);
  padding-bottom: 1px;
  transition: color 150ms ease;
}

.card-link:hover { color: var(--olive); }

/* RESUME BTN */
.resume-btn {
  display: inline-block;
  font-family: 'DM Mono', monospace;
  font-size: 0.8rem;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--brown);
  color: var(--cream);
  text-decoration: none;
  transition: background 180ms ease;
}

.resume-btn:hover {
  background: var(--olive);
  color: var(--brown);
}

/* SKILLS */
.skills-group {
  margin-bottom: 18px;
}

.skill-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(104,96,77,0.6);
  margin-bottom: 8px;
}

.skill-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.skill-pills span {
  font-size: 0.76rem;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--tan);
  border: 1px solid rgba(186,190,117,0.5);
  color: var(--brown);
}

/* CONTACT */
.contact-links {
  display: grid;
  gap: 10px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 8px;
  background: var(--tan);
  border: 1px solid rgba(186,190,117,0.4);
  text-decoration: none;
  color: var(--brown);
  font-size: 0.85rem;
  transition: all 180ms ease;
}

.contact-item:hover {
  background: var(--olive);
  border-color: var(--olive);
  transform: translateX(4px);
}

.contact-icon {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: var(--sage);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 500;
  flex-shrink: 0;
  line-height: 28px;
  text-align: center;
}

/* DECO LINES */
.deco-lines {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: visible;
  width: 5000px;
  height: 5000px;
}

/* BOTTOM HUD */
.bottom-hud {
  position: fixed;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  background: rgba(104,96,77,0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(186,190,117,0.25);
  border-radius: 999px;
  padding: 8px 18px;
}

.hud-hint {
  font-size: 0.72rem;
  color: rgba(241,234,216,0.65);
  letter-spacing: 0.04em;
}

/* DRAG CURSOR */
body.dragging { cursor: grabbing; }

@media (max-width: 768px) {
  .nav-links { gap: 4px; }
  .nav-btn { font-size: 0.7rem; padding: 6px 10px; }
}

.about-divider {
  width: 100%;
  height: 1px;
  background: rgba(186,190,117,0.4);
  margin: 24px 0 20px;
}

/* RESUME SECTION */
.resume-section {
  width: 700px;
}

.resume-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.resume-card {
  background: var(--tan);
  border: 1px solid rgba(186,190,117,0.5);
  border-radius: 8px;
  overflow: hidden;
}

.resume-preview {
  position: relative;
  width: 100%;
  aspect-ratio: 8.5 / 11;
  background: var(--cream);
  overflow: hidden;
}

.resume-preview iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
  z-index: 1;
}

.resume-preview-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  padding: 20px;
  z-index: 0;
}

.resume-preview-fallback span {
  font-size: 2rem;
}

.resume-preview-fallback p {
  font-family: 'DM Serif Display', serif;
  font-size: 0.95rem;
  color: var(--brown);
  margin: 0;
}

.resume-preview-fallback small {
  font-size: 0.72rem;
  color: rgba(104,96,77,0.6);
}

.resume-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-top: 1px solid rgba(186,190,117,0.4);
}

/* HERO HANDLE */
.hero-handle {
  font-family: 'DM Mono', monospace;
  font-size: 0.85rem;
  color: rgba(104,96,77,0.55);
  margin-bottom: 14px;
  letter-spacing: 0.04em;
}

/* HERO HANDLE */
.hero-handle {
  font-family: 'DM Mono', monospace;
  font-size: 0.85rem;
  color: rgba(104,96,77,0.6);
  margin-bottom: 16px;
  margin-top: -4px;
  letter-spacing: 0.04em;
}
