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

body {
    font-family: 'Alfa Slab One', serif;
    background: #EBF2F2;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.game-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    max-width: 800px;
    width: 100%;
    padding: 40px;
    min-height: 500px;
    position: relative;
}

header {
    text-align: center;
    margin-bottom: 30px;
    position: relative;
}

header h1 {
    color: #339933;
    font-size: 2.5em;
    font-weight: normal;
    letter-spacing: 1px;
}

.dev-menu-button {
    position: absolute;
    top: 0;
    right: 0;
    background: #718096;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 10px 15px;
    font-size: 1.2em;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.dev-menu-button:hover {
    background: #4a5568;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.dev-menu-button:active {
    transform: translateY(0);
}

.screen {
    display: none;
}

.screen.active {
    display: block;
}

#game-screen {
    text-align: center;
}

.name-input-container {
    text-align: center;
    padding: 40px 20px;
    position: relative;
}

.paw-print {
    position: absolute;
    opacity: 0.15;
    font-size: 2em;
    color: #8B7355;
}

.paw-print-top-left {
    top: 10px;
    left: 20px;
}

.paw-print-top-right {
    top: 10px;
    right: 20px;
}

.paw-print-bottom-right {
    bottom: 10px;
    right: 20px;
}

.name-input-container h2 {
    color: #339933;
    font-size: 2.2em;
    margin-bottom: 20px;
    font-weight: normal;
    letter-spacing: 0.5px;
}

.name-input-container p {
    color: #2d3748;
    font-size: 1.2em;
    margin-bottom: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-weight: normal;
}

.name-input-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.generate-names-button {
    background: #339933;
    color: white;
    border: none;
    border-radius: 10px;
    width: 50px;
    height: 50px;
    font-size: 1.5em;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 6px rgba(51, 153, 51, 0.2);
    flex-shrink: 0;
}

.generate-names-button:hover {
    background: #2d7d2d;
    transform: scale(1.05);
    box-shadow: 0 4px 8px rgba(51, 153, 51, 0.3);
}

.generate-names-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.generated-names-container {
    margin: 20px auto 30px;
    max-width: 500px;
}

.generated-names-label {
    color: #2d3748;
    font-size: 0.95em;
    margin-bottom: 10px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.generated-names-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.generated-name-button {
    background: white;
    color: #339933;
    border: 2px solid #339933;
    border-radius: 20px;
    padding: 8px 16px;
    font-size: 0.95em;
    font-family: 'Alfa Slab One', serif;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: 0.3px;
}

.generated-name-button:hover {
    background: #339933;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 2px 6px rgba(51, 153, 51, 0.3);
}

#dog-name-input {
    flex: 1;
    padding: 15px 20px;
    font-size: 1.1em;
    border: 2px solid #2d3748;
    border-radius: 10px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    text-align: center;
    background: white;
    color: #2d3748;
    min-width: 0;
}

#dog-name-input:focus {
    outline: none;
    border-color: #339933;
    box-shadow: 0 0 0 3px rgba(51, 153, 51, 0.1);
}

.story-text {
    background: #f7fafc;
    border: 2px solid #e2e8f0;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    font-size: 1.2em;
    line-height: 1.8;
    color: #2d3748;
    min-height: 150px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    text-align: center;
}

/* Choices container - supports flexible choice counts (2-5 choices per scene) */
.choices-container {
    display: flex;
    flex-direction: column;
    gap: 20px; /* Slightly reduced gap to accommodate more choices */
    align-items: center;
    max-width: 600px;
    margin: 0 auto;
    max-height: 70vh; /* Limit height to prevent overflow on mobile */
    overflow-y: auto; /* Allow scrolling if needed for many choices */
    padding: 10px; /* Add padding for scrollbar */
}

.choice-button {
    background: #339933;
    color: white;
    border: none;
    border-radius: 12px;
    padding: 18px 30px;
    font-size: 1.2em;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-weight: normal;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(51, 153, 51, 0.2);
    text-align: center;
    display: block;
    width: 100%;
    max-width: 500px;
    margin: 0 auto 20px; /* Add bottom margin for spacing between buttons */
}

