/* Codinto Dark Theme — #4664a5 & #BDD0F2 palette */
:root {
  --font-body: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
  --font-heading: "Sora", "Plus Jakarta Sans", sans-serif;
  --primary: #4664a5;
  --primary-light: #5a7ab8;
  --primary-dark: #345489;
  --accent: #bdd0f2;
  --accent-soft: rgba(189, 208, 242, 0.15);
  --bg-deep: #0a0f1a;
  --bg-base: #0f1628;
  --bg-surface: #151f35;
  --bg-elevated: #1c2a45;
  --bg-card: #1a2740;
  --text-primary: #f0f4fc;
  --text-secondary: #bdd0f2;
  --text-muted: #8fa3c7;
  --border: rgba(189, 208, 242, 0.12);
  --border-hover: rgba(189, 208, 242, 0.28);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  --shadow-glow: 0 0 40px rgba(70, 100, 165, 0.2);
  --radius: 16px;
  --radius-sm: 10px;
}

body {
  font-family: var(--font-body);
  background: var(--bg-base);
  color: var(--text-muted);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  letter-spacing: -0.01em;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--text-primary);
  letter-spacing: -0.03em;
}

.navbar-nav .nav-item a,
.button .btn,
.section-title h3,
.footer .single-footer h3 {
  font-family: var(--font-heading);
}

.hero-area .hero-content h1 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.section-title h2 {
  font-weight: 700;
  letter-spacing: -0.035em;
}

.features .single-feature h3 {
  font-family: var(--font-heading);
  font-weight: 600;
  letter-spacing: -0.02em;
}

.our-achievement .title h2,
.our-achievement .single-achievement h3 {
  font-family: var(--font-heading);
}

.section-title h2 {
  color: var(--text-primary);
}

.section-title h3 {
  color: var(--accent);
  letter-spacing: 0.12em;
}

.section-title p {
  color: var(--text-muted);
}

/* Header */
.header {
  background: linear-gradient(180deg, rgba(10, 15, 26, 0.92) 0%, rgba(10, 15, 26, 0) 100%);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.navbar-area.sticky,
.sticky {
  background: rgba(15, 22, 40, 0.95) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow) !important;
}

.sticky .navbar .navbar-nav .nav-item a {
  color: var(--text-secondary);
}

.sticky .navbar-nav .nav-item:hover a,
.sticky .navbar .navbar-nav .nav-item a.active {
  color: var(--accent) !important;
}

.navbar-nav .nav-item a {
  color: var(--text-secondary);
  font-weight: 500;
}

.navbar-nav .nav-item:hover a,
.navbar-nav .nav-item a.active {
  color: var(--accent) !important;
}

.nav-mobile li a {
  color: var(--text-secondary) !important;
}

.nav-mobile li a:hover {
  color: var(--accent) !important;
}

@media only screen and (min-width: 768px) and (max-width: 991px),
       (max-width: 767px) {
  .header .navbar-collapse {
    background: var(--bg-elevated) !important;
    border: 1px solid var(--border) !important;
    border-top: 1px solid var(--border) !important;
    box-shadow: var(--shadow) !important;
  }

  .header .navbar .navbar-nav .nav-item a,
  .header .navbar-nav .nav-item a {
    color: var(--text-secondary) !important;
  }

  .header .navbar .navbar-nav .nav-item a:hover,
  .header .navbar .navbar-nav .nav-item a.active {
    color: var(--accent) !important;
  }
}

/* Hero */
.hero-area {
  background: linear-gradient(135deg, var(--bg-deep) 0%, #1a2d52 45%, var(--primary) 100%);
  padding: 140px 0 100px;
  overflow: hidden;
}

.hero-area::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 70% 40%, rgba(189, 208, 242, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 20% 80%, rgba(70, 100, 165, 0.25) 0%, transparent 50%);
  pointer-events: none;
}

.hero-area .hero-content h1 {
  font-size: clamp(0.95rem, 1.1vw + 0.65rem, 1.45rem);
  line-height: 1.3;
  color: var(--text-primary);
  text-shadow: none;
  white-space: nowrap;
}

@media (max-width: 400px) {
  .hero-area .hero-content h1 {
    font-size: 0.82rem;
  }
}

