/* ==========================================================================
   Social Media Showcase Section (TikTok Showcase)
   Used on: index.html & about-us.html
   ========================================================================== */

.social-showcase-section {
  width: 100%;
  background-color: #fafafa;
  padding: 100px 0;
  position: relative;
  overflow: hidden;
}

.social-showcase-container {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 120px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 80px;
  box-sizing: border-box;
}

/* --------------------------------------------------------------------------
   Card Showcase (Left)
   -------------------------------------------------------------------------- */
.social-showcase-card {
  width: 640px;
  height: 658px;
  position: relative;
  border-radius: 16px;
  border: 1px solid #dedede;
  background: linear-gradient(180deg, #eeeeee 54%, #dedede 100%);
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  flex-shrink: 0;
  box-sizing: border-box;
}

/* Card Header: Profile Info + Follow Button */
.social-showcase-card-header {
  position: absolute;
  top: 30px;
  left: 30px;
  right: 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 10;
  gap: 16px;
}

.social-showcase-profile {
  display: flex;
  align-items: center;
  gap: 12px;
}

.social-showcase-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #181818;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  overflow: hidden;
}

.social-showcase-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.social-showcase-profile-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.social-showcase-name {
  font-family: var(--font-sans, "Satoshi Variable", "Satoshi", sans-serif);
  font-size: 18px;
  font-weight: 500;
  line-height: 23px;
  color: #181818;
  white-space: nowrap;
}

.social-showcase-handle {
  font-family: var(--font-sans, "Satoshi Variable", "Satoshi", sans-serif);
  font-size: 14px;
  font-weight: 400;
  line-height: 18px;
  color: #4d4d4d;
  white-space: nowrap;
}

/* Follow CTA Button — extends .build-cta-button from cta-button.css */
.social-showcase-follow-btn {
  flex-shrink: 0;
  box-shadow: 0 4px 20px 0 rgba(0, 0, 0, 0.15);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.social-showcase-follow-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px 0 rgba(0, 0, 0, 0.2);
}

.social-showcase-follow-btn:active {
  transform: translateY(0);
}

/* --------------------------------------------------------------------------
   Phone Frame & Video Showcase
   -------------------------------------------------------------------------- */
.social-showcase-phone-wrapper {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 520px;
  overflow: hidden;
  z-index: 5;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.social-showcase-phone-device {
  position: relative;
  width: 314px;
  height: 518px;
  border-radius: 44px 44px 0 0;
  overflow: hidden;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.18);
  background-color: #000000;
}

