/* ================================================================
   EthicsComputer Premium UI v1.0 — Additional Modern Patterns
   Load after design-system.css and style.css
   ================================================================ */

/* ─────────────────────────────────────────────────────────────
   REVEAL ANIMATIONS (used with GSAP ScrollTrigger)
   ─────────────────────────────────────────────────────────────*/
.reveal-up,
.reveal-left,
.reveal-right {
  opacity: 0;
  will-change: transform, opacity;
}

.reveal-up    { transform: translateY(32px); }
.reveal-left  { transform: translateX(-32px); }
.reveal-right { transform: translateX(32px); }

.reveal-up.is-visible,
.reveal-left.is-visible,
.reveal-right.is-visible {
  opacity: 1;
  transform: translate(0, 0);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ─────────────────────────────────────────────────────────────
   PREMIUM HERO PATTERNS
   ─────────────────────────────────────────────────────────────*/

/* Animated mesh gradient background */
.ec-hero-mesh {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.ec-hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  will-change: transform;
  animation: ec-orb-drift 18s ease-in-out infinite;
}

@keyframes ec-orb-drift {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%       { transform: translate(3%, 2%) scale(1.05); }
  66%       { transform: translate(-2%, 3%) scale(0.97); }
}

/* Grid dot pattern */
.ec-grid-dots {
  background-image: radial-gradient(circle at 1px 1px, rgba(148,163,184,0.15) 1px, transparent 0);
  background-size: 32px 32px;
}

/* Tech line pattern (for dark sections) */
.ec-grid-lines {
  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: 40px 40px;
}

/* ─────────────────────────────────────────────────────────────
   SECTION TRANSITION BLENDS
   ─────────────────────────────────────────────────────────────*/

/* Dark → Light transition */
.ec-blend-to-light {
  position: relative;
}
.ec-blend-to-light::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(to bottom, transparent, #fff);
  pointer-events: none;
  z-index: 1;
}

/* Light → Dark transition */
.ec-blend-to-dark {
  position: relative;
}
.ec-blend-to-dark::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(to bottom, transparent, #020617);
  pointer-events: none;
  z-index: 1;
}

/* ─────────────────────────────────────────────────────────────
   PREMIUM SECTION HEADERS
   ─────────────────────────────────────────────────────────────*/
.ec-section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.ec-section-kicker .ec-kicker-line {
  height: 1px;
  width: 2rem;
  background: var(--ec-primary, #0ea5e9);
}

/* ─────────────────────────────────────────────────────────────
   BENTO GRID CARDS
   ─────────────────────────────────────────────────────────────*/
.ec-bento-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
}

.ec-bento-card {
  background: #fff;
  border: 1px solid #f1f5f9;
  border-radius: 1.75rem;
  padding: 2rem;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.4s ease;
}

.ec-bento-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 50px -12px rgba(0,0,0,0.1);
  border-color: #e2e8f0;
}

.ec-bento-card-dark {
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(20px) saturate(120%);
  -webkit-backdrop-filter: blur(20px) saturate(120%);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 1.75rem;
  padding: 2rem;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.4s ease,
              border-color 0.4s ease;
}

.ec-bento-card-dark:hover {
  transform: translateY(-5px);
  border-color: rgba(14, 165, 233, 0.3);
  box-shadow: 0 24px 60px rgba(0,0,0,0.4),
              0 0 0 1px rgba(14, 165, 233, 0.15);
}

/* Spotlight hover effect on dark cards */
.ec-bento-card-dark::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 0%), rgba(14,165,233,0.07) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.ec-bento-card-dark:hover::before {
  opacity: 1;
}

/* ─────────────────────────────────────────────────────────────
   PROCESS / TIMELINE STEPS
   ─────────────────────────────────────────────────────────────*/