.choice-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(51, 153, 51, 0.3);
    background: #2d7d2d;
}

.choice-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(51, 153, 51, 0.2);
}

/* Remove bottom margin from last choice button to avoid extra space */
.choices-container .choice-button:last-child {
    margin-bottom: 0;
}

#see-images-button,
#play-again-button {
    width: 100%;
    max-width: 300px;
    margin: 30px auto 0;
    display: block;
    text-align: center;
}

/* Comic Book Screen Styles */
#comic-book-screen {
    text-align: center;
    padding: 20px;
}

.comic-book-title {
    color: #339933;
    font-size: 2.5em;
    margin-bottom: 30px;
    font-family: 'Alfa Slab One', serif;
    font-weight: normal;
    letter-spacing: 0.5px;
}

.comic-book-container {
    max-width: 900px;
    margin: 0 auto 30px;
    display: flex;
    flex-direction: column;
    gap: 40px;
    max-height: 70vh;
    overflow-y: auto;
    padding: 20px;
    background: #f7fafc;
    border-radius: 15px;
    border: 3px solid #339933;
}

.comic-book-page {
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border: 2px solid #e2e8f0;
    page-break-after: always;
}

.comic-book-page-title {
    color: #339933;
    font-size: 1.5em;
    margin-bottom: 15px;
    font-family: 'Alfa Slab One', serif;
    font-weight: normal;
}

.comic-book-image {
    width: 100%;
    max-width: 500px;
    height: auto;
    border-radius: 10px;
    border: 3px solid #339933;
    box-shadow: 0 4px 12px rgba(51, 153, 51, 0.2);
    margin: 20px auto;
    display: block;
    object-fit: contain;
}

.comic-book-text {
    color: #2d3748;
    font-size: 1.1em;
    line-height: 1.8;
    margin-top: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    text-align: left;
    padding: 15px;
    background: #f7fafc;
    border-radius: 8px;
    border-left: 4px solid #339933;
}

/* Responsive styles for comic book */
@media (max-width: 600px) {
    .comic-book-title {
        font-size: 1.8em;
    }
    
    .comic-book-container {
        padding: 15px;
        gap: 30px;
    }
    
    .comic-book-page {
        padding: 15px;
    }
    
    .comic-book-image {
        max-width: 100%;
    }
    
    .comic-book-text {
        font-size: 1em;
        padding: 12px;
    }
}

#ending-text {
    text-align: center;
    font-size: 1.4em;
}

.welcome-container {
    text-align: center;
    padding: 50px 20px;
    max-width: 600px;
    margin: 0 auto;
}

.welcome-container h2 {
    color: #339933;
    font-size: 2.5em;
    margin-bottom: 20px;
    font-weight: normal;
    letter-spacing: 0.5px;
    font-family: 'Alfa Slab One', serif;
}

.welcome-container p {
    font-size: 1.2em;
    line-height: 1.8;
    color: #2d3748;
    margin-bottom: 40px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.ending-statistics {
    background: #f7fafc;
    border: 2px solid #339933;
    border-radius: 12px;
    padding: 15px 20px;
    margin: 20px auto 30px;
    max-width: 400px;
    text-align: center;
}

.ending-statistics .statistics-text {
    color: #339933;
    font-size: 1.1em;
    font-weight: bold;
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.customization-container {
    text-align: center;
    padding: 30px 20px;
}

.customization-container h2 {
    color: #339933;
    font-size: 2em;
    margin-bottom: 25px;
    font-weight: normal;
    letter-spacing: 0.5px;
}

.customization-fields-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    max-width: 700px;
    margin: 0 auto 25px;
}

.dog-image-container {
    margin-bottom: 25px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
    width: 100%;
}

#start-adventure-from-image-button {
    margin-top: 20px;
    width: 100%;
    max-width: 300px;
}

