@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,300;0,9..144,400;0,9..144,500;1,9..144,400&family=Inter:wght@400;500;600&display=swap');

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

:root {
  --progress: 0;

  --light-bg: #f2efe6;
  --dark-bg: #0d0d0c;

  --light-text: #1a1814;
  --dark-text: #efece2;

  --accent: #315cff;

  --serif: 'Fraunces', Georgia, serif;
  --sans: 'Inter', Arial, Helvetica, sans-serif;

  --rule: color-mix(in srgb, currentColor 14%, transparent);

  --heading-color: var(--light-text);
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

body {
  overflow-x: hidden;
  overflow-y: auto;
  font-family: var(--sans);

  background:
    color-mix(in srgb, var(--light-bg) calc((1 - var(--progress)) * 100%), var(--dark-bg));

  color:
    color-mix(in srgb, var(--light-text) calc((1 - var(--progress)) * 100%), var(--dark-text));

  transition:
    background 0.15s linear,
    color 0.15s linear;
}


/* film grain — a little tooth so the two tones never feel flat/digital */

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;

  opacity: 0.045;
  mix-blend-mode: overlay;

  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}


/* ========================================
   MAIN SITE
======================================== */

.site {
  position: relative;
  width: 100vw;
  min-height: 100vh;

  overflow: visible;

  background:
    color-mix(in srgb, var(--light-bg) calc((1 - var(--progress)) * 100%), var(--dark-bg));

  color:
    color-mix(in srgb, var(--light-text) calc((1 - var(--progress)) * 100%), var(--dark-text));

  transition:
    background 0.15s linear,
    color 0.15s linear;
}

.site {
  --heading-color: color-mix(
    in srgb,
    var(--light-text) calc((1 - var(--progress)) * 100%),
    var(--dark-text)
  );
}

/* ========================================
   NAVIGATION
======================================== */

nav {
  position: relative;
  z-index: 20;

  height: 90px;

  padding: 0 50px;

  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: var(--serif);
  font-size: 32px;
}

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

.nav-links a {
  color: inherit;
  text-decoration: none;

  font-size: 12px;
  letter-spacing: 0.4px;
}


/* ========================================
   HERO
======================================== */

.hero {
  position: relative;

  width: 100%;
  min-height: calc(100vh - 90px);

  display: flex;
  flex-direction: column;
  justify-content: center;

  padding-left: 8%;
  padding-top: 130px;
  padding-bottom: 60px;

  z-index: 12;
}

.hero-top {
  position: absolute;

  top: 150px;
  left: 55%;
  right: 8%;

  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
}

