/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* BODY */
body {
    font-family: Arial, sans-serif;
    background-image: url('https://img.freepik.com/free-vector/white-jigsaw-puzzle-blank-background-template-vector-illustration_8130-2703.jpg?semt=ais_hybrid&w=740&q=80');
    background-size: cover;
    background-position: center;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* UKRYWANIE */
.hidden {
    display: none;
}

/* KONTENER */
.container {
    background: rgba(255, 255, 255, 0.92);
    padding: 30px;
    border-radius: 12px;
    max-width: 650px;
    width: 100%;
    text-align: center;
    box-shadow: 0 8px 30px rgba(0,0,0,0.2);
}

/* NAGŁÓWKI */
h1 {
    font-size: 22px;
    margin-bottom: 20px;
    color: #2c3e50;
    line-height: 1.3;
}

h2 {
    margin-bottom: 15px;
    color: #34495e;
}

/* SEKCJE */
.section {
    padding: 20px;
    border-radius: 10px;
    margin-top: 15px;
}

.section-start {
    background-color: #e3f2fd;
}

.section-game {
    background-color: #fff8e1;
}

.section-end {
    background-color: #e8f5e9;
}

/* TIMER */
.timer {
    font-size: 30px;
    margin: 20px 0;
    padding: 12px;
    border-radius: 8px;
    background: linear-gradient(135deg, #ffe082, #ffca28);
    color: #4e342e;
    font-weight: bold;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

/* PRZYCISKI */
.btn {
    width: 100%;
    padding: 12px;
    margin-top: 15px;
    font-size: 20px;
    border: none;
    border-radius: 8px;
    background: #007bff;
    color: white;
    cursor: pointer;
    transition: background 0.2s ease;
}

.btn:hover {
    background: #0056b3;
}

.btn-end {
    background: #dc3545;
}

.btn-end:hover {
    background: #b52a37;
}

.btn-restart {
    background: #28a745;
}

.btn-restart:hover {
    background: #1e7e34;
}

#submitBtn:disabled {
    background: #cccccc;
    cursor: not-allowed;
}

/* STOLIKI */
.table-buttons {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
    margin-top: 15px;
}

.table-buttons button {
    padding: 10px;
    border-radius: 6px;
    font-size: 20px;
    background: #007bff;
    color: white;
    border: none;
    cursor: pointer;
}

.table-buttons button.clicked {
    background: #f39c12;
}

/* STATUS PUZZLA */
#currentPuzzleStatus {
    margin-top: 15px;
    padding: 12px;
    background-color: #f1f8e9;
    border-left: 5px solid #7cb342;
    border-radius: 6px;
}

/* RESPONSYWNOŚĆ */
@media (max-width: 480px) {
    .table-buttons {
        grid-template-columns: repeat(3, 1fr);
    }
}
