/* PT Serokin Analitika Teknologi — strictly black & white. */

:root {
  --bg: #000000;
  --fg: #ffffff;
  --fg-muted: rgba(255, 255, 255, 0.62);
  --fg-faint: rgba(255, 255, 255, 0.38);
  --line: rgba(255, 255, 255, 0.14);
  --line-strong: rgba(255, 255, 255, 0.4);
  --surface: rgba(0, 0, 0, 0.45);

  --font-display: 'Space Grotesk', ui-sans-serif, system-ui, sans-serif;
  --font-body: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;

  --gutter: clamp(16px, 5vw, 64px);
  --maxw: 1120px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection {
  background: var(--fg);
  color: var(--bg);
}

#galaxy {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: block;
}

main {
  position: relative;
  z-index: 1;
}

a {
  color: inherit;
  text-decoration: none;
}

:focus-visible {
  outline: 1px solid var(--fg);
  outline-offset: 4px;
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  z-index: 10;
  padding: 8px 14px;
  background: var(--fg);
  color: var(--bg);
  font-size: 14px;
}

.skip-link:focus {
  top: 16px;
}

/* Header */

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px var(--gutter);
  mix-blend-mode: difference;
}

.wordmark {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 0.32em;
}

.site-header nav {
  display: flex;
  gap: clamp(20px, 4vw, 40px);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.site-header nav a {
  color: var(--fg-muted);
  transition: color 0.3s var(--ease);
}

.site-header nav a:hover {
  color: var(--fg);
}

/* Hero */

.hero {
  min-height: 100vh;
  min-height: 100svh;
  text-shadow: 0 0 28px rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 120px var(--gutter) 96px;
  max-width: calc(var(--maxw) + 2 * var(--gutter));
  margin: 0 auto;
  position: relative;
}

.eyebrow {
  margin: 0 0 28px;
  font-size: 12px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--fg-faint);
}

.hero__title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(44px, 11vw, 136px);
  line-height: 0.95;
  letter-spacing: -0.035em;
}

.hero__title span {
  display: block;
}

.hero__title span:nth-child(2) {
  color: var(--fg-muted);
}

.hero__title span:nth-child(3) {
  color: var(--fg-faint);
}

.hero__lead {
  margin: 36px 0 0;
  max-width: 34ch;
  font-size: clamp(16px, 1.6vw, 19px);
  color: var(--fg-muted);
}

.scroll-cue {
  position: absolute;
  left: var(--gutter);
  bottom: 40px;
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--fg-faint);
}

.scroll-cue__line {
  width: 64px;
  height: 1px;
  background: var(--line-strong);
  transform-origin: left;
  animation: cue 2.4s var(--ease) infinite;
}

@keyframes cue {
  0% { transform: scaleX(0); }
  50% { transform: scaleX(1); }
  100% { transform: scaleX(1); opacity: 0; }
}

/* Sections */

.section {
  max-width: calc(var(--maxw) + 2 * var(--gutter));
  margin: 0 auto;
  padding: clamp(80px, 14vh, 160px) var(--gutter);
}

.section__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px 32px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.section h2 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(32px, 5vw, 56px);
  letter-spacing: -0.02em;
}

.section__note {
  margin: 0;
  font-size: 14px;
  color: var(--fg-faint);
}

/* Projects */

.projects {
  list-style: none;
  margin: 0;
  padding: 0;
}

.project {
  border-bottom: 1px solid var(--line);
}

.project__link {
  display: grid;
  grid-template-columns: 56px 1fr auto;
  grid-template-areas:
    'index name url'
    'index desc url';
  align-items: center;
  column-gap: 24px;
  padding: 32px 0;
  position: relative;
  isolation: isolate;
  transition: padding 0.5s var(--ease);
}

a.project__link::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--fg);
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform 0.5s var(--ease);
  z-index: -1;
}

a.project__link:hover,
a.project__link:focus-visible {
  padding-left: 20px;
  padding-right: 20px;
  color: var(--bg);
}

a.project__link:hover::before,
a.project__link:focus-visible::before {
  transform: scaleY(1);
}

a.project__link:hover .project__desc,
a.project__link:hover .project__index,
a.project__link:focus-visible .project__desc,
a.project__link:focus-visible .project__index {
  color: var(--bg);
}

.project__index {
  grid-area: index;
  font-family: var(--font-display);
  font-size: 13px;
  color: var(--fg-faint);
}

.project__name {
  grid-area: name;
  font-family: var(--font-display);
  font-size: clamp(24px, 3.4vw, 36px);
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.project__desc {
  grid-area: desc;
  font-size: 14px;
  color: var(--fg-muted);
}

.project__url {
  grid-area: url;
  font-size: 13px;
  letter-spacing: 0.08em;
}

.project--soon .project__name,
.project--soon .project__url {
  color: var(--fg-faint);
}

/* Contact */

.contact {
  list-style: none;
  margin: 0;
  padding: 0;
}

.contact li {
  display: grid;
  grid-template-columns: 120px 1fr;
  align-items: baseline;
  gap: 8px 24px;
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
}

.contact__label {
  font-size: 12px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--fg-faint);
}

.contact__value {
  font-family: var(--font-display);
  font-size: clamp(18px, 3.2vw, 34px);
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
  background-image: linear-gradient(var(--fg), var(--fg));
  background-size: 0% 1px;
  background-position: 0 100%;
  background-repeat: no-repeat;
  transition: background-size 0.5s var(--ease);
}

.contact__value:hover,
.contact__value:focus-visible {
  background-size: 100% 1px;
}

/* Footer */

.site-footer {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  max-width: calc(var(--maxw) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 40px var(--gutter) 48px;
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--fg-faint);
}

.site-footer p {
  margin: 0;
}

@media (max-width: 600px) {
  .project__link {
    grid-template-columns: 40px 1fr;
    grid-template-areas:
      'index name'
      'index desc'
      'index url';
    row-gap: 4px;
  }

  .project__url {
    margin-top: 8px;
  }

  .contact li {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
