body {
    margin: 0;
    background: #0f172a;
    color: #e2e8f0;
    font-family: system-ui;
}

.header {
    padding: 20px 40px;
    font-size: 28px;
    font-weight: bold;
    background: #020617;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

/* Tabela */
#statisticsList{
    display:flex;
    flex-wrap:wrap;
    gap:20px;
}
#similarityChart {
    width: 60%;
    max-width: 60%;
    height: auto;
    aspect-ratio: 4 / 3;
}
#aboutMeSection canvas {
    background: #021617;
    border-radius: 10px;
}
/* GRID NA KARTY */
#statsCards{
    width:80%;
    margin-left: 10%;
    display:grid;
    grid-template-columns: 1fr 1fr;
    gap:20px;
}

/* karta */
.stat-card{
    background:#1e293b;
    padding:15px;
    border-radius:10px;
    text-align:center;
}
.stat-name{
    color: palegoldenrod;
}
/* tabele */
#statisticsList > div:not(#statsCards){
    flex:1;
    min-width:300px;
}
#statisticsList table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 auto;
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 0.5rem;
    overflow: hidden;
}

#statisticsList thead {
    background-color: rgba(255, 255, 255, 0.15);
}

#statisticsList th, td {
    padding: 0.75rem 1rem;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

#statisticsList th {
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

#statisticsList tbody tr:nth-child(even) {
    background-color: rgba(255, 255, 255, 0.05);
}

#statisticsList tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transition: background 0.2s;
}

.subtitle {
    margin-bottom: 10px;
    margin-top: 8px;
    margin-left: 20px;
    color: yellowgreen;
}

.subtitle > .active {
    color: darkgoldenrod;
}

.subtitle > span:hover {
    color: goldenrod;
}

.filmweb {
    margin-left: 10px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 14px;
}

.add-card {
    display: flex;
    flex-direction: column;
    padding: 0;
}

.vote-actions {
    display: flex;
    justify-content: space-around;
    margin-top: 0;
}

.vote-btn {
    font-size: 26px;
    padding: 16px 16px;
    border: none;
    cursor: pointer;
}

.vote-btn.no {
    background: #ef4444;
    border-bottom-left-radius: 10%;
    border-top-left-radius: 10%;
}

.vote-btn.seen {
    background: #64748b;
}

.vote-btn.want {
    background: #22c55e;
    border-bottom-right-radius: 10%;
    border-top-right-radius: 10%;
}

#userIcon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.userIcon.small {
    width: 22px;
    height: 22px;
    border-radius: 45%;
    object-fit: cover;
    margin-right: 5px;
}

.add-half {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    cursor: pointer;
}

.add-half:first-child {
    border-bottom: 1px solid #334155;
}

.add-half:last-child {
    border-top: 1px solid #334155;
}

.add-half:hover {
    background: #020617;
}

.add-icon {
    font-size: 34px;
    margin-bottom: 6px;
    color: #facc15;
}

.filmweb-icon {
    width: 16px;
    height: 16px;
    object-fit: contain;
}

.logo {
    color: #facc15;
}

main {
    padding: 30px;
}

h2 {
    margin-bottom: 15px;
}

.movie-section {
    margin-top: 15px;
}

.carousel-wrapper {
    position: relative;
}

.carousel {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 10px 50px; /* miejsce na strzałki */
}

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

.movie-card {
    min-width: 180px;
    background: #1e293b;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    transition: transform .25s;
    flex-shrink: 0;
}

.movie-card:hover {
    transform: scale(1.08);
}

.poster {
    width: 100%;
    height: 300px;
    object-fit: cover;
}

.movie-info {
    padding: 10px;
}

.rating {
    color: #facc15;
}


/* modal */

.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: #1e293b;
    padding: 30px;
    border-radius: 10px;
    width: 300px;
}

#proposalModal.modal-content {
    width: 500px;
}

.stars {
    font-size: 30px;
    color: #facc15;
    margin: 15px 0;
}

