/* ================================================
   TECH HARBOR — ENHANCED DESIGN SYSTEM
   Targets existing Tailwind class structures directly
   ================================================ */

:root {
  --primary: #f97316;
  --primary-hover: #ea580c;
  --bg-off-white: #fcfcfc;
  --bg-dark: #111827;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 2px 8px rgba(0,0,0,0.05);
  --shadow-md: 0 12px 30px rgba(0,0,0,0.06), 0 4px 10px rgba(0,0,0,0.03);
  --shadow-orange: 0 10px 25px rgba(249,115,22,0.2);
  --transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

html { scroll-behavior: smooth; }
body { font-family: 'Inter', sans-serif; background-color: var(--bg-off-white); }

/* ================================================
   KEYFRAMES
   ================================================ */

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

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

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

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

@keyframes glowPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(249,115,22,0.3); }
  50%       { box-shadow: 0 0 0 8px rgba(249,115,22,0); }
}

@keyframes shimmer {
  from { left: -80%; }
  to   { left: 140%; }
}

/* ================================================
   SCROLL REVEAL  —  applied by JS to any element
   ================================================ */
.th-hidden {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.6s cubic-bezier(0.4,0,0.2,1),
              transform 0.6s cubic-bezier(0.4,0,0.2,1);
}
.th-hidden.th-from-left  { transform: translateX(-22px); }
.th-hidden.th-from-right { transform: translateX(22px);  }
.th-hidden.th-visible    { opacity: 1; transform: none; }

/* ================================================
   HERO  —  entrance on page load
   ================================================ */
.hero-content > * {
  animation: fadeInUp 0.75s cubic-bezier(0.4,0,0.2,1) both;
}
.hero-content > *:nth-child(1) { animation-delay: 0.05s; }
.hero-content > *:nth-child(2) { animation-delay: 0.18s; }
.hero-content > *:nth-child(3) { animation-delay: 0.30s; }
.hero-content > *:nth-child(4) { animation-delay: 0.42s; }
.hero-content > *:nth-child(5) { animation-delay: 0.54s; }

/* ================================================
   NAVBAR  —  glass scroll effect
   ================================================ */
.glass {
  background: rgba(255,255,255,0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

/* ================================================
   "WHY CHOOSE US" CARDS & GENERAL WHITE CARDS
   Targets: .p-8.bg-white.rounded-brand (Why Choose grid)
   ================================================ */

/* Why Choose Us & testimonial grids — card hover lift */
section .grid > div.p-8 {
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  position: relative;
  overflow: hidden;
}
section .grid > div.p-8::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 3px; height: 0;
  background: var(--primary);
  border-radius: 0 0 3px 0;
  transition: height 0.35s ease;
}
section .grid > div.p-8:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: #fed7aa !important;
}
section .grid > div.p-8:hover::before {
  height: 100%;
}

/* ================================================
   PROCESS STEPS — gradient number circles
   ================================================ */
div.w-12.h-12.bg-primary.text-white.rounded-full {
  background: linear-gradient(135deg, #f97316, #fb923c) !important;
  box-shadow: 0 4px 14px rgba(249,115,22,0.35);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
div.w-12.h-12.bg-primary.text-white.rounded-full:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(249,115,22,0.45);
}

/* ================================================
   FAQ ITEMS — hover border highlight
   ================================================ */
.bg-white.rounded-xl.border.border-gray-100.p-6 {
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.bg-white.rounded-xl.border.border-gray-100.p-6:hover {
  border-color: #fed7aa !important;
  box-shadow: var(--shadow-md);
}

/* ================================================
   TESTIMONIAL AVATAR — styled initials
   ================================================ */
.testimonial-avatar {
  width: 3rem; height: 3rem;
  border-radius: 9999px;
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem; font-weight: 700;
  color: #6b7280; letter-spacing: 0.05em;
  flex-shrink: 0;
}

/* ================================================
   HOVER LIFT  (existing, kept)
   ================================================ */
.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.hover-lift:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

/* ================================================
   SERVICE ICON FLOAT  (services page)
   ================================================ */
.icon-float {
  animation: floatIcon 3.8s ease-in-out infinite;
  filter: drop-shadow(0 4px 10px rgba(249,115,22,0.2));
}

/* ================================================
   PRIMARY BUTTONS  —  shimmer + glow
   ================================================ */
a.bg-primary, button.bg-primary {
  position: relative; overflow: hidden;
  transition: background-color 0.25s ease, box-shadow 0.25s ease, transform 0.2s ease;
}
a.bg-primary::after, button.bg-primary::after {
  content: '';
  position: absolute;
  top: 0; left: -80%; width: 55%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.18), transparent);
  transform: skewX(-15deg);
  pointer-events: none;
}
a.bg-primary:hover::after, button.bg-primary:hover::after {
  animation: shimmer 0.55s ease-out forwards;
}
a.bg-primary:hover, button.bg-primary:hover {
  animation: glowPulse 1.4s ease-out;
}

