/* Service timeline — clickable cards */
.proj-timeline-item.is-right .proj-timeline-card-link {
  grid-column: 3;
  grid-row: 1;
  text-align: right;
}

.proj-timeline-item.is-left .proj-timeline-card-link {
  grid-column: 1;
  grid-row: 1;
  text-align: left;
}

html[dir="rtl"] .proj-timeline-item.is-right .proj-timeline-card-link,
html[lang="ar"] .proj-timeline-item.is-right .proj-timeline-card-link {
  text-align: right;
}

html[dir="rtl"] .proj-timeline-item.is-left .proj-timeline-card-link,
html[lang="ar"] .proj-timeline-item.is-left .proj-timeline-card-link {
  text-align: left;
}

.proj-timeline-card-link {
  display: block;
  text-decoration: none;
  color: inherit;
  position: relative;
  z-index: 3;
}

.proj-timeline-card-link:focus-visible {
  outline: 2px solid var(--theme2);
  outline-offset: 4px;
  border-radius: 8px;
}

.proj-timeline-card-link .proj-timeline-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  cursor: pointer;
}

.proj-timeline-card-link:hover .proj-timeline-card {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(16, 35, 56, 0.14);
  border-color: var(--theme2);
}

.proj-timeline-card-link::after {
  content: "\f061";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  position: absolute;
  bottom: 20px;
  inset-inline-end: 20px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--theme);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

html[dir="rtl"] .proj-timeline-card-link::after,
html[lang="ar"] .proj-timeline-card-link::after {
  content: "\f060";
  transform: translateX(8px);
}

.proj-timeline-card-link:hover::after {
  opacity: 1;
  transform: translateX(0);
}

/* Projects archive — Bootstrap tabs */
.pt-projects-sec {
  padding: 80px 0 100px;
}

.pt-tabs-wrap {
  margin-bottom: 48px;
}

.pt-tabs-nav {
  border: none;
  border-bottom: 2px solid rgba(16, 35, 56, 0.08);
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  padding-bottom: 0;
  margin-bottom: 0;
}

.pt-tabs-nav.nav-tabs {
  --bs-nav-tabs-border-width: 0;
  --bs-nav-tabs-border-color: transparent;
  --bs-nav-tabs-link-active-color: var(--theme);
  --bs-nav-tabs-link-active-bg: #fff;
}

.pt-tabs-nav .nav-link {
  border: none;
  border-bottom: 3px solid transparent;
  border-radius: 12px 12px 0 0;
  padding: 14px 26px;
  color: #667085;
  font-weight: 600;
  background: transparent;
  transition: all 0.25s ease;
  box-shadow: none;
  margin-bottom: -2px;
}

.pt-tabs-nav .nav-link:hover {
  color: var(--theme2);
  border-bottom-color: rgba(195, 138, 74, 0.45);
  background: rgba(16, 35, 56, 0.03);
}

.pt-tabs-nav .nav-link.active {
  background: #fff;
  border-bottom-color: var(--theme2);
  color: var(--theme);
  box-shadow: 0 -4px 20px rgba(16, 35, 56, 0.06);
}

.pt-tab-pane {
  padding-top: 8px;
}

.pt-projects-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
}

.pt-projects-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 24px;
  border: 1px dashed rgba(16, 35, 56, 0.18);
  border-radius: 16px;
  color: #667085;
  background: #fafbfc;
}

/* Modern project card */
.pt-project-card {
  height: 100%;
}

.pt-project-card__link {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: inherit;
  background: #fff;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(16, 35, 56, 0.08);
  box-shadow: 0 8px 30px rgba(16, 35, 56, 0.08);
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.pt-project-card__link:hover {
  transform: translateY(-8px);
  box-shadow: 0 22px 50px rgba(16, 35, 56, 0.16);
}

.pt-project-card__media {
  position: relative;
  aspect-ratio: 16 / 11;
  overflow: hidden;
}

.pt-project-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.pt-project-card__link:hover .pt-project-card__media img {
  transform: scale(1.08);
}

.pt-project-card__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(16, 35, 56, 0) 35%, rgba(16, 35, 56, 0.75) 100%);
  opacity: 0.85;
  transition: opacity 0.35s ease;
}

.pt-project-card__link:hover .pt-project-card__overlay {
  opacity: 1;
}

.pt-project-card__badge {
  position: absolute;
  top: 16px;
  inset-inline-start: 16px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--theme);
  font-size: 12px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 999px;
  backdrop-filter: blur(6px);
}

.pt-project-card__action {
  position: absolute;
  bottom: 16px;
  inset-inline-end: 16px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--theme2);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateY(12px);
  opacity: 0;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.pt-project-card__link:hover .pt-project-card__action {
  transform: translateY(0);
  opacity: 1;
}

.pt-project-card__body {
  padding: 24px 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.pt-project-card__logo {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: #f5f7fa;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
}

.pt-project-card__logo img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.pt-project-card__title {
  font-size: 20px;
  line-height: 1.35;
  margin: 0;
  color: var(--theme);
  transition: color 0.25s ease;
}

.pt-project-card__link:hover .pt-project-card__title {
  color: var(--theme2);
}

.pt-project-card__meta {
  margin: 0;
  font-size: 14px;
  color: var(--theme2);
  display: flex;
  align-items: center;
  gap: 8px;
}

.pt-project-card__excerpt {
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
  color: #667085;
}

@media (max-width: 991px) {
  .pt-projects-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }
}

@media (max-width: 767px) {
  .proj-timeline-item.is-right .proj-timeline-card-link,
  .proj-timeline-item.is-left .proj-timeline-card-link {
    grid-column: 2;
    text-align: start;
  }
}

@media (max-width: 575px) {
  .pt-projects-grid {
    grid-template-columns: 1fr;
  }

  .pt-tabs-nav .nav-link {
    padding: 10px 18px;
    font-size: 14px;
  }
}
