/* ============================================================
   NAVIGATION
   ============================================================ */
nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(15,30,48,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(201,168,76,0.25);
  font-family: var(--font-heading);
}

.nav-inner {
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 0 20px;
}

.nav-btn {
  background: none;
  border: none;
  color: var(--gold-mid);
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  padding: 18px 22px;
  cursor: pointer;
  position: relative;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  transition: color 0.3s ease;
  white-space: nowrap;
  opacity: 0.6;
}

.nav-btn:hover {
  opacity: 1;
}

.nav-btn.active {
  color: var(--gold-light);
  opacity: 1;
}

/* Slim sliding gold underline */
.nav-btn::after {
  content: '';
  position: absolute;
  bottom: 10px;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--gold-dark);
  transition: width 0.3s ease, left 0.3s ease;
}

.nav-btn.active::after {
  width: 60%;
  left: 20%;
}

.nav-btn:hover::after {
  width: 40%;
  left: 30%;
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--gold-mid);
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  padding: 14px 20px;
  cursor: pointer;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  opacity: 0.7;
  margin: 0 auto;
}

/* Nav button styled as a link (Field Notes) */
.nav-btn-link {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

/* Nav card styled as a link */
.nav-card-link {
  text-decoration: none;
}

/* ============================================================
   PAGE CONTAINER
   ============================================================ */
.page {
  display: none;
  min-height: calc(100vh - 70px);
  padding: 40px 20px 60px;
  position: relative;
  overflow: hidden;
}
.page.active {
  display: block;
}

.page-inner {
  max-width: 960px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

/* ============================================================
   HOME PAGE
   ============================================================ */
#page-home {
  height: 100vh;
  height: 100dvh;
  min-height: 0;
  padding: 0;
  box-sizing: border-box;
}

#page-home.active {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

#page-home .page-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
}

.scroll-cue {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-heading);
  font-size: 12px;
  color: var(--gold-mid);
  letter-spacing: 2px;
  text-transform: uppercase;
  opacity: 0.5;
  animation: bobDown 2s ease-in-out infinite;
}

@keyframes bobDown {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

.home-hero {
  text-align: center;
  padding: 40px 0 20px;
}

.home-hero .hero-cap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 130px;
  height: 130px;
  font-family: var(--font-display);
  font-size: 108px;
  font-weight: 900;
  color: var(--gold-dark);
  background: linear-gradient(135deg, var(--deep-blue) 0%, #162a40 100%);
  border: 4px solid var(--gold-dark);
  position: relative;
  margin: 0 auto 20px;
  box-shadow:
    inset 0 0 30px rgba(201,168,76,0.1),
    0 4px 20px rgba(0,0,0,0.25),
    0 0 0 8px var(--page-bg),
    0 0 0 10px var(--gold-dark);
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
.home-hero .hero-cap::before {
  content: '';
  position: absolute;
  top: 6px; left: 6px; right: 6px; bottom: 6px;
  border: 1px solid var(--gold-mid);
  opacity: 0.5;
}
.home-hero .hero-cap::after {
  content: '\2766 \2766';
  position: absolute;
  bottom: -22px;
  font-size: 16px;
  color: var(--gold-dark);
  opacity: 0.6;
  letter-spacing: 10px;
}

.hero-vines {
  position: relative;
  display: inline-block;
}
.hero-vines::before {
  content: '\2767';
  position: absolute;
  top: -8px;
  left: -30px;
  font-size: 20px;
  color: var(--gold-dark);
  opacity: 0.5;
}
.hero-vines::after {
  content: '\2767';
  position: absolute;
  top: -8px;
  right: -30px;
  font-size: 20px;
  color: var(--gold-dark);
  opacity: 0.5;
}

.home-hero h1 {
  font-family: var(--font-heading);
  font-size: 42px;
  font-weight: 700;
  color: var(--parchment-light);
  margin-bottom: 6px;
  letter-spacing: 2px;
}

.home-hero .subtitle {
  font-family: var(--font-heading);
  font-size: 18px;
  color: var(--gold-mid);
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 30px;
}

.home-intro {
  max-width: 680px;
  margin: 0 auto 40px;
  font-size: 19px;
  text-align: center;
  color: #1a1a1e;
  line-height: 1.8;
  font-weight: 300;
}

/* Navigation cards grid */
.nav-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
  margin-top: 20px;
}

.nav-card {
  position: relative;
  border: 2px solid var(--gold-dark);
  padding: 28px 20px 24px;
  text-align: center;
  cursor: pointer;
  background: rgba(240,230,208,0.5);
  transition: all 0.3s ease;
  font-family: var(--font-heading);
}
.nav-card::before {
  content: '';
  position: absolute;
  top: 4px; left: 4px; right: 4px; bottom: 4px;
  border: 1px solid rgba(201,168,76,0.4);
  pointer-events: none;
  transition: border-color 0.3s;
}
.nav-card:hover {
  background: rgba(240,230,208,0.7);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(201,168,76,0.2);
}
.nav-card:hover::before {
  border-color: var(--gold-dark);
}
.nav-card .card-ornament {
  font-size: 16px;
  color: var(--gold-dark);
  margin-bottom: 8px;
  opacity: 0.6;
}
.nav-card h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--deep-blue);
  letter-spacing: 1px;
  margin-bottom: 6px;
}
.nav-card p {
  font-family: var(--font-body);
  font-size: 14px;
  color: #1a1a1e;
  font-weight: 300;
}

