@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Outfit:wght@300;400;500;600;700;800;900&display=swap');

/* =========================================
   Modern Design System & Variables
   ========================================= */
:root {
  /* Colors - Sophisticated Indigo/Violet Palette */
  --primary: #6366f1;
  --primary-hover: #4f46e5;
  --primary-light: #e0e7ff;
  --secondary: #8b5cf6;
  --accent: #f59e0b;

  --background: #ffffff;
  --foreground: #0f172a;

  --card-bg: #ffffff;
  --card-border: rgba(226, 232, 240, 0.6);
  --card-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.1);
  --card-shadow-hover: 0 20px 40px -15px rgba(99, 102, 241, 0.15);

  --muted: #f1f5f9;
  --muted-foreground: #64748b;
  --border: #e2e8f0;

  --glass-bg: rgba(255, 255, 255, 0.7);
  --glass-border: rgba(255, 255, 255, 0.3);

  --radius-sm: 0.5rem;
  --radius-md: 1rem;
  --radius-lg: 1.5rem;
  --radius-xl: 2.5rem;
  --radius-full: 9999px;

  --font-sans: 'Plus Jakarta Sans', sans-serif;
  --font-heading: 'Outfit', sans-serif;
}

.dark {
  --primary: #818cf8;
  --primary-hover: #6366f1;
  --primary-light: #1e1b4b;
  --secondary: #a78bfa;

  --background: #0a0a0c;
  --foreground: #f8fafc;

  --card-bg: #141417;
  --card-border: rgba(255, 255, 255, 0.05);
  --card-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
  --card-shadow-hover: 0 20px 40px -15px rgba(0, 0, 0, 0.7);

  --muted: #1e293b;
  --muted-foreground: #94a3b8;
  --border: #27272a;

  --glass-bg: rgba(10, 10, 12, 0.7);
  --glass-border: rgba(255, 255, 255, 0.08);
}

/* =========================================
   Base Styles
   ========================================= */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  width: 100%;
  transition: background-color 0.4s cubic-bezier(0.4, 0, 0.2, 1), color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

a {
  color: inherit;
  text-decoration: none;
  transition: all 0.2s ease;
}

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

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

/* =========================================
   Layout Utilities
   ========================================= */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 5rem 0;
}

@media (min-width: 768px) {
  .section {
    padding: 8rem 0;
  }
}

.grid-auto {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.flex-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* =========================================
   Premium Components
   ========================================= */

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  padding: 0.875rem 1.75rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: var(--primary);
  color: white;
  box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 20px 25px -5px rgba(99, 102, 241, 0.4);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--foreground);
}

.btn-outline:hover {
  background: var(--muted);
  border-color: var(--primary);
}

/* Base card */
.card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--card-shadow);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 1.5rem;
  height: 100%;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--card-shadow-hover);
  border-color: var(--primary);
}

/* Glass effect */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  border: 1px solid var(--glass-border);
}

/* Back Link Hover Effect */
.back-link {
  transition: all 0.3s ease;
  position: relative;
}

.back-link:hover {
  transform: translateX(-5px);
  color: var(--primary);
}

.back-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--primary);
  transform: scaleX(0);
  transition: transform 0.3s ease;
  transform-origin: right;
}

.back-link:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

/* Text Gradients */
.text-gradient {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Badges */
.badge {
  display: inline-flex;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-primary {
  background: var(--primary-light);
  color: var(--primary);
}

/* =========================================
   Form Elements
   ========================================= */
.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
}

.form-input {
  width: 100%;
  padding: 0.875rem 1.125rem;
  background: var(--muted);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--foreground);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-family: inherit;
}

.form-input:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--background);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

/* =========================================
   Advanced Animations
   ========================================= */
@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-15px);
  }
}

.animate-float {
  animation: float 6s ease-in-out infinite;
}

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

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

@keyframes spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

/* =========================================
   Hero Section & Specialized Layouts (Refactored)
   ========================================= */
.hero-grid {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 4rem;
  width: 100%;
}

.hero-text-item {
  flex: 1.4;
  min-width: 0;
  order: 1;
}

.hero-image-item {
  flex: 0.6;
  min-width: 0;
  order: 2;
  display: flex;
  justify-content: center;
}

.hero-image-wrapper {
  position: relative;
  width: 100%;
  max-width: 480px;
}

.hero-image-container {
  border-radius: 2.5rem;
  overflow: hidden;
  box-shadow: 0 25px 60px -12px rgba(0, 0, 0, 0.2);
  border: 1px solid var(--glass-border);
  position: relative;
  aspect-ratio: 0.85;
  background: var(--muted);
  z-index: 1;
}

.floating-badge {
  position: absolute;
  bottom: -1.5rem;
  right: -1.5rem;
  padding: 1.25rem 1.75rem;
  border-radius: 1.5rem;
  max-width: 240px;
  z-index: 10;
  box-shadow: var(--card-shadow);
  border: 1px solid var(--glass-border);
}

