/* DJ Fatih From Istanbul - Custom Styles */

/* ===================================
   Base & Reset
   =================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

/* Selection color */
::selection {
    background: rgba(212, 175, 55, 0.3);
    color: #fff;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #0a0a0a;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #A78BFA, #C4B5FD);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #A78BFA;
}

/* ===================================
   Animations
   =================================== */
@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

@keyframes glow {
    from {
        box-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
    }

    to {
        box-shadow: 0 0 40px rgba(212, 175, 55, 0.6);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(100%);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse-ring {
    0% {
        transform: scale(0.8);
        opacity: 1;
    }

    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

@keyframes equalizer {

    0%,
    100% {
        height: 4px;
    }

    50% {
        height: 16px;
    }
}

/* ===================================
   Floating Particles
   =================================== */
.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(212, 175, 55, 0.6);
    border-radius: 50%;
    animation: float 8s ease-in-out infinite;
}

.particle-1 {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.particle-2 {
    top: 60%;
    left: 85%;
    animation-delay: 1s;
    background: rgba(0, 212, 255, 0.6);
}

.particle-3 {
    top: 80%;
    left: 25%;
    animation-delay: 2s;
}

.particle-4 {
    top: 30%;
    left: 70%;
    animation-delay: 3s;
    background: rgba(0, 212, 255, 0.6);
}

.particle-5 {
    top: 50%;
    left: 50%;
    animation-delay: 4s;
}

/* ===================================
   Navigation
   =================================== */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(5, 5, 5, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #A78BFA, #C4B5FD);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* ===================================
   Filter Buttons
   =================================== */
.filter-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
}

.filter-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.filter-btn.active {
    background: linear-gradient(135deg, #A78BFA, #C4B5FD);
    border-color: transparent;
    color: #050505;
    font-weight: 600;
}

/* ===================================
   Format Toggle Buttons
   =================================== */
.format-btn {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    transition: all 0.2s ease;
}

.format-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.format-btn.active {
    background: linear-gradient(135deg, #A78BFA, #C4B5FD);
    color: #050505;
    font-weight: 600;
    border-radius: 6px;
}

/* ===================================
   Mix List View (Spotify/YouTube Music Style)
   =================================== */
.mixes-list-container {
    display: flex;
    flex-direction: column;
    gap: 2px;
    background: rgba(26, 26, 26, 0.4);
    border-radius: 0.75rem;
    overflow: hidden;
}

.mix-list-item {
    display: grid;
    grid-template-columns: 32px 40px minmax(0, 1fr) 40px;
    align-items: center;
    gap: 20px;
    padding: 8px 12px;
    background: rgba(26, 26, 26, 0.6);
    cursor: pointer;
    transition: all 0.2s ease;
}

.mix-list-item:hover {
    background: rgba(255, 255, 255, 0.08);
}

.mix-list-item.active {
    background: rgba(212, 175, 55, 0.08);
}

/* Track Number / Play Icon */
.mix-list-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    position: relative;
}

.mix-list-number .track-number {
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
    font-weight: 500;
}

.mix-list-number .play-icon {
    display: none;
    color: #fff;
}

.mix-list-item:hover .track-number {
    display: none;
}

.mix-list-item:hover .play-icon {
    display: block;
}

.mix-list-item.playing .track-number,
.mix-list-item.playing .play-icon {
    display: none;
}

/* Artwork */
.mix-list-artwork {
    width: 48px;
    height: 48px;
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
}

.mix-list-artwork img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Track Info */
.mix-list-info {
    min-width: 0;
    flex: 1;
}

.mix-list-title {
    font-weight: 600;
    font-size: 15px;
    color: #fff;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mix-list-item.active .mix-list-title {
    color: #A78BFA;
}

.mix-list-artist {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Genre Tag */
.mix-list-genre {
    display: none;
}

.genre-tag {
    display: inline-block;
    padding: 4px 10px;
    background: rgba(212, 175, 55, 0.1);
    color: #A78BFA;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    border-radius: 20px;
    letter-spacing: 0.5px;
}

/* Duration */
.mix-list-duration {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    min-width: 50px;
    text-align: right;
}

/* External Link - hidden on mobile */
.mix-list-link {
    display: none;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.5);
    opacity: 0;
    transition: all 0.2s ease;
}

.mix-list-item:hover .mix-list-link {
    opacity: 1;
}

.mix-list-link:hover {
    color: #A78BFA;
    background: rgba(212, 175, 55, 0.1);
}

/* Equalizer animation for playing item */
.mix-list-item .equalizer {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 2px;
    height: 16px;
}

.mix-list-item .equalizer-bar {
    width: 3px;
    background: #A78BFA;
    border-radius: 2px;
    animation: equalizer 0.8s ease-in-out infinite;
}

.mix-list-item .equalizer-bar:nth-child(1) {
    animation-delay: 0s;
}

.mix-list-item .equalizer-bar:nth-child(2) {
    animation-delay: 0.2s;
}

.mix-list-item .equalizer-bar:nth-child(3) {
    animation-delay: 0.4s;
}

.mix-list-item .equalizer-bar:nth-child(4) {
    animation-delay: 0.6s;
}

/* Responsive: Desktop */
@media (min-width: 768px) {
    .mix-list-item {
        grid-template-columns: 40px 56px 1fr 100px 70px 40px;
        gap: 16px;
        padding: 12px 20px;
    }

    .mix-list-artwork {
        width: 56px;
        height: 56px;
    }

    .mix-list-title {
        font-size: 16px;
    }

    .mix-list-artist {
        font-size: 14px;
    }

    .mix-list-genre {
        display: block;
    }

    .mix-list-link {
        display: flex;
        opacity: 0;
    }
}

/* List header (optional) */
.mix-list-header {
    display: none;
    grid-template-columns: 40px 56px 1fr 100px 70px 40px;
    gap: 16px;
    padding: 8px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

@media (min-width: 768px) {
    .mix-list-header {
        display: grid;
    }
}

/* Equalizer animation */
@keyframes equalizer {

    0%,
    100% {
        height: 4px;
    }

    50% {
        height: 16px;
    }
}

/* ===================================
   Gallery
   =================================== */
.gallery-slide {
    border-radius: 1rem;
    overflow: hidden;
    cursor: pointer;
    position: relative;
}

.gallery-slide img,
.gallery-slide video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-slide:hover img,
.gallery-slide:hover video {
    transform: scale(1.05);
}

.gallery-slide .overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(5, 5, 5, 0.9) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 1.5rem;
    pointer-events: none;
}

.gallery-slide:hover .overlay {
    opacity: 1;
}

/* Swiper customization */
.swiper-pagination-custom {
    display: none;
    gap: 6px;
    justify-content: center;
    align-items: center;
    margin-top: 16px;
}

/* Show dots only on tablet and desktop */
@media (min-width: 768px) {
    .swiper-pagination-custom {
        display: flex;
    }
}

.swiper-pagination-custom .swiper-pagination-bullet {
    width: 10px;
    height: 10px;
    min-width: 10px;
    min-height: 10px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
    flex-shrink: 0;
}

.swiper-pagination-custom .swiper-pagination-bullet:hover {
    background: rgba(167, 139, 250, 0.6);
}

.swiper-pagination-custom .swiper-pagination-bullet-active {
    background: #A78BFA;
    border-color: #A78BFA;
    width: 24px;
    min-width: 24px;
    border-radius: 5px;
}

/* ===================================
   Global Player
   =================================== */
#global-player.visible {
    transform: translateY(0);
}

#progress-container {
    cursor: pointer;
}

#progress-container:hover #progress-handle {
    opacity: 1;
}

/* ===================================
   Lightbox
   =================================== */
#lightbox.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

#lightbox img {
    animation: fadeInUp 0.3s ease;
}

