.linkmap-group {
    background: #fff;
    border: 1px solid #ccd0d4;
    box-shadow: 0 1px 1px rgba(0,0,0,.04);
    margin-bottom: 20px;
    padding: 0;
    border-radius: 3px;
}
.linkmap-group-header {
    border-bottom: 1px solid #ccd0d4;
    margin: 0;
    padding: 12px 15px;
    background: #f8f9f9;
    font-size: 14px;
    line-height: 1.4;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.linkmap-group-title {
    margin: 0;
    font-size: 14px;
    line-height: 1.4;
}
.linkmap-candidates {
    padding: 15px;
}
.mapping-option {
    background: #fff;
    border: 1px solid #e5e5e5;
    box-shadow: 0 1px 1px rgba(0,0,0,.04);
    margin-bottom: 10px;
    border-radius: 3px;
    position: relative;
    transition: all .2s ease-in-out;
}
.mapping-option:hover {
    border-color: #999;
    box-shadow: 0 1px 2px rgba(0,0,0,.1);
}
.mapping-option.is-disabled {
    opacity: 0.7;
    pointer-events: none;
    background: #f8f9f9;
}
.mapping-option.is-disabled:after {
    content: attr(data-disabled-reason);
    display: inline-block;
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #72777c;
    font-style: italic;
}
.mapping-option.is-already-mapped {
    opacity: 0.7;
    pointer-events: none;
    background: #f1f1f1;
}
.mapping-option.is-already-mapped .mapping-status-message {
    display: inline-block;
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #72777c;
    font-style: italic;
}
.mapping-header {
    padding: 12px 15px;
    border-bottom: 1px solid #f0f0f0;
}
.mapping-keyword {
    font-size: 14px;
    font-weight: 600;
    color: #1d2327;
    margin: 0;
}
.mapping-content {
    padding: 12px 15px;
}
.mapping-url {
    margin-bottom: 10px;
    color: #50575e;
}
.mapping-url a {
    text-decoration: none;
}
.mapping-select {
    margin-top: 8px;
}
.mapping-select label {
    display: inline-block;
    margin-left: 4px;
    color: #3c434a;
}
.clear-selection {
    color: #a00;
    text-decoration: none;
    font-size: 13px;
}
.clear-selection:hover {
    color: #dc3232;
    text-decoration: none;
}
.clear-selection .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    vertical-align: text-bottom;
}

/* Visualization styles */
.linkmap-tab-content {
    margin-top: 20px;
}

.linkmap-visualization-container {
    position: relative;
    background: #fff;
    border: 1px solid #ccd0d4;
    box-shadow: 0 1px 1px rgba(0,0,0,.04);
    padding: 20px;
    border-radius: 3px;
}

#linkmap-graph {
    height: 500px;
    width: 100%;
    background-color: #f8f9f9;
    border: 1px solid #e5e5e5;
    border-radius: 3px;
}

.linkmap-visualization-legend {
    margin-top: 15px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.linkmap-visualization-legend h3 {
    margin: 0;
    font-size: 14px;
    margin-right: 10px;
}

.legend-item {
    display: flex;
    align-items: center;
    margin-right: 15px;
    font-size: 13px;
}

.legend-color {
    display: inline-block;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    margin-right: 5px;
}

.post-color {
    background-color: #2271b1;
}

.page-color {
    background-color: #3582c4;
}

.legend-arrow {
    display: inline-block;
    width: 20px;
    height: 6px;
    background-color: #72777c;
    position: relative;
    margin-right: 5px;
}

.legend-arrow:after {
    content: '';
    position: absolute;
    right: -4px;
    top: -2px;
    border-left: 6px solid #72777c;
    border-top: 5px solid transparent;
    border-bottom: 5px solid transparent;
}

.linkmap-visualization-controls {
    position: absolute;
    top: 30px;
    right: 30px;
    display: flex;
    gap: 5px;
}

.linkmap-visualization-controls .button {
    padding: 0;
    width: 30px;
    height: 30px;
    text-align: center;
}

.linkmap-visualization-controls .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    margin-top: 7px;
}
