/* ==========================================================================
   AIRISH - Artist Profile & Pinterest Masonry Grid Stylesheet (css/artist.css)
   Inspired by Luxury Dark Mobile UI & Pinterest Masonry Grid Layout
   ========================================================================== */

/* Page Layout & Sticky Discover Filter Wrapper */

.artist-main-content {
  padding-top: 0px;
  padding-bottom: 5px;
}

.artist-main-content .search-section {
  margin-top: 16px;
  margin-bottom: -12px;
}

.artist-main-content .discover-filter-wrapper {
  margin-top: 0;
  margin-bottom: 0px;
}

.artist-main-content .discover-filter-wrapper.is-stuck {
  background: transparent !important;
  backdrop-filter: blur(24px) !important;
  -webkit-backdrop-filter: blur(24px) !important;
  border-bottom: 0px solid var(--glass-border);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.6);
}

/* ==========================================================================
   Pinterest Masonry Grid (Inspired by Reference Design)
   ========================================================================== */
.artist-masonry-grid {
  column-count: 2;
  column-gap: 12px;
  padding-bottom: 0px;
  margin-top: -12px;
}

@media (min-width: 600px) {
  .artist-masonry-grid {
    column-count: 3;
    column-gap: 14px;
  }
}

@media (min-width: 900px) {
  .artist-masonry-grid {
    column-count: 4;
    column-gap: 16px;
  }
}

/* Masonry Pin Card */
.artist-pin-card {
  break-inside: avoid;
  margin-bottom: 12px;
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  border: none;
  outline: none;
  background: transparent;
  box-shadow: none;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1),
    box-shadow 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
  display: block;
  text-decoration: none;
  color: inherit;
  -webkit-user-select: none;
  user-select: none;
}

.artist-pin-card:hover {
  transform: translateY(-4px) scale(1.015);
  box-shadow: 0 12px 28px -4px rgba(0, 0, 0, 0.7);
}

.artist-pin-card:active {
  transform: scale(0.975);
}

/* Variable Height Ratios (Organic Pinterest rhythm) */
.artist-pin-card[data-ratio="tall"] .artist-pin-img-wrap {
  aspect-ratio: 3 / 4.4;
}

.artist-pin-card[data-ratio="standard"] .artist-pin-img-wrap {
  aspect-ratio: 3 / 3.8;
}

.artist-pin-card[data-ratio="square"] .artist-pin-img-wrap {
  aspect-ratio: 1 / 1.05;
}

.artist-pin-card[data-ratio="portrait"] .artist-pin-img-wrap {
  aspect-ratio: 3 / 4.8;
}

.artist-pin-img-wrap {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: transparent;
  border: none;
  outline: none;
  border-radius: 16px;
  -webkit-mask-image: -webkit-radial-gradient(white, black);
  mask-image: radial-gradient(white, black);
  transform: translateZ(0);
  transform-origin: center center;
}

.artist-pin-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  vertical-align: middle;
  border: none;
  outline: none;
  border-radius: 16px;
  transition: transform 0.65s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.artist-pin-card:hover .artist-pin-img {
  transform: scale(1.08);
}

/* Floating Artworks Counter Badge on Pin (Top Right) */
.artist-pin-artworks {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 4px 9px;
  border-radius: var(--radius-full);
  background: rgba(11, 15, 23, 0.68);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #ffffff;
  font-size: 12px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  z-index: 3;
  transition: all 0.25s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.artist-pin-artworks i {
  color: var(--accent-sage);
  font-size: 12px;
}

.artist-pin-card:hover .artist-pin-artworks {
  background: rgba(148, 210, 189, 0.22);
  border-color: rgba(148, 210, 189, 0.45);
  color: var(--accent-sage);
  transform: scale(1.05);
}

/* Gradient Scrim & Info Overlay */
.artist-pin-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
      rgba(11, 15, 23, 0.05) 0%,
      transparent 35%,
      rgba(11, 15, 23, 0.45) 60%,
      rgba(11, 15, 23, 0.95) 100%);
  pointer-events: none;
}

.artist-pin-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 14px 12px 12px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.artist-pin-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.25;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.85);
}

.artist-pin-loc-row {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  margin-top: -3px;
  margin-bottom: 2px;
}

.artist-pin-location {
  font-size: 11px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.78);
  display: inline-flex;
  align-items: center;
  gap: 3px;
  white-space: nowrap;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.7);
}

.artist-pin-location i {
  color: var(--accent-sage);
  font-size: 12px;
}

.artist-pin-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 2px;
}

