/* ==========================================================================
   OTHMAN RIYADH — PHASE 03: EXPERTISE, CREDIBILITY & PROCESS SYSTEM
   Local Development Architecture • Art Directed • Non-Commercialized
   ========================================================================== */

/* --------------------------------------------------------------------------
   Section Common Badges & Headers
   -------------------------------------------------------------------------- */
.p3-section-head {
  margin-bottom: clamp(40px, 6vw, 70px);
  position: relative;
}

.p3-section-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 9999px;
  background: rgba(229, 195, 138, 0.08);
  border: 1px solid rgba(229, 195, 138, 0.22);
  color: var(--accent-gold, #e5c38a);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.p3-section-badge .badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--accent-gold, #e5c38a);
  box-shadow: 0 0 10px var(--accent-gold, #e5c38a);
}

.p3-section-title {
  font-family: inherit;
  font-size: clamp(2rem, 4.5vw, 3.6rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #f8fafc;
  margin-bottom: 16px;
}

.p3-section-subtitle {
  font-size: clamp(1rem, 1.3vw, 1.18rem);
  color: rgba(248, 250, 252, 0.65);
  max-width: 680px;
  line-height: 1.7;
}

/* --------------------------------------------------------------------------
   01. SELECTED CLIENTS & COLLABORATIONS (Section #clients)
   -------------------------------------------------------------------------- */
.clients-collaborations-section {
  padding: clamp(60px, 8vw, 110px) 0;
  position: relative;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: linear-gradient(180deg, rgba(9, 9, 11, 0.4) 0%, rgba(13, 13, 16, 0.8) 100%);
}

.collab-tier-group {
  margin-top: 36px;
}

.collab-tier-label {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(248, 250, 252, 0.5);
  margin-bottom: 22px;
}

.collab-tier-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0) 100%);
}

[dir="rtl"] .collab-tier-label::after {
  background: linear-gradient(270deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0) 100%);
}

.collab-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
  margin-bottom: 48px;
}

.collab-card {
  position: relative;
  background: rgba(18, 18, 22, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 130px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.4s ease,
              background 0.4s ease,
              box-shadow 0.4s ease;
  text-decoration: none;
  overflow: hidden;
}

.collab-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(229, 195, 138, 0.35), transparent);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.collab-card:hover {
  transform: translateY(-4px);
  border-color: rgba(229, 195, 138, 0.3);
  background: rgba(24, 24, 30, 0.85);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.35), 0 0 20px rgba(229, 195, 138, 0.08);
}

.collab-card:hover::before {
  opacity: 1;
}

.collab-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.collab-brand-name {
  font-size: 1.05rem;
  font-weight: 600;
  color: #f8fafc;
  letter-spacing: -0.01em;
}

.collab-logo-thumb {
  height: 28px;
  max-width: 100px;
  object-fit: contain;
  filter: grayscale(1) brightness(0.9);
  opacity: 0.75;
  transition: filter 0.35s ease, opacity 0.35s ease, transform 0.35s ease;
}

.collab-card:hover .collab-logo-thumb {
  filter: grayscale(0) brightness(1.1);
  opacity: 1;
  transform: scale(1.05);
}

.collab-card-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.78rem;
  color: rgba(248, 250, 252, 0.55);
}

.collab-role-tag {
  background: rgba(255, 255, 255, 0.05);
  padding: 4px 10px;
  border-radius: 6px;
  font-weight: 500;
  color: rgba(248, 250, 252, 0.7);
  white-space: nowrap;
}

