* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Segoe UI", Arial, sans-serif;
    color: rgb(31, 41, 55);
    min-height: 100vh;
    background: linear-gradient(171deg, rgba(42, 93, 155, 1) 0%, rgba(0, 212, 255, 1) 93%, rgba(42, 123, 155, 1) 100%);
}

header {
    padding: 24px 32px;
    color: white;
    background: rgba(0, 0, 0, 0.35);
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.6);
}

.ranking-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    padding: 32px;
    justify-content: center;
}

.phone-card {
    background: linear-gradient(145deg, #ffffff, #e5e7eb);
    border-radius: 20px;
    padding: 24px;
    width: 300px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.phone-card:hover {
    transform: translateY(-8px) scale(1.03);
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.35);
}

.phone-card img {
    width: 100%;
    border-radius: 12px;
    margin-bottom: 12px;
}

.phone-card .score {
    display: inline-block;
    margin-top: 12px;
    padding: 6px 12px;
    background: rgb(34, 197, 94);
    color: white;
    border-radius: 999px;
}

footer {
    padding: 24px;
    text-align: center;
    color: white;
    background: rgba(0, 0, 0, 0.4);
}

/* MODAL */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.modal-content {
    background: white;
    padding: 20px;
    width: 400px;
    border-radius: 10px;
    text-align: center;
    animation: popIn 0.3s ease;
}

.modal-img {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 15px;
}

.close-btn {
    float: right;
    cursor: pointer;
    font-size: 20px;
    font-weight: bold;
}

.hidden {
    display: none;
}

@keyframes popIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}
/* FADE IN / FADE OUT */
.modal.fade-in {
    animation: fadeIn 0.3s forwards;
}

.modal.fade-out {
    animation: fadeOut 0.3s forwards;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}
.corner-logo {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 80px;       /* <<< ZMIENIASZ ROZMIAR LOGO */
    height: auto;
    z-index: 100000;   /* zawsze na wierzchu */
    opacity: 0.9;
    transition: opacity 0.2s ease;
}

.corner-logo:hover {
    opacity: 1;
}
