/* General Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #F1FAEE;
    min-height: 100vh;
    padding: 20px;
    padding-top: 100px;
}

.game-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 30px;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Header */
.game-header {
    text-align: center;
    margin-bottom: 30px;
}

.game-header h1 {
    color: #4a5568;
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.subtitle {
    color: #718096;
    font-size: 1.1rem;
}

/* Game Info Section */
.game-info {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
    padding: 20px;
    background: #f7fafc;
    border-radius: 15px;
}

.player-info, .dice-section, .players-overview {
    text-align: center;
}

.player-info h3, .players-overview h3 {
    color: #2d3748;
    margin-bottom: 10px;
}

.current-player {
    font-size: 1.5rem;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 5px;
}

.player-position {
    color: #4a5568;
}

/* Dice Section */
.dice-button {
    background: linear-gradient(145deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.dice-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.4);
}

.dice-button:active {
    transform: scale(0.98);
}

.dice-icon {
    font-size: 1.5rem;
    animation: shake 0.5s infinite;
}

@keyframes shake {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-10deg); }
    75% { transform: rotate(10deg); }
}

.dice-button:hover .dice-icon {
    animation: roll 0.5s ease;
}

@keyframes roll {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.dice-result {
    margin-top: 15px;
    font-size: 2rem;
    font-weight: bold;
    color: #4a5568;
    min-height: 50px;
}

/* Players Overview */
.players-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.player-item {
    background: white;
    padding: 8px 15px;
    border-radius: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.player-item.active {
    background: linear-gradient(145deg, #667eea, #764ba2);
    color: white;
}

/* Board Container - U-Shape */
.board-container {
    background: #edf2f7;
    padding: 30px;
    border-radius: 20px;
    margin-bottom: 30px;
    position: relative;
}

.board {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: repeat(7, 80px);
    gap: 10px;
    max-width: 1000px;
    margin: 0 auto;
}

/* Board Tile */
.board-tile {
    background: white;
    border: 3px solid #e2e8f0;
    border-radius: 15px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    font-weight: 600;
    min-height: 80px;
}

.board-tile:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

/* Tile Types */
.board-tile.start {
    background: linear-gradient(135deg, #48bb78, #38a169);
    color: white;
    border-color: #2f855a;
}

.board-tile.end {
    background: linear-gradient(135deg, #f6d55c, #ed8936);
    color: white;
    border-color: #dd6b20;
}

.board-tile.question {
    background: linear-gradient(135deg, #4299e1, #3182ce);
    color: white;
    border-color: #2c5282;
}

.board-tile.special {
    background: linear-gradient(135deg, #9f7aea, #805ad5);
    color: white;
    border-color: #6b46c1;
}

.board-tile.normal {
    background: white;
    color: #4a5568;
}

/* Tile positioning for U-shape */
.board-tile[data-position="1"] { grid-column: 1; grid-row: 7; }
.board-tile[data-position="2"] { grid-column: 1; grid-row: 6; }
.board-tile[data-position="3"] { grid-column: 1; grid-row: 5; }
.board-tile[data-position="4"] { grid-column: 1; grid-row: 4; }
.board-tile[data-position="5"] { grid-column: 1; grid-row: 3; }
.board-tile[data-position="6"] { grid-column: 1; grid-row: 2; }
.board-tile[data-position="7"] { grid-column: 1; grid-row: 1; }
.board-tile[data-position="8"] { grid-column: 2; grid-row: 1; }
.board-tile[data-position="9"] { grid-column: 3; grid-row: 1; }
.board-tile[data-position="10"] { grid-column: 4; grid-row: 1; }
.board-tile[data-position="11"] { grid-column: 5; grid-row: 1; }
.board-tile[data-position="12"] { grid-column: 6; grid-row: 1; }
.board-tile[data-position="13"] { grid-column: 7; grid-row: 1; }
.board-tile[data-position="14"] { grid-column: 8; grid-row: 1; }
.board-tile[data-position="15"] { grid-column: 9; grid-row: 1; }
.board-tile[data-position="16"] { grid-column: 9; grid-row: 2; }
.board-tile[data-position="17"] { grid-column: 9; grid-row: 3; }
.board-tile[data-position="18"] { grid-column: 9; grid-row: 4; }
.board-tile[data-position="19"] { grid-column: 9; grid-row: 5; }
.board-tile[data-position="20"] { grid-column: 9; grid-row: 6; }

.tile-number {
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.tile-badge {
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.tile-label {
    font-size: 0.75rem;
    text-align: center;
    opacity: 0.9;
}

/* Player Pieces */
.player-piece {
    position: absolute;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
    color: white;
    transition: all 0.5s ease;
    z-index: 10;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
}

.player-piece.player1 { background: #e53e3e; top: 5px; left: 5px; }
.player-piece.player2 { background: #38a169; top: 5px; right: 5px; }
.player-piece.player3 { background: #3182ce; bottom: 5px; left: 5px; }
.player-piece.player4 { background: #d69e2e; bottom: 5px; right: 5px; }

/* Action Panel */
.action-panel {
    background: #f7fafc;
    padding: 20px;
    border-radius: 15px;
    margin-bottom: 20px;
    min-height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.action-content {
    text-align: center;
    color: #2d3748;
}

.action-content h3 {
    color: #667eea;
    margin-bottom: 10px;
}

/* Buttons */
.game-controls {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.btn-primary, .btn-secondary, .btn-info {
    padding: 12px 25px;
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
}

.btn-primary {
    background: linear-gradient(145deg, #667eea, #764ba2);
    color: white;
}

.btn-secondary {
    background: #cbd5e0;
    color: #2d3748;
}

.btn-info {
    background: #4299e1;
    color: white;
}

.btn-primary:hover, .btn-secondary:hover, .btn-info:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s ease;
}

.modal.active {
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: white;
    padding: 30px;
    border-radius: 20px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.close-modal {
    position: absolute;
    right: 15px;
    top: 15px;
    font-size: 2rem;
    color: #a0aec0;
    cursor: pointer;
    transition: color 0.3s;
}

.close-modal:hover {
    color: #4a5568;
}

.modal h2 {
    color: #2d3748;
    margin-bottom: 20px;
    text-align: center;
}

.rules-content {
    line-height: 1.8;
    color: #4a5568;
}

.rules-content h3 {
    color: #667eea;
    margin-top: 20px;
    margin-bottom: 10px;
}

.rules-content ol, .rules-content ul {
    margin-left: 20px;
    margin-bottom: 15px;
}

.rules-content li {
    margin-bottom: 8px;
}

/* Question Modal */
.question-text {
    font-size: 1.3rem;
    color: #2d3748;
    margin: 20px 0;
    padding: 20px;
    background: #f7fafc;
    border-radius: 10px;
}

.question-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 20px 0;
}

.option-button {
    padding: 15px;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s;
    text-align: left;
    font-size: 1rem;
}

.option-button:hover {
    background: #edf2f7;
    border-color: #667eea;
}

.option-button.selected {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.option-button.correct {
    background: #48bb78;
    color: white;
    border-color: #38a169;
}

.option-button.incorrect {
    background: #f56565;
    color: white;
    border-color: #e53e3e;
}

.feedback {
    margin-top: 20px;
    padding: 15px;
    border-radius: 10px;
    font-size: 1.1rem;
    text-align: center;
}

.feedback.correct {
    background: #c6f6d5;
    color: #22543d;
}

.feedback.incorrect {
    background: #fed7d7;
    color: #742a2a;
}

/* Winner Modal */
.winner-content {
    text-align: center;
}

.winner-message {
    font-size: 1.5rem;
    color: #4a5568;
    margin: 20px 0;
}

.confetti-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 30px 0;
}

.confetti {
    font-size: 3rem;
    animation: bounce 1s infinite;
}

.confetti:nth-child(2) { animation-delay: 0.2s; }
.confetti:nth-child(3) { animation-delay: 0.4s; }
.confetti:nth-child(4) { animation-delay: 0.6s; }
.confetti:nth-child(5) { animation-delay: 0.8s; }

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .game-info {
        grid-template-columns: 1fr;
    }
    
    .board {
        grid-template-columns: repeat(9, 1fr);
        grid-template-rows: repeat(7, 60px);
        gap: 5px;
    }
    
    .board-tile {
        min-height: 60px;
        font-size: 0.9rem;
    }
    
    .tile-number {
        font-size: 1rem;
    }
    
    .game-header h1 {
        font-size: 2rem;
    }
}
/* Footer Styling */
.game-footer {
    margin-top: 60px;
    padding: 40px 0;
    background: white;
    border-top: 2px solid #e2e8f0;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
    padding: 0 20px;
}

.footer-text {
    color: #4a5568;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 25px;
}

.footer-image {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.student-work-img {
    width: 600px;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
}

.student-work-img:hover {
    transform: scale(1.02);
}

@media (max-width: 768px) {
    .student-work-img {
        width: 100%;
        max-width: 600px;
    }

    .footer-text {
        font-size: 14px;
    }
}

/* Navbar override - zorg dat deze bovenaan fixed staat */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    padding: 0;
}

.navbar .container {
    background: none;
    box-shadow: none;
    border-radius: 0;
    padding: 0;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
}
