body.page-lottery {
    --bg-start: #120c24;
    --bg-end: #090f25;
    --accent: #00d9ff;
    --accent-soft: rgba(0, 217, 255, 0.2);
}

body.page-lottery main .up {
    max-width: 1100px;
    margin: 0 auto;
    width: 100%;
}

.hero {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 1.5rem;
    align-items: flex-end;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.hero-actions .secondary {
    padding: 0.85rem 1.6rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 999px;
    font-weight: 600;
    color: white;
}

.ghost-link {
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.95rem;
}

.lottery-panel {
    margin-top: 2.5rem;
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.2fr);
    gap: 1.5rem;
}

.result-card,
.control-panel .control-card,
.history-list li,
.reco-card {
    background: rgba(17, 22, 40, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 28px;
    padding: 1.75rem;
    box-shadow: 0 20px 45px rgba(2, 6, 23, 0.45);
}

.result-card {
    min-height: 320px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.result-label {
    font-size: 0.78rem;
    letter-spacing: 0.4em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.65);
}

#resultName {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    margin: 0;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.tag {
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    font-size: 0.85rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.result-meta {
    margin-top: auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.result-meta span {
    font-size: 0.78rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.6);
}

.result-meta p {
    margin: 0.25rem 0 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.filter-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.filter-btn {
    padding: 0.55rem 1.15rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: transparent;
    color: white;
    font-weight: 500;
    cursor: pointer;
}

.filter-btn.active {
    background: var(--accent-soft);
    color: var(--accent);
    border-color: rgba(0, 217, 255, 0.6);
    box-shadow: 0 10px 25px rgba(0, 217, 255, 0.25);
}

.control-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.draw-btn {
    padding: 1rem 1.5rem;
    border-radius: 20px;
    font-size: 1rem;
    font-weight: 600;
    color: #08121f;
    background: linear-gradient(90deg, #00d9ff, #ff10f0);
    border: none;
    cursor: pointer;
    box-shadow: 0 20px 35px rgba(0, 217, 255, 0.35);
}

.hint {
    font-size: 0.92rem;
    color: rgba(255, 255, 255, 0.7);
}

.history {
    margin-top: 3rem;
}

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
}

.history-list {
    margin-top: 1.5rem;
    list-style: none;
    padding: 0;
    display: grid;
    gap: 1rem;
}

.history-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.history-list .title {
    font-weight: 600;
    font-size: 1rem;
}

.history-list .meta {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    display: flex;
    gap: 1.5rem;
}

.history-list .empty {
    justify-content: center;
    text-align: center;
    flex-direction: column;
    padding: 2rem;
    color: rgba(255, 255, 255, 0.6);
}

.recommendations {
    margin-top: 3rem;
}

.reco-grid {
    margin-top: 1.5rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.reco-card {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.reco-card h4 {
    margin: 0;
    font-size: 1.05rem;
}

.reco-card .tag-row {
    gap: 0.4rem;
}

.reco-card small {
    color: rgba(255, 255, 255, 0.6);
}

@media (max-width: 960px) {
    .lottery-panel {
        grid-template-columns: 1fr;
    }

    .result-card,
    .control-panel .control-card {
        padding: 1.5rem;
    }

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

    .hero-actions {
        width: 100%;
        justify-content: space-between;
    }
}

@media (max-width: 600px) {
    .result-meta {
        grid-template-columns: 1fr;
    }

    .history-list li {
        flex-direction: column;
        align-items: flex-start;
    }

    .hero-actions {
        flex-direction: column;
        align-items: flex-start;
    }

    .hero-actions .secondary {
        width: 100%;
        text-align: center;
    }
}
