/* ============================================
   AIVCJ - Custom Styles
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  overflow: hidden;
  height: 100%;
}

body {
  height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* --- Scrollbar --- */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 99px; }

/* --- Page System --- */
.page-container {
  height: 100%;
  overflow: hidden;
  position: relative;
}

.page {
  display: none;
  position: absolute;
  inset: 0;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-y: contain;
}

.page.active {
  display: block;
  animation: pageSlideIn 0.38s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.page.exit {
  display: block;
  animation: pageFadeOut 0.25s ease-out forwards;
  pointer-events: none;
}

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

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

/* --- Mobile Header --- */
.mobile-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  height: 56px;
  padding-top: env(safe-area-inset-top, 0);
  background: rgba(255,255,255,0.82);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
  transition: box-shadow 0.3s ease;
}

.mobile-header.scrolled {
  box-shadow: 0 1px 12px rgba(0,0,0,0.08);
}

/* --- Desktop Header --- */
.desktop-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  height: 64px;
  background: rgba(255,255,255,0.82);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
  transition: box-shadow 0.3s ease;
}

.desktop-header.scrolled {
  box-shadow: 0 1px 12px rgba(0,0,0,0.08);
}

.desktop-nav-link {
  position: relative;
  font-weight: 500;
  font-size: 0.9rem;
  color: #475569;
  transition: color 0.2s;
  padding: 0.25rem 0;
}

.desktop-nav-link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
  border-radius: 99px;
  transition: width 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.desktop-nav-link:hover,
.desktop-nav-link.active {
  color: #312e81;
}

.desktop-nav-link.active::after {
  width: 100%;
}

/* --- Drawer --- */
.drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(0,0,0,0.4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.drawer-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 280px;
  max-width: 85vw;
  z-index: 70;
  background: #fff;
  transform: translateX(-100%);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  overflow-y: auto;
  box-shadow: 4px 0 24px rgba(0,0,0,0.12);
}

.drawer.open {
  transform: translateX(0);
}

.drawer-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  color: #334155;
  font-weight: 500;
  font-size: 0.95rem;
  border-radius: 12px;
  margin: 2px 8px;
  transition: all 0.2s ease;
}

.drawer-link:hover,
.drawer-link.active {
  background: #f1f5f9;
  color: #4338ca;
}

.drawer-link.active {
  background: linear-gradient(135deg, #eef2ff, #ede9fe);
  color: #4338ca;
  font-weight: 600;
}

/* --- Bottom Tabs --- */
.bottom-tabs {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: rgba(255,255,255,0.88);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-top: 1px solid rgba(0,0,0,0.06);
  padding-bottom: env(safe-area-inset-bottom, 0);
}

.tab-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  flex: 1;
  padding: 8px 0 6px;
  color: #94a3b8;
  font-size: 0.625rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: color 0.2s;
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

.tab-btn svg {
  width: 22px;
  height: 22px;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.tab-btn.active {
  color: #4338ca;
}

.tab-btn.active svg {
  transform: scale(1.1);
}

.tab-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: #4338ca;
  border-radius: 0 0 2px 2px;
  transform: translateX(-50%);
  transition: width 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.tab-btn.active::before {
  width: 32px;
}

/* --- More Sheet --- */
.more-sheet-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(0,0,0,0.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.more-sheet-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.more-sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 85;
  background: #fff;
  border-radius: 20px 20px 0 0;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  padding-bottom: env(safe-area-inset-bottom, 0);
  box-shadow: 0 -8px 32px rgba(0,0,0,0.12);
}

.more-sheet.open {
  transform: translateY(0);
}

.more-sheet-handle {
  width: 36px;
  height: 4px;
  border-radius: 99px;
  background: #d1d5db;
  margin: 10px auto 0;
}

.more-sheet-link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 24px;
  color: #334155;
  font-weight: 500;
  font-size: 1rem;
  transition: background 0.15s;
}

.more-sheet-link:active {
  background: #f8fafc;
}

/* --- Hero --- */
.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(145deg, #0f172a 0%, #1e1b4b 40%, #312e81 75%, #3b0764 100%);
  min-height: 100vh;
  min-height: 100dvh;
}

@media (min-width: 1024px) {
  .hero {
    min-height: auto;
    padding: 10rem 0 8rem;
  }
}

.hero-mesh {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.35;
  animation: orbFloat 20s ease-in-out infinite;
}

.hero-orb:nth-child(1) {
  width: 400px;
  height: 400px;
  background: #6366f1;
  top: -10%;
  right: -10%;
  animation-delay: 0s;
}

.hero-orb:nth-child(2) {
  width: 300px;
  height: 300px;
  background: #8b5cf6;
  bottom: -5%;
  left: -5%;
  animation-delay: -7s;
}

.hero-orb:nth-child(3) {
  width: 200px;
  height: 200px;
  background: #a78bfa;
  top: 40%;
  left: 30%;
  animation-delay: -14s;
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 60px 60px;
}

@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  25%      { transform: translate(30px, -20px) scale(1.05); }
  50%      { transform: translate(-20px, 20px) scale(0.95); }
  75%      { transform: translate(15px, 10px) scale(1.02); }
}

