/* Japanese-inspired fonts */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;500;700&family=Yuji+Syuku&display=swap');

:root {
    --ninja-red: #8B0000;
    --ninja-dark: #1a1a1a;
    --ninja-gold: #D4AF37;
    --ninja-light: #2a2a2a;
    --ninja-border: #444;
    --text-light: #f0f0f0;
    --text-muted: #aaa;
}

body {
    font-family: 'Noto Sans JP', sans-serif;
    background: linear-gradient(135deg, var(--ninja-dark) 0%, #2a1a1a 100%);
    color: var(--text-light);
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    text-align: center;
}

h1 {
    font-family: 'Yuji Syuku', serif;
    color: var(--ninja-gold);
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
    margin-bottom: 30px;
    font-size: 2.5em;
}

/* Improved spacing and layout */
.controls-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
}

.controls-container label {
    font-size: 1.3em;
    color: var(--text-light);
    margin-bottom: 10px;
}

#difficulty, #simulatorDifficulty {
    font-size: 1.1em;
    padding: 12px 20px;
    background: var(--ninja-light);
    color: var(--text-light);
    border: 2px solid var(--ninja-gold);
    border-radius: 8px;
    appearance: none;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

#difficulty:hover, #simulatorDifficulty:hover {
    background: #333;
    border-color: #e6c158;
}

