/* ==========================================================================
   res&dev.css - Styles for WakinSoftures Services Page (Research & Development)
   ========================================================================== */

:root {
  --primary: #6d28d9; /* Royal Purple */
  --primary-hover: #5b21b6;
  --badge-bg: #f5f3ff;
  --feature-card-shadow: 0 10px 30px rgba(109, 40, 217, 0.04);
}

/* ---- Breadcrumbs ---- */
.breadcrumb-container {
  padding-top: 100px; /* Offset for fixed navbar */
  padding-bottom: 10px;
  background-color: #f8fafc;
}

.breadcrumb {
  margin-bottom: 0;
  font-size: 0.88rem;
  font-weight: 500;
}

.breadcrumb-item a {
  color: #64748b;
  text-decoration: none;
  transition: var(--transition);
}

.breadcrumb-item a:hover {
  color: var(--primary);
}

.breadcrumb-item.active {
  color: var(--primary);
  font-weight: 600;
}

/* ---- Hero Section ---- */
.rnd-hero-section {
  padding: 20px 0 50px;
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
}

.badge-solution {
  background-color: var(--badge-bg);
  color: var(--primary);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.5rem 1rem;
  border-radius: 50px;
  letter-spacing: 0.5px;
}

.rnd-hero-section .hero-title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  color: var(--text-dark);
  margin-top: 0.5rem;
  margin-bottom: 0.75rem;
  line-height: 1.15;
}

.rnd-hero-section .hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 1rem;
}

.rnd-hero-section .hero-desc {
  color: #475569;
  font-size: 1.02rem;
  line-height: 1.65;
  max-width: 580px;
}

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

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

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

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

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

.btn-quote-action {
  padding: 0.8rem 2.2rem;
  font-weight: 600;
  border-radius: 50px;
}

.btn-work-action {
  padding: 0.8rem 2.2rem;
  font-weight: 600;
  border-radius: 50px;
}

/* Hero benefits grid */
.hero-benefits-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  margin-top: 2rem;
}

.benefit-item {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
}

.benefit-item i {
  font-size: 1.45rem;
  color: var(--primary);
  background-color: var(--badge-bg);
  width: 42px;
  height: 42px;
  min-width: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.benefit-text {
  display: flex;
  flex-direction: column;
}

.benefit-text strong {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 0.15rem;
}

.benefit-text span {
  font-size: 0.82rem;
  color: #64748b;
  line-height: 1.4;
}

.rnd-illustration-wrapper {
  position: relative;
  width: 100%;
  margin-top: -105px;
}

.rnd-hero-img {
  max-width: 100%;
  height: auto;
  border-radius: 20px;
  filter: drop-shadow(0 20px 45px rgba(0, 0, 0, 0.08));
}

/* Overlay Stats Bar */
.rnd-stats-overlay {
  position: absolute;
  bottom: -55px;
  left: 5%;
  width: 90%;
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.06);
  padding: 1.25rem;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  z-index: 10;
}

.stats-overlay-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  position: relative;
}

.stats-overlay-item:not(:last-child)::after {
  content: '';
  position: absolute;
  right: -0.5rem;
  top: 15%;
  height: 70%;
  width: 1px;
  background-color: #e2e8f0;
}

.stats-icon {
  width: 42px;
  height: 42px;
  min-width: 42px;
  border-radius: 10px;
  background-color: var(--badge-bg);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.stats-content {
  display: flex;
  flex-direction: column;
}

.stats-content strong {
  font-size: 0.9rem;
  color: var(--text-dark);
  font-weight: 700;
}

.stats-content span {
  font-size: 0.75rem;
  color: #64748b;
}

/* ---- Offers Section ---- */
.rnd-offers-section {
  background-color: #ffffff;
  padding: 50px 0;
}

.rnd-section-header {
  margin-bottom: 3.5rem;
}

.rnd-section-tag {
  color: var(--primary);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 1px;
}

.rnd-offers-section .section-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  color: var(--text-dark);
}