.social-phone-view {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transition:
    opacity 0.3s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

.social-phone-view:not(.is-active) {
  opacity: 0;
  pointer-events: none;
  transform: scale(0.98);
}

.social-phone-view.is-active {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

/* Mode 1: Profile View */
.social-phone-profile {
  background-color: #ffffff;
}

.social-showcase-phone-img {
  width: 314px;
  height: 518px;
  display: block;
  object-fit: contain;
  object-position: bottom center;
  user-select: none;
  -webkit-user-drag: none;
}

/* Autoplay Video Preview Box on Featured Grid Card */
.social-phone-feed-vid-box {
  position: absolute;
  left: 14px;
  top: 272px;
  width: 97px;
  height: 130px;
  border-radius: 4px;
  overflow: hidden;
  cursor: pointer;
  z-index: 4;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
  background-color: #000000;
}

.social-phone-feed-vid-box:hover {
  transform: scale(1.04);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.social-phone-feed-vid {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.social-phone-vid-badge {
  position: absolute;
  bottom: 6px;
  left: 6px;
  padding: 2px 6px;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-sans, "Satoshi Variable", "Satoshi", sans-serif);
  font-size: 10px;
  font-weight: 600;
  color: #ffffff;
  pointer-events: none;
  letter-spacing: 0.02em;
}

/* Mode 2: Full Phone Video Player */
.social-phone-player {
  background-color: #000000;
  border-radius: 44px 44px 0 0;
  border: 4px solid #1a1a1a;
  border-bottom: none;
  box-sizing: border-box;
}

.social-phone-player-vid {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Phone Top Overlay (Back, Creator name, Sound toggle) */
.social-player-topbar {
  position: absolute;
  top: 14px;
  left: 12px;
  right: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 10;
  color: #ffffff;
}

.social-player-back-btn,
.social-player-sound-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: none;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition:
    background-color 0.2s ease,
    transform 0.2s ease;
  padding: 0;
}

.social-player-back-btn:hover,
.social-player-sound-btn:hover {
  background: rgba(0, 0, 0, 0.75);
  transform: scale(1.08);
}

.social-player-creator-tag {
  display: flex;
  align-items: center;
  gap: 6px;
}

.social-player-creator-name {
  font-family: var(--font-sans, "Satoshi Variable", "Satoshi", sans-serif);
  font-size: 13px;
  font-weight: 600;
  color: #ffffff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8);
}

.is-hidden {
  display: none;
}

/* Phone Bottom Overlay (Caption, Sound title) */
.social-player-bottom {
  position: absolute;
  bottom: 20px;
  left: 14px;
  right: 52px;
  z-index: 10;
  color: #ffffff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.85);
  pointer-events: none;
}

.social-player-caption {
  font-family: var(--font-sans, "Satoshi Variable", "Satoshi", sans-serif);
  font-size: 13px;
  font-weight: 500;
  line-height: 17px;
  margin-bottom: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.social-player-sound-title {
  font-family: var(--font-sans, "Satoshi Variable", "Satoshi", sans-serif);
  font-size: 11px;
  font-weight: 400;
  opacity: 0.9;
  display: flex;
  align-items: center;
  gap: 6px;
}

.social-player-sound-title svg {
  flex-shrink: 0;
}

/* TikTok Floating Sidebar Actions (Avatar, Likes, Comments, Share) */
.social-player-sidebar {
  position: absolute;
  right: 8px;
  bottom: 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  z-index: 10;
  pointer-events: none;
}

.social-player-avatar-small {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1.5px solid #ffffff;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.social-player-avatar-small img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.social-player-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  color: #ffffff;
  font-family: var(--font-sans, "Satoshi Variable", "Satoshi", sans-serif);
  font-size: 10px;
  font-weight: 600;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.85);
}

/* --------------------------------------------------------------------------
   Social Navigation Rail (Right Edge of Card)
   -------------------------------------------------------------------------- */
.social-showcase-nav-rail {
  position: absolute;
  right: 24px;
  bottom: 28px;
  width: 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  z-index: 10;
}

.social-rail-item {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: none;
  border: 2px solid rgba(220, 220, 220, 0.85);
  padding: 0;
  text-decoration: none;
  cursor: pointer;
  box-sizing: border-box;
  transition:
    transform 0.2s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.2s ease,
    box-shadow 0.2s ease;
  user-select: none;
  flex-shrink: 0;
  overflow: hidden;
}

.social-rail-item:hover {
  transform: scale(1.06);
  border-color: #a8a8a8;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.social-rail-item-inner {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.social-rail-item img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  pointer-events: none;
}

/* Active Avatar Button: single gray border and elevation */
.social-rail-item.is-active {
  border: 2px solid #8e8e8e;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.16);
  transform: scale(1.08);
}

.social-rail-item.is-active:hover {
  transform: scale(1.08);
  border-color: #8e8e8e;
}

/* --------------------------------------------------------------------------
   Right Text Content
   -------------------------------------------------------------------------- */
.social-showcase-content {
  width: 480px;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  align-self: flex-start;
  flex-shrink: 0;
}

.social-showcase-eyebrow {
  font-family: var(--font-sans, "Satoshi Variable", "Satoshi", sans-serif);
  font-size: 16px;
  font-weight: 400;
  line-height: 21px;
  color: #313131;
  margin-bottom: 16px;
}

.social-showcase-title {
  font-family: var(--font-sans, "Satoshi Variable", "Satoshi", sans-serif);
  font-size: 44px;
  font-weight: 500;
  line-height: 53px;
  color: #181818;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.social-showcase-desc {
  font-family: var(--font-sans, "Satoshi Variable", "Satoshi", sans-serif);
  font-size: 16px;
  font-weight: 400;
  line-height: 24px;
  color: #4d4d4d;
}

/* --------------------------------------------------------------------------
   Responsive Design
   -------------------------------------------------------------------------- */
@media (max-width: 1360px) {
  .social-showcase-container {
    padding: 0 48px;
    gap: 48px;
    justify-content: center;
  }
}

@media (max-width: 1080px) {
  .social-showcase-section {
    padding: 80px 0;
  }

  .social-showcase-container {
    flex-direction: column-reverse;
    align-items: center;
    gap: 40px;
    padding: 0 32px;
  }

  .social-showcase-content {
    width: 100%;
    max-width: 640px;
    text-align: left;
    align-self: auto;
  }
}

@media (max-width: 680px) {
  .social-showcase-section {
    padding: 60px 0;
  }

  .social-showcase-container {
    padding: 0 16px;
  }

  .social-showcase-card {
    width: 100%;
    height: 560px;
  }

  .social-showcase-card-header {
    top: 20px;
    left: 16px;
    right: 16px;
    gap: 8px;
  }

  .social-showcase-name {
    font-size: 15px;
    line-height: 19px;
  }

  .social-showcase-handle {
    font-size: 12px;
    line-height: 16px;
  }

  .social-showcase-phone-wrapper {
    left: 0;
    right: 0;
    width: 100%;
    height: 430px;
  }

  .social-showcase-phone-device {
    width: 260px;
    height: 428px;
  }

  .social-showcase-phone-img {
    width: 260px;
    height: 428px;
  }

  .social-phone-feed-vid-box {
    left: 11px;
    top: 225px;
    width: 80px;
    height: 108px;
  }

  .social-showcase-nav-rail {
    right: 12px;
    bottom: 20px;
    gap: 10px;
  }

  .social-rail-item {
    width: 40px;
    height: 40px;
    border-radius: 10px;
  }

  .social-showcase-title {
    font-size: 32px;
    line-height: 40px;
  }
}
