/**
 * JASA303 - Main Stylesheet
 * Complete styling for the JASA303 Marketing Digital Platform
 * Domain: https://jasa303.it.com
 */

/* ============================================
   CSS VARIABLES
   ============================================ */
:root {
  --color-primary: #fbbf24;
  --color-primary-dark: #f59e0b;
  --color-secondary: #a855f7;
  --color-dark: #0a0a0a;
  --color-darker: #050505;
  --color-surface: #111111;
  --color-surface-light: #1a1a1a;
  --color-border: #27272a;
  --color-text: #ffffff;
  --color-text-muted: #a1a1aa;
  --color-success: #22c55e;
  --color-error: #ef4444;
  --color-info: #3b82f6;
  
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Space Grotesk', sans-serif;
  
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-glow: 0 0 40px rgba(251, 191, 36, 0.3);
  
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 350ms ease;
}

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  background-color: var(--color-dark);
  color: var(--color-text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

ul, ol {
  list-style: none;
}

/* ============================================
   BACKGROUND EFFECTS
   ============================================ */
.grid-pattern {
  position: fixed;
  inset: 0;
  background-image: 
    linear-gradient(rgba(251, 191, 36, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(251, 191, 36, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
  pointer-events: none;
  z-index: 0;
}

.animated-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.15;
  pointer-events: none;
  z-index: 0;
}

.glow-1 {
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--color-primary) 0%, transparent 70%);
  top: -200px;
  right: -200px;
  animation: float 20s ease-in-out infinite;
}

.glow-2 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, var(--color-secondary) 0%, transparent 70%);
  bottom: 10%;
  left: -150px;
  animation: float 25s ease-in-out infinite reverse;
}

.glow-3 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, #22c55e 0%, transparent 70%);
  top: 50%;
  right: 10%;
  animation: float 18s ease-in-out infinite;
  animation-delay: -5s;
}

@keyframes float {
  0%, 100% {
    transform: translate(0, 0) scale(1);
  }
  25% {
    transform: translate(50px, -30px) scale(1.1);
  }
  50% {
    transform: translate(-30px, 50px) scale(0.9);
  }
  75% {
    transform: translate(-50px, -20px) scale(1.05);
  }
}

/* ============================================
   TYPOGRAPHY
   ============================================ */
.font-display {
  font-family: var(--font-display);
}

.text-gradient {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.text-gradient-alt {
  background: linear-gradient(135deg, var(--color-secondary) 0%, #7c3aed 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ============================================
   NAVBAR
   ============================================ */
.navbar {
  backdrop-filter: blur(0);
  transition: all var(--transition-base);
}

.navbar.scrolled {
  background: rgba(10, 10, 10, 0.95);
  backdrop-filter: blur(20px);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.nav-link {
  color: var(--color-text-muted);
  transition: color var(--transition-fast);
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-primary);
}

.dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-menu {
  transform: translateY(10px);
  transition: all var(--transition-fast);
}

.dropdown-item {
  transition: all var(--transition-fast);
}

.dropdown-item:hover {
  background: rgba(251, 191, 36, 0.1);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  font-weight: 600;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: #000;
  transition: all var(--transition-fast);
  box-shadow: 0 4px 15px rgba(251, 191, 36, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(251, 191, 36, 0.4);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  font-weight: 600;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  color: var(--color-text);
  background: transparent;
  transition: all var(--transition-fast);
}

.btn-outline:hover {
  background: var(--color-text);
  color: var(--color-dark);
  border-color: var(--color-text);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  position: relative;
  z-index: 1;
}

.hero-badge {
  animation: pulse-badge 2s ease-in-out infinite;
}

@keyframes pulse-badge {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.8;
  }
}

.hero-title {
  line-height: 1.1;
}

/* ============================================
   MARQUEE
   ============================================ */
.marquee {
  position: relative;
  overflow: hidden;
}

.marquee-content {
  animation: marquee 30s linear infinite;
}

.marquee:hover .marquee-content {
  animation-play-state: paused;
}

@keyframes marquee {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-33.33%);
  }
}

/* ============================================
   CARDS
   ============================================ */
.glass-card {
  background: rgba(17, 17, 17, 0.8);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-2xl);
}

.service-card {
  transition: all var(--transition-base);
}