@media only screen and (min-width: 768px) and (max-width: 991px) {
  .hero-area .hero-content h1 {
    font-size: 1.2rem;
    line-height: 1.3;
  }
}

@media (max-width: 767px) {
  .hero-area .hero-content h1 {
    font-size: clamp(0.85rem, 3.2vw, 1.05rem);
    line-height: 1.3;
  }
}

.hero-area .hero-content p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.7;
  max-width: 520px;
}

.hero-area .hero-content .button .btn {
  background: var(--primary);
  color: #fff;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(189, 208, 242, 0.2);
  padding: 14px 32px;
  font-weight: 600;
  box-shadow: var(--shadow-glow);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.hero-area .hero-content .button .btn:hover {
  background: var(--primary-light);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(70, 100, 165, 0.45);
}

/* Buttons */
.button .btn {
  border-radius: var(--radius-sm);
  background: var(--primary);
  border: 1px solid rgba(189, 208, 242, 0.15);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.button .btn:hover {
  background: var(--primary-light);
  color: #fff;
  box-shadow: var(--shadow-glow);
  transform: translateY(-1px);
}

/* Features / Services */
.features {
  background: var(--bg-base);
}

.services-section {
  position: relative;
  overflow: hidden;
}

.services-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(189, 208, 242, 0.07) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
  mask-image: linear-gradient(180deg, transparent 0%, #000 12%, #000 88%, transparent 100%);
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 12%, #000 88%, transparent 100%);
}

.services-section__title {
  margin-bottom: 56px !important;
  padding: 0 20px !important;
}

.services-section__title h2::after {
  content: "";
  display: block;
  width: 48px;
  height: 3px;
  margin: 18px auto 0;
  border-radius: 99px;
  background: var(--primary);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1) 0.3s;
}

.services-section__title h2.animate-on-scroll.is-visible::after {
  transform: scaleX(1);
}

.services-grid {
  position: relative;
  z-index: 1;
  row-gap: 4px;
}

.services-card {
  position: relative;
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px 28px;
  margin-top: 24px;
  min-height: 240px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow: var(--shadow);
  transition:
    transform 0.4s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.4s ease,
    box-shadow 0.4s ease,
    background 0.4s ease;
}

.services-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: linear-gradient(135deg, transparent 30%, rgba(189, 208, 242, 0.18) 50%, transparent 70%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.services-card:hover {
  transform: translateY(-8px) scale(1.01);
  border-color: var(--border-hover);
  background: var(--bg-elevated);
  box-shadow: var(--shadow), var(--shadow-glow);
}

.services-card:hover::before {
  opacity: 1;
}

.services-card__index {
  position: absolute;
  top: 18px;
  right: 22px;
  font-family: var(--font-heading);
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1;
  color: rgba(189, 208, 242, 0.05);
  transition: color 0.35s ease, transform 0.35s ease;
  user-select: none;
}

.services-card:hover .services-card__index {
  color: rgba(70, 100, 165, 0.22);
  transform: scale(1.05);
}

.services-card__icon {
  width: 54px;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-size: 1.45rem;
  color: #fff;
  background: var(--primary);
  box-shadow: 0 6px 24px rgba(70, 100, 165, 0.45);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease;
}

.services-card:hover .services-card__icon {
  transform: scale(1.1) rotate(-6deg);
  box-shadow: 0 10px 32px rgba(70, 100, 165, 0.55);
}

.services-card h3 {
  font-family: var(--font-heading);
  color: var(--text-primary);
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  margin: 0;
  transition: color 0.3s ease;
}

.services-card:hover h3 {
  color: var(--accent);
}

.services-card p {
  color: var(--text-muted);
  line-height: 1.7;
  margin: 0;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}

.services-card:hover p {
  color: var(--text-secondary);
}

.services-card__shine {
  position: absolute;
  top: 0;
  left: -120%;
  width: 55%;
  height: 100%;
  background: linear-gradient(105deg, transparent, rgba(189, 208, 242, 0.07), transparent);
  transform: skewX(-18deg);
  pointer-events: none;
}

.services-card:hover .services-card__shine {
  animation: cardShine 0.75s ease forwards;
}

/* Projects */
.features-buyrun {
  background: var(--bg-surface) !important;
  position: relative;
}

.features-buyrun::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-hover), transparent);
}