.ec-steps {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.ec-steps::before {
  content: '';
  position: absolute;
  left: 1.5rem;
  top: 2rem;
  bottom: 2rem;
  width: 1px;
  background: linear-gradient(to bottom, transparent, #e2e8f0 15%, #e2e8f0 85%, transparent);
}

.ec-step {
  display: flex;
  gap: 1.5rem;
  position: relative;
}

.ec-step-number {
  flex-shrink: 0;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  border: 1.5px solid #e2e8f0;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 800;
  color: #94a3b8;
  position: relative;
  z-index: 1;
  transition: all 0.3s ease;
}

.ec-step:hover .ec-step-number {
  background: #0ea5e9;
  border-color: #0ea5e9;
  color: #fff;
  box-shadow: 0 4px 16px rgba(14, 165, 233, 0.3);
}

/* ─────────────────────────────────────────────────────────────
   SERVICE FEATURE LIST ITEMS
   ─────────────────────────────────────────────────────────────*/
.ec-feature-list {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.ec-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem;
  border-radius: 1rem;
  border: 1px solid transparent;
  transition: all 0.3s ease;
}

.ec-feature-item:hover {
  background: rgba(14, 165, 233, 0.04);
  border-color: rgba(14, 165, 233, 0.12);
}

/* ─────────────────────────────────────────────────────────────
   TESTIMONIAL CARDS
   ─────────────────────────────────────────────────────────────*/
.ec-testimonial {
  background: #fff;
  border: 1px solid #f1f5f9;
  border-radius: 1.75rem;
  padding: 2rem;
  position: relative;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.ec-testimonial:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 50px -12px rgba(0,0,0,0.08);
  border-color: #e2e8f0;
}

.ec-testimonial-quote {
  font-size: 1rem;
  line-height: 1.75;
  color: #475569;
  margin-bottom: 1.5rem;
  font-style: italic;
}

.ec-testimonial-author {
  display: flex;
  align-items: center;
  gap: 0.875rem;
}

.ec-testimonial-avatar {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #f1f5f9;
}

/* Stars */
.ec-stars {
  display: flex;
  gap: 2px;
  margin-bottom: 1rem;
}

.ec-star {
  width: 1rem;
  height: 1rem;
  fill: #fbbf24;
  color: #fbbf24;
}

/* ─────────────────────────────────────────────────────────────
   PRICING CARDS
   ─────────────────────────────────────────────────────────────*/
.ec-pricing-card {
  background: #fff;
  border: 1.5px solid #e2e8f0;
  border-radius: 2rem;
  padding: 2.5rem;
  position: relative;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.ec-pricing-card:hover {
  border-color: #0ea5e9;
  box-shadow: 0 20px 60px -12px rgba(14, 165, 233, 0.15);
  transform: translateY(-4px);
}

.ec-pricing-card.is-featured {
  border-color: #0ea5e9;
  background: linear-gradient(180deg, rgba(14,165,233,0.04) 0%, #fff 100%);
}

.ec-pricing-card.is-featured::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #0ea5e9, #6366f1);
}

/* ─────────────────────────────────────────────────────────────
   TAG / CHIP SYSTEM
   ─────────────────────────────────────────────────────────────*/
.ec-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.875rem;
  border-radius: 9999px;
  font-size: 0.8125rem;  /* 13px */
  font-weight: 600;
  border: 1px solid;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.ec-chip-blue    { background: #eff6ff; color: #1d4ed8; border-color: #bfdbfe; }
.ec-chip-emerald { background: #ecfdf5; color: #065f46; border-color: #a7f3d0; }
.ec-chip-amber   { background: #fffbeb; color: #92400e; border-color: #fde68a; }
.ec-chip-rose    { background: #fff1f2; color: #9f1239; border-color: #fecdd3; }
.ec-chip-violet  { background: #f5f3ff; color: #5b21b6; border-color: #ddd6fe; }
.ec-chip-sky     { background: #f0f9ff; color: #0369a1; border-color: #bae6fd; }

/* ─────────────────────────────────────────────────────────────
   DATA TABLE ENHANCEMENTS
   ─────────────────────────────────────────────────────────────*/
.ec-data-table-wrapper {
  border-radius: 1.25rem;
  border: 1px solid #f1f5f9;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

/* Hover row highlight with left accent */
.ec-table tbody tr:hover td:first-child {
  box-shadow: inset 2px 0 0 #0ea5e9;
}

/* ─────────────────────────────────────────────────────────────
   PROGRESS BARS
   ─────────────────────────────────────────────────────────────*/
.ec-progress {
  height: 6px;
  background: #f1f5f9;
  border-radius: 99px;
  overflow: hidden;
}

.ec-progress-bar {
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, #0ea5e9, #38bdf8);
  transition: width 1.2s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.ec-progress-bar::after {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 8px; height: 100%;
  background: rgba(255,255,255,0.5);
  border-radius: 99px;
  animation: ec-progress-shine 2s ease-in-out infinite;
}

@keyframes ec-progress-shine {
  0%, 100% { opacity: 0; }
  50%       { opacity: 1; }
}

/* ─────────────────────────────────────────────────────────────
   EMPTY STATES
   ─────────────────────────────────────────────────────────────*/
.ec-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
  text-align: center;
  gap: 1rem;
}

.ec-empty-icon {
  width: 4rem;
  height: 4rem;
  border-radius: 1.25rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  margin-bottom: 0.5rem;
}

/* ─────────────────────────────────────────────────────────────
   LOADING STATES
   ─────────────────────────────────────────────────────────────*/
.ec-loading-overlay {
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: inherit;
  z-index: 10;
}

/* Spinner */
.ec-spinner {
  width: 2rem;
  height: 2rem;
  border: 2.5px solid #e2e8f0;
  border-top-color: #0ea5e9;
  border-radius: 50%;
  animation: ec-spin 0.75s linear infinite;
}

@keyframes ec-spin {
  to { transform: rotate(360deg); }
}

/* Dot loader */
.ec-dot-loader {
  display: flex;
  gap: 0.375rem;
  align-items: center;
}

.ec-dot-loader span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #0ea5e9;
  animation: ec-dot-pulse 1.2s ease-in-out infinite;
}

.ec-dot-loader span:nth-child(2) { animation-delay: 0.2s; }
.ec-dot-loader span:nth-child(3) { animation-delay: 0.4s; }

@keyframes ec-dot-pulse {
  0%, 100% { transform: scale(0.7); opacity: 0.4; }
  50%       { transform: scale(1.1); opacity: 1; }
}

/* ─────────────────────────────────────────────────────────────
   HOVER CARD EFFECT (spotlight)
   ─────────────────────────────────────────────────────────────*/
.ec-spotlight-card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

.ec-spotlight-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    600px circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
    rgba(14, 165, 233, 0.06),
    transparent 40%
  );
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
  z-index: 0;
}

.ec-spotlight-card:hover::before {
  opacity: 1;
}

/* ─────────────────────────────────────────────────────────────
   MARQUEE (TICKER) SYSTEM
   ─────────────────────────────────────────────────────────────*/
.ec-marquee-wrapper {
  overflow: hidden;
  mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
}

.ec-marquee-track {
  display: flex;
  width: max-content;
  gap: 1rem;
}

.ec-marquee-track-fwd { animation: ec-scroll-left 40s linear infinite; }
.ec-marquee-track-bwd { animation: ec-scroll-right 40s linear infinite; }

.ec-marquee-wrapper:hover .ec-marquee-track { animation-play-state: paused; }

@keyframes ec-scroll-left {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

@keyframes ec-scroll-right {
  from { transform: translateX(-50%); }
  to   { transform: translateX(0); }
}

/* ─────────────────────────────────────────────────────────────
   DARK MODE TOGGLE BUTTON
   ─────────────────────────────────────────────────────────────*/
.ec-dark-toggle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1.5px solid #e2e8f0;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  color: #475569;
}

.ec-dark-toggle:hover {
  border-color: #0ea5e9;
  color: #0ea5e9;
  background: rgba(14,165,233,0.05);
}

/* ─────────────────────────────────────────────────────────────
   NOTIFICATION DOT
   ─────────────────────────────────────────────────────────────*/
.ec-notification-dot {
  position: absolute;
  top: 0.25rem;
  right: 0.25rem;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #f43f5e;
  border: 1.5px solid #fff;
  animation: ec-notification-pulse 2s ease-in-out infinite;
}

@keyframes ec-notification-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(244, 63, 94, 0.4); }
  50%       { box-shadow: 0 0 0 4px rgba(244, 63, 94, 0); }
}

/* ─────────────────────────────────────────────────────────────
   RESPONSIVE MEDIA QUERIES
   ─────────────────────────────────────────────────────────────*/

/* Tablets */
@media (max-width: 1024px) {
  .ec-bento-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile */
@media (max-width: 640px) {
  .ec-bento-grid {
    grid-template-columns: 1fr;
  }

  .ec-section {
    padding: 3rem 0;
  }

  .ec-pricing-card {
    padding: 1.75rem;
  }

  .ec-testimonial {
    padding: 1.5rem;
  }

  /* Reduce floating CTA text on very small screens */
  .ec-floating-cta span { display: none; }
  .ec-floating-cta { width: 52px; height: 52px; border-radius: 50%; justify-content: center; }
  .ec-floating-cta i { margin: 0; }
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .ec-marquee-track-fwd,
  .ec-marquee-track-bwd {
    animation: none !important;
  }
}