.offer-card {
  background-color: #ffffff;
  border: 1px solid #eaeaea;
  border-radius: 16px;
  padding: 2.5rem 1.5rem;
  height: 100%;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  box-shadow: var(--feature-card-shadow);
}

.offer-card:hover {
  transform: translateY(-5px);
  border-color: rgba(109, 40, 217, 0.15);
  box-shadow: 0 15px 35px rgba(109, 40, 217, 0.08);
}

.offer-icon {
  width: 60px;
  height: 60px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin: 0 auto 1.5rem;
}

/* Colored Icon themes */
.si-green { background-color: #e8f5e9; color: #2e7d32; }
.si-red { background-color: #ffebee; color: #c62828; }
.si-blue { background-color: #e3f2fd; color: #1565c0; }
.si-purple { background-color: #f3e5f5; color: #6a1b9a; }
.si-yellow { background-color: #fffde7; color: #f9a825; }
.si-emerald { background-color: #e0f2f1; color: #00695c; }

.offer-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 0.75rem;
}

.offer-desc {
  color: #64748b;
  font-size: 0.86rem;
  line-height: 1.6;
  margin-bottom: 0;
}

/* ---- Process Section ---- */
.rnd-process-section {
  background-color: #f8fafc;
  padding: 50px 0;
}

.process-flow-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 6px;
  margin-top: 3rem;
}

.process-node {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background-color: #ffffff;
  padding: 25px 8px;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.02);
  position: relative;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.process-node:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(109, 40, 217, 0.06);
}

.node-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background-color: var(--badge-bg);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  margin-bottom: 1rem;
}

.node-step {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background-color: var(--primary);
  color: #ffffff;
  font-size: 0.62rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.node-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 0.4rem;
}

.node-desc {
  font-size: 0.74rem;
  color: #64748b;
  line-height: 1.4;
  margin-bottom: 0;
}

.process-arrow {
  align-self: center;
  font-size: 1.25rem;
  color: #cbd5e1;
  margin-bottom: 20px;
}

/* ---- Technologies Section ---- */
.rnd-techs-section {
  padding: 50px 0;
  background-color: #ffffff;
  border-bottom: 1px solid #f1f5f9;
}

.tech-badge {
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.8rem 1.6rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: #1e293b;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.02);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.tech-badge img {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

.tech-badge:hover {
  border-color: var(--primary);
  box-shadow: 0 10px 25px rgba(109, 40, 217, 0.06);
  transform: translateY(-3px);
}

/* ---- Why Choose Section ---- */
.rnd-why-section {
  padding: 50px 0;
  background-color: #f8fafc;
}

.why-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  color: var(--text-dark);
}

.why-checklist {
  list-style: none;
  padding: 0;
  margin: 0;
}

.why-checklist li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-dark);
  padding: 0.5rem 0;
}

.why-checklist li i {
  color: var(--primary);
  font-size: 1.2rem;
}

.why-buttons {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.btn-build-action {
  padding: 0.8rem 2.2rem;
  font-weight: 600;
  border-radius: 50px;
}

/* Why choose us image wrapper */
.why-rnd-img-wrapper {
  position: relative;
  width: 100%;
}

.rnd-why-img {
  max-width: 100%;
  height: auto;
  border-radius: 20px;
  filter: drop-shadow(0 15px 35px rgba(0, 0, 0, 0.04));
  animation: floatRndWhy 3.5s ease-in-out infinite alternate;
}

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

/* Counters Grid */
.counters-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.counter-box {
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.25rem;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 4px 15px rgba(0,0,0,0.01);
  transition: transform 0.25s, border-color 0.25s;
}

.counter-box:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
}

.counter-icon {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background-color: var(--badge-bg);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
}

.counter-text h3 {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-dark);
  margin-bottom: 0.25rem;
}

.counter-text span {
  font-size: 0.78rem;
  color: #64748b;
  line-height: 1.35;
  display: block;
}

/* Bottom Action Banner Card */
.rnd-action-banner {
  background-color: var(--primary);
  color: #ffffff;
  padding: 2.25rem 2.75rem;
  border-radius: 16px;
  box-shadow: 0 15px 35px rgba(109, 40, 217, 0.15);
}