.artist-pin-badge {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--accent-sage);
  background: rgba(148, 210, 189, 0.16);
  border: 1px solid rgba(148, 210, 189, 0.32);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  max-width: 65%;
}

.artist-pin-age {
  font-size: 11px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
  white-space: nowrap;
  flex-shrink: 0;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.7);
}

/* ==========================================================================
   Full-Screen Detail Overlay & Fluid Morph Transition
   ========================================================================== */
.artist-detail-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  z-index: 99990;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  max-width: 480px;
  margin: 0 auto;
  width: 100%;
  height: 100%;
  height: 100dvh;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.22s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.22s ease-out,
    visibility 0.22s ease;
}

.artist-detail-overlay.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Floating Morph Box for Seamless Card to Hero Transition */
.artist-morph-img-box {
  position: fixed;
  overflow: hidden;
  transform-origin: center center;
  contain: paint;
  z-index: 99999;
  will-change: top, left, width, height, border-radius, box-shadow;
  transition: top 0.22s cubic-bezier(0.16, 1, 0.3, 1),
    left 0.22s cubic-bezier(0.16, 1, 0.3, 1),
    width 0.22s cubic-bezier(0.16, 1, 0.3, 1),
    height 0.22s cubic-bezier(0.16, 1, 0.3, 1),
    border-radius 0.22s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.artist-morph-img-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Ambient Stage for Artist Detail */
.artist-detail-ambient {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 380px;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.artist-detail-ambient-canvas {
  position: absolute;
  inset: -20px;
  background-size: cover;
  background-position: center 25%;
  filter: blur(60px) saturate(1.8) brightness(0.65);
  -webkit-filter: blur(60px) saturate(1.8) brightness(0.65);
  opacity: 0.85;
}

.artist-detail-ambient-vignette {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
      rgba(11, 15, 23, 0.05) 0%,
      rgba(11, 15, 23, 0.4) 40%,
      rgba(11, 15, 23, 0.88) 75%,
      var(--bg-primary) 95%);
}

/* Scroll Container inside Detail Overlay */
.artist-detail-scroll-container {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  position: relative;
  z-index: 1;
  padding-bottom: 40px;
}

/* Floating Sticky Navigation Bar - Identical to app-header detail-header */
.artist-detail-nav,
.artist-detail-overlay .app-header.detail-header {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 50px;
  padding: 0 20px;
  margin-bottom: -50px;
  background: rgba(11, 15, 23, 0.28) !important;
  backdrop-filter: blur(20px) saturate(1.8) !important;
  -webkit-backdrop-filter: blur(20px) saturate(1.8) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
  box-sizing: border-box;
}

.artist-detail-nav .header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.artist-detail-nav .detail-nav-title,
.artist-detail-nav-title {
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--text-primary);
  max-width: 190px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  letter-spacing: -0.01em;
  display: inline-block;
  vertical-align: middle;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}

.artist-detail-nav .icon-btn {
  width: 35px;
  height: 35px;
  border-radius: var(--radius-full);
  background: var(--glass-bg-subtle);
  border: 1px solid var(--glass-border);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
  cursor: pointer;
  position: relative;
}

.artist-detail-nav .icon-btn:hover {
  background: var(--glass-bg-active);
  border-color: var(--glass-border-light);
  color: var(--accent-sage);
}

.artist-detail-nav .icon-btn i {
  font-size: 18px !important;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Detail Hero Showcase Frame */
.artist-detail-hero-stage {
  position: relative;
  margin: 0 auto;
  max-width: 480px;
  width: 100%;
  padding-bottom: 0px;
  overflow: hidden;
  transform-origin: center center;
}

.artist-detail-hero-stage::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 160px;
  background: linear-gradient(to bottom, transparent 0%, rgba(11, 15, 23, 0.5) 40%, rgba(11, 15, 23, 0.92) 80%, var(--bg-primary) 100%);
  pointer-events: none;
  z-index: 1;
}

