:root {
    --body-bg: #37474f;
    --body-text-color: #ffffff;

    --player-bg: #263238;
    --player-shadow: 0 0 20px rgba(0, 0, 0, 0.5);

    --displayname-color: #ffffff;
    --station-link-color: #ffffff;

    --play-btn-bg: #e9e9ed;
    --play-btn-border-color: #434343;
    --play-btn-border-width: 2px;

    --song-bg: #434343;
    --song-color: #ffffff;

    --card-radius: 10px;
    --input-bg: #434343;
    --input-border: #434343;
    --muted-text: rgba(255, 255, 255, 0.75);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 20px;
    min-height: 100vh;
    font-family: Arial, sans-serif;
    background: var(--body-bg);
    color: var(--body-text-color);
	cursor: default;
}

.home-shell {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
}

.hero {
    background: var(--player-bg);
    box-shadow: var(--player-shadow);
    border-radius: 14px;
    padding: 24px;
    margin-bottom: 20px;
}

.hero-top {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-bottom: 14px;
    text-align: center;
}

.hero-top i {
    font-size: 1.6rem;
    color: var(--station-link-color);
}

.hero h1 {
    margin: 0;
    font-size: 2rem;
    line-height: 1.2;
    color: var(--displayname-color);
}

.hero p {
    margin: 0 0 20px 0;
    text-align: center;
    color: var(--muted-text);
    line-height: 1.5;
}

.search-wrap {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
}

.search-row {
    display: flex;
    gap: 12px;
    align-items: stretch;
}

.search-input-wrap {
    position: relative;
    flex: 1;
}

#station-search {
    width: 100%;
    height: 48px;
    border-radius: 10px;
    border: 1px solid var(--input-border);
    background: var(--input-bg);
    color: #fff;
    padding: 0 14px;
    font-size: 16px;
    outline: none;
}

#station-search::placeholder {
    color: rgba(255, 255, 255, 0.55);
}

#search-btn {
    min-width: 140px;
    border-radius: 10px;
    border: var(--play-btn-border-width) solid var(--play-btn-border-color);
    background: var(--play-btn-bg);
    color: #000000;
    font-size: 16px;
    cursor: pointer;
    padding: 0 18px;
}

#search-btn:hover,
#load-more-btn:hover,
.station-card:hover {
    opacity: 0.95;
}

.autocomplete {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    background: #434343;
    border: 1px solid var(--input-border);
    border-radius: 10px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.25);
    z-index: 1000;
    max-height: 320px;
    overflow-y: auto;
    display: none;
}

.autocomplete-item {
    padding: 11px 14px;
    cursor: pointer;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    line-height: 1.35;
    word-break: break-word;
}

.autocomplete-item:last-child {
    border-bottom: 0;
}

.autocomplete-item:hover,
.autocomplete-item.active {
    background: rgba(255, 255, 255, 0.08);
}

.section {
    background: var(--player-bg);
    box-shadow: var(--player-shadow);
    border-radius: 14px;
    padding: 20px;
}

.section-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    margin-bottom: 18px;
}

.section-head h2 {
    margin: 0;
    font-size: 1.35rem;
}

.section-head .meta {
    color: var(--muted-text);
    font-size: 0.95rem;
    text-align: right;
}

.state-box {
    padding: 26px 16px;
    text-align: center;
    color: var(--muted-text);
    line-height: 1.5;
}

.stations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
}

.station-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: var(--song-color);
    background: var(--song-bg);
    border-radius: var(--card-radius);
    overflow: hidden;
    min-height: 220px;
    transition: transform 0.15s ease, opacity 0.15s ease;
}

.station-card:hover {
    transform: translateY(-2px);
}

.station-card-image {
    aspect-ratio: 1 / 1;
    width: 100%;
    background: #37474f;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.station-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.station-card-image .fallback-icon {
    font-size: 2.4rem;
    color: rgba(255, 255, 255, 0.55);
}

.station-card-body {
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
    justify-content: center;
}

.station-card-name {
    font-size: 1rem;
    font-weight: bold;
    line-height: 1.35;
    word-break: break-word;
    text-align: center;
}

.actions {
    display: flex;
    justify-content: center;
    margin-top: 22px;
}

#load-more-btn {
    display: none;
    border-radius: 10px;
    border: var(--play-btn-border-width) solid var(--play-btn-border-color);
    background: var(--play-btn-bg);
    color: #000000;
    font-size: 16px;
    cursor: pointer;
    padding: 12px 18px;
    min-width: 180px;
}

.home-footer {
    margin-top: 28px;
    padding: 18px 10px;
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.08);
}

.footer-note {
    margin: 0;
    font-size: 0.9rem;
    color: rgba(255,255,255,0.65);
    line-height: 1.5;
}

.hero-logo {
    width: 56px;
    height: 56px;
    object-fit: contain;
    flex-shrink: 0;
}

@media (max-width: 700px) {
    body {
        padding: 12px;
    }

    .hero,
    .section {
        padding: 16px;
    }

    .hero h1 {
        font-size: 1.55rem;
    }

    .search-row {
        flex-direction: column;
    }

    #search-btn,
    #load-more-btn {
        min-height: 46px;
        width: 100%;
    }

    .section-head {
        flex-direction: column;
        align-items: flex-start;
    }

    .section-head .meta {
        text-align: left;
    }

    .stations-grid {
        grid-template-columns: repeat(auto-fill, minmax(145px, 1fr));
        gap: 12px;
    }

    .station-card {
        min-height: 200px;
    }
}
