/* The OOP Deduction Lab — the committee of clues. */

.oop-stage {
    max-width: 1060px;
    margin: 0 auto;
    padding: 1.4rem 1.2rem 4rem;
}
.oop-header { text-align: center; margin: 0.6rem 0 1.4rem; }
.oop-header h1 { margin: 0 0 0.4rem; }
.oop-lead { color: var(--text-dim, #9fb0bf); max-width: 620px; margin: 0 auto; line-height: 1.6; }

.oop-input-card {
    background: var(--bg-card, rgba(16, 24, 33, 0.75));
    border: 1px solid var(--border, #263241);
    border-radius: 12px;
    padding: 1.1rem 1.2rem;
    margin-bottom: 1.6rem;
}
.oop-input-card textarea {
    width: 100%;
    resize: vertical;
    min-height: 88px;
    max-height: 320px;
    background: var(--bg-raised, #0d141c);
    color: var(--text, #e6edf3);
    border: 1px solid var(--border, #263241);
    border-radius: 10px;
    padding: 0.65rem 0.8rem;
    font-family: inherit;
    font-size: 0.95rem;
    line-height: 1.55;
    caret-color: var(--accent, #00c8ff);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.oop-input-card textarea::placeholder { color: var(--muted, #64748b); }
.oop-input-card textarea:focus {
    border-color: var(--accent, #00c8ff);
    box-shadow: 0 0 0 3px var(--accent-soft, rgba(0, 200, 255, 0.15));
    outline: none;
}

.oop-input-head { display: flex; align-items: center; gap: 0.6rem; }
.oop-input-head .cipher-label { flex: 1; }
.oop-settings-btn {
    flex: none;
    background: none;
    border: 1px solid var(--border, #263241);
    border-radius: 8px;
    font-size: 1rem;
    padding: 0.25rem 0.55rem;
    cursor: pointer;
    transition: border-color 0.15s ease, transform 0.15s ease;
}
.oop-settings-btn:hover { border-color: rgba(0, 200, 255, 0.5); transform: rotate(30deg); }
.oop-settings-panel {
    border: 1px solid var(--border, #263241);
    border-radius: 10px;
    background: var(--bg-raised, rgba(10, 16, 24, 0.9));
    padding: 0.8rem 0.95rem;
    margin: 0.6rem 0;
}
.oop-settings-panel select {
    width: 100%;
    margin-top: 0.3rem;
    background: var(--bg-raised, #0d141c);
    color: var(--text, #e6edf3);
    border: 1px solid var(--border, #263241);
    border-radius: 8px;
    padding: 0.45rem 0.6rem;
    font: inherit;
}
.oop-settings-note {
    margin: 0.5rem 0 0;
    color: var(--text-dim, #93a1af);
    font-size: 0.8rem;
    font-style: italic;
    line-height: 1.5;
}

.oop-starters { display: flex; gap: 0.5rem; flex-wrap: wrap; margin: 0.6rem 0 0.2rem; }
.oop-starter {
    background: rgba(0, 200, 255, 0.06);
    border: 1px solid rgba(0, 200, 255, 0.25);
    border-radius: 999px;
    color: #9fdcf1;
    font-size: 0.8rem;
    padding: 0.3rem 0.75rem;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}
.oop-starter:hover { background: rgba(0, 200, 255, 0.16); color: #d6f3fc; }

.oop-hint {
    margin: 0.55rem 0 0;
    color: var(--text-dim, #7f909f);
    font-size: 0.78rem;
    line-height: 1.5;
}
.oop-hint kbd {
    border: 1px solid var(--border, #34424f);
    border-bottom-width: 2px;
    border-radius: 4px;
    padding: 0 0.3rem;
    font-size: 0.72rem;
    font-family: inherit;
}

.oop-phases { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-top: 0.8rem; }
.oop-phase {
    font-size: 0.78rem;
    letter-spacing: 0.5px;
    padding: 0.25rem 0.7rem;
    border-radius: 999px;
    border: 1px solid var(--border, #263241);
    color: var(--text-dim, #93a1af);
    opacity: 0.6;
}
.oop-phase.is-current {
    opacity: 1;
    color: #ffd166;
    border-color: rgba(255, 209, 102, 0.5);
    animation: oop-pulse 1.4s ease-in-out infinite;
}
.oop-phase.is-done { opacity: 1; color: #7fe0a8; border-color: rgba(64, 200, 120, 0.4); }
@keyframes oop-pulse { 50% { box-shadow: 0 0 12px rgba(255, 209, 102, 0.25); } }

.oop-section-title {
    font-size: 0.85rem;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    color: var(--accent, #ffd166);
    margin: 1.6rem 0 0.8rem;
}

/* -------------------------- object cards --------------------------- */

.oop-object-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 0.9rem;
}
.oop-card {
    background: var(--bg-card, rgba(16, 24, 33, 0.75));
    border: 1px solid var(--border, #263241);
    border-radius: 12px;
    padding: 0.9rem 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease, opacity 0.3s ease;
}
.oop-card.is-dormant { opacity: 0.55; }
.oop-card.is-entering { animation: oop-enter 0.45s ease backwards; }
@keyframes oop-enter {
    from { opacity: 0; transform: translateY(14px) scale(0.97); }
}
.oop-card-state.is-thinking { animation: oop-think 1.2s ease-in-out infinite; }
@keyframes oop-think { 50% { opacity: 0.45; } }
.oop-card.is-awake { opacity: 1; }
.oop-card.is-deliberating {
    border-color: rgba(0, 200, 255, 0.55);
    box-shadow: 0 0 16px rgba(0, 200, 255, 0.12);
}
.oop-card.is-settled { border-color: rgba(64, 200, 120, 0.4); }
.oop-card-head { display: flex; align-items: center; gap: 0.55rem; }
.oop-card-emoji { font-size: 1.35rem; }
.oop-card-head h3 { margin: 0; font-size: 1rem; flex: 1; min-width: 0; }
.oop-card-state {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 0.14rem 0.5rem;
    border-radius: 999px;
    background: rgba(147, 161, 175, 0.12);
    color: var(--text-dim, #93a1af);
    white-space: nowrap;
}
.oop-card.is-deliberating .oop-card-state { background: rgba(0, 200, 255, 0.15); color: #7fd8f5; }
.oop-card.is-settled .oop-card-state { background: rgba(64, 200, 120, 0.15); color: #7fe0a8; }
.oop-card-claim { color: var(--text-dim, #a9b7c4); font-size: 0.88rem; line-height: 1.5; margin: 0.5rem 0 0; }
.oop-card-mind { border-top: 1px dashed var(--border, #263241); margin-top: 0.6rem; padding-top: 0.6rem; }
.oop-card-voice { color: #ffd166; font-style: italic; font-size: 0.86rem; margin: 0 0 0.35rem; }
.oop-card-belief { font-size: 0.88rem; line-height: 1.5; margin: 0 0 0.4rem; }
.oop-meter {
    height: 5px;
    border-radius: 999px;
    background: rgba(147, 161, 175, 0.15);
    overflow: hidden;
    margin-bottom: 0.4rem;
}
.oop-meter span { display: block; height: 100%; background: linear-gradient(90deg, #00c8ff, #7fe0a8); }
.oop-card-suspicion { font-size: 0.8rem; color: #d9a05b; margin: 0.15rem 0 0; line-height: 1.45; }

/* ------------------------------ feed ------------------------------- */

.oop-feed {
    background: var(--bg-card, rgba(10, 16, 24, 0.8));
    border: 1px solid var(--border, #263241);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    max-height: 380px;
    overflow-y: auto;
    font-size: 0.88rem;
    line-height: 1.55;
}
.oop-feed-line { padding: 0.28rem 0; border-bottom: 1px dotted rgba(38, 50, 65, 0.6); }
.oop-feed-line:last-child { border-bottom: none; }
.oop-feed-line.is-system { color: #9fb0bf; }
.oop-feed-line.is-awaken { color: #ffd166; }
.oop-feed-line.is-turn { padding-left: 1rem; }
.oop-speaker { color: #7fd8f5; font-weight: 600; margin-right: 0.3rem; }
.oop-feed-line.is-accepted { color: #7fe0a8; }
.oop-feed-line.is-rejected { color: #ff9d9d; }

/* ----------------------------- verdict ----------------------------- */

.oop-verdict {
    background: var(--bg-card, rgba(16, 24, 33, 0.8));
    border: 1px solid rgba(255, 209, 102, 0.35);
    border-radius: 12px;
    padding: 1rem 1.2rem 1.2rem;
    margin-top: 1.4rem;
}
.oop-verdict-text { font-size: 1.15rem; line-height: 1.5; margin: 0 0 0.5rem; }
.oop-verdict-rationale { color: var(--text-dim, #a9b7c4); line-height: 1.6; margin: 0 0 0.6rem; }
.oop-vote-tally { font-size: 0.85rem; letter-spacing: 0.6px; color: var(--accent, #ffd166); margin: 0 0 0.5rem; }
.oop-vote {
    display: flex;
    gap: 0.6rem;
    align-items: baseline;
    padding: 0.3rem 0.55rem;
    margin: 0.25rem 0;
    border-radius: 8px;
    font-size: 0.88rem;
    line-height: 1.5;
}
.oop-vote.is-aye { background: rgba(64, 200, 120, 0.07); }
.oop-vote.is-nay { background: rgba(230, 90, 90, 0.08); }
.oop-vote-mark { flex: none; font-weight: bold; }
.oop-vote.is-aye .oop-vote-mark { color: #7fe0a8; }
.oop-vote.is-nay .oop-vote-mark { color: #ff9d9d; }
.oop-dissent {
    margin: 0.7rem 0 0;
    padding-top: 0.6rem;
    border-top: 1px solid var(--border, #263241);
    color: #ffce7a;
    font-size: 0.9rem;
    line-height: 1.55;
}
.oop-dissent.is-unanimous { color: #7fe0a8; }

.oop-usage {
    display: inline-block;
    margin: 0.5rem 0 0;
    font-size: 0.78rem;
    letter-spacing: 0.4px;
    font-variant-numeric: tabular-nums;
    color: var(--text-dim, #93a1af);
    background: var(--bg-raised, rgba(147, 161, 175, 0.08));
    border: 1px solid var(--border, #263241);
    border-radius: 999px;
    padding: 0.22rem 0.7rem;
}
.oop-feed-count {
    font-size: 0.72rem;
    letter-spacing: 0.6px;
    text-transform: none;
    color: var(--text-dim, #93a1af);
    background: rgba(147, 161, 175, 0.12);
    border-radius: 999px;
    padding: 0.12rem 0.55rem;
    margin-left: 0.5rem;
    vertical-align: middle;
}
.oop-verdict-tools {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    flex-wrap: wrap;
    margin-top: 0.9rem;
}
.oop-verdict-tools .export-bar { margin: 0; }

.tool-status.is-error { color: #ff9d9d; }

@media (max-width: 640px) {
    .oop-object-grid { grid-template-columns: 1fr; }
}
