/* ==========================================================
   Sindhu Asmoro · Portfolio — Cloudflare Pages static site
   Mobile-first; works on phone (portrait) and desktop.
   ========================================================== */

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: #121212;
  color: #111;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior: none;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; }

/* ----------- Top story progress bar ----------- */
.progress-bar {
  position: fixed;
  top: max(env(safe-area-inset-top, 0px), 14px);
  left: 0;
  right: 0;
  z-index: 30;
  display: flex;
  gap: 6px;
  padding: 0 18px;
  pointer-events: none;
}

.progress-segment {
  flex: 1;
  height: 3px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.35);
  overflow: hidden;
  position: relative;
}

.slide-light ~ * .progress-segment,
.slide-light .progress-segment {
  background: rgba(0, 0, 0, 0.18);
}

.progress-segment::after {
  content: "";
  position: absolute;
  inset: 0;
  width: 0;
  background: #fff;
  transition: width 0.15s linear;
}

.slide-light .progress-segment::after,
body[data-current="0"] .progress-segment::after,
body[data-current="2"] .progress-segment::after {
  background: #111;
}

.progress-segment.is-filled::after { width: 100%; }
.progress-segment.is-active::after {
  width: 0;
  animation: progress-fill 6s linear forwards;
}

@keyframes progress-fill {
  from { width: 0; }
  to { width: 100%; }
}

/* ----------- Slider container ----------- */
.slider {
  display: flex;
  flex-direction: row;
  height: 100dvh;
  width: 100vw;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  background: #fff;
}

.slider::-webkit-scrollbar { display: none; }

/* ----------- Each slide ----------- */
.slide {
  flex: 0 0 100%;
  width: 100%;
  height: 100dvh;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  position: relative;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
}

.slide-light { background: #fff; color: #111; }
.slide-dark {
  background: #000;
  color: #fff;
}

.slide-inner {
  min-height: 100dvh;
  padding: 64px 24px 96px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.slide-inner-pad { padding: 64px 24px 80px; }
.slide-inner-spread {
  justify-content: space-between;
  align-items: stretch;
}

/* ===========================================================
   SLIDE 1 — PROFILE
   =========================================================== */
.hero-name {
  margin: 0;
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 900;
  font-size: 34px;
  letter-spacing: -0.5px;
  align-self: flex-start;
  color: #111;
}

.profil-btn-wrap { align-self: flex-start; margin-top: 8px; }

.btn-profil {
  display: inline-flex;
  align-items: flex-start;
  gap: 8px;
  background: #111;
  color: #fff;
  border: none;
  border-radius: 14px;
  padding: 12px 16px;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.45;
  letter-spacing: 0.2px;
  text-align: left;
  max-width: 320px;
  white-space: normal;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease;
}
.btn-profil svg { flex-shrink: 0; margin-top: 3px; }

.btn-profil:hover { background: #333; }
.btn-profil:active { transform: scale(0.96); }

.photo-crop {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid #111;
  background: #f5f5f5;
  margin: 24px 0 18px;
  flex-shrink: 0;
}

.photo-crop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 22%;
  display: block;
}

.section-label {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 2px;
  margin: 0;
  color: #111;
}

.section-underline {
  display: block;
  width: 40px;
  height: 2px;
  background: #111;
  margin: 6px auto 14px;
}

.template-text {
  font-size: 14px;
  line-height: 1.6;
  color: #333;
  text-align: center;
  margin: 0 24px 14px;
  max-width: 480px;
}

.tag-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 22px;
}

.tag-pill {
  display: inline-block;
  border: 1px solid #111;
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 10px;
  font-weight: 600;
  color: #111;
  background: #fff;
}

.sosmed-row {
  display: flex;
  gap: 14px;
  justify-content: center;
  align-items: center;
  margin-bottom: 8px;
}

.sosmed-chip {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #f7f7f7;
  border: 1px solid #e6e6e6;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease;
}

.sosmed-chip:hover { background: #eee; }
.sosmed-chip:active { transform: scale(0.92); }
.sosmed-chip svg { display: block; }

.handles-line {
  font-size: 11px;
  color: #777;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  margin: 4px 0 22px;
  text-align: center;
}

.thin-divider {
  border: none;
  border-top: 1px solid #e0e0e0;
  margin: 4px 40px 10px;
}

/* ----------- Music Player ----------- */
.music-player {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 14px 24px 24px;
  background: #f5f5f5;
  border-radius: 14px;
  padding: 14px 14px 10px;
}

.music-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.music-note-icon {
  flex-shrink: 0;
  color: #111;
  opacity: 0.7;
}

.music-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
  text-align: left;
}

.music-title {
  font-size: 10px;
  font-weight: 700;
  color: #111;
  letter-spacing: 0.2px;
}

.music-artist {
  font-size: 9px;
  color: #666;
}

.music-audio {
  width: 100%;
  height: 36px;
  border-radius: 8px;
  accent-color: #111;
}

.dev-credit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #111;
  font-size: 11px;
  text-decoration: none;
  transition: opacity 0.15s ease;
}

.dev-credit:hover { opacity: 0.7; }
.dev-credit-dark { color: #111; }

.dev-by { color: #555; }
.dev-credit strong { color: #111; font-weight: 700; }

.dev-email {
  font-size: 10px;
  color: #888;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  margin: 2px 0 40px;
  text-align: center;
}

/* ===========================================================
   SLIDE 2 — INTERACTION
   =========================================================== */
.slide-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.slide-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 25%;
  display: block;
}

.slide-bg-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.35) 0%,
    rgba(0, 0, 0, 0.5) 50%,
    rgba(0, 0, 0, 0.85) 100%
  );
}

.slide-dark .slide-inner { position: relative; z-index: 1; padding: 64px 24px 48px; }

