/* Mara Ekin — an editorial portfolio. Paper, ink, one vermilion signal. */
:root {
  --paper: #F1EEE7;
  --paper-2: #E8E4DA;
  --ink: #161513;
  --ink-2: #3E3B36;
  --stone: #8A867D;
  --rule: #D9D4C9;
  --verm: #E5482D;
  --display: var(--kit-didone);
  --sans: var(--kit-sans);
  --mono: var(--kit-mono);
  --pad: clamp(28px, 2.8vw, 44px);
  --ease: cubic-bezier(.2, .7, .1, 1);
  --curtain: cubic-bezier(.76, 0, .24, 1);
}
* { box-sizing: border-box; }
html { background: var(--paper); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
body { margin: 0; font: 400 16px/1.55 var(--sans); color: var(--ink); background: var(--paper); overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, h6, p, ul, ol, dl, dd, blockquote { margin: 0; padding: 0; }
ul, ol { list-style: none; }
::selection { background: var(--verm); color: var(--paper); }
:focus-visible { outline: 1.5px solid var(--verm); outline-offset: 4px; }

/* ---------------- header ---------------- */
.top {
  position: fixed; inset: 0 0 auto; z-index: 40; height: 64px; padding: 0 var(--pad);
  display: grid; grid-template-columns: repeat(12, 1fr); gap: 20px; align-items: center;
  font: 450 13px/1 var(--sans); letter-spacing: 0.005em; color: var(--ink);
  transition: background-color .4s, box-shadow .4s;
}
.top.is-solid { background: rgb(241 238 231 / 0.9); backdrop-filter: blur(14px); box-shadow: 0 1px 0 var(--rule); }
.top.on-dark { background: rgb(22 21 19 / 0.92); color: var(--paper); box-shadow: 0 1px 0 rgb(241 238 231 / .12); }
.top.on-dark .top__role, .top.on-dark .top__clock { color: rgb(241 238 231 / .55); }
.top.on-dark .top__clock b { color: var(--paper); }
.top__name { grid-column: 1 / span 2; font-weight: 600; letter-spacing: -0.01em; font-size: 14px; }
.top__role { grid-column: 3 / span 3; color: var(--stone); }
.top__clock { grid-column: 6 / span 2; color: var(--stone); font-variant-numeric: tabular-nums; }
.top__clock b { font: 500 12.5px/1 var(--mono); color: var(--ink); margin-left: 6px; }
.top__nav { grid-column: 8 / span 3; display: flex; gap: 22px; }
.top__nav a { position: relative; padding: 6px 0; }
.top__nav a::after { content: ''; position: absolute; left: 0; right: 0; bottom: 2px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform .45s var(--ease); }
.top__nav a:hover::after { transform: scaleX(1); transform-origin: left; }
.top__nav sup { font: 500 9px/1 var(--mono); margin-left: 3px; color: var(--stone); }
.top__avail { grid-column: 11 / span 2; justify-self: end; display: inline-flex; align-items: center; gap: 9px; white-space: nowrap; }
.top__avail i, .live { width: 7px; height: 7px; border-radius: 50%; background: var(--verm); box-shadow: 0 0 0 0 rgb(229 72 45 / .5); animation: pulse 2s infinite; display: inline-block; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgb(229 72 45 / .5); } 70%, 100% { box-shadow: 0 0 0 8px rgb(229 72 45 / 0); } }

/* ---------------- hero ---------------- */
.hero { position: relative; min-height: 100vh; padding: 76px var(--pad) 0; display: flex; flex-direction: column; }
.name {
  font: 400 280px/0.8 var(--display); letter-spacing: -0.035em; white-space: nowrap; margin: 0 0 0 -0.04em;
  padding-top: 0.08em; color: var(--ink);
}
.name__in { display: inline-block; }
.name .w1, .name .w2, .name .dot { display: inline-block; animation: nameIn 1.3s var(--ease) both; }
.name .w2 { font-style: italic; letter-spacing: -0.02em; animation-delay: .08s; }
.name .dot { color: var(--verm); animation-delay: .16s; margin-left: -0.02em; }
@keyframes nameIn { from { transform: translateY(0.35em); opacity: 0; } to { transform: none; opacity: 1; } }
.intro { margin-top: 30px; display: grid; grid-template-columns: repeat(12, 1fr); gap: 20px; padding-top: 18px; border-top: 1px solid var(--ink); animation: fadeUp 1s .35s var(--ease) both; }
.intro__a { grid-column: 1 / span 5; font: 400 22px/1.32 var(--sans); letter-spacing: -0.012em; max-width: 30ch; }
.intro__b { grid-column: 7 / span 3; font-size: 14.5px; line-height: 1.55; color: var(--ink-2); }
.intro__s { grid-column: 10 / span 3; }
h6 { font: 500 11px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--stone); margin-bottom: 12px; }
.intro__s li { font-size: 14.5px; line-height: 1.6; }
.marquee { margin: auto calc(-1 * var(--pad)) 0; padding: 36px 0 0; overflow: hidden; animation: fadeUp 1.2s .5s var(--ease) both; }
.marquee__track { display: flex; gap: 14px; width: max-content; will-change: transform; }
.mq { flex: none; height: 232px; position: relative; overflow: hidden; background: var(--paper-2); }
.mq svg { display: block; width: 100%; height: 100%; }
.cue { position: absolute; right: var(--pad); bottom: 262px; display: none; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* ---------------- section headers ---------------- */
.sec-h { display: flex; align-items: flex-end; justify-content: space-between; padding: 0 var(--pad) 22px; border-bottom: 1px solid var(--ink); margin: 0 0 40px; }
.sec-h h2 { font: 400 clamp(72px, 8.6vw, 136px)/0.86 var(--display); letter-spacing: -0.03em; }
.sec-h__n { font: 500 13px/1 var(--mono); color: var(--stone); padding-bottom: 10px; }
.sec-h--small h2 { font-size: clamp(48px, 5vw, 76px); }
.process .sec-h { border-bottom: 0; padding-bottom: 0; margin-bottom: 36px; }

/* ---------------- cases ---------------- */
.work { padding-top: 150px; }
.cases { padding: 0 var(--pad); display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 20px; row-gap: 110px; }
.case { grid-column: 1 / -1; }
.case--half { grid-column: span 6; }
.case--half:nth-of-type(3) { margin-top: 140px; }
.cover { position: relative; display: block; overflow: hidden; aspect-ratio: 16 / 10; background: var(--paper-2); cursor: none; clip-path: inset(100% 0 0 0); transition: clip-path 1.25s var(--curtain); }
.case--half .cover { aspect-ratio: 4 / 5; }
.cover__img { position: absolute; inset: 0; transform: scale(1.14); transition: transform 1.6s var(--ease); }
.cover__img svg { display: block; width: 100%; height: 100%; }
.case.in .cover { clip-path: inset(0 0 0 0); }
.case.in .cover__img { transform: scale(1); }
.case.in .cover:hover .cover__img { transform: scale(1.035); transition-duration: 1.1s; }
.cap { margin-top: 22px; display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 20px; align-items: start; opacity: 0; transform: translateY(16px); transition: opacity .9s .35s var(--ease), transform .9s .35s var(--ease); }
.case.in .cap { opacity: 1; transform: none; }
.cap__n { grid-column: span 1; font: 500 12px/1 var(--mono); color: var(--stone); padding-top: 10px; }
.cap__t { grid-column: span 4; font: 400 50px/0.95 var(--display); letter-spacing: -0.02em; }
.cap__t em { font-style: italic; }
.cap__d { grid-column: span 4; font-size: 15px; line-height: 1.55; color: var(--ink-2); padding-top: 6px; }
.cap__m { grid-column: span 3; justify-self: end; text-align: right; padding-top: 8px; display: flex; flex-direction: column; align-items: flex-end; gap: 12px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
.tags li { font: 500 11px/1 var(--mono); padding: 6px 9px; border-radius: 999px; box-shadow: 0 0 0 1px var(--rule) inset; color: var(--ink-2); }
.cap__y { font: 500 12px/1 var(--mono); color: var(--stone); }
.cap__go { white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 500; }
.cap__go svg { width: 14px; height: 14px; transition: transform .4s var(--ease); }
.cap__go:hover svg { transform: translateX(4px); }
.case--half .cap__n { grid-column: span 2; }
.case--half .cap__t { grid-column: span 10; font-size: 44px; }
.case--half .cap__d { grid-column: 3 / span 7; }
.case--half .cap__m { grid-column: span 3; }

/* ---------------- index ---------------- */
.index { padding-top: 190px; }
.table { padding: 0 var(--pad); }
.row { display: grid; grid-template-columns: 1fr 4fr 5fr 2fr 40px; gap: 20px; align-items: center; height: 76px; border-bottom: 1px solid var(--rule); position: relative; transition: color .35s, padding .5s var(--ease); }
.row::before { content: ''; position: absolute; inset: 0 calc(-1 * var(--pad)); background: var(--ink); transform: scaleY(0); transform-origin: bottom; transition: transform .45s var(--ease); z-index: -1; }
.row:hover { color: var(--paper); padding-left: 14px; }
.row:hover::before { transform: scaleY(1); }
.row--head { height: 40px; font: 500 11px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--stone); }
.row--head::before { display: none; }
.row--head:hover { color: var(--stone); padding-left: 0; }
.row__y { font: 500 13px/1 var(--mono); color: var(--stone); }
.row:hover .row__y, .row:hover .row__k { color: rgb(241 238 231 / .6); }
.row__p { font: 400 32px/1 var(--display); letter-spacing: -0.01em; }
.row__w { font-size: 15px; }
.row__k { font: 500 12px/1 var(--mono); color: var(--stone); }
.row__a { justify-self: end; width: 18px; height: 18px; transform: rotate(-45deg); transition: transform .45s var(--ease); }
.row:hover .row__a { transform: none; }
.peek { position: fixed; z-index: 30; left: 0; top: 0; width: 300px; height: 197px; pointer-events: none; overflow: hidden; opacity: 0; transform: translate(-50%, -50%) scale(.85); transition: opacity .3s, transform .4s var(--ease); box-shadow: 0 30px 60px -20px rgb(0 0 0 / .35); }
.peek.on { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.peek svg { display: block; width: 100%; height: 100%; }

/* ---------------- process ---------------- */
.process { padding-top: 180px; }
.steps { padding: 0 var(--pad); display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.steps li { border-top: 1px solid var(--ink); padding-top: 20px; }
.steps b { display: block; font: 400 italic 64px/1 var(--display); color: var(--ink); }
.steps h3 { margin-top: 26px; font: 600 19px/1.2 var(--sans); letter-spacing: -0.01em; }
.steps p { margin-top: 10px; font-size: 15px; color: var(--ink-2); max-width: 30ch; }

/* ---------------- about ---------------- */
.about { margin-top: 170px; padding: 120px var(--pad) 130px; background: var(--ink); color: var(--paper); display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 20px; row-gap: 70px; }
.about__label { grid-column: 1 / span 2; font: 500 11px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: rgb(241 238 231 / .55); padding-top: 16px; }
.about__quote { grid-column: 3 / span 10; font: 400 clamp(52px, 5.6vw, 88px)/1.0 var(--display); letter-spacing: -0.025em; text-wrap: balance; }
.about__quote em { font-style: italic; color: var(--verm); }
.about__text { grid-column: 3 / span 5; display: grid; gap: 16px; font-size: 17px; line-height: 1.6; color: rgb(241 238 231 / .82); }
.about__lists { grid-column: 3 / span 10; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; border-top: 1px solid rgb(241 238 231 / .2); padding-top: 26px; }
.about h6 { color: rgb(241 238 231 / .5); }
.about__lists li { font-size: 15px; line-height: 1.7; color: rgb(241 238 231 / .9); }

/* ---------------- contact ---------------- */
.contact { padding: 160px var(--pad) 120px; }
.contact__label { font: 500 11px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--stone); }
.contact__lead { margin-top: 24px; font: 400 clamp(40px, 4vw, 60px)/1 var(--display); letter-spacing: -0.02em; }
.contact__mail { margin-top: 26px; display: flex; align-items: flex-end; gap: 28px; flex-wrap: wrap; }
.mail { font: 400 italic clamp(64px, 8.6vw, 136px)/1 var(--display); letter-spacing: -0.035em; position: relative; padding-bottom: 10px; white-space: nowrap; }
.mail::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--ink); transform: scaleX(.15); transform-origin: left; transition: transform .7s var(--ease), background-color .3s; }
.mail:hover::after { transform: scaleX(1); background: var(--verm); }
.copy { margin-bottom: 22px; height: 44px; padding: 0 20px; border-radius: 999px; box-shadow: 0 0 0 1px var(--ink) inset; font: 500 14px/1 var(--sans); transition: background-color .3s, color .3s; }
.copy:hover, .copy.done { background: var(--ink); color: var(--paper); }
.contact__meta { margin-top: 70px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; border-top: 1px solid var(--rule); padding-top: 22px; }
.contact__meta dt { font: 500 11px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--stone); }
.contact__meta dd { margin-top: 10px; font-size: 17px; display: flex; align-items: center; gap: 10px; }
.foot { padding: 22px var(--pad) 28px; border-top: 1px solid var(--rule); display: flex; gap: 24px; justify-content: space-between; font: 500 12px/1.4 var(--mono); color: var(--stone); }
.foot__fic { flex: 1; text-align: center; }
.foot__top:hover { color: var(--ink); }

