/* Teja — portfolio hub */
:root {
  --bg: #141414;
  --ink: #F3F1EC;
  --accent: #F3F1EC;
  --mute: rgba(243, 241, 236, .55);
  --line: rgba(243, 241, 236, .16);
  color-scheme: dark;
  --serif: 'Instrument Serif', Georgia, serif;
  --sans: 'Inter Tight', Inter, system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --gutter: clamp(20px, 4vw, 64px);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: auto; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body {
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  transition: background-color .6s var(--ease-out), color .6s var(--ease-out);
}
::selection { background: var(--ink); color: var(--bg); }
a { color: inherit; text-decoration: none; }
em { font-style: italic; }
img { display: block; max-width: 100%; }
.mono { font-family: var(--mono); font-size: 12px; letter-spacing: .04em; text-transform: uppercase; }

/* loader */
.loader {
  position: fixed; inset: 0; z-index: 100;
  background: var(--bg); color: var(--ink);
  display: grid; place-items: center;
}
.loader__word { font: italic 400 clamp(64px, 12vw, 160px)/1.15 var(--serif); display: flex; overflow: hidden; padding: 0 .08em; }
.loader__word span { display: inline-block; transform: translateY(110%); }
.loader__line { position: absolute; left: var(--gutter); right: var(--gutter); bottom: var(--gutter); height: 1px; background: var(--ink); transform: scaleX(0); transform-origin: left; }
.loader.is-done { display: none; }

/* wipe for leaving to a site */
.wipe { position: fixed; inset: 0; z-index: 90; background: var(--ink); transform: scaleY(0); transform-origin: bottom; pointer-events: none; }

/* nav */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: 22px var(--gutter);
  mix-blend-mode: difference; color: #fff;
}
.nav__name { font: italic 400 28px/1 var(--serif); }
.nav__links { display: flex; gap: 28px; font-size: 14px; }
.nav__links a { position: relative; padding: 4px 0; }
.nav__links a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform .5s var(--ease-out); }
.nav__links a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav__time { justify-self: end; }

/* hero */
.hero { position: relative; min-height: 100vh; min-height: 100svh; display: grid; align-items: end; padding: 0 var(--gutter) clamp(48px, 9vh, 110px); overflow: hidden; }
.hero__gl { position: absolute; inset: 0; width: 100%; height: 100%; display: block; pointer-events: none; }
.hero__inner { position: relative; z-index: 2; max-width: 1100px; }
.hero__kicker { margin-bottom: 28px; color: var(--mute); }
.hero__title { font: 400 clamp(52px, 8.6vw, 136px)/1.08 var(--serif); letter-spacing: -0.015em; text-wrap: balance; margin-bottom: 32px; }
.hero__title em { color: var(--accent); }
.hero__sub { max-width: 540px; font-size: clamp(16px, 1.3vw, 19px); color: var(--mute); margin-bottom: 36px; }
.hero__scroll { position: absolute; right: var(--gutter); bottom: clamp(48px, 9vh, 110px); z-index: 2; color: var(--mute); writing-mode: vertical-rl; }
[data-split] { visibility: hidden; }
[data-split].is-ready { visibility: visible; }
[data-split] .line { padding-bottom: .06em; margin-bottom: -.06em; }

/* buttons — adapted from Osmo: magnetic-hover-effect */
.btn {
  display: inline-flex; align-items: center; gap: 14px;
  padding: 14px 22px 14px 24px; border-radius: 999px;
  border: 1px solid var(--ink); color: var(--ink); background: transparent;
  font: 500 15px/1 var(--sans); cursor: pointer; position: relative; overflow: hidden;
  transition: color .35s var(--ease-out), border-color .35s;
}
.btn::before { content: ""; position: absolute; inset: 0; background: var(--ink); transform: translateY(101%); transition: transform .5s var(--ease-out); border-radius: inherit; }
.btn span, .btn i { position: relative; z-index: 1; font-style: normal; }
.btn:hover { color: var(--bg); }
.btn:hover::before { transform: translateY(0); }
.btn i { transition: transform .5s var(--ease-out); }
.btn:hover i { transform: translateY(3px); }
.btn--big { font-size: clamp(18px, 2.2vw, 28px); padding: 20px 30px; }


/* sections */
section { padding: clamp(80px, 12vw, 160px) var(--gutter); }
.sec-title { font: 400 clamp(40px, 6vw, 96px)/1.1 var(--serif); letter-spacing: -0.01em; }
.sec-title em { color: var(--accent); }
.work__head { display: flex; justify-content: space-between; align-items: end; margin-bottom: 40px; gap: 24px; }
.work__head .mono { color: var(--mute); }