.begin-btn {
    animation: pulse 2s infinite ease-in-out;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Instructions Styles */
.instructions {
    background: var(--ninja-light);
    padding: 25px;
    border-radius: 12px;
    border: 2px solid var(--ninja-gold);
    margin: 25px auto;
    max-width: 800px;
    text-align: left;
}

.instructions h3 {
    color: var(--ninja-gold);
    font-family: 'Yuji Syuku', serif;
    text-align: center;
    margin-bottom: 20px;
    font-size: 1.4em;
}

.instruction-steps {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.instruction-step {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 15px;
    background: var(--ninja-dark);
    border-radius: 8px;
    border: 1px solid var(--ninja-border);
}

.step-number {
    background: var(--ninja-red);
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    flex-shrink: 0;
    font-size: 0.9em;
}

.instruction-step p {
    margin: 0;
    color: var(--text-light);
    line-height: 1.5;
}

.instruction-step ul {
    margin: 10px 0 0 0;
    padding-left: 20px;
    color: var(--text-light);
}

.instruction-step li {
    margin-bottom: 8px;
    line-height: 1.4;
    display: flex;
    align-items: center;
    gap: 8px;
}

.instruction-step strong {
    color: var(--ninja-gold);
}

/* Progress Indicator */
.progress-indicator {
    background: var(--ninja-light);
    padding: 15px;
    border-radius: 10px;
    border: 1px solid var(--ninja-border);
    margin: 20px auto;
    max-width: 400px;
    transition: all 0.3s ease;
}

.progress-text {
    font-size: 1em;
    color: var(--text-light);
    margin-bottom: 10px;
    font-weight: 500;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #333;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--ninja-red), var(--ninja-gold));
    transition: width 0.5s ease;
    width: 100%;
}

.performance-info {
    font-size: 0.9em;
    color: var(--text-muted);
    margin-top: 8px;
}

/* Number Input with +/- Buttons */
.number-input-group {
    display: flex;
    align-items: center;
    gap: 5px;
}

.number-btn {
    width: 40px;
    height: 40px;
    background: var(--ninja-dark);
    border: 2px solid var(--ninja-border);
    border-radius: 8px;
    color: var(--text-light);
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.number-btn:hover {
    background: var(--ninja-gold);
    border-color: var(--ninja-gold);
    color: var(--ninja-dark);
    transform: scale(1.1);
}

.number-btn:active {
    transform: scale(0.95);
}

.plus-btn:hover {
    background: #1d8324;
    border-color: #1d8324;
    color: white;
}

.minus-btn:hover {
    background: var(--ninja-red);
    border-color: var(--ninja-red);
    color: white;
}

/* Adjust input width to fit with buttons */
.feedback-group input[type="number"] {
    width: 60px;
    margin: 0;
}

/* Improved guess box with animation */
.guess-box {
    font-size: 1.3em;
    margin: 25px 0;
    background: var(--ninja-light);
    padding: 20px;
    border-radius: 12px;
    border: 2px solid var(--ninja-border);
    display: inline-block;
    transition: all 0.3s ease;
    animation: slideIn 0.5s ease;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Rune animations */
.rune-animate {
    animation: runeFloat 0.6s ease;
}

@keyframes runeFloat {
    0% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-10px) scale(1.1); }
    100% { transform: translateY(0) scale(1); }
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--ninja-gold);
    border-radius: 50%;
    pointer-events: none;
    animation: particleFloat 1s ease-out forwards;
}

@keyframes particleFloat {
    0% { transform: translate(0, 0); opacity: 1; }
    100% { transform: translate(var(--tx), var(--ty)); opacity: 0; }
}

/* Improved feedback section */
.feedback-section {
    margin: 25px 0;
}

.feedback-controls {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.feedback-group {
    display: flex;
    align-items: center;
    gap: 15px;
    background: var(--ninja-light);
    padding: 15px;
    border-radius: 10px;
    border: 1px solid var(--ninja-border);
    transition: all 0.3s ease;
}

.feedback-group:hover {
    border-color: var(--ninja-gold);
}

.feedback-group label {
    color: var(--text-light);
    font-size: 1.1em;
    font-weight: 500;
    white-space: nowrap;
}

/* Improved action buttons */
.action-buttons {
    display: flex;
    gap: 20px;
    margin: 25px 0;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.undo-btn, .next-btn, .redo-btn {
    transition: all 0.3s ease;
    min-width: 140px;
    min-height: 80px;
}

.undo-btn:disabled, .redo-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    filter: grayscale(100%);
}

.undo-btn:not(:disabled):hover, .redo-btn:not(:disabled):hover {
    transform: translateY(-2px);
    filter: brightness(1.2);
}

.next-btn {
    animation: pulse 2s infinite ease-in-out;
}

/* Button-specific styles */
.undo-btn .image-wrapper img {
    border: 2px solid #efac28;
    border-radius: 12px;
    min-width: 140px;
    min-height: 80px;
}

.redo-btn .image-wrapper img {
    border: 2px solid #ff6b6b;
    border-radius: 12px;
    min-width: 140px;
    min-height: 80px;
}

.next-btn .image-wrapper img {
    border: 2px solid #1d8324;
    border-radius: 12px;
    min-width: 140px;
    min-height: 80px;
}

/* Smaller text for Undo/Redo */
.undo-btn .centered-text,
.redo-btn .centered-text {
    font-size: 16px;
    font-weight: 600;
}

.next-btn .centered-text {
    font-size: 18px;
    font-weight: bold;
}

/* Larger touch targets for mobile */
@media (max-width: 768px) {
    .action-buttons {
        gap: 15px;
    }
    
    .undo-btn, .next-btn, .redo-btn {
        min-width: 120px;
        min-height: 70px;
        margin: 8px;
    }
    
    .undo-btn .image-wrapper img,
    .redo-btn .image-wrapper img,
    .next-btn .image-wrapper img {
        min-width: 120px;
        min-height: 70px;
    }
    
    /* Number input mobile optimization */
    .number-input-group {
        gap: 8px;
    }
    
    .number-btn {
        width: 44px;
        height: 44px;
        font-size: 20px;
    }
    
    .feedback-group input[type="number"] {
        width: 70px;
        font-size: 18px;
        padding: 12px;
    }
    
    .feedback-group {
        padding: 20px;
        gap: 15px;
    }
    
    /* Even larger for very small screens */
    @media (max-width: 480px) {
        .undo-btn, .next-btn, .redo-btn {
            min-width: 110px;
            min-height: 65px;
            margin: 6px;
        }
        
        .undo-btn .image-wrapper img,
        .redo-btn .image-wrapper img,
        .next-btn .image-wrapper img {
            min-width: 110px;
            min-height: 65px;
        }
        
        .undo-btn .centered-text,
        .redo-btn .centered-text {
            font-size: 15px;
        }
        
        .next-btn .centered-text {
            font-size: 16px;
        }
        
        .number-btn {
            width: 42px;
            height: 42px;
        }
        
        .feedback-group input[type="number"] {
            width: 65px;
            padding: 10px;
        }
        
        .feedback-group {
            flex-direction: column;
            gap: 12px;
        }
        
        .number-input-group {
            order: 2;
        }
        
        .feedback-group label {
            order: 1;
            margin-bottom: 5px;
        }
        
        .feedback-group .green-circle,
        .feedback-group .yellow-circle {
            order: 0;
        }
    }
}

/* Make all interactive elements larger on mobile */
@media (max-width: 768px) {
    #difficulty, #simulatorDifficulty {
        padding: 15px 25px;
        font-size: 1.2em;
        min-height: 60px;
    }
    
    .begin-btn {
        min-width: 140px;
        min-height: 80px;
    }
    
    .begin-btn .image-wrapper img {
        min-width: 140px;
        min-height: 80px;
    }
    
    .action-btn {
        padding: 8px 12px;
        min-width: 44px;
        min-height: 44px;
    }
}

/* Extra large touch targets for accessibility */
@media (max-width: 480px) {
    #difficulty, #simulatorDifficulty {
        padding: 18px 30px;
        min-height: 70px;
    }
    
    .begin-btn {
        min-width: 150px;
        min-height: 85px;
    }
    
    .begin-btn .image-wrapper img {
        min-width: 150px;
        min-height: 85px;
    }
}

