body {
    font-family: Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    background-color: #fde4e4; /* Original Doğa Color: #fde4e4 */
}

.game-container {
    background-color: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(0,0,0,0.2);
    width: 90%;
    max-width: 1000px;
    margin: 20px auto;
}

.input-group {
    margin: 1rem 0;
}

.input-group label {
    display: block;
    margin-bottom: 0.5rem;
}

.input-group input {
    padding: 0.5rem;
    width: 200px;
}

button {
    padding: 0.5rem 1rem;
    margin: 0.5rem;
    cursor: pointer;
}

#game-board {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 15px;
    margin: 2rem 0;
    position: relative;
    padding: 30px;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

.cell {
    width: 100%;
    aspect-ratio: 1;  /* Keep cells square */
    max-width: 100px;
    max-height: 100px;
    border: 3px solid #ccc;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    background-color: #fff;
    box-shadow: 4px 4px 0 rgba(0,0,0,0.2);
    color: #333;
    font-size: clamp(16px, 4vw, 28px);  /* Responsive font size */
    font-weight: bold;
    text-shadow: none;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.cell:nth-child(even) {
    background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
}

.cell.katz::after {
    content: '';
    position: absolute;
    width: 85px;
    height: 85px;
    background-image: url('cat.png');
    background-size: contain;
    background-repeat: no-repeat;
    z-index: 1;
    filter: drop-shadow(2px 2px 2px rgba(0,0,0,0.5));
}

.cell.maus::after {
    content: '';
    position: absolute;
    width: 75px;
    height: 75px;
    background-image: url('mouse.png');
    background-size: contain;
    background-repeat: no-repeat;
    z-index: 1;
    filter: drop-shadow(2px 2px 2px rgba(0,0,0,0.5));
}

@keyframes bounce {
    from { transform: translateY(0); }
    to { transform: translateY(-5px) rotate(5deg); }
}

@keyframes wiggle {
    from { transform: rotate(-5deg); }
    to { transform: rotate(5deg); }
}

#player-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 18px;
    align-items: center;
    padding: 0 20px;
}

#message {
    margin-top: 1rem;
    text-align: center;
    font-weight: bold;
    min-height: 24px;
}

#dice-display {
    text-align: center;
    margin: 1rem 0;
    min-height: 80px;
}

#dice-value {
    font-size: 24px;
    font-weight: bold;
    color: #333;
    margin-bottom: 0.5rem;
}

#current-turn {
    color: #666;
    font-style: italic;
    min-height: 24px;
    margin: 8px 0;
}

@keyframes diceRoll {
    0% { transform: rotate(0deg); }
    25% { transform: rotate(90deg); }
    50% { transform: rotate(180deg); }
    75% { transform: rotate(270deg); }
    100% { transform: rotate(360deg); }
}

.rolling {
    animation: diceRoll 0.5s ease-in-out;
    display: inline-block;
}

.cheese-target {
    background-image: url('cheese.png');
    background-size: 85%;
    background-repeat: no-repeat;
    background-position: center;
    color: transparent;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.cheese-target:hover {
    transform: scale(1.05);
}

@keyframes wrongMove {
    0%, 100% { 
        box-shadow: none;
        transform: scale(1);
    }
    50% { 
        box-shadow: 0 0 20px red;
        transform: scale(1.1);
        background-color: rgba(255, 0, 0, 0.3);
    }
}

@keyframes correctMove {
    0%, 100% { 
        box-shadow: none;
        transform: scale(1);
    }
    50% { 
        box-shadow: 0 0 20px green;
        transform: scale(1.1);
        background-color: rgba(0, 255, 0, 0.3);
    }
}

.cell.wrong-move {
    animation: wrongMove 0.5s ease;
}

.cell.correct-move {
    animation: correctMove 0.5s ease;
}

.cell.clickable {
    cursor: pointer;
    position: relative;
}

.cell.clickable::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.2);
    display: none;
}

.cell.clickable:hover::before {
    display: block;
}

/* Add styles for character selection */
.character-select {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 1rem;
}

.character-icon {
    width: 40px;
    height: 40px;
    background-size: contain;
    background-repeat: no-repeat;
    margin-right: 10px;
}

/* Add styles for selected piece */
.cell.selected {
    border: 2px solid #ffd700;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.cell.katz, .cell.maus {
    cursor: pointer;
}

.cell.katz:hover, .cell.maus:hover {
    transform: scale(1.05);
    transition: transform 0.2s ease;
}

.cell.selected {
    transform: scale(1.1);
    transition: transform 0.2s ease;
}

