/* ============================================================
   STYLE.CSS
   ============================================================ */

html { scroll-behavior: smooth; }
* { box-sizing: border-box; }

/* ===== NAVBAR ===== */
#navbar.scrolled {
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(42, 42, 58, 0.8);
}

/* ===== GRADIENT TEXT ===== */
.gradient-text {
  background: linear-gradient(135deg, #7C3AED 0%, #A78BFA 50%, #06B6D4 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ===== HERO BLOBS ===== */
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  animation: float 8s ease-in-out infinite;
}
.blob-1 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(124,58,237,0.25) 0%, transparent 70%);
  top: -200px; left: -200px;
}
.blob-2 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(6,182,212,0.15) 0%, transparent 70%);
  bottom: -100px; right: -150px;
  animation-delay: -4s;
}
@keyframes float {
  0%,100% { transform: translate(0,0) scale(1); }
  33%      { transform: translate(30px,-30px) scale(1.05); }
  66%      { transform: translate(-20px,20px) scale(0.95); }
}
.noise-overlay {
  position: absolute; inset: 0; opacity: 0.03; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* ===== SCROLL ARROW ===== */
.scroll-arrow {
  width: 20px; height: 20px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  animation: scrollBounce 1.5s ease-in-out infinite;
}
@keyframes scrollBounce {
  0%,100% { transform: rotate(45deg) translateY(0); opacity: 0.4; }
  50%      { transform: rotate(45deg) translateY(6px); opacity: 1; }
}

/* ===== SECTION LABELS ===== */
.section-label {
  display: inline-block;
  font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: #7C3AED;
  background: rgba(124,58,237,0.1);
  border: 1px solid rgba(124,58,237,0.3);
  padding: 4px 14px; border-radius: 99px; margin-bottom: 12px;
}
.section-heading {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  line-height: 1.15; color: #fff;
}

/* ===== REVEAL ON SCROLL ===== */
.reveal {
  opacity: 0; transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ===== FILTER BUTTONS ===== */
.filter-btn {
  padding: 8px 18px; border-radius: 99px;
  font-size: 0.8rem; font-weight: 500;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  color: #9ca3af; cursor: pointer;
  transition: all 0.2s;
}
.filter-btn:hover, .filter-btn.active {
  background: #7C3AED; border-color: #7C3AED; color: #fff;
}

/* ============================================================
   MASONRY-HYBRID PORTFOLIO GRID
   ============================================================ */
.portfolio-masonry {
  columns: 1;
  column-gap: 16px;
}
@media (min-width: 640px)  { .portfolio-masonry { columns: 2; } }
@media (min-width: 1024px) { .portfolio-masonry { columns: 3; } }

/* Each card breaks inside column independently */
.p-card {
  break-inside: avoid;
  display: block;
  margin-bottom: 16px;
  position: relative;
  overflow: hidden;
  border-radius: 16px;
  background: #16161F;
  border: 1px solid #2A2A3A;
  cursor: pointer;
  transition: transform 0.35s cubic-bezier(0.34,1.56,0.64,1),
              box-shadow 0.35s ease,
              border-color 0.35s ease;
}
.p-card:hover {
  transform: translateY(-6px) scale(1.01);
  box-shadow: 0 24px 60px rgba(0,0,0,0.5);
  border-color: rgba(124,58,237,0.45);
}

/* Aspect ratio wrappers */
.p-card .card-media {
  position: relative;
  width: 100%;
  overflow: hidden;
}
/* 16:9  — YouTube / Thumbnails */
.p-card.ratio-16-9 .card-media { padding-bottom: 56.25%; }
/* 9:16  — Vertical Shorts / Reels  */
.p-card.ratio-9-16 .card-media { padding-bottom: 177.78%; }
/* 4:5   — Instagram Posts */
.p-card.ratio-4-5  .card-media { padding-bottom: 125%; }
/* 1:1   — Square */
.p-card.ratio-1-1  .card-media { padding-bottom: 100%; }

.p-card .card-media img,
.p-card .card-media video {
  position: absolute;
  inset: 0; width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.25,0.46,0.45,0.94);
}
.p-card:hover .card-media img,
.p-card:hover .card-media video {
  transform: scale(1.07);
}

/* Card overlay */
.p-card .card-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(
    to top,
    rgba(10,10,15,0.96) 0%,
    rgba(10,10,15,0.5)  40%,
    rgba(10,10,15,0.1)  70%,
    transparent         100%
  );
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 18px;
  opacity: 0;
  transition: opacity 0.35s ease;
}
.p-card:hover .card-overlay { opacity: 1; }