/* --- Gradient Text --- */
.gradient-text {
  background: linear-gradient(135deg, #c7d2fe, #e9d5ff, #fff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.gradient-text-brand {
  background: linear-gradient(135deg, #6366f1, #8b5cf6, #a78bfa);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* --- Buttons --- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: 0 4px 16px rgba(79,70,229,0.3);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(79,70,229,0.4);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: rgba(255,255,255,0.08);
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.15);
  cursor: pointer;
  transition: all 0.25s ease;
  backdrop-filter: blur(8px);
}

.btn-secondary:hover {
  background: rgba(255,255,255,0.14);
  border-color: rgba(255,255,255,0.25);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: transparent;
  color: #4338ca;
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: 12px;
  border: 1.5px solid #c7d2fe;
  cursor: pointer;
  transition: all 0.25s ease;
}

.btn-outline:hover {
  background: #eef2ff;
  border-color: #818cf8;
}

/* --- Cards --- */
.service-card {
  background: #fff;
  border: 1px solid #f1f5f9;
  border-radius: 20px;
  padding: 28px 24px;
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.service-card:hover {
  border-color: #e0e7ff;
  box-shadow: 0 8px 32px rgba(67,56,202,0.08);
  transform: translateY(-4px);
}

.service-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.feature-card {
  background: #fff;
  border: 1px solid #f1f5f9;
  border-radius: 16px;
  padding: 24px 20px;
  transition: all 0.3s ease;
}

.feature-card:hover {
  border-color: #e0e7ff;
  box-shadow: 0 4px 20px rgba(0,0,0,0.04);
}

/* --- Process Steps --- */
.process-step {
  position: relative;
  padding-left: 48px;
}

.process-step::before {
  content: attr(data-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* --- Section Dark --- */
.section-dark {
  background: linear-gradient(145deg, #0f172a, #1e1b4b);
  color: #fff;
}

/* --- WhatsApp FAB --- */
.whatsapp-fab {
  position: fixed;
  z-index: 45;
  right: 20px;
  bottom: 88px;
  width: 54px;
  height: 54px;
  border-radius: 16px;
  background: #25d366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37,211,102,0.35);
  transition: all 0.3s ease;
  text-decoration: none;
}

@media (min-width: 1024px) {
  .whatsapp-fab {
    bottom: 32px;
    right: 32px;
    width: 56px;
    height: 56px;
    border-radius: 18px;
  }
}

.whatsapp-fab:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 24px rgba(37,211,102,0.45);
}

.whatsapp-fab:active {
  transform: scale(0.96);
}

/* --- Legal Content --- */
.legal-content h2 {
  font-family: 'Sora', sans-serif;
  font-weight: 600;
  font-size: 1.25rem;
  color: #1e293b;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.legal-content h3 {
  font-family: 'Sora', sans-serif;
  font-weight: 600;
  font-size: 1.05rem;
  color: #334155;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

.legal-content p {
  color: #475569;
  line-height: 1.75;
  margin-bottom: 0.75rem;
  font-size: 0.925rem;
}

.legal-content ul {
  list-style: none;
  padding: 0;
  margin-bottom: 1rem;
}

.legal-content ul li {
  position: relative;
  padding-left: 20px;
  color: #475569;
  line-height: 1.75;
  font-size: 0.925rem;
  margin-bottom: 0.25rem;
}

.legal-content ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 11px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #818cf8;
}

/* --- Footer --- */
.site-footer {
  background: #0f172a;
  color: #94a3b8;
}

.site-footer a {
  color: #94a3b8;
  text-decoration: none;
  transition: color 0.2s;
}

.site-footer a:hover {
  color: #e2e8f0;
}

/* --- Swiper Custom --- */
.swiper-service .swiper-slide {
  height: auto;
}

.swiper-pagination-bullet {
  background: #cbd5e1 !important;
  opacity: 1 !important;
  width: 6px !important;
  height: 6px !important;
  transition: all 0.3s !important;
}

.swiper-pagination-bullet-active {
  background: #4f46e5 !important;
  width: 20px !important;
  border-radius: 3px !important;
}

/* --- Utility --- */
.text-balance {
  text-wrap: balance;
}

.glass {
  background: rgba(255,255,255,0.06);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.1);
}

/* --- Responsive Spacing --- */
@media (max-width: 1023px) {
  .page {
    padding-top: 56px;
    padding-bottom: 64px;
  }
}

@media (min-width: 1024px) {
  .page {
    padding-top: 64px;
  }
}

/* --- No-scroll body when drawer/sheet open --- */
body.no-scroll .page {
  overflow: hidden;
}

/* --- Badge --- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 500;
  border-radius: 99px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  color: #c7d2fe;
}

/* --- About Info Cards --- */
.info-card {
  background: #f8fafc;
  border: 1px solid #f1f5f9;
  border-radius: 16px;
  padding: 24px;
}

/* --- Stat counter --- */
.stat-number {
  font-family: 'Sora', sans-serif;
  font-weight: 700;
  font-size: 2rem;
  line-height: 1;
}

/* --- Link Styles --- */
a {
  text-decoration: none;
}

/* --- Selection --- */
::selection {
  background: #c7d2fe;
  color: #1e1b4b;
}