.service-card:hover {
  transform: translateY(-5px);
  border-color: rgba(251, 191, 36, 0.5);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.service-card:hover .service-icon {
  transform: scale(1.1);
}

.service-icon {
  transition: transform var(--transition-base);
}

.domain-card {
  transition: all var(--transition-base);
}

.domain-card:hover {
  transform: translateY(-5px);
  border-color: rgba(168, 85, 247, 0.5);
}

.pricing-card {
  transition: all var(--transition-base);
}

.pricing-card:hover {
  transform: translateY(-5px);
  border-color: rgba(251, 191, 36, 0.5);
}

.pricing-card.featured {
  position: relative;
}

.pricing-card.featured::before {
  content: '';
  position: absolute;
  inset: -2px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
  border-radius: calc(var(--radius-2xl) + 2px);
  z-index: -1;
  opacity: 0.5;
}

.testimonial-card {
  transition: all var(--transition-base);
}

.testimonial-card:hover {
  border-color: rgba(251, 191, 36, 0.3);
}

.blog-card {
  transition: all var(--transition-base);
}

.blog-card:hover {
  transform: translateY(-5px);
  border-color: rgba(251, 191, 36, 0.5);
}

.blog-card:hover .blog-thumb img {
  transform: scale(1.05);
}

.blog-thumb img {
  transition: transform 0.5s ease;
}

/* ============================================
   STATS
   ============================================ */
.stat-card {
  transition: all var(--transition-base);
}

.stat-card:hover {
  border-color: rgba(251, 191, 36, 0.5);
  transform: translateY(-3px);
}

/* ============================================
   FAQ
   ============================================ */
.faq-item {
  transition: all var(--transition-fast);
}

.faq-question {
  transition: all var(--transition-fast);
}

.faq-answer {
  animation: slideDown 0.3s ease;
}

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

/* ============================================
   MODAL
   ============================================ */
.modal-overlay {
  animation: fadeIn 0.3s ease;
}

.checkout-modal {
  animation: slideUp 0.3s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

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

.pay-tab {
  transition: all var(--transition-fast);
}

.pay-tab.active {
  border-bottom-color: var(--color-primary);
  color: var(--color-primary);
}

/* ============================================
   CHAT WIDGET
   ============================================ */
.chat-button {
  animation: pulse-chat 2s ease-in-out infinite;
}

@keyframes pulse-chat {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(251, 191, 36, 0.4);
  }
  50% {
    box-shadow: 0 0 0 15px rgba(251, 191, 36, 0);
  }
}

.chat-panel {
  animation: slideUpChat 0.3s ease;
}

@keyframes slideUpChat {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ============================================
   TOAST
   ============================================ */
.toast {
  backdrop-filter: blur(10px);
}

/* ============================================
   PAGE TRANSITIONS
   ============================================ */
.page-view {
  animation: fadeInPage 0.4s ease;
}

.page-view.hidden {
  display: none;
}

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

/* ============================================
   FOOTER
   ============================================ */
.footer-links a {
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--color-primary);
}

.footer-social a {
  transition: all var(--transition-fast);
}

.footer-social a:hover {
  transform: translateY(-3px);
}

/* ============================================
   UTILITIES
   ============================================ */
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--color-dark);
}

::-webkit-scrollbar-thumb {
  background: var(--color-border);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary);
}

/* Selection */
::selection {
  background: rgba(251, 191, 36, 0.3);
  color: var(--color-text);
}

/* Focus */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .hero-title {
    font-size: 2.5rem;
  }
  
  .glow-1,
  .glow-2,
  .glow-3 {
    display: none;
  }
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 2rem;
  }
  
  .section-title {
    font-size: 1.75rem;
  }
  
  .pricing-card.featured {
    transform: none;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 1.5rem;
  }
  
  .btn-primary,
  .btn-outline {
    width: 100%;
    justify-content: center;
  }
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.animate-spin {
  animation: spin 1s linear infinite;
}

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

.animate-bounce {
  animation: bounce 1s ease-in-out infinite;
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
  .navbar,
  .chat-widget,
  .modal-overlay,
  .animated-glow,
  .grid-pattern {
    display: none !important;
  }
  
  body {
    background: white;
    color: black;
  }
}

/* ============================================
   PROSE (Blog Content)
   ============================================ */
.prose {
  color: var(--color-text);
}

.prose h1,
.prose h2,
.prose h3,
.prose h4,
.prose h5,
.prose h6 {
  color: var(--color-text);
  font-weight: 700;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.prose h2 {
  font-size: 1.75rem;
  border-bottom: 1px solid var(--color-border);
  padding-bottom: 0.5rem;
}

.prose h3 {
  font-size: 1.375rem;
}

.prose p {
  margin-bottom: 1.25rem;
  line-height: 1.8;
}

.prose ul,
.prose ol {
  margin-bottom: 1.25rem;
  padding-left: 1.5rem;
}

.prose ul {
  list-style-type: disc;
}

.prose ol {
  list-style-type: decimal;
}

.prose li {
  margin-bottom: 0.5rem;
}

.prose a {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.prose a:hover {
  color: var(--color-primary-dark);
}

.prose blockquote {
  border-left: 4px solid var(--color-primary);
  padding-left: 1rem;
  margin: 1.5rem 0;
  font-style: italic;
  color: var(--color-text-muted);
}

.prose code {
  background: var(--color-surface);
  padding: 0.2rem 0.4rem;
  border-radius: var(--radius-sm);
  font-family: 'Monaco', 'Consolas', monospace;
  font-size: 0.875em;
}

.prose pre {
  background: var(--color-surface);
  padding: 1rem;
  border-radius: var(--radius-lg);
  overflow-x: auto;
  margin: 1.5rem 0;
}

.prose pre code {
  background: none;
  padding: 0;
}

.prose img {
  border-radius: var(--radius-lg);
  margin: 1.5rem 0;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
}

.prose th,
.prose td {
  border: 1px solid var(--color-border);
  padding: 0.75rem;
  text-align: left;
}

.prose th {
  background: var(--color-surface);
  font-weight: 600;
}

/* ============================================
   PREMIUM CHAT WIDGET STYLES
   ============================================ */
#chatPanel {
  animation: slideUpFade 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

#chatPanel.hidden {
  display: none !important;
}

@keyframes slideUpFade {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Pesan Animasi Muncul */
.chat-message {
  animation: messagePop 0.3s ease-out forwards;
}

@keyframes messagePop {
  0% { opacity: 0; transform: translateY(10px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* Custom Scrollbar Super Tipis untuk Chat */
.custom-scrollbar::-webkit-scrollbar {
  width: 4px;
}
.custom-scrollbar::-webkit-scrollbar-track {
  background: transparent;
}
.custom-scrollbar::-webkit-scrollbar-thumb {
  background: rgba(251, 191, 36, 0.3); /* Amber semi transparent */
  border-radius: 10px;
}
.custom-scrollbar::-webkit-scrollbar-thumb:hover {
  background: rgba(251, 191, 36, 0.8);
}