/* ================================================
   GLASS DARK
   ================================================ */
.glass-dark {
  background: rgba(17,24,39,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.08);
}

/* ================================================
   GRADIENT UTILITIES
   ================================================ */
.text-gradient {
  background: linear-gradient(to right, var(--primary), #fb923c);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.bg-gradient-tech {
  background: linear-gradient(135deg, #111827 0%, #1f2937 100%);
}

/* ================================================
   CYBER LINK UNDERLINE
   ================================================ */
.cyber-border { position: relative; }
.cyber-border::after {
  content: ''; position: absolute;
  bottom: 0; left: 0; width: 0; height: 2px;
  background: var(--primary); transition: width 0.35s ease; border-radius: 1px;
}
.cyber-border:hover::after { width: 100%; }


/* Added for Mobile Menu Animation */
@keyframes fadeDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
.animate-fade-down { animation: fadeDown 0.3s ease-out forwards; }

/* Floating Contact Button */
.floating-contact {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 9999;
  display: flex;
  align-items: center;
  background-color: var(--bg-dark);
  color: white;
  padding: 0.85rem 1.75rem;
  border-radius: 9999px;
  border: 1px solid var(--primary);
  text-decoration: none !important;
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.025em;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
}

.floating-contact:hover {
  background-color: #1f2937;
  box-shadow: 0 0 20px rgba(249, 115, 22, 0.35);
  transform: translateY(-3px);
  border-color: #fb923c;
}

.floating-contact svg {
  width: 1.25rem;
  height: 1.25rem;
  margin-right: 0.75rem;
  color: white;
}

@media (max-width: 640px) {
  .floating-contact {
    padding: 1.1rem;
    right: 1.25rem;
    bottom: 1.25rem;
    border-radius: 50%;
  }
  .floating-contact span {
    display: none;
  }
  .floating-contact svg {
    margin-right: 0;
  }
}

/* ================================================
   PWA INSTALL PROMPT (Added via JS)
   ================================================ */
.pwa-install-prompt {
  position: fixed;
  bottom: -100px; /* Start hidden below screen */
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  max-width: 400px;
  background: white;
  padding: 1rem;
  border-radius: 1rem;
  box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.2), 0 0 0 1px rgba(0,0,0,0.05);
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 99999;
  transition: bottom 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.pwa-install-prompt.show {
  bottom: 2rem;
}

.pwa-install-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pwa-install-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #f97316;
  padding: 8px;
}

.pwa-install-text h4 {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  color: #111827;
  font-size: 1rem;
  margin: 0 0 2px 0;
  line-height: 1.2;
}

.pwa-install-text p {
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  color: #6b7280;
  margin: 0;
}

.pwa-install-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pwa-install-btn {
  background: #f97316;
  color: white;
  border: none;
  border-radius: 99px;
  padding: 6px 16px;
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  transition: background 0.2s;
}

.pwa-install-btn:hover {
  background: #ea580c;
}

.pwa-close-btn {
  background: none;
  border: none;
  color: #9ca3af;
  font-size: 0.7rem;
  cursor: pointer;
  padding: 2px;
  text-decoration: underline;
}

/* ================================================
   EXPERTISE TAG PILLS  (About page team cards)
   ================================================ */
.th-tag {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 9999px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #c2410c;
  background-color: #fff7ed;
  border: 1px solid #fed7aa;
  transition: background-color 0.2s ease, border-color 0.2s ease;
  white-space: nowrap;
}
.th-tag:hover {
  background-color: #ffedd5;
  border-color: #f97316;
}

/* ================================================
   CALENDLY POPUP OVERRIDES
   ================================================ */

/* 1. Eliminate the double-loading parent spinner (only show the iframe's internal spinner) */
.calendly-overlay .calendly-spinner {
    display: none !important;
}