/* Improved table with animations */
table {
    border-collapse: collapse;
    margin: 25px auto;
    background-color: var(--ninja-light);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
}

th, td {
    border: 1px solid var(--ninja-border);
    padding: 12px 20px;
    transition: all 0.3s ease;
}

th {
    background: linear-gradient(135deg, var(--ninja-red), #6a0000);
    color: var(--text-light);
    font-weight: 600;
    font-size: 1.1em;
}

.action-column {
    width: 120px;
}

/* Action buttons in history table */
.action-btn {
    background: var(--ninja-light);
    border: 1px solid var(--ninja-border);
    border-radius: 6px;
    padding: 5px 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.action-btn:hover {
    background: var(--ninja-gold);
    border-color: var(--ninja-gold);
    transform: scale(1.1);
}

.action-btn:active {
    transform: scale(0.95);
}

/* Ninja Message Styles */
#ninjaMessage {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(26, 26, 26, 0.95);
    padding: 25px;
    border-radius: 15px;
    border: 3px solid var(--ninja-red);
    z-index: 1000;
    box-shadow: 0 0 30px rgba(139, 0, 0, 0.5);
    font-family: 'Noto Sans JP', sans-serif;
    min-width: 450px;
    animation: modalAppear 0.5s ease;
}

@keyframes modalAppear {
    from { opacity: 0; transform: translate(-50%, -50%) scale(0.8); }
    to { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}

.ninja-container {
    display: flex;
    align-items: flex-start;
    gap: 25px;
}

.ninja-character {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

#ninjaMessage img {
    border-radius: 10px;
    border: 2px solid var(--ninja-gold);
}

.chat-dialog {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.ninja-name {
    color: var(--ninja-gold);
    font-size: 1.4em;
    font-weight: bold;
    margin-bottom: 15px;
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.5);
    text-align: left;
    font-family: 'Yuji Syuku', serif;
}

.dialog-text {
    color: var(--text-light);
    font-size: 1.1em;
    font-weight: 500;
    line-height: 1.5;
    text-align: left;
    margin-bottom: 20px;
    flex: 1;
}

#ninjaMessage button {
    padding: 12px 24px;
    background: linear-gradient(135deg, var(--ninja-red), #6a0f0f);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.1em;
    font-weight: bold;
    transition: all 0.3s ease;
    align-self: flex-start;
}

#ninjaMessage button:hover {
    background: linear-gradient(135deg, #a52a2a, #8B0000);
    transform: translateY(-2px);
}

/* Circle indicators */
.green-circle, .yellow-circle {
    display: inline-block;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: 0 0 10px rgba(0,0,0,0.5);
    flex-shrink: 0;
}

.green-circle {
    background: #1d8324;
}

.yellow-circle {
    background: #efac28;
}

/* Input improvements */
input[type="number"] {
    width: 70px;
    padding: 10px;
    font-size: 1.1em;
    border: 2px solid var(--ninja-border);
    border-radius: 6px;
    background: var(--ninja-dark);
    color: var(--text-light);
    text-align: center;
    transition: all 0.3s ease;
}

input[type="number"]:focus {
    border-color: var(--ninja-gold);
    outline: none;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}

/* Font Awesome Icon Styles */
.community-link i {
    font-size: 1.3em;
    width: 20px;
    text-align: center;
}

/* Specific icon colors */
.fa-google-play { color: #689F38; }
.fa-facebook, .fa-facebook-square { color: #1877F2; }
.fa-globe { color: #4285F4; }
.fa-comments { color: #FF6D00; }
.fa-book { color: #7B1FA2; }

/* Community Links Footer */
.community-footer {
    margin-top: 40px;
    padding: 25px;
    background: var(--ninja-light);
    border-radius: 15px;
    border: 2px solid var(--ninja-gold);
    text-align: center;
    max-width: 800px;
    width: 100%;
}

.community-footer h3 {
    color: var(--ninja-gold);
    margin-bottom: 20px;
    font-family: 'Yuji Syuku', serif;
    font-size: 1.5em;
}

.link-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    justify-items: center;
}

.community-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    background: var(--ninja-dark);
    border: 1px solid var(--ninja-border);
    border-radius: 8px;
    color: var(--text-light);
    text-decoration: none;
    transition: all 0.3s ease;
    min-width: 180px;
}

.community-link:hover {
    background: var(--ninja-gold);
    color: var(--ninja-dark);
    transform: translateY(-2px);
    border-color: var(--ninja-gold);
}

.link-icon {
    font-size: 1.2em;
}

/* Kekkai Simulator Styles */
.simulator-section {
    margin: 40px auto;
    padding: 30px;
    background: var(--ninja-light);
    border-radius: 15px;
    border: 2px solid var(--ninja-gold);
    max-width: 800px;
    width: 100%;
    text-align: center;
}

.simulator-section h2 {
    color: var(--ninja-gold);
    font-family: 'Yuji Syuku', serif;
    margin-bottom: 25px;
    font-size: 2em;
}

.simulator-controls {
    display: flex;
    flex-direction: column;
    gap: 20px;
    justify-content: center;
    align-items: center;
    margin-bottom: 30px;
}

.simulator-btn, .simulator-action-btn {
    transition: all 0.3s ease;
    min-width: 200px;
    min-height: 80px;
}

.simulator-btn:hover, .simulator-action-btn:hover {
    transform: translateY(-2px);
}

.kekkai-container {
    min-height: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Kekkai Display */
.kekkai-display {
    margin: 20px 0;
    padding: 20px;
    background: var(--ninja-dark);
    border-radius: 12px;
    border: 2px solid var(--ninja-border);
}

.kekkai-runes {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 20px 0;
    flex-wrap: wrap;
}

.kekkai-rune {
    width: 60px;
    height: 60px;
    border-radius: 10px;
    border: 3px solid var(--ninja-gold);
    background: var(--ninja-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.3);
}

/* Player Input */
.player-input {
    margin: 20px 0;
    padding: 20px;
    background: var(--ninja-light);
    border-radius: 12px;
    border: 2px solid var(--ninja-border);
}

.guess-slots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 20px 0;
    flex-wrap: wrap;
}

.guess-slot {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    border: 2px dashed var(--ninja-border);
    background: var(--ninja-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.guess-slot:hover {
    border-color: var(--ninja-gold);
}

.guess-slot.filled {
    border: 2px solid var(--ninja-gold);
}

.guess-slot.selected {
    border: 2px solid var(--ninja-red);
    box-shadow: 0 0 10px rgba(139, 0, 0, 0.5);
}

.symbol-selector {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 20px 0;
    flex-wrap: wrap;
}

.symbol-option {
    width: 45px;
    height: 45px;
    border-radius: 6px;
    border: 2px solid var(--ninja-border);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.symbol-option:hover {
    transform: scale(1.1);
    border-color: var(--ninja-gold);
}

.simulator-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 20px;
}

/* Feedback */
.simulator-feedback {
    margin-top: 20px;
    padding: 15px;
    background: var(--ninja-light);
    border-radius: 8px;
    border: 1px solid var(--ninja-border);
}

.feedback-result {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 8px 0;
    justify-content: center;
}

/* Solution */
.kekkai-solution {
    background: rgba(26, 26, 26, 0.8);
    padding: 25px;
    border-radius: 12px;
    border: 2px solid var(--ninja-red);
    margin-bottom: 20px;
    animation: slideIn 0.5s ease;
}

.kekkai-solution h3 {
    color: var(--ninja-gold);
    margin-bottom: 15px;
    font-family: 'Yuji Syuku', serif;
}

.solution-sequence {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin: 20px 0;
    flex-wrap: wrap;
}

.solution-rune {
    width: 60px;
    height: 60px;
    border-radius: 10px;
    border: 3px solid var(--ninja-gold);
    animation: runeFloat 0.6s ease;
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.3);
}

.simulator-info {
    color: var(--text-muted);
    font-size: 1.1em;
    line-height: 1.6;
    max-width: 600px;
}

.simulator-history {
    margin: 20px 0;
    padding: 20px;
    background: var(--ninja-light);
    border-radius: 12px;
    border: 2px solid var(--ninja-border);
    width: 100%;
    max-width: 800px;
}

/* Mode Toggle Styles */
.mode-toggle {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 30px auto;
    max-width: 600px;
}

.mode-btn {
    transition: all 0.3s ease;
    min-width: 180px;
    min-height: 70px;
    opacity: 0.7;
    position: relative;
}

.mode-btn.active {
    opacity: 1;
    transform: scale(1.05);
}

.mode-btn.active .image-wrapper img {
    box-shadow: 0 0 25px rgba(212, 175, 55, 0.8);
    border: 3px solid var(--ninja-gold);
}

.mode-btn:hover {
    opacity: 1;
    transform: translateY(-2px);
}

/* Responsive design */
@media (max-width: 768px) {
    body {
        padding: 15px;
    }
    
    h1 {
        font-size: 2em;
    }
    
    .controls-container {
        gap: 15px;
    }
    
    .action-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .feedback-group {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    #ninjaMessage {
        min-width: 90%;
        margin: 0 10px;
    }
    
    .ninja-container {
        flex-direction: column;
        text-align: center;
    }
    
    .chat-dialog {
        align-items: center;
    }
    
    .ninja-name, .dialog-text {
        text-align: center;
    }
    
    table {
        font-size: 0.9em;
    }
    
    th, td {
        padding: 8px 12px;
    }
    
    /* Community links responsive */
    .link-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .community-link {
        min-width: 140px;
        padding: 10px 15px;
        font-size: 0.9em;
    }
    
    .community-footer {
        padding: 20px;
    }
    
    /* Simulator responsive */
    .simulator-section {
        padding: 20px;
        margin: 20px auto;
    }
    
    .simulator-controls {
        flex-direction: column;
        align-items: center;
    }
    
    .simulator-btn, .simulator-action-btn {
        min-width: 160px;
        min-height: 70px;
    }
    
    .mode-toggle {
        flex-direction: column;
        align-items: center;
    }
    
    .mode-btn {
        min-width: 160px;
        min-height: 65px;
    }
    
    .solution-rune, .kekkai-rune {
        width: 50px;
        height: 50px;
    }
    
    .guess-slot {
        width: 45px;
        height: 45px;
    }
    
    .symbol-option {
        width: 40px;
        height: 40px;
    }
    
    /* Instructions responsive */
    .instructions {
        padding: 20px;
        margin: 20px auto;
    }
    
    .instruction-step {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .step-number {
        align-self: center;
    }
    
    .instruction-step ul {
        text-align: left;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.7em;
    }
    
    .guess-box {
        font-size: 1.1em;
        padding: 15px;
    }
    
    .progress-indicator {
        padding: 10px;
    }
    
    /* Community links mobile */
    .link-grid {
        grid-template-columns: 1fr;
    }
    
    .community-footer {
        padding: 15px;
    }
    
    .community-footer h3 {
        font-size: 1.3em;
    }
    
    /* Simulator mobile */
    .simulator-section h2 {
        font-size: 1.6em;
    }
    
    .simulator-btn, .simulator-action-btn {
        min-width: 140px;
        min-height: 60px;
    }
    
    .solution-rune, .kekkai-rune {
        width: 45px;
        height: 45px;
    }
    
    .kekkai-solution {
        padding: 15px;
    }
    
    .guess-slot {
        width: 40px;
        height: 40px;
    }
    
    .symbol-option {
        width: 35px;
        height: 35px;
    }
    
    /* Instructions mobile */
    .instructions {
        padding: 15px;
    }
    
    .instructions h3 {
        font-size: 1.2em;
    }
    
    .instruction-step {
        padding: 12px;
    }
}

/* Existing styles that remain the same */
.image-wrapper {
  position: relative;
  display: inline-block;
}

.image-wrapper img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  transition: all 0.3s ease;
}

.centered-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: rgb(235, 225, 225);
  font-weight: bold;
  font-size: 18px;
  text-shadow: 1px 1px 2px black;
  pointer-events: none;
}

button {
    margin: 5px;
    padding: 0;
    background: none;
    border: none;
    cursor: pointer;
}

.image-button img:hover {
    transform: scale(1.05);
}

@keyframes beat {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}