/* ===================================
   Form Styling
   =================================== */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
textarea:-webkit-autofill,
textarea:-webkit-autofill:hover,
textarea:-webkit-autofill:focus,
select:-webkit-autofill,
select:-webkit-autofill:hover,
select:-webkit-autofill:focus {
    -webkit-text-fill-color: #fff;
    -webkit-box-shadow: 0 0 0px 1000px #1a1a1a inset;
    transition: background-color 5000s ease-in-out 0s;
}

/* Form messages */
.form-success {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #22c55e;
}

.form-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

/* ===================================
   Mobile Optimizations
   =================================== */
@media (max-width: 768px) {
    .particle {
        display: none;
    }

    #global-player .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

/* Hide scroll indicator on short viewports */
#scroll-indicator {
    display: flex !important;
}

@media (max-height: 600px) {
    #scroll-indicator {
        display: none !important;
    }
}

@media (max-height: 500px) and (max-width: 768px) {
    #scroll-indicator {
        display: none !important;
    }
}

/* Touch-friendly spacing */
@media (hover: none) and (pointer: coarse) {
    .mix-card .play-overlay {
        opacity: 1;
        background: rgba(5, 5, 5, 0.3);
    }

    .gallery-slide .overlay {
        opacity: 1;
    }

    .filter-btn {
        padding: 0.75rem 1.5rem;
    }
}

/* ===================================
   Loading States
   =================================== */
.skeleton {
    background: linear-gradient(90deg, #1a1a1a 25%, #252525 50%, #1a1a1a 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* ===================================
   Utilities
   =================================== */
.text-gradient {
    background: linear-gradient(135deg, #A78BFA, #C4B5FD);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.border-gradient {
    border: 2px solid transparent;
    background: linear-gradient(#050505, #050505) padding-box,
        linear-gradient(135deg, #A78BFA, #C4B5FD) border-box;
}

/* Hide scrollbar but allow scrolling */
.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.no-scrollbar::-webkit-scrollbar {
    display: none;
}

/* Aspect Ratios */
.aspect-video {
    aspect-ratio: 16 / 9;
}

.aspect-square {
    aspect-ratio: 1 / 1;
}

/* ===================================
   Page Load Animation
   =================================== */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards;
}

.fade-in-up:nth-child(1) {
    animation-delay: 0.1s;
}

.fade-in-up:nth-child(2) {
    animation-delay: 0.2s;
}

.fade-in-up:nth-child(3) {
    animation-delay: 0.3s;
}

.fade-in-up:nth-child(4) {
    animation-delay: 0.4s;
}

.fade-in-up:nth-child(5) {
    animation-delay: 0.5s;
}