/* Play button for video cards */
.card-play {
  width: 48px; height: 48px;
  background: rgba(124,58,237,0.9);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  margin-bottom: 10px;
  transition: transform 0.2s, background 0.2s;
  flex-shrink: 0;
}
.p-card:hover .card-play { transform: scale(1.12); background: #7C3AED; }

/* Card badge */
.card-badge {
  font-size: 0.65rem; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase;
  margin-bottom: 4px;
}
.card-title {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700; font-size: 0.95rem; color: #fff;
  line-height: 1.3;
}

/* Expand hint icon (bottom-right corner) */
.card-expand-hint {
  position: absolute;
  top: 12px; right: 12px;
  width: 32px; height: 32px;
  background: rgba(255,255,255,0.08);
  backdrop-filter: blur(8px);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.7);
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.p-card:hover .card-expand-hint {
  opacity: 1; transform: scale(1);
}

/* ===== SERVICE CARDS ===== */
.service-card {
  background: #16161F; border: 1px solid #2A2A3A;
  border-radius: 16px; padding: 24px;
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
  display: flex; flex-direction: column;
}
.service-card:hover {
  border-color: rgba(124,58,237,0.5);
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(124,58,237,0.12);
}
.service-icon {
  width: 48px; height: 48px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.3s, color 0.3s;
}
.service-cta {
  display: inline-flex; align-items: center;
  font-size: 0.82rem; font-weight: 600;
  color: #7C3AED; text-decoration: none;
  transition: gap 0.2s; gap: 4px;
}
.service-cta:hover { gap: 8px; }

/* ===== TESTIMONIALS ===== */
.testimonial-slide { flex-shrink: 0; width: 100%; }
@media (min-width: 640px)  { .testimonial-slide { width: 50%; } }
@media (min-width: 1024px) { .testimonial-slide { width: 33.333%; } }

.slider-btn {
  width: 40px; height: 40px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: #9ca3af; cursor: pointer;
  transition: all 0.2s;
}
.slider-btn:hover { background: #7C3AED; border-color: #7C3AED; color: #fff; }

.dot {
  width: 8px; height: 8px; border-radius: 99px;
  background: rgba(255,255,255,0.15);
  border: none; cursor: pointer;
  transition: all 0.3s;
}
.dot.active { width: 24px; background: #7C3AED; }

/* ===== FORM ELEMENTS ===== */
.form-label {
  display: block; font-size: 0.78rem; font-weight: 500;
  color: #9ca3af; margin-bottom: 6px;
}
.form-input {
  width: 100%; background: #0A0A0F;
  border: 1px solid #2A2A3A; border-radius: 10px;
  padding: 12px 14px; font-size: 0.875rem; color: #fff;
  outline: none; transition: border-color 0.2s, box-shadow 0.2s;
  appearance: none; -webkit-appearance: none;
}
.form-input::placeholder { color: #4b5563; }
.form-input:focus {
  border-color: #7C3AED;
  box-shadow: 0 0 0 3px rgba(124,58,237,0.15);
}
select.form-input {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%236b7280' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
  background-size: 16px; padding-right: 40px;
}
select.form-input option { background: #16161F; color: #fff; }

/* ===== SOCIAL LINKS ===== */
.social-link {
  display: flex; align-items: center; gap: 10px;
  font-size: 0.85rem; color: #9ca3af; text-decoration: none;
  padding: 8px 0; border-bottom: 1px solid rgba(42,42,58,0.5);
  transition: color 0.2s;
}
.social-link:last-child { border-bottom: none; }
.social-link:hover { color: #A78BFA; }

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #0A0A0F; }
::-webkit-scrollbar-thumb { background: #2A2A3A; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #7C3AED; }

/* ============================================================
   PROJECT MODAL — Glassmorphism
   ============================================================ */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 100;
  display: flex; align-items: center; justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  opacity: 0; pointer-events: none;
  transition: opacity 0.35s ease;
  overflow-y: auto;
}
.modal-backdrop.open {
  opacity: 1; pointer-events: auto;
}
.modal-panel {
  position: relative;
  width: 100%; max-width: 860px;
  margin: auto;
  background: rgba(22, 22, 31, 0.85);
  backdrop-filter: blur(32px);
  -webkit-backdrop-filter: blur(32px);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 24px;
  box-shadow: 0 40px 120px rgba(0,0,0,0.7),
              inset 0 1px 0 rgba(255,255,255,0.06);
  overflow: hidden;
  transform: scale(0.95) translateY(20px);
  transition: transform 0.4s cubic-bezier(0.34,1.56,0.64,1);
}
.modal-backdrop.open .modal-panel {
  transform: scale(1) translateY(0);
}
.modal-header {
  display: flex; align-items: flex-start;
  justify-content: space-between; gap: 16px;
  padding: 28px 28px 0;
}
.modal-badge {
  display: inline-block;
  font-size: 0.65rem; font-weight: 700;
  letter-spacing: 0.15em; text-transform: uppercase;
  padding: 4px 12px; border-radius: 99px;
  background: rgba(124,58,237,0.15);
  border: 1px solid rgba(124,58,237,0.35);
  color: #A78BFA;
}
.modal-close-btn {
  width: 36px; height: 36px; flex-shrink: 0;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: #9ca3af; cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.modal-close-btn:hover { background: rgba(239,68,68,0.2); color: #ef4444; }

.modal-body { padding: 20px 28px; }

.modal-footer {
  padding: 20px 28px 28px;
  border-top: 1px solid rgba(255,255,255,0.06);
  background: rgba(0,0,0,0.2);
}

/* --- Video embed wrapper --- */
.modal-video-wrap {
  position: relative; width: 100%;
  padding-bottom: 56.25%; /* 16:9 */
  border-radius: 14px; overflow: hidden;
  background: #000;
  margin-bottom: 24px;
}
.modal-video-wrap iframe {
  position: absolute; inset: 0;
  width: 100%; height: 100%; border: none;
}

/* --- Info grid (Client Goal / Tools Used) --- */
.modal-info-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-bottom: 20px;
}
@media (min-width: 560px) {
  .modal-info-grid { grid-template-columns: 1fr 1fr; }
}
.modal-info-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 12px; padding: 16px;
}
.modal-info-label {
  font-size: 0.65rem; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: #6b7280; margin-bottom: 8px;
}
.modal-info-value { font-size: 0.875rem; color: #e5e7eb; line-height: 1.6; }

/* --- Client results stat strip --- */
.modal-results {
  display: flex; flex-wrap: wrap; gap: 12px;
  margin-bottom: 20px;
}
.modal-result-pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(124,58,237,0.12);
  border: 1px solid rgba(124,58,237,0.25);
  border-radius: 99px; padding: 8px 16px;
  font-size: 0.8rem; color: #A78BFA; font-weight: 600;
}

/* --- Description --- */
.modal-description {
  font-size: 0.9rem; color: #9ca3af;
  line-height: 1.75; margin-bottom: 20px;
}

/* --- Gallery grid (design / thumbnail type) --- */
.modal-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
  margin-bottom: 20px;
}
.modal-gallery img {
  width: 100%; border-radius: 10px; object-fit: cover;
  border: 1px solid rgba(255,255,255,0.08);
  transition: transform 0.3s ease;
  cursor: zoom-in;
}
.modal-gallery img:hover { transform: scale(1.03); }

/* --- Before / After Slider --- */
.ba-slider {
  position: relative; width: 100%;
  border-radius: 14px; overflow: hidden;
  user-select: none; touch-action: none;
  margin-bottom: 20px;
  cursor: ew-resize;
}
.ba-slider .ba-after,
.ba-slider .ba-before {
  display: block; width: 100%; height: auto;
}
.ba-slider .ba-before {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
  clip-path: inset(0 50% 0 0);
}
.ba-handle {
  position: absolute; top: 0; bottom: 0;
  left: 50%; transform: translateX(-50%);
  width: 40px;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  pointer-events: none; z-index: 5;
}
.ba-handle-line {
  width: 2px; flex: 1;
  background: rgba(255,255,255,0.9);
  box-shadow: 0 0 10px rgba(124,58,237,0.8);
}
.ba-handle-knob {
  width: 38px; height: 38px; border-radius: 50%;
  background: #7C3AED;
  border: 3px solid #fff;
  box-shadow: 0 0 20px rgba(124,58,237,0.7);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 0.75rem; font-weight: 700;
  flex-shrink: 0;
}
.ba-labels {
  display: flex; justify-content: space-between;
  margin-top: 8px;
}
.ba-labels span {
  font-size: 0.7rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.1em; color: #6b7280;
}

/* --- Logo animation / transparent BG style --- */
.modal-logo-stage {
  width: 100%;
  background: repeating-conic-gradient(#1e1e2a 0% 25%, #16161F 0% 50%) 0 0 / 24px 24px;
  border-radius: 14px; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  padding: 40px 20px;
  margin-bottom: 20px;
  min-height: 220px;
}
.modal-logo-stage img,
.modal-logo-stage video {
  max-width: 100%; max-height: 300px; object-fit: contain;
}
.modal-logo-stage-label {
  text-align: center;
  font-size: 0.7rem; text-transform: uppercase;
  letter-spacing: 0.12em; color: #4b5563; margin-bottom: 16px;
}

/* --- Tools tag list --- */
.modal-tools { display: flex; flex-wrap: wrap; gap: 8px; }
.tool-tag {
  padding: 5px 12px; border-radius: 6px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  font-size: 0.75rem; color: #9ca3af;
}
/* ============================================================
   THUMBNAIL GALLERY — Featured image + clickable strip
   ============================================================ */

/* Big featured image container */
.gallery-featured-wrap {
  width: 100%;
  border-radius: 14px;
  overflow: hidden;
  background: #0A0A0F;
  border: 1px solid rgba(255,255,255,0.07);
  margin-bottom: 4px;
}

/* The large image itself */
.gallery-featured-img {
  width: 100%;
  height: auto;
  display: block;
  max-height: 460px;
  object-fit: contain;
  opacity: 1;
  transform: scale(1);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

/* Small thumbnail strip grid */
.gallery-thumb-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 8px;
  margin-bottom: 20px;
}

/* Individual thumbnail in the strip */
.gallery-thumb-item {
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  transition: border-color 0.2s ease, transform 0.2s ease, opacity 0.2s ease;
  opacity: 0.55;
}
.gallery-thumb-item img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}
.gallery-thumb-item:hover {
  opacity: 0.85;
  transform: translateY(-2px);
}
.gallery-thumb-item.active {
  border-color: #7C3AED;
  opacity: 1;
  box-shadow: 0 0 0 3px rgba(124,58,237,0.25);
}