/* iNatQuiz v1.0 */
#inq-app {
    max-width: 900px; margin: 0 auto; padding: 24px;
    font-family: Arial, sans-serif;
}
#inq-home, #inq-game, #inq-summary {
    background: white; padding: 24px; border-radius: 24px;
    box-shadow: 0 4px 24px rgba(0,0,0,.08);
}
#inq-app h1 { text-align: center; }

/* Boutons */
#inq-app button {
    background: #84b060; color: white; border: none;
    padding: 12px 20px; border-radius: 12px;
    cursor: pointer; font-size: 16px; transition: all .2s;
}
#inq-app button:hover  { background: #689046; }
#inq-app button:active { background: #557a38; transform: scale(.98); }
#inq-app button.disabled, #inq-app button:disabled {
    background: #999 !important; cursor: not-allowed; opacity: .7; transform: none !important;
}
.inq-stop-btn { background: #c62828 !important; margin-bottom: 16px; }
.inq-stop-btn:hover { background: #8e0000 !important; }
.inq-btn-secondary { background: #546e7a !important; }
.inq-btn-secondary:hover { background: #37474f !important; }
.gmf-hidden { display: none !important; }
.inq-btn-small { font-size:14px !important; padding:8px 14px !important; }
.inq-btn-row { display: flex; gap: 12px; margin-top: 16px; flex-wrap: wrap; }

/* Tooltip How to play */
.inq-howtoplay-tooltip {
    position: relative; display: block;
    cursor: help; margin: 10px 0 16px; font-size: 14px; color: #555;
    text-align: center;
}
.inq-howtoplay-label { user-select: none; }
.inq-howtoplay-bubble {
    display: none; position: absolute;
    left: 50%; transform: translateX(-50%);
    top: calc(100% + 10px);
    width: min(400px, 90vw);
    background: #222; color: #fff;
    padding: 14px 16px; border-radius: 8px;
    font-size: 13px; line-height: 1.6;
    z-index: 999999; pointer-events: none; text-align: left;
    white-space: normal; word-wrap: break-word;
}
.inq-howtoplay-tooltip:hover .inq-howtoplay-bubble { display: block; }

/* Options accueil */
.inq-option-block { margin: 16px 0; }
.inq-radio { display: inline-block; margin-right: 16px; margin-top: 6px; cursor: pointer; }

/* Photo */
#inq-photo {
    width: 100%; max-width: 600px;
    height: auto;
    border-radius: 16px;
    margin: 16px auto; display: block;
    box-shadow: 0 4px 16px rgba(0,0,0,.15);
}

/* Progress */
#inq-progress {
    font-size: 16px; font-weight: bold; margin-bottom: 12px; color: #555;
}

/* Champ saisie */
#inq-answer-input {
    width: 100%; padding: 12px; border-radius: 12px;
    border: 1px solid #ddd; font-size: 15px; box-sizing: border-box;
    margin-top: 4px;
}
#inq-answer-input:focus { outline: none; border-color: #84b060; box-shadow: 0 0 0 2px #d4e8c2; }
#inq-answer-input:disabled { background: #f5f5f5; color: #888; }

/* Autocomplete */
.inq-ac-list {
    position: fixed;
    background: white;
    border: 1px solid #ddd;
    border-radius: 10px;
    box-shadow: 0 4px 16px rgba(0,0,0,.15);
    z-index: 999999;
    max-height: 320px;
    overflow-y: auto;
    min-width: 200px;
}
.inq-ac-item {
    padding: 10px 14px; cursor: pointer; font-size: 14px;
    border-bottom: 1px solid #f0f0f0;
}
.inq-ac-item:last-child { border-bottom: none; }
.inq-ac-item:hover { background: #f0f7eb; }

/* Correction */
#inq-correction {
    margin-top: 16px; padding: 16px;
    background: #f4f8fb; border-radius: 12px;
    font-size: 15px; line-height: 1.7;
}

/* Résumé */
#inq-summary h2 { text-align: center; }
#inq-restart-btn { display: block; margin: 0 auto 24px; }
.inq-summary-item {
    display: flex; align-items: center; gap: 16px;
    padding: 12px 16px; border-radius: 12px;
    margin-bottom: 12px; color: white;
}
.inq-good { background: #2e7d32; }
.inq-bad  { background: #c62828; }
.inq-summary-num  { font-size: 18px; font-weight: bold; min-width: 32px; }
.inq-summary-photo {
    width: 80px; height: 60px; object-fit: cover;
    border-radius: 8px; flex-shrink: 0;
}
.inq-summary-info { font-size: 14px; line-height: 1.5; }
.inq-summary-info em { opacity: .8; }

/* Selects dans les options */
#inq-home select, #inq-region-select select, #inq-country-select select {
    padding: 10px; border-radius: 10px;
    border: 1px solid #ddd; font-size: 14px;
    min-width: 220px;
}

/* Mobile */
@media (max-width: 768px) {
    #inq-app { padding: 8px; }
    #inq-home, #inq-game, #inq-summary {
        padding: 12px; border-radius: 0; box-shadow: none; background: #f0f0f0;
    }
    #inq-app button { width: 100%; display: block; box-sizing: border-box; margin-bottom: 8px; }
    .inq-btn-row { flex-direction: column; }
    #inq-photo { width: 100%; }
    .inq-summary-item { flex-wrap: wrap; }
    .inq-summary-photo { width: 60px; height: 45px; }
    .inq-ac-list { position: fixed; left: 8px; right: 8px; top: auto; }
}