.dog-image {
    max-width: 250px;
    max-height: 250px;
    border-radius: 15px;
    border: 3px solid #339933;
    box-shadow: 0 4px 12px rgba(51, 153, 51, 0.2);
    object-fit: contain;
}

.image-loading {
    background: #f7fafc;
    border: 2px solid #339933;
    border-radius: 15px;
    padding: 40px;
    color: #339933;
    font-size: 1.1em;
    min-width: 200px;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.image-loading::after {
    content: '...';
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}

.scene-image-container {
    margin-bottom: 25px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
    width: 100%;
}

.scene-image {
    max-width: 300px;
    max-height: 300px;
    border-radius: 15px;
    border: 3px solid #339933;
    box-shadow: 0 4px 12px rgba(51, 153, 51, 0.2);
    object-fit: contain;
}

.scene-image-loading {
    background: #f7fafc;
    border: 2px solid #339933;
    border-radius: 15px;
    padding: 40px;
    color: #339933;
    font-size: 1.1em;
    min-width: 200px;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.scene-image-loading::after {
    content: '...';
    animation: dots 1.5s steps(4, end) infinite;
}

.customization-section {
    margin-bottom: 0;
    text-align: left;
}

.customization-section.full-width {
    grid-column: 1 / -1;
}

.customization-section label {
    display: block;
    color: #2d3748;
    font-size: 1.2em;
    font-weight: normal;
    margin-bottom: 10px;
    font-family: 'Alfa Slab One', serif;
    letter-spacing: 0.3px;
}

.required {
    color: #e53e3e;
}

.customization-select:disabled {
    background: #edf2f7;
    color: #a0aec0;
    cursor: not-allowed;
    opacity: 0.6;
}

.choice-button:disabled {
    background: #cbd5e0;
    cursor: not-allowed;
    opacity: 0.6;
}

.choice-button:disabled:hover {
    transform: none;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    background: #cbd5e0;
}

.customization-select {
    width: 100%;
    padding: 12px 15px;
    font-size: 1.1em;
    border: 2px solid #2d3748;
    border-radius: 10px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: white;
    color: #2d3748;
    cursor: pointer;
    transition: all 0.3s ease;
}

.customization-select:focus {
    outline: none;
    border-color: #339933;
    box-shadow: 0 0 0 3px rgba(51, 153, 51, 0.1);
}

.customization-select:hover {
    border-color: #339933;
}

#start-adventure-button {
    margin-top: 30px;
    width: 100%;
    max-width: 400px;
}

/* Mobile responsive */
@media (max-width: 600px) {
    header h1 {
        font-size: 1.8em;
    }
    
    .welcome-container h2,
    .name-input-container h2,
    .customization-container h2 {
        font-size: 1.5em;
    }
    
    .welcome-container p {
        font-size: 1em;
        margin-bottom: 30px;
    }
    
    .story-text {
        font-size: 1.1em;
        padding: 20px;
    }
    
    .choice-button {
        font-size: 1em;
        padding: 15px 20px;
    }
    
    .choices-container {
        gap: 15px; /* Tighter gap on mobile for more choices */
        max-height: 60vh; /* Lower max height on mobile */
    }
    
    .game-container {
        padding: 20px;
    }
    
    .customization-fields-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .customization-section {
        margin-bottom: 0;
    }
    
    .customization-select {
        font-size: 1em;
        padding: 10px 12px;
    }
    
    .dog-preview-container {
        min-height: 150px;
    }
    
    .dog-image {
        max-width: 200px;
        max-height: 200px;
    }
    
    .dog-image-placeholder {
        min-width: 150px;
        min-height: 150px;
        padding: 20px;
        font-size: 0.9em;
    }
    
    .name-input-wrapper {
        flex-direction: column;
        gap: 10px;
    }
    
    .generate-names-button {
        width: 100%;
        max-width: 400px;
    }
    
    .generated-names-list {
        flex-direction: column;
        align-items: stretch;
    }
    
    .generated-name-button {
        width: 100%;
    }
}

/* Custom Modal Styles */
.custom-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
}

