/* =========================================
   HAIP — Design System
   ========================================= */

@import url('https://fonts.googleapis.com/css2?family=Anek+Malayalam:wght@100..800&display=swap');
@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/variable/pretendardvariable.min.css');

:root {
  --white:   #FFFFFF;
  --lime:    #F3FF94;
  --blue:    #0425FF;
  --black:   #111111;
  --gray-1:  #F7F7F7;
  --gray-2:  #E8E8E8;
  --gray-3:  #AAAAAA;
  --gray-4:  #666666;

  --font: 'Pretendard Variable', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --max: 1200px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --transition: 0.3s var(--ease);
  --radius: 10px;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body {
  font-family: var(--font);
  font-weight: 400;
  color: var(--black);
  background: var(--white);
  overflow-x: hidden;
}
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

/* ── Container ── */
.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 48px;
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 14px 28px;
  border-radius: 100px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: var(--transition);
  white-space: nowrap;
}
.btn-primary {
  background: var(--blue);
  color: var(--white);
}
.btn-primary:hover {
  background: #0318CC;
  transform: translateY(-2px);
}
.btn-secondary {
  background: var(--gray-1);
  color: var(--black);
}
.btn-secondary:hover {
  background: var(--gray-2);
  transform: translateY(-2px);
}
.btn-outline {
  border: 1.5px solid var(--gray-2);
  color: var(--black);
  padding: 12px 24px;
}
.btn-outline:hover {
  border-color: var(--blue);
  color: var(--blue);
}

/* ── Section shared ── */
.section-label {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 16px;
}
.section-title {
  font-size: clamp(28px, 3.5vw, 44px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: var(--black);
}

/* ── Scroll Reveal ── */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* =========================================
   NAV
   ========================================= */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.nav.scrolled {
  border-bottom-color: var(--gray-2);
  box-shadow: 0 1px 24px rgba(0,0,0,0.06);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 48px;
  height: 80px;
}
.nav-logo {
  font-family: 'Pretendard Variable', -apple-system, sans-serif;
  font-size: 44px;
  font-weight: 700;
  color: var(--blue);
  letter-spacing: -0.04em;
  flex-shrink: 0;
  line-height: 1;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--gray-4);
  padding: 8px 14px;
  border-radius: 8px;
  transition: color 0.2s, background 0.2s;
}
.nav-links a:hover { color: var(--black); background: var(--gray-1); }
.nav-links a.active { color: var(--blue); }
.nav-cta {
  background: var(--blue) !important;
  color: var(--white) !important;
  padding: 9px 20px !important;
  border-radius: 100px !important;
  font-weight: 600 !important;
}
.nav-cta:hover { background: #0318CC !important; }

/* Mobile burger */
.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}
.nav-burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--black);
  border-radius: 2px;
  transition: var(--transition);
}

/* Mobile menu */
.nav-mobile {
  display: none;
  flex-direction: column;
  padding: 12px 24px 20px;
  border-top: 1px solid var(--gray-2);
  gap: 4px;
}
.nav-mobile a {
  padding: 12px 8px;
  font-size: 16px;
  font-weight: 500;
  color: var(--black);
  border-bottom: 1px solid var(--gray-1);
}
.nav-mobile a:last-child { border-bottom: none; }
.nav-mobile.open { display: flex; }
.nav-burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; }
.nav-burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* =========================================
   HERO
   ========================================= */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 0 80px;
  position: relative;
  overflow: hidden;
}
.hero-inner {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 48px;
  position: relative;
  z-index: 1;
}
.hero-heading {
  font-size: clamp(52px, 7.5vw, 104px);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1.0;
  margin-bottom: 32px;
  overflow: hidden;
}
.hero-heading .line {
  display: block;
  animation: slideUp 0.7s var(--ease) both;
}
.hero-heading .line:nth-child(1) { animation-delay: 0.2s; }
.hero-heading .line:nth-child(2) { animation-delay: 0.35s; }
.hero-heading .line:nth-child(3) { animation-delay: 0.5s; color: var(--blue); }
.hero-sub {
  font-size: clamp(15px, 1.5vw, 18px);
  color: var(--gray-4);
  line-height: 1.7;
  margin-bottom: 44px;
  max-width: 480px;
  animation: fadeUp 0.7s var(--ease) 0.65s both;
}
.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  animation: fadeUp 0.7s var(--ease) 0.8s both;
}

/* Hero accent — lime shape */
.hero-accent {
  position: absolute;
  right: -40px;
  top: 50%;
  transform: translateY(-50%);
  width: clamp(320px, 40vw, 560px);
  height: clamp(320px, 40vw, 560px);
  background: var(--lime);
  border-radius: 40% 60% 60% 40% / 50% 40% 60% 50%;
  opacity: 0.55;
  animation: morph 12s ease-in-out infinite;
  pointer-events: none;
}

/* =========================================
   SERVICES
   ========================================= */