.decorative-circle {
  position: absolute;
  top: -2.5rem;
  right: -2.5rem;
  width: 160px;
  height: 160px;
  border-radius: 50%;
  border: 2px dashed var(--primary);
  opacity: 0.2;
  z-index: 0;
  animation: rotate 20s linear infinite;
}

@keyframes rotate {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.hero-text-content {
  margin-bottom: 3.5rem;
  width: 100%;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.75rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
  font-weight: 900;
  margin-bottom: 2rem;
  overflow-wrap: break-word;
  word-break: break-word;
}

.hero-desc {
  font-size: 1.125rem;
  color: var(--muted-foreground);
  max-width: 42rem;
  line-height: 1.8;
  margin-bottom: 3.5rem;
  overflow-wrap: break-word;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.hero-stats {
  display: flex;
  gap: 3rem;
  align-items: center;
  opacity: 0.85;
  margin-top: 4rem;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-num {
  font-size: 1.75rem;
  font-weight: 900;
  color: var(--primary);
}

.stat-label {
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted-foreground);
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

/* Responsive Specific Overrides */
@media (max-width: 991px) {
  .hero-grid {
    flex-direction: column;
    text-align: center;
    gap: 3rem;
  }

  .hero-text-item {
    order: 2;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero-image-item {
    order: 1;
    width: 100%;
  }

  .hero-image-wrapper {
    max-width: 280px;
  }

  .hero-image-container {
    aspect-ratio: 1;
    border-radius: 2rem;
  }

  .floating-badge {
    right: -1rem;
    bottom: -1rem;
    max-width: 200px;
    padding: 1rem 1.25rem;
    font-size: 0.85rem;
    text-align: left;
  }

  .hero-title {
    font-size: clamp(1.75rem, 8vw, 2.5rem);
    width: 100%;
    margin-bottom: 1.5rem;
  }

  .hero-desc {
    font-size: 1rem;
    margin-bottom: 2.5rem;
    margin-left: auto;
    margin-right: auto;
  }

  .hero-actions,
  .hero-stats {
    justify-content: center;
  }

  .hero-stats {
    margin-top: 3rem;
    gap: 1.5rem;
    flex-wrap: wrap;
  }
}

@media (max-width: 480px) {
  .hero-stats {
    gap: 1rem;
  }

  .stat-item {
    padding: 0.5rem;
    flex: 1 1 100px;
  }

  .stat-num {
    font-size: 1.5rem;
  }

  .hero-actions .btn {
    width: 100%;
  }
}

/* =========================================
   Responsive Adjustments
   ========================================= */
@media (max-width: 1100px) {
  .hero-grid {
    gap: 3rem;
  }
}

@media (max-width: 991px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 4rem;
  }

  .hero-text-item {
    order: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero-image-item {
    order: 1;
    width: 100%;
  }

  .hero-actions,
  .hero-stats {
    justify-content: center;
  }

  .hero-image-wrapper {
    max-width: 320px;
    margin: 0 auto;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .hero-image-container {
    width: 100%;
    border-radius: 2.5rem;
    z-index: 5;
    box-shadow: var(--card-shadow-hover);
    background: var(--muted);
    min-height: 220px;
  }

  .floating-badge {
    right: 0rem;
    bottom: -1rem;
    padding: 1.25rem 1.5rem;
    max-width: 220px;
    z-index: 10;
    text-align: left;
  }

  .decorative-circle {
    width: 240px;
    height: 240px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 0;
    margin: 0;
  }
}

@media (max-width: 580px) {
  .hero-title {
    font-size: clamp(1.85rem, 10vw, 2.5rem);
    margin-bottom: 1.5rem;
    line-height: 1.15;
  }

  .hero-image-wrapper {
    max-width: 260px;
  }

  .floating-badge {
    padding: 0.85rem 1.25rem;
    max-width: 180px;
    font-size: 0.8rem;
    right: -0.5rem;
    bottom: -0.5rem;
  }

  .hero-stats {
    gap: 1.25rem;
    margin-top: 3rem;
  }

  .stat-item {
    padding: 0.75rem;
    flex: 1 1 100px;
  }

  .expertise-card,
  .service-card,
  .card {
    padding: 2rem 1.5rem !important;
  }

  .hero-actions {
    gap: 1rem;
    width: 100%;
  }

  .hero-actions .btn {
    width: 100%;
    padding: 1rem;
  }
}

/* Scrollbar & Custom Selection */
::-webkit-scrollbar {
  width: 10px;
}

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

::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 5px;
  border: 2px solid var(--background);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--muted-foreground);
}

::selection {
  background: var(--primary);
  color: white;
}

/* Rich content fixes for MySQL LongText */
.rich-content {
  font-size: 1.125rem;
  color: var(--foreground);
  line-height: 1.8;
}

.rich-content p {
  margin-bottom: 1.5rem;
}

.rich-content h2 {
  margin: 2.5rem 0 1.25rem;
  font-size: 1.85rem;
  font-weight: 800;
}

.rich-content ul {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.rich-content li {
  margin-bottom: 0.625rem;
}