/* rows — adapted from Osmo: image-preview-cursor-follower */
.rows { position: relative; }
.rows__head, .row__link {
  display: grid; grid-template-columns: 56px 1.2fr 1fr 1.6fr 64px; align-items: center; gap: 24px;
}
.rows__head { color: var(--mute); padding: 0 0 14px; border-bottom: 1px solid var(--line); }
.rows__list { list-style: none; }
.row { border-bottom: 1px solid var(--line); transition: opacity .3s; }
.row__link { padding: 30px 0; }
.row__idx { color: var(--mute); }
.row__brand { display: flex; align-items: center; gap: 16px; }
.row__mark { width: 28px; height: 28px; object-fit: contain; }
.row__mark--img { border-radius: 50%; }
.row__name { font: 400 clamp(28px, 3.4vw, 54px)/1.15 var(--serif); }
.row__kind { color: var(--ink); }
.row__inside { color: var(--mute); font-size: 15px; }
.row__year { text-align: right; color: var(--mute); }
.row__visual { display: none; }
@media (hover: hover) and (min-width: 992px) {
  body:has(.row:hover) .row:not(:hover) { opacity: .4; }
}
.follower {
  position: fixed; top: 0; left: 0; z-index: 60; width: 22em; aspect-ratio: 16 / 10; pointer-events: none;
  border-radius: 10px; overflow: hidden; display: none;
}
.follower__inner { position: relative; width: 100%; height: 100%; opacity: 0; transform: scale(0); transition: opacity .1s ease, transform .6s cubic-bezier(0.65, 0.1, 0, 1); }
.follower__label { position: absolute; z-index: 3; left: 50%; top: 50%; transform: translate(-50%, -50%); font: 500 13px/1 var(--sans); }
.follower__label span { display: inline-block; background: #fff; color: #111; border-radius: 999px; padding: 10px 16px; }
.follower [data-follower-visual] { display: block; position: absolute; inset: 0; width: 100%; height: 100%; background: var(--b); color: var(--i); }
.follower [data-follower-visual] img { width: 100%; height: 100%; object-fit: cover; }
.follower [data-follower-visual] span { position: absolute; left: 20px; bottom: 16px; font: italic 400 28px/1 var(--serif); }
.follower [data-follower-visual] img + span { display: none; }
@media (hover: hover) and (min-width: 992px) {
  .follower { display: block; }
  body:has([data-follower-collection]:hover) .follower__inner { opacity: 1; transform: scale(1); }
}


/* about + contact (dark theme sections) */
.about__inner, .contact__inner { max-width: 1100px; }
.about__line { max-width: 620px; margin: 40px 0 0; font-size: clamp(17px, 1.4vw, 21px); color: var(--mute); }
.contact { padding-top: 0; }
.contact__title { font: 400 clamp(44px, 8vw, 128px)/1.08 var(--serif); letter-spacing: -0.015em; margin-bottom: 40px; }
.contact__title em { color: var(--accent); }
.contact__links { display: flex; gap: 28px; margin-top: 28px; color: var(--mute); }
.contact__links a:hover { color: var(--ink); }

/* footer */
.footer { display: flex; justify-content: space-between; gap: 20px; padding: 28px var(--gutter); border-top: 1px solid var(--line); color: var(--mute); flex-wrap: wrap; }

/* reveal defaults */
[data-fade] { opacity: 0; transform: translateY(24px); }
.no-js [data-fade], .no-js [data-split] { opacity: 1; transform: none; visibility: visible; }

@media (max-width: 991px) {
  .nav { grid-template-columns: 1fr auto; }
  .nav__time { display: none; }
  .rows__head { display: none; }
  .row__link { grid-template-columns: 40px 1fr 48px; grid-template-areas: "idx brand year" "idx kind kind" "idx inside inside"; row-gap: 6px; }
  .row__idx { grid-area: idx; align-self: start; }
  .row__brand { grid-area: brand; }
  .row__kind { grid-area: kind; }
  .row__inside { grid-area: inside; }
  .row__year { grid-area: year; }
  .work__head { flex-direction: column; align-items: start; }
}
@media (max-width: 600px) {
  .nav__links { gap: 18px; font-size: 13px; }
  .hero__scroll { display: none; }
  .btn--big { font-size: 16px; padding: 16px 20px; }
  .footer { flex-direction: column; }
}
