/* DHITI Styling Variables */
:root {
  --background: 40 30% 97%;
  --foreground: 200 25% 15%;

  --card: 40 25% 100%;
  --card-foreground: 200 25% 15%;

  --primary: 185 45% 28%;
  --primary-foreground: 40 30% 97%;

  --secondary: 40 20% 92%;
  --secondary-foreground: 200 25% 15%;

  --muted: 40 15% 90%;
  --muted-foreground: 200 10% 45%;

  --accent: 170 35% 40%;
  --accent-foreground: 40 30% 97%;

  --border: 40 20% 88%;
  --input: 40 20% 88%;
  --ring: 185 45% 28%;

  --radius: 1rem;
}

/* Base resets relying on correct tailwind layer mapping */
html {
  font-size: 90%; /* Scales all rem-based units down while keeping 100% width elements full width */
}
html, body {
  overflow-x: hidden;
  scroll-behavior: smooth;
}

body {
  font-family: 'DM Sans', sans-serif;
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
  -webkit-font-smoothing: antialiased;
}

/* Utilities */
.font-display {
  font-family: 'Playfair Display', serif;
}

/* Gorgeous background meshes */
.hero-bg {
  position: relative;
  background: hsl(var(--background));
  overflow: hidden;
}

.hero-bg::before,
.hero-bg::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  z-index: 0;
  animation: pulse-glow 15s infinite alternate;
}

.hero-bg::before {
  top: -10%;
  left: -10%;
  width: 50vw;
  height: 50vw;
  background: radial-gradient(circle, hsla(185, 45%, 28%, 0.15) 0%, transparent 70%);
}

.hero-bg::after {
  bottom: -20%;
  right: -10%;
  width: 60vw;
  height: 60vw;
  background: radial-gradient(circle, hsla(170, 35%, 40%, 0.15) 0%, transparent 70%);
  animation-delay: -5s;
}

.bg-mesh {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
      radial-gradient(at 80% 0%, hsla(185, 45%, 28%, 0.1) 0px, transparent 50%),
      radial-gradient(at 0% 50%, hsla(170, 35%, 40%, 0.1) 0px, transparent 50%);
  z-index: 0;
  pointer-events: none;
}

/* Glassmorphism Classes */
.glass-panel {
  background: hsla(var(--card) / 0.6);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid hsla(var(--border) / 0.6);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
}

.glass-nav {
  background: hsla(var(--background) / 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid hsla(var(--border) / 0.5);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.02);
}

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

.text-gradient-alt {
  background: linear-gradient(135deg, hsl(var(--foreground)), hsl(185, 45%, 28%));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Animations */
@keyframes pulse-glow {
  0% { transform: scale(1) translate(0, 0); opacity: 0.8; }
  50% { transform: scale(1.1) translate(2%, 2%); opacity: 1; }
  100% { transform: scale(0.9) translate(-2%, -2%); opacity: 0.8; }
}

@keyframes float {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-15px) rotate(1deg); }
}

@keyframes float-delayed {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-10px) rotate(-1deg); }
}

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

.animate-float-delayed {
  animation: float-delayed 7s ease-in-out infinite;
  animation-delay: 2s;
}

.fade-up {
  opacity: 0;
  transform: translateY(30px);
}

/* Stagger reveals */
.stagger-1 { transition-delay: 100ms; }
.stagger-2 { transition-delay: 200ms; }
.stagger-3 { transition-delay: 300ms; }

/* Enhanced Bento Grid */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
}

.bento-item {
  position: relative;
  overflow: hidden;
  border-radius: 1.5rem;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.bento-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px -10px hsla(var(--primary) / 0.15);
}

.bento-col-span-12 { grid-column: span 12; }
.bento-col-span-8 { grid-column: span 8; }
.bento-col-span-7 { grid-column: span 7; }
.bento-col-span-6 { grid-column: span 6; }
.bento-col-span-5 { grid-column: span 5; }
.bento-col-span-4 { grid-column: span 4; }

@media (max-width: 991px) {
  .bento-col-span-8, .bento-col-span-7, .bento-col-span-6, .bento-col-span-5, .bento-col-span-4 {
    grid-column: span 12;
  }
}

/* Fancy Hover Button */
.btn-primary {
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
  z-index: 1;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(120deg, hsla(var(--accent) / 0.5), transparent);
  opacity: 0;
  z-index: -1;
  transition: opacity 0.3s ease;
}

.btn-primary:hover::before {
  opacity: 1;
}

/* FAQ Enhancements */
.faq-button {
  transition: background-color 0.2s ease;
}
.faq-button:hover {
  background-color: hsla(var(--primary) / 0.03);
}

/* Outline Animations */
.animated-border {
  position: relative;
  background: inherit;
  border-radius: inherit;
}
.animated-border::before {
  content: "";
  position: absolute;
  top: -1px;
  left: -1px;
  right: -1px;
  bottom: -1px;
  background: linear-gradient(45deg, hsla(var(--primary)/0.5), hsla(var(--accent)/0.5), hsla(var(--primary)/0.5));
  z-index: -1;
  border-radius: inherit;
  background-size: 200% 200%;
  animation: bg-pan 3s linear infinite;
  opacity: 0;
  transition: opacity 0.3s;
}
.animated-border:hover::before {
  opacity: 1;
}

@keyframes bg-pan {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: hsl(var(--background));
}
::-webkit-scrollbar-thumb {
  background: hsl(var(--border));
  border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
  background: hsl(var(--primary) / 0.5);
}

/* Custom Hamburger Menu classes */
.menu-open body {
  overflow: hidden;
}
.mobile-menu-overlay {
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Pattern background for features */
.bg-pattern {
  background-image: radial-gradient(hsla(var(--primary) / 0.1) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* Custom Cursor */
* {
  cursor: url('data:image/svg+xml;utf8,<svg width="22" height="22" viewBox="0 0 24 24" fill="%231E2A31" stroke="white" stroke-width="1.5" xmlns="http://www.w3.org/2000/svg"><path d="M5.06 4.34v15.93c0 .54.63.83 1.05.47l4.77-4.14c.16-.14.36-.21.58-.21h5.81c.53 0 .81-.62.47-1.02L5.06 4.34z"/></svg>'), auto !important;
}
a, button, [role="button"], .cursor-pointer {
  cursor: url('data:image/svg+xml;utf8,<svg width="22" height="22" viewBox="0 0 24 24" fill="none" stroke="%231E2A31" stroke-width="1.5" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><path d="M8 13.5V5a2 2 0 1 1 4 0v4 M12 9a2 2 0 1 1 4 0v1.5 M16 10.5a2 2 0 1 1 4 0v4c0 3.5-2.5 6.5-6 6.5s-6-3-6-6.5L8 13.5zM8 12.5L5 15" fill="%231E2A31" stroke="white" stroke-width="1.2"/></svg>') 6 2, pointer !important;
}