.collab-link-cue {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--accent-gold, #e5c38a);
  font-weight: 500;
  font-size: 0.75rem;
  opacity: 0.7;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.collab-card:hover .collab-link-cue {
  opacity: 1;
  transform: translateX(3px);
}

[dir="rtl"] .collab-card:hover .collab-link-cue {
  transform: translateX(-3px);
}

/* --------------------------------------------------------------------------
   02. ELEVATED ABOUT & PROFILE SECTION (#about)
   -------------------------------------------------------------------------- */
.p3-about-experience {
  padding: clamp(70px, 9vw, 130px) 0;
  position: relative;
  background: radial-gradient(circle at 15% 40%, rgba(229, 195, 138, 0.035) 0%, transparent 60%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.p3-about-layout {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: clamp(40px, 6vw, 80px);
  align-items: start;
}

.p3-about-visual-column {
  position: sticky;
  top: 100px;
}

.p3-portrait-frame {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #101014;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 40px rgba(229, 195, 138, 0.06);
}

.p3-portrait-img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  display: block;
  filter: contrast(1.05) brightness(0.96);
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), filter 0.8s ease;
}

.p3-portrait-frame:hover .p3-portrait-img {
  transform: scale(1.03);
  filter: contrast(1.08) brightness(1.02);
}

.p3-portrait-caption-tag {
  position: absolute;
  bottom: 16px;
  left: 16px;
  right: 16px;
  background: rgba(15, 15, 18, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.p3-caption-name {
  font-size: 0.86rem;
  font-weight: 600;
  color: #f8fafc;
}

.p3-caption-role {
  font-size: 0.74rem;
  color: var(--accent-gold, #e5c38a);
  font-weight: 500;
}

.p3-about-quote-headline {
  font-family: inherit;
  font-size: clamp(1.4rem, 2.4vw, 2.1rem);
  font-weight: 600;
  line-height: 1.35;
  color: #f8fafc;
  margin-bottom: 24px;
  letter-spacing: -0.015em;
  border-inline-start: 3px solid var(--accent-gold, #e5c38a);
  padding-inline-start: 20px;
}

.p3-about-bio-text {
  font-size: 1.05rem;
  line-height: 1.8;
  color: rgba(248, 250, 252, 0.72);
  margin-bottom: 36px;
}

.p3-pillars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 40px;
}

.p3-pillar-card {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  padding: 20px;
  transition: border-color 0.3s ease, background 0.3s ease;
}

.p3-pillar-card:hover {
  border-color: rgba(229, 195, 138, 0.3);
  background: rgba(229, 195, 138, 0.03);
}

.p3-pillar-num {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--accent-gold, #e5c38a);
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}

.p3-pillar-title {
  font-size: 0.96rem;
  font-weight: 600;
  color: #f8fafc;
  margin-bottom: 6px;
}

.p3-pillar-desc {
  font-size: 0.82rem;
  line-height: 1.55;
  color: rgba(248, 250, 252, 0.55);
}

.p3-about-stats-triad {
  display: flex;
  gap: clamp(20px, 4vw, 48px);
  padding: 24px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 36px;
}

.p3-stat-item {
  display: flex;
  flex-direction: column;
}

.p3-stat-value {
  font-size: clamp(2rem, 3.2vw, 2.8rem);
  font-weight: 700;
  color: var(--accent-gold, #e5c38a);
  line-height: 1.1;
  font-feature-settings: 'tnum';
}

.p3-stat-label {
  font-size: 0.8rem;
  color: rgba(248, 250, 252, 0.6);
  margin-top: 4px;
}

.p3-about-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* --------------------------------------------------------------------------
   03. THE EXPERTISE EXPERIENCE (#expertise)
   Large Typography-Led Rows • Non-Marketplace • Interactive Preview
   -------------------------------------------------------------------------- */
.expertise-section {
  padding: clamp(80px, 10vw, 140px) 0;
  position: relative;
  background: #09090b;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.expertise-rows-container {
  display: flex;
  flex-direction: column;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  position: relative;
}

.expertise-row {
  position: relative;
  padding: clamp(32px, 4.5vw, 54px) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: grid;
  grid-template-columns: 80px 1.4fr 1.6fr auto;
  gap: clamp(24px, 3.5vw, 48px);
  align-items: center;
  text-decoration: none;
  color: inherit;
  transition: background 0.4s ease, border-color 0.4s ease;
  cursor: pointer;
}

.expertise-row::before {
  content: '';
  position: absolute;
  inset: 0 -24px;
  background: rgba(255, 255, 255, 0.02);
  opacity: 0;
  border-radius: 12px;
  transition: opacity 0.35s ease;
  pointer-events: none;
}

.expertise-row:hover::before,
.expertise-row:focus-visible::before {
  opacity: 1;
}

.expertise-num {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--accent-gold, #e5c38a);
  letter-spacing: 0.08em;
  font-family: inherit;
  font-feature-settings: 'tnum';
}

.expertise-title-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.expertise-title {
  font-size: clamp(1.4rem, 2.2vw, 1.95rem);
  font-weight: 700;
  color: #f8fafc;
  line-height: 1.2;
  letter-spacing: -0.015em;
  transition: color 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.expertise-row:hover .expertise-title {
  color: var(--accent-gold, #e5c38a);
  transform: translateX(6px);
}

[dir="rtl"] .expertise-row:hover .expertise-title {
  transform: translateX(-6px);
}

.expertise-headline {
  font-size: 0.86rem;
  color: rgba(248, 250, 252, 0.55);
  line-height: 1.5;
}

.expertise-body-block {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.expertise-desc {
  font-size: 0.94rem;
  line-height: 1.65;
  color: rgba(248, 250, 252, 0.68);
}

.expertise-tags-flow {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.expertise-tag {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: rgba(248, 250, 252, 0.7);
  font-size: 0.76rem;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 6px;
  transition: border-color 0.3s ease, background 0.3s ease;
}

.expertise-row:hover .expertise-tag {
  border-color: rgba(229, 195, 138, 0.2);
  background: rgba(229, 195, 138, 0.04);
}

.expertise-action-block {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.expertise-link-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #f8fafc;
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  transition: background 0.3s ease, border-color 0.3s ease, color 0.3s ease, transform 0.3s ease;
}

.expertise-link-arrow {
  display: inline-block;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  color: var(--accent-gold, #e5c38a);
}

.expertise-row:hover .expertise-link-pill {
  background: var(--accent-gold, #e5c38a);
  border-color: var(--accent-gold, #e5c38a);
  color: #09090b;
}

.expertise-row:hover .expertise-link-arrow {
  color: #09090b;
  transform: translate(3px, -3px);
}

[dir="rtl"] .expertise-row:hover .expertise-link-arrow {
  transform: translate(-3px, -3px);
}

/* Floating Interactive Visual Preview (Ivan Amad Inspiration) */
.expertise-floating-preview {
  position: fixed;
  top: 0;
  left: 0;
  width: 320px;
  height: 200px;
  border-radius: 14px;
  overflow: hidden;
  pointer-events: none;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.7), 0 0 30px rgba(229, 195, 138, 0.15);
  border: 1px solid rgba(229, 195, 138, 0.3);
  transform: scale(0.92) translate3d(0, 0, 0);
  transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              visibility 0.35s ease;
  will-change: transform, opacity;
}

.expertise-floating-preview.is-active {
  opacity: 1;
  visibility: visible;
  transform: scale(1) translate3d(0, 0, 0);
}

.expertise-floating-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.expertise-floating-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 8px 12px;
  background: rgba(9, 9, 11, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-size: 0.74rem;
  font-weight: 600;
  color: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Inline Mobile Preview Fallback */
.expertise-inline-preview {
  display: none;
}

/* --------------------------------------------------------------------------
   04. THE CREATIVE PROCESS SECTION (#process)
   5-Step Editorial Progression
   -------------------------------------------------------------------------- */
.process-section {
  padding: clamp(80px, 9vw, 130px) 0;
  position: relative;
  background: linear-gradient(180deg, #09090b 0%, rgba(15, 15, 20, 0.95) 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.process-steps-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
  position: relative;
  margin-top: 40px;
}

.process-step-card {
  position: relative;
  background: rgba(18, 18, 22, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 28px 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 260px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.4s ease,
              background 0.4s ease,
              box-shadow 0.4s ease;
}

.process-step-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 20px;
  right: 20px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent-gold, #e5c38a), transparent);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.process-step-card:hover {
  transform: translateY(-6px);
  border-color: rgba(229, 195, 138, 0.35);
  background: rgba(26, 26, 32, 0.85);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 24px rgba(229, 195, 138, 0.06);
}

.process-step-card:hover::before {
  opacity: 1;
}

.process-step-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.process-step-index {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--accent-gold, #e5c38a);
  letter-spacing: 0.08em;
  font-feature-settings: 'tnum';
}

.process-step-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.process-step-card:hover .process-step-indicator {
  background: var(--accent-gold, #e5c38a);
  box-shadow: 0 0 10px var(--accent-gold, #e5c38a);
}

.process-step-title {
  font-size: 1.18rem;
  font-weight: 700;
  color: #f8fafc;
  line-height: 1.25;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}

.process-step-desc {
  font-size: 0.84rem;
  line-height: 1.6;
  color: rgba(248, 250, 252, 0.62);
  margin-bottom: 20px;
}

.process-step-output {
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px dashed rgba(255, 255, 255, 0.1);
  font-size: 0.74rem;
  color: rgba(229, 195, 138, 0.8);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
}

.process-step-output::before {
  content: '✦';
  font-size: 0.68rem;
  color: var(--accent-gold, #e5c38a);
}

/* --------------------------------------------------------------------------
   05. DATA-DRIVEN TESTIMONIALS SECTION (Dormant when no verified quotes)
   -------------------------------------------------------------------------- */
.testimonials-section {
  display: none; /* Shown dynamically only if real verified quotes exist */
  padding: clamp(60px, 8vw, 100px) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

/* --------------------------------------------------------------------------
   Responsive Breakpoints & Media Queries
   -------------------------------------------------------------------------- */
@media (max-width: 1200px) {
  .expertise-row {
    grid-template-columns: 60px 1.2fr 1.6fr auto;
    gap: 24px;
  }
  .process-steps-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 960px) {
  .p3-about-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .p3-about-visual-column {
    position: static;
    max-width: 360px;
  }
  .p3-pillars-grid {
    grid-template-columns: 1fr;
  }
  .expertise-row {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 30px 0;
  }
  .expertise-action-block {
    justify-content: flex-start;
    margin-top: 8px;
  }
  .expertise-floating-preview {
    display: none !important;
  }
  .expertise-inline-preview {
    display: block;
    width: 100%;
    height: 180px;
    border-radius: 12px;
    overflow: hidden;
    margin-top: 14px;
    border: 1px solid rgba(255, 255, 255, 0.1);
  }
  .expertise-inline-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  .process-steps-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .collab-grid {
    grid-template-columns: 1fr;
  }
  .process-steps-grid {
    grid-template-columns: 1fr;
  }
  .p3-about-stats-triad {
    flex-direction: column;
    gap: 20px;
  }
}

/* --------------------------------------------------------------------------
   Reduced Motion Preferences
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .collab-card,
  .p3-portrait-img,
  .process-step-card,
  .expertise-floating-preview,
  .expertise-row:hover .expertise-title,
  .expertise-link-arrow {
    transform: none !important;
    transition: none !important;
  }
  .expertise-floating-preview {
    display: none !important;
  }
}