.services {
  padding: 120px 0;
  background: var(--white);
}
.services-circles {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: center;
  margin-top: 64px;
}
.service-circle {
  position: relative;
  flex: 1;
  min-width: 0;
  aspect-ratio: 1 / 1;
}
.service-circle-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
  user-select: none;
}
.service-circle-content {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20% 12%;
  gap: 18px;
}
.service-circle h3 {
  font-size: clamp(20px, 2vw, 28px);
  font-weight: 900;
  letter-spacing: -0.03em;
  color: var(--black);
  line-height: 1.1;
}
.service-circle ul {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.service-circle li {
  font-size: clamp(12px, 1vw, 14px);
  color: var(--black);
  line-height: 1.6;
  font-weight: 400;
}
.services-link {
  margin-top: 48px;
  text-align: right;
}

/* =========================================
   WORKS (Portfolio Preview)
   ========================================= */
.works {
  padding: 120px 0;
}
.works-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 48px;
}
.works-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.work-card {
  border-radius: 16px;
  overflow: hidden;
  background: var(--gray-1);
  transition: transform 0.3s var(--ease), box-shadow 0.3s;
  cursor: pointer;
  display: block;
  color: inherit;
}
.work-card:first-child {
  grid-column: span 2;
}
.work-card:hover { transform: translateY(-6px); box-shadow: 0 20px 60px rgba(0,0,0,0.1); }
.work-thumb {
  width: 100%;
  padding-bottom: 62%;
  position: relative;
  overflow: hidden;
}
.work-card:first-child .work-thumb { padding-bottom: 52%; }
.work-thumb-inner {
  position: absolute;
  inset: 0;
  background: var(--gray-2);
  transition: transform 0.5s var(--ease);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-3);
  letter-spacing: 0.05em;
}
.work-card:hover .work-thumb-inner { transform: scale(1.04); }
.work-info {
  padding: 20px 24px;
}
.work-cat {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 6px;
  display: block;
}
.work-info h3 {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--black);
}

/* =========================================
   STATS BAR
   ========================================= */
.stats {
  background: var(--blue);
  padding: 56px 0;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  text-align: center;
}
.stat-item {
  padding: 0 20px;
  border-right: 1px solid rgba(255,255,255,0.15);
}
.stat-item:last-child { border-right: none; }
.stat-num {
  font-size: clamp(32px, 4vw, 52px);
  font-weight: 900;
  color: var(--lime);
  letter-spacing: -0.04em;
  line-height: 1;
  margin-bottom: 8px;
}
.stat-label {
  font-size: 13px;
  color: rgba(255,255,255,0.65);
  font-weight: 500;
}

/* =========================================
   FOOTER
   ========================================= */
.footer {
  background: var(--lime);
  padding: 80px 0 48px;
}
.footer-cta {
  text-align: center;
  margin-bottom: 72px;
}
.footer-cta-eyebrow {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(0,0,0,0.4);
  margin-bottom: 20px;
}
.footer-cta-title {
  font-size: clamp(36px, 5vw, 68px);
  font-weight: 900;
  letter-spacing: -0.04em;
  color: var(--black);
  margin-bottom: 36px;
  line-height: 1.1;
}
.footer-cta-title span { color: var(--blue); }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 32px;
  border-top: 1px solid rgba(0,0,0,0.12);
  flex-wrap: wrap;
  gap: 16px;
}
.footer-logo {
  font-size: 20px;
  font-weight: 900;
  color: var(--blue);
  letter-spacing: -0.04em;
}
.footer-links {
  display: flex;
  gap: 24px;
}
.footer-links a {
  font-size: 13px;
  font-weight: 500;
  color: rgba(0,0,0,0.55);
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--blue); }
.footer-copy {
  font-size: 12px;
  color: rgba(0,0,0,0.4);
}

/* =========================================
   ABOUT PAGE — excerpt
   ========================================= */
.page-hero {
  padding: 160px 0 80px;
  background: var(--white);
}
.page-hero-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 20px;
}
.page-hero-title {
  font-size: clamp(40px, 6vw, 80px);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1.05;
  margin-bottom: 28px;
  max-width: 800px;
}
.page-hero-sub {
  font-size: 18px;
  color: var(--gray-4);
  line-height: 1.7;
  max-width: 560px;
}
.page-divider {
  height: 1px;
  background: var(--gray-2);
  margin: 80px 0;
}

/* =========================================
   KEYFRAMES
   ========================================= */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes slideUp {
  from { transform: translateY(100%); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}
@keyframes morph {
  0%, 100% { border-radius: 40% 60% 60% 40% / 50% 40% 60% 50%; }
  33%       { border-radius: 60% 40% 50% 50% / 40% 60% 50% 50%; }
  66%       { border-radius: 50% 50% 40% 60% / 60% 50% 40% 50%; }
}

/* =========================================
   RESPONSIVE
   ========================================= */
@media (max-width: 1024px) {
  .container { padding: 0 32px; }
  .nav-inner { padding: 0 32px; }
  .hero-inner { padding: 0 32px; }
  .services-grid { grid-template-columns: 1fr 1fr; }
  .works-grid { grid-template-columns: 1fr 1fr; }
  .work-card:first-child { grid-column: span 1; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 40px 0; }
  .stat-item:nth-child(2) { border-right: none; }
}

@media (max-width: 768px) {
  .container { padding: 0 20px; }
  .nav-inner { padding: 0 20px; }
  .hero-inner { padding: 0 20px; }
  .nav-links { display: none; }
  .nav-burger { display: flex; }
  .hero { min-height: 100svh; padding: 100px 0 60px; }
  .hero-accent { width: 280px; height: 280px; right: -80px; opacity: 0.4; }
  .services { padding: 80px 0; }
  .services-circles { flex-direction: column; align-items: center; gap: 0; }
  .service-circle { width: min(380px, 88vw); flex: none; }
  .works { padding: 80px 0; }
  .works-header { flex-direction: column; align-items: flex-start; gap: 20px; }
  .works-grid { grid-template-columns: 1fr; }
  .stats { padding: 40px 0; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .footer { padding: 60px 0 36px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .page-hero { padding: 120px 0 60px; }
}