.banner-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
}

.banner-content h4 {
  font-weight: 700;
  font-size: 1.3rem;
  margin-bottom: 0.35rem;
}

.banner-content p {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.85);
}

.btn-banner-quote {
  padding: 0.8rem 2rem;
  font-weight: 600;
  color: var(--primary);
  border-radius: 50px;
}

/* Large tablet / small laptop: tighten the 4-column absolute overlay */
@media (min-width: 992px) and (max-width: 1199px) {
  .rnd-stats-overlay {
    padding: 0.9rem 0.75rem;
    gap: 0.5rem;
    left: 2%;
    width: 96%;
  }

  .stats-overlay-item {
    gap: 0.5rem;
  }

  .stats-icon {
    width: 36px;
    height: 36px;
    min-width: 36px;
    font-size: 1rem;
  }

  .stats-content strong {
    font-size: 0.82rem;
  }

  .stats-content span {
    font-size: 0.68rem;
  }
}

/* ---- Responsive CSS ---- */
@media (max-width: 991.98px) {
  .breadcrumb-container {
    padding-top: 85px;
  }
  
  .rnd-hero-section {
    text-align: center;
    padding-bottom: 40px;
  }
  
  .rnd-hero-section .hero-desc {
    margin-left: auto;
    margin-right: auto;
  }
  
  .hero-buttons {
    justify-content: center;
  }
  
  .hero-benefits-grid {
    grid-template-columns: repeat(2, 1fr);
    max-width: 550px;
    margin: 2rem auto 0;
  }

  .benefit-item {
    text-align: left;
  }
  
  .rnd-illustration-wrapper {
    margin-top: 1rem;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
  }
  
  .rnd-illustration-wrapper::before {
    display: none !important;
  }

  .rnd-stats-overlay {
    position: static;
    grid-template-columns: repeat(2, 1fr);
    width: 100%;
    margin-top: 2rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.02);
    text-align: left;
    gap: 1rem;
    padding: 1rem;
  }
  
  .stats-overlay-item::after {
    display: none !important;
  }
  
  .process-flow-wrapper {
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
  }
  
  .process-node {
    width: 100%;
    max-width: 320px;
    padding: 25px 15px;
  }
  
  .rnd-why-section {
    text-align: center;
  }
  
  .why-checklist {
    max-width: 320px;
    margin: 0 auto 2rem;
    text-align: left;
  }
  
  .why-buttons {
    justify-content: center;
    margin-bottom: 3rem;
  }
  
  .why-rnd-img-wrapper {
    margin: 0 auto 3rem;
    max-width: 380px;
  }
  
  .counters-grid {
    max-width: 480px;
    margin: 0 auto;
    text-align: left;
  }
}

@media (max-width: 767.98px) {
  .rnd-action-banner {
    padding: 1.75rem;
  }
}

/* Targeted fix for mid-tablets (768px–900px) where 4 items in a row overflow */
@media (min-width: 768px) and (max-width: 900px) {
  .rnd-stats-overlay {
    position: static;
    grid-template-columns: repeat(2, 1fr);
    width: 100%;
    margin-top: 1.5rem;
    gap: 0.75rem;
    padding: 0.85rem;
  }

  .stats-overlay-item::after {
    display: none !important;
  }

  .stats-icon {
    width: 36px;
    height: 36px;
    min-width: 36px;
    font-size: 1rem;
  }

  .stats-content strong {
    font-size: 0.82rem;
  }

  .stats-content span {
    font-size: 0.7rem;
  }
}

@media (max-width: 575.98px) {
  .hero-benefits-grid {
    grid-template-columns: 1fr;
  }

  .benefit-item {
    max-width: 280px;
    margin: 0 auto;
  }
  
  .rnd-stats-overlay {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .stats-overlay-item {
    justify-content: flex-start;
    max-width: 240px;
    margin: 0 auto;
    width: 100%;
  }
  
  .counters-grid {
    grid-template-columns: 1fr;
  }
}
