* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: radial-gradient(circle at 20% 80%, rgb(160,160,210) 0%, rgb(60,60,110) 50%, rgb(25,25,45) 100%);
    background-attachment: fixed;
    min-height: 100vh;
    transition: background 0.8s ease-in-out;
}
header {
    background: rgba(0,0,0,0.0);
    color: white;
    padding: 1rem;
    text-align: center;
    backdrop-filter: blur(10px);
}

nav a {
	color: white;
	margin: 0 1rem;
	text-decoration: none;
	font-weight: 500;
	transition: color 0.3s;
	cursor: pointer;
}
nav a:hover {
	color: #ffd700;
}

main {
	padding: 2rem 0;
	min-height: calc(100vh - 140px);
	width: 100%;
	margin: 0;
}

/* ГОРИЗОНТАЛЬНЫЙ СКРОЛЛ - БОЛЬШИЕ КАРТОЧКИ */
/* СКРЫТЫЙ СКРОЛЛБАР + АВТОСКРОЛЛ ПО КРАЯМ */
.stations-grid {
	display: flex;
	overflow-x: auto;
	overflow-y: hidden;
	gap: 1.5rem;
	margin-top: 2rem;
	padding: 1rem 0;
	height: 550px;
	scroll-behavior: smooth;
	padding-bottom: 1rem;
	padding-left:2%;
	padding-right:10%;
	/* СКРЫТЫЙ СКРОЛЛБАР */
	scrollbar-width: none; /* Firefox */
	-ms-overflow-style: none; /* IE/Edge */
}
.stations-grid::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}
/* НЕВИЗИБЛЬНЫЕ ЗОНЫ АВТОСКРОЛЛА */
.stations-grid::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 10%;
    height: 100%;
    z-index: 10;
    cursor: w-resize;
}
.stations-grid::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 10%;
    height: 100%;
    z-index: 10;
    cursor: e-resize;
}
/* БОЛЬШИЕ КВАДРАТНЫЕ КАРТОЧКИ */
.station-card {
    flex: 0 0 320px;
    height: 480px;
    min-height: 400px;
    max-height: 550px;
    scroll-snap-align: start;
    background: #000;
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border: 2px solid rgba(255,255,255,0.1);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 0;
	padding-top:30px;
}
.station-art {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 0 !important;
}
.station-cover {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    filter: brightness(0.5) contrast(1.1) !important;
    transition: filter 0.4s !important;
}
.station-card:hover .station-cover {
    filter: brightness(0.9) contrast(1.0) !important;
}
.station-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(transparent 0%, rgba(0,0,0,0.8) 70%);
    z-index: 1;
    transition: opacity 0.4s;
    pointer-events: none;
}
.station-card:hover::after {
    background: linear-gradient(transparent 0%, rgba(0,0,0,0.9) 60%);
}
.station-content {
    position: relative;
    z-index: 2;
    padding: 1.5rem;
    color: white;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}
.station-card h3 {
    font-size: 1.9rem;
    margin: 0 0 0.5rem 0;
    text-shadow: 0 2px 10px rgba(0,0,0,0.9);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
	font-family: "Bitcount Grid Single", system-ui;
	font-optical-sizing: auto;
	font-weight: 400;
	font-style: normal;
	font-variation-settings:
    "slnt" 0,
    "CRSV" 0.9,
    "ELSH" 0,
    "ELXP" 0;
}
.station-track {
    margin-top: auto;
}
.track-title-small {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.2rem;
    text-shadow: 0 1px 5px rgba(0,0,0,0.9);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
}
.artist-name-small {
    font-size: 0.85rem;
    opacity: 0.9;
    text-shadow: 0 1px 5px rgba(0,0,0,0.9);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.station-card:hover:not(.active-station) {
    transform: translateY(10px) scale(1.03) !important;
    border-color: rgba(255,255,255,0.4) !important;
    box-shadow: 0 25px 50px rgba(0,0,0,0.6) !important;
}
.station-card.active-station {
    position: relative !important;
    z-index: 10 !important;
}
#player {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(0,0,0,0.35);
    backdrop-filter: blur(20px);
    box-shadow: 0 -4px 20px rgba(0,0,0,0.3);
    z-index: 1000;
    display: flex;
    align-items: center;
    padding: 1rem 2rem;
}
.player-container {
    display: flex;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    gap: 1rem;
    width: 100%;
}
.album-art {
    flex-shrink: 0;
}
#albumCover {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    object-fit: cover;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}
.track-info {
    flex: 1;
    color: white;
    min-width: 0;
}
#currentStationName {
    font-size: 0.85rem;
    opacity: 0.8;
    margin-bottom: 0.25rem;
}
.track-title {
    font-size: 1rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 0.125rem;
}
.artist-name {
    font-size: 0.9rem;
    opacity: 0.9;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}
#audioPlayer {
    display: none;
}
#stopBtn {
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s;
    color: white;
}
#stopBtn {
    background: #7c6193;
    box-shadow: 0 4px 15px rgba(143,119,163,0.4);
}
#stopBtn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(143,119,163,0.6);
}
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
/* МОБИЛЬНАЯ АДАПТАЦИЯ */
@media (max-width: 768px) {
    .player-container {
        padding: 1rem;
        flex-wrap: wrap;
    }
    #albumCover {
        width: 50px;
        height: 50px;
    }
    .track-info {
        flex: 1 1 100%;
    }
    .stations-grid {
        gap: 1rem;
        height: 280px;
        padding: 0.5rem 0;
    }
    .station-card {
        flex: 0 0 240px;
        height: 260px;
        min-height: 260px;
        max-height: 260px;
    }
    .station-card h3 {
        font-size: 1.1rem;
    }
    .track-title-small {
        font-size: 0.95rem;
    }
}
@media (max-width: 480px) {
    .station-card {
        flex: 0 0 220px;
        height: 240px;
        min-height: 240px;
        max-height: 240px;
    }
    .stations-grid {
        height: 260px;
    }
}