/* ============================================================
   EXPERIENCE PAGE — TIMELINE
   ============================================================ */
.timeline {
  position: relative;
  padding-left: 40px;
}
.timeline::after {
  content: '\2767\a\2E19\a\2766\a\2767\a\2E19\a\2766\a\2767\a\2E19\a\2766\a\2767\a\2E19\a\2766\a\2767\a\2E19';
  white-space: pre;
  position: absolute;
  left: 2px;
  top: 20px;
  font-size: 12px;
  color: var(--forest-green);
  opacity: 0.2;
  line-height: 4.6;
  pointer-events: none;
}

/* SVG vine overlay for the timeline */
.timeline-vine-svg {
  position: absolute;
  left: 0;
  top: 0;
  width: 30px;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.timeline-entry {
  position: relative;
  margin-bottom: 40px;
  border: 2px solid var(--gold-dark);
  padding: 28px 28px 24px;
  background: rgba(240,230,208,0.5);
}
.timeline-entry::before {
  content: '';
  position: absolute;
  top: 5px; left: 5px; right: 5px; bottom: 5px;
  border: 1px solid rgba(201,168,76,0.3);
  pointer-events: none;
}
.timeline-entry::after {
  content: '\2726';
  position: absolute;
  left: -34px;
  top: 24px;
  font-size: 14px;
  color: var(--gold-dark);
}

.entry-date-label {
  font-family: var(--font-heading);
  font-size: 14px;
  color: var(--parchment-dark);
  opacity: 0.6;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 8px;
  padding-left: 4px;
}

.entry-date {
  font-family: var(--font-heading);
  font-size: 13px;
  color: var(--rubric-red);
  font-weight: 600;
  letter-spacing: 1px;
  margin-bottom: 4px;
  text-transform: uppercase;
}

.entry-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 4px;
}

.entry-header .entry-title {
  margin-bottom: 0;
}

.entry-header .entry-company {
  margin-bottom: 0;
  text-align: right;
  flex-shrink: 0;
}

.entry-title {
  font-family: var(--font-heading);
  font-size: 20px;
  color: var(--blue-mid);
  font-weight: 700;
  margin-bottom: 4px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  flex-wrap: wrap;
}

.entry-company {
  font-family: var(--font-heading);
  font-size: 15px;
  color: var(--deep-blue);
  font-weight: 600;
  margin-bottom: 10px;
  letter-spacing: 0.5px;
}

.entry-desc {
  font-size: 16px;
  line-height: 1.7;
  color: #1a1a1e;
}
.entry-desc ul {
  list-style: none;
  padding-left: 0;
}
.entry-desc ul li {
  position: relative;
  padding-left: 22px;
  margin-bottom: 6px;
}
.entry-desc ul li::before {
  content: '\2726';
  position: absolute;
  left: 0;
  color: var(--gold-dark);
  font-size: 10px;
  top: 4px;
}

/* ============================================================
   PROJECTS PAGE
   ============================================================ */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
}

/* Card flip container */
.project-card {
  position: relative;
  perspective: 800px;
  min-height: 220px;
}
.project-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.6s ease;
  transform-style: preserve-3d;
}
.project-card.flipped .project-card-inner {
  transform: rotateY(180deg);
}

.project-card-front,
.project-card-back {
  position: relative;
  backface-visibility: hidden;
  border: 2px solid var(--gold-dark);
  padding: 32px 24px 24px;
  background: rgba(240,230,208,0.5);
  cursor: pointer;
}
.project-card-front::before,
.project-card-back::before {
  content: '';
  position: absolute;
  top: 5px; left: 5px; right: 5px; bottom: 5px;
  border: 1px solid rgba(201,168,76,0.3);
  pointer-events: none;
  transition: border-color 0.3s;
}

/* Top center rosette */
/* Top center accent — now in HTML */
.project-card-emoji {
  position: absolute;
  top: -18px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 20px;
  background: var(--parchment-light);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--gold-dark);
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
  line-height: 1;
}

.project-card-front:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 24px rgba(201,168,76,0.25), 0 0 0 1px var(--gold-mid);
  background: rgba(240,230,208,0.6);
}
.project-card-front:hover::before {
  border-color: var(--gold-dark);
}

