/* ===== Custom Work Section ===== */

/* --- Base (Mobile) --- */
.custom {
  position: relative;
  padding: var(--space-2xl) 0 var(--space-2xl);
  background: var(--az-dark-1);
  overflow: hidden;
}

.custom__texture {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.25;
  background: repeating-linear-gradient(
    to bottom,
    transparent,
    transparent 2px,
    rgba(244, 131, 46, 0.012) 2px,
    rgba(244, 131, 46, 0.012) 3px
  );
}

/* Three.js Canvas */
.custom__canvas-wrap {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.custom__canvas-wrap canvas {
  width: 100% !important;
  height: 100% !important;
}

/* ── Header ── */
.custom__header {
  text-align: center;
  margin-bottom: var(--space-xl);
  position: relative;
  z-index: 5;
}

.custom__title {
  font-size: var(--fs-h1);
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.custom__subtitle {
  font-size: var(--fs-body-lg);
  color: var(--text-secondary);
  max-width: 560px;
  margin-inline: auto;
  line-height: 1.7;
}

/* ── Cards Grid ── */
.custom__cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1rem, 2vw, 1.5rem);
  margin-bottom: var(--space-xl);
  position: relative;
  z-index: 5;
}

/* Card */
.custom__card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: clamp(1.5rem, 3vw, 2rem);
  background: rgba(35, 28, 21, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.custom__card:hover {
  border-color: var(--border-orange);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.3), 0 0 0 1px rgba(244,131,46,0.08);
}

/* Background patterns */
.custom__card-pattern {
  position: absolute;
  inset: 0;
  pointer-events: none;
  color: var(--az-orange);
  opacity: 0.06;
  transition: opacity 0.4s ease;
}

.custom__card:hover .custom__card-pattern {
  opacity: 0.12;
}

.custom__card-pattern svg {
  width: 100%;
  height: 100%;
}

/* Icon */
.custom__card-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  background: var(--az-orange-dim);
  border: 1px solid var(--border-orange);
  color: var(--az-orange);
  margin-bottom: 1rem;
  position: relative;
  z-index: 2;
  transition: all 0.3s ease;
}

.custom__card:hover .custom__card-icon {
  background: rgba(244,131,46,0.15);
  box-shadow: 0 0 20px rgba(244,131,46,0.15);
}

/* Text */
.custom__card-title {
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  position: relative;
  z-index: 2;
}

.custom__card-body {
  font-size: var(--fs-body);
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 1rem;
  position: relative;
  z-index: 2;
  flex-grow: 1;
}

/* Format tags */
.custom__card-formats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.2rem;
  position: relative;
  z-index: 2;
}

.custom__card-formats span {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 0.25em 0.6em;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
}

/* Card CTA link */
.custom__card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  font-family: var(--font-body);
  font-size: var(--fs-small);
  font-weight: 600;
  color: var(--az-orange);
  position: relative;
  z-index: 2;
  transition: all 0.3s ease;
  width: fit-content;
}

.custom__card-link svg {
  transition: transform 0.3s ease;
}

.custom__card-link:hover {
  color: var(--az-orange-light);
}

.custom__card-link:hover svg {
  transform: translateX(3px);
}


/* ── Testimonial ── */
.custom__testimonial {
  position: relative;
  z-index: 5;
  max-width: 720px;
  margin: 0 auto var(--space-xl);
  padding: clamp(1.5rem, 3vw, 2rem) clamp(1.5rem, 4vw, 2.5rem);
  background: rgba(35, 28, 21, 0.5);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
}

.custom__quote-border {
  position: absolute;
  top: 1.5rem;
  bottom: 1.5rem;
  left: 0;
  width: 3px;
  border-radius: 2px;
  background: linear-gradient(
    to bottom,
    var(--az-orange),
    var(--az-orange-dark)
  );
  box-shadow: 0 0 12px rgba(244,131,46,0.3);
}

.custom__quote {
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 1.2vw + 0.5rem, 1.3rem);
  font-style: italic;
  font-weight: 400;
  color: var(--text-primary);
  line-height: 1.65;
  margin-bottom: 1rem;
}

.custom__quote-attr {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.custom__quote-name {
  font-family: var(--font-body);
  font-size: var(--fs-small);
  font-weight: 600;
  color: var(--text-primary);
}

.custom__quote-company {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

/* ── Footer CTA ── */
.custom__footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  position: relative;
  z-index: 5;
}

.btn--lg {
  padding: 1.1em 2.5em;
  font-size: var(--fs-body);
}

.custom__footer-note {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
  letter-spacing: 0.06em;
}


/* --- Tablet (768px+) --- */
@media (min-width: 768px) {
  .custom__cards {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* --- Desktop (1024px+) --- */
@media (min-width: 1024px) {
  .custom__cards {
    gap: 1.5rem;
  }
}

/* --- Mobile --- */
@media (max-width: 767px) {
  .custom__canvas-wrap {
    opacity: 0.3;
  }

  .custom__card-pattern {
    opacity: 0.04;
  }
}

/* Build reveal */
.reveal-custom {
  opacity: 0;
  transform: translateY(25px);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .reveal-custom {
    opacity: 1;
    transform: none;
  }
}
