/* Author: Dimas Aulia Trianggana (dat.vaditra)
 * Email: dimasauliat@gmail.com
 * Copyright (c) 2026. Dimas Aulia Trianggana. All rights reserved. */

:root {
  --ink: #ffffff;
  --ink-soft: rgba(255, 255, 255, 0.88);
  --ink-mute: rgba(255, 255, 255, 0.55);
  --font-ui: "Poppins", "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

.landing-body {
  min-height: 100vh;
  min-height: 100dvh;
  font-family: var(--font-ui);
  background: #0b3a8c;
  color: var(--ink);
  overflow: hidden;
}

.splash {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: clamp(1.5rem, 4vw, 3rem);
  background:
    radial-gradient(120% 80% at 20% 0%, rgba(255, 255, 255, 0.14), transparent 55%),
    linear-gradient(145deg, #1d5fd0 0%, #0f4cb8 42%, #0b3a8c 100%);
  cursor: pointer;
}

.splash.is-exiting {
  animation: splash-exit 0.32s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  pointer-events: none;
}

html.splash-leaving,
html.splash-leaving body {
  background: #0b3a8c;
}

.splash__glow {
  position: absolute;
  inset: 22% 24% auto;
  height: 36%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.16), transparent 70%);
  filter: blur(6px);
  opacity: 0;
  animation: splash-fade 1.1s ease 0.15s forwards;
  pointer-events: none;
  z-index: 0;
}

.splash__sweep {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    transparent 38%,
    rgba(255, 255, 255, 0.1) 50%,
    transparent 62%
  );
  transform: translateX(-120%);
  animation: splash-sweep 1.55s cubic-bezier(0.22, 1, 0.36, 1) 0.25s forwards;
  pointer-events: none;
  z-index: 1;
}

.splash__stage {
  position: relative;
  z-index: 2;
  width: min(720px, 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.splash__unived {
  width: clamp(110px, 20vw, 150px);
  height: auto;
  display: block;
  margin-bottom: clamp(1rem, 2.8vh, 1.5rem);
  opacity: 0;
  transform: translateY(-28px) scale(0.9);
  animation: splash-bounce 1s cubic-bezier(0.22, 1.35, 0.36, 1) 0.12s forwards;
  filter: drop-shadow(0 16px 28px rgba(0, 0, 0, 0.28));
}

.splash__rule {
  width: 0;
  height: 1px;
  margin: 0 0 clamp(1rem, 2.6vh, 1.4rem);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.75), transparent);
  animation: splash-rule 0.7s ease 0.7s forwards;
}

.splash__title {
  margin: 0;
  max-width: 34rem;
  line-height: 1.15;
}

.splash__line {
  display: block;
  opacity: 0;
  transform: translateX(-42px);
  animation: splash-slide 0.75s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.splash__line--0 {
  animation-delay: 0.85s;
}

.splash__line--1 {
  animation-delay: 1.05s;
}

.splash__line--2 {
  animation-delay: 1.22s;
}

/* SIOBE — sama gaya login (Poppins 800, putih) */
.splash__line--brand {
  font-size: clamp(3rem, 9vw, 4.5rem);
  font-weight: 800;
  letter-spacing: 1px;
  color: #fff;
  line-height: 1.05;
}

.splash__line--tagline {
  margin-top: 0.7rem;
  font-size: clamp(1rem, 2.4vw, 1.35rem);
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.4;
  color: var(--ink-soft);
}

.splash__line--org {
  margin-top: 0.75rem;
  font-size: clamp(0.78rem, 1.7vw, 0.95rem);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-mute);
}

.splash__skip {
  position: absolute;
  z-index: 3;
  right: clamp(1rem, 3vw, 1.75rem);
  bottom: clamp(1rem, 3vw, 1.75rem);
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-decoration: none;
  opacity: 0;
  animation: splash-fade 0.55s ease 1.55s forwards;
}

.splash__skip:hover,
.splash__skip:focus-visible {
  color: #fff;
  outline: none;
}

@keyframes splash-bounce {
  0% {
    opacity: 0;
    transform: translateY(-28px) scale(0.9);
  }
  55% {
    opacity: 1;
    transform: translateY(8px) scale(1.04);
  }
  75% {
    transform: translateY(-4px) scale(0.98);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes splash-slide {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes splash-rule {
  to {
    width: min(200px, 40vw);
  }
}

@keyframes splash-fade {
  to {
    opacity: 1;
  }
}

@keyframes splash-sweep {
  to {
    transform: translateX(120%);
  }
}

@keyframes splash-exit {
  to {
    opacity: 0;
    filter: blur(6px);
    transform: scale(1.02);
  }
}

/* Cross-document view transition (Chrome/Edge) — soft crossfade */
@view-transition {
  navigation: auto;
}

::view-transition-old(root) {
  animation: vt-fade-out 0.28s cubic-bezier(0.4, 0, 0.2, 1) both;
}

::view-transition-new(root) {
  animation: vt-fade-in 0.38s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes vt-fade-out {
  to {
    opacity: 0;
  }
}

@keyframes vt-fade-in {
  from {
    opacity: 0;
  }
}

@media (max-width: 640px) {
  .splash__line--org {
    letter-spacing: 0.08em;
  }

  .splash__line--tagline {
    padding-inline: 0.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .splash__glow,
  .splash__sweep,
  .splash__unived,
  .splash__rule,
  .splash__line,
  .splash__skip {
    animation: none !important;
  }

  .splash__glow,
  .splash__unived,
  .splash__line,
  .splash__skip {
    opacity: 1;
    transform: none;
  }

  .splash__rule {
    width: min(200px, 40vw);
  }

  .splash__sweep {
    display: none;
  }

  .splash.is-exiting {
    animation: none;
    opacity: 0;
    filter: none;
    transform: none;
  }

  ::view-transition-old(root),
  ::view-transition-new(root) {
    animation: none !important;
  }
}
