/* ═══════════════════════════════════════════════
   DryFairy — System View (Pergament-Kartografie)
   ═══════════════════════════════════════════════ */

.sf-system-view {
    padding: 20px 24px;
    margin: 0 auto;
    height: calc(100vh - 106px);
    display: flex;
    flex-direction: column;
}
.sf-system-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
    flex-shrink: 0;
}
.sf-system-title {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}
.sf-system-title h2 {
    margin: 0;
    font-family: 'Cinzel', serif;
    font-size: 26px;
    color: #e8d8b8;
    text-shadow: 0 2px 8px rgba(0,0,0,0.4);
}
.sf-sys-icon { font-size: 30px; }
.sf-sys-type {
    font-size: 14px;
    padding: 5px 14px;
    border-radius: 20px;
    background: rgba(20, 16, 10, 0.6);
    border: 1px solid rgba(222, 167, 38, 0.25);
    color: #c8b898;
}
.sf-sys-danger { font-size: 14px; color: #dea726; }

/* System Hex Layout */
.sf-system-hex-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 20px;
    flex: 1;
    min-height: 0;
}

/* ── Hex Canvas Wrapper (Pergament-Rahmen) ── */
.sf-hex-system-wrap {
    background: #d4bc8b;
    border: 3px solid rgba(120, 90, 40, 0.5);
    border-radius: 4px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 24px rgba(0,0,0,0.3), inset 0 0 20px rgba(100,80,40,0.15);
}
.sf-hex-system {
    display: block;
    width: 100%;
    height: 100%;
}

/* ── Sidebar (dunkles Panel, kontrastreicher Pergament-Look) ── */
.sf-system-sidebar {
    background: rgba(20, 16, 10, 0.92);
    border: 1px solid rgba(222, 167, 38, 0.25);
    border-radius: 8px;
    padding: 22px;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4), inset 0 1px 0 rgba(222,167,38,0.08);
    backdrop-filter: blur(4px);
}
.sf-system-sidebar h3 {
    font-size: 13px;
    color: #dea726;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin: 0 0 14px 0;
    font-family: 'Cinzel', serif;
}
.sf-system-sidebar h3:not(:first-child) { margin-top: 22px; }