.stars span {
    cursor: pointer;
}

textarea {
    width: 100%;
    height: 70px;
    margin-top: 10px;
    background: #020617;
    border: none;
    color: white;
    padding: 8px;
}

button {
    margin-top: 15px;
    width: 100%;
    padding: 10px;
    background: #facc15;
    border: none;
    font-weight: bold;
    cursor: pointer;
}

/* blur strony */

.blur {
    filter: blur(6px);
    pointer-events: none;
}

/* login overlay */

.login-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.login-box {
    background: #1e293b;
    padding: 40px;
    border-radius: 12px;
    text-align: center;
    width: 300px;
}

.login-box h2 {
    margin-bottom: 20px;
    color: #facc15;
}

.login-box input {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: none;
    background: #020617;
    color: white;
}

.user-panel {
    display: flex;
    align-items: center;
    gap: 10px;
}

#logoutBtn {
    padding: 6px 10px;
    font-size: 12px;
    background: #1e293b;
    color: #e2e8f0;
    border: 1px solid #334155;
    cursor: pointer;
}

#logoutBtn:hover {
    background: #334155;
}

.scoreBtn {
    padding: 6px 10px;
    font-size: 12px;
    background: #1e293b;
    color: #e2e8f0;
    border: 1px solid #334155;
    cursor: pointer;
}

.scoreBtn:hover {
    background: #334155;
}

.potato {
    font-size: 22px;
    cursor: pointer;
    display: inline-block;
    position: relative;
    opacity: 0.25;
}

.potato.full {
    opacity: 1;
    transform: scale(1.4);
}

.potato.half {
    opacity: 0.55;
    transform: scale(1.2);
}

.potato:hover {
    transform: scale(1.6);
}

.rating {
    color: #facc15;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
}

.rating-slider {
    margin-top: 15px;
    text-align: center;
}

#ratingSlider {
    width: 100%;
}

.potato-area {
    height: 120px; /* miejsce na największego kartofla */
    display: flex;
    align-items: center;
    justify-content: center;
}

#potatoWrapper {
    transition: transform 0.2s;
}

#ratingValue {
    margin-top: 5px;
    font-weight: bold;
}

.scroll-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(2, 6, 23, 0.85);
    border: none;
    color: white;
    font-size: 30px;
    width: 44px;
    height: 64px;
    cursor: pointer;
    opacity: .9;
    z-index: 10;
    border-radius: 6px;
}

.left {
    left: 0;
}

.right {
    right: 0;
}

.scroll-btn:hover {
    opacity: 1;
}

@media (max-width: 600px) {

    .header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding: 20px;
        font-size: 24px;
    }
    #statisticsList{
        flex-direction:column;
    }

    #statisticsList div{
        width:100%;
    }

    #statsCards{
        grid-template-columns: 1fr;
    }
    .logo {
        font-size: 28px;
    }

    .user-panel {
        width: 100%;
        justify-content: space-between;
    }

    main {
        padding: 15px;
    }

    .movie-card {
        min-width: 220px;
    }

    .poster {
        height: 325px;
    }

    .movie-info {
        font-size: 18px;
    }

    .rating {
        font-size: 20px;
    }

    .scroll-btn {
        display: none;
    }

    .modal-content {
        width: 90%;
        padding: 25px;
    }

    textarea {
        height: 100px;
        font-size: 16px;
    }

    button {
        font-size: 18px;
        padding: 14px;
    }

    #potatoPreview {
        font-size: 60px;
    }

    #ratingSlider {
        height: 35px;
    }

    .carousel {
        padding: 10px 20px; /* miejsce na strzałki */
    }
    #similarityChart {
    width: 100%;
    max-width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
}
}

.vote-card {
    width: 260px;
    margin: auto;
    text-align: center;
    cursor: grab;
    user-select: none;
}

.vote-card img {
    width: 100%;
    border-radius: 12px;
}