/* ---------------- cursor ---------------- */
.cursor { position: fixed; z-index: 50; left: 0; top: 0; width: 92px; height: 92px; margin: -46px 0 0 -46px; border-radius: 50%; background: var(--ink); color: var(--paper); display: grid; place-items: center; font: 500 13px/1 var(--sans); pointer-events: none; transform: scale(0); transition: transform .4s var(--ease); }
.cursor.on { transform: scale(1); }
.is-capturing .cursor, .is-capturing .peek { display: none; }

/* ---------------- reveal ---------------- */
.rv { opacity: 0; transform: translateY(28px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.rv.in { opacity: 1; transform: none; }
.is-capturing .rv, .is-capturing .cap { transition-duration: .55s; transition-delay: 0s; }
.is-capturing .cover { transition-duration: .8s; }

@media (max-width: 1240px) {
  .top__role { grid-column: 3 / span 2; }
  .top__clock { grid-column: 5 / span 2; }
  .top__nav { grid-column: 7 / span 3; }
  .top__avail { grid-column: 10 / span 3; }
  .cap__t { grid-column: span 5; font-size: 42px; }
  .cap__d { grid-column: span 6; }
  .cap__m, .case--half .cap__m { grid-column: 2 / -1; justify-self: start; text-align: left; align-items: center; flex-direction: row; flex-wrap: wrap; gap: 14px; margin-top: 14px; }
  .case--half .cap__m { grid-column: 3 / -1; }
  .tags { justify-content: flex-start; }
  .case--half .cap__t { font-size: 36px; }
}
@media (max-width: 1080px) {
  .top__role { display: none; }
  .top__clock { grid-column: 3 / span 3; }
  .intro__a { grid-column: 1 / span 6; font-size: 20px; }
  .intro__b { grid-column: 7 / span 3; }
  .row { grid-template-columns: 1fr 4fr 5fr 40px; }
  .row__k { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
