/* Asset Sidebar Component
   Right sidebar component displaying post ownership and market data
   Follows SVT Protocol (Self-Valued Token) data structure

   Data Source: asset_sidebar_context processor in forum/context_processors.py
   Template: templates/includes/asset_sidebar.html
*/

/* Section Structure */
.asset-sidebar {
    font-family: var(--font-family-mono);
    font-size: var(--font-size-sm);
    color: var(--color-text-primary);
    padding-top: var(--spacing-3);
}

/* Section Container - Unified spacing control */
.asset-section-container {
    margin-bottom: var(--spacing-3);  /* 1.5x section-end spacing */
}

/* Remove bottom margin from last section (no trailing space) */
.asset-sidebar > .asset-section-container:last-child {
    margin-bottom: 0;
}

/* Remove bottom margin from last child within each section (prevents double spacing) */
.asset-section-container > *:last-child {
    margin-bottom: 0;
}

/* Section Labels */
.asset-section-label {
    font-family: var(--font-family-headings);
    font-weight: var(--font-weight-bold);
    color: var(--color-text-primary);
    margin-bottom: var(--spacing-2);
    margin-top: 0;  /* Section spacing controlled by container */
    font-size: var(--font-size-lg);
}

/* Herald Intro Text - Uses body font instead of mono */
.herald-intro-text {
    font-family: var(--font-family-base);
    color: var(--color-text-primary);
    margin-bottom: var(--spacing-2);
    margin-top: 0;
}

/* Herald Intro Link - Clickable "The Herald" text in intro paragraph */
.herald-intro-link {
    color: var(--color-accent);
    text-decoration: none;
    text-underline-offset: 2px;
}

.herald-intro-link:hover {
    color: var(--color-accent-dark);
    text-decoration: underline;
}

/* Herald Action Button - Extra spacing for visual separation */
.herald-action-button {
    margin-top: var(--spacing-4);
    margin-bottom: var(--spacing-3);
}

/* User Information Display */
.herald-user-info {
    display: flex;
    flex-direction: column;
}

/* Address line wrapper - keeps indicator and ethereum address on same line */
.asset-address-line {
    display: flex;
    align-items: baseline;
    gap: var(--spacing-1);
    margin-bottom: var(--spacing-2);
    font-family: var(--font-family-mono);
}

/* Address indicator (">") */
.asset-address-indicator {
    color: var(--color-text-secondary);
    font-family: var(--font-family-mono);
    flex-shrink: 0;
}

/* Herald username base styling (structural only) */
.herald-username {
    font-weight: bold;
    text-decoration: none;
}

/* Unheralded state - toned down since it's an empty/available state */
span.herald-username {
    color: var(--color-text-muted);
    font-weight: normal;
}

/* Primary color for linked Original Author username */
.author-username {
    font-weight: bold;
    color: var(--color-accent);
}

.author-username:hover {
    color: var(--color-accent-dark);
    text-decoration: underline;
}

/* Herald Username Shimmer Effects
   Shimmer effects have been moved to _username_effects.css for reusability
   across multiple contexts (herald sidebar, style guide, future features).
   See: /static/css/03-components/_username_effects.css
*/

.herald-metadata {
    color: var(--color-text-secondary);
    display: block;
    margin-bottom: var(--spacing-2);
}

/* Stat Rows */
.asset-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

/* Timestamp Rows - left-aligned text flow (no space-between) */
.asset-timestamp-row {
    color: var(--color-text-secondary);
    margin-bottom: var(--spacing-1);
}

.asset-stat-label {
    color: var(--color-text-secondary);
    display: block;
    margin-bottom: var(--spacing-2);
}

.asset-stat-value .timestamp {
    color: var(--color-text-secondary);
}

/* Visual Separator */
.asset-divider {
    border: none;
    border-top: var(--border-width-1) solid var(--border-color);
    margin: var(--spacing-5) 0;
}

/* History Section */
.asset-history-entry {
    display: flex;
    flex-direction: column;
}

.asset-prev-val-display {
    color: var(--color-text-secondary);
    margin-bottom: var(--spacing-2);
    /* font-family removed - now uses .eth-value class */
}

/* Original Author Badge */
.badge-original-author {
    font-size: 0.85em;
    margin-left: 0.25rem;
    opacity: 0.8;
}

/* No History Message */
.asset-no-history {
    color: var(--color-text-secondary);
    font-style: italic;
    margin: var(--spacing-2) 0;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .asset-sidebar {
        padding: var(--spacing-3);
    }

}