.sf-sidebar-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.sf-info-row {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    color: #e8d8b8;
    padding: 8px 12px;
    border-radius: 6px;
    transition: background 0.15s;
    border: 1px solid transparent;
}
.sf-info-row:hover {
    background: rgba(222, 167, 38, 0.06);
    border-color: rgba(222, 167, 38, 0.12);
}
.sf-info-row span:first-child { color: #a09070; }
.sf-danger-val { color: #dea726; }

.sf-sidebar-hint {
    margin-top: 16px;
    font-size: 13px;
    color: rgba(200, 184, 136, 0.5);
    text-align: center;
    font-style: italic;
}

.sf-poi-list { display: flex; flex-direction: column; gap: 4px; }
.sf-poi-chip {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    background: rgba(30, 25, 15, 0.6);
    border: 1px solid rgba(222, 167, 38, 0.15);
    border-radius: 6px;
    font-size: 14px;
    color: #c8b898;
    transition: all 0.15s;
}
.sf-poi-chip:hover {
    background: rgba(40, 32, 18, 0.8);
    border-color: rgba(222, 167, 38, 0.35);
}

/* Legacy body cards */
.sf-body-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    background: rgba(30, 25, 15, 0.6);
    border: 1px solid rgba(222, 167, 38, 0.15);
    border-radius: 6px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s;
    color: #e8d8b8;
}
.sf-body-card:hover {
    border-color: rgba(222, 167, 38, 0.4);
    background: rgba(40, 32, 18, 0.8);
    box-shadow: 0 0 12px rgba(222,167,38,0.15);
    transform: translateY(-1px);
}
.sf-body-home { border-color: rgba(61,220,132,0.35); box-shadow: 0 0 12px rgba(61,220,132,0.15); }
.sf-body-icon { font-size: 36px; }
.sf-body-info { flex: 1; }
.sf-body-name { font-weight: 600; font-size: 16px; color: #e8d8b8; }
.sf-home-badge { font-size: 12px; color: #3ddc84; font-weight: 400; }
.sf-body-type { font-size: 14px; color: #a09070; margin-top: 3px; }
.sf-body-resources { display: flex; gap: 10px; margin-top: 6px; flex-wrap: wrap; }
.sf-body-res { font-size: 13px; color: #c8b898; }
.sf-body-atmo { font-size: 13px; color: #dea726; margin-top: 6px; }
.sf-no-res { font-size: 13px; color: #8a7a6a; }

/* ═══════════════════════════════════════════════
   Fog of War
   ═══════════════════════════════════════════════ */

.sf-body-unknown {
    opacity: 0.5;
    border-style: dashed;
    border-color: rgba(222, 167, 38, 0.2);
}
.sf-body-unknown:hover {
    opacity: 0.7;
    border-color: rgba(222, 167, 38, 0.35);
}
.sf-body-icon-unknown { filter: grayscale(1); opacity: 0.6; }
.sf-name-unknown { font-style: italic; color: #8a7a6a; }
.sf-btn-explore {
    background: rgba(61, 220, 132, 0.1);
    border: 1px solid rgba(61, 220, 132, 0.35);
    color: #3ddc84;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
    padding: 8px 16px;
    border-radius: 6px;
}
.sf-btn-explore:hover {
    background: rgba(61, 220, 132, 0.18);
    box-shadow: 0 0 12px rgba(61,220,132,0.2);
    transform: translateY(-1px);
}
.sf-btn-explore.sf-btn-disabled,
.sf-btn-explore:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}
.sf-discovered-count { font-size: 14px; color: #a09070; font-weight: 400; }

/* ═══════════════════════════════════════════════
   System Counted View (Level 2)
   ═══════════════════════════════════════════════ */

.sf-system-counted {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    text-align: center;
    gap: 12px;
}
.sf-counted-icon {
    font-size: 56px;
    opacity: 0.6;
}
.sf-counted-text {
    font-family: 'Cinzel', serif;
    font-size: 20px;
    color: #e8d8b8;
}
.sf-counted-hint {
    font-size: 13px;
    color: #a09070;
    max-width: 450px;
    line-height: 1.5;
}

/* ═══════════════════════════════════════════════
   Building Detail Panel (in sidebar)
   ═══════════════════════════════════════════════ */

.sf-building-detail .sf-detail-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}
.sf-building-detail .sf-detail-icon {
    font-size: 42px;
    flex-shrink: 0;
}
.sf-building-detail .sf-detail-name {
    font-family: 'Cinzel', serif;
    font-size: 18px;
    font-weight: 600;
    color: #e8d8b8;
    display: flex;
    align-items: center;
    gap: 8px;
}
.sf-building-detail .sf-detail-meta {
    font-size: 13px;
    color: #a09070;
    margin-top: 4px;
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
.sf-building-detail .sf-detail-desc {
    font-size: 13px;
    color: #c8b898;
    line-height: 1.6;
}

.sf-scan-progress {
    margin-top: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.sf-scan-bar {
    flex: 1;
    height: 4px;
    background: rgba(222, 167, 38, 0.12);
    border-radius: 2px;
    overflow: hidden;
}
.sf-scan-fill {
    height: 100%;
    background: #dea726;
    border-radius: 2px;
    transition: width 0.3s;
}
.sf-scan-label {
    font-size: 12px;
    color: #a09070;
    white-space: nowrap;
}

/* Rename button */
.sf-btn-rename-sm {
    background: none;
    border: none;
    color: #a09070;
    cursor: pointer;
    font-size: 14px;
    padding: 2px 4px;
    opacity: 0.6;
    transition: opacity 0.2s;
}
.sf-btn-rename-sm:hover {
    opacity: 1;
    color: #dea726;
}