.project-card-back {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  transform: rotateY(180deg);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  background: rgba(30,58,92,0.95);
  border-color: var(--gold-mid);
}
.project-card-back h4 {
  font-family: var(--font-heading);
  font-size: 16px;
  color: var(--gold-light);
  margin-bottom: 12px;
}
.project-card-back p {
  font-size: 14px;
  color: var(--parchment-light);
  line-height: 1.6;
  max-width: 260px;
}
.project-card-back .flip-hint {
  margin-top: 16px;
  font-size: 12px;
  color: var(--gold-mid);
  opacity: 0.7;
}

.project-card h3 {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  color: var(--deep-blue);
  margin-bottom: 8px;
}

.project-card .project-desc {
  font-size: 15px;
  color: #1a1a1e;
  line-height: 1.6;
  margin-bottom: 14px;
}

.flip-hint-front {
  font-size: 11px;
  color: var(--gold-dark);
  opacity: 0.6;
  text-align: center;
  margin-top: 12px;
  font-family: var(--font-heading);
  letter-spacing: 0.5px;
}

/* ============================================================
   ABOUT PAGE
   ============================================================ */
.about-bio {
  font-size: 18px;
  line-height: 1.9;
  color: #1a1a1e;
  margin-bottom: 10px;
}

.skills-section {
  margin-top: 0;
}
.skills-section h3 {
  font-family: var(--font-heading);
  font-size: 20px;
  color: var(--deep-blue);
  font-weight: 700;
  margin-bottom: 20px;
  text-align: center;
}

.skills-columns {
  display: flex;
  gap: 0;
  align-items: flex-start;
}
.skills-col {
  flex: 1;
  padding: 0 24px;
}
.skills-col:first-child {
  padding-left: 0;
}
.skills-col:last-child {
  padding-right: 0;
}

.skills-divider {
  width: 2px;
  background: repeating-linear-gradient(
    180deg,
    var(--gold-dark) 0px,
    var(--gold-dark) 8px,
    transparent 8px,
    transparent 16px
  );
  align-self: stretch;
  position: relative;
  margin: 0 4px;
}
.skills-divider::before {
  content: '\2766';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 14px;
  color: var(--gold-dark);
  background: rgba(240,230,208,0.85);
  padding: 4px 0;
}

.skill-item {
  font-size: 16px;
  color: var(--ink);
  padding: 6px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}
.skill-item::before {
  content: '\2726';
  color: var(--gold-dark);
  font-size: 11px;
  flex-shrink: 0;
}

.interests-section h3 {
  font-family: var(--font-heading);
  font-size: 20px;
  color: var(--deep-blue);
  font-weight: 700;
  margin-bottom: 20px;
  text-align: center;
}

.interests-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
}

/* ============================================================
   CONTACT PAGE
   ============================================================ */
.contact-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
  max-width: 800px;
  margin: 0 auto;
}

.contact-card {
  position: relative;
  border: 2px solid var(--gold-dark);
  padding: 32px 24px;
  text-align: center;
  text-decoration: none;
  color: var(--ink);
  transition: all 0.3s ease;
  display: block;
  background: rgba(240,230,208,0.5);
}
.contact-card::before {
  content: '';
  position: absolute;
  top: 5px; left: 5px; right: 5px; bottom: 5px;
  border: 1px solid rgba(201,168,76,0.3);
  pointer-events: none;
  transition: border-color 0.3s;
}
.contact-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(201,168,76,0.2);
  background: rgba(240,230,208,0.6);
}
.contact-card:hover::before {
  border-color: var(--gold-dark);
}

.contact-card .contact-initial {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 700;
  color: var(--gold-dark);
  background: var(--deep-blue);
  border: 2px solid var(--gold-dark);
  margin-bottom: 14px;
  position: relative;
}
.contact-card .contact-initial::before {
  content: '';
  position: absolute;
  top: 3px; left: 3px; right: 3px; bottom: 3px;
  border: 1px solid rgba(201,168,76,0.4);
}

.contact-card h3 {
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 700;
  color: var(--deep-blue);
  margin-bottom: 6px;
}
.contact-card p {
  font-size: 14px;
  color: #1a1a1e;
  font-weight: 300;
}

.contact-footer-vine {
  text-align: center;
  margin-top: 50px;
  font-size: 14px;
  color: var(--gold-dark);
  opacity: 0.35;
  user-select: none;
  letter-spacing: 4px;
}

/* ============================================================
   FOOTER
   ============================================================ */
/* Hide footer when home page is active */
body:has(#page-home.active) footer {
  display: none;
}

body:has(#page-home.active) {
  overflow: hidden;
}

footer {
  text-align: center;
  padding: 20px;
  font-family: var(--font-heading);
  font-size: 12px;
  color: var(--gold-dark);
  opacity: 0.5;
  letter-spacing: 1px;
}