.game-over-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background-color: white;
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.big-cheese {
    width: 150px;
    height: 150px;
    background-image: url('cheese.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.big-cat {
    width: 150px;
    height: 150px;
    background-image: url('cat.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.button-container {
    display: flex;
    gap: 1rem;
}

.math-display {
    text-align: center;
    font-size: 24px;
    font-weight: bold;
    margin-top: 1rem;
    color: #333;
    min-height: 36px;
}

.cell:hover {
    transform: translateY(-2px);
    box-shadow: 6px 6px 0 rgba(0,0,0,0.2);
}

.player-icon {
    width: 30px;
    height: 30px;
    vertical-align: middle;
    margin-right: 8px;
}

.turn-indicator {
    width: 25px;
    height: 25px;
    display: inline-block;
    margin-right: 8px;
}

.turn-indicator img {
    width: 100%;
    height: 100%;
    vertical-align: middle;
}

#katz-info, #maus-info {
    display: flex;
    align-items: center;
    min-width: 150px;
    position: relative;
}

@keyframes bounce {
    from { transform: translateY(0); }
    to { transform: translateY(-5px) rotate(5deg); }
}

/* Add styles for player name containers */
#katz-info, #maus-info {
    display: flex;
    align-items: center;
    min-width: 150px;  /* Ensure consistent width */
}

/* Update signature styles */
.signature {
    position: fixed;
    bottom: 15px;
    right: 15px;
    font-family: 'Brush Script MT', cursive;
    font-size: 24px;  /* Increased size */
    color: #746f6f;      /* Darker color */
    opacity: 0.9;     /* More visible */
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);  /* Add subtle shadow */
}

/* Improve mobile responsiveness */
@media (max-width: 844px) {
    body {
        padding: 5px;
        min-height: -webkit-fill-available; /* Fix for iOS */
    }

    .game-container {
        padding: 0.5rem;
        width: 100%;
        margin: 0;
        max-width: none;
    }

    #game-board {
        gap: 5px;
        padding: 5px;
        grid-template-columns: repeat(5, 1fr); /* 5 columns for better fit */
        max-width: none;
        margin: 1rem auto;
    }

    .cell {
        max-width: none;
        width: 100%;
        aspect-ratio: 1;
        border-width: 2px;
        font-size: 14px;
        border-radius: 6px;
    }

    .cell.katz::after,
    .cell.maus::after,
    .cheese-target {
        width: 70%;
        height: 70%;
        background-size: contain;
    }

    #player-info {
        flex-direction: row; /* Keep horizontal on mobile */
        justify-content: space-between;
        padding: 0 5px;
        font-size: 14px;
        margin-bottom: 0.5rem;
    }

    #katz-info, #maus-info {
        min-width: auto;
        gap: 5px;
    }

    .player-icon {
        width: 20px;
        height: 20px;
        margin-right: 4px;
    }

    .turn-indicator {
        width: 18px;
        height: 18px;
        margin-right: 4px;
    }

    .math-display {
        font-size: 16px;
        margin-top: 0.5rem;
        min-height: 24px;
    }

    #dice-display {
        min-height: 50px;
        margin: 0.5rem 0;
    }

    #dice-value {
        font-size: 18px;
    }

    #current-turn {
        font-size: 12px;
        min-height: 18px;
    }

    #message {
        font-size: 14px;
        min-height: 18px;
        margin-top: 0.5rem;
    }

    button {
        padding: 0.3rem 0.8rem;
        font-size: 14px;
    }

    .signature {
        font-size: 18px;
        bottom: 5px;
        right: 5px;
    }
}

/* iPhone specific adjustments */
@media (max-width: 390px) {
    #game-board {
        grid-template-columns: repeat(4, 1fr); /* 4 columns for smaller screens */
    }

    .cell {
        font-size: 12px;
    }

    .character-select {
        flex-direction: column;
        align-items: center;
    }

    .input-group {
        width: 100%;
        text-align: center;
    }

    .input-group input {
        width: 80%;
        max-width: 180px;
    }

    .modal-content {
        width: 90%;
        padding: 1rem;
    }

    .big-cheese,
    .big-cat {
        width: 80px;
        height: 80px;
    }
}

/* Landscape mode adjustments */
@media (orientation: landscape) and (max-height: 844px) {
    .game-container {
        margin: 0 auto;
        padding: 5px;
    }

    #game-board {
        margin: 0.5rem 0;
        grid-template-columns: repeat(7, 1fr);
        gap: 3px;
    }

    .cell {
        font-size: 12px;
    }

    #player-info {
        margin-bottom: 0.3rem;
    }

    .math-display,
    #dice-display,
    #message {
        margin: 0.3rem 0;
    }
}

/* Add orientation specific styles */
@media (orientation: landscape) and (max-height: 600px) {
    .game-container {
        margin: 5px auto;
    }

    #game-board {
        margin: 1rem 0;
    }

    .cell {
        aspect-ratio: 1;
    }
} 
