/*
 * Pythie — Cryptographic verification panel.
 * Used by drawing/new.leaf (streaming), drawing/oracle-result.leaf,
 * chroma/result.leaf, and drawing/verify.leaf (standalone page).
 */

.verify-panel {
    margin-top: 1.5rem;
    padding: 1rem 1.25rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.02);
}
.verify-panel.hidden { display: none; }
.verify-panel > summary {
    cursor: pointer;
    font-weight: 600;
    color: var(--accent, #e94560);
}
.verify-intro {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.75);
    margin: 0.75rem 0 1rem;
    line-height: 1.5;
}
.verify-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.verify-actions button {
    cursor: pointer;
    padding: 0.5rem 0.9rem;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.04);
    color: inherit;
    font-size: 0.9rem;
}
.verify-actions button:hover:not(:disabled) { background: rgba(255, 255, 255, 0.08); }
.verify-actions button:disabled { opacity: 0.6; cursor: progress; }

.verify-result { margin-top: 1rem; font-size: 0.9rem; }
.verify-result .verify-success { color: #34c759; font-weight: 600; margin-bottom: 0.5rem; }
.verify-result .verify-failure { color: #ff453a; font-weight: 600; margin-bottom: 0.5rem; }
.verify-result ul { padding-left: 1.25rem; margin: 0.25rem 0; }
.verify-result ul li { line-height: 1.4; }
.verify-result .verify-error { color: #ff453a; }

.verify-details { margin-top: 0.75rem; font-size: 0.8rem; opacity: 0.85; }
.verify-details > summary { cursor: pointer; }
.verify-details dl { margin: 0.5rem 0; }
.verify-details dt { font-weight: 600; margin-top: 0.4rem; }
.verify-details dd {
    margin: 0 0 0.2rem;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    word-break: break-all;
}

/* Streaming result (shared by Chroma/Fractal inline rendering) */
.streaming-result { padding: 1rem 0; max-width: 920px; margin: 0 auto; }
.streaming-result.hidden { display: none; }
.streaming-cards { display: flex; flex-wrap: wrap; gap: 0.75rem; justify-content: center; margin-bottom: 1.5rem; }
.streaming-card {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    padding: 0.75rem 1rem;
    min-width: 150px;
    text-align: center;
}
.streaming-card-number { font-size: 1.5rem; font-weight: 600; color: var(--accent, #e94560); }
.streaming-card-name { font-size: 0.95rem; margin-top: 0.3rem; }
.streaming-card-sub { font-size: 0.8rem; color: rgba(255,255,255,0.6); margin-top: 0.2rem; }
.streaming-conjugation { text-align: center; margin: 0.5rem 0 1.25rem; font-size: 0.95rem; color: rgba(255,255,255,0.85); }
.narration-heading { color: var(--accent, #e94560); font-weight: 500; margin-bottom: 0.5rem; }
.streaming-narration { white-space: pre-wrap; line-height: 1.55; }
.streaming-narration::after { content: '▊'; opacity: 0.6; animation: blink 1s steps(1) infinite; margin-left: 2px; }
.streaming-narration.done::after { content: ''; }
@keyframes blink { 50% { opacity: 0; } }
.streaming-actions { margin-top: 1.5rem; text-align: center; }

/* Model picker — collapsible */
.model-selector { margin: 0.75rem 0 1rem; }
.model-selector > summary { cursor: pointer; font-size: 0.85rem; color: rgba(255,255,255,0.6); padding: 0.25rem 0; }
.model-selector > summary:hover { color: rgba(255,255,255,0.85); }
.model-selector select {
    margin-top: 0.4rem; width: 100%; padding: 0.5rem; font-size: 0.9rem;
    background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.2);
    border-radius: 4px; color: inherit;
}

/* Fallback notice */
.fallback-notice {
    margin: 0.5rem 0 0.75rem; padding: 0.55rem 0.75rem; font-size: 0.85rem;
    background: rgba(255,196,0,0.08); border-left: 3px solid #ffc400;
    border-radius: 3px; color: rgba(255,235,180,0.9);
}

/* Reading feedback widget (3-level satisfaction) */
.feedback-widget { margin: 1.25rem 0 0.5rem; text-align: center; }
.feedback-widget[hidden] { display: none; }
.feedback-question { font-size: 0.9rem; color: rgba(255,255,255,0.75); margin-bottom: 0.5rem; }
.feedback-buttons { display: flex; gap: 0.5rem; justify-content: center; flex-wrap: wrap; }
.feedback-btn {
    cursor: pointer; padding: 0.45rem 0.85rem; font-size: 0.88rem;
    border-radius: 999px; border: 1px solid rgba(255,255,255,0.25);
    background: rgba(255,255,255,0.04); color: inherit;
}
.feedback-btn:hover:not(:disabled) { background: rgba(255,255,255,0.09); }
.feedback-btn:disabled { opacity: 0.5; cursor: default; }
.feedback-btn.chosen { background: var(--accent, #e94560); border-color: var(--accent, #e94560); color: #fff; opacity: 1; }
.feedback-thanks { margin-top: 0.5rem; font-size: 0.85rem; color: #34c759; }

/* Standalone /draw/verify page */
.verify-page #dropzone {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 180px;
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    margin: 1rem 0;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
}
.verify-page #dropzone.dragover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--accent, #e94560);
}
.verify-page #fileInput { display: none; }