.hero-avatar {
  position: relative;

  width: 460px;
  height: 340px;

  overflow: hidden;

  border: 1px solid var(--rule);
  outline: 1px solid color-mix(in srgb, currentColor 8%, transparent);
  outline-offset: 8px;

  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-avatar img {
  width: 100%;
  height: 100%;

  object-fit: cover;

  filter: grayscale(1) contrast(1.08) brightness(1.02);
  transition: filter 0.6s ease;
}

.hero-avatar:hover img {
  filter: grayscale(0.75) contrast(1.1) brightness(1.02);
}

.hero-avatar img[src=""],
.hero-avatar img:not([src]) {
  display: none;
}

.hero-avatar::after {
  content: "";

  position: absolute;
  inset: -14px;

  pointer-events: none;

  background-image:
    linear-gradient(currentColor, currentColor),
    linear-gradient(currentColor, currentColor),
    linear-gradient(currentColor, currentColor),
    linear-gradient(currentColor, currentColor),
    linear-gradient(currentColor, currentColor),
    linear-gradient(currentColor, currentColor),
    linear-gradient(currentColor, currentColor),
    linear-gradient(currentColor, currentColor);

  background-repeat: no-repeat;
  opacity: 0.5;

  background-size:
    16px 1px, 1px 16px,
    16px 1px, 1px 16px,
    16px 1px, 1px 16px,
    16px 1px, 1px 16px;

  background-position:
    top 0 left 0, top 0 left 0,
    top 0 right 0, top 0 right 0,
    bottom 0 left 0, bottom 0 left 0,
    bottom 0 right 0, bottom 0 right 0;
}

.hero-avatar::before {
  content: attr(data-initial);

  position: absolute;
  inset: 0;

  display: flex;
  align-items: center;
  justify-content: center;

  font-family: var(--serif);
  font-size: 28px;

  opacity: 0.35;
}

.status-badge {
  display: flex;
  align-items: center;
  gap: 8px;

  padding: 9px 16px;

  border-radius: 100px;

  border: 1px solid color-mix(in srgb, #2ecc71 35%, transparent);
  background: color-mix(in srgb, #2ecc71 12%, transparent);

  color: #2ecc71;

  font-size: 12px;
  letter-spacing: 0.3px;
}

.status-dot {
  width: 6px;
  height: 6px;

  border-radius: 50%;

  background: #2ecc71;

  box-shadow: 0 0 0 3px color-mix(in srgb, #2ecc71 25%, transparent);
}

.hero-content {
  max-width: 620px;
}

.hero-content h2 {
  font-family: var(--serif);
  font-optical-sizing: auto;
  font-size: clamp(44px, 6vw, 84px);
  font-weight: 400;
  font-style: italic;
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin-bottom: 28px;

  background: linear-gradient(
    100deg,
    var(--heading-color) 40%,
    var(--accent) 50%,
    var(--heading-color) 60%
  );

  background-size: 300% 100%;
  background-position: 100% 0;

  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;

  animation: nameSheen 3.5s ease forwards;
}

@keyframes nameSheen {
  0% {
    background-position: 100% 0;
  }

  100% {
    background-position: 0% 0;
  }
}

@keyframes nameSheen {
  0% {
    background-position: 100% 0;
  }

  100% {
    background-position: 0% 0;
  }
}

.eyebrow {
  font-size: 11px;
  letter-spacing: 1.5px;
  margin-bottom: 30px;

  opacity: 0.55;
}

h1 {
  font-family: var(--serif);

  font-size: clamp(60px, 8vw, 120px);
  font-weight: 400;

  line-height: 0.9;

  margin-bottom: 35px;
}

h1 span,
h2 span {
  font-style: italic;
}

.description {
  max-width: 560px;

  font-size: 18px;
  font-family: var(--sans);

  line-height: 1.75;

  opacity: 0.68;

  margin-bottom: 35px;
}

.work-btn {
  position: relative;

  padding: 15px 26px;

  background: transparent;

  border: 1px solid currentColor;

  color: inherit;

  cursor: pointer;

  font-size: 11px;

  letter-spacing: 0.6px;

  transition: background 0.25s ease, color 0.25s ease;
}

.work-btn:hover {
  background: currentColor;
  color: color-mix(in srgb, var(--light-bg) calc((1 - var(--progress)) * 100%), var(--dark-bg));
}


/* ========================================
   BLINDS
======================================== */

.blinds {
  position: fixed;

  left: 0;
  right: 0;
  top: 90px;

  height: calc(100vh - 90px);

  z-index: 10;

  pointer-events: none;

  display: flex;

  flex-direction: column;

  gap: calc(24px - (23px * var(--progress)));
}


.blind {
  width: 100%;

  height: calc(2px + (70px * var(--progress)));

  background:
    color-mix(in srgb, #ffffff calc((1 - var(--progress)) * 100%), #161616);

  border-bottom: 1px solid rgba(255,255,255,0.15);

  box-shadow:
    0 2px 8px rgba(0,0,0, calc(var(--progress) * 0.35)),
    inset 0 1px 0 rgba(255,255,255, calc((1 - var(--progress)) * 0.15));

  transform:
    perspective(800px)
    rotateX(calc(20deg * (1 - var(--progress))));

  transform-origin: center;

  flex-shrink: 0;
}


/* ========================================
   CORD
======================================== */

.cord {
    position: fixed;

    right: 48px;
    top: 100px;

    width: 40px;
    height: 180px;

    z-index: 100;

    display: flex;
    justify-content: center;

    user-select: none;

    transform-origin: top center;

    animation: cordSway 5.5s ease-in-out infinite;
}

.cord.dragging {
    animation-play-state: paused;
}

@keyframes cordSway {
    0%   { transform: rotate(0deg); }
    12%  { transform: rotate(12deg); }
    26%  { transform: rotate(-8deg); }
    40%  { transform: rotate(6.4deg); }
    55%  { transform: rotate(-10.4deg); }
    70%  { transform: rotate(5.4deg); }
    85%  { transform: rotate(-3deg); }
    100% { transform: rotate(0deg); }
}


.cord-line {
    position: absolute;

    top: 0;

    width: 1.5px;

    height: 110px;

    background: currentColor;

    opacity: 0.45;

    transform-origin: top center;

    transition:
        height 480ms
        cubic-bezier(0.16, 1.4, 0.3, 1);

    animation: stringDrift 3.6s ease-in-out infinite;
    animation-delay: -0.4s;
}

.cord.dragging .cord-line {
    animation-play-state: paused;
}

@keyframes stringDrift {
    0%, 100% { transform: skewX(0deg); }
    30%      { transform: skewX(-2deg); }
    65%      { transform: skewX(1.6deg); }
}


.cord-handle {
    position: absolute;

    top: 110px;

    width: 18px;
    height: 42px;

    border-radius: 10px;

    background: currentColor;

    cursor: grab;

    touch-action: none;

    transform-origin: top center;

    transition:
        transform 480ms cubic-bezier(0.16, 1.4, 0.3, 1),
        scale 180ms ease;

    animation: handleJiggle 5.5s ease-in-out infinite;
}

.cord.dragging .cord-handle {
    animation-play-state: paused;
    rotate: 0deg;
}

@keyframes handleJiggle {
    0%, 100% { rotate: 0deg; }
    12%      { rotate: 4deg; }
    26%      { rotate: -3deg; }
    40%      { rotate: 2.4deg; }
    55%      { rotate: -3.6deg; }
    70%      { rotate: 1.8deg; }
    85%      { rotate: -1.4deg; }
}

.cord-handle:active {
    cursor: grabbing;
}

.cord-handle::after {
    content: "";

    position: absolute;
    inset: -6px;

    border-radius: 14px;

    box-shadow: 0 0 0 1px color-mix(in srgb, currentColor 12%, transparent);

    opacity: 0.6;

    pointer-events: none;

    animation: handleGlow 2.8s ease-in-out infinite;
}

@keyframes handleGlow {
    0%, 100% { opacity: 0.25; transform: scale(1); }
    50%      { opacity: 0.6; transform: scale(1.08); }
}


.cord-handle span {
    position: absolute;

    width: 4px;
    height: 18px;

    border-radius: 3px;

    background: rgba(255,255,255,0.3);

    left: 50%;
    top: 50%;

    transform: translate(-50%, -50%);
}

/* ========================================
   HINT
======================================== */

.pull-hint {
  position: fixed;

  right: 78px;
  top: 50%;

  z-index: 51;

  writing-mode: vertical-rl;

  font-family: var(--sans);
  font-size: 9px;

  letter-spacing: 2.5px;

  opacity: 0.45;

  pointer-events: none;

  transition: opacity 0.5s ease;
}

.pull-hint.hidden {
  opacity: 0;
}


/* ========================================
   DARK MODE EXTRA ATMOSPHERE
======================================== */

.site::after {
  content: "";

  position: absolute;

  inset: 0;

  pointer-events: none;

  z-index: 5;

  background:
    radial-gradient(circle at 65% 50%, rgba(255,255,255,0.08), transparent 45%);

  opacity: calc(1 - var(--progress));

  transition: opacity 0.15s linear;
}


/* =========================================
   SECTION
========================================= */

.experience {
    min-height: 100vh;
    padding: 140px 9vw 180px;

    position: relative;
    overflow: visible;

    z-index: 10;

    background:
        color-mix(in srgb, var(--light-bg) calc((1 - var(--progress)) * 100%), var(--dark-bg));

    color:
        color-mix(in srgb, var(--light-text) calc((1 - var(--progress)) * 100%), var(--dark-text));

    transition:
        background 0.15s linear,
        color 0.15s linear;
}

/* =========================================
   HEADER
========================================= */

.section-header {
    max-width: 850px;
    margin-left: 18%;
    margin-bottom: 110px;
}

.section-label {
    font-size: 10px;
    letter-spacing: 1.5px;

    opacity: 0.4;

    margin-bottom: 18px;
}

.section-header h2 {
    font-family: var(--serif);

    font-size: clamp(42px, 5vw, 72px);
    font-weight: 400;

    line-height: 1;

    margin-bottom: 20px;
}

.section-header p {
    max-width: 620px;

    font-size: 19px;

    line-height: 1.6;

    opacity: 0.6;
}


/* =========================================
   TIMELINE
========================================= */

.timeline {
    position: relative;

    max-width: 980px;

    margin: auto;
}


.timeline-line {
    position: absolute;

    left: 90px;
    top: 0;
    bottom: 0;

    width: 1px;

    background: currentColor;

    opacity: 0.13;
}


.timeline-progress {
    position: absolute;

    left: 89.5px;
    top: 0;

    width: 2px;

    height: 0;

    background: var(--accent);

    box-shadow: 0 0 10px color-mix(in srgb, var(--accent) 60%, transparent);

    transition: height 0.15s linear;
}


/* =========================================
   TIMELINE ITEM
========================================= */

.timeline-item {
    position: relative;

    padding-left: 140px;
    padding-bottom: 90px;

    opacity: 0.35;
    filter: grayscale(0.4);

    transition:
        opacity 0.6s ease,
        filter 0.6s ease;
}

.timeline-item.active {
    opacity: 1;
    filter: grayscale(0);
}

.timeline-item:last-child {
    padding-bottom: 0;
}


/* =========================================
   DOT
========================================= */

.timeline-dot {
    position: absolute;

    left: 83px;
    top: 3px;

    width: 15px;
    height: 15px;

    border-radius: 50%;

    background: color-mix(in srgb, currentColor 8%, transparent);

    border: 1px solid currentColor;

    opacity: 0.4;

    z-index: 3;

    transition:
        border-color 0.3s ease,
        transform 0.3s ease,
        opacity 0.3s ease;
}


.timeline-dot::after {
    content: "";

    position: absolute;

    left: 50%;
    top: 50%;

    width: 5px;
    height: 5px;

    border-radius: 50%;

    background: var(--accent);

    transform: translate(-50%, -50%) scale(0);

    transition: transform 0.3s ease;
}


.timeline-item.active .timeline-dot {
    border-color: var(--accent);
    opacity: 1;

    transform: scale(1.1);
}

.timeline-item.active .timeline-dot::after {
    transform: translate(-50%, -50%) scale(1);
}

.timeline-item.active .timeline-dot::before {
    content: "";

    position: absolute;
    inset: -1px;

    border-radius: 50%;

    border: 1px solid var(--accent);

    opacity: 0;

    animation: dotPulse 2.4s ease-out infinite;
}

@keyframes dotPulse {
    0%   { transform: scale(1);   opacity: 0.5; }
    100% { transform: scale(2.4); opacity: 0; }
}


/* =========================================
   CONTENT
========================================= */

.timeline-content {
    padding-left: 0;
}

.current-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;

    padding: 5px 12px 5px 10px;

    margin-bottom: 16px;

    border-radius: 100px;

    border: 1px solid color-mix(in srgb, #2ecc71 35%, transparent);
    background: color-mix(in srgb, #2ecc71 12%, transparent);

    color: #2ecc71;

    font-size: 10px;
    letter-spacing: 0.8px;
}

.current-badge .status-dot {
    width: 5px;
    height: 5px;
}

.company {
    font-family: var(--serif);

    font-size: 30px;
    font-weight: 400;

    letter-spacing: -0.01em;

    margin-bottom: 8px;
}

.role {
    font-family: var(--sans);
    font-size: 14px;

    font-weight: 500;
    letter-spacing: 0.2px;

    opacity: 0.8;

    margin-bottom: 14px;
}

.timeline-content .description {
    max-width: 620px;

    font-size: 16px;

    line-height: 1.75;

    opacity: 0.62;

    margin-bottom: 0;
}


/* =========================================
   PROJECT CARD
========================================= */

.project-cards {
    margin-top: 30px;

    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.project-card {
    display: grid;
    grid-template-columns: 170px 1fr;
    gap: 24px;

    width: 100%;
    max-width: 620px;

    padding: 20px;

    border: 1px solid var(--rule);

    text-decoration: none;
    color: inherit;

    transition:
        border-color 0.3s ease,
        transform 0.3s ease,
        background 0.3s ease;
}

.project-card:hover {
    border-color: var(--accent);
    transform: translateY(-3px);
    background: color-mix(in srgb, currentColor 4%, transparent);
}

.project-card-image {
    position: relative;

    aspect-ratio: 1 / 1;
    width: 100%;

    border: 1px solid var(--rule);

    overflow: hidden;

    display: flex;
    align-items: center;
    justify-content: center;

    background: color-mix(in srgb, currentColor 5%, transparent);
}

.project-card-image img {
    width: 100%;
    height: 100%;

    object-fit: cover;
    display: block;

    filter: grayscale(1) contrast(1.05);
    transition: filter 0.5s ease, transform 0.5s ease;
}

.project-card:hover .project-card-image img {
    filter: grayscale(0.2) contrast(1.05);
    transform: scale(1.04);
}

.project-card-image::before {
    content: attr(data-initial);

    position: absolute;
    inset: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    font-family: var(--serif);
    font-size: 13px;
    letter-spacing: 1px;

    opacity: 0.4;
}

.project-card-image img[src=""],
.project-card-image img:not([src]) {
    display: none;
}

.project-card-body {
    display: flex;
    flex-direction: column;

    min-width: 0;
}

.project-card-title {
    font-family: var(--serif);
    font-weight: 400;
    font-style: italic;

    font-size: 23px;

    margin-bottom: 9px;
}

.project-card-description {
    font-size: 13.5px;
    line-height: 1.65;

    opacity: 0.6;

    margin-bottom: auto;
    padding-bottom: 16px;
}

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

.tag {
    padding: 6px 11px;

    border: 1px solid var(--rule);

    font-size: 9.5px;
    letter-spacing: 0.4px;

    opacity: 0.7;

    white-space: nowrap;

    transition: border-color 0.25s ease, color 0.25s ease, opacity 0.25s ease;
}

.project-card:hover .tag {
    border-color: var(--accent);
    color: var(--accent);
    opacity: 1;
}


/* =========================================
   LEGACY VARIANT
========================================= */

.timeline-detail {
    margin-top: 28px;

    display: flex;

    align-items: center;

    gap: 15px;
}

.detail-icon {
    width: 48px;
    height: 48px;

    background: color-mix(in srgb, currentColor 8%, transparent);

    display: flex;
    align-items: center;
    justify-content: center;

    font-family: var(--serif);
    font-size: 17px;
}

.detail-text strong {
    display: block;

    font-size: 14px;

    margin-bottom: 4px;
}

.detail-text span {
    font-size: 13px;

    opacity: 0.65;
}


/* =========================================
   BLIND TICKS
========================================= */

.timeline-ticks {
    position: absolute;

    left: 90px;

    top: 0;
    bottom: 0;

    width: 80px;

    pointer-events: none;
}

.timeline-ticks span {
    position: absolute;

    left: -10px;

    width: 22px;
    height: 1px;

    background: currentColor;

    opacity: 0.18;
}


/* =========================================
   LIGHT INDICATOR
========================================= */

.light-indicator {
    position: fixed;

    right: 35px;
    bottom: 35px;

    display: flex;

    align-items: center;

    gap: 10px;

    font-size: 9px;

    letter-spacing: 1.2px;

    opacity: 0.5;

    z-index: 10;
}

.light-indicator::before {
    content: "";

    width: 7px;
    height: 7px;

    border-radius: 50%;

    background: var(--accent);

    box-shadow: 0 0 0 4px rgba(49,92,255,0.1);
}


/* =========================================
   RESPONSIVE
========================================= */

@media (max-width: 700px) {

    .experience {
        padding: 90px 22px 110px;
    }

    .section-header {
        margin-left: 0;
        margin-bottom: 70px;
    }

    .timeline-line {
        left: 15px;
    }

    .timeline-progress {
        left: 14.5px;
    }

    .timeline-item {
        padding-left: 45px;
        opacity: 1;
        filter: none;
    }

    .timeline-dot {
        left: 8px;
    }

    .timeline-content {
        padding-left: 0;
    }

    .timeline-ticks {
        display: none;
    }

    .hero {
        padding-left: 6%;
        padding-top: 100px;
    }

    .hero-top {
        position: static;
        justify-content: center;
        margin-bottom: 36px;
    }

    .hero-avatar {
        width: 100%;
        max-width: 420px;
        height: 300px;
    }

    .project-card {
        grid-template-columns: 1fr;
        max-width: 100%;
    }

    .project-card-image {
        max-width: 160px;
    }

}


/* =========================================
   SITE FOOTER
========================================= */

.site-footer {
    position: fixed;

    width: 100vw;
    left: 50%;
    bottom: 0px;

    transform: translateX(-50%);

    z-index: 200;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0px;

    padding: 15px 28px;

    background: color-mix(in srgb, currentColor 10%, transparent);

    backdrop-filter: blur(18px) saturate(160%);
    -webkit-backdrop-filter: blur(18px) saturate(160%);

    box-shadow:
        0 8px 30px rgba(0, 0, 0, 0.18),
        inset 0 0 0 1px color-mix(in srgb, currentColor 8%, transparent);

    color: inherit;

    transition:
        background 0.15s linear,
        box-shadow 0.15s linear;
}

.footer-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 60px;
    height: 22px;

    color: inherit;
    opacity: 0.75;

    transition:
        opacity 0.2s ease,
        transform 0.2s ease,
        color 0.2s ease;
}

.footer-icon img {
    width: 22px;
    height: 22px;

    transition: filter 0.2s ease;
}

.footer-icon:hover img {
    filter: invert(35%) sepia(90%) saturate(3000%) hue-rotate(215deg) brightness(100%) contrast(100%);
}

.footer-icon:hover {
    opacity: 1;
    color: var(--accent);
    transform: translateY(-3px);
}

@media (max-width: 700px) {

    .site-footer {
        gap: 8px;
        padding: 13px 22px;
        bottom: 0px;
    }

    .footer-icon {
        width: 44px;
        height: 20px;
    }

}
