/* Guide density — collapsible reference blocks (cheats / careers / storyteller) */

.wiki-fold-panel {
    border-radius: 1rem;
    border: 1px solid rgba(195, 200, 191, 0.55);
    background: rgba(255, 255, 255, 0.5);
    overflow: hidden;
}

.wiki-fold-panel-summary {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    cursor: pointer;
    list-style: none;
    user-select: none;
}

.wiki-fold-panel-summary::-webkit-details-marker {
    display: none;
}

.wiki-fold-panel-chevron {
    color: #7d562d;
    transition: transform 0.2s ease;
    flex-shrink: 0;
    margin-top: 0.125rem;
}

.wiki-fold-panel[open] .wiki-fold-panel-chevron {
    transform: rotate(180deg);
}

.wiki-fold-panel-body {
    border-top: 1px solid rgba(195, 200, 191, 0.35);
    padding: 1rem 1.25rem 1.25rem;
}

/* Cheats — category folds inside reference */
.wiki-cheat-cat-fold {
    border-radius: 0.75rem;
    border: 1px solid rgba(195, 200, 191, 0.45);
    background: rgba(248, 244, 219, 0.5);
    overflow: hidden;
}

.wiki-cheat-cat-fold-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    cursor: pointer;
    list-style: none;
    font-weight: 600;
    font-size: 0.875rem;
    color: #4a6549;
}

.wiki-cheat-cat-fold-summary::-webkit-details-marker {
    display: none;
}

.wiki-cheat-cat-fold-count {
    font-size: 0.75rem;
    font-weight: 600;
    color: #7d562d;
    opacity: 0.85;
}

.wiki-cheat-cat-fold-body {
    padding: 0.5rem 0.75rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.wiki-cheat-cat-fold .cheat-row {
    padding: 0.75rem 1rem !important;
    box-shadow: none !important;
}

.wiki-cheat-cat-fold .cheat-row .cheat-row-body h3 {
    font-size: 0.875rem !important;
}

.wiki-cheat-cat-fold .cheat-row .cheat-row-body p {
    font-size: 0.8125rem !important;
    line-height: 1.4;
}

.wiki-cheat-cat-fold .cheat-row .cheat-row-body [data-i18n^="cheats.cat"] {
    display: none;
}

.wiki-cheat-cat-fold .cheat-row .cheat-row-actions .copy-btn {
    width: 2.25rem;
    height: 2.25rem;
}

/* Careers — domain filter tabs */
.wiki-career-filter-tab {
    transition: background-color 0.15s ease, color 0.15s ease;
}

.wiki-career-filter-tab.is-active {
    background-color: #4a6549;
    color: #ffffff;
}

.wiki-career-domain-row.is-hidden,
.wiki-career-domain-card.is-hidden,
.wiki-melino-purpose-row.is-hidden,
.wiki-melino-purpose-card.is-hidden {
    display: none !important;
}

.wiki-career-table-wrap {
    overflow-x: auto;
    border-radius: 0.75rem;
    border: 1px solid rgba(195, 200, 191, 0.45);
}

.wiki-career-table {
    width: 100%;
    min-width: 640px;
    border-collapse: collapse;
    font-size: 0.8125rem;
}

.wiki-career-table th {
    text-align: left;
    padding: 0.625rem 0.75rem;
    background: rgba(139, 168, 136, 0.18);
    color: #4a6549;
    font-weight: 600;
}

.wiki-career-table td {
    padding: 0.625rem 0.75rem;
    border-top: 1px solid rgba(195, 200, 191, 0.35);
    vertical-align: top;
    color: #434841;
}

.wiki-career-table tbody tr:hover {
    background: rgba(248, 244, 219, 0.6);
}

@media (min-width: 1024px) {
    .wiki-tool-layout {
        align-items: stretch;
    }
}

.wiki-tool-fields {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
}

@media (min-width: 640px) {
    .wiki-tool-fields--2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .wiki-tool-fields--3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 1280px) {
    .wiki-tool-fields--3 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.wiki-tool-field {
    min-width: 0;
}

.wiki-tool-label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #5c6359;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.wiki-tool-select,
.wiki-tool-input {
    display: block;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    padding: 0.6875rem 3rem 0.6875rem 0.875rem;
    border-radius: 0.75rem;
    border: 1px solid rgba(195, 200, 191, 0.65);
    background-color: #ffffff;
    font-size: 0.875rem;
    line-height: 1.4;
    color: #434841;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.wiki-tool-input {
    padding-right: 0.875rem;
}

.wiki-tool-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    background-color: #ffffff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%237d562d' stroke-width='2.25' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat;
    background-position: right 0.625rem center;
    background-size: 1.125rem;
    cursor: pointer;
}

.wiki-tool-select:focus,
.wiki-tool-input:focus {
    outline: none;
    border-color: #8ba888;
    box-shadow: 0 0 0 2px rgba(139, 168, 136, 0.35);
}

.wiki-tool-select:disabled,
.wiki-tool-input:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.wiki-tool-main {
    flex: 1 1 0%;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.wiki-tool-result {
    display: flex;
    flex-direction: column;
    width: 100%;
    flex-shrink: 0;
    border-radius: 1rem;
    padding: 1.25rem;
    box-sizing: border-box;
}

@media (min-width: 1024px) {
    .wiki-tool-layout .wiki-tool-result {
        width: 24rem;
        max-width: 100%;
        align-self: stretch;
        position: sticky;
        top: 7rem;
    }
}

.wiki-tool-result-footer {
    margin-top: auto;
    padding-top: 1rem;
}

.wiki-tool-result h3 {
    font-size: 1.125rem;
    line-height: 1.35;
    word-break: break-word;
}

.wiki-tool-result p,
.wiki-tool-result li,
.wiki-tool-result span {
    word-break: break-word;
}

.wiki-tool-code {
    display: block;
    width: 100%;
    min-height: 3rem;
    padding: 0.875rem 1rem;
    border-radius: 0.75rem;
    border: 1px solid rgba(195, 200, 191, 0.35);
    word-break: break-all;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.8125rem;
    line-height: 1.45;
}

.wiki-tool-checklist {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.wiki-tool-checklist--grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.75rem;
}

@media (min-width: 768px) {
    .wiki-tool-checklist--grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.wiki-tool-checklist label {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    padding: 0.75rem 0.875rem;
    border-radius: 0.75rem;
    border: 1px solid rgba(195, 200, 191, 0.5);
    background: rgba(248, 244, 219, 0.35);
    cursor: pointer;
    font-size: 0.875rem;
    line-height: 1.45;
    color: #434841;
    transition: background-color 0.15s ease;
}

.wiki-tool-checklist label:hover {
    background: rgba(248, 244, 219, 0.65);
}

.wiki-tool-checklist input[type="checkbox"] {
    margin-top: 0.15rem;
    flex-shrink: 0;
    width: 1rem;
    height: 1rem;
    accent-color: #4a6549;
}

.wiki-tool-status {
    margin-top: 1.25rem;
    padding: 1rem 1.125rem;
    border-radius: 1rem;
}

.wiki-tool-badge {
    display: block;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.wiki-tool-step-num {
    display: flex;
    height: 1.5rem;
    width: 1.5rem;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    background-color: #7d562d;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
}