.modal-content {
    position: relative;
    background: white;
    border-radius: 20px;
    padding: 30px 40px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    z-index: 1001;
    text-align: center;
}

.modal-title {
    color: #339933;
    font-size: 1.5em;
    font-family: 'Alfa Slab One', serif;
    margin-bottom: 15px;
    font-weight: normal;
    letter-spacing: 0.5px;
}

.modal-message {
    color: #2d3748;
    font-size: 1.1em;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    margin-bottom: 25px;
    line-height: 1.6;
}

.modal-button {
    width: 100%;
    max-width: 200px;
    margin: 10px auto;
}

.modal-content {
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Mobile responsive for modal */
@media (max-width: 600px) {
    .modal-content {
        padding: 25px 30px;
        max-width: 90%;
    }
    
    .modal-title {
        font-size: 1.3em;
    }
    
    .modal-message {
        font-size: 1em;
    }
}

/* Minigame Overlay Styles */
.minigame-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.minigame-container {
    position: relative;
    background: white;
    border-radius: 20px;
    padding: 30px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.minigame-skip-button {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #f44336;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 10px 20px;
    font-size: 1em;
    font-family: 'Alfa Slab One', serif;
    cursor: pointer;
    transition: background 0.3s;
    z-index: 2001;
}

.minigame-skip-button:hover {
    background: #d32f2f;
}

.minigame-skip-button:active {
    transform: scale(0.95);
}

.minigame-content {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

/* Maze Minigame Styles */
.minigame-maze {
    display: grid;
    gap: 2px;
    background: #333;
    padding: 10px;
    border-radius: 10px;
    margin: 20px 0;
}

.maze-cell {
    width: 60px;
    height: 60px;
    background: #f5f5f5;
    border: 2px solid #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    transition: background 0.2s;
    user-select: none;
}

.maze-cell.path {
    background: #e8f5e9;
}

.maze-cell.start {
    background: #c8e6c9;
}

.maze-cell.end {
    background: #ffccbc;
}

.maze-cell.current {
    background: #4caf50;
    border-color: #2e7d32;
    box-shadow: 0 0 10px rgba(76, 175, 80, 0.5);
}

.maze-cell.visited {
    background: #a5d6a7;
}

.maze-cell:hover:not(.wall) {
    background: #81c784;
    transform: scale(1.05);
}

.maze-cell.wall {
    background: #424242;
    cursor: not-allowed;
}

.maze-cell.wall:hover {
    transform: none;
}

.maze-pawprint {
    font-size: 24px;
    opacity: 0.7;
}

.maze-dog {
    width: 40px;
    height: 40px;
    background: #ff9800;
    border-radius: 50%;
    border: 3px solid #f57c00;
    position: relative;
}

.maze-dog::before {
    content: '🐕';
    font-size: 30px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.maze-success {
    text-align: center;
    color: #2e7d32;
    font-size: 1.5em;
    font-family: 'Alfa Slab One', serif;
    margin-top: 20px;
    animation: fadeIn 0.5s;
}

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

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-5px);
    }
    20%, 40%, 60%, 80% {
        transform: translateX(5px);
    }
}

.minigame-title {
    color: #339933;
    font-size: 1.8em;
    font-family: 'Alfa Slab One', serif;
    margin-bottom: 10px;
    text-align: center;
}

.minigame-instructions {
    color: #2d3748;
    font-size: 1.1em;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    text-align: center;
    margin-bottom: 20px;
}

.minigame-progress {
    color: #339933;
    font-size: 1.2em;
    font-weight: bold;
    text-align: center;
    margin: 10px 0;
}

.minigame-status {
    color: #2d3748;
    font-size: 1.1em;
    font-weight: bold;
    text-align: center;
    margin: 10px 0;
}

/* Find and Collect Minigame Styles */
.minigame-find-collect {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
    width: 100%;
    max-width: 500px;
    margin: 20px 0;
}

.find-collect-location {
    padding: 20px;
    background: #e8f5e9;
    border: 3px solid #4caf50;
    border-radius: 12px;
    font-size: 1.1em;
    font-weight: bold;
    color: #2e7d32;
    cursor: pointer;
    transition: all 0.3s;
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    text-align: center;
}

.find-collect-location:hover:not(:disabled) {
    background: #c8e6c9;
    transform: scale(1.05);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.find-collect-location:active:not(:disabled) {
    transform: scale(0.95);
}

.find-collect-location.found {
    background: #c8e6c9;
    border-color: #2e7d32;
    cursor: default;
}

.find-collect-location.empty {
    background: #f5f5f5;
    border-color: #bdbdbd;
    cursor: default;
    opacity: 0.8;
}

.find-collect-location .found-item {
    font-size: 2em;
    margin-top: 10px;
}

.find-collect-location .empty-result {
    font-size: 0.9em;
    margin-top: 5px;
    color: #757575;
    font-style: italic;
}

/* Pattern Matching Minigame Styles */
.minigame-pattern-matching {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    width: 100%;
    max-width: 300px;
    margin: 20px 0;
}

.pattern-tile {
    width: 120px;
    height: 120px;
    font-size: 3em;
    border: 4px solid #ddd;
    border-radius: 12px;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pattern-tile:hover:not(:disabled) {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.pattern-tile:active:not(:disabled) {
    transform: scale(0.95);
}

.pattern-tile.active {
    background: #fff9c4;
    border-color: #fbc02d;
    box-shadow: 0 0 20px rgba(251, 192, 45, 0.6);
    transform: scale(1.15);
}

.pattern-tile.clicked {
    background: #e1f5fe;
    border-color: #0288d1;
    transform: scale(0.9);
}

.pattern-tile:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

/* Hidden Object Minigame Styles */
.minigame-checklist {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    margin: 15px 0;
}

.checklist-item {
    padding: 10px 15px;
    background: #fff3e0;
    border: 2px solid #ff9800;
    border-radius: 8px;
    font-size: 1.2em;
    font-weight: bold;
}

.checklist-item.found {
    background: #c8e6c9;
    border-color: #4caf50;
    color: #2e7d32;
}

.minigame-hidden-object {
    display: grid;
    gap: 4px;
    background: #f5f5f5;
    padding: 15px;
    border-radius: 12px;
    margin: 20px 0;
    width: 100%;
    max-width: 400px;
}

.hidden-object-cell {
    width: 60px;
    height: 60px;
    background: #e8eaf6;
    border: 2px solid #9fa8da;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5em;
    position: relative;
}

.hidden-object-cell:hover:not(.found) {
    background: #c5cae9;
    transform: scale(1.1);
}

/* Searched cells - neutral appearance */
.hidden-object-cell.searched {
    background: #f5f5f5;
    border-color: #bdbdbd;
    cursor: default;
    opacity: 0.8;
}

/* Hot/cold feedback after threshold */
.hidden-object-cell.warm {
    background: #ffe0b2;
    border-color: #ff9800;
    cursor: default;
}

.hidden-object-cell.cold {
    background: #e3f2fd;
    border-color: #2196f3;
    cursor: default;
}

/* Found object - success state */
.hidden-object-cell.found {
    background: #c8e6c9;
    border-color: #4caf50;
    cursor: default;
}

/* Sequence Puzzle Minigame Styles */
.minigame-sequence-puzzle {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    max-width: 400px;
    margin: 20px 0;
}

.sequence-items-container {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
}

.sequence-item {
    padding: 15px 20px;
    font-size: 2em;
    background: #e3f2fd;
    border: 3px solid #2196f3;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    min-width: 60px;
    text-align: center;
}

.sequence-item:hover:not(:disabled) {
    background: #bbdefb;
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.sequence-item:active:not(:disabled) {
    transform: scale(0.95);
}

.sequence-item.selected {
    background: #c8e6c9;
    border-color: #4caf50;
    cursor: default;
    opacity: 0.6;
}

.sequence-item:disabled {
    cursor: not-allowed;
}

.sequence-order-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    min-height: 80px;
    padding: 20px;
    background: #f5f5f5;
    border: 3px dashed #9e9e9e;
    border-radius: 12px;
}

.sequence-order-slot {
    padding: 15px 20px;
    font-size: 2em;
    background: #fff9c4;
    border: 3px solid #fbc02d;
    border-radius: 12px;
    min-width: 60px;
    text-align: center;
    animation: fadeIn 0.3s;
}

/* Mobile responsive for minigame */
@media (max-width: 600px) {
    .minigame-container {
        padding: 20px;
        width: 95%;
    }
    
    .maze-cell {
        width: 50px;
        height: 50px;
    }
    
    .minigame-title {
        font-size: 1.5em;
    }
    
    .minigame-instructions {
        font-size: 1em;
    }
    
    .minigame-skip-button {
        padding: 8px 16px;
        font-size: 0.9em;
        top: 10px;
        right: 10px;
    }
    
    .find-collect-location {
        padding: 15px;
        min-height: 70px;
        font-size: 1em;
    }
    
    .pattern-tile {
        width: 100px;
        height: 100px;
        font-size: 2.5em;
    }
    
    .hidden-object-cell {
        width: 50px;
        height: 50px;
        font-size: 1.2em;
    }
    
    .sequence-item {
        padding: 12px 16px;
        font-size: 1.5em;
        min-width: 50px;
    }
    
    .sequence-order-slot {
        padding: 12px 16px;
        font-size: 1.5em;
        min-width: 50px;
    }
}

@media (max-width: 400px) {
    .maze-cell {
        width: 44px;
        height: 44px;
    }
    
    .pattern-tile {
        width: 80px;
        height: 80px;
        font-size: 2em;
    }
    
    .hidden-object-cell {
        width: 44px;
        height: 44px;
        font-size: 1em;
    }
    
    .find-collect-location {
        padding: 12px;
        min-height: 60px;
        font-size: 0.9em;
    }
    
    .sequence-item,
    .sequence-order-slot {
        padding: 10px 14px;
        font-size: 1.3em;
        min-width: 44px;
    }
    
    .maze-dog {
        width: 32px;
        height: 32px;
    }
    
    .maze-dog::before {
        font-size: 24px;
    }
}

/* Developer Tool Styles */
.dev-tool {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dev-tool-container {
    background: white;
    border-radius: 20px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.dev-tool-container h2 {
    color: #339933;
    font-family: 'Alfa Slab One', serif;
    font-size: 1.8em;
    margin-bottom: 20px;
    text-align: center;
}

.dev-tool-controls {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.dev-tool-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dev-tool-section label {
    color: #2d3748;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 1em;
    font-weight: 600;
}

.dev-select,
.dev-input {
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1em;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: white;
    color: #2d3748;
    transition: border-color 0.3s;
}

.dev-select:focus,
.dev-input:focus {
    outline: none;
    border-color: #339933;
}

.dev-tool-buttons {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.dev-button {
    flex: 1;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    font-family: 'Alfa Slab One', serif;
    cursor: pointer;
    transition: all 0.3s;
    background: #339933;
    color: white;
}

.dev-button:hover {
    background: #2d7d32;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.dev-button:active {
    transform: translateY(0);
}

.dev-button-secondary {
    background: #718096;
}

.dev-button-secondary:hover {
    background: #4a5568;
}

/* Mobile responsive for dev tool */
@media (max-width: 600px) {
    .dev-tool-container {
        padding: 20px;
        width: 95%;
    }
    
    .dev-tool-container h2 {
        font-size: 1.5em;
    }
    
    .dev-tool-buttons {
        flex-direction: column;
    }
}

