﻿:root {
  --bg: #f3f6fb;
  --surface: #ffffff;
  --text: #0f172a;
  --muted: #526076;
  --accent: #0b67ff;
  --accent-soft: #dcebff;
  --line: #dfe6f1;
  --radius: 20px;
  --snake: #000000;
  --snake-soft: #1f1f1f;
}

@font-face {
  font-family: "Pagkaki";
  src: url("./fonts/PAGKAKI-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Manrope", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 8% 6%, #dff1ff 0, transparent 30%),
    radial-gradient(circle at 84% 4%, #e8ffe8 0, transparent 28%),
    var(--bg);
}

.intro {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 1.5rem;
  transition: padding 700ms ease, place-items 700ms ease;
}
.logo-stage { width: min(92vw, 980px); display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.logo-wrap {
  position: relative;
  width: min(90vw, 760px);
  aspect-ratio: 5 / 3;
  display: grid;
  place-items: center;
  transition: transform 700ms ease, width 700ms ease;
}
.hero-logo {
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  filter: grayscale(100%) opacity(0.25);
}
.line-overlay { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
#snakePath {
  fill: none;
  stroke: var(--snake);
  stroke-width: 58;
  stroke-linecap: round;
  stroke-linejoin: round;
  transform-origin: center center;
  animation: drawLine 1.8s ease-in-out forwards, snakeWave 560ms ease-in-out infinite;
}
.keys-layer { fill: #000; }
.logo-key {
  opacity: 0;
  transform-box: fill-box;
  transform-origin: center;
  transform: translateY(20px) scale(0.82);
  transition: all 0.4s ease-out;
}
.logo-key.show { opacity: 1; transform: translateY(0) scale(1); }
.logo-wrap.keys-idle .logo-key.show { animation: keySnakeIdle 620ms ease-in-out infinite; }
body.keyboard-docked .logo-wrap {
  width: min(72vw, 620px);
  transform: translateY(-36px) scale(0.94);
}

.page-content {
  min-height: 40vh;
  display: grid;
  place-items: center;
  padding: 0 1rem 0.6rem;
  opacity: 0;
  transform: translateY(-24px);
  transition: opacity 700ms ease, transform 700ms ease;
}
body.content-ready .page-content { opacity: 1; transform: translateY(0); }
.profile-wrap {
  width: min(34vw, 190px);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  overflow: hidden;
  border: 4px solid #fff;
  box-shadow: 0 16px 34px rgba(8, 25, 48, 0.2);
}
.profile-image { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; transform: scale(1.22); display: block; }
.profile-name {
  margin: 0.55rem 0 0;
  font-family: "Pagkaki", "Manrope", sans-serif;
  font-weight: 800;
  font-size: clamp(1.2rem, 3.8vw, 1.7rem);
  letter-spacing: 0.01em;
}

.site-content { opacity: 0; transform: translateY(16px); transition: opacity 700ms ease, transform 700ms ease; }
body.content-ready .site-content { opacity: 1; transform: translateY(0); }

.section { padding: 3.8rem 1.1rem; }
.container { width: min(1100px, 100%); margin: 0 auto; }
.hero { padding-top: 1.2rem; }
.hero-inner {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0.4rem 0.1rem 0;
  box-shadow: none;
}
.eyebrow { margin: 0 0 0.5rem; color: #2f7f43; font-weight: 700; font-size: 0.85rem; letter-spacing: 0.08em; text-transform: uppercase; }
h1 { margin: 0; font-size: clamp(2rem, 8vw, 3.8rem); line-height: 1.07; }
.subtitle { margin: 0.8rem 0 0; color: #1e2d49; font-weight: 700; font-size: clamp(1rem, 3.8vw, 1.35rem); }
.lead { margin: 0.95rem 0 0; color: var(--muted); max-width: 640px; font-size: clamp(0.96rem, 3.2vw, 1.1rem); }
.hero-cta { margin-top: 1.4rem; display: flex; gap: 0.65rem; flex-wrap: wrap; }

.btn {
  text-decoration: none;
  border-radius: 999px;
  padding: 0.8rem 1.15rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 180ms ease, box-shadow 180ms ease, background-color 180ms ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 10px 24px rgba(11, 103, 255, 0.24); }
.btn-ghost { border: 1px solid #bfd4ff; color: #143468; background: #f4f8ff; }

.section-title { margin: 0; font-size: clamp(1.4rem, 5vw, 2rem); }
.section-intro { margin: 0.6rem 0 0; color: var(--muted); }
.service-grid, .project-grid, .steps { margin-top: 1.2rem; display: grid; gap: 0.85rem; }
.service-grid, .project-grid, .steps { grid-template-columns: 1fr; }
.card, .project, .step, .contact-box, .why .container { background: transparent; border: 0; border-radius: 0; }
.card, .project, .step, .contact-box { padding: 0.2rem 0; }
.icon { font-size: 1.4rem; display: inline-flex; width: 2.1rem; height: 2.1rem; align-items: center; justify-content: center; border-radius: 10px; background: #ecf4ff; }
.card h3, .project h3, .step h3 { margin: 0.7rem 0 0; }
.card p, .project p { margin: 0.45rem 0 0; color: var(--muted); }
.card, .project, .step {
  border-bottom: 1px solid #e6edf7;
  padding-bottom: 0.95rem;
}
.project-thumb { width: 100%; aspect-ratio: 16/10; border-radius: 14px; border: 0; }
.type-web { background: linear-gradient(135deg, #dff1ff, #b9d8ff); }
.type-edu { background: linear-gradient(135deg, #efe6ff, #d7ccff); }
.type-info { background: linear-gradient(135deg, #fff0db, #ffddb3); }
.type-illu { background: linear-gradient(135deg, #ffe6ec, #ffc8d7); }
.type-anim { background: linear-gradient(135deg, #d8fff0, #b7efd6); }
.type-portfolio { background: linear-gradient(135deg, #f0f2f8, #dbe2f1); }
.project-link { margin-top: 0.8rem; display: inline-flex; color: #0b4ab8; font-weight: 700; text-decoration: none; }

.collab-grid {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
}

.collab-item {
  min-height: 64px;
  display: grid;
  place-items: center;
  text-align: center;
  font-weight: 700;
  color: #2e3a51;
  background: #ffffff;
  border: 1px solid #e3eaf5;
  border-radius: 12px;
  padding: 0.7rem;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.collab-logo {
  max-width: min(150px, 82%);
  max-height: 46px;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

.collab-item:hover {
  transform: scale(1.02);
  border-color: #cad9ef;
  box-shadow: 0 8px 18px rgba(9, 28, 56, 0.08);
}

.collab-note {
  margin: 0.9rem 0 0;
  color: var(--muted);
  font-size: 0.96rem;
}

.credibility-box {
  background: #ffffff;
  border: 1px solid #e2e8f2;
  border-radius: 16px;
  padding: 1.15rem 1rem;
}

.credibility-text {
  margin: 0.75rem 0 0;
  color: #2e3a51;
  line-height: 1.55;
}

.stats-grid {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.7rem;
}

.stat-card {
  border: 1px solid #e7edf6;
  border-radius: 12px;
  padding: 0.85rem 0.8rem;
  background: #fff;
}

.stat-number {
  margin: 0;
  font-size: clamp(1.8rem, 8vw, 2.6rem);
  font-weight: 800;
  line-height: 1;
  color: #0b0f19;
}

.stat-label {
  margin: 0.45rem 0 0;
  color: #48556d;
  font-size: 0.95rem;
}

.credibility-btn {
  margin-top: 1rem;
}
.why .container { padding: 0.2rem 0; }
.why-list { margin: 0.8rem 0 0; padding-left: 1.1rem; color: #1e2d49; }
.why-list li + li { margin-top: 0.45rem; }
.step { display: flex; align-items: center; gap: 0.75rem; }
.step span { width: 2rem; height: 2rem; border-radius: 50%; display: inline-grid; place-items: center; background: var(--accent-soft); color: #0c4cb7; font-weight: 800; }
.contact-box p { margin: 0.7rem 0 0; color: var(--muted); }
.contact-box a { color: #0b4ab8; }
.btn-large { margin-top: 1.1rem; width: fit-content; }

.services .section-title,
.projects .section-title,
.why .section-title,
.process .section-title,
.contact .section-title {
  margin-bottom: 0.5rem;
}

.reveal { opacity: 0; transform: translateY(18px); transition: opacity 520ms ease, transform 520ms ease; }
.reveal.show { opacity: 1; transform: translateY(0); }

@keyframes drawLine {
  0% { stroke-dashoffset: var(--path-length); }
  100% { stroke-dashoffset: 0; }
}
@keyframes snakeWave {
  0% { transform: translateY(0) skewX(0deg); stroke: var(--snake); }
  50% { transform: translateY(-3px) skewX(0.8deg); stroke: var(--snake-soft); }
  100% { transform: translateY(0) skewX(0deg); stroke: var(--snake); }
}
@keyframes keySnakeIdle {
  0% { transform: translateY(0) scale(1) rotate(0deg); }
  50% { transform: translateY(-2px) scale(1.01) rotate(0.7deg); }
  100% { transform: translateY(0) scale(1) rotate(0deg); }
}

@media (min-width: 760px) {
  .section { padding: 4.6rem 1.5rem; }
  .hero-inner { padding: 2.6rem 2rem; }
  .service-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .collab-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .stats-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .credibility-box { padding: 1.4rem 1.25rem; }
}
@media (min-width: 1040px) { .project-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 640px) {
  #snakePath { stroke-width: 56; }
  .profile-wrap { width: min(58vw, 155px); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
