@use '../abstracts' as *;

// Specific styles for the Entry Details Modal content

.gfm-details-table {
    width: 100%;
    border-collapse: separate;
    margin-bottom: $space-lg;
    border: 1px solid $border;
    border-radius: $radius;
    overflow: hidden;
    background: $white;

    tr:nth-child(even) {
        background: #F9FAFB;
    }

    th,
    td {
        padding: 16px 20px;
        font-size: $size-base;
        text-align: left;
        border-bottom: 1px solid $border;
    }

    tr:last-child td {
        border-bottom: none;
    }

    .gfm-label-col {
        width: 30%;
        font-weight: $weight-bold;
        color: $text-muted;
        background: rgba($bg, 0.5);
        font-size: 13px;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        border-right: 1px solid $border;
    }

    .gfm-value-col {
        color: $text-main;
        line-height: 1.5;
    }
}

.gfm-system-info-box {
    background: $primary-light;
    border: 1px solid rgba($primary, 0.1);
    border-radius: $radius-md;
    padding: $space-md;

    .gfm-system-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: $space-sm;
    }

    .gfm-system-row {
        display: flex;
        align-items: center;
        gap: 10px;
        font-size: 13px;
        color: $text-main;
        padding: 8px $space-sm;
        background: rgba($white, 0.6);
        border-radius: $radius-sm;
        border: 1px solid rgba($white, 0.5);

        .dashicons {
            color: $primary;
            font-size: 18px;
            width: 18px;
            height: 18px;
        }

        strong {
            color: $text-muted;
            margin-right: 4px;
        }

        code {
            background: rgba($white, 0.8);
            color: $primary;
            padding: 2px 6px;
            border-radius: 4px;
            font-family: inherit;
            font-weight: 600;
        }
    }
}

.gfm-source-link {
    color: $primary;
    text-decoration: none;
    word-break: break-all;
    font-weight: 600;

    &:hover {
        color: $primary-dark;
        text-decoration: underline;
    }
}

.gfm-pro-marketing-row {
    margin-top: $space-sm;
    padding: $space-sm;
    background: #FFFBEB;
    border: 1px solid #FEF3C7;
    border-radius: $radius-md;
    display: flex;
    align-items: center;
    gap: 12px;

    .gfm-blurred-text {
        filter: blur(5px);
        opacity: 0.4;
        user-select: none;
        font-size: 13px;
    }

    .gfm-pro-lock-badge {
        @include badge(#92400e);
        background: #FDE68A;
        margin-left: auto;
    }
}

.gfm-empty-state {
    padding: $space-xl * 1.5 $space-md;
    text-align: center;
    background: $white;
    border-radius: $radius-lg;
    border: 2px dashed $border;
    margin: $space-md 0;

    .dashicons {
        font-size: 80px;
        width: 80px;
        height: 80px;
        color: $primary;
        margin-bottom: $space-md;
        display: inline-block;
        opacity: 0.15;
    }

    h2 {
        margin: 0 0 $space-xs 0;
        font-size: 24px;
        font-weight: 800;
        color: $text-main;
        letter-spacing: -0.02em;
    }

    p {
        color: $text-muted;
        margin-bottom: $space-lg;
        font-size: 16px;
        max-width: 400px;
        margin-left: auto;
        margin-right: auto;
    }

    .gfm-empty-state-actions {
        display: flex;
        justify-content: center;
        gap: $space-sm;
        flex-wrap: wrap;
    }
}

.gfm-header-flex {
    @include flex-between;
    margin-bottom: $space-lg;
    padding: $space-sm 0;

    h1 {
        margin: 0;
        font-size: 28px;
        font-weight: 800;
        letter-spacing: -0.02em;
    }

    .gfm-actions {
        display: flex;
        gap: $space-sm;
    }
}

// ========================================
// Entry Detail Layout
// ========================================

.gfm-entry-detail-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 20px;

    @media (max-width: 768px) {
        grid-template-columns: 1fr;
    }

    h3 {
        margin-top: 0;
        font-size: 16px;
        font-weight: 700;
        color: $text-main;
    }
}

.gfm-entry-meta {
    line-height: 2;

    p {
        margin: 0 0 $space-xs 0;
    }
}

.gfm-entry-sidebar-card {
    margin-bottom: $space-md;
}