.artist-detail-hero-img {
  width: 100%;
  aspect-ratio: 2 / 2.5;
  object-fit: cover;
  display: block;
  -webkit-mask-image: linear-gradient(to bottom, #000000 55%, rgba(0, 0, 0, 0.85) 75%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000000 55%, rgba(0, 0, 0, 0.85) 75%, transparent 100%);
}

.artist-detail-hero-badges {
  position: absolute;
  bottom: 30px;
  left: 14px;
  right: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  z-index: 2;
}

.artist-detail-hero-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  background: rgba(11, 15, 23, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(148, 210, 189, 0.4);
  color: var(--accent-sage);
}

/* Detail Floating Frosted Content Card */
.artist-detail-card {
  max-width: 540px;
  margin: 0 auto;
  padding: 0 18px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.artist-detail-header-block {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.artist-detail-name {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.15;
  margin-bottom: 4px;
  letter-spacing: -0.02em;
}

.artist-detail-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 12px;
}

.artist-detail-meta {
  font-size: var(--text-xs);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 6px;
}

.artist-detail-age {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
}

/* Stats 3 Columns (Frosted Glass Cards) */
.artist-detail-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.artist-stat-box {
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 6px 18px -4px rgba(0, 0, 0, 0.4);
  text-align: center;
  background: rgba(255, 255, 255, 0.03);
  padding: 10px 6px;
  border-radius: var(--radius-sm);
}

.artist-stat-number {
  font-size: 1.35rem;
  font-weight: 700;
  display: block;
  line-height: 1.2;
}

.artist-stat-num-art {
  color: var(--accent-sage);
}

.artist-stat-num-rented {
  color: var(--accent-gold);
}

.artist-stat-num-therapy {
  color: var(--accent-lavender);
}

.artist-stat-lbl {
  font-size: 0.65rem;
  color: var(--text-muted);
  margin-top: 4px;
  display: block;
}

/* Audio Player Box */
.artist-audio-narrator-box {
  box-shadow: 0 8px 24px -6px rgba(0, 0, 0, 0.55);
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 12px 20px;
  background: transparent;
  backdrop-filter: var(--glass-blur);
  border: 1px solid rgb(255 255 255 / 20%);
  border-radius: var(--radius-md);
  margin: 0;
}

.artist-voice-play-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #3b3d3f;
  color: #ffffff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.artist-voice-play-btn:hover {
  transform: scale(1.08);
}

.artist-voice-play-btn.playing {
  background: linear-gradient(135deg, #f4a261 0%, #e76f51 100%);
  color: #ffffff;
}

.artist-audio-text-wrap {
  flex: 1;
}

.artist-audio-title {
  font-size: 14px;
  font-weight: 600;
  color: #ffffff;
  display: block;
  margin-bottom: 2px;
}

.artist-audio-quote-preview {
  font-size: 0.76rem;
  color: var(--text-secondary);
  font-style: italic;
  line-height: 1.45;
}


/* Story & Creative Journey */
.artist-story-box {
  border: 1px solid var(--glass-border);
  padding: 18px;
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.65;
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: var(--glass-blur);
  border-radius: var(--radius-md);
}

.artist-creative-quote {
  margin-top: 14px;
  padding: 12px 14px;
  background: rgba(148, 210, 189, 0.08);
  border-left: 0;
  font-size: 0.8rem;
  border-radius: 8px;
  color: var(--text-primary);
  line-height: 1.55;
}

.artist-creative-quote strong {
  color: var(--accent-sage);
  display: block;
  margin-bottom: 2px;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ==========================================================================
   DETAIL ARTIST GALLERY SECTION (Horizontal Carousel 1:1)
   Identical layout to detailArtistGallerySection in artwork-detail
   ========================================================================== */
.artist-gallery-section {
  position: relative;
  width: 100%;
  margin-top: 4px;
  margin-bottom: 8px;
  scroll-margin-bottom: 110px;
  scroll-margin-top: 70px;
}

.artist-gallery-section .gallery-section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 12px;
}

.artist-gallery-section .gallery-sub-curated {
  font-size: var(--text-xs);
  color: var(--text-muted);
  display: block;
  margin-top: 2px;
}

.artist-gallery-section .gallery-badge-count {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--accent-sage);
}

.artist-gallery-section .new-artwork-scroll {
  display: flex;
  align-items: stretch;
  gap: 16px;
  overflow-x: auto;
  margin-left: -18px;
  margin-right: -18px;
  padding: 4px 18px 8px 18px;
  scroll-padding: 0 18px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
}

.artist-gallery-section .new-artwork-scroll::-webkit-scrollbar {
  display: none;
}

.artist-gallery-section .new-art-card {
  flex: 0 0 calc((100% - 16px) / 2.15);
  width: calc((100% - 16px) / 2.15);
  max-width: calc((100% - 16px) / 2.15);
  min-width: 0;
  scroll-snap-align: start;
}

.artist-gallery-section .new-art-card.current-viewing .new-art-media {
  border-color: var(--accent-sage);
  box-shadow: 0 0 16px rgba(148, 210, 189, 0.25);
}

.artist-gallery-section .new-art-badge.active-now {
  color: var(--accent-sage);
  border-color: rgba(148, 210, 189, 0.4);
  background: rgba(11, 15, 23, 0.85);
}