.kicker {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  color: rgba(255, 255, 255, 0.6);
  margin: 0;
  text-align: left;
  align-self: flex-start;
}

.menu-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
  max-width: 520px;
  margin: 28px 0;
}

.menu-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 60px;
  padding: 0 18px;
  border: none;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 22px;
  font-weight: 700;
  cursor: pointer;
  text-align: left;
  transition: background 0.15s ease, transform 0.15s ease;
  text-decoration: none;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.menu-btn:hover { background: rgba(0, 0, 0, 0.7); }
.menu-btn:active { transform: scale(0.98); }

.menu-btn-cta {
  background: #25D366;
  color: #fff;
}

.menu-btn-cta:hover { background: #1eb858; }

.menu-arrow { font-size: 22px; line-height: 1; }

.hairline {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  margin: 0 0 14px;
}

.brand-mark {
  margin: 0;
  font-family: 'Inter', sans-serif;
  font-weight: 900;
  font-size: 56px;
  letter-spacing: 4px;
  color: #fff;
  text-align: left;
}

/* ===========================================================
   SLIDE 3 — SOSMED
   =========================================================== */
.sosmed-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 720px;
  margin-bottom: 6px;
}

.product-label {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  font-size: 14px;
  font-weight: 700;
  color: #111;
}

.burger {
  display: flex;
  flex-direction: column;
  gap: 3px;
  align-items: flex-end;
}

.burger span {
  display: block;
  width: 18px;
  height: 2px;
  background: #111;
}

.burger span.short { width: 12px; }

.thick-divider {
  border: none;
  border-top: 1.5px solid #111;
  margin: 6px 0 10px;
  width: 100%;
  max-width: 720px;
}

.big-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 900;
  font-size: 58px;
  letter-spacing: -1px;
  margin: 4px 0 0;
  color: #111;
  align-self: flex-start;
  max-width: 720px;
}

.subtitle-line {
  font-size: 16px;
  font-weight: 600;
  color: #444;
  margin: 4px 0 12px;
  align-self: flex-start;
  max-width: 720px;
}

.hairline-light {
  border: none;
  border-top: 1px solid #ddd;
  margin: 0 0 16px;
  width: 100%;
  max-width: 720px;
}

.grid-2x2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  width: 100%;
  max-width: 720px;
  margin-bottom: 24px;
}

.grid-card {
  border: 1px solid #f0f0f0;
  border-radius: 12px;
  padding: 8px;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: #111;
  background: #fff;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.grid-card:hover { box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08); }
.grid-card:active { transform: scale(0.98); }

.card-image {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  overflow: hidden;
  background: #f5f5f5;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.platform-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

.platform-badge svg { display: block; }

.card-meta { padding: 8px 4px 4px; }

.card-platform {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  font-size: 14px;
  color: #111;
}

.card-platform svg { display: block; }

.card-handle {
  font-size: 11px;
  color: #777;
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  margin-top: 2px;
  display: block;
}

/* ----------- Dots ----------- */
.dots {
  position: fixed;
  bottom: 18px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 8px;
  z-index: 30;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.25);
  transition: width 0.2s ease, background 0.2s ease;
  cursor: pointer;
}

body[data-current="1"] .dot { background: rgba(255, 255, 255, 0.5); }
.dot.is-active {
  width: 12px;
  background: #111;
}
body[data-current="1"] .dot.is-active { background: #fff; }

/* ===========================================================
   MODAL
   =========================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  animation: fade-in 0.18s ease;
}

.modal-overlay[hidden] { display: none; }

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-card {
  background: #fff;
  border-radius: 20px;
  padding: 24px;
  width: 100%;
  max-width: 460px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
  animation: pop-in 0.22s ease;
}

@keyframes pop-in {
  from { transform: scale(0.94); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.modal-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
}

.modal-title {
  margin: 0 0 16px;
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 800;
  font-size: 18px;
  letter-spacing: 1px;
  text-align: center;
  color: #111;
}

.modal-body {
  overflow-y: auto;
  flex: 1;
  margin-bottom: 20px;
  font-size: 14px;
  line-height: 1.6;
  color: #444;
}

.modal-body h4 {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 700;
  color: #111;
}

.modal-body p { margin: 0 0 10px; }

.modal-body-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  padding: 8px 4px;
}

.big-punch {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 900;
  font-size: 26px;
  color: #111;
  margin: 0;
  line-height: 1.3;
}

.muted { color: #888; font-size: 13px; margin: 0; }

.modal-close {
  width: 100%;
  height: 48px;
  border: none;
  border-radius: 10px;
  background: #111;
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.15s ease;
}

.modal-close:hover { background: #333; }
.modal-close:active { transform: scale(0.98); }

/* ===========================================================
   Responsive: small phones
   =========================================================== */
@media (max-width: 380px) {
  .photo-crop { width: 150px; height: 150px; }
  .big-title { font-size: 48px; }
  .brand-mark { font-size: 44px; }
  .menu-btn { font-size: 20px; min-height: 56px; }
  .hero-name { font-size: 30px; }
}

/* ===========================================================
   Responsive: tablets and desktop — center phone-like viewport
   =========================================================== */
@media (min-width: 720px) {
  body {
    background: #181818;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .slider {
    width: 100%;
    max-width: 420px;
    height: 90dvh;
    max-height: 860px;
    border-radius: 32px;
    overflow-x: auto;
    overflow-y: hidden;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
    background: #fff;
  }

  .slide { overflow-y: auto; }

  .progress-bar {
    position: fixed;
    top: max(env(safe-area-inset-top, 0px), 14px);
    left: 50%;
    transform: translateX(-50%);
    max-width: 420px;
  }

  .dots {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    bottom: 18px;
    max-width: 420px;
  }
}