.white-box {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 48px;
}

.features-buyrun p {
  color: var(--text-secondary);
  line-height: 1.75;
}

.btn-buyrun {
  background: linear-gradient(135deg, #c43a1a 0%, #af3015 100%) !important;
  color: #fff !important;
  border: none !important;
  border-radius: var(--radius-sm) !important;
  padding: 14px 28px !important;
  margin-top: 10px;
  box-shadow: 0 4px 20px rgba(175, 48, 21, 0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-buyrun:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(175, 48, 21, 0.5);
}

/* Achievement */
.our-achievement {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, #3d5a94 100%);
  position: relative;
  overflow: hidden;
}

.our-achievement::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 50%, rgba(189, 208, 242, 0.15) 0%, transparent 50%);
  pointer-events: none;
}

.our-achievement .title h2 {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
}

.our-achievement .single-achievement h3 {
  color: var(--accent);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
}

/* Contact */
#contactus.features {
  background: var(--bg-deep);
}

.contact-form-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
  box-shadow: var(--shadow);
}

.contact-form-card .form-control,
.contact-form-card textarea.form-control {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  padding: 12px 16px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form-card .form-control:focus,
.contact-form-card textarea.form-control:focus {
  background: var(--bg-surface);
  border-color: var(--primary-light);
  color: var(--text-primary);
  box-shadow: 0 0 0 3px rgba(70, 100, 165, 0.25);
}

.contact-form-card .form-control::placeholder,
.contact-form-card textarea.form-control::placeholder {
  color: var(--text-muted);
}

.contact-form-card .btn-primary {
  background: var(--primary) !important;
  border-color: var(--primary) !important;
  border-radius: var(--radius-sm);
  padding: 12px 36px;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.contact-form-card .btn-primary:hover {
  background: var(--primary-light) !important;
  border-color: var(--primary-light) !important;
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow);
}

.contact-success {
  color: var(--accent);
  font-size: 1.1rem;
  text-align: center;
  padding: 24px;
}

/* Footer */
.footer {
  background: var(--bg-deep);
  border-top: 1px solid var(--border);
}

.footer .single-footer h3 {
  color: var(--text-primary);
}

.footer .single-footer.f-link li a {
  color: var(--text-muted);
  transition: color 0.2s ease;
}

.footer .single-footer.f-link li a:hover {
  color: var(--accent);
}

.footer .single-footer.f-about .social li a {
  color: var(--text-secondary);
  background: var(--accent-soft);
  width: 40px;
  height: 40px;
  line-height: 40px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.footer .single-footer.f-about .social li a:hover {
  color: var(--text-primary);
  background: var(--primary);
  transform: translateY(-2px);
}

.footer .single-footer.f-about .copyright-text {
  color: var(--text-muted);
}

.footer .single-footer.f-about .copyright-text a:hover {
  color: var(--accent);
}

/* WhatsApp accent in footer */
.footer-whatsapp {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(37, 211, 102, 0.1);
  border: 1px solid rgba(37, 211, 102, 0.25);
  border-radius: var(--radius-sm);
  color: #25d366 !important;
  transition: background 0.2s ease, transform 0.2s ease;
}

.footer-whatsapp:hover {
  background: rgba(37, 211, 102, 0.18);
  color: #4ade80 !important;
  transform: translateY(-1px);
}

/* ── Animations ── */
@keyframes fadeInLeft {
  from { opacity: 0; transform: translateX(-36px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes fadeInRight {
  from { opacity: 0; transform: translateX(36px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(36px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes zoomIn {
  from { opacity: 0; transform: scale(0.88); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}

@keyframes pulseGlow {
  0%, 100% { opacity: 0.5; transform: scale(1); }
  50% { opacity: 0.85; transform: scale(1.04); }
}

@keyframes headerSlideDown {
  from { opacity: 0; transform: translateY(-16px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes countPop {
  0% { opacity: 0; transform: scale(0.6); }
  70% { transform: scale(1.08); }
  100% { opacity: 1; transform: scale(1); }
}

@keyframes cardShine {
  from { left: -120%; }
  to { left: 160%; }
}

@keyframes iconPop {
  0% { opacity: 0; transform: scale(0.4) rotate(-12deg); }
  65% { transform: scale(1.12) rotate(4deg); }
  100% { opacity: 1; transform: scale(1) rotate(0); }
}

@keyframes cardBorderPulse {
  0%, 100% { box-shadow: var(--shadow); }
  50% { box-shadow: var(--shadow), 0 0 0 1px rgba(189, 208, 242, 0.15); }
}

@media (prefers-reduced-motion: no-preference) {
  .header {
    animation: headerSlideDown 0.6s ease forwards;
  }

  .animate-hero {
    opacity: 0;
    animation-fill-mode: forwards;
  }

  .animate-hero.fade-left { animation: fadeInLeft 0.85s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
  .animate-hero.fade-left.delay-1 { animation-delay: 0.15s; }
  .animate-hero.fade-left.delay-2 { animation-delay: 0.3s; }
  .animate-hero.fade-left.delay-3 { animation-delay: 0.45s; }
  .animate-hero.fade-right { animation: fadeInRight 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.25s forwards; }

  .hero-area .hero-image .hero-lottie {
    width: 80%;
    max-width: 560px;
    margin: 0 auto;
    display: block;
    animation: float 5s ease-in-out infinite;
    animation-delay: 1.2s;
  }

  .hero-lottie--loading {
    width: 80%;
    max-width: 560px;
    aspect-ratio: 1;
    margin: 0 auto;
    border-radius: var(--radius);
    background: var(--accent-soft);
  }

  .hero-area::after {
    content: "";
    position: absolute;
    width: 420px;
    height: 420px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(189, 208, 242, 0.08) 0%, transparent 70%);
    top: 10%;
    right: 5%;
    pointer-events: none;
    animation: pulseGlow 8s ease-in-out infinite;
  }

  .animate-on-scroll {
    opacity: 0;
    transition:
      opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
      transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  }

  .animate-on-scroll.fade-up { transform: translateY(40px); }
  .animate-on-scroll.fade-left { transform: translateX(-40px); }
  .animate-on-scroll.fade-right { transform: translateX(40px); }
  .animate-on-scroll.zoom-in { transform: scale(0.9); }

  .animate-on-scroll.is-visible {
    opacity: 1;
    transform: translate(0) scale(1);
  }

  .animate-on-scroll[data-delay="100"] { transition-delay: 0.1s; }
  .animate-on-scroll[data-delay="200"] { transition-delay: 0.2s; }
  .animate-on-scroll[data-delay="300"] { transition-delay: 0.3s; }
  .animate-on-scroll[data-delay="400"] { transition-delay: 0.4s; }
  .animate-on-scroll[data-delay="500"] { transition-delay: 0.5s; }
  .animate-on-scroll[data-delay="600"] { transition-delay: 0.6s; }

  .our-achievement .single-achievement.is-visible h3 {
    animation: countPop 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  }

  .our-achievement .single-achievement[data-delay="200"].is-visible h3 { animation-delay: 0.15s; }
  .our-achievement .single-achievement[data-delay="400"].is-visible h3 { animation-delay: 0.3s; }
  .our-achievement .single-achievement[data-delay="600"].is-visible h3 { animation-delay: 0.45s; }

  .services-card.is-visible .services-card__icon {
    animation: iconPop 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  }

  .services-card[data-delay="100"].is-visible .services-card__icon { animation-delay: 0.05s; }
  .services-card[data-delay="200"].is-visible .services-card__icon { animation-delay: 0.12s; }
  .services-card[data-delay="300"].is-visible .services-card__icon { animation-delay: 0.19s; }
  .services-card[data-delay="400"].is-visible .services-card__icon { animation-delay: 0.26s; }
  .services-card[data-delay="500"].is-visible .services-card__icon { animation-delay: 0.33s; }
  .services-card[data-delay="600"].is-visible .services-card__icon { animation-delay: 0.4s; }

  .services-card.is-visible {
    animation: cardBorderPulse 0.8s ease 0.2s both;
  }

  .footer .single-footer.f-about {
    animation: fadeInLeft 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.2s both;
  }

  .footer .single-footer.f-link {
    animation: fadeInUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.35s both;
  }
}

@media (prefers-reduced-motion: reduce) {
  .animate-on-scroll,
  .animate-hero {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }
}