/* ============================================================
   PARTICLES CANVAS
   ============================================================ */
#particles-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

/* ============================================================
   FIELD NOTES — NAV
   ============================================================ */
.fieldnotes-nav .nav-inner {
  justify-content: center;
  gap: 8px;
}

.nav-link {
  color: var(--gold-mid);
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 600;
  padding: 18px 22px;
  text-decoration: none;
  position: relative;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  transition: color 0.3s ease;
  opacity: 0.6;
}

.nav-link:hover {
  opacity: 1;
  color: var(--gold-light);
}

.nav-link.active {
  color: var(--gold-light);
  opacity: 1;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 10px;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--gold-dark);
  transition: width 0.3s ease, left 0.3s ease;
}

.nav-link.active::after {
  width: 60%;
  left: 20%;
}

.nav-link:hover::after {
  width: 40%;
  left: 30%;
}

/* ============================================================
   FIELD NOTES — POST PAGE
   ============================================================ */
.post-page {
  min-height: calc(100vh - 70px);
  padding: 40px 20px 60px;
  position: relative;
  overflow: hidden;
}

.post-container {
  max-width: 760px;
  margin: 0 auto;
}

.post-header {
  margin-bottom: 10px;
}

.post-date {
  font-family: var(--font-heading);
  font-size: 13px;
  color: var(--rubric-red);
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.post-title {
  font-size: 28px;
  margin-bottom: 16px;
  line-height: 1.3;
}

.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.post-body {
  font-size: 18px;
  line-height: 1.9;
  color: #1a1a1e;
}

.post-body h2 {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 700;
  color: var(--deep-blue);
  margin: 32px 0 14px;
}

.post-body h3 {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 700;
  color: var(--blue-mid);
  margin: 24px 0 10px;
}

.post-body p {
  margin-bottom: 16px;
}

.post-body blockquote {
  border-left: 3px solid var(--gold-dark);
  padding-left: 20px;
  margin: 20px 0;
  font-style: italic;
  color: var(--blue-mid);
}

.post-body code {
  font-family: 'Courier New', monospace;
  font-size: 0.9em;
  background: rgba(30,58,92,0.08);
  padding: 2px 6px;
  border: 1px solid rgba(201,168,76,0.2);
}

.post-body pre {
  background: rgba(30,58,92,0.06);
  border: 1px solid rgba(201,168,76,0.2);
  padding: 16px 20px;
  overflow-x: auto;
  margin: 20px 0;
}

.post-body pre code {
  background: none;
  border: none;
  padding: 0;
}

.post-body ul, .post-body ol {
  padding-left: 24px;
  margin-bottom: 16px;
}

.post-body li {
  margin-bottom: 6px;
}

/* ============================================================
   FIELD NOTES — POST NAV (prev/next)
   ============================================================ */
.post-nav {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 10px;
}

.post-nav-link {
  font-family: var(--font-heading);
  font-size: 14px;
  color: var(--gold-dark);
  text-decoration: none;
  transition: color 0.3s ease;
  letter-spacing: 0.5px;
}

.post-nav-link:hover {
  color: var(--gold-light);
}

.post-nav-prev {
  text-align: left;
}

.post-nav-next {
  text-align: right;
  margin-left: auto;
}

/* ============================================================
   FIELD NOTES — BACK LINK
   ============================================================ */
.back-link-wrap {
  text-align: center;
  margin-top: 30px;
}

.back-link {
  font-family: var(--font-heading);
  font-size: 14px;
  color: var(--gold-dark);
  text-decoration: none;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  transition: color 0.3s ease;
  opacity: 0.7;
}

.back-link:hover {
  color: var(--gold-light);
  opacity: 1;
}

/* ============================================================
   FIELD NOTES — LISTING
   ============================================================ */
.fieldnotes-listing {
  max-width: 760px;
  margin: 0 auto;
}

.fieldnotes-entry {
  position: relative;
  margin-bottom: 30px;
  border: 2px solid var(--gold-dark);
  padding: 28px 28px 24px;
  background: rgba(240,230,208,0.5);
}

.fieldnotes-entry::before {
  content: '';
  position: absolute;
  top: 5px; left: 5px; right: 5px; bottom: 5px;
  border: 1px solid rgba(201,168,76,0.3);
  pointer-events: none;
}

.fieldnotes-entry .entry-title {
  display: block;
}

.fieldnotes-link {
  color: var(--blue-mid);
  text-decoration: none;
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 700;
  transition: color 0.3s ease;
}

.fieldnotes-link:hover {
  color: var(--gold-dark);
}

.entry-excerpt {
  font-size: 16px;
  line-height: 1.7;
  color: #1a1a1e;
  margin-top: 8px;
}
